Re: D2 port of Tango

2011-12-28 Thread mta`chrono
 Another thing, I got many problems generating documentation.

 $ make doc -f posix.mak 
 ...
 tango/core/RuntimeTraits.d(569): use of typedef is deprecated; use alias 
 instead
 tango/core/RuntimeTraits.d(569): use of typedef is deprecated; use alias 
 instead
 ...

 
 Me too!

I've fixed that. Solution was just to replace typedef with alias on Line
569. Just do `git pull`.


Re: D2 port of Tango

2011-12-27 Thread Jordi Sayol
Al 27/12/11 14:41, En/na mta`chrono ha escrit:
 
 Yes, but phobos is called phobos instead of phobos2. I'll think about
 it ;-).
 
h, phobos for dmd2 is not a fork of phobos for dmd1 ;-)

Another thing, I got many problems generating documentation.

$ make doc -f posix.mak 
...
tango/core/RuntimeTraits.d(569): use of typedef is deprecated; use alias instead
tango/core/RuntimeTraits.d(569): use of typedef is deprecated; use alias instead
...

-- 
Jordi Sayol


Re: D2 port of Tango

2011-12-27 Thread mta`chrono
 
 Ok, so if this tango will be quite different than the original one, is not 
 a good idea to change its name? Just to make it more clear and less 
 confusing. Tango2 is enough, I think.
 

Yes, but phobos is called phobos instead of phobos2. I'll think about
it ;-).


Re: D2 port of Tango

2011-12-27 Thread Jordi Sayol
Al 27/12/11 14:04, En/na mta`chrono ha escrit:
 
 If you start use phobos and tango more intensively, you'll ran into
 different problems.
 
 Consider this: Cannot implicit convert struct timeval to struct timeval.
 Just because there are two definitions, one in druntime and another in
 tango.
 
 Sooner or later you'll get crazy. I'm going to remove everything that's
 already present in druntime.
 

 import std.stdio;
 import tango.io.Stdout;

 void main()
 {
   writeln(hello phobos!);
   Stdout(hello tango!).newline;
 }

 Properly compiles and run.
 So, is it not a good idea to join forces to advance more strongly, since 
 pursued the same goal?

 Best regards,
 
 
 Okay, I've also changed a little bit of tango's original api. People
 might dislike this. But it's a little bit more KISS (Keep it small and
 simple).
 
 tango.utils.container.more.Stack.
 
 Why not just use
 
 tango.container.Stack ?
 
 

Ok, so if this tango will be quite different than the original one, is not a 
good idea to change its name? Just to make it more clear and less 
confusing. Tango2 is enough, I think.

-- 
Jordi Sayol


Re: D2 port of Tango

2011-12-27 Thread mta`chrono
 Al 24/12/11 14:20, En/na mta`chrono ha escrit:

 Unlike SiegeLord's branch I've removed tango's runtime and build on top
 of druntime. This step is inevitable in order to make tango and phobos
 work side by side.
 
 SiegeLord's branch do not need druntime lib to be present on the system when 
 compiling tango-d2, and the resulting libraries can be used together with 
 phobos.

If you start use phobos and tango more intensively, you'll ran into
different problems.

Consider this: Cannot implicit convert struct timeval to struct timeval.
Just because there are two definitions, one in druntime and another in
tango.

Sooner or later you'll get crazy. I'm going to remove everything that's
already present in druntime.

 
 import std.stdio;
 import tango.io.Stdout;
 
 void main()
 {
   writeln(hello phobos!);
   Stdout(hello tango!).newline;
 }
 
 Properly compiles and run.
 So, is it not a good idea to join forces to advance more strongly, since 
 pursued the same goal?
 
 Best regards,


Okay, I've also changed a little bit of tango's original api. People
might dislike this. But it's a little bit more KISS (Keep it small and
simple).

tango.utils.container.more.Stack.

Why not just use

tango.container.Stack ?



Re: D2 port of Tango

2011-12-27 Thread Epíleg
Al 27/12/11 14:54, En/na Jordi Sayol ha escrit:
 Al 27/12/11 14:41, En/na mta`chrono ha escrit:

 Yes, but phobos is called phobos instead of phobos2. I'll think about
 it ;-).

 h, phobos for dmd2 is not a fork of phobos for dmd1 ;-)
 
 Another thing, I got many problems generating documentation.
 
 $ make doc -f posix.mak 
 ...
 tango/core/RuntimeTraits.d(569): use of typedef is deprecated; use alias 
 instead
 tango/core/RuntimeTraits.d(569): use of typedef is deprecated; use alias 
 instead
 ...
 

Me too!
-- 
Epíleg



Re: D2 port of Tango

2011-12-26 Thread Jordi Sayol
Al 25/12/11 18:17, En/na Damian Ziemba ha escrit:
 
 They got 2 different goals. SiegeLord wants to keep as much of original Tango 
 as possible and make it D2-wish while mt'chrono changes Tango itself, because 
 he thinks something is wrong-designed (or he doesn't get idea properly). 
 tango.net.* for example. That's all, that's why there are 2 branches.

Thanks for your comment.
Then, if mt'chrono change Tango itself, isn't a good ide to change a bit its 
name? as Tango2 or whatever, just to be more distinguishable from SiegeLord's 
branch.

 
 And SiegeLord's branch *IS* built on top of druntime. Extra features that 
 Tango runtime had, are inside version blocks, so you may want use them also 
 :) But out of box it works with druntime without any additional steps.
 

I'm sure you're right but, I just say that SiegeLord's branch do not need 
druntime.a library present on a Linux system to be compiled, and mt'chrono's 
branch yes.

Best regards,
-- 
Jordi Sayol



smime.p7s
Description: S/MIME Cryptographic Signature


Re: D2 port of Tango

2011-12-26 Thread Jacob Carlborg

On 2011-12-26 15:54, Jordi Sayol wrote:

Al 25/12/11 18:17, En/na Damian Ziemba ha escrit:


They got 2 different goals. SiegeLord wants to keep as much of original Tango 
as possible and make it D2-wish while mt'chrono changes Tango itself, because 
he thinks something is wrong-designed (or he doesn't get idea properly). 
tango.net.* for example. That's all, that's why there are 2 branches.


Thanks for your comment.
Then, if mt'chrono change Tango itself, isn't a good ide to change a bit its 
name? as Tango2 or whatever, just to be more distinguishable from SiegeLord's 
branch.



And SiegeLord's branch *IS* built on top of druntime. Extra features that Tango 
runtime had, are inside version blocks, so you may want use them also :) But 
out of box it works with druntime without any additional steps.



I'm sure you're right but, I just say that SiegeLord's branch do not need 
druntime.a library present on a Linux system to be compiled, and mt'chrono's 
branch yes.

Best regards,


I got linker errors on Mac OS X when I did link with druntime.

--
/Jacob Carlborg


Re: D2 port of Tango

2011-12-25 Thread Damian Ziemba

On Saturday, 24 December 2011 at 22:15:59 UTC, Jordi Sayol wrote:

Al 24/12/11 14:20, En/na mta`chrono ha escrit:


Unlike SiegeLord's branch I've removed tango's runtime and 
build on top
of druntime. This step is inevitable in order to make tango 
and phobos

work side by side.


SiegeLord's branch do not need druntime lib to be present on 
the system when compiling tango-d2, and the resulting libraries 
can be used together with phobos.


import std.stdio;
import tango.io.Stdout;

void main()
{
writeln(hello phobos!);
Stdout(hello tango!).newline;
}

Properly compiles and run.
So, is it not a good idea to join forces to advance more 
strongly, since pursued the same goal?


Best regards,


