OT: What's your favorite codeline?

Robert Fraser fraserofthenight at gmail.com
Tue Sep 1 11:02:04 PDT 2009


downs wrote:
> <downs>     foo.betweens("src=\"", "\"") /select/ (string s) { return s.find(criteria) != -1; }

Heh, I love that infix expression syntax. Too abd it ends up with a 
completely useless wrapper struct & 2 function calls, but hopefully LDC 
can inline that out.

> <downs>     auto videocon = ctx.getStreams().first(WHERE!("?.codec.codec_type == CodecType.Video")).codec;

Heh, going LINQ on us, now?



More information about the Digitalmars-d mailing list