aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/a-chahan.adb
diff options
context:
space:
mode:
authorRobert Dewar <dewar@adacore.com>2009-08-17 10:09:55 +0000
committerArnaud Charlet <charlet@gcc.gnu.org>2009-08-17 12:09:55 +0200
commit1d5a85bd838e6d42ca7315c3980b4f6d99f217a5 (patch)
tree413a1ca4724e02b6fd1f64e1fe14e1d496bbffa8 /gcc/ada/a-chahan.adb
parentb01bf852a0c2a50f5511c00c553eaed3b894ef05 (diff)
downloadgcc-1d5a85bd838e6d42ca7315c3980b4f6d99f217a5.zip
gcc-1d5a85bd838e6d42ca7315c3980b4f6d99f217a5.tar.gz
gcc-1d5a85bd838e6d42ca7315c3980b4f6d99f217a5.tar.bz2
a-caldel-vms.adb, [...]: Minor code reorganization (use conditional expressions).
2009-08-17 Robert Dewar <dewar@adacore.com> * a-caldel-vms.adb, a-calend-vms.adb, a-calfor.adb, a-cdlili.adb, a-chahan.adb, a-cidlli.adb, a-coinve.adb, a-comlin.adb: Minor code reorganization (use conditional expressions). From-SVN: r150834
Diffstat (limited to 'gcc/ada/a-chahan.adb')
-rw-r--r--gcc/ada/a-chahan.adb13
1 files changed, 3 insertions, 10 deletions
diff --git a/gcc/ada/a-chahan.adb b/gcc/ada/a-chahan.adb
index e6a9361..61419b0 100644
--- a/gcc/ada/a-chahan.adb
+++ b/gcc/ada/a-chahan.adb
@@ -457,11 +457,7 @@ package body Ada.Characters.Handling is
Substitute : ISO_646 := ' ') return ISO_646
is
begin
- if Item in ISO_646 then
- return Item;
- else
- return Substitute;
- end if;
+ return (if Item in ISO_646 then Item else Substitute);
end To_ISO_646;
function To_ISO_646
@@ -472,11 +468,8 @@ package body Ada.Characters.Handling is
begin
for J in Item'Range loop
- if Item (J) in ISO_646 then
- Result (J - (Item'First - 1)) := Item (J);
- else
- Result (J - (Item'First - 1)) := Substitute;
- end if;
+ Result (J - (Item'First - 1)) :=
+ (if Item (J) in ISO_646 then Item (J) else Substitute);
end loop;
return Result;