[Issue 1457] array extension member syntax confused with local member functions

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sun Oct 21 12:27:09 PDT 2007


http://d.puremagic.com/issues/show_bug.cgi?id=1457


smjg at iname.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |smjg at iname.com
           Keywords|                            |rejects-valid




------- Comment #1 from smjg at iname.com  2007-10-21 14:27 -------
I've a feeling that there's been something reported to this effect before.  The
problem only occurs because the compiler tries to convert numbers.begin() to
begin(numbers) and then look up the symbol in the local scope.

Really, it doesn't make sense.  Hi.begin is a property of the struct Hi, not of
any array.  So the compiler shouldn't try to match the array property to it. 
Another way to put it is that numbers.begin() should instead be converted to
.begin(numbers).


-- 



More information about the Digitalmars-d-bugs mailing list