by userbinator · 8y ago · 0 comments
struct Foo foo = return_foo();
becomes struct Foo foo;
return_foo(&foo);
That said, the ability to pass, return, and assign structures by value seems to be one of the lesser-known features of C, so this serves as a good example.