sol2
sol2 copied to clipboard
SIGSEGV when getting protected function from `sol::state`
trafficstars
build system
ubuntu 20.04
clang-12 with c++20
using Clion 2022.2.1
lua related
sol-3.2.2 with luajit-2.1
what I did
sol::protected_function foo = lua_state["bar"];
lua_state = std::move(new_state);
foo = lua_state["bar"]; //SIGSEGV here
expected behavior
no segfault
full script to reproduce
https://gist.github.com/skywalkerytx/87e46500fc2ceb2fa58eef99e203f4af