Re: associative arrays: iteration is finally here

2009-10-29 Thread rmcguire
Andrei Alexandrescu wrote: > Denis Koroskin wrote: >> On Wed, 28 Oct 2009 17:22:00 +0300, Andrei Alexandrescu >> wrote: >> >>> Walter has magically converted his work on T[new] into work on making >>> associative arrays true templates defined in druntime and not >>> considered very special

Re: associative arrays: iteration is finally here

2009-10-29 Thread rmcguire
Andrei Alexandrescu wrote: > rmcguire wrote: >> Wouldn't opIn be more useful if it returned a range starting with >> the element that was found? > > Thought about that, but it's hard to justify. Items aren't sorted in any > particular order, so you&#x

Re: Targeting C

2009-10-30 Thread rmcguire
Andrei Alexandrescu wrote: > grauzone wrote: >> Andrei Alexandrescu wrote: >>> Pelle MÃ¥nsson wrote: Andrei Alexandrescu wrote: > Yigal Chripun wrote: >> On 23/10/2009 13:02, bearophile wrote: >>> Chris Nicholson-Sauls: >>> I prefer this (Scala): list = list

Re: Proposal: Replace __traits and is(typeof(XXX)) with a 'magic namespace'.

2009-11-03 Thread rmcguire
Andrei Alexandrescu wrote: > Don wrote: >> Andrei Alexandrescu wrote: >>> Don wrote: [I'm moving this from deep inside a TDPL thread, since I think it's important] is(typeof(XXX)) is infamously ugly and unintuitive __traits(compiles, XXX) is more comprehensible, but jus

Re: Safety, undefined behavior, @safe, @trusted

2009-11-05 Thread rmcguire
Ellery Newcomer wrote: > Walter Bright wrote: >>> Well, if that's a problem you could fix it by making immutable not >>> shared unless you also put the shared attribute: >>> >>> immutable Object o;// thread-local >>> shared immutable Object o; // visible from all threads >> >>

Re: typedef: what's it good for?

2009-11-11 Thread rmcguire
Justin Johansson wrote: > Walter Bright Wrote: > >> When I originally worked out ideas for D, there were many requests from >> the C and C++ community for a 'strong' typedef, and so I put one in D. I >> didn't think about it too much, just assumed that it was a good idea. >> >> Now I'm not s

Re: typedef: what's it good for?

2009-11-11 Thread rmcguire
Andrei Alexandrescu wrote: > rmcguire wrote: >> Justin Johansson wrote: >> >>> Walter Bright Wrote: >>> >>>> When I originally worked out ideas for D, there were many requests from >>>> the C and C++ community for a 'strong'