Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
baa3680f
Commit
baa3680f
authored
Jan 24, 2023
by
Rémi Bernon
Committed by
Alexandre Julliard
Mar 17, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
widl: Introduce a new helper to produce num tokens.
parent
a46facfd
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
8 deletions
+8
-8
parser.l
tools/widl/parser.l
+8
-8
No files found.
tools/widl/parser.l
View file @
baa3680f
...
...
@@ -131,6 +131,12 @@ struct uuid *parse_uuid(const char *u)
return uuid;
}
static int token_num( int token, const char *yytext, YYSTYPE *yylval )
{
yylval->num = xstrtoul( yytext, NULL, 0 );
return token;
}
%}
/*
...
...
@@ -227,14 +233,8 @@ SAFEARRAY{ws}*/\( return tSAFEARRAY;
^{ws}*\#{ws}* { yy_push_state(PP_LINE); }
\[ { yy_push_state(ATTR); return '['; }
{hex} {
yylval->num = xstrtoul(yytext, NULL, 0);
return aHEXNUM;
}
{int} {
yylval->num = xstrtoul(yytext, NULL, 0);
return aNUM;
}
{hex} { return token_num( aHEXNUM, yytext, yylval ); }
{int} { return token_num( aNUM, yytext, yylval ); }
\n { line_number++; }
{ws} {}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment