From bc03234e25740ecc8ff6a35f5ae2f6d89fc0c232 Mon Sep 17 00:00:00 2001 From: Ivan Molodetskikh Date: Fri, 31 Aug 2018 17:51:36 +0300 Subject: [PATCH] Add a test for #2496 --- tests/source/issue-2496.rs | 16 ++++++++++++++++ tests/target/issue-2496.rs | 14 ++++++++++++++ 2 files changed, 30 insertions(+) create mode 100644 tests/source/issue-2496.rs create mode 100644 tests/target/issue-2496.rs diff --git a/tests/source/issue-2496.rs b/tests/source/issue-2496.rs new file mode 100644 index 000000000000..0ebd4b510ece --- /dev/null +++ b/tests/source/issue-2496.rs @@ -0,0 +1,16 @@ +// rustfmt-indent_style: Visual +fn main() { + match option { + None => some_function(first_reasonably_long_argument, + second_reasonably_long_argument), + } +} + +fn main() { + match option { + None => { + some_function(first_reasonably_long_argument, + second_reasonably_long_argument) + } + } +} diff --git a/tests/target/issue-2496.rs b/tests/target/issue-2496.rs new file mode 100644 index 000000000000..60c4f55ddffd --- /dev/null +++ b/tests/target/issue-2496.rs @@ -0,0 +1,14 @@ +// rustfmt-indent_style: Visual +fn main() { + match option { + None => some_function(first_reasonably_long_argument, + second_reasonably_long_argument), + } +} + +fn main() { + match option { + None => some_function(first_reasonably_long_argument, + second_reasonably_long_argument), + } +}