1--  { dg-do compile }
2
3with Unchecked_Conversion;
4procedure warn2 is
5   type R1 is record X : Integer; end record;
6   type R2 is record X, Y : Integer; end record;
7   pragma Warnings
8     (Off, "types for unchecked conversion have different sizes");
9   function F is new Unchecked_Conversion (R1, R2);
10   pragma Warnings
11     (On, "types for unchecked conversion have different sizes");
12begin
13   null;
14end warn2;
15