- register_function(name,
- [code](std::vector<std::string> args) { return std::bind(std::move(code), std::move(args)); });
+ kernel::actor::ActorCodeFactory code_factory = [code](std::vector<std::string> args) {
+ return std::bind(std::move(code), std::move(args));
+ };
+ register_function(name, std::move(code_factory));