mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-18 20:49:19 +02:00
* the checks for no parameters are not needed for Insert() and Delete() as they take care of that themselves with an overload listing
git-svn-id: trunk@37428 -
This commit is contained in:
parent
9d32f87ebb
commit
c01b36a2fa
@ -632,7 +632,7 @@ implementation
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
function inline_copy_insert_delete(nr:tinlinenumber;name:string) : tnode;
|
function inline_copy_insert_delete(nr:tinlinenumber;name:string;checkempty:boolean) : tnode;
|
||||||
var
|
var
|
||||||
paras : tnode;
|
paras : tnode;
|
||||||
{ for easy exiting if something goes wrong }
|
{ for easy exiting if something goes wrong }
|
||||||
@ -642,7 +642,7 @@ implementation
|
|||||||
consume(_LKLAMMER);
|
consume(_LKLAMMER);
|
||||||
paras:=parse_paras(false,false,_RKLAMMER);
|
paras:=parse_paras(false,false,_RKLAMMER);
|
||||||
consume(_RKLAMMER);
|
consume(_RKLAMMER);
|
||||||
if not assigned(paras) then
|
if not assigned(paras) and checkempty then
|
||||||
begin
|
begin
|
||||||
CGMessage1(parser_e_wrong_parameter_size,name);
|
CGMessage1(parser_e_wrong_parameter_size,name);
|
||||||
exit;
|
exit;
|
||||||
@ -654,19 +654,19 @@ implementation
|
|||||||
|
|
||||||
function inline_copy: tnode;
|
function inline_copy: tnode;
|
||||||
begin
|
begin
|
||||||
result:=inline_copy_insert_delete(in_copy_x,'Copy');
|
result:=inline_copy_insert_delete(in_copy_x,'Copy',true);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
function inline_insert: tnode;
|
function inline_insert: tnode;
|
||||||
begin
|
begin
|
||||||
result:=inline_copy_insert_delete(in_insert_x_y_z,'Insert');
|
result:=inline_copy_insert_delete(in_insert_x_y_z,'Insert',false);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
function inline_delete: tnode;
|
function inline_delete: tnode;
|
||||||
begin
|
begin
|
||||||
result:=inline_copy_insert_delete(in_delete_x_y_z,'Delete');
|
result:=inline_copy_insert_delete(in_delete_x_y_z,'Delete',false);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user