mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-09-05 22:30:25 +02:00
* small tp7 fix
* fix void pointer with formaldef
This commit is contained in:
parent
c5e21bbc71
commit
1e89937590
@ -628,7 +628,7 @@ implementation
|
||||
end;
|
||||
valid_for_formal_var:=v;
|
||||
end;
|
||||
|
||||
|
||||
function valid_for_formal_const(p : ptree) : boolean;
|
||||
var
|
||||
v : boolean;
|
||||
@ -636,11 +636,12 @@ implementation
|
||||
{ p must have been firstpass'd before }
|
||||
{ accept about anything but not a statement ! }
|
||||
v:=true;
|
||||
if not assigned(p^.resulttype) or (p^.resulttype=voiddef) then
|
||||
if (p^.treetype in [calln,statementn]) then
|
||||
{ if not assigned(p^.resulttype) or (p^.resulttype=pdef(voiddef)) then }
|
||||
v:=false;
|
||||
valid_for_formal_const:=v;
|
||||
end;
|
||||
|
||||
|
||||
function is_procsym_load(p:Ptree):boolean;
|
||||
begin
|
||||
is_procsym_load:=((p^.treetype=loadn) and (p^.symtableentry^.typ=procsym)) or
|
||||
@ -683,7 +684,11 @@ implementation
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.22 1999-04-21 22:00:01 pierre
|
||||
Revision 1.23 1999-04-26 09:30:47 peter
|
||||
* small tp7 fix
|
||||
* fix void pointer with formaldef
|
||||
|
||||
Revision 1.22 1999/04/21 22:00:01 pierre
|
||||
+ valid_for_formal_var and valid_for_formal_const added
|
||||
|
||||
Revision 1.21 1999/04/21 16:31:40 pierre
|
||||
|
@ -277,7 +277,7 @@ implementation
|
||||
{ into a register }
|
||||
{ is this usefull here ? }
|
||||
{ this was missing in formal parameter list }
|
||||
if (defcoll^.data=cformaldef) then
|
||||
if (defcoll^.data=pdef(cformaldef)) then
|
||||
begin
|
||||
if defcoll^.paratyp=vs_var then
|
||||
if not valid_for_formal_var(p^.left) then
|
||||
@ -286,7 +286,7 @@ implementation
|
||||
if not valid_for_formal_const(p^.left) then
|
||||
CGMessage(parser_e_illegal_parameter_list);
|
||||
end;
|
||||
|
||||
|
||||
if defcoll^.paratyp=vs_var then
|
||||
begin
|
||||
set_unique(p^.left);
|
||||
@ -1149,7 +1149,11 @@ implementation
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.35 1999-04-21 21:49:18 pierre
|
||||
Revision 1.36 1999-04-26 09:30:46 peter
|
||||
* small tp7 fix
|
||||
* fix void pointer with formaldef
|
||||
|
||||
Revision 1.35 1999/04/21 21:49:18 pierre
|
||||
* previous log corrected
|
||||
|
||||
Revision 1.34 1999/04/21 16:31:46 pierre
|
||||
|
Loading…
Reference in New Issue
Block a user