This is because it is simply not possible to return a reference to a temporary variable, at least in "reverse wrappers". Adding support for returning references is really hard. I suggest you just use std::string instead of std::string& as type. It will probably work just as well as long as you are not using it in a virtual method or attribute.
This is because it is simply not possible to return a reference to a temporary variable, at least in "reverse wrappers". Adding support for returning references is really hard. I suggest you just use std::string instead of std::string& as type. It will probably work just as well as long as you are not using it in a virtual method or attribute.