Commit Graph

3 Commits

Author SHA1 Message Date
feos
d51d2a71d5 luaengine: reduce memory usage during compilation
Previous semantics were encouraged by sol2, and ThePhD admitted it was a bad idea for usertypes with lots of members. sol3 allows to assign members outside a constructor for regular usertypes, but mame can't move to sol3 because it requires C++17. Turns out sol2 also has a way to add members separately, and that is what I used. This helps immensely.

This approach required a fix to warning C5046 copied from here 5799084572

Tested current mame plugins, everything seems to work.

PS: Due to come black magic, if I use simple_usertype::set() with "manager" as well, "machine" member dies (others are fine!), so I had to leave it intact.
2019-10-19 11:37:01 +03:00
cracyc
a68d423992 luaengine: use initializers (nw) 2016-11-15 22:21:07 -06:00
Miodrag Milanovic
377472a6dd Added sol2 header only library as future replacement for luabridge (nw) 2016-10-07 14:43:09 +02:00