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


Kenji Hara <k.hara...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |patch
                 CC|                            |k.hara...@gmail.com


--- Comment #5 from Kenji Hara <k.hara...@gmail.com> 2011-07-29 06:29:13 PDT ---
I think this is not enhancement at least D2.
opDispatch for property syntax needs fixing this issue.

struct S
{
    template opDispatch(string name)
    {
        @property int opDispatch(A...)(A args)
        {
          static if (args.length)
            return args[0];
          else
            return 0;
        }
    }
}
void main()
{
    S s;
    s.prop == 0;  // Error: s.opDispatch(A...) has no value
}

I have posted D2 patch.
https://github.com/D-Programming-Language/dmd/pull/280

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------

Reply via email to