www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 21472] New: `-checkaction=context` doesn't work with `tupleof`


          Issue ID: 21472
           Summary: `-checkaction=context` doesn't work with `tupleof`
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: P1
         Component: dmd
          Assignee: nobody puremagic.com
          Reporter: pro.mathias.lang gmail.com

struct Var { int a, b; }

void main ()
    Var v;
    assert(v.tupleof == v.tupleof);

Results in:
testc.d(6): Error: template core.internal.dassert._d_assert_fail cannot deduce
function from argument types !("==", int, int, int, int)(int, int, int, int),
candidates are:
       _d_assert_fail(string op, A)(auto ref scope const A a)
       _d_assert_fail(string comp, A, B)(auto ref scope const A a, auto ref
scope const B b)

Dec 11 2020