enums
don't introduce new scope.
In your example, the second enum
wouldn't compile due to the stuffA
name clash.
To avoid name clashes, it is a common practice to give the elements of an enum
a common prefix. Different prefixes would be used for different enums:
enum EnumA
{
EA_stuffA = 0
};
enum EnumAA
{
EAA_stuffA = 1
};
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…