Hi people,
I just merged my first change to the syntax of the language! \o/
Anyway, this is about the import namespaces I added some time ago which worked like this:
import "[namespace:]some-import" "version";
But Gavin suggested that it would be nicer to make the namespace part of the syntax of the language. So I decided on the following:
import [namespace:]some.import "version";
import [namespace:]"some-import" "version";
The immediate recognizable difference is that the namespace can now be used in both forms of the import, the quoted and unquoted ones, but also that the typechecker knows about the prefix and can validate that the namespace is just a plain identifier (no spaces, special characters, etc).
But a very nice advantage of this change is that no old-style Maven imports can be ambiguous anymore! Before an import like:
import "junit:junit" "1.2.3";
could be misinterpreted as an import of module "junit" for the namespace "junit" requiring you to fix the import by adding the "maven:" prefix, but not anymore! The prefix is still preferred though, so if you use the above import you'll get a warning telling you to change it to:
import maven:"junit:junit" "1.2.3";