February 01, 2007
Lutger wrote:
> Awesome library. My compliments especially to the documentation writers,  the little I have read before dsource couldn't handle the traffic anymore was of exceptional quality. I hope the docs can be read offline too in the near future.

Agreed, I learned some interesting stuff about NaNs and Bessel functions and how to get sin and cos together for half the cost reading the math docs.  That's stuff you just don't get from reading your average standard lib documentation.

--bb
February 01, 2007
kris wrote:
> Lionello Lunesu wrote:
>> Bill Baxter wrote:
>>
>>> C) Port while maintaining compatibility -- annoying the poor me who has to deal with incompatibilities in the most basic functions (e.g. toString, writefln)
>>
>>
>> I too wonder why those were changed. Why not leave them be? What's so terrible about toString? It returns a string, doesn't it? Furthermore, there's no toUTF16, toUTF32, so what's the point?
>>
>> Seems like a change for the sake of being different.
>>
>> L.
> 
> Well, that's not entirely fair :)
> 
> You mention two specific areas:
> 
> 1) writefln does not support the functionality we needed. It has no support for either Locales, or for indexing the arguments themselves (both for supporting I18N). We decided to go a different route, because we beleive I18N is important enough to warrant some direct attention. (locale is not quite fully enabled in this release, but it will be in the next one).

A noble cause, for sure, and I'm glad you did it. I just think that porting from phobos should be a no-brainer.

> It would be cool if you ported the writefln code though, as an external option -- we can't expect I18N support to be to everyone's liking.

Maybe I will ;)

> 2) there's no toUtf16() and toUtf32()? This is not the case. Tango uses those in a number of modules to do just what they indicate. There are modules that expose all three ... in certain cases they're also templated for the base type that you want stored within (e.g. store as dchar, expose as all three types).

Obviously, I was talking about Object.toString. Changing Object creates unnecessary incompatibilities.

> This really was a not an easy decision for us to take, as I'm sure you can imagine.
> 
> Tango is what it is, and yet is open to change too. There's a /lot/ of people involved as you can see on the site, and I do hope you'll give it a good look?

I definitely will. I, like most people, have been waiting for a general framework to appear and Tango is the best :) So far :)

Maybe my post was too harsh, I really appreciate the effort put in Tango. D needs Tango.

L.
February 01, 2007
Woooow, at first sight it looks very nice!

Congratulations to you all and many thanks,

--
Tom;

== Quote from Lars Ivar Igesund (larsivar@igesund.net)'s article
> Dear D community
> The first public release of Tango is now ready for download.
> Tango is a D library that provides a runtime for the D programming language,
> plus many additional library features for the D programmer. Further growth
> and sharpening of quality is expected for coming releases.
> A feature list can be found on
> http://www.dsource.org/projects/tango/wiki/Features
> Extensive work has been put into documenting the basic features, and in
> trying to make usage and installation easy for as many as possible.
> Platform support will be provided with the help of the users. Win32, Posix
> x86 and PPC have currently received most testing.
> Tango is not yet fully polished, but the last few weeks have seen efforts to
> solve toolchain problems, cleaning operations, documentation production, an
> improved website and more. Hopefully you will find it a useful addition to
> the D world, and feedback will gladly be accepted.
> The Tango homepage can be found at
> http://www.dsource.org/projects/tango
> Downloads:
> Graphical installer for Windows -
> http://63.99.9.206/tango/downloads/setup-tango-0.95-beta1.exe
> Zip file -
> http://63.99.9.206/tango/downloads/tango-0.95-beta1-src.zip
> tar.gz file -
> http://63.99.9.206/tango/downloads/tango-0.95-beta1-src.tar.gz
> See http://www.dsource.org/projects/tango/wiki/Download for other
> alternatives like access to SVN repositories.
> See http://www.dsource.org/projects/tango/wiki/TopicInstallTango for more
> detailed installation instructions for your system.
> Contact
> http://www.dsource.org/projects/tango/wiki/Contact
> Signed,
> The Tango Team
> http://www.dsource.org/projects/tango/wiki/Contributors

February 01, 2007
Lionello Lunesu wrote:
> kris wrote:
>>
>> 2) there's no toUtf16() and toUtf32()? This is not the case. Tango uses those in a number of modules to do just what they indicate. There are modules that expose all three ... in certain cases they're also templated for the base type that you want stored within (e.g. store as dchar, expose as all three types).
> 
> Obviously, I was talking about Object.toString. Changing Object creates unnecessary incompatibilities.

