mirror of
https://gitlab.com/freepascal.org/fpc/pas2js.git
synced 2025-04-07 09:57:57 +02:00
* Remove some duplicates
This commit is contained in:
parent
75c570f2b2
commit
b7e3150635
@ -44,8 +44,8 @@ Function AnsiEndsStr(const ASubText, AText: string): Boolean;
|
||||
Function AnsiReplaceStr(const AText, AFromText, AToText: string): string;
|
||||
Function AnsiMatchStr(const AText: string; const AValues: array of string): Boolean;
|
||||
Function AnsiIndexStr(const AText: string; const AValues: array of string): Integer;
|
||||
Function MatchStr(const AText: UnicodeString; const AValues: array of UnicodeString): Boolean;
|
||||
Function IndexStr(const AText: UnicodeString; const AValues: array of UnicodeString): Integer;
|
||||
Function MatchStr(const AText: String; const AValues: array of String): Boolean;
|
||||
Function IndexStr(const AText: String; const AValues: array of String): Integer;
|
||||
|
||||
{ ---------------------------------------------------------------------
|
||||
Miscellaneous
|
||||
@ -357,13 +357,13 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
Function MatchStr(const AText: UnicodeString; const AValues: array of UnicodeString): Boolean;
|
||||
Function MatchStr(const AText: String; const AValues: array of String): Boolean;
|
||||
begin
|
||||
Result := IndexStr(AText,AValues) <> -1;
|
||||
end;
|
||||
|
||||
|
||||
Function IndexStr(const AText: UnicodeString; const AValues: array of UnicodeString): Integer;
|
||||
Function IndexStr(const AText: String; const AValues: array of String): Integer;
|
||||
var
|
||||
i: longint;
|
||||
begin
|
||||
@ -665,29 +665,6 @@ begin
|
||||
end;
|
||||
|
||||
|
||||
Function LeftStr(const AText: WideString; const ACount: SizeInt): WideString;
|
||||
begin
|
||||
Result:=Copy(AText,1,ACount);
|
||||
end;
|
||||
|
||||
|
||||
Function RightStr(const AText: WideString; const ACount: SizeInt): WideString;
|
||||
var
|
||||
j,l:SizeInt;
|
||||
begin
|
||||
l:=length(atext);
|
||||
j:=ACount;
|
||||
if j>l then j:=l;
|
||||
Result:=Copy(AText,l-j+1,j);
|
||||
end;
|
||||
|
||||
|
||||
Function MidStr(const AText: WideString; const AStart, ACount: SizeInt): WideString;
|
||||
begin
|
||||
Result:=Copy(AText,AStart,ACount);
|
||||
end;
|
||||
|
||||
|
||||
Function PosEx(const SubStr, S: string; Offset: SizeUint): SizeInt;
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user