Sorry, I missed your reply. Yes it is what you described.

Le jeu. 10 mars 2022 à 11:25, Claude Warren <claude.war...@instaclustr.com>
a écrit :

> I found it in https://github.com/antlr/grammars-v4.git and I suspected it
> was wrong.  I assume it should be that the tuple can contain 1 or more
> elements and the elements may be of type  tuple, constant, map, list or
> set.
>
> Does that make sense?  I think that is what I saw in the code base.
>
> On Thu, 10 Mar 2022 at 09:38, Benjamin Lerer <ble...@apache.org> wrote:
>
>> Hi Claude,
>>
>> I am not aware of the CqlParser.g4 file in our code base. Where did you
>> find that file?
>>
>> At first glance effectively something looks wrong in the syntax. The
>> construct ((4 ,5 ), 6, (7, 8)) should be legal in CQL.
>>
>> Le jeu. 10 mars 2022 à 06:50, Claude Warren <
>> claude.war...@instaclustr.com> a écrit :
>>
>>> I have been looking at  CqlParser.g4 file for cql3  and have a question
>>> about assignment tuples.  The assignment tuple is defined as :
>>>
>>> assignmentTuple
>>>    : syntaxBracketLr (
>>>          constant ((syntaxComma constant)* | (syntaxComma 
>>> assignmentTuple)*) |
>>>          assignmentTuple (syntaxComma assignmentTuple)*
>>>      ) syntaxBracketRr
>>>    ;
>>>
>>> which I read to be ( constant [, constant | tuple ... ]) or ( tuple [,
>>> tuple...]) .  So the construct ((4 ,5 ), 6, (7, 8)) is not a legal
>>> tuple.2 questions:
>>>
>>>    1.  Is my interpretation of the grammar correct?
>>>    2. Is my example tuple supposed to be allowed?
>>>
>>>
>>> Claude
>>>
>>> --
>>>
>>> [image: Instaclustr logo]
>>>
>>>
>>> *Claude Warren*
>>>
>>> Principal Software Engineer
>>>
>>> Instaclustr
>>>
>>>
>>>
>>>

Reply via email to