X-Git-Url: http://git.nguyen.vg/gitweb/?p=tatoo.git;a=blobdiff_plain;f=src%2Fxpath%2Fxpath_internal_parser.mly;h=3651d2cd9e547a0e2ff239bdcbe61c40f64da233;hp=fe38f67d41c342b450b09a5beae0eaaf96e47722;hb=238dc42c2cb6324b103585556c3f5f9150ee221e;hpb=97cc08246d4a73e9cc9070f645a351799b7340d1 diff --git a/src/xpath/xpath_internal_parser.mly b/src/xpath/xpath_internal_parser.mly index fe38f67..3651d2c 100644 --- a/src/xpath/xpath_internal_parser.mly +++ b/src/xpath/xpath_internal_parser.mly @@ -15,7 +15,7 @@ (***********************************************************************) (* - Time-stamp: + Time-stamp: *) open Ast @@ -23,6 +23,7 @@ %} %token TAG +%token ATTNAME %token STRING %token INT %token FLOAT @@ -85,7 +86,7 @@ step: axis_test: AXIS COLONCOLON test { let a, t = $1, $3 in - if a == Attribute && Utils.QNameSet.is_finite t then + if a == Attribute && Utils.QNameSet.is_finite t then (a, Utils.QNameSet.fold (fun t a -> Utils.QNameSet.add @@ -101,6 +102,8 @@ axis_test: let a = Format.flush_str_formatter () in Child, Utils.QNameSet.singleton (Utils.QName.of_string a) } +| ATTNAME { (Attribute, + Utils.QNameSet.singleton (Utils.QName.of_string $1)) } ; test: @@ -151,4 +154,3 @@ arg_list1: expr { [ $1 ] } | arg_list1 COMMA expr { $3 :: $1 } ; -