XPath IDL does not match spec (there is no modern spec) |
||||||
Issue descriptionhttps://www.w3.org/TR/2004/NOTE-DOM-Level-3-XPath-20040226/DOM3-XPath.html appears to be the most recent XPath specification, now 13 years old. In Blink we have XPath*.idl and DocumentXPathEvaluator.idl as the entry points to XPath, mainly being document.createExpression(), createNSResolver() and evaluate(), and the same methods on the XPathEvaluator interface. The details here do not match the 13 year old spec, which uses IDL constructs which are not part of Web IDL. When comparing Blink's IDL to all known specs, XPath thus shows up as lacking a spec. There are also differences to Gecko in practice. For example, document.evaluate.length is 2 in Chrome, but 5 in Firefox. If XPath is forever a part of the web platform, which seems likely, then at some point we need an actively maintained spec that defines it, where we can do the work of figuring out what the "right" value of document.evaluate.length is. This is fairly low priority.
,
Feb 9 2017
Some httparchive results for use of document.evaluate() and the XPathEvaluator constructor: https://bigquery.cloud.google.com:443/savedquery/762219082167:7d64259e252341d0a80572f6c809e825 https://bigquery.cloud.google.com:443/savedquery/762219082167:672aa415f04f4505aae4655fa257935b It looks like a lot of usage is from mootools. Probably there isn't much interesting to learn from looking closely, this is a situation where we "simply" need to specify and converge on what is already shipping, perhaps removing some corner cases that aren't interoperable.
,
Feb 13 2017
,
Mar 9 2017
,
Mar 9 2018
This issue has been Available for over a year. If it's no longer important or seems unlikely to be fixed, please consider closing it out. If it is important, please re-triage the issue. Sorry for the inconvenience if the bug really should have been left as Available. If you change it back, also remove the "Hotlist-Recharge-Cold" label. For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
,
Mar 10 2018
sshruthi@, are we tracking "missing specs" anywhere? Having this issue sitting around isn't hugely useful for prioritizing such cases I'm guessing, even though it's still valid.
,
Apr 12 2018
|
||||||
►
Sign in to add a comment |
||||||
Comment 1 by foolip@chromium.org
, Feb 9 2017