-
- Downloads
Big fixes of pattern compilations
The problem is that "@node()", "attribute::node()", "child::node()" and "node()" are all handled in different code paths and only the latter works. Then, I noticed that the handling of match="child::name" is wrong. It matches the parents of <name> elements although it should be treated exactly like match="name". So the whole XSLT_OP_CHILD stuff is unneeded. I also found that xsltScanName behaves a bit strange with regard to ':' characters. It doesn't parse an XML Name like the documentation says. It's better to use xsltScanNCName instead. Another minor issue is that the parser currently allows invalid expressions like match="element*" because of lines 1745-1747 in pattern.c in trunk. * libxslt/pattern.c: fix all those problems * tests/REC/Makefile.am tests/REC/test-5.2-19* tests/REC/test-5.2-20* tests/REC/test-5.2-21*: add test cases to the regression suite
Showing
- libxslt/pattern.c 67 additions, 182 deletionslibxslt/pattern.c
- tests/REC/Makefile.am 3 additions, 0 deletionstests/REC/Makefile.am
- tests/REC/test-5.2-19.out 2 additions, 0 deletionstests/REC/test-5.2-19.out
- tests/REC/test-5.2-19.xml 4 additions, 0 deletionstests/REC/test-5.2-19.xml
- tests/REC/test-5.2-19.xsl 12 additions, 0 deletionstests/REC/test-5.2-19.xsl
- tests/REC/test-5.2-20.out 2 additions, 0 deletionstests/REC/test-5.2-20.out
- tests/REC/test-5.2-20.xml 4 additions, 0 deletionstests/REC/test-5.2-20.xml
- tests/REC/test-5.2-20.xsl 14 additions, 0 deletionstests/REC/test-5.2-20.xsl
- tests/REC/test-5.2-21.out 2 additions, 0 deletionstests/REC/test-5.2-21.out
- tests/REC/test-5.2-21.xml 4 additions, 0 deletionstests/REC/test-5.2-21.xml
- tests/REC/test-5.2-21.xsl 14 additions, 0 deletionstests/REC/test-5.2-21.xsl
Loading
Please register or sign in to comment