Skip to content

Commit ae61d74

Browse files
avpfacebook-github-bot
authored andcommitted
Fix extra parens in property assignment
Reviewed By: tmikov Differential Revision: D33072070 fbshipit-source-id: a9dfd6820b71d191df11e5f17edfac054dbd7ebc
1 parent 1ba8ef6 commit ae61d74

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

unsupported/juno/crates/juno/src/gen_js.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1389,7 +1389,7 @@ impl<W: Write> GenJS<W> {
13891389
} else {
13901390
out!(self, ":");
13911391
self.space(ForceSpace::No);
1392-
self.print_comma_expression(ctx, *value, Path::new(node, NodeField::value));
1392+
value.visit(ctx, self, Some(Path::new(node, NodeField::value)));
13931393
}
13941394
}
13951395

unsupported/juno/crates/juno/tests/gen_js/mod.rs

+1
Original file line numberDiff line numberDiff line change
@@ -343,6 +343,7 @@ fn test_assignment() {
343343
test_roundtrip("(a = b) && c");
344344
test_roundtrip("a && b = c");
345345
test_roundtrip("a && (b = c)");
346+
test_roundtrip("var {x: {y: [{z}]}} = foo;");
346347
}
347348

348349
#[test]

0 commit comments

Comments
 (0)