[Bug 18861] [XSLT 3.0] predicates in patterns

https://www.w3.org/Bugs/Public/show_bug.cgi?id=18861

--- Comment #3 from Michael Kay <mike@saxonica.com> 2012-09-17 15:39:38 UTC ---
I believe the following revised grammar fixes the problems:

[1] Pattern       ::=       PatternTerm ( ('|' | 'union') PatternTerm )*

[2] PatternTerm       ::=       PathPattern ( ('intersect' | 'except')
PathPattern )*

[3]      PathPattern       ::=      
RelativePathPattern
| '/' RelativePathPattern?
| '//' RelativePathPattern
| StartPattern (('/'|'//') RelativePathPattern)?


[4]      RelativePathPattern       ::=       StepPattern (("/" | "//")
StepPattern)*

[5] StepPattern ::= PatternAxis? NodeTest{XP3} PredicateList{XP30}

[6] PatternAxis ::= ("child" "::")
| ("descendant" "::")
| ("attribute" "::")
| ("self" "::")
| ("descendant-or-self" "::")
| ("following-sibling" "::")
| ("following" "::")
| ("namespace" "::")
| "@"

[7] StartPattern ::= PrimaryPattern PredicateList{XP30}

[8] PrimaryPattern ::= VarRef{XP30} | ParenthesizedPattern | FunctionCall |
TypePattern

[9] ParenthesizedPattern ::= "(" Pattern ")"

[10] FunctionCall ::= DocCall | IdCall | ElementWithIdCall | KeyCall


[11]       DocCall       ::=       'doc' '(' ArgValue ')'
[12]       IdCall       ::=       'id' '(' ArgValue (',' ArgValue )? ')'
[13]       ElementWithIdCall       ::=       'element-with-id' '(' ArgValue
(',' ArgValue )? ')'
[14]       KeyCall       ::=       'key' '(' ArgValue ',' ArgValue (','
ArgValue )? ')'
[15]       ArgValue       ::=       Literal{XP30} | VarRef{XP30}

[16]       TypePattern       ::=       '~' ItemType{XP30}

-- 
Configure bugmail: https://www.w3.org/Bugs/Public/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.

Received on Monday, 17 September 2012 15:39:39 UTC