questions on PhanTango 'merger' (was Merging Tangobos into Tango) - long-term vision

BCS ao at pathlink.com
Thu Oct 11 08:25:44 PDT 2007


Reply to Lars,

> Generally I think you make a comment on an uninformed basis, but I'll
> try to put you straight :)
> 
> BCS wrote:
> 
>> I think that style and ease of use are tightly linked. In Phobos, if
>> you want to write to the screen you use writef and it dumps a pile of
>> stuff to the screen. In tango (from what I've seen) you get a
>> reference to an object and then run a big sequence of chained calls.
>> In some cases, the tango way has something going for it, but in
>> others, Just get the ___ out of my way and put "bla bla bla" on the
>> screen. I don't care if it's less flexible, because I just want to
>> print.
>> 
> How on earth is
> 
> Cout("somestring"); more "complex" than writef (write actually)?
>

it isn't, but what about

writef("hello %s, how did you like your %d, %s?", name, count, product);

vs.

Cout("hello ")(name)(", how did you like your ")(count)(", ")(product)("?");

The first is one (static) function call, the other is 7 (virtual) function 
calls, to 3 different functions. If you don't see a difference in complexity, 
then you are measuring something different than me.

Note: there may be a better way to do that, but I don't know what it is.
 
> You can use chained calls with Tango, but you don't have to, and
> generally you won't. So Tango is probably both flexible _and_ able to
> do just do what you want?
> 

I'm a cycle snob. How hard it is to code, how hard it is to get it to do 
what I want and *how long it takes to run* are of equal importance to me. 
With tango's use of chained calls (not exactly free from a performance standpoint) 
is a small minus in my book.

> Tango's IO system is indeed flexible, and to some complex to learn.
> With the fairly new stream abstractions, it should be no more
> difficult than Phobos' though, and indeed, in Tango they are
> integrated such that you can chain streams using them as filters and
> more.
>

please don't waste your time here explaining to me how it work. Please do 
put the same amount of time into improving the docs so that everyone can 
get the benefit.
 
>> Where the "OO is god" (oops, make that "good") stance puts me off is
>> where it get in my way with things like (random example) RegEx. I
>> don't want to new of an object and fill in all the members (etc, etc)
>> just to run one regex match and then drop the object. I'd love to
>> have both a RegEx class then compiles to some sort of fast state
>> machine and a free function that does an on the fly interpretation.
>> 
> I highly doubt this is a good example from Tango considering Tango and
> Phobos currently share Regex implementation?
> 

Well, I'm not to fond of it as part of phobos ether. My point was an example 
of where "style" is more than a secondary concern.

>> I know that's all a bit disjointed, but I hope it shows something of
>> my reservations of switching to Tango.
>> 
> It mostly shows that you are making decisions on an 
> uninformed and

wrong*

> outdated 

correct

> basis :)

If these thing have changed, I'm happy for Tango. Don't get me wrong, I want 
to use Tango, It's just that the benefit has yet to outweigh the cost, primarily 
as a result of a dwindling supply of my available time.



* it is not uninformed because I knew it is outdated. Also, the decisions 
you mention are "tango /was/ to complex for me to learn /in the time I had/" 
and "I don't have time to figure out Tango now". Even with world class docs, 
I wouldn't have the time now. One of my jobs might be going into a project 
In D and that would let me /make/ the time to figure it out. But at this 
point, I booked for most of the time I'm awake





More information about the Digitalmars-d mailing list