Home » U++ Library support » U++ Callbacks and Timers » callback1 vs callback2
callback1 vs callback2 [message #15281] |
Tue, 15 April 2008 14:28  |
captainc
Messages: 278 Registered: December 2006 Location: New Jersey, USA
|
Experienced Member |
|
|
Why can I do this:
void CBTestFunc2(String foo, String bar){
Cout() << foo << " " << bar << "\n;"
}
Callback1<String> cb1 = callback1(&CBTestFunc2, "parameter 2"));
cb1("parameter 1");
But not:
void CBTestFunc3(String one, String two, String three){
Cout() << Format("%s %s %s", one, two, three);
}
Callback1<String> cb2 = callback2(&CBTestFunc3, "two", "three");
cb2("one");
?
The error is: Could not deduce template argument for Upp::Callback2<P1,P2>
|
|
|
Goto Forum:
Current Time: Mon May 12 16:18:29 CEST 2025
Total time taken to generate the page: 0.00817 seconds
|