phobos / tango / ares

Lars Ivar Igesund larsivar at igesund.net
Fri Feb 9 02:13:07 PST 2007


Kevin Bealer wrote:

> Lars Ivar Igesund wrote:
>> Frits van Bommel wrote:
>> 
>>> Which one to use is hard to say at this point. I've been trying out
>>> Tango since its release and I like it but I sometimes miss some parts of
>>> Phobos. Whether this is because Phobos is just more familiar to me or
>>> actually better is hard to say...
>> 
>> Note that what you miss that you feel you have in Phobos, is very much
>> part of the feedback we would like.
>> 
> 
> Okay -- I'm really sorry if any of this seems to have a negative tone.
> I hesitate to write this since I have a lot of respect for the Tango
> design in general, but there are a couple of friction points I've noticed.
> 
> 1. writefln / format replacements
> 
> Concerning standard output and string formatting, in phobos I can do
> these operations:
> 
>    writefln("%s %s %s", a, b, c);
>    format("%s %s %s", a, b, c);
> 
> How do I do these in Tango?  The change to "{0} {1}" stuff is fine with
> me, in fact I like it, but this syntax:
> 
>    Stdout.formatln("{0} {1} {2}", a, b, c);
>    Format!(char).convert("{0} {1} {2}", a, b, c);

I can't give you an immediate solution for the "length" of the
Stdout.formatln, but usually one would use tango.text.convert.Sprint for
what you use the formatter for. If you only want to print values, there are
non-formatting ways to do that. We may be able to give you quicker/easier
help over our forum if you have followups? May make it easier for us to
integrate solutions into our documentation too if needed.

-- 
Lars Ivar Igesund
blog at http://larsivi.net
DSource & #D: larsivi
Dancing the Tango


More information about the Digitalmars-d-learn mailing list