[challenge] To implement XPath 2.0 in D

Justin Johansson no at spam.com
Mon Sep 13 07:46:31 PDT 2010


Is D2 suitable to implementing the W3C specifications
for XPath 2.0, and particularly the XPath & XQuery Data
Model (XDM), with both coding succinctness and runtime
time and space efficiency?

The reference links to the W3C specs are as follows:

XML Path Language (XPath) 2.0 (Second Edition)
http://www.w3.org/TR/2009/PER-xpath20-20090421/

XQuery 1.0 and XPath 2.0 Data Model (XDM) (Second Edition)
http://www.w3.org/TR/2009/PER-xpath-datamodel-20090421/

XQuery 1.0 and XPath 2.0 Formal Semantics (Second Edition)
http://www.w3.org/TR/2009/PER-xquery-semantics-20090421/

XQuery 1.0 and XPath 2.0 Functions and Operators (Second Edition)
http://www.w3.org/TR/2009/PER-xpath-functions-20090421/


Now, by suitability, I don't mean if it can be done.  Of course
it can be done in COBOL, assembler or any Turing machine
if one tries hard enough.

The challenge for D2 is to show that these W3C specs
can be implemented in D2 with ease (as say compared to
implementation in C++ or Java).

The biggest challenge that I see in any intelligent
implementation of these W3C specifications is to
produce an implementation that
(1) makes good balance of space and time complexity
from an algorithmic point of view
(2) demonstrates a well-read codification in the target
language which mirrors well, that is traceability,
with the W3C XPath/XDM specifications.
(3) implicit in (1) and (2) the target language lives
up to its expectations as advertised to be capable of
producing a concise and succinct implementation of
something as complex as XPath 2.0.

Is D2 up to a challenge a steep as this?

-- Justin Johansson






More information about the Digitalmars-d mailing list