From c9b1b70485e8d621d7bfd15568930681eba8e24c Mon Sep 17 00:00:00 2001 From: Florian Hahn Date: Sat, 22 Feb 2014 20:37:52 +0100 Subject: [PATCH] Remove some obsolete ignored tests * compile-fail/vec-add.rs is obsolete, there are no mutable vectors any more, #2711 is closed * compile-fail/issue-1451.rs is obsolete, there are no more structural records, #1451 is closed * compile-fail/issue-2074.rs is obsolete, an up to date test is in run-pass/nested-enum-same-names.rs, #2074 is closed * compile-fail/omitted-arg-wrong-types.rs is obsolete, #2093 is closed --- src/test/compile-fail/issue-1451.rs | 33 --------- src/test/compile-fail/issue-2074.rs | 23 ------ .../compile-fail/omitted-arg-wrong-types.rs | 21 ------ src/test/compile-fail/vec-add.rs | 73 ------------------- 4 files changed, 150 deletions(-) delete mode 100644 src/test/compile-fail/issue-1451.rs delete mode 100644 src/test/compile-fail/issue-2074.rs delete mode 100644 src/test/compile-fail/omitted-arg-wrong-types.rs delete mode 100644 src/test/compile-fail/vec-add.rs diff --git a/src/test/compile-fail/issue-1451.rs b/src/test/compile-fail/issue-1451.rs deleted file mode 100644 index ce27cc3be38dc..0000000000000 --- a/src/test/compile-fail/issue-1451.rs +++ /dev/null @@ -1,33 +0,0 @@ -// Copyright 2012-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. - -// ignore-test - -struct T { f: extern "Rust" fn() }; -struct S { f: extern "Rust" fn() }; - -fn fooS(t: S) { -} - -fn fooT(t: T) { -} - -fn bar() { -} - -fn main() { - let x: extern "Rust" fn() = bar; - fooS(S {f: x}); - fooS(S {f: bar}); - - let x: extern "Rust" fn() = bar; - fooT(T {f: x}); - fooT(T {f: bar}); -} diff --git a/src/test/compile-fail/issue-2074.rs b/src/test/compile-fail/issue-2074.rs deleted file mode 100644 index 338d0cb439c23..0000000000000 --- a/src/test/compile-fail/issue-2074.rs +++ /dev/null @@ -1,23 +0,0 @@ -// Copyright 2012-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. - -// ignore-test - -fn main() { - let one: || -> uint = || { - enum r { a }; - a as uint - }; - let two = || -> uint = || { - enum r { a }; - a as uint - }; - one(); two(); -} diff --git a/src/test/compile-fail/omitted-arg-wrong-types.rs b/src/test/compile-fail/omitted-arg-wrong-types.rs deleted file mode 100644 index 1f1a6849acad5..0000000000000 --- a/src/test/compile-fail/omitted-arg-wrong-types.rs +++ /dev/null @@ -1,21 +0,0 @@ -// Copyright 2012-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. - -// ignore-test - #2093 - -fn let_in(x: T, f: |T|) {} - -fn main() { - let_in(3u, |i| { assert!(i == 3); }); - //~^ ERROR expected `uint` but found `int` - - let_in(3, |i| { assert!(i == 3u); }); - //~^ ERROR expected `int` but found `uint` -} diff --git a/src/test/compile-fail/vec-add.rs b/src/test/compile-fail/vec-add.rs deleted file mode 100644 index 3f1b82d1768d6..0000000000000 --- a/src/test/compile-fail/vec-add.rs +++ /dev/null @@ -1,73 +0,0 @@ -// Copyright 2012-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. - -// ignore-test - -// FIXME (Issue #2711): + should allow immutable or mutable vectors on -// the right hand side in all cases. We are getting compiler errors -// about this now, so I'm ignoring the test for now. -eholk - -fn add(i: ~[int], mut m: ~[int]) { - - // Check that: - // (1) vectors of any two mutabilities can be added - // (2) result has mutability of lhs - - add(i + ~[3], - m + ~[3], - ~[3]); - - add(i + ~[3], - m + ~[3], - ~[3]); - - add(i + i, - m + i, - i); - - add(i + m, - m + m, - m); - - add(m + ~[3], //~ ERROR mismatched types - m + ~[3], - m + ~[3]); - - add(i + ~[3], - i + ~[3], //~ ERROR mismatched types - i + ~[3]); - - add(m + ~[3], //~ ERROR mismatched types - m + ~[3], - m + ~[3]); - - add(i + ~[3], - i + ~[3], //~ ERROR mismatched types - i + ~[3]); - - add(m + i, //~ ERROR mismatched types - m + i, - m + i); - - add(i + i, - i + i, //~ ERROR mismatched types - i + i); - - add(m + m, //~ ERROR mismatched types - m + m, - m + m); - - add(i + m, - i + m, //~ ERROR mismatched types - i + m); -} - -fn main() { -}