Commit 1037b0f4 by Arnaud Charlet

[multiple changes]

2014-02-24  Ed Schonberg  <schonberg@adacore.com>

	* s-dimmks.ads: Replace symbol for temperature, previously the
	Greek letter Theta, by the ASCII @ sign.
	* s-diflio.ads: ditto.

2014-02-24  Robert Dewar  <dewar@adacore.com>

	* exp_ch4.adb: Minor code reorganization (use OR for boolean
	variables).
	* sem_ch3.adb, sem_prag.adb, freeze.adb: Minor reformatting.

2014-02-24  Ben Brosgol  <brosgol@adacore.com>

	* gnat_ugn.texi, projects.texi: Added the necessary conditionalization
	so that references to gnatmem and ASIS tools do not appear in the FSF
	edition of the GNAT User's Guide.

From-SVN: r208071
parent ebb6b0bd
2014-02-24 Ed Schonberg <schonberg@adacore.com>
* s-dimmks.ads: Replace symbol for temperature, previously the
Greek letter Theta, by the ASCII @ sign.
* s-diflio.ads: ditto.
2014-02-24 Robert Dewar <dewar@adacore.com>
* exp_ch4.adb: Minor code reorganization (use OR for boolean
variables).
* sem_ch3.adb, sem_prag.adb, freeze.adb: Minor reformatting.
2014-02-24 Ben Brosgol <brosgol@adacore.com>
* gnat_ugn.texi, projects.texi: Added the necessary conditionalization
so that references to gnatmem and ASIS tools do not appear in the FSF
edition of the GNAT User's Guide.
2014-02-24 Yannick Moy <moy@adacore.com>
* freeze.adb (Freeze_Entity): Do not issue warning
......
......@@ -7615,7 +7615,7 @@ package body Exp_Ch4 is
-- arithmetic instructions check overflow automatically, so only
-- one version of the exponentiation unit is needed.
if Ovflo or else AAMP_On_Target then
if Ovflo or AAMP_On_Target then
Rent := RE_Exp_Long_Long_Integer;
else
Rent := RE_Exn_Long_Long_Integer;
......@@ -7628,7 +7628,7 @@ package body Exp_Ch4 is
-- arithmetic instructions check overflow automatically, so only
-- one version of the exponentiation unit is needed.
if Ovflo or else AAMP_On_Target then
if Ovflo or AAMP_On_Target then
Rent := RE_Exp_Integer;
else
Rent := RE_Exn_Integer;
......
......@@ -3871,9 +3871,9 @@ package body Freeze is
-- Pre/post conditions are implemented through a subprogram
-- in the corresponding body, and therefore are not checked on
-- an imported subprogram for which the body is not available.
-- This warning is not issued in GNATprove mode, as these
-- contracts are handled in formal verification, so the
-- warning would be misleading in that case.
-- This warning is not issued in GNATprove mode, as all these
-- contracts are handled in formal verification, so the warning
-- would be misleading in that case.
-- Could consider generating a wrapper to take care of this???
......@@ -3887,7 +3887,6 @@ package body Freeze is
("pre/post conditions on imported subprogram are not "
& "enforced??", E, Pre_Post_Conditions (Contract (E)));
end if;
end if;
-- Must freeze its parent first if it is a derived subprogram
......
......@@ -3166,6 +3166,7 @@ The following packages are currently supported in project files
but there are some general options that should be defined in this
package. @xref{Main Subprograms}, and @pxref{Executable File Names} in
particular.
@ifclear FSFEDITION
@item Check
This package specifies the options used when calling the checking tool
@command{gnatcheck} via the @command{gnat} driver. Its attribute
......@@ -3173,6 +3174,7 @@ The following packages are currently supported in project files
@code{Builder}. The first string should always be @code{-rules} to specify
that all the other options belong to the @code{-rules} section of the
parameters to @command{gnatcheck}.
@end ifclear
@item Clean
This package specifies the options used when cleaning a project or a project
tree using the tools @command{gnatclean} or @command{gprclean}.
......@@ -3184,11 +3186,13 @@ The following packages are currently supported in project files
@command{gnatxref} via the @command{gnat} driver. Its attributes
@b{Default_Switches} and @b{^Switches^Switches^} have the same semantics as for the
package @code{Builder}.
@ifclear FSFEDITION
@item Eliminate
This package specifies the options used when calling the tool
@command{gnatelim} via the @command{gnat} driver. Its attributes
@b{Default_Switches} and @b{^Switches^Switches^} have the same semantics as for the
package @code{Builder}.
@end ifclear
@item Finder
This package specifies the options used when calling the search tool
@command{gnatfind} via the @command{gnat} driver. Its attributes
......@@ -3197,11 +3201,13 @@ The following packages are currently supported in project files
@item ^Gnatls^Gnatls^
This package specifies the options to use when invoking @command{gnatls}
via the @command{gnat} driver.
@ifclear FSFEDITION
@item ^Gnatstub^Gnatstub^
This package specifies the options used when calling the tool
@command{gnatstub} via the @command{gnat} driver. Its attributes
@b{Default_Switches} and @b{^Switches^Switches^} have the same semantics as for the
package @code{Builder}.
@end ifclear
@item IDE
This package specifies the options used when starting an integrated
development environment, for instance @command{GPS} or @command{Gnatbench}.
......@@ -3211,22 +3217,26 @@ The following packages are currently supported in project files
@item Linker
This package specifies the options used by the linker.
@xref{Main Subprograms}.
@ifclear FSFEDITION
@item Metrics
This package specifies the options used when calling the tool
@command{gnatmetric} via the @command{gnat} driver. Its attributes
@b{Default_Switches} and @b{^Switches^Switches^} have the same semantics as for the
package @code{Builder}.
@end ifclear
@item Naming
This package specifies the naming conventions that apply
to the source files in a project. In particular, these conventions are
used to automatically find all source files in the source directories,
or given a file name to find out its language for proper processing.
@xref{Naming Schemes}.
@ifclear FSFEDITION
@item Pretty_Printer
This package specifies the options used when calling the formatting tool
@command{gnatpp} via the @command{gnat} driver. Its attributes
@b{Default_Switches} and @b{^Switches^Switches^} have the same semantics as for the
package @code{Builder}.
@end ifclear
@item Remote
This package is used by @command{gprbuild} to describe how distributed
compilation should be done.
......@@ -3648,20 +3658,30 @@ end MyProj;
* Project Level Attributes::
* Package Binder Attributes::
* Package Builder Attributes::
@ifclear FSFEDITION
* Package Check Attributes::
@end ifclear
* Package Clean Attributes::
* Package Compiler Attributes::
* Package Cross_Reference Attributes::
@ifclear FSFEDITION
* Package Eliminate Attributes::
@end ifclear
* Package Finder Attributes::
* Package ^gnatls^gnatls^ Attributes::
@ifclear FSFEDITION
* Package ^gnatstub^gnatstub^ Attributes::
@end ifclear
* Package IDE Attributes::
* Package Install Attributes::
* Package Linker Attributes::
@ifclear FSFEDITION
* Package Metrics Attribute::
@end ifclear
* Package Naming Attributes::
@ifclear FSFEDITION
* Package Pretty_Printer Attributes::
@end ifclear
* Package Remote Attributes::
* Package Stack Attributes::
* Package Synchronize Attributes::
......@@ -4310,6 +4330,7 @@ project tree.
@end itemize
@ifclear FSFEDITION
@node Package Check Attributes
@subsubsection Package Check Attributes
......@@ -4328,6 +4349,7 @@ Index is a source file name. Value is the list of switches to be used when
invoking @code{gnatcheck} for the source.
@end itemize
@end ifclear
@node Package Clean Attributes
@subsubsection Package Clean Attributes
......@@ -4619,6 +4641,7 @@ invoking @code{gnatxref} for the source.
@end itemize
@ifclear FSFEDITION
@node Package Eliminate Attributes
@subsubsection Package Eliminate Attributes
......@@ -4637,6 +4660,7 @@ Index is a source file name. Value is the list of switches to be used when
invoking @code{gnatelim} for the source.
@end itemize
@end ifclear
@node Package Finder Attributes
@subsubsection Package Finder Attributes
......@@ -4668,6 +4692,7 @@ Value is a list of switches to be used when invoking @code{gnatls}.
@end itemize
@ifclear FSFEDITION
@node Package ^gnatstub^gnatstub^ Attributes
@subsubsection Package ^gnatstub^gnatstub^ Attributes
......@@ -4686,6 +4711,7 @@ Index is a source file name. Value is the list of switches to be used when
invoking @code{gnatstub} for the source.
@end itemize
@end ifclear
@node Package IDE Attributes
@subsubsection Package IDE Attributes
......@@ -4878,6 +4904,7 @@ Value is the list of switches to specify a response file to the linker.
@end itemize
@ifclear FSFEDITION
@node Package Metrics Attribute
@subsubsection Package Metrics Attribute
......@@ -4896,6 +4923,7 @@ Index is a source file name. Value is the list of switches to be used when
invoking @code{gnatmetric} for the source.
@end itemize
@end ifclear
@node Package Naming Attributes
@subsubsection Package Naming Attributes
......@@ -4966,6 +4994,7 @@ be found in the source directories of the project.
@end itemize
@ifclear FSFEDITION
@node Package Pretty_Printer Attributes
@subsubsection Package Pretty_Printer Attributes
......@@ -4984,6 +5013,7 @@ Index is a source file name. Value is the list of switches to be used when
invoking @code{gnatpp} for the source.
@end itemize
@end ifclear
@node Package Remote Attributes
@subsubsection Package Remote Attributes
......
......@@ -6,7 +6,7 @@
-- --
-- S p e c --
-- --
-- Copyright (C) 2011-2012, Free Software Foundation, Inc. --
-- Copyright (C) 2011-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- --
......@@ -44,7 +44,7 @@
-- (Unit_Name => Kilogram, Unit_Symbol => "kg", Dim_Symbol => 'M'),
-- (Unit_Name => Second, Unit_Symbol => 's', Dim_Symbol => 'T'),
-- (Unit_Name => Ampere, Unit_Symbol => 'A', Dim_Symbol => 'I'),
-- (Unit_Name => Kelvin, Unit_Symbol => 'K', Dim_Symbol => "Θ"),
-- (Unit_Name => Kelvin, Unit_Symbol => 'K', Dim_Symbol => '@'),
-- (Unit_Name => Mole, Unit_Symbol => "mol", Dim_Symbol => 'N'),
-- (Unit_Name => Candela, Unit_Symbol => "cd", Dim_Symbol => 'J'));
......
......@@ -53,7 +53,7 @@ package System.Dim.Mks is
(Unit_Name => Kilogram, Unit_Symbol => "kg", Dim_Symbol => 'M'),
(Unit_Name => Second, Unit_Symbol => 's', Dim_Symbol => 'T'),
(Unit_Name => Ampere, Unit_Symbol => 'A', Dim_Symbol => 'I'),
(Unit_Name => Kelvin, Unit_Symbol => 'K', Dim_Symbol => "Θ"),
(Unit_Name => Kelvin, Unit_Symbol => 'K', Dim_Symbol => '@'),
(Unit_Name => Mole, Unit_Symbol => "mol", Dim_Symbol => 'N'),
(Unit_Name => Candela, Unit_Symbol => "cd", Dim_Symbol => 'J'));
......
......@@ -2381,8 +2381,7 @@ package body Sem_Ch3 is
elsif Nkind (Decl) = N_Subprogram_Body then
Analyze_Subprogram_Body_Contract (Defining_Entity (Decl));
elsif Nkind_In (Decl,
N_Subprogram_Declaration,
elsif Nkind_In (Decl, N_Subprogram_Declaration,
N_Abstract_Subprogram_Declaration)
then
Analyze_Subprogram_Contract (Defining_Entity (Decl));
......
......@@ -4456,7 +4456,13 @@ package body Sem_Prag is
("argument of pragma% must be protected procedure", Arg1);
end if;
if Parent (N) /= Protected_Definition (Parent (Proc_Scope)) then
-- For pragma case (as opposed to access case), check placement.
-- We don't need to do that for aspects, because we have the
-- check that they are apply an appropriate procedure.
if not From_Aspect_Specification (N)
and then Parent (N) /= Protected_Definition (Parent (Proc_Scope))
then
Error_Pragma ("pragma% must be in protected definition");
end if;
end if;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment