From 5429305e5d9e2fa24645ebc9c5591cf39a24a322 Mon Sep 17 00:00:00 2001 From: Andrew Cann Date: Sat, 4 Feb 2017 13:09:04 +0800 Subject: [PATCH] Add test for #39485 --- src/test/run-pass/inference-changes-39485.rs | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 src/test/run-pass/inference-changes-39485.rs diff --git a/src/test/run-pass/inference-changes-39485.rs b/src/test/run-pass/inference-changes-39485.rs new file mode 100644 index 000000000000..193c66b2a2af --- /dev/null +++ b/src/test/run-pass/inference-changes-39485.rs @@ -0,0 +1,19 @@ +// Copyright 2014 The Rust Project Developers. See the COPYRIGHT +// file at the top-level directory of this distribution and at +// http://rust-lang.org/COPYRIGHT. +// +// Licensed under the Apache License, Version 2.0 or the MIT license +// , at your +// option. This file may not be copied, modified, or distributed +// except according to those terms. + +fn g() { + &panic!() +} + +fn f() -> isize { + (return 1, return 2) +} + +fn main() {}