--TEST-- GH-7792 (Refer to enum as enum instead of class) --FILE-- --EXPECTF-- Fatal error: Enum Foo inherits both A::FOO and B::FOO, which is ambiguous in %s on line %d