[ 
https://issues.apache.org/jira/browse/METRON-1090?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16468992#comment-16468992
 ] 

ASF GitHub Bot commented on METRON-1090:
----------------------------------------

Github user cestella commented on the issue:

    https://github.com/apache/metron/pull/687
  
    Sorry, @ottobackwards this got lost in the shuffle.   What I was saying was 
that I think we should not adjust the VariableResolver infrastructure to update 
variables as the result of assignments, but rather return back the variable and 
the updated object.  For instance, in the `BaseStellarProcessor` class we have 
a `parse` method that returns the output of the expression.  I'd suggest we 
have a `parseExpression` and `parseAssignment` where the first acts as it does 
now and the second returns the variable name and the result.  As a follow-on, I 
think we can adjust the variableresolver infrastructure to support variable 
updates.
    
    I guess ultimately, I suggest a tactical solution that leads us to the 
right direction rather than trying to fix it all at once.
    
    Thoughts?


> STELLAR Add Assignment capability to Stellar language
> -----------------------------------------------------
>
>                 Key: METRON-1090
>                 URL: https://issues.apache.org/jira/browse/METRON-1090
>             Project: Metron
>          Issue Type: New Feature
>            Reporter: Otto Fowler
>            Assignee: Otto Fowler
>            Priority: Major
>
> Add support for =, +=, -=, *=, /= for variables in stellar.
> foo = 5  returns 5 AND sets foo to 5 if the VariableResolver supports it.
> The shell should be changed to assign variables using this syntax, because 
> exposing the left side to stellar allows catching errors for invalid keywords 
> in left side.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to