October 06, 2019 [Issue 20274] New: IFTI fails for opDispatch and 'with' | ||||
---|---|---|---|---|
| ||||
https://issues.dlang.org/show_bug.cgi?id=20274 Issue ID: 20274 Summary: IFTI fails for opDispatch and 'with' Product: D Version: D2 Hardware: x86_64 OS: Linux Status: NEW Severity: normal Priority: P1 Component: dmd Assignee: nobody@puremagic.com Reporter: maxsamukha@gmail.com struct A { void opDispatch(string name, A...)(A a) { } } struct B { void opDispatch(string name, T)(T a) { } } void main() { A a; a.foo(2); // ok with (a) { foo(2); // fails } B b; b.foo(3); // ok with(b) { foo(3); // fails } } test.d(18): Error: function expected before (), not (*__withSym).opDispatch() of type void test.d(25): Error: undefined identifier foo -- |
Copyright © 1999-2021 by the D Language Foundation