diff options
author | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-06-18 12:29:49 +0000 |
---|---|---|
committer | charlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4> | 2010-06-18 12:29:49 +0000 |
commit | c0501c1916723eec307d16451cfd94f0dbfb65fd (patch) | |
tree | 1005e9ee2894b1411be31e22a219e5ab16847f6c /gcc/ada/a-stunau.adb | |
parent | 503f7fd32934139e941744aac188fb5f5b9f75ff (diff) | |
download | gcc-c0501c1916723eec307d16451cfd94f0dbfb65fd.tar.gz |
* g-spipat.adb, a-swunau.adb, a-swunau.ads, g-spitbo.adb,
a-szunau.adb, a-szunau.ads, a-stunau.adb, a-stunau.ads,
a-strunb.adb (Big_String. Big_String_Access): New type.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@160981 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/a-stunau.adb')
-rw-r--r-- | gcc/ada/a-stunau.adb | 18 |
1 files changed, 5 insertions, 13 deletions
diff --git a/gcc/ada/a-stunau.adb b/gcc/ada/a-stunau.adb index e77f71c12b1..c6d2bc43ac3 100644 --- a/gcc/ada/a-stunau.adb +++ b/gcc/ada/a-stunau.adb @@ -37,11 +37,14 @@ package body Ada.Strings.Unbounded.Aux is procedure Get_String (U : Unbounded_String; - S : out String_Access; + S : out Big_String_Access; L : out Natural) is + X : aliased Big_String; + for X'Address use U.Reference.all'Address; + begin - S := U.Reference; + S := X'Unchecked_Access; L := U.Last; end Get_String; @@ -49,17 +52,6 @@ package body Ada.Strings.Unbounded.Aux is -- Set_String -- ---------------- - procedure Set_String (UP : in out Unbounded_String; S : String) is - begin - if S'Length > UP.Last then - Finalize (UP); - UP.Reference := new String (1 .. S'Length); - end if; - - UP.Reference (1 .. S'Length) := S; - UP.Last := S'Length; - end Set_String; - procedure Set_String (UP : in out Unbounded_String; S : String_Access) is begin Finalize (UP); |