This was a difficult decision for us.  Technically, Object.toString doesn't return a string, it returns a char array (ie. a sequence of UTF-8 characters).  Thus, toUtf8 is a more meaningful term for what the method actually does.  Another reason we chose this route is because Tango has a string class, and toString suggests that an instance of this class would be returned.  I suppose it's worth mentioning, however, that toString support for structs has not been changed because it is a compiler feature, and the disparity bothers me.  Fortunately, toString isn't required for IO in Tango so the issue hasn't come up in practice.


Sean
February 01, 2007
Good things come to those who wait !

I already installed tango from source on windows and I intend to use it as a replacement for phobos where possible.
Although I just did some simple review and testing, it seems very promising. The code looks very clean and structured. So I hope it will become the standard lib for D.

Even selector is working on windows now. I mentioned it yesterday on irc and today it's fixed, great :)

Thanks to all contributors
and best wishes for the future,
Daniel

February 01, 2007
Bill Baxter wrote:
> Lutger wrote:
>> Awesome library. My compliments especially to the documentation writers,  the little I have read before dsource couldn't handle the traffic anymore was of exceptional quality. I hope the docs can be read offline too in the near future.
> 
> Agreed, I learned some interesting stuff about NaNs and Bessel functions and how to get sin and cos together for half the cost reading the math docs.  That's stuff you just don't get from reading your average standard lib documentation.
> 
> --bb

Thanks, Bill! I learnt a lot writing it, too. I hope people come away thinking that it's a more interesting topic than they expected,

- dac
February 02, 2007
Good to see the famed uber lib out in the open!

When I try to use it though, I get the following compiler error:

--------------------------

C:\Dprojects\tango>build main.d -clean
Assertion failure: 'classinfo->structsize == CLASSINFO_SIZE' on line 315 in file
 'toobj.c'

abnormal program termination

C:\Dprojects\tango>

--------------------------

main.d:

import tango.io.Stdout;

void main()
{
	Stdout.println("Hello world!" );
}

--------------------------

Any idea what caused this?


Also, reading the docs I have a few questions/complaints/critiques:

Why do I have to instantiate classes to do stuff like basic file/path operations?  I don't like having to keep track of classes and stuff when doing such trivial things.  Maybe there could be a procedural wrapper around this stuff?

Is there some simple way to get a start a timer that will either call a callback after some period of time or give you the time since it was started like in phobos' std.perf?

Is there any way I could make my programs that still use phobos compile again without uninstalling Tango?

The documentation uses 'auto' a lot.  auto is a cool feature, but now I have no idea what file.read; returns or how to deal with it.  Is it an array of (u)bytes (I hope!) ??  Is it something else that needs special care?  I suppose I could read the more exhaustive API index or even the source, but that would kinda defeat the purpose of a quick reference.


Questions/critique aside, Tango seems the best hope for a high quality and community driven standard library.  Thank you very much for your effort Tango team!
February 02, 2007
On Thu, 01 Feb 2007 22:30:06 -0500, Chad J wrote:

> Good to see the famed uber lib out in the open!
> 
> When I try to use it though, I get the following compiler error:
> 
> --------------------------
> 
> C:\Dprojects\tango>build main.d -clean
> Assertion failure: 'classinfo->structsize == CLASSINFO_SIZE' on line 315
> in file
>   'toobj.c'

This is a bug in DMD but was fixed. Install the latest DMD version and try again.


-- 
Derek
(skype: derek.j.parnell)
Melbourne, Australia
"Down with mediocrity!"
2/02/2007 3:01:52 PM
February 02, 2007
Chad J wrote:
> Good to see the famed uber lib out in the open!
> 
> When I try to use it though, I get the following compiler error:
> 
> --------------------------
> 
> C:\Dprojects\tango>build main.d -clean
> Assertion failure: 'classinfo->structsize == CLASSINFO_SIZE' on line 315 in file
>  'toobj.c'
> 
> abnormal program termination
> 
> C:\Dprojects\tango>
> 
> --------------------------
> 
> main.d:
> 
> import tango.io.Stdout;
> 
> void main()
> {
>     Stdout.println("Hello world!" );
> }
> 
> --------------------------
> 
> Any idea what caused this?

Yes; the Tango release is based upon a 1004 runtime model. You're using a 1.0 compiler? Imagine you'd find the same when using a 1.0 DMD compiler with a 1004 phobos.lib?



> 
> 
> Also, reading the docs I have a few questions/complaints/critiques:
> 
> Why do I have to instantiate classes to do stuff like basic file/path operations?  I don't like having to keep track of classes and stuff when doing such trivial things.  Maybe there could be a procedural wrapper around this stuff?

That's possible, but usage of scope is handy here also? e.g.

scope path = new FilePath (...)

For many people, the advantages of keeping all the functionality together is a real boon.

> 
> Is there some simple way to get a start a timer that will either call a callback after some period of time or give you the time since it was started like in phobos' std.perf?


Not yet. Want to write one?

