gcc/testsuite/gnat.dg/sso12.adb
raw| 1 | -- { dg-do compile } |
| 2 | |
| 3 | with Ada.Unchecked_Deallocation; |
| 4 | with System; |
| 5 | |
| 6 | procedure SSO12 is |
| 7 | type Rec is abstract tagged null record; |
| 8 | for Rec'Scalar_Storage_Order use System.High_Order_First; -- { dg-warning "scalar storage order specified but no component clause" } |
| 9 | for Rec'Bit_Order use System.High_Order_First; |
| 10 | |
| 11 | type Rec_Acc is access all Rec'Class; |
| 12 | |
| 13 | procedure Free is new Ada.Unchecked_Deallocation (Rec'Class, Rec_Acc); |
| 14 | X : Rec_Acc; |
| 15 | begin |
| 16 | Free (X); |
| 17 | end SSO12; |