They got 2 different goals. SiegeLord wants to keep as much of 
original Tango as possible and make it D2-wish while mt'chrono 
changes Tango itself, because he thinks something is 
wrong-designed (or he doesn't get idea properly). tango.net.* for 
example. That's all, that's why there are 2 branches.


And SiegeLord's branch *IS* built on top of druntime. Extra 
features that Tango runtime had, are inside version blocks, so 
you may want use them also :) But out of box it works with 
druntime without any additional steps.





Re: D2 port of Tango

2011-12-24 Thread Jordi Sayol
Al 24/12/11 01:39, En/na mta`chrono ha escrit:
 I'm using dmd 2.058 and `make -f posix.mak` to compile it. Can you
 please tell me your errors?
 
 - mta`chrono
 

$ make -f posix.mak
make MODEL=32 BUILD=release --no-print-directory -f posix.mak
dmd -c -m32 -I../druntime/import -w -d -m32 -O -release -nofloat 
-ofgenerated/release/32/tango/util/log/AppendSocket.o 
tango/util/log/AppendSocket.d
tango/net/Address.d(18): Error: module un is in file 'core/sys/posix/sys/un.d' 
which cannot be read
import path[0] = ../druntime/import
import path[1] = /usr/include/d/dmd/phobos
import path[2] = /usr/include/d/dmd/druntime/import
make[1]: *** [generated/release/32/tango/util/log/AppendSocket.o] Error 1
make: *** [release] Error 2

same result with:
$ make -f posix.mak MODEL=64
-- 
Jordi Sayol



smime.p7s
Description: S/MIME Cryptographic Signature


Re: D2 port of Tango

2011-12-24 Thread mta`chrono
Hey Jordi,

thank you for posting your results!!! :-)

It tries to read core.sys.posix.sys.un which is part of druntime.

Unlike SiegeLord's branch I've removed tango's runtime and build on top
of druntime. This step is inevitable in order to make tango and phobos
work side by side.

The file that cannot be read on your system is definitivly there.
https://github.com/D-Programming-Language/druntime/blob/master/src/core/sys/posix/sys/un.d

You just need to checkout druntime, phobos and tango and put them in
some kind of following file structure.

/usr/include/d/dmd/druntime
/usr/include/d/dmd/tango
/usr/include/d/dmd/phobos

Then compile druntime, phobos and tango.


- mta`chrono


Re: D2 port of Tango

2011-12-24 Thread Jordi Sayol
Al 24/12/11 14:20, En/na mta`chrono ha escrit:
 Hey Jordi,
 
 thank you for posting your results!!! :-)
 
 It tries to read core.sys.posix.sys.un which is part of druntime.

Yes, but it is not present on dmd.2.057.zip

 
 Unlike SiegeLord's branch I've removed tango's runtime and build on top
 of druntime. This step is inevitable in order to make tango and phobos
 work side by side.

hmmm, SiegeLord's branch works together with phobos too.

 
 The file that cannot be read on your system is definitivly there.
 https://github.com/D-Programming-Language/druntime/blob/master/src/core/sys/posix/sys/un.d
 
 You just need to checkout druntime, phobos and tango and put them in
 some kind of following file structure.
 
 /usr/include/d/dmd/druntime
 /usr/include/d/dmd/tango
 /usr/include/d/dmd/phobos
 
 Then compile druntime, phobos and tango.
 

After checkout, it properly compiles your branch of tango! many thanks!

Here is a link to a deb file containing your tango branch.

https://d-packages.googlecode.com/files/libtango-dev_1.99%7E2011.12.23-0_all.deb

It includes both 32 and 64-bit libraries, the modules, and the pkg-config 
configuration file for an easy compiling:
$ dmd `pkg-config --cflags --libs tango` myapp.d

As it was compiled with dmd 2.058 and there is not deb package for this version 
yet, this tango deb package has no  any dmd dependency (enough just for 
testing).

Now I've many problems generating documentation.
$ make doc -f posix.mak 
dmd -o- -version=TangoDoc -Dfdoc/html/tango/core/Array.html tango/core/Array.d
dmd -o- -version=TangoDoc -Dfdoc/html/tango/core/BitArray.html 
tango/core/BitArray.d
dmd -o- -version=TangoDoc -Dfdoc/html/tango/core/ByteSwap.html 
tango/core/ByteSwap.d
dmd -o- -version=TangoDoc -Dfdoc/html/tango/core/Exception.html 
tango/core/Exception.d
dmd -o- -version=TangoDoc -Dfdoc/html/tango/core/RuntimeTraits.html 
tango/core/RuntimeTraits.d
tango/core/RuntimeTraits.d(569): use of typedef is deprecated; use alias instead
tango/core/RuntimeTraits.d(569): use of typedef is deprecated; use alias instead
make: *** [doc/html/tango/core/RuntimeTraits.html] Error 1

Best regards,
-- 
Jordi Sayol




smime.p7s
Description: S/MIME Cryptographic Signature


Re: D2 port of Tango

2011-12-24 Thread Jordi Sayol
Al 24/12/11 14:20, En/na mta`chrono ha escrit:
 
 Unlike SiegeLord's branch I've removed tango's runtime and build on top
 of druntime. This step is inevitable in order to make tango and phobos
 work side by side.

SiegeLord's branch do not need druntime lib to be present on the system when 
compiling tango-d2, and the resulting libraries can be used together with 
phobos.

import std.stdio;
import tango.io.Stdout;

void main()
{
  writeln(hello phobos!);
  Stdout(hello tango!).newline;
}

Properly compiles and run.
So, is it not a good idea to join forces to advance more strongly, since 
pursued the same goal?

Best regards,
-- 
Jordi Sayol



smime.p7s
Description: S/MIME Cryptographic Signature


Re: D2 port of Tango

2011-12-23 Thread Jordi Sayol
Al 18/10/11 06:52, En/na SiegeLord ha escrit:
 I just wanted to get the word out about a little project me and a few other 
 people been working on for the few past months, in case anyone feels like 
 helping out (or just as an FYI). This project is the D2 port of the Tango 
 framework library. You can read about it here:
 
 https://github.com/SiegeLord/Tango-D2
 
 We are currently a little more than half way done in terms of modules fiddled 
 with. Currently there are 181 modules ported out of approximately 343 (give 
 or take 20). Currently only the dmd compiler and Linux platform are 
 supported... but obviously we want to get all the other platforms/compilers 
 as time goes on. I'm guessing at the current rate of porting we'll be done in 
 about half a year.
 
 Now, the project is actually two projects in one.
 
 The first project is a D2 port proper that tries to keep API semantics the 
 same as the D1 original. I preside over this aspect, and you can see the 
 rough porting guidelines in the repository. This is the 'd2port' branch in my 
 repository.
 
 The second project is a more ambitious effort to rewrite some aspects of 
 Tango without preserving semantics or anything. mtachrono presides over this 
 aspect, so you can talk to him about the motivations behind it. This is the 
 'master' branch in my repository.
 
 That's all. Cheers.
 
 -SiegeLord
 

Hello,

I've created two tango-d2 deb packages for debian like systems.

https://d-packages.googlecode.com/files/libtango-dev_1.99%7E2011.12.17-0_all.deb
https://d-packages.googlecode.com/files/libtango-doc_1.99%7E2011.12.17-0_all.deb

The first one includes the library (both, 32 and 64 bit, so it is not arch 
dependent), the source modules, and the pkg-config configuration file for an 
easy compilation:

$ dmd `pkg-config --cflags --libs tango` myapp.d

It depends on dmd 2.057 and newer.

The second one includes the html documentation generated with CandyDoc, and a 
shortcut to it at the system menu.
Also it includes the examples.

Best regards,
-- 
Jordi Sayol



smime.p7s
Description: S/MIME Cryptographic Signature


Re: D2 port of Tango

