1、tinybind.h there are no arguments to `params' that depend on a template parameter, so a declaration of `params' must be available。。。
solution:参考一下文档
11.9.2. Name lookup, templates, and accessing members of base classes
The C++ standard prescribes that all names that are not dependent ontemplate parameters are bound to their present definitions when parsinga template function or class.[1] Only names that are dependent are looked up at the pointof instantiation. For example, consider
void foo(double); struct A { template <typename T> void f () { foo (1); // 1 int i = N; // 2 T t; t.bar(); // 3 foo (t); // 4 } static const int N; }; |
Here, the names foo and N appear in a context that doesnot depend on the type ofT. The compiler will thus require thatthey are defined in the context of use in the template, not only beforethe