Explorar o código

+ Removed INTERNLENGTH/INTERNSETLENGTH defines

git-svn-id: trunk@257 -
michael %!s(int64=20) %!d(string=hai) anos
pai
achega
a20556e62d
Modificáronse 6 ficheiros con 0 adicións e 64 borrados
  1. 0 18
      rtl/inc/astrings.inc
  2. 0 4
      rtl/inc/sstrings.inc
  3. 0 4
      rtl/inc/system.inc
  4. 0 15
      rtl/inc/systemh.inc
  5. 0 6
      rtl/inc/wstringh.inc
  6. 0 17
      rtl/inc/wstrings.inc

+ 0 - 18
rtl/inc/astrings.inc

@@ -410,11 +410,7 @@ begin
     HandleErrorFrame(201,get_frame);
 end;
 
-{$ifndef INTERNSETLENGTH}
-Procedure SetLength (Var S : AnsiString; l : SizeInt);
-{$else INTERNSETLENGTH}
 Procedure fpc_AnsiStr_SetLength (Var S : AnsiString; l : SizeInt);[Public,Alias : 'FPC_ANSISTR_SETLENGTH'];  {$ifdef hascompilerproc} compilerproc; {$endif}
-{$endif INTERNSETLENGTH}
 {
   Sets The length of string S to L.
   Makes sure S is unique, and contains enough room.
@@ -496,20 +492,6 @@ end;
                      Public functions, In interface.
 *****************************************************************************}
 
-{$ifndef INTERNLENGTH}
-Function Length (Const S : AnsiString) : SizeInt;
-{
-  Returns the length of an AnsiString.
-  Takes in acount that zero strings are NIL;
-}
-begin
-  If Pointer(S)=Nil then
-    Length:=0
-  else
-    Length:=PAnsiRec(Pointer(S)-FirstOff)^.Len;
-end;
-{$endif INTERNLENGTH}
-
 
 {$ifdef HASCOMPILERPROC}
 Function fpc_ansistr_Unique(Var S : Pointer): Pointer; [Public,Alias : 'FPC_ANSISTR_UNIQUE']; {$ifdef hascompilerproc} compilerproc; {$endif}

+ 0 - 4
rtl/inc/sstrings.inc

@@ -15,11 +15,7 @@
                     subroutines for string handling
 ****************************************************************************}
 
-{$ifndef INTERNSETLENGTH}
-procedure SetLength(var s:shortstring;len:SizeInt);
-{$else INTERNSETLENGTH}
 procedure fpc_Shortstr_SetLength(var s:shortstring;len:SizeInt);[Public,Alias : 'FPC_SHORTSTR_SETLENGTH']; {$ifdef hascompilerproc} compilerproc; {$endif}
-{$endif INTERNSETLENGTH}
 begin
   if Len>255 then
    Len:=255;

+ 0 - 4
rtl/inc/system.inc

@@ -66,10 +66,6 @@ Function  hi(q : QWord) : DWord;  [INTERNPROC: fpc_in_hi_qword];
 Function  hi(i : Int64) : DWord;  [INTERNPROC: fpc_in_hi_qword];
 
 Function chr(b : byte) : Char;      [INTERNPROC: fpc_in_chr_byte];
-{$ifndef INTERNLENGTH}
-Function Length(s : string) : byte; [INTERNPROC: fpc_in_Length_string];
-Function Length(c : char) : byte;   [INTERNPROC: fpc_in_Length_string];
-{$endif INTERNLENGTH}
 
 Procedure Reset(var f : TypedFile);   [INTERNPROC: fpc_in_Reset_TypedFile];
 Procedure Rewrite(var f : TypedFile); [INTERNPROC: fpc_in_Rewrite_TypedFile];

+ 0 - 15
rtl/inc/systemh.inc

@@ -462,9 +462,6 @@ function strpas(p:pchar):shortstring;external name 'FPC_PCHAR_TO_SHORTSTR';
 function strlen(p:pchar):longint;external name 'FPC_PCHAR_LENGTH';
 
 { Shortstring functions }
