Hi all,
I'm not sure if this is a bug, because I am experimenting with C code generation for the first time in EA. (I use build 832.)
Parameter 'a' of a method 'polish' in class 'Class1' is defined as Type 'float' with Kind 'inout'. The problem is that the generated code for the function signature is 'float a'; I was expecting 'float* a'.
In more detail. When I change the parameter Kind from 'in' to 'inout', I see in the UML diagram that part of the method signature changes from 'float' to 'float*'. But when I generate that class to C, the result is always 'float', never 'float*' in both .h and .c files.
This UML signature
+ polish (this: Class1*, [inout] a: float, b: boolean): void
results in this generated .h code
void Class1_polish(Class1* this, float a, boolean b = false);
If I manually create c and h files with float* in the signature, and then synchronize code with model, the resulting parameter is describe as a parameter of Kind 'in' with Type 'float*'.
In C preferences the Reference Parameter Style is 'Pointer (*)'.
Very odd. Am I missing something?
Regards,
Owen