What's the deal with "Warning: explicit element-wise assignment..."

Andrei Alexandrescu via Digitalmars-d digitalmars-d at puremagic.com
Tue Apr 29 20:32:23 PDT 2014


On 4/29/14, 4:09 PM, bearophile wrote:
> Andrei Alexandrescu:
>
>> On 4/29/14, 11:08 AM, bearophile wrote:
>>> In Phobos there are awkward names like walkLength
>>
>> Love it. -- Andrei
>
> The name like "walkLength" was chosen (by you?), instead of a more
> natural name like "length" (or even a nice, short, clean, readable,
> handy and easer to write name like "len" as in Python) to underline that
> walkLength could be O(n).

"length" was already taken, and it seemed unbecoming to have "len" 
describe the longer operation. I find "walkLength" awesomely suggestive. 
-- Andrei




More information about the Digitalmars-d mailing list