| 1 |
-- { dg-do compile } |
| 2 |
|
| 3 |
package body Frame_Overflow is |
| 4 |
|
| 5 |
function -- { dg-error "exceeds" } |
| 6 |
Set_In (Bitmap : Bitmap_T; Bitpos : Bitpos_Range_T) return Bitmap_T |
| 7 |
is |
| 8 |
Result: Bitmap_T := Bitmap; |
| 9 |
begin |
| 10 |
Result.Bits (Bitpos) := True; |
| 11 |
return Result; |
| 12 |
end; |
| 13 |
|
| 14 |
function -- { dg-error "exceeds" } |
| 15 |
Negate (Bitmap : Bitmap_T) return Bitmap_T |
| 16 |
is |
| 17 |
Result: Bitmap_T; |
| 18 |
begin |
| 19 |
for E in Bitpos_Range_T loop |
| 20 |
Result.Bits (E) := not Bitmap.Bits (E); |
| 21 |
end loop; |
| 22 |
return Result; |
| 23 |
end; |
| 24 |
|
| 25 |
end Frame_Overflow; |