mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-20 19:29:26 +02:00
* Add RangeIndexError (delphi compatible)
This commit is contained in:
parent
081af9a892
commit
0533acdc27
@ -264,6 +264,7 @@ type
|
||||
procedure ListIndexError(aIndex,aMax: Integer; aObj: TObject);
|
||||
function ListIndexErrorMsg(aIndex, aMaxIndex: SizeInt; const aListObjName: string): string; overload;
|
||||
function ListIndexErrorMsg(aIndex, aMaxIndex: SizeInt; aListObj: TObject): string; overload;
|
||||
procedure RangeIndexError(aIndex, aMaxIndex: SizeInt; aListObj: TObject);
|
||||
|
||||
Type
|
||||
TBeepHandler = Procedure;
|
||||
|
@ -531,6 +531,12 @@ end;
|
||||
|
||||
{$pop} //{$S-} for Error handling functions
|
||||
|
||||
procedure RangeIndexError(aIndex, aMaxIndex: SizeInt; aListObj: TObject);
|
||||
|
||||
begin
|
||||
raise ERangeError.Create(ListIndexErrorMsg(aIndex,aMaxIndex,aListObj));
|
||||
end;
|
||||
|
||||
Procedure InitExceptions;
|
||||
{
|
||||
Must install uncaught exception handler (ExceptProc)
|
||||
|
Loading…
Reference in New Issue
Block a user