> 
> Is there any way I could make my programs that still use phobos compile again without uninstalling Tango?

Yes, flip the phobos.lib file (or .a) back to the original one, and use the original -I setting. It's pretty easy, but might become easier if the compiler did not hard-code the lib name ("phobos.lib").


> 
> The documentation uses 'auto' a lot.  auto is a cool feature, but now I have no idea what file.read; returns or how to deal with it.  Is it an array of (u)bytes (I hope!) ??  Is it something else that needs special care?  I suppose I could read the more exhaustive API index or even the source, but that would kinda defeat the purpose of a quick reference.

That's a good point. And at this time we don't have a quick reference per se [writes a ticket for it].

FWIW, untyped data in Tango is invariably returned as a void[], and the API links are pretty good even if the doc isn't always complete -- the doc API uses CandyDoc, and the big-blue-title at the top leads to a Decant generated source listing. All the other blue links on the CandyDoc pages lead to Wiki comments, which we'll uses for improving the code doc etc. Quite sophiticated really, for API doc :)

> 
> 
> Questions/critique aside, Tango seems the best hope for a high quality and community driven standard library.  Thank you very much for your effort Tango team!

On behalf of the team, you're very welcome!
February 02, 2007
kris wrote:
> Chad J wrote:
> 
>> Good to see the famed uber lib out in the open!
>>
>> When I try to use it though, I get the following compiler error:
>>
>> --------------------------
>>
>> C:\Dprojects\tango>build main.d -clean
>> Assertion failure: 'classinfo->structsize == CLASSINFO_SIZE' on line 315 in file
>>  'toobj.c'
>>
>> abnormal program termination
>>
>> C:\Dprojects\tango>
>>
>> --------------------------
>>
>> main.d:
>>
>> import tango.io.Stdout;
>>
>> void main()
>> {
>>     Stdout.println("Hello world!" );
>> }
>>
>> --------------------------
>>
>> Any idea what caused this?
> 
> 
> Yes; the Tango release is based upon a 1004 runtime model. You're using a 1.0 compiler? Imagine you'd find the same when using a 1.0 DMD compiler with a 1004 phobos.lib?
> 
> 

Yeah I was using a 1.0 compiler and the problem went away when I installed 1.004.

> 
>>
>>
>> Also, reading the docs I have a few questions/complaints/critiques:
>>
>> Why do I have to instantiate classes to do stuff like basic file/path operations?  I don't like having to keep track of classes and stuff when doing such trivial things.  Maybe there could be a procedural wrapper around this stuff?
> 
> 
> That's possible, but usage of scope is handy here also? e.g.
> 
> scope path = new FilePath (...)
> 
> For many people, the advantages of keeping all the functionality together is a real boon.
> 

For the rest of us, would you consider having a wrapper for that stuff included in Tango?

>>
>> Is there some simple way to get a start a timer that will either call a callback after some period of time or give you the time since it was started like in phobos' std.perf?
> 
> 
> 
> Not yet. Want to write one?
> 

Sure.

Problem is though, I'm in a bit of time crunch with midterms, scholarship essays, and my father's birthday, so I probably wouldn't be able to even start for another week or so.  Is that OK?

>>
>> Is there any way I could make my programs that still use phobos compile again without uninstalling Tango?
> 
> 
> Yes, flip the phobos.lib file (or .a) back to the original one, and use the original -I setting. It's pretty easy, but might become easier if the compiler did not hard-code the lib name ("phobos.lib").
> 
> 

OK, thanks.  Yeah, that's a bit inconvenient.  Hope dmd changes then.

>>
>> The documentation uses 'auto' a lot.  auto is a cool feature, but now I have no idea what file.read; returns or how to deal with it.  Is it an array of (u)bytes (I hope!) ??  Is it something else that needs special care?  I suppose I could read the more exhaustive API index or even the source, but that would kinda defeat the purpose of a quick reference.
> 
> 
> That's a good point. And at this time we don't have a quick reference per se [writes a ticket for it].
> 
> FWIW, untyped data in Tango is invariably returned as a void[], and the API links are pretty good even if the doc isn't always complete -- the doc API uses CandyDoc, and the big-blue-title at the top leads to a Decant generated source listing. All the other blue links on the CandyDoc pages lead to Wiki comments, which we'll uses for improving the code doc etc. Quite sophiticated really, for API doc :)
> 

Might I suggest that ubyte[] or byte[] be a more appropriate return type for some of those arrays due to the type-awareness of the GC?  It would suck to read in a "noisy" data file and have the GC choke on it, or have to always tell the GC that there are no pointers there.  I'm assuming you will never find valid pointers to memory in a file from a drive, or if you do, the GC probably wasn't scanning the file anyways so you'd have problems if you didn't already have a safety reference.