+ Patch from Jeff Pohlmeyer to support multiline macros

This commit is contained in:
michael 2004-02-09 18:51:53 +00:00
parent 4fbee8aafc
commit ab4e8dfef4
2 changed files with 2422 additions and 2401 deletions

View File

@ -149,6 +149,8 @@ unit scan;
const
in_define : boolean = false;
{ True if define spans to the next line }
cont_line : boolean = false;
{ 1 after define; 2 after the ID to print the first separating space }
in_space_define : byte = 0;
arglevel : longint = 0;
@ -668,12 +670,31 @@ D [0-9]
\n begin
if in_define then
begin
in_define:=false;
in_space_define:=0;
return(NEW_LINE);
in_space_define:=0;
if cont_line then
begin
cont_line:=false;
end
else
begin
in_define:=false;
return(NEW_LINE);
end;
end;
end;
. begin
end;
\\$ begin
if in_define then
begin
cont_line:=true;
end
else
begin
writeln('Unexpected wrap of line ',yylineno);
writeln('"',yyline,'"');
return(256);
end;
end;
. begin
writeln('Illegal character in line ',yylineno);
writeln('"',yyline,'"');
return(256);

File diff suppressed because it is too large Load Diff