Permalink
Browse files

Wrap some generated do expressions in parens (#5339)

  • Loading branch information...
zjmiller authored and hzoo committed Feb 22, 2017
1 parent be293bd commit 6614a63b3b0f17a1f6e54e96f2ccaf3ea3692fc5
@@ -46,6 +46,10 @@ export function ObjectExpression(node: Object, parent: Object, printStack: Array
return isFirstInStatement(printStack, { considerArrow: true });
}
export function DoExpression(node: Object, parent: Object, printStack: Array<Object>): boolean {
return isFirstInStatement(printStack);
}
export function Binary(node: Object, parent: Object): boolean {
if ((t.isCallExpression(parent) || t.isNewExpression(parent)) && parent.callee === node) {
return true;

0 comments on commit 6614a63

Please sign in to comment.