Skip to content

Commit

Permalink
Merge pull request #1125 from michaelhkay/1094-enhanced-lookup-expres…
Browse files Browse the repository at this point in the history
…sions

1094 Enhanced lookup expressions
  • Loading branch information
michaelhkay authored Apr 23, 2024
2 parents cf1a778 + 0ddaa64 commit c583d83
Show file tree
Hide file tree
Showing 2 changed files with 314 additions and 62 deletions.
25 changes: 25 additions & 0 deletions specifications/grammar-40/xpath-grammar.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2088,9 +2088,22 @@ ErrorVal ::= "$" VarName
<g:string>?</g:string>
<g:string>??</g:string>
</g:choice>
<g:optional>
<g:ref name="Modifier"/>
<g:string>::</g:string>
</g:optional>
<g:ref name="KeySpecifier"/>
</g:production>

<g:production name="Modifier">
<g:choice>
<g:string>pairs</g:string>
<g:string>keys</g:string>
<g:string>values</g:string>
<g:string>items</g:string>
</g:choice>
</g:production>

<g:production name="KeySpecifier" if="xpath40 xquery40">
<g:choice>
<g:ref name="NCName"/>
Expand All @@ -2099,12 +2112,20 @@ ErrorVal ::= "$" VarName
<g:ref name="VarRef" if="xpath40 xquery40"/>
<g:ref name="ParenthesizedExpr"/>
<g:ref name="LookupWildcard"/>
<g:ref name="TypeQualifier"/>
</g:choice>
</g:production>

<g:production name="LookupWildcard">
<g:string process-value="yes">*</g:string>
</g:production>

<g:production name="TypeQualifier">
<g:string>type</g:string>
<g:string>(</g:string>
<g:ref name="SequenceType"/>
<g:string>)</g:string>
</g:production>

<g:production name="ArrowStaticFunction">
<g:ref name="EQName"/>
Expand Down Expand Up @@ -2664,6 +2685,10 @@ ErrorVal ::= "$" VarName
<g:string>?</g:string>
<g:string>??</g:string>
</g:choice>
<g:optional>
<g:ref name="Modifier"/>
<g:string>::</g:string>
</g:optional>
<g:ref name="KeySpecifier"/>
</g:production>

Expand Down
Loading

0 comments on commit c583d83

Please sign in to comment.