[
https://issues.apache.org/jira/browse/TINKERPOP-3047?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17941972#comment-17941972
]
ASF GitHub Bot commented on TINKERPOP-3047:
-------------------------------------------
Cole-Greer commented on code in PR #3091:
URL: https://github.com/apache/tinkerpop/pull/3091#discussion_r2033798312
##########
gremlin-language/src/main/antlr4/Gremlin.g4:
##########
@@ -22,6 +22,12 @@ grammar Gremlin;
PARSER RULES
**********************************************/
+gremlinValue
+ : (numericLiteral | booleanLiteral | stringLiteral | dateLiteral |
nullLiteral | nanLiteral | infLiteral |
+ traversalT | traversalCardinality | traversalDirection | traversalMerge
|
+ structureVertex | genericLiteralSet | genericLiteralCollection |
genericLiteralMap) EOF
Review Comment:
I'm wondering if we need some sort of `gremlinValueSet`,
`gremlinValueCollection`, and `gremlinValueMap`. It's a bit weird that
`DT.hour` is not a valid gremlinValue, but `[DT.hour]` is a gremlinValue.
Further, these collection types currently allow `nestedTraversal` and
`terminatedTraversal` to leak into `gremlinValue` which I assume is not desired.
> Grammar does not parse keywords into Map keys
> ---------------------------------------------
>
> Key: TINKERPOP-3047
> URL: https://issues.apache.org/jira/browse/TINKERPOP-3047
> Project: TinkerPop
> Issue Type: Bug
> Components: language
> Affects Versions: 3.7.1
> Reporter: Stephen Mallette
> Priority: Critical
>
> {{[keys: ["a","b"]}} won't work because "keys" ends up being parsed to
> {{Column.keys}}. another issue at play is the use of parens to wrap certain
> key definitions but not others. it doesn't feel consistent. like, it will
> work for {{T}} values but not for something like "edges" which is just a
> keyword token. Not sure it's wrong but it requires some examination.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)