From: Saašha Metsärantala
Sent: Thursday, May 05, 2011 10:57 AM
To: [log in to unmask]
Subject: Re: [DATETIME] Some comments about the BNF
>  Question marks
> > > If there is a semantic difference between
> > > 2011?-04
> > > on the one hand and
> > > (2011)?-04
> > The first is not intended to be valid.
> I think that the BNF would be more consistent and easier to write if we
> consider the SECOND as non-valid. My suggestion is not counter-
> intuitive at all: If a question mark comes directly after a year, it is
> quite obvious that the question mark refers to the year and I consider
> we do not need parentheses for that.
I'm not sure. If it comes directly after a year, as in 2011?-04 then it is obvious. That's because the year is the first part of the string so with nothing before it there can be ambiguity.
What if it comes directly after a month as in
For (1) Would you say:
(a) it applies to the year-month combination, because the rule is that if it is at the end of the string it applies to the whole string; or
(b) it applies to the month because it directly follows the month
For (2) would you say:
(a) it applies to the year-month combination, because it should apply to the portion of the string preceding it; or
(b) it applies to the month because it directly follows the month.
And what about 2011-04-01?
I'm sure we can craft rules, but I think those rules would be more complicated than saying:
- if it is at the end and there are no parenthesis, it applies to the whole string.
- if it applies to only part of the string, that part is enclosed in parenthesis.
I'll get to the rest of the question mark comments later.