Open loonycyborg opened 5 days ago
Can you tell me more exactly something you'd like to do with YS and c++?
I'm assuming you want to access a shared library from ys code, but maybe it's something else.
I'll also look at pybind11 for examples
I want to access api of the program that embeds YS, and also to make particular C++ variables/objects accessible depending on location in the yaml structure.
In python when you eval something you can provide your own locals and globals, thus you have control on what variables that code piece sees. I'm not sure how easily such control is accessible in YS in general.
Although you can just use YS C api from C++, there's some value in easing access to C++ objects from YS code by mapping them to YS concepts somehow, in same way as pybind11 maps C++ objects to python objects.