UTBotCpp
UTBotCpp copied to clipboard
Nested structs as function parameters are not supported
Description In C we can use nested structs as function parameters without parent struct typename. But wrappers for such functions cannot be compiled with C++ compilers
Example
struct MainStruct {
struct InnerStruct {
int fld;
} str;
};
int get_fld(struct InnerStruct *str) {
return str->fld;
}
To Reproduce Steps to reproduce the behavior:
- Copy the example above to your project
- Generate tests for function
get_fld - Try to run generated tests
Expected behavior Tests are supposed to be executed successfully.
Actual behavior Compilation error.
Visual proofs (screenshots, logs)
error: variable has incomplete type 'struct InnerStruct'
struct InnerStruct expected_str = {