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
e7b8459b
Commit
e7b8459b
authored
Oct 02, 2014
by
Jacek Caban
Committed by
Alexandre Julliard
Oct 02, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
jscript: Added support for relational CC expressions.
parent
d9e8c013
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
31 additions
and
6 deletions
+31
-6
cc_parser.y
dlls/jscript/cc_parser.y
+4
-4
cc.js
dlls/jscript/tests/cc.js
+27
-2
No files found.
dlls/jscript/cc_parser.y
View file @
e7b8459b
...
...
@@ -192,13 +192,13 @@ CCEqualityExpression
CCRelationalExpression
: CCShiftExpression { $$ = $1; }
| CCRelationalExpression '<' CCShiftExpression
{
FIXME("'<' expression not implemented\n"); ctx->hres = E_NOTIMPL; YYABORT
; }
{
$$ = ccval_bool(get_ccnum($1) < get_ccnum($3))
; }
| CCRelationalExpression tLEQ CCShiftExpression
{
FIXME("'<=' expression not implemented\n"); ctx->hres = E_NOTIMPL; YYABORT
; }
{
$$ = ccval_bool(get_ccnum($1) <= get_ccnum($3))
; }
| CCRelationalExpression '>' CCShiftExpression
{
FIXME("'>' expression not implemented\n"); ctx->hres = E_NOTIMPL; YYABORT
; }
{
$$ = ccval_bool(get_ccnum($1) > get_ccnum($3))
; }
| CCRelationalExpression tGEQ CCShiftExpression
{
FIXME("'>=' expression not implemented\n"); ctx->hres = E_NOTIMPL; YYABORT
; }
{
$$ = ccval_bool(get_ccnum($1) >= get_ccnum($3))
; }
CCShiftExpression
: CCAdditiveExpression { $$ = $1; }
...
...
dlls/jscript/tests/cc.js
View file @
e7b8459b
...
...
@@ -152,8 +152,33 @@ ok(@test === true, "@test = " + @test);
@
set
@
test
=
(
1
==
false
+
1
)
ok
(@
test
===
true
,
"@test = "
+
@
test
);
@
set
@
test
=
(
1
+
true
==
false
+
1
)
ok
(@
test
===
false
,
"@test = "
+
@
test
);
function
expect
(
val
,
exval
)
{
ok
(
val
===
exval
,
"got "
+
val
+
" expected "
+
exval
);
}
@
set
@
test
=
(
false
<
0.5
)
expect
(@
test
,
true
);
@
set
@
test
=
(
true
==
0
<
0.5
)
expect
(@
test
,
true
);
@
set
@
test
=
(
false
<
0
)
expect
(@
test
,
false
);
@
set
@
test
=
(
false
>
0.5
)
expect
(@
test
,
false
);
@
set
@
test
=
(
1
<
true
)
expect
(@
test
,
false
);
@
set
@
test
=
(
1
<=
true
)
expect
(@
test
,
true
);
@
set
@
test
=
(
1
>=
true
)
expect
(@
test
,
true
);
@
set
@
test
=
(
1
>=
true
-
1
)
expect
(@
test
,
true
);
@
if
(
false
)
this
wouldn
not
parse
...
...
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