help with bind

jspencer spencer8 at
Wed Jun 16 09:55:59 PDT 2010

I talked to Tom Stachowiak, who couldn't spot anything wrong with the
code.  I believe this is a bug in std.bind (or maybe std.traits.)  Has
anyone else seen this?

With 2.047:
import std.bind;
import std.stdio;

void g (int a, int b)
   int c = a + b;

void main()
   auto g1 = bind(&g, _0, _0);


C:\tools\dmd2\windows\bin\..\..\src\phobos\std\bind.d(977): Error:
template instance ParameterTypeTuple!(const(EmptySlot)*) does not
match template declaration ParameterTypeTuple(dg...) if (dg.length ==
1 && isCallable!(dg))

More information about the Digitalmars-d-learn mailing list