
From: zeratul976@hotmail.com Date: Mon, 13 Feb 2012 22:25:51 +0000
A note: if you substitute using signature = R (Arg...); with: typedef R (Arg...) signature; you get a compile time error.
I believe the correct typedef syntax is:
typedef R signature(Arg...);
(This syntax never made sense to me, but it's the only one there was prior to C++11).
"signature" goes in the same place a function name would go. The inventors of C copiedthe "declaration the same as usage" syntax from B(PCL). I warned about making your programming syntax cute; it looks magnificent at first glance,but months later (or sooner) people discover ways the cuteness backfires. (Seestd::vector<bool>.) When I found out (a few months ago) how C got its declaration syntax,I realized that C and C++ programmers have been slammed for decades(!) over the inventor ofB being cute! Daryle W.