parts of !797: lua light userdata WIP
- Apr 17, 2019
-
-
-
-
The layer functions are supposed to return the new state. We've been lucky that errors are negative numbers and thus they typically passed the (status & KR_STATE_FAIL) test.
-
... for layers and props. This breaks C module API+ABI. It seemed weird to repeatedly call a function that returns a pointer to a structure in which we find the function we want to actually call. We've never used changing these functions AFAIK, and the target functions could easily be written to change their behavior instead (i.e. move the indirection *inside* the function). When breaking this, I also removed these two (_layers and _props) from the dynamic symbols (to be) exported from the C modules. They always pointed to memory belonging inside the module, and they seem quite sensible to be set up by the _init symbol instead.
-