diff --git a/external-crates/move/crates/move-analyzer/prettier-move/src/cst/function/ControlFlow.ts b/external-crates/move/crates/move-analyzer/prettier-move/src/cst/function/ControlFlow.ts index 37a35d177e42e..395c8616a982c 100644 --- a/external-crates/move/crates/move-analyzer/prettier-move/src/cst/function/ControlFlow.ts +++ b/external-crates/move/crates/move-analyzer/prettier-move/src/cst/function/ControlFlow.ts @@ -167,24 +167,6 @@ function printAbortExpression(path: AstPath, options: ParserOptions, print const expression = path.node.nonFormattingChildren[0]; const printed = path.call(print, 'nonFormattingChildren', 0); - // Special case in `abort`. Historically, people have been using `abort` with - // parentheses, which are not required. We can format against it. Note, that - // we only do this for `abort` and should never do for other cases where - // `expression_list` is used, because it affects the semantics. - if (expression?.type === 'expression_list') { - return group([ - 'abort', - indent(line), - indent( - path.call( - (path) => path.call(print, 'nonFormattingChildren', 0), - 'nonFormattingChildren', - 0, - ), - ), - ]); - } - return group([ 'abort', expression?.isList || expression?.isControlFlow diff --git a/external-crates/move/crates/move-analyzer/prettier-move/tests/control-flow/abort_expression.exp.move b/external-crates/move/crates/move-analyzer/prettier-move/tests/control-flow/abort_expression.exp.move index a662af8eb0ebe..925d0aab0c294 100644 --- a/external-crates/move/crates/move-analyzer/prettier-move/tests/control-flow/abort_expression.exp.move +++ b/external-crates/move/crates/move-analyzer/prettier-move/tests/control-flow/abort_expression.exp.move @@ -4,8 +4,8 @@ module prettier::abort_expression { fun abort_expression() { abort 0; - abort 0; - abort 10; + abort (0); + abort (10); abort { 10 }; diff --git a/external-crates/move/crates/move-analyzer/prettier-move/tests/sui-framework/test_utils.exp.move b/external-crates/move/crates/move-analyzer/prettier-move/tests/sui-framework/test_utils.exp.move index 76a5c944e8d64..5a3a84cb63775 100644 --- a/external-crates/move/crates/move-analyzer/prettier-move/tests/sui-framework/test_utils.exp.move +++ b/external-crates/move/crates/move-analyzer/prettier-move/tests/sui-framework/test_utils.exp.move @@ -14,7 +14,7 @@ module sui::test_utils { std::debug::print(t1); print(b"!="); std::debug::print(t2); - abort 0 + abort (0) } }