[URGENT]Hi, straight to the point:
I have the following class method :
class Graph
{
const std::set<size_t>& get_selected_nodes() const;
…
}the following binding to angelscript:
engine->RegisterObjectType("Graph", 0, asOBJ_REF);
engine->RegisterObjectMethod("Graph", "set<uint>@ get_selected_nodes()", asMETHOD(gph::Graph, get_selected_nodes), asCALL_THISCALL);engine->RegisterGlobalProperty("Graph g", g);
and i'm including and registering all the containers that are available in the angelscript repository.
The RegisterObjectMethod succeeds (i get no error when it happens)
Then i'm trying to run the following script:
g.get_selected_nodes().size(); i get crazy numbers, and with
set<uint>@ selected = g.get_selected_nodes();
for(auto it = selected.begin(); it++;)
{
print("" + it.current());
dfs_(it.current(), 0);
}i get crazy content.
Any idea on the possible cause?