The Strange Loop conference

Jacob Carlborg doob at me.com
Thu Sep 22 02:22:10 PDT 2011


On 2011-09-21 22:20, Andrei Alexandrescu wrote:
> On 9/21/11 2:29 PM, Timon Gehr wrote:
>> On 09/21/2011 06:55 PM, Andrei Alexandrescu wrote:
>>> I'm back from the Strange Loop conference. It's been an interesting
>>> experience. The audience was very diverse, with interest in everything
>>> functional (you'd only need to say "Haskell" or "monad" to get positive
>>> aahs), Web/cloud/tablet stuff, concurrent and distributed systems.
>>> Mentioning C++ non-mockingly was all but a faux pas; languages like
>>> Scala, Haskell, Clojure, and Erlang got attention. The quality of talks
>>> has been very variable, and unfortunately the
>>> over-confident-but-clueless-speaker stereotype was well represented.
>>>
>>> I gave a talk there
>>> (https://thestrangeloop.com/sessions/generic-programming-galore-using-d)
>>> which has enjoyed moderate audience and success. I uploaded the slides
>>> at http://erdani.com/d/generic-programming-galore.pdf and the video may
>>> be available soon.
>>
>> I am looking forward to it!
>>
>>>
>>> There was a very strong interest in D's CTFE abilities, which we should
>>> consider a strategic direction going forward.
>>
>> One milestone would be to make DMD GC enabled. CTFE string manipulation
>> sucks up too much memory.
>>
>>> Also finalizing D's
>>> concurrency language and library infrastructure is essential. These two
>>> features are key differentiators. Also, capitalizing on D's functional
>>> features (which are e.g. better than Scala's but less known) would add
>>> good value.
>>>
>>
>> Where D still loses when compared to Scala is functional code syntax:
>>
>> val newcol = collection filter {x=>x<5} map {x=>2*x}
>
> Yoda this wrote.
>
>> or maybe
>>
>> val newcol = for(x<-collection if(x<5)) yield 2*x
>
> Too baroque.
>
>> vs
>>
>> auto newrange = filter!((x){return x<5;})(map!((x){return 2*x;})(range));
>
> auto newrange = filter!"a<5"(map!"2*a"(range));
>
> At first some people get the heebiejeebies when seeing string-based
> lambda and the implicit naming convention for unary and binary
> functions. More importantly, there's the disadvantage you can't access
> local functions inside a string lambda. We should probably add a
> specialized lambda syntax.

I like this syntax:

auto newRange = range.map(a => 2 * a).filter(a => a < 5);

-- 
/Jacob Carlborg


More information about the Digitalmars-d mailing list