Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
e7f582e8
Commit
e7f582e8
authored
Sep 08, 2011
by
Jacek Caban
Committed by
Alexandre Julliard
Sep 08, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vbscript: Added support for arguments in interp_icallv.
parent
2cbbf571
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
7 deletions
+29
-7
interp.c
dlls/vbscript/interp.c
+29
-7
No files found.
dlls/vbscript/interp.c
View file @
e7f582e8
...
...
@@ -107,25 +107,46 @@ static void stack_popn(exec_ctx_t *ctx, unsigned n)
VariantClear
(
stack_pop
(
ctx
));
}
static
void
vbstack_to_dp
(
exec_ctx_t
*
ctx
,
unsigned
arg_cnt
,
DISPPARAMS
*
dp
)
{
dp
->
cArgs
=
arg_cnt
;
dp
->
rgdispidNamedArgs
=
NULL
;
dp
->
cNamedArgs
=
0
;
if
(
arg_cnt
)
{
VARIANT
tmp
;
unsigned
i
;
assert
(
ctx
->
top
>=
arg_cnt
);
for
(
i
=
1
;
i
*
2
<=
arg_cnt
;
i
++
)
{
tmp
=
ctx
->
stack
[
ctx
->
top
-
i
];
ctx
->
stack
[
ctx
->
top
-
i
]
=
ctx
->
stack
[
ctx
->
top
-
arg_cnt
+
i
-
1
];
ctx
->
stack
[
ctx
->
top
-
arg_cnt
+
i
-
1
]
=
tmp
;
}
dp
->
rgvarg
=
ctx
->
stack
+
ctx
->
top
-
arg_cnt
;
}
else
{
dp
->
rgvarg
=
NULL
;
}
}
static
HRESULT
interp_icallv
(
exec_ctx_t
*
ctx
)
{
BSTR
identifier
=
ctx
->
instr
->
arg1
.
bstr
;
const
unsigned
arg_cnt
=
ctx
->
instr
->
arg2
.
uint
;
DISPPARAMS
dp
=
{
0
};
ref_t
ref
;
ref_t
ref
=
{
0
};
DISPPARAMS
dp
;
HRESULT
hres
;
TRACE
(
"
\n
"
);
if
(
arg_cnt
)
{
FIXME
(
"arguments not implemented
\n
"
);
return
E_NOTIMPL
;
}
hres
=
lookup_identifier
(
ctx
,
identifier
,
&
ref
);
if
(
FAILED
(
hres
))
return
hres
;
vbstack_to_dp
(
ctx
,
arg_cnt
,
&
dp
);
switch
(
ref
.
type
)
{
case
REF_DISP
:
hres
=
disp_call
(
ctx
->
script
,
ref
.
u
.
d
.
disp
,
ref
.
u
.
d
.
id
,
&
dp
,
NULL
);
...
...
@@ -137,6 +158,7 @@ static HRESULT interp_icallv(exec_ctx_t *ctx)
return
DISP_E_UNKNOWNNAME
;
}
stack_popn
(
ctx
,
arg_cnt
);
return
S_OK
;
}
...
...
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