Possible Duplicate:
Looking for an easy way to reinitialize a struct
I dont actually know what my problem is called so I had not much luck searching for a solution.
I want to initialize a struct to an existing variable.
struct s { int i; };
s inst = { 7 }; // valid
inst = { 9 }; // invalid
How can I achieve something like this?