[Issue 17473] foreach on delegates incorrectly rejected

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Wed Jun 7 06:40:36 PDT 2017


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

--- Comment #2 from Eyal <eyal at weka.io> ---
(In reply to Vladimir Panteleev from comment #1)
> Your example works here. Could you specify the compiler version and
> compilation flags?

dmd --version
DMD64 D Compiler v2.074.0
Copyright (c) 1999-2017 by Digital Mars written by Walter Bright

dmd -unittest testdlg.d
int delegate(int delegate(char a) dlg)
int delegate(int delegate(char a) dlg)
testdlg.d(15): Error: delegate g (int delegate(char a) dlg) is not callable
using argument types (int delegate(ref char __applyArg0) pure nothrow @nogc
@safe)


Perhaps you didn't pass -unittest?

--


More information about the Digitalmars-d-bugs mailing list