2011-12-23 Thread mta`chrono
Hey,

that's cool. How did you create it? I'd like to create a .deb for my
tango branch, too.

https://github.com/mtachrono/tango

- mta`chrono



Re: D2 port of Tango

2011-12-23 Thread Jordi Sayol
Al 23/12/11 21:38, En/na mta`chrono ha escrit:
 Hey,
 
 that's cool. How did you create it? I'd like to create a .deb for my
 tango branch, too.
 
 https://github.com/mtachrono/tango
 
 - mta`chrono
 
 

I manually created them with debhelper.

I'm getting errors compiling your branch with dmd 2.057

Regards,
-- 
Jordi Sayol



smime.p7s
Description: S/MIME Cryptographic Signature


Re: D2 port of Tango

2011-12-23 Thread mta`chrono
I'm using dmd 2.058 and `make -f posix.mak` to compile it. Can you
please tell me your errors?

- mta`chrono


Re: D2 port of Tango

2011-11-06 Thread mta`chrono
 No he said he was surprised Tango reallocated without him knowing
 about it. If this is actually documented behavior, then that could be
 ok.

I think this behavoir should be changed in tango d2. if you pass a
buffer then it should be used or not (if it's not big enough for any
reason). but no hidden memory allocation.


Re: D2 port of Tango

2011-11-06 Thread mta`chrono
 You will never satisfy both worlds (simplicity vs flexibility). Both
 Phobos and Tango have their place in the D community. It is unfortunate
 many people in the D community fails to see it. Also, it is unfortunate
 (but very easy to explain) that Tango project started as a complete
 implementation of the run-time library. We debate this for years on
 irc://
 irc.freenode.org/d and it never ends.

Tango d2 should give up it's own runtime and consequently use druntime,
even though this is an immense change that nearly affects everything to
change.

Nobody will be able to maintain two runtime's at the same time. You'll
have to be aware of so many stuff. Even if you provide a method that the
user can choose between tango's runtime and druntime, you will have to
mess around with duplicate declarations etc. In one module you're using
tango's struct sockaddr declaration and in the other you'll try to pass
it to a functions that requires druntime's struct sockaddr. the compiler
will complain that you cannot pass sockaddr where sockaddr is required.

So please give up tango's runtime and make a consequent use of druntime.
If someone want's to customize the behavoir of the gc for example than
he should use druntime's possibilities to change it.


Re: D2 port of Tango

2011-11-06 Thread Jacob Carlborg

On 2011-11-06 12:43, mta`chrono wrote:

You will never satisfy both worlds (simplicity vs flexibility). Both
Phobos and Tango have their place in the D community. It is unfortunate
many people in the D community fails to see it. Also, it is unfortunate
(but very easy to explain) that Tango project started as a complete
implementation of the run-time library. We debate this for years on
irc://
irc.freenode.org/d and it never ends.


Tango d2 should give up it's own runtime and consequently use druntime,
even though this is an immense change that nearly affects everything to
change.

Nobody will be able to maintain two runtime's at the same time. You'll
have to be aware of so many stuff. Even if you provide a method that the
user can choose between tango's runtime and druntime, you will have to
mess around with duplicate declarations etc. In one module you're using
tango's struct sockaddr declaration and in the other you'll try to pass
it to a functions that requires druntime's struct sockaddr. the compiler
will complain that you cannot pass sockaddr where sockaddr is required.

So please give up tango's runtime and make a consequent use of druntime.
If someone want's to customize the behavoir of the gc for example than
he should use druntime's possibilities to change it.


As far as I know, the D2 port of Tango uses druntime.

--
/Jacob Carlborg


Re: D2 port of Tango

2011-11-06 Thread Jacob Carlborg

On 2011-11-04 20:11, Andrej Mitrovic wrote:

On 11/4/11, Jacob Carlborgd...@me.com  wrote:

Since most functions in Phobos don't accept a buffer parameter it would
always need to allocate. How is that better?


No he said he was surprised Tango reallocated without him knowing
about it. If this is actually documented behavior, then that could be
ok.


Many functions in Tango mention in the documentation if it allocates. If 
you know the concept of how buffers are used then you know it could 
allocate.


--
/Jacob Carlborg


Re: D2 port of Tango

2011-11-05 Thread zsxxsz
== Quote from Damian Ziemba (nazr...@driv.pl)'s article
 On Tue, 18 Oct 2011 20:27:40 +0300, Denis Shelomovskij wrote:
  +1 to Caligo. I agree that Tango is a good library (and was the best one
  for D1) but, IMHO, porting it to D2 is a bad idea.
  I'm the one who has a big D1+Tango project and I'd better rewrite it
  with D2+Phobos, because:
 
   0. I don't want to have a two standard libraries problem with D2
  (which one to select?).
 
 You don't have to. You can use Tango and Phobos together.
 You can also use some selected modules :) For example in one of my
 projects I use cipher and digest modules from Tango and rest is Phobos.
   1. Phobos has a better design (Tango is too complicated in some
  places, has a lot of things I (and a regular programmer IMHO) don't use,
  and has bad design decisions sometimes - both internal and user API)
 
 I totally disagree :) Show me example of such bad decision.
   2. Phobos has less _critical bugs_ because of better code control
  (e.g. Tango has memory corruption bug for a very long time in Vector
  container (#2064)).
 
 Tickets and Patches are always welcome :)
   3. There is no Andrei Alexandrescu clone to generate that perfect
  ideas for Tango.
 This one made me rotfl in real :D Haha. Tango had some best developers in
 D community including h3r3tic, Kris, Fawzi, Sean and so on, so on :)

I don't like Phobos design, which takes all libs in the same path looking so
urgly, but tango seperate libs in different path according to its function 
using,
so I like tango's design.


Re: D2 port of Tango

2011-11-05 Thread Dejan Lekic
On Sat, 05 Nov 2011 14:50:09 +, zsxxsz wrote:

 
 I don't like Phobos design, which takes all libs in the same path
 looking so urgly, but tango seperate libs in different path according to
 its function using,
 so I like tango's design.

You will never satisfy both worlds (simplicity vs flexibility). Both 
Phobos and Tango have their place in the D community. It is unfortunate 
many people in the D community fails to see it. Also, it is unfortunate 
(but very easy to explain) that Tango project started as a complete 
implementation of the run-time library. We debate this for years on irc://
irc.freenode.org/d and it never ends. I belong to the group that like the 
way Phobos does things, but unlike some people I think Tango is a 
brilliant, high-level library. I wish we had druntime when Tango project 
started, but nothing is lost, I believe Tango2 project will fit nicely on 
top of druntime, and live long and prosperous life.

The reason why I also like Tango (even though I never used it in anything 
serious) is that it reminds me a lot of Java API which is robust, reach 
and intuitive. Tango IO is very similar to Java NIO...


Re: D2 port of Tango

2011-11-05 Thread Charles Hixson

On 11/05/2011 10:56 AM, Dejan Lekic wrote:

On Sat, 05 Nov 2011 14:50:09 +, zsxxsz wrote:



I don't like Phobos design, which takes all libs in the same path
looking so urgly, but tango seperate libs in different path according to
its function using,
so I like tango's design.


You will never satisfy both worlds (simplicity vs flexibility). Both
Phobos and Tango have their place in the D community. It is unfortunate
many people in the D community fails to see it. Also, it is unfortunate
(but very easy to explain) that Tango project started as a complete
implementation of the run-time library. We debate this for years on irc://
irc.freenode.org/d and it never ends. I belong to the group that like the
way Phobos does things, but unlike some people I think Tango is a
brilliant, high-level library. I wish we had druntime when Tango project
started, but nothing is lost, I believe Tango2 project will fit nicely on
top of druntime, and live long and prosperous life.

The reason why I also like Tango (even though I never used it in anything
serious) is that it reminds me a lot of Java API which is robust, reach
and intuitive. Tango IO is very similar to Java NIO...


If Tango is compatible with Phobos, then I don't mind it.  I'm not real 
tight on either disk space or RAM.  The prior version, however, required 
that Phobos be removed to install, so you could either use Tango 
libraries *OR* Phobos libraries.  And Tango was often broken, where 
Phobos usually worked.  This divided the community, and gifted us with 
REAMS of non-usable projects.


So I'm just a bit skittish when I hear the name Tango these days. 
(Perhaps it worked better on MSWind platforms.  But it still divided a 
community that was already smaller than optimal.)




Re: D2 port of Tango

2011-11-04 Thread Jacob Carlborg

On 2011-11-03 16:01, Andrej Mitrovic wrote:

On 11/3/11, Denis Shelomovskijverylonglogin@gmail.com  wrote:

* the worst case, if you provide a large enough buffer, you are (I was)
completely sure Tango will use it (you want to do a manual memory
management by some reason), *but* it will reallocate a new one from GC
if it just don't like yours



That sounds really weird. So it takes your array buffer as a ref
argument and resizes it / reallocates it if it's not big enough? I've
never used Tango so I don't quite understand how it works. If I pass a
static array or its slice of it, it can't do much except maybe throw
an exception if it's not big enough. Hidden memory allocations are
superbad!


Since most functions in Phobos don't accept a buffer parameter it would 
always need to allocate. How is that better? Or are you meaning that 
then you know it will always allocate.


Don't know what happens if a static array is not big enough.

--
/Jacob Carlborg


Re: D2 port of Tango

2011-11-04 Thread Andrej Mitrovic
On 11/4/11, Jacob Carlborg d...@me.com wrote:
 Since most functions in Phobos don't accept a buffer parameter it would
 always need to allocate. How is that better?

No he said he was surprised Tango reallocated without him knowing
about it. If this is actually documented behavior, then that could be
ok.


Re: D2 port of Tango

2011-11-03 Thread Denis Shelomovskij

03.11.2011 1:29, Damian Ziemba пишет:

1. Phobos has a better design (Tango is too complicated in some
  places, has a lot of things I (and a regular programmer IMHO) don't use,
  and has bad design decisions sometimes - both internal and user API)


I totally disagree:)  Show me example of such bad decision.



Tango often asks you a buffer (e.g. at tango.text.Unicode, 
tango.text.convert.Utf) that is not needed in a language with GC. But it 
isn't a main problem. Let's consider the cases:
* if you don't provide a buffer it will manually allocate an array 
instead of using an Appender and than reallocate it etc.
* the worst case, if you provide a large enough buffer, you are (I was) 
completely sure Tango will use it (you whant to do a manual memory 
management by some reason), *but* it will reallocate a new one from GC 
if it just don't like yours (if yourBuffer.length - minimalNeededLength 
 tangoSacredAdditionLength, and addition length it often nonzero, so 
Tango will not like your exactly enough buffer).


Re: D2 port of Tango

2011-11-03 Thread Andrej Mitrovic
On 11/3/11, Denis Shelomovskij verylonglogin@gmail.com wrote:
 * the worst case, if you provide a large enough buffer, you are (I was)
 completely sure Tango will use it (you want to do a manual memory
 management by some reason), *but* it will reallocate a new one from GC
 if it just don't like yours


That sounds really weird. So it takes your array buffer as a ref
argument and resizes it / reallocates it if it's not big enough? I've
never used Tango so I don't quite understand how it works. If I pass a
static array or its slice of it, it can't do much except maybe throw
an exception if it's not big enough. Hidden memory allocations are
superbad!


Re: D2 port of Tango

2011-11-03 Thread Timon Gehr

On 11/03/2011 02:55 PM, Trass3r wrote:

Am 03.11.2011, 00:46 Uhr, schrieb mta`chrono
chr...@mta-international.net:


