1--TEST-- 2GH-7821: Can't use arbitrary constant expressions in enum cases 3--FILE-- 4<?php 5 6interface I { 7 public const A = 'A'; 8 public const B = 'B'; 9} 10 11enum B: string implements I { 12 case C = I::A; 13 case D = self::B; 14} 15 16var_dump(B::A); 17var_dump(B::B); 18var_dump(B::C->value); 19var_dump(B::D->value); 20 21?> 22--EXPECT-- 23string(1) "A" 24string(1) "B" 25string(1) "A" 26string(1) "B" 27