mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2026-02-25 07:49:08 +01:00
+ support of octal literals
This commit is contained in:
parent
ac8c32c93d
commit
74303d74b1
@ -619,6 +619,11 @@ D [0-9]
|
||||
skip_until_eol;
|
||||
{D}+[Uu]?[Ll]?[Ll]? if NotInCPlusBlock then
|
||||
begin
|
||||
if yytext[1]='0' then
|
||||
begin
|
||||
delete(yytext,1,1);
|
||||
yytext:='&'+yytext;
|
||||
end;
|
||||
while yytext[length(yytext)] in ['L','U','l','u'] do
|
||||
Delete(yytext,length(yytext),1);
|
||||
return(NUMBER);
|
||||
|
||||
@ -634,6 +634,11 @@ begin
|
||||
7:
|
||||
if NotInCPlusBlock then
|
||||
begin
|
||||
if yytext[1]='0' then
|
||||
begin
|
||||
delete(yytext,1,1);
|
||||
yytext:='&'+yytext;
|
||||
end;
|
||||
while yytext[length(yytext)] in ['L','U','l','u'] do
|
||||
Delete(yytext,length(yytext),1);
|
||||
return(NUMBER);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user