package pak1 is type T1 is tagged null record; x1: T1; x2: T1'class := x1; x3: T1'class renames x1; --ERROR: (detected) T1'class vs T1 x4: T1 renames x2; --ERROR: (missed) T1 vs T1'class end pak1; $ gnatmake pak1 gcc-4.3 -c pak1.ads pak1.ads:5:25: expected type "T1'class" defined at line 2 pak1.ads:5:25: found type "T1" defined at line 2 gnatmake: "pak1.ads" compilation error RM 8.5.1(3) says "The type of the object_name shall resolve to the type determined by the subtype_mark." T and T'class are considered to be different types, and shouldn't match. There is flexibility in RM 8.6(23) for T'class to sometimes match T, but only when the rules provide an "expected type". But this flexibility doesn't apply when the rules say "shall resolve to", as in this case, without giving an expected type. This subtle wording distinction can also be seen in other places in the RM, such as 12.4(4) vs. 12.4(5).
$ gnatmake pak1 gcc-4.4 -c pak1.ads pak1.ads:5:25: expected type "T1'class" defined at line 2 pak1.ads:5:25: found type "T1" defined at line 2 pak1.ads:6:19: dynamically tagged expression not allowed gnatmake: "pak1.ads" compilation error So the bug is fixed in 4.4.