Forum Navigation
questions about module names and D 2.0 compatibility
Posted: 09/17/07 17:48:50Hi,
I have two questions regarding tango:
First, one of the confusing aspects of Tango is the module names all being the same or similar to the class names contained within the file. For example, the Conduit class is not tango.io.Conduit, but tango.io.Conduit.Conduit. I sort of understand the reasoning behind doing it this way, because D only allows you one file per module declaration, but has there been any effort to either:
- Change the way D imports modules (preferred)
- Come up with module names that are not the same as class names
The reason I bring this up is because it is especially confusing to java developers. i.e.:
import tango.io.Conduit;
Conduit x = ...;
A Java developer looks at this and says "I imported the *class* tango.io.Conduit", when in fact, they are loading a header file that describes the class tango.io.Conduit.Conduit.
The point really becomes confusing in instances such as tango.text.convert.Integer:
import Integer = tango.text.convert.Integer;
Second question, I know that tango has avoided being compatible with D 2.0 because it is a changing beast. However, are the changes so vast that tango cannot keep up with them? I would like to try out some of the changes in the language that are ongoing (const comes immediately to mind), but as a tango user, I am stuck with D 1.0 until D 2.0 is released. My question is simply, is it a principle thing, where you don't want to base a library on an unreleased language, or is it a effort thing, where it would be too much effort to change all the tango code, and therefore not worth it since D 2.0 is changing? I seem to recall reading that phobos had little or no changes when porting to D 2.0...
-Steve