From 7c9aee78f05446c647675fbfc408bc1eb0c19bc2 Mon Sep 17 00:00:00 2001 From: Seiichi Uchida Date: Wed, 26 Jul 2017 22:43:50 +0900 Subject: [PATCH] Update tests --- tests/source/expr.rs | 28 ++++++++++++++++++++++++++++ tests/target/expr.rs | 22 ++++++++++++++++++++++ 2 files changed, 50 insertions(+) diff --git a/tests/source/expr.rs b/tests/source/expr.rs index fb0bd905d0aa..799bfe724322 100644 --- a/tests/source/expr.rs +++ b/tests/source/expr.rs @@ -327,3 +327,31 @@ fn issue1749() { } } } + +// #1172 +fn newlines_between_list_like_expr() { + foo( + xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx, + + yyyyyyyyyyyyyyyyyyyyyyyyyyyyyy, + + zzzzzzzzzzzzzzzzzzzzzzzzzzzzzz, + ); + + vec![ + xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx, + + yyyyyyyyyyyyyyyyyyyyyyyyyyyyyy, + + zzzzzzzzzzzzzzzzzzzzzzzzzzzzzz, + ]; + + match x { + xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx | + + yyyyyyyyyyyyyyyyyyyyyyyyyyyyyy | + + zzzzzzzzzzzzzzzzzzzzzzzzzzzzzz => foo(a, b, c), + _ => bar(), + }; +} diff --git a/tests/target/expr.rs b/tests/target/expr.rs index dde596394a8f..3fe7df43b26d 100644 --- a/tests/target/expr.rs +++ b/tests/target/expr.rs @@ -393,3 +393,25 @@ fn issue1749() { } } } + +// #1172 +fn newlines_between_list_like_expr() { + foo( + xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx, + yyyyyyyyyyyyyyyyyyyyyyyyyyyyyy, + zzzzzzzzzzzzzzzzzzzzzzzzzzzzzz, + ); + + vec![ + xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx, + yyyyyyyyyyyyyyyyyyyyyyyyyyyyyy, + zzzzzzzzzzzzzzzzzzzzzzzzzzzzzz, + ]; + + match x { + xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx | + yyyyyyyyyyyyyyyyyyyyyyyyyyyyyy | + zzzzzzzzzzzzzzzzzzzzzzzzzzzzzz => foo(a, b, c), + _ => bar(), + }; +}