Commit 378faa57 authored by Hugo Beauzée-Luyssen's avatar Hugo Beauzée-Luyssen

test: main.cpp: Ensure we don't move callbacks when an lvalue is provided

parent 3ef2529d
......@@ -87,8 +87,9 @@ int main(int ac, char** av)
std::cout << "Lambda called" << std::endl;
auto h1 = mp.eventManager().onTimeChanged(l);
auto h2 = mp.eventManager().onPositionChanged(l);
auto lFunc = std::function<void(float)>{ l };
auto h1 = mp.eventManager().onTimeChanged(lFunc);
auto h2 = mp.eventManager().onPositionChanged(lFunc);
std::this_thread::sleep_for( std::chrono::seconds( 2 ) );
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment