www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 21463] New: std.typecons.Proxy declares opCmp when it should

https://issues.dlang.org/show_bug.cgi?id=21463

          Issue ID: 21463
           Summary: std.typecons.Proxy declares opCmp when it should not
           Product: D
           Version: D2
          Hardware: x86_64
                OS: Linux
            Status: NEW
          Severity: enhancement
          Priority: P1
         Component: phobos
          Assignee: nobody puremagic.com
          Reporter: tobias pankrath.net

--
import std.typecons : Proxy;

struct Inner {}
class Outer
{
    Inner inner;
    mixin Proxy!inner;
}

int main() { return 0; }
--

 /usr/include/dlang/dmd/std/typecons.d(6762): Error: need member function
opCmp() for struct Inner to compare
--
Dec 08 2020