A plain Lua table with typed field access.
Unlike Haxe anonymous structs, this creates tables without __fields__ metadata,
making them suitable for passing to Lua APIs that expect plain tables.
Example:
var opts = TableStruct.create({baz: 42, qux: "hello"});
opts.baz; // 42 - typed field access works
opts.qux; // "hello"
// Can be passed to APIs expecting AnyTable
function process(t:AnyTable):Void {}
process(opts); // works via implicit conversion
Note: Haxe reflection (Reflect.fields, etc.) will not work on TableStruct values
since they lack the __fields__ metadata that Haxe uses for reflection.
Static methods
staticinlinecreate<T>(obj:T):TableStruct<T>
Creates a plain Lua table from an anonymous struct.
The resulting table will not have __fields__ metadata, making it
compatible with Lua APIs that reject tables with extra fields.
staticinlinetoAnyTable(this:T):AnyTable
Converts to AnyTable for use with APIs that accept any table type.