]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
common: forward_handler() for handlers with move-only args
authorCasey Bodley <cbodley@redhat.com>
Tue, 10 Apr 2018 22:27:50 +0000 (18:27 -0400)
committerCasey Bodley <cbodley@redhat.com>
Wed, 9 May 2018 17:40:16 +0000 (13:40 -0400)
commitacf1374f887ed9ca3d650423eae9c56251fb52e7
treed97f02cbbd37f07ce409483abb4a8497866b8912
parent4b7ca701c7ca34e0b0b675ee468a59dbde70f061
common: forward_handler() for handlers with move-only args

executors will always call the handler's lvalue overload of operator(),
so forward_handler() is required to wrap calls to bind_handler() with
move-only argument types. Completion uses this to forward all of its
CompletionHandlers

Signed-off-by: Casey Bodley <cbodley@redhat.com>
src/common/async/completion.h
src/common/async/forward_handler.h [new file with mode: 0644]
src/test/common/test_async_completion.cc