mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-17 19:11:03 +02:00
+ Final fixes: RightStr
This commit is contained in:
parent
2ffca0ba47
commit
7ed5f5cc10
@ -816,7 +816,7 @@ begin
|
|||||||
'X' : begin
|
'X' : begin
|
||||||
Checkarg(vtinteger,true);
|
Checkarg(vtinteger,true);
|
||||||
If Prec>32 then
|
If Prec>32 then
|
||||||
ToAdd:=HexStr(Args[Doarg].VInteger,Prec)
|
ToAdd:=HexStr(Args[Doarg].VInteger,32)
|
||||||
else
|
else
|
||||||
begin
|
begin
|
||||||
// determine minimum needed number of hex digits.
|
// determine minimum needed number of hex digits.
|
||||||
@ -1053,6 +1053,8 @@ end ;
|
|||||||
|
|
||||||
function RightStr(const S: string; Count: integer): string;
|
function RightStr(const S: string; Count: integer): string;
|
||||||
begin
|
begin
|
||||||
|
If Count>Length(S) then
|
||||||
|
Count:=Length(S);
|
||||||
result := Copy(S, 1 + Length(S) - Count, Count);
|
result := Copy(S, 1 + Length(S) - Count, Count);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
@ -1128,7 +1130,10 @@ const
|
|||||||
|
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.20 1999-05-31 20:50:45 peter
|
Revision 1.21 1999-06-05 20:47:03 michael
|
||||||
|
+ Final fixes: RightStr
|
||||||
|
|
||||||
|
Revision 1.20 1999/05/31 20:50:45 peter
|
||||||
* removed warnings
|
* removed warnings
|
||||||
|
|
||||||
Revision 1.19 1999/05/30 07:53:15 michael
|
Revision 1.19 1999/05/30 07:53:15 michael
|
||||||
|
Loading…
Reference in New Issue
Block a user