Compiling Java 9
Alex Buckley
alex.buckley at oracle.com
Wed Nov 16 22:57:28 UTC 2016
On 11/16/2016 2:26 PM, Stephan Herrmann wrote:
> And we may safely assume regularity of the grammar, i.e.,
> the above approach will never lead to ambiguities, right?
>
> Fictitious counter example
>
> ModuleDeclaration:
> module open Identifier ModuleBody;
> module Identifier ModuleBody;
>
> With this the second token could be keyword or identifier, and we're
> stuck, aren't we?
>
> May we assume that the grammar will not be extended in such ambiguous ways?
There is already a production like this:
ModuleStatement:
requires transitive ModuleName ;
requires ModuleName ;
Alex
More information about the jigsaw-dev
mailing list