What's the deal with "Warning: explicit element-wise assignment..."
via Digitalmars-d
digitalmars-d at puremagic.com
Wed Apr 30 13:56:47 PDT 2014
On Wednesday, 30 April 2014 at 19:55:08 UTC, Wyatt wrote:
> It's an awkward discussion because neither is very discoverable
> in the first place; maybe make one an alias for the other and
> give people a sporting chance to find the damn thing?
With an IDE discoverable probably means that it follows the
conventions of the language for the first phrase. I.e. it should
start with "length" so that it pops up when you start typing
"len…". Well, if it is callable with dot-notation.
I know from experience that I avoid using functions that I don't
remember the name of. That is one reason I use list
comprehensions so much in Python. The more dedicated functions
takes time to look up. I think large sections of Python's
standard library could be wiped out in favour of the more
powerful abstractions and mechanisms it has now.
And even if a very narrow function might be faster, I probably
will write my own loop if speed is that important. So I would
favour fewer and more generic functions, with better optimization.
(I think you can get a long way by just using templates, but
others have suggested AST macros, and pattern/matching term
rewriting is also a possibility.)
More information about the Digitalmars-d
mailing list