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
69bee9f0
Commit
69bee9f0
authored
Mar 13, 2014
by
Jacek Caban
Committed by
Alexandre Julliard
Mar 13, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vbscript: Allow empty brackets in argument declarations.
parent
c7d45060
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
20 additions
and
3 deletions
+20
-3
parser.y
dlls/vbscript/parser.y
+3
-3
lang.vbs
dlls/vbscript/tests/lang.vbs
+17
-0
No files found.
dlls/vbscript/parser.y
View file @
69bee9f0
...
...
@@ -434,9 +434,9 @@ ArgumentDeclList
| ArgumentDecl ',' ArgumentDeclList { $1->next = $3; $$ = $1; }
ArgumentDecl
: Identifier
{ $$ = new_argument_decl(ctx, $1, TRUE); }
| tBYREF Identifier
{ $$ = new_argument_decl(ctx, $2, TRUE); }
| tBYVAL Identifier
{ $$ = new_argument_decl(ctx, $2, FALSE); }
: Identifier
EmptyBrackets_opt
{ $$ = new_argument_decl(ctx, $1, TRUE); }
| tBYREF Identifier
EmptyBrackets_opt
{ $$ = new_argument_decl(ctx, $2, TRUE); }
| tBYVAL Identifier
EmptyBrackets_opt
{ $$ = new_argument_decl(ctx, $2, FALSE); }
/* 'property' may be both keyword and identifier, depending on context */
Identifier
...
...
dlls/vbscript/tests/lang.vbs
View file @
69bee9f0
...
...
@@ -1115,4 +1115,21 @@ End Sub
Call
arrarg
(
arr
,
arr
,
obj
.
classarr
,
obj
.
classarr
)
Sub
arrarg2
(
byref
refarr
(),
byval
valarr
(),
byref
refarr2
(),
byval
valarr2
())
Call
ok
(
getVT
(
refarr
)
=
"VT_ARRAY|VT_BYREF|VT_VARIANT*"
,
"getVT(refarr) = "
&
getVT
(
refarr
))
Call
ok
(
getVT
(
valarr
)
=
"VT_ARRAY|VT_VARIANT*"
,
"getVT(valarr) = "
&
getVT
(
valarr
))
Call
ok
(
getVT
(
refarr2
)
=
"VT_ARRAY|VT_VARIANT*"
,
"getVT(refarr2) = "
&
getVT
(
refarr2
))
Call
ok
(
getVT
(
valarr2
)
=
"VT_ARRAY|VT_VARIANT*"
,
"getVT(valarr2) = "
&
getVT
(
valarr2
))
End
Sub
Call
arrarg2
(
arr
,
arr
,
obj
.
classarr
,
obj
.
classarr
)
Sub
testarrarg
(
arg
(),
vt
)
Call
ok
(
getVT
(
arg
)
=
vt
,
"getVT() = "
&
getVT
(
arg
)
&
" expected "
&
vt
)
End
Sub
Call
testarrarg
(
1
,
"VT_I2*"
)
Call
testarrarg
(
false
,
"VT_BOOL*"
)
Call
testarrarg
(
Empty
,
"VT_EMPTY*"
)
reportSuccess
()
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