diff options
| author | Philipp Brüschweiler <blei42@gmail.com> | 2013-06-07 18:06:38 +0200 |
|---|---|---|
| committer | Philipp Brüschweiler <blei42@gmail.com> | 2013-06-08 09:34:25 +0200 |
| commit | c786b68dd3ecf96e202f50ba600292f54b35f2ee (patch) | |
| tree | d65a65c563ce3efcf67d06d7cf1e12dfeb0c5a26 /src/test | |
| parent | 3fc052481856c980a76a08ff6b3303aa69915490 (diff) | |
| download | rust-c786b68dd3ecf96e202f50ba600292f54b35f2ee.tar.gz rust-c786b68dd3ecf96e202f50ba600292f54b35f2ee.zip | |
Add a test that causes an ICE currently
Diffstat (limited to 'src/test')
| -rw-r--r-- | src/test/compile-fail/unconstrained-ref.rs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/test/compile-fail/unconstrained-ref.rs b/src/test/compile-fail/unconstrained-ref.rs new file mode 100644 index 00000000000..80bd83caf32 --- /dev/null +++ b/src/test/compile-fail/unconstrained-ref.rs @@ -0,0 +1,17 @@ +// Copyright 2012 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 <LICENSE-APACHE or +// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license +// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your +// option. This file may not be copied, modified, or distributed +// except according to those terms. + +struct S<'self, T> { + o: &'self Option<T> +} + +fn main() { + S { o: &None }; //~ ERROR cannot determine a type for this expression: unconstrained type +} |