Yesterday I managed to compile all ported modules on Windows.
So it looks like Tango for D2 should work on Linux and Windows right
now.


SiegeLord has created a master branch. I've deleted tango.stdc and parts
of tango.sys in my fork. At first, a thousands of errors arose but I
could fix them by using druntime instead. We need to do similar for
windows.


So how far along is this project actually?



Yes, Tango for D2 should make use of druntime and deimos.

Deimos?? Isn't that dead?


Probably he meant this:
https://github.com/D-Programming-Language/deimos

What other project were you referring to?


Re: D2 port of Tango

2011-11-03 Thread Trass3r
Timon Gehr Wrote:
  Yes, Tango for D2 should make use of druntime and deimos.
  Deimos?? Isn't that dead?
 
 Probably he meant this:
 https://github.com/D-Programming-Language/deimos
 
 What other project were you referring to?

http://www.dsource.org/projects/deimos of course ;)


Re: D2 port of Tango

2011-11-03 Thread Sean Kelly
On Nov 3, 2011, at 9:06 AM, Timon Gehr wrote:

 On 11/03/2011 02:55 PM, Trass3r wrote:
 
 
 Yes, Tango for D2 should make use of druntime and deimos.
 Deimos?? Isn't that dead?
 
 Probably he meant this:
 https://github.com/D-Programming-Language/deimos
 
 What other project were you referring to?

There's an old dead project on source named deimos.  As a bit of trivia, Tango 
would probably have been named deimos if dsource/deimos hadn't existed.



Re: D2 port of Tango

2011-11-02 Thread Damian Ziemba
Yesterday I managed to compile all ported modules on Windows.
So it looks like Tango for D2 should work on Linux and Windows right now.

Lots of people are missing the point of whole project.

Tango for D2 uses Druntime so it is quite normal to use Phobos and Tango 
together :)

Giving users a choice is great thing in my opinion. Not everyone likes 
the Phobos philosophy or its design decisions.

Somebody said that Tango hasn't got Andrei on board...
Well, with all respect to Andrei as he is great developer but he is not 
the only one who knows how the things should be done. The whole tango.net 
module is example of great Design :)
Lets say that Phobos has Andrei on board, and Tango has got Kris on 
board ;)

So, resuming, you can use Tango(D2) with Phobos, you do not have to 
sacrifice neither library.

Lots of people sticks with D1 because of Tango... This maybe great step 
for those folks to go with flow, and D2 ;)


Re: D2 port of Tango

2011-11-02 Thread Damian Ziemba
On Tue, 18 Oct 2011 20:27:40 +0300, Denis Shelomovskij wrote:

 +1 to Caligo. I agree that Tango is a good library (and was the best one
 for D1) but, IMHO, porting it to D2 is a bad idea.
 I'm the one who has a big D1+Tango project and I'd better rewrite it
 with D2+Phobos, because:
 
  0. I don't want to have a two standard libraries problem with D2
 (which one to select?).
 
You don't have to. You can use Tango and Phobos together.
You can also use some selected modules :) For example in one of my 
projects I use cipher and digest modules from Tango and rest is Phobos.

  1. Phobos has a better design (Tango is too complicated in some
 places, has a lot of things I (and a regular programmer IMHO) don't use,
 and has bad design decisions sometimes - both internal and user API)
 

I totally disagree :) Show me example of such bad decision.

  2. Phobos has less _critical bugs_ because of better code control
 (e.g. Tango has memory corruption bug for a very long time in Vector
 container (#2064)).
 

Tickets and Patches are always welcome :)

  3. There is no Andrei Alexandrescu clone to generate that perfect
 ideas for Tango.

This one made me rotfl in real :D Haha. Tango had some best developers in 
D community including h3r3tic, Kris, Fawzi, Sean and so on, so on :)


Re: D2 port of Tango

