diff options
author | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-02-25 15:02:01 +0000 |
---|---|---|
committer | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2014-02-25 15:02:01 +0000 |
commit | 8d2e29ed34fe8f6178750fac64c4d547cfb86b8c (patch) | |
tree | b93ba0ae89df95c49efac340d1747fd633893b68 /gcc | |
parent | 8f50bc39f3513ddd4fcf165bf1c01c6b5d06dc57 (diff) | |
download | gcc-8d2e29ed34fe8f6178750fac64c4d547cfb86b8c.tar.gz |
2014-02-25 Robert Dewar <dewar@adacore.com>
* sinfo.ads: Minor reformatting.
2014-02-25 Tristan Gingold <gingold@adacore.com>
* s-expllu.ads, s-expuns.ads, s-expmod.ads: Minor comment fix.
2014-02-25 Pascal Obry <obry@adacore.com>
* sinput-l.adb, osint.adb, osint.ads: Add Prep_Suffix to factorize code.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@208132 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ada/ChangeLog | 12 | ||||
-rw-r--r-- | gcc/ada/osint.adb | 13 | ||||
-rw-r--r-- | gcc/ada/osint.ads | 5 | ||||
-rw-r--r-- | gcc/ada/s-expllu.ads | 4 | ||||
-rw-r--r-- | gcc/ada/s-expmod.ads | 4 | ||||
-rw-r--r-- | gcc/ada/s-expuns.ads | 4 | ||||
-rw-r--r-- | gcc/ada/sinfo.ads | 98 | ||||
-rw-r--r-- | gcc/ada/sinput-l.adb | 8 |
8 files changed, 86 insertions, 62 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog index e3908c99f43..527a58f1899 100644 --- a/gcc/ada/ChangeLog +++ b/gcc/ada/ChangeLog @@ -1,3 +1,15 @@ +2014-02-25 Robert Dewar <dewar@adacore.com> + + * sinfo.ads: Minor reformatting. + +2014-02-25 Tristan Gingold <gingold@adacore.com> + + * s-expllu.ads, s-expuns.ads, s-expmod.ads: Minor comment fix. + +2014-02-25 Pascal Obry <obry@adacore.com> + + * sinput-l.adb, osint.adb, osint.ads: Add Prep_Suffix to factorize code. + 2014-02-25 Tristan Gingold <gingold@adacore.com> * sem_ch10.adb: Minor comment fix. diff --git a/gcc/ada/osint.adb b/gcc/ada/osint.adb index b9b03d45f6d..c30ed8c0d05 100644 --- a/gcc/ada/osint.adb +++ b/gcc/ada/osint.adb @@ -2190,6 +2190,19 @@ package body Osint is return GNAT_Time; end OS_Time_To_GNAT_Time; + ----------------- + -- Prep_Suffix -- + ----------------- + + function Prep_Suffix return String is + begin + if Hostparm.OpenVMS then + return "_prep"; + else + return ".prep"; + end if; + end Prep_Suffix; + ------------------ -- Program_Name -- ------------------ diff --git a/gcc/ada/osint.ads b/gcc/ada/osint.ads index f18a5ea97cc..e1c04c18467 100644 --- a/gcc/ada/osint.ads +++ b/gcc/ada/osint.ads @@ -677,7 +677,10 @@ package Osint is ALI_Default_Suffix : constant String_Ptr := new String'("ali"); ALI_Suffix : String_Ptr := ALI_Default_Suffix; - -- The suffixes used for the library files (also known as ALI files) + -- The suffixes used for the ALI files + + function Prep_Suffix return String; + -- The suffix used for pre-processed files private diff --git a/gcc/ada/s-expllu.ads b/gcc/ada/s-expllu.ads index e4c1ce9151c..d99215a46e0 100644 --- a/gcc/ada/s-expllu.ads +++ b/gcc/ada/s-expllu.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2009 Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2013, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -29,7 +29,7 @@ -- -- ------------------------------------------------------------------------------ --- This procedure performs exponentiation of unsigned types (with binary +-- This function performs exponentiation of unsigned types (with binary -- modulus values exceeding that of Unsigned_Types.Unsigned). The result -- is always full width, the caller must do a masking operation if the -- modulus is less than 2 ** (Long_Long_Unsigned'Size). diff --git a/gcc/ada/s-expmod.ads b/gcc/ada/s-expmod.ads index 99cf46ec754..73d845c8ee3 100644 --- a/gcc/ada/s-expmod.ads +++ b/gcc/ada/s-expmod.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2009 Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2013, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -29,7 +29,7 @@ -- -- ------------------------------------------------------------------------------ --- This procedure performs exponentiation of a modular type with non-binary +-- This function performs exponentiation of a modular type with non-binary -- modulus values. Arithmetic is done in Long_Long_Unsigned, with explicit -- accounting for the modulus value which is passed as the second argument. diff --git a/gcc/ada/s-expuns.ads b/gcc/ada/s-expuns.ads index 948330613f8..824327f270e 100644 --- a/gcc/ada/s-expuns.ads +++ b/gcc/ada/s-expuns.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2009 Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2013, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -29,7 +29,7 @@ -- -- ------------------------------------------------------------------------------ --- This procedure performs exponentiation of unsigned types (with binary +-- This function performs exponentiation of unsigned types (with binary -- modulus values up to and including that of Unsigned_Types.Unsigned). -- The result is always full width, the caller must do a masking operation -- the modulus is less than 2 ** (Unsigned'Size). diff --git a/gcc/ada/sinfo.ads b/gcc/ada/sinfo.ads index f9bf8a69094..ec4a3bdab9d 100644 --- a/gcc/ada/sinfo.ads +++ b/gcc/ada/sinfo.ads @@ -4573,16 +4573,16 @@ package Sinfo is -- the implicit label declaration which occurs in the innermost -- enclosing block. - -- Note: there is always a loop statement identifier present in - -- the tree, even if none was given in the source. In the case where - -- no loop identifier is given in the source, the parser creates - -- a name of the form _Loop_n, where n is a decimal integer (the - -- two underlines ensure that the loop names created in this manner - -- do not conflict with any user defined identifiers), and the flag - -- Has_Created_Identifier is set to True. The only exception to the - -- rule that all loop statement nodes have identifiers occurs for - -- loops constructed by the expander, and the semantic analyzer will - -- create and supply dummy loop identifiers in these cases. + -- Note: there is always a loop statement identifier present in the + -- tree, even if none was given in the source. In the case where no loop + -- identifier is given in the source, the parser creates a name of the + -- form _Loop_n, where n is a decimal integer (the two underlines ensure + -- that the loop names created in this manner do not conflict with any + -- user defined identifiers), and the flag Has_Created_Identifier is set + -- to True. The only exception to the rule that all loop statement nodes + -- have identifiers occurs for loops constructed by the expander, and + -- the semantic analyzer will create and supply dummy loop identifiers + -- in these cases. -- N_Loop_Statement -- Sloc points to LOOP @@ -4614,9 +4614,9 @@ package Sinfo is -- is present at a time, in which case the other one is empty. Both are -- empty in the case of a WHILE loop. - -- Gigi restriction: This expander ensures that the type of the - -- Condition field is always Standard.Boolean, even if the type - -- in the source is some non-standard boolean type. + -- Gigi restriction: The expander ensures that the type of the Condition + -- field is always Standard.Boolean, even if the type in the source is + -- some non-standard boolean type. -- N_Iteration_Scheme -- Sloc points to WHILE or FOR @@ -4675,12 +4675,12 @@ package Sinfo is -- or body; the block identifier denotes that E_Block. -- For block statements that come from source code, there is always a - -- block statement identifier present in the tree, denoting an - -- E_Block. In the case where no block identifier is given in the - -- source, the parser creates a name of the form B_n, where n is a - -- decimal integer, and the flag Has_Created_Identifier is set to - -- True. Blocks constructed by the expander usually have no identifier, - -- and no corresponding entity. + -- block statement identifier present in the tree, denoting an E_Block. + -- In the case where no block identifier is given in the source, + -- the parser creates a name of the form B_n, where n is a decimal + -- integer, and the flag Has_Created_Identifier is set to True. Blocks + -- constructed by the expander usually have no identifier, and no + -- corresponding entity. -- Note: the block statement created for an extended return statement -- has an entity, and this entity is an E_Return_Statement, rather than @@ -4716,9 +4716,9 @@ package Sinfo is -- EXIT_STATEMENT ::= exit [loop_NAME] [when CONDITION]; - -- Gigi restriction: This expander ensures that the type of the - -- Condition field is always Standard.Boolean, even if the type - -- in the source is some non-standard boolean type. + -- Gigi restriction: The expander ensures that the type of the Condition + -- field is always Standard.Boolean, even if the type in the source is + -- some non-standard boolean type. -- N_Exit_Statement -- Sloc points to EXIT @@ -4813,11 +4813,12 @@ package Sinfo is -- N_Designator -- Sloc points to period - -- Name (Node2) holds the parent unit name. Note that this is always - -- non-Empty, since this node is only used for the case where a - -- parent library unit package name is present. + -- Name (Node2) holds the parent unit name -- Identifier (Node1) + -- Note: Name is always non-Empty, since this node is only used for the + -- case where a parent library unit package name is present. + -- Note that the identifier can also be an operator symbol here ------------------------------ @@ -4834,33 +4835,34 @@ package Sinfo is -- DEFINING_PROGRAM_UNIT_NAME ::= -- [PARENT_UNIT_NAME .] DEFINING_IDENTIFIER - -- The parent unit name is present only in the case of a child unit - -- name (permissible only for Ada 95 for a library level unit, i.e. - -- a unit at scope level one). If no such name is present, the defining - -- program unit name is represented simply as the defining identifier. - -- In the child unit case, the following node is used to represent the - -- child unit name. + -- The parent unit name is present only in the case of a child unit name + -- (permissible only for Ada 95 for a library level unit, i.e. a unit + -- at scope level one). If no such name is present, the defining program + -- unit name is represented simply as the defining identifier. In the + -- child unit case, the following node is used to represent the child + -- unit name. -- N_Defining_Program_Unit_Name -- Sloc points to period - -- Name (Node2) holds the parent unit name. Note that this is always - -- non-Empty, since this node is only used for the case where a - -- parent unit name is present. + -- Name (Node2) holds the parent unit name -- Defining_Identifier (Node1) + -- Note: Name is always non-Empty, since this node is only used for the + -- case where a parent unit name is present. + -------------------------- -- 6.1 Operator Symbol -- -------------------------- -- OPERATOR_SYMBOL ::= STRING_LITERAL - -- Note: the fields of the N_Operator_Symbol node are laid out to - -- match the corresponding fields of an N_Character_Literal node. This - -- allows easy conversion of the operator symbol node into a character - -- literal node in the case where a string constant of the form of an - -- operator symbol is scanned out as such, but turns out semantically - -- to be a string literal that is not an operator. For details see - -- Sinfo.CN.Change_Operator_Symbol_To_String_Literal. + -- Note: the fields of the N_Operator_Symbol node are laid out to match + -- the corresponding fields of an N_Character_Literal node. This allows + -- easy conversion of the operator symbol node into a character literal + -- node in the case where a string constant of the form of an operator + -- symbol is scanned out as such, but turns out semantically to be a + -- string literal that is not an operator. For details see Sinfo.CN. + -- Change_Operator_Symbol_To_String_Literal. -- N_Operator_Symbol -- Sloc points to literal @@ -5020,11 +5022,11 @@ package Sinfo is -- PROCEDURE_CALL_STATEMENT ::= -- procedure_NAME; | procedure_PREFIX ACTUAL_PARAMETER_PART; - -- Note: the reason that a procedure call has expression fields is - -- that it semantically resembles an expression, e.g. overloading is - -- allowed and a type is concocted for semantic processing purposes. - -- Certain of these fields, such as Parens are not relevant, but it - -- is easier to just supply all of them together. + -- Note: the reason that a procedure call has expression fields is that + -- it semantically resembles an expression, e.g. overloading is allowed + -- and a type is concocted for semantic processing purposes. Certain of + -- these fields, such as Parens are not relevant, but it is easier to + -- just supply all of them together. -- N_Procedure_Call_Statement -- Sloc points to first token of name or prefix @@ -5161,8 +5163,8 @@ package Sinfo is -- [:= EXPRESSION] -- There are two entities associated with an extended_return_statement: - -- the Return_Statement_Entity represents the statement itself, and the - -- Defining_Identifier of the Object_Declaration in + -- the Return_Statement_Entity represents the statement itself, + -- and the Defining_Identifier of the Object_Declaration in -- Return_Object_Declarations represents the object being -- returned. N_Simple_Return_Statement has only the former. diff --git a/gcc/ada/sinput-l.adb b/gcc/ada/sinput-l.adb index b72278851b4..e2dbed3dfba 100644 --- a/gcc/ada/sinput-l.adb +++ b/gcc/ada/sinput-l.adb @@ -29,7 +29,6 @@ with Debug; use Debug; with Einfo; use Einfo; with Errout; use Errout; with Fname; use Fname; -with Hostparm; with Lib; use Lib; with Opt; use Opt; with Osint; use Osint; @@ -646,12 +645,7 @@ package body Sinput.L is begin Get_Name_String (N); - - if Hostparm.OpenVMS then - Add_Str_To_Name_Buffer ("_prep"); - else - Add_Str_To_Name_Buffer (".prep"); - end if; + Add_Str_To_Name_Buffer (Prep_Suffix); Delete_File (Name_Buffer (1 .. Name_Len), Status); |