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
f0f179dd
Commit
f0f179dd
authored
Sep 26, 2005
by
Francois Gouget
Committed by
Alexandre Julliard
Sep 26, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
volatile is valid everywhere const is valid.
parent
b25c266d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
c_parser.pm
tools/winapi/c_parser.pm
+6
-6
No files found.
tools/winapi/c_parser.pm
View file @
f0f179dd
...
...
@@ -1110,7 +1110,7 @@ sub parse_c_file($$$$) {
$declaration
.=
$&
;
if
(
$declaration
=~
/^typedef/s
||
$declaration
=~
/^(?:const\s+|extern\s+|static\s+)*(?:struct|union)(?:\s+\w+)?\s*\{/s
)
$declaration
=~
/^(?:const\s+|extern\s+|static\s+
|volatile\s+
)*(?:struct|union)(?:\s+\w+)?\s*\{/s
)
{
# Nothing
}
elsif
(
$plevel
==
1
&&
$blevel
==
1
)
{
...
...
@@ -1128,7 +1128,7 @@ sub parse_c_file($$$$) {
$declaration
.=
$&
;
if
(
0
&&
$blevel
==
1
&&
$declaration
!~
/^typedef/
&&
$declaration
!~
/^(?:const\s+|extern\s+|static\s+)?(?:struct|union)(?:\s+\w+)?\s*\{/s
&&
$declaration
!~
/^(?:const\s+|extern\s+|static\s+
|volatile\s+
)?(?:struct|union)(?:\s+\w+)?\s*\{/s
&&
$declaration
=~
/^(?:\w+(?:\s*\*)*\s+)*(\w+)\s*\(\s*(?:(?:\w+\s*,\s*)*(\w+))?\s*\)\s*(.*?);$/s
&&
$1
ne
"ICOM_VTABLE"
&&
defined
(
$2
)
&&
$2
ne
"void"
&&
$3
)
# K&R
{
...
...
@@ -1233,7 +1233,7 @@ sub parse_c_function($$$$$) {
# FIXME: ???: Old variant of __attribute((const))
$self
->
_parse_c
(
'
const
'
,
\
$_
,
\
$line
,
\
$column
);
$self
->
_parse_c
(
'
(?:const|volatile)
'
,
\
$_
,
\
$line
,
\
$column
);
if
(
!
$self
->
_parse_c
(
'(?:operator\s*!=|(?:MSVCRT|WS)\(\s*\w+\s*\)|\w+)'
,
\
$_
,
\
$line
,
\
$column
,
\
$name
))
{
return
0
;
...
...
@@ -1781,7 +1781,7 @@ sub parse_c_type($$$$$) {
my
$type
;
$self
->
_parse_c
(
"
const
"
,
\
$_
,
\
$line
,
\
$column
);
$self
->
_parse_c
(
"
(?:const|volatile)
"
,
\
$_
,
\
$line
,
\
$column
);
if
(
0
)
{
# Nothing
...
...
@@ -1998,7 +1998,7 @@ sub parse_c_variable($$$$$$$) {
}
$finished
=
1
;
}
elsif
(
s/^((?:enum\s+|struct\s+|union\s+)?\w+\b(?:\s+DECLSPEC_ALIGN\(.*?\)|\s*(?:const\s*)?\*)*)\s*(\w+)\s*(\[.*?\]$|:\s*(\d+)$|\{)?//s
)
{
}
elsif
(
s/^((?:enum\s+|struct\s+|union\s+)?\w+\b(?:\s+DECLSPEC_ALIGN\(.*?\)|\s*(?:const\s*
|volatile\s*
)?\*)*)\s*(\w+)\s*(\[.*?\]$|:\s*(\d+)$|\{)?//s
)
{
$type
=
"$sign$1"
;
$name
=
$2
;
...
...
@@ -2091,7 +2091,7 @@ sub parse_c_variable($$$$$$$) {
if
(
!
s/^(?:=\s*|,\s*|$)//
)
{
return
0
;
}
}
elsif
(
s/^(?:\*\s*)*(?:const\s+)?(\w+)\s*(?:\[[^\]]*\]\s*)*\s*(?:=\s*|,\s*|$)//
)
{
}
elsif
(
s/^(?:\*\s*)*(?:const\s+
|volatile\s+
)?(\w+)\s*(?:\[[^\]]*\]\s*)*\s*(?:=\s*|,\s*|$)//
)
{
$self
->
_update_c_position
(
$&
,
\
$line
,
\
$column
);
$name
=
$1
;
...
...
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