mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-08 04:48:07 +02:00
* show name of procedure/function called with too few parameters
git-svn-id: trunk@5522 -
This commit is contained in:
parent
c963543c74
commit
9e60d6791d
@ -414,7 +414,7 @@ parser_n_object_has_no_vmt=03023_N_The object "$1" has no VMT
|
||||
parser_e_illegal_parameter_list=03024_E_Illegal parameter list
|
||||
% You are calling a function with parameters that are of a different type than
|
||||
% the declared parameters of the function.
|
||||
parser_e_wrong_parameter_size=03026_E_Wrong number of parameters specified
|
||||
parser_e_wrong_parameter_size=03026_E_Wrong number of parameters specified for call to "$1"
|
||||
% There is an error in the parameter list of the function or procedure,
|
||||
% the number of parameters is not correct.
|
||||
parser_e_overloaded_no_procedure=03027_E_overloaded identifier "$1" isn't a function
|
||||
|
@ -704,7 +704,7 @@ const
|
||||
option_info=11024;
|
||||
option_help_pages=11025;
|
||||
|
||||
MsgTxtSize = 41751;
|
||||
MsgTxtSize = 41768;
|
||||
|
||||
MsgIdxMax : array[1..20] of longint=(
|
||||
24,82,226,79,62,47,102,22,135,60,
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -1799,7 +1799,7 @@ implementation
|
||||
internalerror(200402261);
|
||||
if not assigned(tparavarsym(procdefinition.paras[paraidx]).defaultconstsym) then
|
||||
begin
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,symtableprocentry.realname);
|
||||
goto errorexit;
|
||||
end;
|
||||
dec(paraidx);
|
||||
@ -1828,7 +1828,7 @@ implementation
|
||||
begin
|
||||
if assigned(pt) then
|
||||
current_filepos:=pt.fileinfo;
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,symtableprocentry.realname);
|
||||
goto errorexit;
|
||||
end;
|
||||
end
|
||||
@ -1881,7 +1881,7 @@ implementation
|
||||
begin
|
||||
if assigned(left) then
|
||||
current_filepos:=left.fileinfo;
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,symtableprocentry.realname);
|
||||
symtableprocentry.write_parameter_lists(nil);
|
||||
end;
|
||||
end;
|
||||
|
@ -148,7 +148,7 @@ implementation
|
||||
if not assigned(left) or
|
||||
(left.nodetype <> callparan) then
|
||||
begin
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,'Str');
|
||||
exit;
|
||||
end;
|
||||
|
||||
@ -165,7 +165,7 @@ implementation
|
||||
if (source=dest) or
|
||||
(cpf_is_colon_para in tcallparanode(dest).callparaflags) then
|
||||
begin
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,'Str');
|
||||
exit;
|
||||
end;
|
||||
|
||||
@ -307,6 +307,8 @@ implementation
|
||||
const
|
||||
procnames: array[boolean,boolean] of string[11] =
|
||||
(('write_text_','read_text_'),('typed_write','typed_read'));
|
||||
procnamesdisplay: array[boolean] of string[5] =
|
||||
('Write','Read');
|
||||
|
||||
var
|
||||
filepara,
|
||||
@ -477,7 +479,7 @@ implementation
|
||||
{ check for "no parameters" (you need at least one extra para for typed files) }
|
||||
if not assigned(para) then
|
||||
begin
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,procnamesdisplay[do_read]);
|
||||
found_error := true;
|
||||
end;
|
||||
|
||||
@ -905,7 +907,7 @@ implementation
|
||||
if not(assigned(left)) or
|
||||
not(assigned(tcallparanode(left).right)) then
|
||||
begin
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,'Val');
|
||||
exit;
|
||||
end;
|
||||
|
||||
|
@ -470,7 +470,7 @@ implementation
|
||||
consume(_RKLAMMER);
|
||||
if not assigned(paras) then
|
||||
begin
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,'SetLength');
|
||||
exit;
|
||||
end;
|
||||
|
||||
@ -489,7 +489,7 @@ implementation
|
||||
end;
|
||||
if dims=0 then
|
||||
begin
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,'SetLength');
|
||||
paras.free;
|
||||
exit;
|
||||
end;
|
||||
@ -523,7 +523,7 @@ implementation
|
||||
begin
|
||||
if not(is_dynamic_array(def)) then
|
||||
begin
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,'SetLength');
|
||||
break;
|
||||
end;
|
||||
dec(counter);
|
||||
@ -597,7 +597,7 @@ implementation
|
||||
consume(_RKLAMMER);
|
||||
if not assigned(paras) then
|
||||
begin
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,'Initialize');
|
||||
exit;
|
||||
end;
|
||||
|
||||
@ -605,7 +605,7 @@ implementation
|
||||
{ 2 arguments? }
|
||||
if assigned(ppn.right) then
|
||||
begin
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,'Initialize');
|
||||
paras.free;
|
||||
exit;
|
||||
end;
|
||||
@ -635,7 +635,7 @@ implementation
|
||||
consume(_RKLAMMER);
|
||||
if not assigned(paras) then
|
||||
begin
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,'Finalize');
|
||||
exit;
|
||||
end;
|
||||
|
||||
@ -647,7 +647,7 @@ implementation
|
||||
{ 3 arguments is invalid }
|
||||
if assigned(destppn.right) then
|
||||
begin
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,'Finalize');
|
||||
paras.free;
|
||||
exit;
|
||||
end;
|
||||
@ -694,7 +694,7 @@ implementation
|
||||
consume(_RKLAMMER);
|
||||
if not assigned(paras) then
|
||||
begin
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,'Copy');
|
||||
exit;
|
||||
end;
|
||||
|
||||
@ -728,7 +728,7 @@ implementation
|
||||
{ Only allow 1 or 3 arguments }
|
||||
if (counter<>1) and (counter<>3) then
|
||||
begin
|
||||
CGMessage(parser_e_wrong_parameter_size);
|
||||
CGMessage1(parser_e_wrong_parameter_size,'Copy');
|
||||
exit;
|
||||
end;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user