On Sat Jun 17 18:37:45 2023 +0000, Rémi Bernon wrote:
Although it works I think you should also change the wg_format structure, moving enums declarations out of it and using fixed size type for the members. Same for some other structures which use bool, I don't think it has a standard defined fixed size. Using UINT8 would probably be better.
If things are compiled without packing/short enums we can expect common compilers to always choose between 32/64bit ints based on the values defined in the enum (Or if wine is C89 strict only 32bits are allowed). Similarly bools can be expected to be 8bits on common compilers.
Though replacing these types is fairly trivial and everything casts appropriately, i'm not sure how to represent the intended type after sizing things away. However if there are any existing conventions used for sizing these I can follow that would be reasonable.
Maybe its best to just assert the size of the struct like is done with `struct wg_parser_buffer` for structs with questionable sizes due to containing enums/bools?