Liste des Groupes | Revenir à cl c |
I took a different approach:But what happens with calling a external C function that has a struct X as parameter? (not pointer to struct)
In the backend IR stage, structs are essentially treated as references to the structure.
A local structure may be "initialized" via an IR operation, in which point it will be assigned storage in the stack frame, and the reference will be initialized to the storage area for the structure.
Most operations will pass them by reference.
Assigning a struct will essentially be turned into a struct-copy operation (using the same mechanism as inline memcpy).
Les messages affichés proviennent d'usenet.