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
470137b6
Commit
470137b6
authored
Oct 08, 2012
by
Jacek Caban
Committed by
Alexandre Julliard
Oct 08, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vbscript: Added CStr implementation.
parent
c046d30f
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
2 deletions
+22
-2
global.c
dlls/vbscript/global.c
+10
-2
api.vbs
dlls/vbscript/tests/api.vbs
+12
-0
No files found.
dlls/vbscript/global.c
View file @
470137b6
...
...
@@ -402,8 +402,16 @@ static HRESULT Global_CSng(vbdisp_t *This, VARIANT *arg, unsigned args_cnt, VARI
static
HRESULT
Global_CStr
(
vbdisp_t
*
This
,
VARIANT
*
arg
,
unsigned
args_cnt
,
VARIANT
*
res
)
{
FIXME
(
"
\n
"
);
return
E_NOTIMPL
;
BSTR
str
;
HRESULT
hres
;
TRACE
(
"%s
\n
"
,
debugstr_variant
(
arg
));
hres
=
to_string
(
arg
,
&
str
);
if
(
FAILED
(
hres
))
return
hres
;
return
return_bstr
(
res
,
str
);
}
static
inline
WCHAR
hex_char
(
unsigned
n
)
...
...
dlls/vbscript/tests/api.vbs
View file @
470137b6
...
...
@@ -38,6 +38,18 @@ Call ok(getVT(vbFriday) = "VT_I2", "getVT(vbFriday) = " & getVT(vbFriday))
Call
ok
(
vbSaturday
=
7
,
"vbSaturday = "
&
vbSaturday
)
Call
ok
(
getVT
(
vbSaturday
)
=
"VT_I2"
,
"getVT(vbSaturday) = "
&
getVT
(
vbSaturday
))
Sub
TestCStr
(
arg
,
exval
)
dim
x
x
=
CStr
(
arg
)
Call
ok
(
getVT
(
x
)
=
"VT_BSTR*"
,
"getVT(x) = "
&
getVT
(
x
))
Call
ok
(
x
=
exval
,
"CStr("
&
arg
&
") = "
&
x
)
End
Sub
TestCStr
"test"
,
"test"
TestCStr
3
,
"3"
TestCStr
3.5
,
"3.5"
if
isEnglishLang
then
TestCStr
true
,
"True"
Call
ok
(
isObject
(
new
EmptyClass
),
"isObject(new EmptyClass) is not true?"
)
Set
x
=
new
EmptyClass
Call
ok
(
isObject
(
x
),
"isObject(x) is not true?"
)
...
...
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