summaryrefslogtreecommitdiff
path: root/gcc/ada/a-ngelfu.adb
diff options
context:
space:
mode:
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2009-10-30 13:27:40 +0000
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2009-10-30 13:27:40 +0000
commitec40265d92e9db6dd4fac77cbe77138c3a5ebc35 (patch)
tree854f726823e2af6587eb683f740988813fd28f9a /gcc/ada/a-ngelfu.adb
parentc6d4a1059abf96f88cbcc63b31b92a12d83b28af (diff)
downloadgcc-ec40265d92e9db6dd4fac77cbe77138c3a5ebc35.tar.gz
2009-10-30 Robert Dewar <dewar@adacore.com>
* a-tideio.adb: Minor reformatting * a-wtdeio.adb, a-ztdeio.adb: Update comments, code clean up. * a-reatim.adb, a-tideau.adb, a-ngelfu.adb, a-ztdeau.adb, a-ngrear.adb, a-wtedit.adb, a-ststio.adb, a-ztedit.adb: Minor code reorganization (use conditional expressions). 2009-10-30 Ed Schonberg <schonberg@adacore.com> * gnat_ugn.texi: Additional info on gnatw.i and gnatw.I * sem_case.adb: Improved error message. 2009-10-30 Emmanuel Briot <briot@adacore.com> * a-direct.adb, gnatcmd.adb, gnatname.adb, makeutl.adb, opt.ads, osint.adb, prj-ext.adb, switch-m.adb (Follow_Links_For_Dirs): Now defaults to False, and controlled by -eL. * a-direct.adb: Add comments. * osint.adb (File_Stamp): Avoid unneeded duplicate system call git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@153744 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/a-ngelfu.adb')
-rw-r--r--gcc/ada/a-ngelfu.adb19
1 files changed, 5 insertions, 14 deletions
diff --git a/gcc/ada/a-ngelfu.adb b/gcc/ada/a-ngelfu.adb
index ef9aadd4306..55d14e7db53 100644
--- a/gcc/ada/a-ngelfu.adb
+++ b/gcc/ada/a-ngelfu.adb
@@ -729,21 +729,12 @@ package body Ada.Numerics.Generic_Elementary_Functions is
Raw_Atan : Float_Type'Base;
begin
- if abs Y > abs X then
- Z := abs (X / Y);
- else
- Z := abs (Y / X);
- end if;
-
- if Z < Sqrt_Epsilon then
- Raw_Atan := Z;
+ Z := (if abs Y > abs X then abs (X / Y) else abs (Y / X));
- elsif Z = 1.0 then
- Raw_Atan := Pi / 4.0;
-
- else
- Raw_Atan := Float_Type'Base (Aux.Atan (Double (Z)));
- end if;
+ Raw_Atan :=
+ (if Z < Sqrt_Epsilon then Z
+ elsif Z = 1.0 then Pi / 4.0
+ else Float_Type'Base (Aux.Atan (Double (Z))));
if abs Y > abs X then
Raw_Atan := Half_Pi - Raw_Atan;