@@ -10051,7 +10051,9 @@ merge(Compressor.prototype, {
|
|||||||
found = true;
|
found = true;
|
||||||
var exp = prop.expression;
|
var exp = prop.expression;
|
||||||
if (compressor.option("spread") && exp instanceof AST_Object && all(exp.properties, function(prop) {
|
if (compressor.option("spread") && exp instanceof AST_Object && all(exp.properties, function(prop) {
|
||||||
return !(prop instanceof AST_ObjectGetter || prop instanceof AST_Spread);
|
return !(prop instanceof AST_ObjectGetter
|
||||||
|
|| prop instanceof AST_ObjectSetter && prop.key instanceof AST_Node
|
||||||
|
|| prop instanceof AST_Spread);
|
||||||
})) {
|
})) {
|
||||||
changed = true;
|
changed = true;
|
||||||
exp.properties.forEach(function(prop) {
|
exp.properties.forEach(function(prop) {
|
||||||
|
|||||||
@@ -758,3 +758,26 @@ issue_4361: {
|
|||||||
]
|
]
|
||||||
node_version: ">=8"
|
node_version: ">=8"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
issue_4363: {
|
||||||
|
options = {
|
||||||
|
objects: true,
|
||||||
|
spread: true,
|
||||||
|
}
|
||||||
|
input: {
|
||||||
|
({
|
||||||
|
...{
|
||||||
|
set [console.log("PASS")](v) {},
|
||||||
|
},
|
||||||
|
});
|
||||||
|
}
|
||||||
|
expect: {
|
||||||
|
({
|
||||||
|
...{
|
||||||
|
set [console.log("PASS")](v) {},
|
||||||
|
},
|
||||||
|
});
|
||||||
|
}
|
||||||
|
expect_stdout: "PASS"
|
||||||
|
node_version: ">=8"
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user