Why are they so design? I am very confused.
Update: I really want to know the answer to the question. I am Googled, but I can not find anything useful.
I think there can be two reasons:
One : technical. Perhaps this is difficult to implement by the compiler (struct pass by reference). If the answer is this. Please explain this.
Two : useful for use (programming). As I think it is more elegant (or beautiful?), If the structure follows the link. I cannot find a few examples showing the advantage (strut pass by value). My programming career is not very long. In practice, I prefer to pass the struct function as a pointer (the pointer takes up less space on the stack).
source
share