2011-11-02 Thread mta`chrono
 Yesterday I managed to compile all ported modules on Windows.
 So it looks like Tango for D2 should work on Linux and Windows right now.

SiegeLord has created a master branch. I've deleted tango.stdc and parts
of tango.sys in my fork. At first, a thousands of errors arose but I
could fix them by using druntime instead. We need to do similar for windows.

 Lots of people are missing the point of whole project.
 
 Tango for D2 uses Druntime so it is quite normal to use Phobos and Tango 
 together :)

Yes, Tango for D2 should make use of druntime and deimos. I understand
people are afraid that developing tango will split the community like it
already happend in the past. But since tango and phobos use the same
core, furthur tango developers will even contribute to druntime and deimos.

 Giving users a choice is great thing in my opinion. Not everyone likes 
 the Phobos philosophy or its design decisions.

Yes, though there is some lack of tangos design. It's too complex.
IConduit, Conduit, Device, InputStream, OutputStream, InputFilter,
OutputFilter... I don't understand why they haven't merged Conduit and
Device?!?

 Somebody said that Tango hasn't got Andrei on board...
 Well, with all respect to Andrei as he is great developer but he is not 
 the only one who knows how the things should be done. The whole tango.net 
 module is example of great Design :)
 Lets say that Phobos has Andrei on board, and Tango has got Kris on 
 board ;)

Andrei on board means Andrei!T on board ;-).

 
 So, resuming, you can use Tango(D2) with Phobos, you do not have to 
 sacrifice neither library.
 
 Lots of people sticks with D1 because of Tango... This maybe great step 
 for those folks to go with flow, and D2 ;)



Re: D2 port of Tango

2011-10-26 Thread mta`chrono
the reason I love tango is it's design. tango's approach is very c++
like and since I'm a Qt-Fan, I would flavour a d2 version like this:

tango.io.Device
   +
   +++--+
   vv|  |
tango.net.Socket   tango.io.File |  |
   ++|  |
   |||  v
+---++  | tango.io.ThreadPipe
v   |v  ||
tango.net.TcpSocket | tango.net.UdpSocket|
+   |   ||
|   v   |v
|   tango.net.LocalSocket   | tango.io.BitBucket
v   |
tango.net.SslSocket v
 tango.io.Console



tango should use druntime and work with phobos side by side. this one
works fine.


import std.stdio;
import tango.io.Stdout;

void main()
{
 writeln(hello phobos!);
 Stdout(hello tango!).newline;
}





Re: D2 port of Tango

2011-10-21 Thread Jacob Carlborg

On 2011-10-21 07:00, Kagamin wrote:

Jacob Carlborg Wrote:


Even if one would use Phobos, Tango still have things to offer over
Phobos. For example, support for OpenSSL, cryptographic, a net library
that doesn't depend on external libraries and a better XML library.


Hmm... does phobos offer something over Tango?


No, not really. Well, ZIP support that doesn't depend on external 
libraries and some array operations, e.g. map, filter, reduce and so on. 
Although I see that Tango just got map and filter.


--
/Jacob Carlborg


Re: D2 port of Tango

2011-10-21 Thread Jacob Carlborg

On 2011-10-20 20:16, SiegeLord wrote:

Eric Poggel (JoeCoder) Wrote:



That's what I do now with Tango 1.

But if every library I used required separate installation steps
(instead of just pitting it in the repository), there would be about a
dozen to install. I want to keep things as simple as possible for my users.

My goal is to make it as easy as:

1. Install dmd
2. Checkout Yage from Hg
3. Run the build script


Sorry, I don't mean to sound so demanding.  I greatly appreciate your
work in porting tango to D2.


No offense taken. What you're suggesting seems to me a little outside of the 
scope of Tango specifically. You'd have the same issue with any other 3rd party 
library in D and in many other languages (e.g. C and C++). This sort of thing 
is probably best solved by some cpan/ruby gem type of thing that was discussed 
earlier on the mailing lists (I don't follow them anymore so I've no idea how 
that turned out).


I'm working on that.

https://github.com/jacob-carlborg/orbit/wiki/Orbit-Package-Manager-for-D
https://github.com/jacob-carlborg/orbit


--
/Jacob Carlborg


Re: D2 port of Tango

2011-10-21 Thread Charles Hixson

On 10/20/2011 10:00 PM, Kagamin wrote:

Jacob Carlborg Wrote:


Even if one would use Phobos, Tango still have things to offer over
Phobos. For example, support for OpenSSL, cryptographic, a net library
that doesn't depend on external libraries and a better XML library.


Hmm... does Phobos offer something over Tango?
Even *IF* Phobos didn't offer anything else over Tango, it comes 
standardly installed with D.  Unless Tango offers the EXACT same 
interface, that's enough to cause me to prefer Phobos over Tango.  And 
being feature compatible is quite difficult even when that's your goal.


So it would be extremely preferable if Tango could be installed along 
side of Phobos without interfering with it.  If it can't be, it will 
divide the development community.  Again.  With foreseeable effects in 
an already small community.




Re: D2 port of Tango

2011-10-20 Thread Eric Poggel (JoeCoder)

On 10/18/2011 5:07 PM, SiegeLord wrote:

to use it you'd install the whole thing somewhere on your computer.


That's what I do now with Tango 1.

But if every library I used required separate installation steps 
(instead of just pitting it in the repository), there would be about a 
dozen to install.  I want to keep things as simple as possible for my users.


My goal is to make it as easy as:

1.  Install dmd
2.  Checkout Yage from Hg
3.  Run the build script


Re: D2 port of Tango

2011-10-20 Thread Eric Poggel (JoeCoder)

On 10/20/2011 12:38 PM, Eric Poggel (JoeCoder) wrote:

On 10/18/2011 5:07 PM, SiegeLord wrote:

to use it you'd install the whole thing somewhere on your computer.


That's what I do now with Tango 1.

But if every library I used required separate installation steps
(instead of just pitting it in the repository), there would be about a
dozen to install. I want to keep things as simple as possible for my users.

My goal is to make it as easy as:

1. Install dmd
2. Checkout Yage from Hg
3. Run the build script


Sorry, I don't mean to sound so demanding.  I greatly appreciate your 
work in porting tango to D2.


Re: D2 port of Tango

2011-10-20 Thread SiegeLord
Eric Poggel (JoeCoder) Wrote:

 
  That's what I do now with Tango 1.
 
  But if every library I used required separate installation steps
  (instead of just pitting it in the repository), there would be about a
  dozen to install. I want to keep things as simple as possible for my users.
 
  My goal is to make it as easy as:
 
  1. Install dmd
  2. Checkout Yage from Hg
  3. Run the build script
 
 Sorry, I don't mean to sound so demanding.  I greatly appreciate your 
 work in porting tango to D2.

No offense taken. What you're suggesting seems to me a little outside of the 
scope of Tango specifically. You'd have the same issue with any other 3rd party 
library in D and in many other languages (e.g. C and C++). This sort of thing 
is probably best solved by some cpan/ruby gem type of thing that was discussed 
earlier on the mailing lists (I don't follow them anymore so I've no idea how 
that turned out).

Now, in principle Tango could get special treatment that you suggest... but I 
personally would rather have a framework for all (registered) 3rd party 
libraries.

Also... in principle Tango might one day get a package in some repository 
(bioinformatics suggested that he would take care of it for Fedora once the 
port was complete) so at least it won't be as big of a deal there.

-SiegeLord


Re: D2 port of Tango

2011-10-20 Thread torhu

Great stuff!


Re: D2 port of Tango

2011-10-20 Thread Fawzi Mohamed
I think that having tango for D2 could be useful, but I would be quite 
disappointed if Tango would still not get along with phobos.
I understand that druntime might be quite connected to phobos releases, still 
there should be less reasons this time to fork also the runtime this time.
That was always a pita IMHO, and I am a happy D1/tango user.

