W3C home > Mailing lists > Public > public-cwm-talk@w3.org > January to March 2009

Re: n3 grammar : ambiguity for integer and decimal

From: Tim Berners-Lee <timbl@w3.org>
Date: Fri, 20 Feb 2009 15:40:41 -0800
Cc: cwm talk <public-cwm-talk@w3.org>, DIG group <diggers@csail.mit.edu>, Yosi Scharf <syosi@mit.edu>
Message-Id: <C82A09DD-459D-49B1-8954-FC470383CB15@w3.org>
To: luc peuvrier at home <lc.pvrr@orange.fr>
Luc, thanks for spotting that.

It seems to make sense.  I have checked it in as the new n3.n3


Tim

On 2009-02 -12, at 18:26, luc peuvrier at home wrote:

> Hi,
>
> Looking for integer and decimal non terminal ( token ) definition on  
> following n3 grammar specification:
> http://www..w3.org/2000/10/swap/grammar/n3-report.html
>
> and
>
> http://www.w3.org/2000/10/swap/grammar/n3.n3
>
> The ebnf definition for integer and decimal are:
>
> integer : [-+]?[0-9]+
>
> decimal : [-+]?[0-9]+(\.[0-9])?
>
> There is an ambiguity since "123" ( for example ) match integer and  
> decimal
>
> I propose
> decimal : [-+]?[0-9]+\.[0-9]*
>
> Width the above definition "123" match only integer, "123." match  
> decimal. This look like C and Java standard for numéric constants
>
> Best regards
> Luc Peuvrier
Received on Saturday, 21 February 2009 16:12:29 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Saturday, 21 February 2009 16:12:31 GMT