You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
currently it is possible to construct struct types at comptime and before, with the
struct { ... };
likewise with functions.
However there is no way to directly work with the struct Type.
Let's say we wanted to add the field a: i32 to some c :: struct { b: i8 }.
Currently that isn't possble afaik, you could only do something similar with struct { c: c, a: i32 }.
The same thing can be said for functions
Proposed Solution
add some function addfield :: (ty: mut type, field: type) or addfield :: (ty: type, field: type) -> type
also maybe add some iterator/visitor for struct and function types