Casting ActionData to long int error with GCC
Closed this issue · 4 comments
mik30s commented
Hi just tried to compile pinecone and i got this error with GCC (5.1).
src/Actions/FunctionAction.cpp:104:31: error: cast from 'ActionData*' to 'long int' loses precision [-fpermissive] name+="_"+to_string((long)&*action); ^
Thanks.
mik30s commented
Never mind, fixed it. I'm on a 64bit compiler so i had to use unsigned long long instead.
wmww commented
Thanks for pointing this issue out. This code is supposed to use a pointer to create a unique string that can be used in a transpiled C++ identifier. Your fix works, but I just implemented a much better way to go about this, so I won't be accepting your pull request.
mik30s commented
Mkay.
wmww commented
Fix is now pushed to master