sol2
sol2 copied to clipboard
Crash during destruction when using meta_function::new_index and coroutines
I attached a reproduction example to the ticket: main.cpp.txt
The example crashes during the m_entries.clear();
in the ~MyDynamic()
destructor.
The crash only occurs if the test()
function is started as a coroutine.
I sadly don't know enough about lua to see if this is a problem with lua itself, or something in sol2. Any help/hints would be greatly appreciated.
Build and reproduced on macOS 14,
clang++ --version e0bb8f0 ✭ ✱ ◼
Apple clang version 15.0.0 (clang-1500.3.9.4)
Target: arm64-apple-darwin23.2.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin