- From: Mischa Tuffield <mischa.tuffield@garlik.com>
- Date: Sat, 9 Jul 2011 11:15:06 +0100
- To: Alex Hall <alexhall@revelytix.com>
- Cc: RDF WG <public-rdf-wg@w3.org>
- Message-Id: <A70BF0FE-7C14-4D35-8AD7-A000842BC9F6@garlik.com>
<snip/> On 9 Jul 2011, at 01:02, Alex Hall <alexhall@revelytix.com> wrote: > On Fri, Jul 8, 2011 at 12:29 PM, Mischa Tuffield <mischa.tuffield@garlik.com> wrote: > <snip/> > 5. In Section 4.4 - Grammar: there is a distinct lack of whitespacing here, I am guessing this is based the current grammar is but a first pass. There is an email thread I started on this list which includes feedback from a Stefano D'Angelo (parser implementer), I think we should make sure we address the issues brought forward there [1]. > > > There is a related note from Andy at [1]. Basically, whitespace and comments are included in the PASSED TOKENS rule, which indicates that whitespace and comments are allowed as tokens (a.k.a. terminals) anywhere in the grammar but ignored. This reflects the fact that many tools (javacc, Antlr, etc) can skip whitespace tokens or emit them on a special hidden channel. > > Note that section 4.1 does talk some about whitespace. Manually inserting whitespace tokens everywhere they could possibly appear in the grammar would be too difficult and would obscure the meaningful parts of the grammar. So we just say that it's allowed everywhere (outside of terminals) and only required to disambiguate two terminals that would otherwise be interpreted as one. > > Note also that the SPARQL grammar [2] handles whitespace in a similar fashion. I have just gone though SPARQL1.1 grammar and agreed the handling of whitespace is best left out to not obscure the meaningful parts. FWIW Section 4.1 is slightly confusing from my point of view perhaps the following statement in [a] should be expanded upon: "White space is significant in tokens IRI_REF and string." > -Alex > > [1] http://lists.w3.org/Archives/Public/public-rdf-wg/2011Mar/0297.html > [2] http://www.w3.org/TR/sparql11-query/#whitespace > The link [2] above doesn't resolve in my browser, and I can find any section entitled whitespace in the document, nevertheless I do prefer SPARQL's style over the older "ws" heavy turtle submission. Regards, Mischa [a] http://dvcs.w3.org/hg/rdf/raw-file/Turtle-FPWD/rdf-turtle/index.html#sec-grammar-ws - sent from a tablet thing
Received on Saturday, 9 July 2011 10:15:24 UTC