aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/switch.adb
diff options
context:
space:
mode:
authorArnaud Charlet <charlet@gcc.gnu.org>2009-07-15 15:06:43 +0200
committerArnaud Charlet <charlet@gcc.gnu.org>2009-07-15 15:06:43 +0200
commit9cd33a669fe96723b5d07c1b0bfa0b5a70dc03a3 (patch)
tree4820fcf687061774908146b6e2eb0f71c1669d73 /gcc/ada/switch.adb
parent6eab5a95753e09c22158046f43129d6a1c194af5 (diff)
downloadgcc-9cd33a669fe96723b5d07c1b0bfa0b5a70dc03a3.zip
gcc-9cd33a669fe96723b5d07c1b0bfa0b5a70dc03a3.tar.gz
gcc-9cd33a669fe96723b5d07c1b0bfa0b5a70dc03a3.tar.bz2
[multiple changes]
2009-07-15 Robert Dewar <dewar@adacore.com> * par_sco.adb (Traverse_Declarations_Or_Statements): Add processing for N_Label. Remove SCO table entry for entry point (not used). * par_sco.ads: Remove SCO entry point type (not used) * switch.adb: Minor code clean up. 2009-07-15 Eric Botcazou <ebotcazou@adacore.com> * exp_dbug.ads (Base Record Types): Document enhanced encoding. 2009-07-15 Thomas Quinot <quinot@adacore.com> * gnatls.adb: Minor reformatting * gnatcmd.adb: Minor code reorganization 2009-07-15 Ed Schonberg <schonberg@adacore.com> * exp_util.adb (Component_May_Be_Bit_Aligned): Use underlying type to determine whether a component of a private type has a composite type. From-SVN: r149688
Diffstat (limited to 'gcc/ada/switch.adb')
-rw-r--r--gcc/ada/switch.adb16
1 files changed, 8 insertions, 8 deletions
diff --git a/gcc/ada/switch.adb b/gcc/ada/switch.adb
index cb5c4d1..0c761b6 100644
--- a/gcc/ada/switch.adb
+++ b/gcc/ada/switch.adb
@@ -148,10 +148,10 @@ package body Switch is
begin
return Is_Switch (Switch_Chars)
and then
- (Switch_Chars (First .. Last) = "-param" or else
- Switch_Chars (First .. Last) = "dumpbase" or else
- Switch_Chars (First .. Last) = "auxbase-strip" or else
- Switch_Chars (First .. Last) = "auxbase");
+ (Switch_Chars (First .. Last) = "-param"
+ or else Switch_Chars (First .. Last) = "dumpbase"
+ or else Switch_Chars (First .. Last) = "auxbase-strip"
+ or else Switch_Chars (First .. Last) = "auxbase");
end Is_Internal_GCC_Switch;
---------------
@@ -169,15 +169,15 @@ package body Switch is
-----------------
function Switch_Last (Switch_Chars : String) return Natural is
- Last : constant Natural := Switch_Chars'Last;
+ Last : Natural := Switch_Chars'Last;
begin
if Last >= Switch_Chars'First
and then Switch_Chars (Last) = ASCII.NUL
then
- return Last - 1;
- else
- return Last;
+ Last := Last - 1;
end if;
+
+ return Last;
end Switch_Last;
-----------------