CPP: Extend the unions test.

This commit is contained in:
Geoffrey White
2019-08-06 16:00:35 +01:00
parent cf20647765
commit 4ed559ee0b
3 changed files with 44 additions and 7 deletions

View File

@@ -21,3 +21,20 @@ struct EntryWithMethod: Entry {
return i;
}
};
void myFunction()
{
union MyLocalUnion {
int i;
float f;
};
}
class MyClass
{
public:
union MyNestedUnion {
int i;
float f;
};
};