+2016-05-02 Hristian Kirtchev <kirtchev@adacore.com>
+
+ * checks.adb, freeze.adb, sem_res.adb, s-stposu.adb, repinfo.adb:
+ Minor reformatting.
+
2016-05-02 Hristian Kirtchev <kirtchev@adacore.com>
* sem_ch4.adb (Find_Indexing_Operations): Use the underlying type
Make_Predicate_Check
(Typ, New_Occurrence_Of (Entity (N), Sloc (N))));
- -- If the expression is not an entity it may have side-effects,
- -- and the following call will create an object declaration for
- -- it. We disable checks during its analysis, to prevent an
- -- infinite recursion.
+ -- If the expression is not an entity it may have side-effects,
+ -- and the following call will create an object declaration for
+ -- it. We disable checks during its analysis, to prevent an
+ -- infinite recursion.
else
Insert_Action (N,
- Make_Predicate_Check (Typ, Duplicate_Subexpr (N)),
- Suppress => All_Checks);
+ Make_Predicate_Check
+ (Typ, Duplicate_Subexpr (N)), Suppress => All_Checks);
end if;
end if;
end if;
if Is_Packed_Array (Comp_Type) then
Error_Msg_N
- ("type of packed component must have same scalar "
- & "storage order as enclosing composite", Err_Node);
+ ("type of packed component must have same scalar storage "
+ & "order as enclosing composite", Err_Node);
-- Reject if composite is a packed array, as it may be rewritten
-- into an array of scalars.
elsif Is_Packed_Array (Encl_Type) then
- Error_Msg_N ("type of packed array must have same scalar "
- & "storage order as component", Err_Node);
+ Error_Msg_N
+ ("type of packed array must have same scalar storage order "
+ & "as component", Err_Node);
-- Reject if not byte aligned
elsif Is_Record_Type (Encl_Type)
- and then not Comp_Byte_Aligned
+ and then not Comp_Byte_Aligned
then
Error_Msg_N
("type of non-byte-aligned component must have same scalar "
elsif Present (ADC) and then No (Comp_ADC) then
Error_Msg_NE
- ("scalar storage order specified for& doesn''t "
- & "apply to component?", Err_Node, Encl_Type);
+ ("scalar storage order specified for & does not apply to "
+ & "component?", Err_Node, Encl_Type);
end if;
end if;
elsif Present (ADC) and then Component_Aliased then
Error_Msg_N
- ("aliased component not permitted for type with "
- & "explicit Scalar_Storage_Order", Err_Node);
+ ("aliased component not permitted for type with explicit "
+ & "Scalar_Storage_Order", Err_Node);
end if;
end Check_Component_Storage_Order;
-- a blank line precedes the output for a particular entity.
procedure List_Entities
- (Ent : Entity_Id;
+ (Ent : Entity_Id;
Bytes_Big_Endian : Boolean;
In_Subprogram : Boolean := False);
-- This procedure lists the entities associated with the entity E, starting
-------------------
procedure List_Entities
- (Ent : Entity_Id;
+ (Ent : Entity_Id;
Bytes_Big_Endian : Boolean;
In_Subprogram : Boolean := False)
is
-- Step 4: Attachment
if Is_Controlled then
- -- Note that we already did "Lock_Task.all;" in Step 2 above.
+
+ -- Note that we already did "Lock_Task.all;" in Step 2 above
-- Map the allocated memory into a FM_Node record. This converts the
-- top of the allocated bits into a list header. If there is padding
-- | |
-- +- Header_And_Padding --+
- N_Ptr := Address_To_FM_Node_Ptr
- (N_Addr + Header_And_Padding - Header_Size);
+ N_Ptr :=
+ Address_To_FM_Node_Ptr (N_Addr + Header_And_Padding - Header_Size);
-- Prepend the allocated object to the finalization master
exception
when others =>
- -- If we locked, we want to unlock
+
+ -- Unlock the task in case the allocation step failed and reraise the
+ -- exception.
if Is_Controlled then
Unlock_Task.all;
exception
when others =>
- -- If we locked, we want to unlock
+
+ -- Unlock the task in case the computations performed above
+ -- fail for some reason.
Unlock_Task.all;
raise;
Apply_Scalar_Range_Check (Expr, Typ);
end if;
- -- Finally, check whether a predicate applies to the target type.
- -- This comes from AI12-0100. As for type conversions, check the
- -- enclosing context to prevent an infinite expansion.
+ -- Finally, check whether a predicate applies to the target type. This
+ -- comes from AI12-0100. As for type conversions, check the enclosing
+ -- context to prevent an infinite expansion.
if Has_Predicates (Target_Typ) then
if Nkind (Parent (N)) = N_Function_Call