Is str ~ regex the root of all evil, or the leaf of all good?

Andrei Alexandrescu SeeWebsiteForEmail at erdani.org
Thu Feb 19 19:21:40 PST 2009


Denis Koroskin wrote:
> On Thu, 19 Feb 2009 23:23:13 +0300, Bill Baxter <wbaxter at gmail.com> wrote:
> 
>> I don't like the syntax I saw somewhere earlier in the thread of
>>     0..iter.captures
>>
>> .captures looks like it should be a set of captures, not a count.
>>
>> This is a need that comes up again and again -- querying the size, or
>> count, or length of some sub-element like this -- so I think it would
>> greatly benefit Phobos to choose some less ambiguous convention and
>> stick to it.   Like  nCaptures, numCaptures, capturesLength, etc.
>>
>> ---bb
> 
> Agree. I thought that iter.captures is a set (range) of captures.
> 

I'm done implementing that.

Andrei



More information about the Digitalmars-d mailing list