mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-07-26 03:26:13 +02:00
* Micro-optimization. Fix issue #39617
This commit is contained in:
parent
2f28c5596f
commit
2a19e152b7
@ -1476,6 +1476,8 @@ Var
|
|||||||
Obj : TObject;
|
Obj : TObject;
|
||||||
Str : String;
|
Str : String;
|
||||||
begin
|
begin
|
||||||
|
if (CurIndex=NewIndex) then
|
||||||
|
Exit;
|
||||||
BeginUpdate;
|
BeginUpdate;
|
||||||
Try
|
Try
|
||||||
Obj:=Objects[CurIndex];
|
Obj:=Objects[CurIndex];
|
||||||
@ -1485,7 +1487,7 @@ begin
|
|||||||
InsertObject(NewIndex,Str,Obj);
|
InsertObject(NewIndex,Str,Obj);
|
||||||
finally
|
finally
|
||||||
EndUpdate;
|
EndUpdate;
|
||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TStrings.Pop: string;
|
function TStrings.Pop: string;
|
||||||
|
Loading…
Reference in New Issue
Block a user