aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/lib.ads
diff options
context:
space:
mode:
authorRobert Dewar <dewar@adacore.com>2010-06-14 13:01:07 +0000
committerArnaud Charlet <charlet@gcc.gnu.org>2010-06-14 15:01:07 +0200
commit7eaa7cdf7da806ba900237e34eb11fd580039da3 (patch)
tree098473a5e47938dcfa8b53ff687d42c7e5548626 /gcc/ada/lib.ads
parent3a13e78582d1be59cd9e5ecb24f8f1c355261648 (diff)
downloadgcc-7eaa7cdf7da806ba900237e34eb11fd580039da3.zip
gcc-7eaa7cdf7da806ba900237e34eb11fd580039da3.tar.gz
gcc-7eaa7cdf7da806ba900237e34eb11fd580039da3.tar.bz2
ali.adb (Scan_ALI): Implement reading and storing of N lines
2010-06-14 Robert Dewar <dewar@adacore.com> * ali.adb (Scan_ALI): Implement reading and storing of N lines (Known_ALI_Lines): Add entry for 'N' (notes) * ali.ads (Notes): New table to store Notes information * alloc.ads: Add entries for Notes table * lib-util.adb (Write_Info_Int): New procedure (Write_Info_Slit): New procedure (Write_Info_Uint): New procedure * lib-util.ads (Write_Info_Int): New procedure (Write_Info_Slit): New procedure (Write_Info_Uint): New procedure * lib-writ.adb (Write_Unit_Information): Output N (notes) lines * lib-writ.ads: Update documentation for N (Notes) lines * lib.adb (Store_Note): New procedure * lib.ads (Notes): New table (Store_Note): New procedure * sem_prag.adb: Call Store_Note for affected pragmas From-SVN: r160736
Diffstat (limited to 'gcc/ada/lib.ads')
-rw-r--r--gcc/ada/lib.ads19
1 files changed, 19 insertions, 0 deletions
diff --git a/gcc/ada/lib.ads b/gcc/ada/lib.ads
index 9c36d91..4a956b5 100644
--- a/gcc/ada/lib.ads
+++ b/gcc/ada/lib.ads
@@ -574,6 +574,10 @@ package Lib is
-- This procedure is called to register the string from a pragma
-- Linker_Option. The argument is the Id of the string to register.
+ procedure Store_Note (N : Node_Id);
+ -- This procedure is called to register a pragma N for which a notes
+ -- entry is required.
+
procedure Initialize;
-- Initialize internal tables
@@ -733,6 +737,21 @@ private
Table_Increment => Alloc.Linker_Option_Lines_Increment,
Table_Name => "Linker_Option_Lines");
+ -- The following table stores references to pragmas that generate Notes
+
+ type Notes_Entry is record
+ Pragma_Node : Node_Id;
+ Unit : Unit_Number_Type;
+ end record;
+
+ package Notes is new Table.Table (
+ Table_Component_Type => Notes_Entry,
+ Table_Index_Type => Integer,
+ Table_Low_Bound => 1,
+ Table_Initial => Alloc.Notes_Initial,
+ Table_Increment => Alloc.Notes_Increment,
+ Table_Name => "Notes");
+
-- The following table records the compilation switches used to compile
-- the main unit. The table includes only switches. It excludes -o
-- switches as well as artifacts of the gcc/gnat1 interface such as