Browse Source

+ Added Ansistring setstring call

michael 26 years ago
parent
commit
65cd1cdbc7
2 changed files with 16 additions and 2 deletions
  1. 11 1
      rtl/inc/astrings.inc
  2. 5 1
      rtl/inc/systemh.inc

+ 11 - 1
rtl/inc/astrings.inc

@@ -631,9 +631,19 @@ begin
   FillChar(Pointer(StringOfChar)^,Length(StringOfChar),c);
 end;
 
+Procedure SetString (Var S : AnsiString; Buf : PChar; Len : Longint);
+
+begin
+  SetLength(S,Len);
+  Move (Buf[0],S[1],Len);
+end;
+
 {
   $Log$
-  Revision 1.35  1999-11-06 14:35:38  peter
+  Revision 1.36  1999-11-25 13:34:57  michael
+  + Added Ansistring setstring call
+
+  Revision 1.35  1999/11/06 14:35:38  peter
     * truncated log
 
   Revision 1.34  1999/11/02 23:57:54  peter

+ 5 - 1
rtl/inc/systemh.inc

@@ -217,6 +217,7 @@ Function  Pos(const substr:shortstring;const s:shortstring):StrLenInt;
 Function  Pos(C:Char;const s:shortstring):StrLenInt;
 Procedure SetLength(var s:shortstring;len:StrLenInt);
 Procedure SetString (Var S : Shortstring; Buf : PChar; Len : Longint);
+Procedure SetString (Var S : AnsiString; Buf : PChar; Len : Longint);
 Function  Length(s:string):byte;
 Function  upCase(const s:shortstring):shortstring;
 {$ifndef RTLLITE}
@@ -398,7 +399,10 @@ const
 
 {
   $Log$
-  Revision 1.67  1999-11-20 12:48:09  jonas
+  Revision 1.68  1999-11-25 13:34:57  michael
+  + Added Ansistring setstring call
+
+  Revision 1.67  1999/11/20 12:48:09  jonas
     * reinstated old random generator, but modified it so the integer
       one now has a much longer period