www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 9936] New: Wrong opBinary/opBinaryRight rewrite.

reply d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=9936

           Summary: Wrong opBinary/opBinaryRight rewrite.
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody puremagic.com
        ReportedBy: timon.gehr gmx.ch


--- Comment #0 from timon.gehr gmx.ch 2013-04-15 09:35:35 PDT ---
DMD 2.062:

struct S{ auto opBinary(S s){ return 3; } }
static assert(!is(typeof(S()+S())));

The static assertion should pass. opBinary is not even a template.
The analogous bug exists for opBinaryRight.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Apr 15 2013
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=9936


Walter Bright <bugzilla digitalmars.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |bugzilla digitalmars.com


--- Comment #1 from Walter Bright <bugzilla digitalmars.com> 2013-04-15
16:27:05 PDT ---
The wrong right rewrite? Best bugzilla title evar!

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Apr 15 2013
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=9936


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

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Keywords|                            |accepts-invalid, pull


--- Comment #2 from Kenji Hara <k.hara.pg gmail.com> 2013-04-15 18:38:17 PDT ---
https://github.com/D-Programming-Language/dmd/pull/1899

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Apr 15 2013
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=9936



--- Comment #3 from github-bugzilla puremagic.com 2013-04-16 04:54:45 PDT ---
Commits pushed to master at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/0e5b0ea500919f7c3af6b7eaee10d0feef1db006
fix Issue 9936 - Wrong opBinary/opBinaryRight rewrite.

opBinary, opBinaryRight, and opOpAssign had same problem.

https://github.com/D-Programming-Language/dmd/commit/f4f4b9080ef0574aec31585a2ca49c3e344c1e28
Merge pull request #1899 from 9rnsr/fix9936

Issue 9936 - Wrong opBinary/opBinaryRight rewrite.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Apr 16 2013
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=9936


Andrej Mitrovic <andrej.mitrovich gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |andrej.mitrovich gmail.com
         Resolution|                            |FIXED


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