Skip to content

Commit a39a65e

Browse files
committed
Eliminate warnings in micro:bit test files.
* test-microbit/circle.adb: add warnings round System.HardFault_Handling. * test-microbit/events.adb: likewise.
1 parent 4222b6a commit a39a65e

File tree

2 files changed

+13
-6
lines changed

2 files changed

+13
-6
lines changed

test-microbit/circle.adb

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
-- Copyright (C) 2018,2020 Free Software Foundation, Inc.
1+
-- Copyright (C) 2018-2021 Free Software Foundation, Inc.
22

33
-- This file is part of the Cortex GNAT RTS package.
44
--
@@ -16,8 +16,10 @@
1616
-- along with this program; see the file COPYING3. If not, see
1717
-- <http://www.gnu.org/licenses/>.
1818

19-
with Hardfault_Handling;
20-
pragma Unreferenced (Hardfault_Handling);
19+
pragma Warnings (Off, "internal GNAT unit");
20+
with System.Hardfault_Handling;
21+
pragma Warnings (On, "internal GNAT unit");
22+
pragma Unreferenced (System.Hardfault_Handling);
2123

2224
with Lights;
2325
pragma Unreferenced (Lights);

test-microbit/events.adb

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
-- Copyright (C) 2020 Free Software Foundation, Inc.
1+
-- Copyright (C) 2020-2021 Free Software Foundation, Inc.
22

33
-- This file is part of the Cortex GNAT RTS package.
44
--
@@ -18,8 +18,12 @@
1818

1919
with Event_Support;
2020
with Ada.Real_Time.Timing_Events;
21-
-- with Hardfault_Handling;
22-
-- pragma Unreferenced (Hardfault_Handling);
21+
22+
pragma Warnings (Off, "internal GNAT unit");
23+
with System.Hardfault_Handling;
24+
pragma Warnings (On, "internal GNAT unit");
25+
pragma Unreferenced (System.Hardfault_Handling);
26+
2327
procedure Events is
2428
-- Environment_Task_Storage_Size : constant Natural := 1536
2529
-- with
@@ -36,5 +40,6 @@ begin
3640
(Ada.Real_Time.Timing_Events.Timing_Event (Event_Support.Slow));
3741
Event_Support.Handler
3842
(Ada.Real_Time.Timing_Events.Timing_Event (Event_Support.Quick));
43+
3944
delay until Ada.Real_Time.Time_Last;
4045
end Events;

0 commit comments

Comments
 (0)