The great compromise of the D standard library
Mikola Lysenko
mclysenk at mtu.edu
Thu Oct 18 13:41:55 PDT 2007
Sean Kelly Wrote:
> Ender KaShae wrote:
> > I have great misgivings over the divide among the D community between standard libriraries. The contintion will no doubt eventually lead to a schism reduce the reusibility of D code. I suggest the following compromise:
> >
> > 1.) Phobos and Tango are combined into a single Standard library, as Phobos seems to be lower level, it would make sense for Tango to call Phobos functions and for alias's to be made between equivilent entities that exist in both libraries
>
> I'll leave the remaining points to others, but I believe this assessment
> is incorrect. One could argue that Tango scales higher than Phobos, but
> both are equivalent in terms of low-level coverage. The design is
> merely different.
>
>
> Sean
I'd even go so far as to say that at the very lowest level, Tango is the decisive winner. Any project involving either threads or networking should stay away from Phobos. There are still all kinds of outstanding bugs from *years* ago, including crowd favorites such as issue 318:
http://d.puremagic.com/issues/show_bug.cgi?id=318
As if the bugs weren't enough, the implementation of Phobos' Threads is also much slower. Simple things like Thread.getThis are O(n) in Phobos and O(1) in Tango. It is also missing features like thread local storage and Fibers. Ultimately switching Tango to Phobos' core would be a big step backwards.
-Mik
More information about the Digitalmars-d
mailing list