The Strange Loop conference

Timon Gehr timon.gehr at gmx.ch
Wed Sep 21 12:29:57 PDT 2011


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}

or maybe

val newcol = for(x<-collection if(x<5)) yield 2*x

vs

auto newrange = filter!((x){return x<5;})(map!((x){return 2*x;})(range));

I believe that is part of the reason why it is less known. If I write 
functional style code in D I unfortunately usually get feedback that it 
is "extremely hard to read". Furthermore, Scala has built-in tuples, and 
eg delimited continuations, which enable some more functional 
programming idioms. std.algorithm/std.range are also considerably (and 
as I understand, deliberately) underpowered for FP when compared to eg 
Haskell's standard set of libraries, and writing a good range from 
scratch is usually a serious undertaking.

Another big advantage that Scala has is that it supports pattern 
matching. It is usually about the first feature functional programmers 
care about.

What do you think is the biggest advantage that Ds functional 
programming has in comparison to Scala's?



More information about the Digitalmars-d mailing list