What is the use of a constant union object?

Viewed 5006

If I make a const union object (e.g in code below ), then no member assignment can be done in that. So is there any use of making a const union object, in any case ?

union un
{
    int i;
    float f;
    char c;
};
const union un a; 
/// ! a.i = 10; error.
2 Answers
Related