projects
/
tatoo.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Simplify the automaton encoding a bit (remove redundant predicates in formulae).
[tatoo.git]
/
src
/
xpath
/
ulexer.ml
diff --git
a/src/xpath/ulexer.ml
b/src/xpath/ulexer.ml
index
baa794d
..
02b6e02
100644
(file)
--- a/
src/xpath/ulexer.ml
+++ b/
src/xpath/ulexer.ml
@@
-122,7
+122,8
@@
let rec token = lexer
| "node()" -> NODE
| "text()" -> TEXT
| "comment()" -> COMMENT
| "node()" -> NODE
| "text()" -> TEXT
| "comment()" -> COMMENT
- | '@' ncname -> ATTNAME (L.utf8_lexeme lexbuf)
+ | '@' ncname -> let l = L.utf8_lexeme lexbuf in
+ ATTNAME (String.sub l 1 (String.length l - 1))
| "processing-instruction()" -> PI ""
| "processing-instruction('"ncname"')"
| "processing-instruction(\""ncname"\")"->
| "processing-instruction()" -> PI ""
| "processing-instruction('"ncname"')"
| "processing-instruction(\""ncname"\")"->