From e62727ee514f0820bfc3b70af99bf3cd0e9718bb Mon Sep 17 00:00:00 2001 From: Oliver Schneider Date: Wed, 29 Nov 2017 16:05:13 +0100 Subject: [PATCH] Add regression test (fixes #2234) --- tests/ui/ty_fn_sig.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/tests/ui/ty_fn_sig.rs b/tests/ui/ty_fn_sig.rs index b6f9e645d..9e2753dcb 100644 --- a/tests/ui/ty_fn_sig.rs +++ b/tests/ui/ty_fn_sig.rs @@ -6,4 +6,9 @@ pub fn retry(f: F) { } } -fn main() {} +fn main() { + for y in 0..4 { + let func = || (); + func(); + } +}