* introduction of in_generic in r20699 was unneeded, replaced by parse_generic

git-svn-id: trunk@20858 -
This commit is contained in:
florian 2012-04-12 21:53:10 +00:00
parent 4c472a1569
commit ce845bf97c
3 changed files with 2 additions and 13 deletions

View File

@ -178,10 +178,6 @@ interface
arrays, records and objects are checked recursively }
function is_valid_for_default(def:tdef):boolean;
{ returns true if currently a generic declaration or definition is parsed/compiled,
regardless if it's a subroutine or type }
function in_generic : boolean;
implementation
uses
@ -3018,11 +3014,4 @@ implementation
end;
function in_generic: boolean;
begin
result:=(assigned(current_structdef) and (df_generic in current_structdef.defoptions)) or
(assigned(current_procinfo) and (df_generic in current_procinfo.procdef.defoptions));
end;
end.

View File

@ -151,7 +151,7 @@ implementation
Message(parser_e_illegal_expression);
end;
else
if not(in_generic) then
if not(parse_generic) then
Message(parser_e_illegal_expression);
end;
current_tokenpos:=storetokenpos;

View File

@ -173,7 +173,7 @@ implementation
if is_constnode(n) then
IncompatibleTypes(n.resultdef, def)
else
if not(in_generic) then
if not(parse_generic) then
Message(parser_e_illegal_expression);
end;