Simen Kjaeraas:
> auto re = regex("a[b-e]", "g");
> foreach (e; "abracazoo" / re) {
> }

D has operator overload, that Java lacks, but this fact doesn't force you to 
use them even when they are unreadable.

For people that like the "in" there I'd like to remind how it can look once (if 
it will ever happen) the foreach uses "in" too:

foreach (e in (re in "abracazoo")) {...}

Bye,
bearophile

Reply via email to