[Ada] Fix couple of bugs in the implementation of Round attribute
authorEric Botcazou <ebotcazou@adacore.com>
Wed, 18 Nov 2020 20:42:18 +0000 (21:42 +0100)
committerPierre-Marie de Rodat <derodat@adacore.com>
Mon, 14 Dec 2020 15:51:50 +0000 (10:51 -0500)
commit32543637450cd686a193fafc681501e930b66088
treef94651e3cd22a1334a315956b69e50b6e51a94f1
parentc2dc9fb66147830f1ca83206543bbef7f3966a40
[Ada] Fix couple of bugs in the implementation of Round attribute

gcc/ada/

* exp_attr.adb (Expand_N_Attribute_Reference) <Attribute_Round>:
Adjust commentary and set the Rounded_Result flag on the type
conversion node when the node is needed.
* exp_ch4.adb (Expand_N_Type_Conversion): Minor tweak.
(Fixup_Universal_Fixed_Operation): Look through the type conversion
only when it is to Universal_Real.
* exp_fixd.adb: Remove with and use clauses for Snames.
(Build_Divide): Remove redundant test.
(Expand_Convert_Float_To_Fixed): Use Rounded_Result flag on the
node to set the truncation parameter.
gcc/ada/exp_attr.adb
gcc/ada/exp_ch4.adb
gcc/ada/exp_fixd.adb