- From: "Hermann Stamm-Wilbrandt" <STAMMW@d...>
- To: xml-dev@l...
- Date: Sat, 19 Dec 2015 15:12:10 +0100
More than a year ago Jonathan Robie tweeted on this nice XPath expression: false()=/..
The expression is true for XPath 1.0 and false for XPath 2.0. Therefore the expression can be named "isXPath1".
I cannot find his tweet anymore, nor my reply tweet with this minimal equivalent "isXPath1" expression: (4=5)=/..
I was not able to reduce the expression until today. Still above expression is minimal for "isXPath1", but a character can be reduced for "isXPath2": not(/..)
This expression is true for XPath 2.0 and false for XPath 1.0.
$ java net.sf.saxon.Query -qs:"(4=5)=/.." \!omit-xml-declaration=yes ; echo false $ java net.sf.saxon.Query -qs:"not(/..)" \!omit-xml-declaration=yes ; echo true $ java net.sf.saxon.Query 2>&1 | head -2 No query file name Saxon-HE 9.6.0.8J from Saxonica $
Mit besten Gruessen / Best wishes,
Hermann Stamm-Wilbrandt Compiler Level 3 support & Fixpack team lead IBM DataPower Gateways (⬚ᵈᵃᵗᵃ / ⣏⠆⡮⡆⢹⠁⡮⡆⡯⠂⢎⠆⡧⡇⣟⡃⡿⡃) https://www.ibm.com/developerworks/mydeveloperworks/blogs/HermannSW/ https://twitter.com/HermannSW/ https://stamm-wilbrandt.de/GraphvizFiddle/ ---------------------------------------------------------------------- IBM Deutschland Research & Development GmbH Vorsitzende des Aufsichtsrats: Martina Koederitz Geschaeftsfuehrung: Dirk Wittkopp Sitz der Gesellschaft: Boeblingen Registergericht: Amtsgericht Stuttgart, HRB 243294
[Date Prev]
| [Thread Prev]
| [Thread Next]
| [Date Next]
--
[Date Index]
| [Thread Index]
|