W3C home > Mailing lists > Public > public-cwm-talk@w3.org > October to December 2007

Re: [Fwd: Turtle - Terse RDF Triple Language doc 2007-11-20 update]

From: Tim Berners-Lee <timbl@w3.org>
Date: Sun, 25 Nov 2007 20:04:45 -0500
Cc: Public CWM <public-cwm-talk@w3.org>, Ivan Herman <ivan@w3.org>, Dave Beckett <dave@dajobe.org>, Eric Prud'hommeaux <eric@w3.org>
Message-Id: <6A30459C-9A14-4179-94E9-CCA2DA509338@w3.org>
To: Dan Brickley <danbri@danbri.org>

> One thing I was thinking about, comparing with SPARQL
> is the difference in quoting for literals.  SPARQL allows
> 'foo' and '''foo''' as well as "foo" and """foo"" but
> Turtle only uses double quotes.  I need more information
> on whether to add this, does this causes N3/cwm problems?

Cwm has always had triple-double-quote, which are like python and, I  
invaluable for multi-line strings.

The single quotes and back quotes were reserved.
I wish they had been reserved in SPARQL too.
It is the sort of thing that, once you've allowed them, you can't  
reclaim them --
and then you find you want to extend the language and you are hosed as  
you have no characters left.

Single quotes could for example be used as:

- a different sort for string, one in which variable substitution occurs
   as in { ?x name ?y; phone ?z }  =>  { 'You can call $y on the phone  
at $z for more information' }.

- Nested quotes of some form with backquote, such as   `foaf:Person'  
meaning the string of the URI of that symbol, as in       myStatemet  
rdf:predicateURI  `foaf:knows'.

- Embedding XML  as a shorter syntax for XML literals
	foo s:comment   '<em>Don't try this at home</em>'


What do people think?  The SPARQL design seems to have been to just  
use up the language space with no  thought for the future expansion.  
Also using up the $sign as a synonym for ?.


> The other SPARQL issue to consider is the allowed
> characters in prefixed names.  SPARQL has slightly
> different rules that allow numbers and '.'s in different
> places.
> See
>  Turtle - Terse RDF Triple Language 20 November 2007
>  http://www.dajobe.org/2004/01/turtle/
> All changes:
>  http://www.dajobe.org/2004/01/turtle/#sec-changelog
> Dave
Received on Monday, 26 November 2007 01:05:06 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:01:05 UTC