Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
wine
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Package registry
Container registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Lorenzo Ferrillo
wine
Commits
82368f5c
Commit
82368f5c
authored
13 years ago
by
Jacek Caban
Committed by
Alexandre Julliard
13 years ago
Browse files
Options
Downloads
Patches
Plain Diff
jscript: Get rid of no longer needed EXPRVAL_NAMEREF.
parent
962307da
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
dlls/jscript/engine.c
+5
-34
5 additions, 34 deletions
dlls/jscript/engine.c
dlls/jscript/engine.h
+0
-5
0 additions, 5 deletions
dlls/jscript/engine.h
with
5 additions
and
39 deletions
dlls/jscript/engine.c
+
5
−
34
View file @
82368f5c
...
...
@@ -31,7 +31,6 @@ WINE_DEFAULT_DEBUG_CHANNEL(jscript);
#define EXPR_NOVAL 0x0001
#define EXPR_NEWREF 0x0002
#define EXPR_STRREF 0x0004
struct
_return_type_t
{
enum
{
...
...
@@ -154,11 +153,6 @@ static void exprval_release(exprval_t *val)
if
(
val
->
u
.
idref
.
disp
)
IDispatch_Release
(
val
->
u
.
idref
.
disp
);
return
;
case
EXPRVAL_NAMEREF
:
if
(
val
->
u
.
nameref
.
disp
)
IDispatch_Release
(
val
->
u
.
nameref
.
disp
);
SysFreeString
(
val
->
u
.
nameref
.
name
);
return
;
case
EXPRVAL_INVALID
:
SysFreeString
(
val
->
u
.
identifier
);
}
...
...
@@ -179,8 +173,6 @@ static HRESULT exprval_value(script_ctx_t *ctx, exprval_t *val, jsexcept_t *ei,
}
return
disp_propget
(
ctx
,
val
->
u
.
idref
.
disp
,
val
->
u
.
idref
.
id
,
ret
,
ei
,
NULL
/*FIXME*/
);
case
EXPRVAL_NAMEREF
:
break
;
case
EXPRVAL_INVALID
:
return
throw_type_error
(
ctx
,
ei
,
JS_E_UNDEFINED_VARIABLE
,
val
->
u
.
identifier
);
}
...
...
@@ -1494,13 +1486,6 @@ HRESULT array_expression_eval(script_ctx_t *ctx, expression_t *_expr, DWORD flag
hres
=
to_string
(
ctx
,
&
val
,
ei
,
&
str
);
VariantClear
(
&
val
);
if
(
SUCCEEDED
(
hres
))
{
if
(
flags
&
EXPR_STRREF
)
{
ret
->
type
=
EXPRVAL_NAMEREF
;
ret
->
u
.
nameref
.
disp
=
obj
;
ret
->
u
.
nameref
.
name
=
str
;
return
S_OK
;
}
hres
=
disp_get_id
(
ctx
,
obj
,
str
,
flags
&
EXPR_NEWREF
?
fdexNameEnsure
:
0
,
&
id
);
SysFreeString
(
str
);
}
...
...
@@ -1546,11 +1531,9 @@ HRESULT member_expression_eval(script_ctx_t *ctx, expression_t *_expr, DWORD fla
return
hres
;
str
=
SysAllocString
(
expr
->
identifier
);
if
(
flags
&
EXPR_STRREF
)
{
ret
->
type
=
EXPRVAL_NAMEREF
;
ret
->
u
.
nameref
.
disp
=
obj
;
ret
->
u
.
nameref
.
name
=
str
;
return
S_OK
;
if
(
!
str
)
{
IDispatch_Release
(
obj
);
return
E_OUTOFMEMORY
;
}
hres
=
disp_get_id
(
ctx
,
obj
,
str
,
flags
&
EXPR_NEWREF
?
fdexNameEnsure
:
0
,
&
id
);
...
...
@@ -2457,7 +2440,7 @@ HRESULT delete_expression_eval(script_ctx_t *ctx, expression_t *_expr, DWORD fla
TRACE
(
"
\n
"
);
hres
=
expr_eval
(
ctx
,
expr
->
expression
,
EXPR_STRREF
,
ei
,
&
exprval
);
hres
=
expr_eval
(
ctx
,
expr
->
expression
,
0
,
ei
,
&
exprval
);
if
(
FAILED
(
hres
))
return
hres
;
...
...
@@ -2465,7 +2448,7 @@ HRESULT delete_expression_eval(script_ctx_t *ctx, expression_t *_expr, DWORD fla
case
EXPRVAL_IDREF
:
{
IDispatchEx
*
dispex
;
hres
=
IDispatch_QueryInterface
(
exprval
.
u
.
name
ref
.
disp
,
&
IID_IDispatchEx
,
(
void
**
)
&
dispex
);
hres
=
IDispatch_QueryInterface
(
exprval
.
u
.
id
ref
.
disp
,
&
IID_IDispatchEx
,
(
void
**
)
&
dispex
);
if
(
SUCCEEDED
(
hres
))
{
hres
=
IDispatchEx_DeleteMemberByDispID
(
dispex
,
exprval
.
u
.
idref
.
id
);
b
=
VARIANT_TRUE
;
...
...
@@ -2473,18 +2456,6 @@ HRESULT delete_expression_eval(script_ctx_t *ctx, expression_t *_expr, DWORD fla
}
break
;
}
case
EXPRVAL_NAMEREF
:
{
IDispatchEx
*
dispex
;
hres
=
IDispatch_QueryInterface
(
exprval
.
u
.
nameref
.
disp
,
&
IID_IDispatchEx
,
(
void
**
)
&
dispex
);
if
(
SUCCEEDED
(
hres
))
{
hres
=
IDispatchEx_DeleteMemberByName
(
dispex
,
exprval
.
u
.
nameref
.
name
,
make_grfdex
(
ctx
,
fdexNameCaseSensitive
));
b
=
VARIANT_TRUE
;
IDispatchEx_Release
(
dispex
);
}
break
;
}
default:
FIXME
(
"unsupported type %d
\n
"
,
exprval
.
type
);
hres
=
E_NOTIMPL
;
...
...
This diff is collapsed.
Click to expand it.
dlls/jscript/engine.h
+
0
−
5
View file @
82368f5c
...
...
@@ -364,7 +364,6 @@ typedef struct {
enum
{
EXPRVAL_VARIANT
,
EXPRVAL_IDREF
,
EXPRVAL_NAMEREF
,
EXPRVAL_INVALID
}
type
;
union
{
...
...
@@ -373,10 +372,6 @@ typedef struct {
IDispatch
*
disp
;
DISPID
id
;
}
idref
;
struct
{
IDispatch
*
disp
;
BSTR
name
;
}
nameref
;
BSTR
identifier
;
}
u
;
}
exprval_t
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment