Thanks - I had missed that other thread earlier, I think…
In your example here, you define two functions, fun1 and fun2 in chaiscript.
Then in c++ you create two function ‘pointers’ (not sure if that’s technically the right term) to those functions?
So should that not read
std::function<int (int, int)> f1 = chai.eval<std::function<int (int, int)>>("fun1");
(I hope so, otherwise I am very confused!!)
Again, thanks for you help - I’m struggling because I’m pretty new to C++ and some of the syntax overwhelms me - but I’m getting there!