module version query syntax
Alex Buckley
Alex.Buckley at Sun.COM
Mon Mar 2 13:56:20 PST 2009
Mark Reinhold wrote:
>> Date: Mon, 02 Mar 2009 11:46:51 -0800
>> From: jonathan.gibbons at sun.com
>
>> The syntax for module version queries includes support for ranges
>> introduced by '(' and '[', but doesn't allow ',', so you can't write
>> requires M@[1,2)
>> without quoting the stuff after the @.
>>
>> Is this intentional?
>
> No, I doubt it. Looks like a bug.
If comma is allowed in the token after the @, then comma cannot also be
used to separate module identities. In that case, a 'requires' clause
could only take one module identity, a la 'import'. This may be a good
thing.
Semicolon is harder, since its role as end-of-statement is so well
known. Dropping that to allow semicolons in version ranges, e.g. 1-3;5
to exclude v4, looks undesirable to me.
I have not received any EG feedback in this area, and will bring up the
dual meaning of comma+semicolon soon.
Alex
More information about the jigsaw-dev
mailing list