The function Unique_Name did not actually compute a unique name for enumeration literals, because the type to which the literal belongs was not taken into account. This patch fixes the issue. Tested on x86_64-pc-linux-gnu, committed on trunk 2011-09-02 Johannes Kanig * sem_util.adb (Unique_Name): To obtain a unique name for enumeration literals, take into account the type name; the type is *not* the scope for an enumeration literal.