What is untagged union?

C/C++ In C and C++, untagged unions are expressed nearly exactly like structures (structs), except that each data member begins at the same location in memory . The data members, as in structures, need not be primitive values, and in fact may be structures or even other unions.

Read more

How does a union struct work?

A struct is a block of memory that stores several data objects , where those objects don’t overlap. A union is a block of memory that stores several data objects, but has only storage for the largest of these, and thus can only store one of the data objects at any one time.

Read more