ammachado commented on code in PR #24120:
URL: https://github.com/apache/camel/pull/24120#discussion_r3447778463


##########
core/camel-core-languages/src/main/java/org/apache/camel/language/simple/SimpleExpressionParser.java:
##########
@@ -242,8 +241,8 @@ protected void removeIgnorableWhiteSpaceTokens() {
     protected void parseAndCreateAstModel() {
         // we loop the tokens and create a sequence of ast nodes
 
-        // counter to keep track of number of functions in the tokens
-        AtomicInteger functions = new AtomicInteger();
+        // single-element array used as a mutable counter (no concurrency; 
AtomicInteger is not needed here)

Review Comment:
   Correct on both counts: this counter is passed by reference into 
createNode(), not captured by a lambda, and the comment described the mechanism 
rather than what is tracked. Withdrawing the PR; see closing comment.
   
   _Claude Code on behalf of Adriano Machado_



##########
core/camel-core-languages/src/main/java/org/apache/camel/language/simple/SimplePredicateParser.java:
##########
@@ -334,25 +333,25 @@ private void addImageToken(LiteralNode imageToken) {
      * Creates a node from the given token
      *
      * @param  token         the token
-     * @param  startSingle   state of single quoted blocks
-     * @param  startDouble   state of double quoted blocks
-     * @param  startFunction state of function blocks
+     * @param  startSingle   state of single quoted blocks (single-element 
boolean array used as a mutable holder)
+     * @param  startDouble   state of double quoted blocks (single-element 
boolean array used as a mutable holder)
+     * @param  startFunction state of function blocks (single-element boolean 
array used as a mutable holder)
      * @return               the created node, or <tt>null</tt> to let a 
default node be created instead.

Review Comment:
   Agreed: the added text restates the boolean[] type and the original @param 
documented the semantic meaning. Withdrawing the PR; see closing comment.
   
   _Claude Code on behalf of Adriano Machado_



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to