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
/
xpath_internal_parser.mly
diff --git
a/src/xpath/xpath_internal_parser.mly
b/src/xpath/xpath_internal_parser.mly
index
e5c0700
..
6395b6e
100644
(file)
--- a/
src/xpath/xpath_internal_parser.mly
+++ b/
src/xpath/xpath_internal_parser.mly
@@
-99,12
+99,7
@@
step:
axis_test:
AXIS COLONCOLON test { let a, (t,k) = $1, $3 in
match a with
axis_test:
AXIS COLONCOLON test { let a, (t,k) = $1, $3 in
match a with
- Attribute when QNameSet.is_finite t ->
- [ a, ((QNameSet.fold
- (fun t a ->
- QNameSet.add
- (QName.attribute t) a)
- t QNameSet.empty), k) ]
+ | Attribute -> [ a, (t, NodeKind.Attribute) ]
| Preceding|Following ->
[ (Descendant true, (t,k));
if a == Preceding then
| Preceding|Following ->
[ (Descendant true, (t,k));
if a == Preceding then
@@
-136,8
+131,7
@@
test:
}
| PI { (if $1 = "" then star
else QNameSet.singleton(
}
| PI { (if $1 = "" then star
else QNameSet.singleton(
- QName.processing_instruction (
- QName.of_string $1)
+ QName.of_string $1
)), NodeKind.ProcessingInstruction
}
| TAG { QNameSet.singleton(QName.of_string $1),
)), NodeKind.ProcessingInstruction
}
| TAG { QNameSet.singleton(QName.of_string $1),