When expanding attribute Loop_Entry we create constant object
declarations and put them just before the loop. The current values of
variables at the point of Loop_Entry attribute must not be used when
analysing the initialization expressions of these constants, because
they might be different from
The problem is that the resolution of expanded names implicitly assumes
that the visible and private homonyms in a given scope are segregated on
the homonym chain, and this was no longer the case for equality operators
in the specific case at stake.
Tested on x86_64-pc-linux-gnu, committed on trun
This patch fixes an odd incomplete optimization within pragma
expressions. For example, in this code:
X := True;
pragma Assert (X = True);
pragma Assert (X);
the first assertion was eliminated by the frontend (regardless of the
optimization switches), while the second assertion was only
The parser skips the token without verifying it is indeed "access". So
any token is accepted.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* par-ch3.adb (P_Access_Type_Definition): Outputs an error if
token is not "access".diff --git a/gcc/ada/par-ch3.adb b/gcc/ada
Attribute Loop_Entry was initially only allowed to appear in pragmas
Loop_Variant and Loop_Invariant. Then it was also allowed to appear in
pragmas Assert, Assert_And_Cut and Assume, but this change was not
reflected in the GNAT RM.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
In some special cases involving class-wide pre/post conditions, Ada
allows a non-dispatching call to an abstract function (which is usually
illegal). Fix a bug in the implementation of Ada's rules about the
run-time behavior of such a call. Thanks to Javier Miranda for producing
this patch.
Teste
This has a couple of advantages: 1) the actions are analyzed with checks
disabled and 2) they are considered elaboration code by Sem_Elab.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* exp_ch13.adb (Expand_N_Freeze_Entity): Delete freeze nodes for
subprograms only
When the compiler is built with assertions enabled and processes the
following declarations:
type Vector_Boolean_Array is array (1 .. 10) of Boolean;
O2 : constant Vector_Boolean_Array := [for J in 2 => True];
The expression is rewritten by the frontend with an N_Raise_CE node,
which leads
The function Same_Object starts by taking the Original_Node of its
arguments.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* sem_ch5.adb (Analyze_Assignment): Remove superfluous call to
Original_Node.diff --git a/gcc/ada/sem_ch5.adb b/gcc/ada/sem_ch5.adb
--- a/gcc/a
The predicate is only concerned with the internal representation of types
and this representation is shared by the subtypes of a given type, so the
implementation can directly look into the (implementation) base types.
No functional changes.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/
More precisely, untagged record types, as tagged record types are already
handled by the predicate. If the derived type has not been given its own
representation clause, then the representations are the same.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* sem_ch13.adb (Has
When building gnat1 with `-gnatVa` as we do locally, rules like: `gcc -c
-gnatyM79 ` will throw a
constraint error as `lib.compiler_state` is initialized by par.adb, ie
after scanning. Therefore any error_msg thrown during scanning will
perform this uninitialized read (which raises a Constraint_Err
Add missing 's' and reformat the comment block.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* exp_ch7.adb: Fix typo.diff --git a/gcc/ada/exp_ch7.adb b/gcc/ada/exp_ch7.adb
--- a/gcc/ada/exp_ch7.adb
+++ b/gcc/ada/exp_ch7.adb
@@ -157,14 +157,14 @@ package body Exp_Ch7 is
Prevent creation of references to Abort_Undefer when aborts aren't
allowed. Another solution could have been an early return at
Expand_N_Asynchronous_Select's beginning, but this would break backends
that currently expect trees that do not contain any
N_Asynchronous_Selects in their AST (e.g. CodeP
After a period of experimentation, allow 'Reduce in Ada 2022 mode.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* sem_attr.adb (Analyze_Attribute [Attribute_Reduce]): Allow
'Reduce for Ada 2022 and above.
* sem_attr.ads (Attribute_Impl_Def): 'Reduce is no lo
This allows to resolve the following:
type Rec (<>) is private;
type Arr (<>) is private;
private
type Arr is array (Positive range <>) of Natural;
type Rec (L : Natural) is record
F1 : Integer;
F2 : Arr (1 .. L);
end record;
Tested on x86_64-pc-
The problem comes from the special instantiation (abbreviated instantiation
in GNAT parlance) done to check conformance between a formal package and its
corresponding actual in a generic instantiation: the compiler instantiates
the formal package, in the context of the generic instantiation, so tha
Allows binary search in sorted anonymous array (or array-like
container).
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* libgnat/g-binsea.ads, libgnat/g-binsea.adb
(GNAT.Binary_Search): New package.
* Makefile.rtl (GNATRTL_NONTASKING_OBJS): New item in list.
There are several debugging procedures called Output.w, and some
output-redirection features. This patch modifies Output.w so their
output is not redirected; it always goes to standard error. Otherwise,
debugging output can get mixed in with some "real" output (perhaps to a
file), which causes conf
This patch disallows N_Protected_Body from being passed to
Requires_Cleanup_Actions. Protected bodies never need cleanup, and are
never passed to Requires_Cleanup_Actions, which is a good thing, because
it would blow up on Handled_Statement_Sequence, which doesn't exist for
N_Protected_Body.
Teste
The original node is not guaranteed to also be an
N_Full_Type_Declaration, so the code needs to look into the node itself.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* exp_ch3.adb (Expand_N_Full_Type_Declaration): Look into N.diff --git a/gcc/ada/exp_ch3.adb b/gcc/ada/exp
Fix the Forced sign flag that is incorrectly ignored for scientific
notation and shortest representation.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* libgnat/g-forstr.adb (Is_Number): Add scientific notation and
shortest representation.diff --git a/gcc/ada/libgna
When the evaluation of the subtype_indication for the
iterator_specification of a quantified_expression leads to the insertion
of a type declaration, this should be done with Insert_Action instead of
Insert_Before.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* sem_ch5.adb
Put package GNAT.Binary_Search to predefined units list.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* impunit.adb: Add "g-binsea" to Non_Imp_File_Names_95 list.diff --git a/gcc/ada/impunit.adb b/gcc/ada/impunit.adb
--- a/gcc/ada/impunit.adb
+++ b/gcc/ada/impunit.adb
@@ -2
This patch cleans up some code that is left over from the front-end SJLJ
exception handling mechanism, which has been removed.
This is in preparation for fixing a finalization-related bug.
Most importantly:
The documentation is changed: a Handled_Sequence_Of_Statements node
CAN contain bo
When an allocator is for an access type that has a
Designated_Storage_Model aspect, and the designated type is an
unconstrained record type with discriminants, and the subtype associated
with the allocator is constrained, a dereference of the new access value
can be passed to the designated type's
For local subprograms without contracts inside generics, allow their
inlining for proof in GNATprove mode. This requires forbidding the
inlining of subprograms which contain references to object renamings,
which would be replaced in the SPARK expansion and violate assumptions
of the inlining code.
Improve the warning message and silence warning when size > 32, this is
likely intentional and does not warrant a warning.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* freeze.adb (Freeze_Enumeration_Type): Fix comment, enhance
message and silence warning for size
A previous commit implemented a new kernel registration scheme, using
the binder to generate registration code rather than inserting
registration code in packages. Now that this new approach has had time
to be thoroughly tested, it is time to remove the old approach.
Tested on x86_64-pc-linux-gnu
When flagging names of volatile objects occurring in actual parameters
it is safer to guard against identifiers without entity. This is
redundant (because earlier in the resolution of actual parameters we
already guard against actuals with Any_Type), but perhaps such
identifiers will become allowed
The compiler failed to detect an error where the first prefix of an
expanded name given as the renamed subprogram in a subprogram renaming
declaration denotes a unit with the same name as the name given for the
subprogram renaming. Such a unit must be hidden by the renaming itself.
An error check i
The QNX system specs for ARM and AARCH64 are identical. It makes more
sense to have it named for the base architecture.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* Makefile.rtl: Rename system-qnx-aarch64.ads to
system-qnx-arm.ads.
(AARCH64 QNX section): M
This avoids a useless walk of the prefix chain in instances.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* sem_ch8.adb (Analyze_Subprogram_Renaming): Move final test on
In_Instance to outer condition.diff --git a/gcc/ada/sem_ch8.adb b/gcc/ada/sem_ch8.adb
--- a/gcc/
Since we import the elemental math functions as intrinsics, it's not
accurate to state we're drawing them in from the C math library.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* libgnat/a-nagefl.ads: Replace mentions of C/unix math library
with intrinsics.
The Analyze_Associations.Check_Generic_Parent function was using an
incorrect node as the instanciation node for the actual, possibly
leading to incorrect freeze node being created (and later crashing in
gigi). Using Get_Unit_Instantiation_Node fixes the issue.
Tested on x86_64-pc-linux-gnu, commi
Should_Freeze_Type is relaxed to only take the relevant case into
account (entities denoted by generic actual parameters as per
13.14(5/3), as well as profile of any subprograms named as per
13.14(10.2/4)), instead of being overly conservative wrt instances and
as a result, wrongly rejecting some l
This adds a package renaming unit to the GNAT hierarchy so as to expose
the underlying implementation of floating-point mathematical functions,
thus also making it possible to use their vector implementation, if any.
The change also contains a small improvement to the Hide_Public_Entities
mechanis
When computing size of a static aggregate to decide if it should be
transformed into assignments and loops we could have an overflow check.
This is mostly harmless, because colossal aggregates will likely crash
the application anyway, no matter how we transform them.
This was not detected because
When a derived type DT has an untagged private parent type PT with a
discriminant, where the full type of PT is tagged, and DT inherits a
function F with an anonymous access result that designates the type, the
compiler wrongly reports an error saying that DT must be declared
abstract or F overridd
The compiler builds renamings for actuals of formal objects for debugging
purposes in this case, but it must not generate them for temporaries.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* exp_dbug.ads (Build_Subprogram_Instance_Renamings): Fix typo.
* exp_dbug.ad
When an object declaration is initialized with a type conversion:
Var : Typ := Typ (Value);
we skip the check for Typ's predicate as it is already checked
during the type conversion.
This is not correct when Var's subtype and the target subtype of the
conversion do not statically match:
Var :
SPARK RM 7.7(8) mandates that the freezing point of a tagged type must
occur within the so-called early call region of all its primitives.
This check may lead to spurious errors due to generated constructs being
considered in the search for the start of the early call region.
Tested on x86_64-pc-l
We need a couple of guards for boundary conditions in the support code.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* libgnat/s-dourea.adb ("/"): Add guard for zero and infinite
divisor.
* libgnat/s-valuer.adb (Scan_Raw_Real): Add guard for very large
The simple use of Ada.Tags triggers a dependency on the secondary stack
mechanism, which is unwanted on small embedded targets. To avoid this
dependency, we special case a-tags.ali in ALI.Scan_ALI to not set
Sec_Stack_Used. If some other code calls one of the functions returning
a string, this code
In Ada 2022, delta aggregate must use parentheses not square brackets
except array delta aggregates.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* gen_il-gen-gen_nodes.adb (Gen_IL.Gen.Gen_Nodes): Add
Is_Homogeneous_Aggregate field for N_Delta_Aggregate nodes.
This ACATS test shows that we need to call Is_Immutably_Limited_Type
in Analyze_Function_Return and also that we have a latent bug in
Is_Immutably_Limited_Type which shouldn't look through private types.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* sem_aux.adb (Is_Immutab
Update to latest version of Why3 caused some proof regressions.
Fix the proof by changing ghost code.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* libgnat/s-imagei.adb (Set_Digits): Add assertion.
* libgnat/s-imgboo.adb (Image_Boolean): Add assertions.
* l
When a tagged type T has aspect String_Literal, a derived type defines a
null extension T2, and the context to resolve the use of an object of
type T2 where the string literal is applicable is a class-wide type the
frontend crashes trying to evaluate if the object is a null extension.
This problem
For the sake of consistency with other similar manipulations.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* exp_ch7.adb (Build_BIP_Cleanup_Stmts): Use Needs_BIP_Alloc_Form.diff --git a/gcc/ada/exp_ch7.adb b/gcc/ada/exp_ch7.adb
--- a/gcc/ada/exp_ch7.adb
+++ b/gcc/ada/exp_ch
The conversion between OS and Ada priorties should be done in the wider
Interfaces.C.int type rather than Any_Priority otherwise
Constraint_Error will be raised when coverting Any_Priority'Last to int.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* libgnarl/s-osinte__qnx.ad
The error message issued for use of GNAT extension features without
specifying -gnatX (or pragma Extensions_Allowed) was confusing in the
presence of a pragma specifying a language version (such as "pragma
Ada_2022;"), because the pragma supersedes the switch. The message is
improved by testing fo
Currently, a 64-bit gnatsymbolize fails to output line numbers and
accurate symbol names when run on 32-bit executables (and vice-versa).
This is because a couple of spots in System.Dwarf_Lines expect the
Address_Size found in the DWARF data to match the host Address'Size.
This patch corrects that
Configure the arm-qnx runtime packages to avoid generating these
symbols.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* Makefile.rtl (arm-qnx): Use default (non-fma) target pair.diff --git a/gcc/ada/Makefile.rtl b/gcc/ada/Makefile.rtl
--- a/gcc/ada/Makefile.rtl
+++ b/gcc/a
Update to provers caused some proof regressions. Fix the proof by
changing ghost code.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* libgnat/s-valueu.adb (Scan_Raw_Unsigned): Add assertions.diff --git a/gcc/ada/libgnat/s-valueu.adb b/gcc/ada/libgnat/s-valueu.adb
--- a/gcc
Calls to various Vet functions are used throughout the containers
packages to check internal consistency. This patch improves efficiency
by disabling these calls when Container_Checks are suppressed.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* libgnat/a-crbtgo.ads, libgn
Fix compilation warning. The code was using a cast to struct sigcontext
*, which doesn't exist. It worked by accident.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* sigtramp-qnx.c: Change struct sigcontext * to mcontext_t *.diff --git a/gcc/ada/sigtramp-qnx.c b/gcc/ada/sig
Update to provers caused some proof regressions. Fix the proof by
adding an assertion.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* libgnat/s-imageu.adb (Set_Image_Unsigned): Change assertion.diff --git a/gcc/ada/libgnat/s-imageu.adb b/gcc/ada/libgnat/s-imageu.adb
--- a/
After changes in Why3 and generation of VCs, ghost code needs to be
adapted for proofs to remain automatic.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* libgnat/s-aridou.adb (Big3): Change return type.
(Lemma_Mult_Non_Negative, Lemma_Mult_Non_Positive): Reorder
Rewrite and base on VxWorks RTP implementation.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* sigtramp-arm-qnx.c: Rewrite.diff --git a/gcc/ada/sigtramp-arm-qnx.c b/gcc/ada/sigtramp-arm-qnx.c
--- a/gcc/ada/sigtramp-arm-qnx.c
+++ b/gcc/ada/sigtramp-arm-qnx.c
@@ -6,7 +6,7 @@
In GNAT AST the Scope field always points to the semantic scope (e.g.
subprogram) and never to syntactic scope (e.g. subprogram body).
Cleanup related to handling of circular access-to-record types.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* gcc-interface/decl.cc (gnat
No functional changes.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* gcc-interface/trans.cc (Subprogram_Body_to_gnu): Rename a couple
of local variables and use Is_Generic_Subprogram predicate.
(process_decls): Likewise.diff --git a/gcc/ada/gcc-interface/tr
No functional changes.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* gcc-interface/trans.cc: Fix formatting issues in comments.
(Subprogram_Body_to_gnu): Tidy up.
(Exception_Handler_to_gnu_gcc): Rename into...
(Exception_Handler_to_gnu): ...this.
This eliminates the use of the secondary stack to return composite types
with controlled components from functions, by exposing the return slot of
these functions through the support interface of memory pools, much like
for the secondary stack itself. This is piggybacked on the support of a
specif
This patch fixes a bug where the -gnatyr switch fails to detect
incorrect casing of record components.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* style.adb (Check_Identifier): Deal with the case where a
record component definition has been transformed; we want t
After changes in Why3 and generation of VCs, ghost code needs to be
adapted for proofs to remain automatic.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* libgnat/s-aridou.adb (Lemma_Abs_Range,
Lemma_Double_Shift_Left, Lemma_Shift_Left): New lemmas.
(Double_
Add support for Ada 2022's "[]" null array aggregates (thanks to Ed
Schonberg for producing most of this patch).
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* erroutc.ads: Fix a single-character typo in a comment.
* exp_aggr.adb: Fix a single-character typo in a co
This patch fixes a performance regression, introduced by a previous bug
fix. That fix had the unintended side effect of removing the
optimization in cases where the two operands are of two different
compiler-generated modular types.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
Update to provers caused some proof regressions. Fix the proof by
adding an assertion.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* libgnat/a-strfix.adb: Add assertions.
* libgnat/a-strsup.adb: Idem.diff --git a/gcc/ada/libgnat/a-strfix.adb b/gcc/ada/libgnat/a-st
Expansion of entry families contained a condition that was always true.
Cleanup related to detection of uninitialized scalar objects (which
uncovered that expansion of entry families creates a slightly illegal
AST with Elsif_Parts being an empty list).
Tested on x86_64-pc-linux-gnu, committed on t
Expansion of entry families created a slightly illegal AST with
Elsif_Parts being an empty list. Cleanup uncovered by the work on
detection of uninitialized scalars.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* exp_ch9.adb (Build_Find_Body_Index): Remove empty Elsif_Parts
The underlying issue is that the front-end does not create transient scopes
for return statements, so objects copied for these statements can never be
finalized properly.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* exp_ch6.adb (Expand_Call_Helper): Adjust comment.
In GNATprove mode we are don't want predicate failure to pollute the
predicate expression extracted from the predicate function.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* sem_ch13.adb (Build_Predicate_Function): Ignore predicate
failure in GNATprove mode.diff -
The run-time behavior of the Ada 2022 Predicate_Failure aspect was
incorrectly implemented. This could cause incorrect exception messages
at execution time in the case of a predicate check failure, as
demonstrated by ACATS test C324006. In addition, a new attribute
(Predicate_Expression) is defined
When the prefix of an Access attribute is an explicit dereference of an
access parameter (or a renaming of such a dereference, or a subcomponent
of such a dereference), the context is a general access type to a
class-wide interface type, and an accessibility check must be generated,
the frontend si
Instead of using that of Original_Node (N) after rewriting, which does not
work if N had previously been rewritten.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* exp_ch4.adb (Narrow_Large_Operation): Preserve and reuse Etype.diff --git a/gcc/ada/exp_ch4.adb b/gcc/ada/exp_c
This is needed in particular by GNAT LLVM builds.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* raise-gcc.c: Fix compilation with -DSTANDALONE under windows.diff --git a/gcc/ada/raise-gcc.c b/gcc/ada/raise-gcc.c
--- a/gcc/ada/raise-gcc.c
+++ b/gcc/ada/raise-gcc.c
@@ -78,7
Now that finalization and return on the secondary stack are decoupled, the
transient scopes created because of the former need not necessarily manage
the secondary stack and trigger a violation of the associated restriction.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* ex
The predicate is now a simple disjunction of two other predicates.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* sem_util.ads (Requires_Transient_Scope): Add pragma Inline.diff --git a/gcc/ada/sem_util.ads b/gcc/ada/sem_util.ads
--- a/gcc/ada/sem_util.ads
+++ b/gcc/ada/sem
When resolution of an expanded name fails, we call routine
Error_Missing_With_Of_Known_Unit which emits an error continuation
message (i.e. an error string starting with \\). However, for error
continuations to work properly there must be some prior error, because
continuation itself doesn't set fl
We flag illegal pragma Elaborate with a call to Error_Msg on the pragma
argument, which in turn calls Set_Error_Posted on the enclosing
statement, i.e. on the pragma itself. The explicit call to
Set_Error_Posted on the pragma itself was redundant.
Cleanup related to handling of illegal code when d
This makes it possible to pass the result to a C function directly.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* gcc-interface/utils.cc (unchecked_convert): Do not fold a string
constant if the target type is pointer to character.diff --git a/gcc/ada/gcc-interface
This creates a couple of record subtypes pointing to each other through
access subtypes, and we break the circularity at the latter subtypes.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* gcc-interface/decl.cc (gnat_to_gnu_entity) : If
it is a special subtype desig
The front-end properly computes a linear elaboration order for them, but
there was a loophole in the handling of the delayed case.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* gcc-interface/decl.cc (gnat_to_gnu_entity) : And
skip the elaboration of the designated
The message "No source file position information available" is displayed
in the bugbox when Current_Error_Node has no location, which is useless.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* gcc-interface/trans.cc (gnat_to_gnu): Do not set Current_Error_Node
to a
The issue arises when the unchecked union contains both a fixed part and
a variant part, and is subject to a full representation clause covering
all the components in all the variants, when the component clauses do not
align the variant boundaries with byte boundaries consistently.
Tested on x86_6
This alphabetizes the large switch statement, removes a useless nested
switch statement, an artificial fall through and adds a default return.
No functional changes.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* gcc-interface/trans.cc (gnat_gimplify_expr): Tidy up.diff --
The rationale is that these entities are almost always the result of
expansion activities in the front-end, over which the user has very
limited control. These warnings can be restored by means of -gnatD.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* gcc-interface/utils.c
Before removing them completely.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* gnatfind.adb, gnatxref.adb: Mark these tools as obsolete
before removing them completely.diff --git a/gcc/ada/gnatfind.adb b/gcc/ada/gnatfind.adb
--- a/gcc/ada/gnatfind.adb
+++ b/gcc/ada
To make it compatible with -gnatwE so that this warning is easier to
spot when needed.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* sem_ch6.adb (Check_Returns): Change message on missing return.diff --git a/gcc/ada/sem_ch6.adb b/gcc/ada/sem_ch6.adb
--- a/gcc/ada/sem_ch6.a
So that this unit can be used and called even before elaboration has
started, to ensure very early registration via e.g. C code.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* libgnarl/a-tasini.ads, libgnarl/a-tasini.adb: Make compatible
with No_Elaboration_Code_All
The current error message does not distinguish the component clause case
from the packed case, which can be confusing in the latter case.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* freeze.adb (Check_Component_Storage_Order): Give a specific error
message for non
Improve existing support for the Ada extension feature of casing on
composite values to handle casing on array values; in particular, casing
on an array value whose subtype is unconstrained (or dynamically
constrained) so that choices in the case statement may have differing
lengths. This commit do
When an if-expression is a condition in an outer decision, the compiler
may entirely encode the interplay between the two decisions, i.e. the
if-expression and the outer one, in the control-flow graph, effectively
creating branches that are shared between the two decisions.
This makes it very hard
'Image is too recent for bootstraping and shouldn't be used when
emitting error messages in any case.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* sem_case.adb (Composite_Case_Ops): Replace 'Image with
Error_Msg_Uint.diff --git a/gcc/ada/sem_case.adb b/gcc/ada/sem
Several inconsistencies were found. They will be submitted as separate
proposed fixes. The approach is to make them "types" rather than
"subtypes" in order to catch inconsistencies in their usage, and to
declare them in a central package. System.VxWorks.Ext was chosen, the
only difficulty with this
Int_Unlock/intUnlock is incorrectly declared as a function. In the
VxWorks headers intUnlock is type void.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* libgnarl/s-osinte__vxworks.ads: Make procedure vice function.
* libgnarl/s-vxwext.ads: Likewise.
* libgn
This name was changed in 2002 to stored discriminants, but some comments
and variable names were not converted.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* einfo.ads: Fix comments.
* exp_aggr.adb: Fix variable name.
* exp_util.adb: Fix comments.
*
It was still needed only because of bootstrap path considerations that
are obsolete after the recent overhaul of the bootstrap process.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* libgnat/s-imenne.ads, libgnat/s-imenne.adb: Delete.
* gcc-interface/Make-lang.in (G
An existing optimization substantially improves performance in the case
of checking for pattern matches where all possible matches are known to
start with the same character. Generalize this optimization to also
apply in the case of a case-insensitive comparison (so that there are
two possible init
Such as importing a package as was accepted by JGNAT, for use in
analyzers such as SPARK or CodePeer.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* sem_prag.adb (Process_Import_Or_Interface): Relax error when
Relaxed_RM_Semantics.diff --git a/gcc/ada/sem_prag.adb b
2901 - 3000 of 3426 matches
Mail list logo