Fawzi
On Oct 19, 2011, at 11:12 PM, Andrej Mitrovic wrote:

 On 10/19/11, Nick Sabalausky a@a.a wrote:
 zsxxsz zsx...@63.net wrote in message
 news:j7mmkr$1fm0$1...@digitalmars.com...
 I love Tango, because it's like using JAVA to program with Tango, and using
 
 C++
 to program with Phobos. Java is much more easy to program.
 
 Heh. The Java-ness of it is actually the one thing about Tango that I don't
 really like. 'Course, I'm a big Java-hater anyway, YMMV...
 
 
 Oh what, you don't like
 getterAbstractFactoriesBuilderFactorySingletonObjectListener?



Re: D2 port of Tango

2011-10-20 Thread Kagamin
Jacob Carlborg Wrote:

 Even if one would use Phobos, Tango still have things to offer over 
 Phobos. For example, support for OpenSSL, cryptographic, a net library 
 that doesn't depend on external libraries and a better XML library.

Hmm... does phobos offer something over Tango?


Re: D2 port of Tango

2011-10-19 Thread Jacob Carlborg

On 2011-10-18 20:09, Jonathan M Davis wrote:

On Tuesday, October 18, 2011 10:27 Denis Shelomovskij wrote:

18.10.2011 8:00, Caligo пишет:

On Mon, Oct 17, 2011 at 11:52 PM, SiegeLordn...@none.com

mailto:n...@none.com  wrote:
I just wanted to get the word out about a little project me and a
few other people been working on for the few past months, in case
anyone feels like helping out (or just as an FYI). This project is
the D2 port of the Tango framework library. You can read about it
here:

https://github.com/haskelSiegeLord/Tango-D2
https://github.com/SiegeLord/Tango-D2

We are currently a little more than half way done in terms of
modules fiddled with. Currently there are 181 modules ported out of
approximately 343 (give or take 20). Currently only the dmd compiler
and Linux platform are supported... but obviously we want to get all
the other platforms/compilers as time goes on. I'm guessing at the
current rate of porting we'll be done in about half a year.

Now, the project is actually two projects in one.

The first project is a D2 port proper that tries to keep API
semantics the same as the D1 original. I preside over this aspect,
and you can see the rough porting guidelines in the repository. This
is the 'd2port' branch in my repository.

The second project is a more ambitious effort to rewrite some
aspects of Tango without preserving semantics or anything. mtachrono
presides over this aspect, so you can talk to him about the
motivations behind it. This is the 'master' branch in my repository.

That's all. Cheers.

-SiegeLord

Why? What's the point? Why not work on Phobos instead?


+1 to Caligo. I agree that Tango is a good library (and was the best one
for D1) but, IMHO, porting it to D2 is a bad idea.
I'm the one who has a big D1+Tango project and I'd better rewrite it
with D2+Phobos, because:

0. I don't want to have a two standard libraries problem with D2
(which one to select?).

1. Phobos has a better design (Tango is too complicated in some
places, has a lot of things I (and a regular programmer IMHO) don't use,
and has bad design decisions sometimes - both internal and user API)

