Imports with versions

bearophile bearophileHUGS at lycos.com
Mon Oct 29 17:51:05 PDT 2012


There are some updated on the Java-like language Ceylon:

http://ceylon-lang.org/blog/2012/10/29/ceylon-m4-analytical-engine/


One of the features of Ceylon that seems interesting are the 
module imports:

http://ceylon-lang.org/documentation/1.0/reference/structure/module/#descriptor


An example:

doc "An example module."
module com.example.foo 1.2.0 {
     import com.example.bar 3.4.1
     import org.example.whizzbang 0.5;
}


I think it helps avoid version troubles.

A possible syntax for D:

import std.random(2.0);
import std.random(2.0+);

Bye,
bearophile


More information about the Digitalmars-d mailing list