* fixed variant warning with was sometimes said with sets

This commit is contained in:
peter 1998-11-05 14:26:47 +00:00
parent 82aa9f9b00
commit 37732325f3
2 changed files with 24 additions and 19 deletions

View File

@ -270,7 +270,7 @@ implementation
firstadd, {starstarn} firstadd, {starstarn}
firstprocinline, {procinlinen} firstprocinline, {procinlinen}
firstarrayconstruct, {arrayconstructn} firstarrayconstruct, {arrayconstructn}
firstnothing, {arrayconstructrangen} firstarrayconstructrange, {arrayconstructrangen}
firstnothing, {nothingn} firstnothing, {nothingn}
firstloadvmt {loadvmtn} firstloadvmt {loadvmtn}
); );
@ -350,7 +350,10 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.96 1998-10-06 20:49:07 peter Revision 1.97 1998-11-05 14:26:47 peter
* fixed variant warning with was sometimes said with sets
Revision 1.96 1998/10/06 20:49:07 peter
* m68k compiler compiles again * m68k compiler compiles again
Revision 1.95 1998/09/24 15:13:44 peter Revision 1.95 1998/09/24 15:13:44 peter

View File

@ -29,6 +29,7 @@ interface
procedure firstload(var p : ptree); procedure firstload(var p : ptree);
procedure firstassignment(var p : ptree); procedure firstassignment(var p : ptree);
procedure firstfuncret(var p : ptree); procedure firstfuncret(var p : ptree);
procedure firstarrayconstructrange(var p:ptree);
procedure firstarrayconstruct(var p : ptree); procedure firstarrayconstruct(var p : ptree);
procedure firsttype(var p : ptree); procedure firsttype(var p : ptree);
@ -319,6 +320,19 @@ implementation
end; end;
{*****************************************************************************
FirstArrayConstructRange
*****************************************************************************}
procedure firstarrayconstructrange(var p:ptree);
begin
firstpass(p^.left);
firstpass(p^.right);
calcregisters(p,0,0,0);
p^.resulttype:=p^.left^.resulttype;
end;
{***************************************************************************** {*****************************************************************************
FirstArrayConstruct FirstArrayConstruct
*****************************************************************************} *****************************************************************************}
@ -357,10 +371,7 @@ implementation
pd:=hp^.left^.resulttype pd:=hp^.left^.resulttype
else else
if (not varia) and (not is_equal(pd,hp^.left^.resulttype)) then if (not varia) and (not is_equal(pd,hp^.left^.resulttype)) then
begin varia:=true;
varia:=true;
Comment(V_Warning,'Variant type found !!');
end;
inc(len); inc(len);
hp:=hp^.right; hp:=hp^.right;
end; end;
@ -373,18 +384,6 @@ implementation
end; end;
{*****************************************************************************
FirstArrayConstructRange
*****************************************************************************}
procedure firstarrayconstructrange(var p : ptree);
begin
{ This is not allowed, it's only to support sets when parsing the [a..b] }
Internalerror(4236);
Codegenerror:=true;
end;
{***************************************************************************** {*****************************************************************************
Type Type
*****************************************************************************} *****************************************************************************}
@ -399,7 +398,10 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.6 1998-10-19 08:55:12 pierre Revision 1.7 1998-11-05 14:26:48 peter
* fixed variant warning with was sometimes said with sets
Revision 1.6 1998/10/19 08:55:12 pierre
* wrong stabs info corrected once again !! * wrong stabs info corrected once again !!
+ variable vmt offset with vmt field only if required + variable vmt offset with vmt field only if required
implemented now !!! implemented now !!!