Because this is not valid syntax.
He has nothing to do with union, that is, he will be the same for struct.
You are trying to use a member unionname as a name that is not valid. Names cannot contain a period ( .).
Initializations work because there is a mapping (view) of the initializer expression (right side) to the type of the left side, but this is not what you are trying to use on the last line.
I think this will work, and seems to be close:
data d2 = { .i = 20 };
C99 .