Don't copy the node/way/segment/turn function objects for every call. 12-13% speedup for lua processing right there.

This commit is contained in:
Daniel Patterson
2017-06-12 18:40:17 +02:00
committed by Patrick Niklaus
parent 9d30817294
commit 5c8e2b6f78
2 changed files with 19 additions and 18 deletions
@@ -31,6 +31,11 @@ struct LuaScriptingContext final
bool has_way_function;
bool has_segment_function;
sol::function turn_function;
sol::function way_function;
sol::function node_function;
sol::function segment_function;
int api_version;
};