close
Skip to content

Make type registration dynamic #6

@candycode

Description

@candycode

Currently all the available types are pre-created statically when a context is created.

Move to a fully dynamic solution where types are added at run-time by specifying QArg and LArg constructors together with the type to add as done in QPy.

Steps to implement:

  1. Move QArgConstructor and LArgConstructor to separate include files
  2. Move QArgWrapper and LArgWrapper into a separate include file
  3. Change name of LuaArguments.h to LuaDefaultArguments.h - these are the types registered
    by default
  4. Make GenerateQArgWrappers and GenerateLArgWrappers private members of LuaContext
  5. Create a map between type names and *ArgConstructors to make it possible to check if a type conversion is supported and to retrieve the proper constructor given a type name

Note that (4) is required to access the type->constructor map declared as a private member of LuaContext

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions