W3C home > Mailing lists > Public > www-webdav-dasl@w3.org > April to June 1999

RE: JW15: wildcards

From: Jim Whitehead <ejw@ics.uci.edu>
Date: Thu, 24 Jun 1999 17:12:14 -0700
To: "Babich, Alan" <ABabich@filenet.com>, "'DASL'" <www-webdav-dasl@w3.org>
Message-ID: <NDBBIKLAGLCOPGKGADOJCEDPCAAA.ejw@ics.uci.edu>
> "The BNF for a wildcard permits the entry of "</d:literal>" which
>   would confuse parsers."
>
> The spec. is precise and correct. The second operand
> of the "like" operator is a string literal. (This
> is completely consistent with all the other operators.)
> The syntax of the pattern contained in this string literal
> is given by the BNF in section 5.12.1. The only parser that
> needs to parse the body of the string literal is the
> parser embedded inside the query engine,
> in the implementation of the "like" operator.
> The XML parser won't be confused.
> So, I disagree that either parser would get "confused".
> Parsers don't get confused, people do (and then
> they write bugs). Implementers just need to read
> the spec. carefully.

An XML parser typically doesn't understand the contents inside its elements,
hence an XML parser which saw the sequence:

<d:literal>asdasdada</d:literal></d:literal>

Would be confused, since it would end the element at the first </d:literal>
and would flag an error at the second </d:literal>.  The BNF for the
interior of a literal element allows this to happen, and hence, in my
opinion, should be changed to escape "<" characters.

- Jim
Received on Thursday, 24 June 1999 20:14:22 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Sunday, 22 March 2009 03:38:04 GMT