2. Phobos has less _critical bugs_ because of better code control
(e.g. Tango has memory corruption bug for a very long time in Vector
container (#2064)).

3. There is no Andrei Alexandrescu clone to generate that perfect
ideas for Tango.


While I would much rather see effort being put into improving Phobos than
Tango, I think that it's a bit rude to claim that the Tango folks should just
throw away all of their Tango work and move all of their projects over to
Phobos. Wanting to be able to easily port D1 programs to D2 is a completely
valid thing to want to do, and while I think that new projects should use
Phobos since it's the standard library, there's nothing wrong with using a
different library if you want to. If SiegeLord and others want to spend time
porting Tango to D2, it's their right to be able to do so. Ostracizing Tango
and its users is just going to make the D2 community poorer. And thanks to
druntime, it's now perfectly possible to mix Phobos and Tango code if you
want to (though the differences in design will likely make that not always
work as well as might be nice), so the situation is not the same as it was
for D1 when Phobos sucked, and it and Tango didn't work together.

- Jonathan M Davis


Even if one would use Phobos, Tango still have things to offer over 
Phobos. For example, support for OpenSSL, cryptographic, a net library 
that doesn't depend on external libraries and a better XML library.


--
/Jacob Carlborg


Re: D2 port of Tango

2011-10-19 Thread zsxxsz
I love Tango, because it's like using JAVA to program with Tango, and using C++
to program with Phobos. Java is much more easy to program.


Re: D2 port of Tango

2011-10-19 Thread Nick Sabalausky
SiegeLord n...@none.com wrote in message 
news:j7kpr8$l58$1...@digitalmars.com...

Then, you can compile the whole thing into a library OR use a tool like 
xfbuild (maybe rdmd too, never had luck with that one) to compile only the 
modules that your program imports.


I've had somewhat opposite experience. I was never able to get xfbuild to 
work with D2, but I've been using rdmd successfully for awhile. That said, 
there *were* some major bugs in the rdmd's from before 2.055/1.070 that 
caused problems on non-trivial projects. But those issues are now fixed, so 
you may want to try it again now.




Re: D2 port of Tango

2011-10-19 Thread Nick Sabalausky
Trass3r u...@known.com wrote in message news:op.v3jlvlcj3ncmek@enigma...
 Why?  What's the point?  Why not work on Phobos instead?

 Well D1 projects could be ported to D2 much more easily, e.g. Yage.

I ported a fair amout of stuff directly from D1/Tango to D2/Phobos about a 
year and a half ago, and it actually went a lot more smoothly than I had 
expected. Of course, Tango on D2 would make the process even easier still.




Re: D2 port of Tango

2011-10-19 Thread Nick Sabalausky
zsxxsz zsx...@63.net wrote in message 
news:j7mmkr$1fm0$1...@digitalmars.com...
I love Tango, because it's like using JAVA to program with Tango, and using 
C++
 to program with Phobos. Java is much more easy to program.

Heh. The Java-ness of it is actually the one thing about Tango that I don't 
really like. 'Course, I'm a big Java-hater anyway, YMMV...




Re: D2 port of Tango

2011-10-19 Thread Andrej Mitrovic
On 10/19/11, Nick Sabalausky a@a.a wrote:
 zsxxsz zsx...@63.net wrote in message
 news:j7mmkr$1fm0$1...@digitalmars.com...
I love Tango, because it's like using JAVA to program with Tango, and using

C++
 to program with Phobos. Java is much more easy to program.

 Heh. The Java-ness of it is actually the one thing about Tango that I don't
 really like. 'Course, I'm a big Java-hater anyway, YMMV...


Oh what, you don't like
getterAbstractFactoriesBuilderFactorySingletonObjectListener?


Re: D2 port of Tango

2011-10-18 Thread Jacob Carlborg

On 2011-10-18 06:52, SiegeLord wrote:

I just wanted to get the word out about a little project me and a few other 
people been working on for the few past months, in case anyone feels like 
helping out (or just as an FYI). This project is the D2 port of the Tango 
framework library. You can read about it here:

https://github.com/SiegeLord/Tango-D2

We are currently a little more than half way done in terms of modules fiddled 
with. Currently there are 181 modules ported out of approximately 343 (give or 
take 20). Currently only the dmd compiler and Linux platform are supported... 
but obviously we want to get all the other platforms/compilers as time goes on. 
I'm guessing at the current rate of porting we'll be done in about half a year.

Now, the project is actually two projects in one.

The first project is a D2 port proper that tries to keep API semantics the same 
as the D1 original. I preside over this aspect, and you can see the rough 
porting guidelines in the repository. This is the 'd2port' branch in my 
repository.

The second project is a more ambitious effort to rewrite some aspects of Tango 
without preserving semantics or anything. mtachrono presides over this aspect, 
so you can talk to him about the motivations behind it. This is the 'master' 
branch in my repository.

That's all. Cheers.

-SiegeLord


This is great, keep up to good work.

--
/Jacob Carlborg


Re: D2 port of Tango

2011-10-18 Thread Jacob Carlborg

On 2011-10-18 06:52, SiegeLord wrote:

I just wanted to get the word out about a little project me and a few other 
people been working on for the few past months, in case anyone feels like 
helping out (or just as an FYI). This project is the D2 port of the Tango 
framework library. You can read about it here:

https://github.com/SiegeLord/Tango-D2

We are currently a little more than half way done in terms of modules fiddled 
with. Currently there are 181 modules ported out of approximately 343 (give or 
take 20). Currently only the dmd compiler and Linux platform are supported... 
but obviously we want to get all the other platforms/compilers as time goes on. 
I'm guessing at the current rate of porting we'll be done in about half a year.

Now, the project is actually two projects in one.

The first project is a D2 port proper that tries to keep API semantics the same 
as the D1 original. I preside over this aspect, and you can see the rough 
porting guidelines in the repository. This is the 'd2port' branch in my 
repository.


Does this use druntime?


The second project is a more ambitious effort to rewrite some aspects of Tango 
without preserving semantics or anything. mtachrono presides over this aspect, 
so you can talk to him about the motivations behind it. This is the 'master' 
branch in my repository.


Do you have any examples of this, what's changed?


That's all. Cheers.

-SiegeLord



--
/Jacob Carlborg


Re: D2 port of Tango

2011-10-18 Thread Trass3r

Good job.

The first project is a D2 port proper that tries to keep API semantics  
This is the 'd2port' branch in my repository.


The second project is a more ambitious effort to rewrite some aspects 
This is the 'master' branch in my repository.


Why isn't it the other way around?


Re: D2 port of Tango

2011-10-18 Thread Trass3r

Why?  What's the point?  Why not work on Phobos instead?


Well D1 projects could be ported to D2 much more easily, e.g. Yage.


Re: D2 port of Tango

2011-10-18 Thread zsxxsz
Greate news. I wait for it for a long time.


Re: D2 port of Tango

2011-10-18 Thread SiegeLord
Caligo Wrote:
 Why?  What's the point?  Why not work on Phobos instead?

Aside from the obvious philosophical differences, which I am NOT going to get 
into, porting D1 projects is an important reason.

-SiegeLord


Re: D2 port of Tango

2011-10-18 Thread SiegeLord
Jacob Carlborg Wrote:
 Does this use druntime?

Yes, although a Tango specific runtime (compatible with druntime) will probably 
be an option some day too. Still, right now you can safely use (modulo my 
imperfect testing) Phobos and Tango modules together in a single program.

 Do you have any examples of this, what's changed?

The biggest difference right now is the near-complete rewriting of the 
tango.net package. You'd have to get a hold of mtachrono to see what roadmap he 
has.

-SiegeLord


Re: D2 port of Tango

2011-10-18 Thread SiegeLord
Trass3r Wrote:
 Why isn't it the other way around?

Just a historical oddity.

-SiegeLord


Re: D2 port of Tango

2011-10-18 Thread Denis Shelomovskij

18.10.2011 8:00, Caligo пишет:



On Mon, Oct 17, 2011 at 11:52 PM, SiegeLord n...@none.com
mailto:n...@none.com wrote:

I just wanted to get the word out about a little project me and a
few other people been working on for the few past months, in case
anyone feels like helping out (or just as an FYI). This project is
the D2 port of the Tango framework library. You can read about it here:

https://github.com/haskelSiegeLord/Tango-D2
https://github.com/SiegeLord/Tango-D2

We are currently a little more than half way done in terms of
modules fiddled with. Currently there are 181 modules ported out of
approximately 343 (give or take 20). Currently only the dmd compiler
and Linux platform are supported... but obviously we want to get all
the other platforms/compilers as time goes on. I'm guessing at the
current rate of porting we'll be done in about half a year.

Now, the project is actually two projects in one.

The first project is a D2 port proper that tries to keep API
semantics the same as the D1 original. I preside over this aspect,
and you can see the rough porting guidelines in the repository. This
is the 'd2port' branch in my repository.

The second project is a more ambitious effort to rewrite some
aspects of Tango without preserving semantics or anything. mtachrono
presides over this aspect, so you can talk to him about the
motivations behind it. This is the 'master' branch in my repository.

That's all. Cheers.

-SiegeLord


Why?  What's the point?  Why not work on Phobos instead?


+1 to Caligo. I agree that Tango is a good library (and was the best one 
for D1) but, IMHO, porting it to D2 is a bad idea.
I'm the one who has a big D1+Tango project and I'd better rewrite it 
with D2+Phobos, because:


0. I don't want to have a two standard libraries problem with D2 
(which one to select?).


1. Phobos has a better design (Tango is too complicated in some 
places, has a lot of things I (and a regular programmer IMHO) don't use, 
and has bad design decisions sometimes - both internal and user API)


2. Phobos has less _critical bugs_ because of better code control 
(e.g. Tango has memory corruption bug for a very long time in Vector 
container (#2064)).


3. There is no Andrei Alexandrescu clone to generate that perfect 
ideas for Tango.


Re: D2 port of Tango

2011-10-18 Thread Eric Poggel (JoeCoder)

On 10/18/2011 12:52 AM, SiegeLord wrote:

I just wanted to get the word out about a little project me and a few other 
people been working on for the few past months, in case anyone feels like 
helping out (or just as an FYI). This project is the D2 port of the Tango 
framework library. You can read about it here:

https://github.com/SiegeLord/Tango-D2

We are currently a little more than half way done in terms of modules fiddled 
with. Currently there are 181 modules ported out of approximately 343 (give or 
take 20). Currently only the dmd compiler and Linux platform are supported... 
but obviously we want to get all the other platforms/compilers as time goes on. 
I'm guessing at the current rate of porting we'll be done in about half a year.

Now, the project is actually two projects in one.

The first project is a D2 port proper that tries to keep API semantics the same 
as the D1 original. I preside over this aspect, and you can see the rough 
porting guidelines in the repository. This is the 'd2port' branch in my 
repository.

The second project is a more ambitious effort to rewrite some aspects of Tango 
without preserving semantics or anything. mtachrono presides over this aspect, 
so you can talk to him about the motivations behind it. This is the 'master' 
branch in my repository.

That's all. Cheers.

-SiegeLord


I already mentioned this deeper down in the thread, but what are the 
chances of being able to use tango as an add-on for phobos2?  Something 
from which I could pull in only the tango modules I need and use phobos 
for the rest?


Re: D2 port of Tango

2011-10-18 Thread Eric Poggel (JoeCoder)

On 10/18/2011 6:24 AM, Trass3r wrote:

Why? What's the point? Why not work on Phobos instead?


Well D1 projects could be ported to D2 much more easily, e.g. Yage.


True, but I had hoped to port Yage to phobos2 anyway.  Lack of xml 
support in phobos is the biggest reason I haven't started doing this 
already.  Time being another reason.


If Tango was a library of add-in modules of which I could include only 
what I need, I would be very likely to keep using it.  I think tango 
could become quite popular again with an approach like this.  But it may 
need to depend on some phobos modules and conventions for good integration.


Re: D2 port of Tango

2011-10-18 Thread Trass3r
I already mentioned this deeper down in the thread, but what are the  
chances of being able to use tango as an add-on for phobos2?  Something  
from which I could pull in only the tango modules I need and use phobos  
for the rest?


He already answered that:

SiegeLord Wrote:

Does this use druntime?
Yes, although a Tango specific runtime (compatible with druntime) will  
probably be an option some day too. Still, right now you can safely use  
(modulo my imperfect testing) Phobos and Tango modules together in a  
single program.


Re: D2 port of Tango

2011-10-18 Thread Eric Poggel (JoeCoder)

On 10/18/2011 12:45 PM, Trass3r wrote:

I already mentioned this deeper down in the thread, but what are the
chances of being able to use tango as an add-on for phobos2? Something
from which I could pull in only the tango modules I need and use
phobos for the rest?


He already answered that:

SiegeLord Wrote:

Does this use druntime?

Yes, although a Tango specific runtime (compatible with druntime) will
probably be an option some day too. Still, right now you can safely
use (modulo my imperfect testing) Phobos and Tango modules together in
a single program.


Not quite.  I was wondering if it can be done with ONLY bringing in what 
I need, as apposed to most or all of tango.


Re: D2 port of Tango

2011-10-18 Thread Jonathan M Davis
On Tuesday, October 18, 2011 10:27 Denis Shelomovskij wrote:
 18.10.2011 8:00, Caligo пишет:
  On Mon, Oct 17, 2011 at 11:52 PM, SiegeLord n...@none.com
  
  mailto:n...@none.com wrote:
  I just wanted to get the word out about a little project me and a
  few other people been working on for the few past months, in case
  anyone feels like helping out (or just as an FYI). This project is
  the D2 port of the Tango framework library. You can read about it
  here:
  
  https://github.com/haskelSiegeLord/Tango-D2
  https://github.com/SiegeLord/Tango-D2
  
  We are currently a little more than half way done in terms of
  modules fiddled with. Currently there are 181 modules ported out of
  approximately 343 (give or take 20). Currently only the dmd compiler
  and Linux platform are supported... but obviously we want to get all
  the other platforms/compilers as time goes on. I'm guessing at the
  current rate of porting we'll be done in about half a year.
  
  Now, the project is actually two projects in one.
  
  The first project is a D2 port proper that tries to keep API
  semantics the same as the D1 original. I preside over this aspect,
  and you can see the rough porting guidelines in the repository. This
  is the 'd2port' branch in my repository.
  
  The second project is a more ambitious effort to rewrite some
  aspects of Tango without preserving semantics or anything. mtachrono
  presides over this aspect, so you can talk to him about the
  motivations behind it. This is the 'master' branch in my repository.
  
  That's all. Cheers.
  
  -SiegeLord
  
  Why? What's the point? Why not work on Phobos instead?
 
 +1 to Caligo. I agree that Tango is a good library (and was the best one
 for D1) but, IMHO, porting it to D2 is a bad idea.
 I'm the one who has a big D1+Tango project and I'd better rewrite it
 with D2+Phobos, because:
 
 0. I don't want to have a two standard libraries problem with D2
 (which one to select?).
 
 1. Phobos has a better design (Tango is too complicated in some
 places, has a lot of things I (and a regular programmer IMHO) don't use,
 and has bad design decisions sometimes - both internal and user API)
 
 2. Phobos has less _critical bugs_ because of better code control
 (e.g. Tango has memory corruption bug for a very long time in Vector
 container (#2064)).
 
 3. There is no Andrei Alexandrescu clone to generate that perfect
 ideas for Tango.

While I would much rather see effort being put into improving Phobos than 
Tango, I think that it's a bit rude to claim that the Tango folks should just 
throw away all of their Tango work and move all of their projects over to 
Phobos. Wanting to be able to easily port D1 programs to D2 is a completely 
valid thing to want to do, and while I think that new projects should use 
Phobos since it's the standard library, there's nothing wrong with using a 
different library if you want to. If SiegeLord and others want to spend time 
porting Tango to D2, it's their right to be able to do so. Ostracizing Tango 
and its users is just going to make the D2 community poorer. And thanks to
druntime, it's now perfectly possible to mix Phobos and Tango code if you
want to (though the differences in design will likely make that not always
work as well as might be nice), so the situation is not the same as it was
for D1 when Phobos sucked, and it and Tango didn't work together.

- Jonathan M Davis


Re: D2 port of Tango

2011-10-18 Thread SiegeLord
Denis Shelomovskij Wrote:
 +1 to Caligo. I agree that Tango is a good library (and was the best one 
 for D1) but, IMHO, porting it to D2 is a bad idea.
 I'm the one who has a big D1+Tango project and I'd better rewrite it 
 with D2+Phobos, because:
 
  0. I don't want to have a two standard libraries problem with D2 
 (which one to select?).
 
  1. Phobos has a better design (Tango is too complicated in some 
 places, has a lot of things I (and a regular programmer IMHO) don't use, 
 and has bad design decisions sometimes - both internal and user API)
 
  2. Phobos has less _critical bugs_ because of better code control 
 (e.g. Tango has memory corruption bug for a very long time in Vector 
 container (#2064)).
 
  3. There is no Andrei Alexandrescu clone to generate that perfect 
 ideas for Tango.

0. Phobos is still the standard library for D2. Tango becomes a 3rd party 
library you can use alongside Phobos. Think using libGTK along side glibc.

1, 3. Subjective. I think the opposite and more importantly I believe in choice.

2. Fixed 3 months ago.

-SiegeLord


Re: D2 port of Tango

2011-10-18 Thread SiegeLord
Eric Poggel (JoeCoder) Wrote:

 Not quite.  I was wondering if it can be done with ONLY bringing in what 
 I need, as apposed to most or all of tango.

One of Tango's philosophies was to minimize intermodule dependencies, something 
that makes this porting effort a lot easier... still, those dependencies do 
exist, meaning that you usually can't use individual modules in isolation. I 
don't really get your question however. TangoD2 is just another 3rd party 
library... to use it you'd install the whole thing somewhere on your computer. 
Then, you can compile the whole thing into a library OR use a tool like xfbuild 
(maybe rdmd too, never had luck with that one) to compile only the modules that 
your program imports.

-SiegeLord


Re: D2 port of Tango

2011-10-18 Thread Charles Hixson

On 10/18/2011 09:15 AM, SiegeLord wrote:

Caligo Wrote:

Why?  What's the point?  Why not work on Phobos instead?


Aside from the obvious philosophical differences, which I am NOT going to get 
into, porting D1 projects is an important reason.

-SiegeLord


While I can see the desirability of porting good D1 projects, from my 
point of view when Tango became popular the usability of D1 plummeted. 
Too many tools would only work either with or without Tango installed. 
And I kept having installation problems.


So I'm *not* looking forwards to seeing Tango in D2.  If this could be 
done without requiring phobos to be disabled, and without mangling it, 
then I would have many fewer problems with it, but as it is...Tango for 
D1 left a VERY bad taste in my mouth.  Very.  In fact it was one of the 
major reasons I switched to D2 while it was still quite flakey.





D2 port of Tango

2011-10-17 Thread SiegeLord
I just wanted to get the word out about a little project me and a few other 
people been working on for the few past months, in case anyone feels like 
helping out (or just as an FYI). This project is the D2 port of the Tango 
framework library. You can read about it here:

https://github.com/SiegeLord/Tango-D2

We are currently a little more than half way done in terms of modules fiddled 
with. Currently there are 181 modules ported out of approximately 343 (give or 
take 20). Currently only the dmd compiler and Linux platform are supported... 
but obviously we want to get all the other platforms/compilers as time goes on. 
I'm guessing at the current rate of porting we'll be done in about half a year.

Now, the project is actually two projects in one.

The first project is a D2 port proper that tries to keep API semantics the same 
as the D1 original. I preside over this aspect, and you can see the rough 
porting guidelines in the repository. This is the 'd2port' branch in my 
repository.

The second project is a more ambitious effort to rewrite some aspects of Tango 
without preserving semantics or anything. mtachrono presides over this aspect, 
so you can talk to him about the motivations behind it. This is the 'master' 
branch in my repository.

That's all. Cheers.

-SiegeLord