questions on PhanTango 'merger' - long-term vision

Aarti_pl aarti at interia.pl
Wed Oct 10 08:09:49 PDT 2007


Reply to Lars Ivar Igesund:

-----------

I decided to skip discussion before, as it seems you misinterpreted a 
little bit my intentions.

I am all for merging libraries, and just thinking about the best way to 
do it.

 From earlier discussions it seems that:
1. Runtime will be merged.
2. Other fundamental incompatibilities will be ironed out: 
Exception/Error, toString/toUtf8

That's ok.

After that point it will be possible to write programs, which will work 
on same runtime and use Tango as normal extension library.

But IMHO there will be still somewhat strange situation where 2 
libraries will pretend to be kind of standard. That will be not so bad 
as situation which we have currently. But with some coordination between 
Tango and Phobos it is possible to transform such a situation into real 
advantage.

Basically I am saying following:
1. Both libraries should be packed together with compiler (e.g. DMD). 
 From user point of view it will be one standard library logically 
divided into 2 parts.

2. They will still live in their own namespaces: Phobos = std, Tango = 
tango.

3. As I said in previous posts:

- Phobos should do lower level stuff. Functionalities in Phobos
which belongs to second group should be dropped from it. Library 
characteristics: for lower level stuff, which should be fast, simple, 
small, easy to learn and use. Possible applications: embedded devices, 
quick hacks, scripting, game's engines, kernel programming etc. Style of 
library: free functions, simple classes, consts...

- Tango should do higher level stuff. Functionalities in Tango which 
belongs to first group should be dropped (transferred to Phobos) from 
it. Library characterisctics: for higher level stuff, which gives 
flexibility, encapsulation and easy way to work in big teams. Possible 
applications: desktop programs, advanced networking, distributed 
computing etc. Style of library: classes, inheritance, interfaces...

- It is not necessary that Tango will relay on Phobos functionality, but 
it should be possible to make such dependencies.

- There will be probably overlapping *functionality* (not same 
classes/functions!) in both libraries. I am thinking e.g. about issue 
with writef and Cout - in this case I think both ways of doing output 
have strong supporters.

4. It seems that Phobos will also "live forever", so alternative is that 
  you will have whole Tango, and whole Phobos side by side, while it 
would be much better to have both libraries profiled a little bit. If 
such profiling will not happen, duplication of code will be much bigger, 
as anyone using Tango will be able also to use high-level stuff from 
Phobos, which probably is also in Tango.

I hope it clears my opinion a little bit. These are just few thoughts. 
That said I think it could be quite difficult to coordinate such a big 
projects as Tango and Phobos. But for sure it would be better for users...

Best Regards
Marcin Kuszczak
(aarti_pl - www.zapytajmnie.com)



More information about the Digitalmars-d mailing list