diff options
author | Robert Dewar <dewar@adacore.com> | 2009-04-16 10:13:09 +0000 |
---|---|---|
committer | Arnaud Charlet <charlet@gcc.gnu.org> | 2009-04-16 12:13:09 +0200 |
commit | bded454f79118e8b5b6627355d34bb29c795949d (patch) | |
tree | 369b35340cb5733a90b4f53ab439a3d41140e777 /gcc/ada/s-conca9.adb | |
parent | 4a3b249c3cda8d020bbbe3b03527f4b8af991fdf (diff) | |
download | gcc-bded454f79118e8b5b6627355d34bb29c795949d.zip gcc-bded454f79118e8b5b6627355d34bb29c795949d.tar.gz gcc-bded454f79118e8b5b6627355d34bb29c795949d.tar.bz2 |
Makefile.rtl: Add entries for s-conca?
2009-04-16 Robert Dewar <dewar@adacore.com>
* Makefile.rtl: Add entries for s-conca?
* debug.adb: Add debug flags -gnatd.c and -gnatd.C to control behavior
of concatenation expansion
* exp_ch4.adb (Expand_Concatenation): Generate calls for certain
string cases instead of expanding assignments inline.
* opt.ads (Optimize_Size): New flag
* s-conca2.ads, s-conca2.adb, s-conca3.adb, s-conca3.ads,
s-conca4.adb, s-conca4.ads, s-conca5.adb, s-conca5.ads, s-conca6.adb,
s-conca6.ads, s-conca7.ads, s-conca7.adb, s-conca8.adb, s-conca8.ads,
s-conca9.adb, s-conca9.ads: New file.
From-SVN: r146161
Diffstat (limited to 'gcc/ada/s-conca9.adb')
-rw-r--r-- | gcc/ada/s-conca9.adb | 88 |
1 files changed, 88 insertions, 0 deletions
diff --git a/gcc/ada/s-conca9.adb b/gcc/ada/s-conca9.adb new file mode 100644 index 0000000..34fcd9d --- /dev/null +++ b/gcc/ada/s-conca9.adb @@ -0,0 +1,88 @@ +------------------------------------------------------------------------------ +-- -- +-- GNAT RUN-TIME LIBRARY (GNARL) COMPONENTS -- +-- -- +-- S Y S T E M . C O N C A T _ 9 -- +-- -- +-- B o d y -- +-- -- +-- Copyright (C) 2008-2009, Free Software Foundation, Inc. -- +-- -- +-- GNAT is free software; you can redistribute it and/or modify it under -- +-- terms of the GNU General Public License as published by the Free Soft- -- +-- ware Foundation; either version 3, or (at your option) any later ver- -- +-- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- +-- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- +-- or FITNESS FOR A PARTICULAR PURPOSE. -- +-- -- +-- As a special exception under Section 7 of GPL version 3, you are granted -- +-- additional permissions described in the GCC Runtime Library Exception, -- +-- version 3.1, as published by the Free Software Foundation. -- +-- -- +-- You should have received a copy of the GNU General Public License and -- +-- a copy of the GCC Runtime Library Exception along with this program; -- +-- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- +-- <http://www.gnu.org/licenses/>. -- +-- -- +-- GNAT was originally developed by the GNAT team at New York University. -- +-- Extensive contributions were provided by Ada Core Technologies Inc. -- +-- -- +------------------------------------------------------------------------------ + +pragma Warnings (Off); +pragma Compiler_Unit; +pragma Warnings (On); + +package body System.Concat_9 is + + pragma Suppress (All_Checks); + + ------------------ + -- Str_Concat_9 -- + ------------------ + + procedure Str_Concat_9 + (R : out String; + S1, S2, S3, S4, S5, S6, S7, S8, S9 : String) + is + F, L : Natural; + + begin + F := R'First; + L := F + S1'Length - 1; + R (F .. L) := S1; + + F := L + 1; + L := F + S2'Length - 1; + R (F .. L) := S2; + + F := L + 1; + L := F + S3'Length - 1; + R (F .. L) := S3; + + F := L + 1; + L := F + S4'Length - 1; + R (F .. L) := S4; + + F := L + 1; + L := F + S5'Length - 1; + R (F .. L) := S5; + + F := L + 1; + L := F + S6'Length - 1; + R (F .. L) := S6; + + F := L + 1; + L := F + S7'Length - 1; + R (F .. L) := S7; + + F := L + 1; + L := F + S8'Length - 1; + R (F .. L) := S8; + + F := L + 1; + L := R'Last; + R (F .. L) := S9; + end Str_Concat_9; + +end System.Concat_9; |