mirror of
https://github.com/boostorg/local_function.git
synced 2026-01-27 19:02:16 +00:00
Compiling all ScopeExit and LocalFunction tests and examples on GCC with and without type-of emulation mode.
Added LocalFunction configuration macro to force use or not use of locals as template parameters. [SVN r77765]
This commit is contained in:
@@ -7,6 +7,8 @@
|
||||
|
||||
#include <boost/local_function.hpp>
|
||||
#include <boost/noncopyable.hpp>
|
||||
#include <boost/typeof/typeof.hpp>
|
||||
#include BOOST_TYPEOF_INCREMENT_REGISTRATION_GROUP()
|
||||
#include <cassert>
|
||||
|
||||
//[noncopyable_local_function
|
||||
@@ -14,6 +16,7 @@ struct n: boost::noncopyable {
|
||||
int i;
|
||||
n(int _i): i(_i) {}
|
||||
};
|
||||
BOOST_TYPEOF_REGISTER_TYPE(n) // Register for `bind& x` below.
|
||||
|
||||
int main() {
|
||||
n x(-1);
|
||||
|
||||
Reference in New Issue
Block a user