Open maxdemarzi opened 2 years ago
I think a version of bug https://github.com/ThePhD/sol2/issues/155 has come back:
I have a bunch of overloaded functions that look like this and this works:
lua.set_function("LinksGetLinks", sol::overload( ... [this](std::vector<Link> links, const std::string& rel_type) { return this->LinksGetLinksForTypeViaLua(links, rel_type); }, ));
However if I flip the vector it to "const type&" I get "no matching function call takes this number of arguments and the specified types" just like issue #155 the string is unaffected.
lua.set_function("LinksGetLinks", sol::overload( .... [this](const std::vector<Link>& links, const std::string& rel_type) { return this->LinksGetLinksForTypeViaLua(links, rel_type); }, ));
Is this something that can be fixed or should I just start removing const type& from vectors everywhere?
const type&
I think a version of bug https://github.com/ThePhD/sol2/issues/155 has come back:
I have a bunch of overloaded functions that look like this and this works:
However if I flip the vector it to "const type&" I get "no matching function call takes this number of arguments and the specified types" just like issue #155 the string is unaffected.
Is this something that can be fixed or should I just start removing
const type&
from vectors everywhere?