-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make sure UnknownXYExpressions are included when referenced as return…
… values in a MultiExpression (#3559)
- Loading branch information
1 parent
e5872b0
commit 4ae97b5
Showing
3 changed files
with
25 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 9 additions & 0 deletions
9
test/function/samples/chained-mutable-array-methods/_config.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
const assert = require('assert'); | ||
|
||
module.exports = { | ||
description: | ||
'recognizes side-effects when applying mutable array methods to chained array methods (#3555)', | ||
exports(exports) { | ||
assert.deepStrictEqual(exports.a, ['PASS']); | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
function f(x) { | ||
return (x ? [] : ['FAIL']).map(o => o); | ||
} | ||
export const a = f(0); | ||
a.splice(0, 1, 'PASS'); |