-{$ifndef INTERNSETLENGTH}
-Procedure SetLength (Var S:ShortString;len:SizeInt);
-{$endif INTERNSETLENGTH}
 {$ifndef InternCopy}
 Function  Copy(const s:shortstring;index:SizeInt;count:SizeInt):shortstring;
 {$endif interncopy}
@@ -475,9 +472,6 @@ Function  Pos(const substr:shortstring;const s:shortstring):SizeInt;
 Function  Pos(C:Char;const s:shortstring):SizeInt;
 Procedure SetString (Var S : Shortstring; Buf : PChar; Len : SizeInt);
 Procedure SetString (Var S : AnsiString; Buf : PChar; Len : SizeInt);
-{$ifndef INTERNLENGTH}
-Function  Length(s:string):byte;
-{$endif INTERNLENGTH}
 Function  upCase(const s:shortstring):shortstring;
 Function  lowerCase(const s:shortstring):shortstring; overload;
 Function  Space(b:byte):shortstring;
@@ -501,22 +495,13 @@ Function  lowerCase(c:Char):Char; overload;
 function  copy(c:char;index : SizeInt;count : SizeInt): shortstring;
 {$endif interncopy}
 function  pos(const substr : shortstring;c:char): SizeInt;
-{$ifndef INTERNLENGTH}
-function  length(c:char):byte;
-{$endif INTERNLENGTH}
 
 
 {****************************************************************************
                              AnsiString Handling
 ****************************************************************************}
 
-{$ifndef INTERNSETLENGTH}
-Procedure SetLength (Var S : AnsiString; l : SizeInt);
-{$endif INTERNSETLENGTH}
 Procedure UniqueString(Var S : AnsiString);external name 'FPC_ANSISTR_UNIQUE';
-{$ifndef INTERNLENGTH}
-Function  Length (Const S : AnsiString) : SizeInt;
-{$endif INTERNLENGTH}
 {$ifndef InternCopy}
 Function  Copy (Const S : AnsiString; Index,Size : SizeInt) : AnsiString;
 {$endif interncopy}

+ 0 - 6
rtl/inc/wstringh.inc

@@ -15,13 +15,7 @@
  **********************************************************************}
 
 
-{$ifndef INTERNSETLENGTH}
-Procedure SetLength (Var S : WideString; l : SizeInt);
-{$endif INTERNSETLENGTH}
 procedure UniqueString(Var S : WideString);external name 'FPC_WIDESTR_UNIQUE';
-{$ifndef INTERNLENGTH}
-Function  Length (Const S : WideString) : SizeInt;
-{$endif INTERNLENGTH}
 {$ifndef InternCopy}
 Function  Copy (Const S : WideString; Index,Size : SizeInt) : WideString;
 {$endif interncopy}

+ 0 - 17
rtl/inc/wstrings.inc

@@ -734,11 +734,7 @@ begin
     HandleErrorFrame(201,get_frame);
 end;
 
-{$ifndef INTERNSETLENGTH}
-Procedure SetLength (Var S : WideString; l : SizeInt);
-{$else INTERNSETLENGTH}
 Procedure fpc_WideStr_SetLength (Var S : WideString; l : SizeInt);[Public,Alias : 'FPC_WIDESTR_SETLENGTH']; {$ifdef hascompilerproc} compilerproc; {$endif}
-{$endif INTERNSETLENGTH}
 {
   Sets The length of string S to L.
   Makes sure S is unique, and contains enough room.
@@ -832,19 +828,6 @@ procedure WideCharToStrVar(S : PWideChar;var Dest : AnsiString);
   end;
 
 
-{$ifndef INTERNLENGTH}
-Function Length (Const S : WideString) : SizeInt;
-{
-  Returns the length of an WideString.
-  Takes in acount that zero strings are NIL;
-}
-begin
-  If Pointer(S)=Nil then
-    Length:=0
-  else
-    Length:=PWideRec(Pointer(S)-WideFirstOff)^.Len;
-end;
-{$endif INTERNLENGTH}
 
 
 Function fpc_widestr_Unique(Var S : Pointer): Pointer; [Public,Alias : 'FPC_WIDESTR_UNIQUE']; {$ifdef hascompilerproc} compilerproc; {$endif}