sol2 icon indicating copy to clipboard operation
sol2 copied to clipboard

Occasional integer misrepresentation error when passing pointers to reference existing user defined types.

Open Nyoveee opened this issue 1 year ago • 0 comments

I am using LuaJit as my intepreter.

If the pointer is too large, this particular exception gets thrown. However, I am unable to control the value of my pointer, so not sure if there is any work around.

Tried using sol::optional<std::reference_wrapper<T>> as well, but the issue still comes up occasionally.

Not sure if the only solution is to use Lua 5.4 instead, where they support big integers now. Do I need the precision check? I would assume so since I need the exact value of the pointer.

Nyoveee avatar Nov 13 '24 08:11 Nyoveee