Correct and/or/div/mod in path expressions 22/99122/1
authorRobert Varga <robert.varga@pantheon.tech>
Sun, 19 Dec 2021 09:35:17 +0000 (10:35 +0100)
committerRobert Varga <robert.varga@pantheon.tech>
Mon, 20 Dec 2021 09:52:44 +0000 (10:52 +0100)
commitdaab64a496b958334cfbaaedd0f1f537df7bb938
treecb5055fafac80e6e91cc2eeed93363e7cb3e7568
parent45cecf9cfcc3039d7de06cb4c1a82f8a62e49ff0
Correct and/or/div/mod in path expressions

The grammar is creating implicit lexer tokens for and/or/div/mod, which
take precedence overt NCName. Make sure we define these tokens
explicitly and allow them to be an alternative wherever NCName is
valid.

JIRA: YANGTOOLS-1387
Change-Id: I4f4f26fe0f8bc27614b769b465a76696a49ad7c2
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
(cherry picked from commit 1a7e93a50d22944771fe2ea4fc18c24fcf3aae11)
yang/yang-xpath-antlr/src/main/antlr4/org/opendaylight/yangtools/yang/xpath/antlr/xpath.g4
yang/yang-xpath-impl/src/test/java/org/opendaylight/yangtools/yang/xpath/impl/XPathParserTest.java