From e192b6d7c59607233cc2e455c8d177cd37226162 Mon Sep 17 00:00:00 2001 From: Daniel Micay Date: Fri, 11 Oct 2013 11:59:26 -0400 Subject: correct names for `#[no_send]`/`#[no_freeze]` tests --- src/test/compile-fail/mutable-enum.rs | 19 ------------------- src/test/compile-fail/mutable-struct.rs | 19 ------------------- src/test/compile-fail/no_freeze-enum.rs | 19 +++++++++++++++++++ src/test/compile-fail/no_freeze-struct.rs | 19 +++++++++++++++++++ src/test/compile-fail/no_send-enum.rs | 19 +++++++++++++++++++ src/test/compile-fail/no_send-struct.rs | 19 +++++++++++++++++++ src/test/compile-fail/non_owned-enum.rs | 19 ------------------- src/test/compile-fail/non_owned-struct.rs | 19 ------------------- 8 files changed, 76 insertions(+), 76 deletions(-) delete mode 100644 src/test/compile-fail/mutable-enum.rs delete mode 100644 src/test/compile-fail/mutable-struct.rs create mode 100644 src/test/compile-fail/no_freeze-enum.rs create mode 100644 src/test/compile-fail/no_freeze-struct.rs create mode 100644 src/test/compile-fail/no_send-enum.rs create mode 100644 src/test/compile-fail/no_send-struct.rs delete mode 100644 src/test/compile-fail/non_owned-enum.rs delete mode 100644 src/test/compile-fail/non_owned-struct.rs diff --git a/src/test/compile-fail/mutable-enum.rs b/src/test/compile-fail/mutable-enum.rs deleted file mode 100644 index 35842a53a31..00000000000 --- a/src/test/compile-fail/mutable-enum.rs +++ /dev/null @@ -1,19 +0,0 @@ -// Copyright 2013 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. - -#[no_freeze] -enum Foo { A } - -fn bar(_: T) {} - -fn main() { - let x = A; - bar(x); //~ ERROR instantiating a type parameter with an incompatible type `Foo`, which does not fulfill `Freeze` -} diff --git a/src/test/compile-fail/mutable-struct.rs b/src/test/compile-fail/mutable-struct.rs deleted file mode 100644 index 6f29fcfd96d..00000000000 --- a/src/test/compile-fail/mutable-struct.rs +++ /dev/null @@ -1,19 +0,0 @@ -// Copyright 2013 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. - -#[no_freeze] -struct Foo { a: int } - -fn bar(_: T) {} - -fn main() { - let x = Foo { a: 5 }; - bar(x); //~ ERROR instantiating a type parameter with an incompatible type `Foo`, which does not fulfill `Freeze` -} diff --git a/src/test/compile-fail/no_freeze-enum.rs b/src/test/compile-fail/no_freeze-enum.rs new file mode 100644 index 00000000000..35842a53a31 --- /dev/null +++ b/src/test/compile-fail/no_freeze-enum.rs @@ -0,0 +1,19 @@ +// Copyright 2013 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. + +#[no_freeze] +enum Foo { A } + +fn bar(_: T) {} + +fn main() { + let x = A; + bar(x); //~ ERROR instantiating a type parameter with an incompatible type `Foo`, which does not fulfill `Freeze` +} diff --git a/src/test/compile-fail/no_freeze-struct.rs b/src/test/compile-fail/no_freeze-struct.rs new file mode 100644 index 00000000000..6f29fcfd96d --- /dev/null +++ b/src/test/compile-fail/no_freeze-struct.rs @@ -0,0 +1,19 @@ +// Copyright 2013 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. + +#[no_freeze] +struct Foo { a: int } + +fn bar(_: T) {} + +fn main() { + let x = Foo { a: 5 }; + bar(x); //~ ERROR instantiating a type parameter with an incompatible type `Foo`, which does not fulfill `Freeze` +} diff --git a/src/test/compile-fail/no_send-enum.rs b/src/test/compile-fail/no_send-enum.rs new file mode 100644 index 00000000000..b436bfb8b0f --- /dev/null +++ b/src/test/compile-fail/no_send-enum.rs @@ -0,0 +1,19 @@ +// Copyright 2013 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. + +#[no_send] +enum Foo { A } + +fn bar(_: T) {} + +fn main() { + let x = A; + bar(x); //~ ERROR instantiating a type parameter with an incompatible type `Foo`, which does not fulfill `Send` +} diff --git a/src/test/compile-fail/no_send-struct.rs b/src/test/compile-fail/no_send-struct.rs new file mode 100644 index 00000000000..542c3aa212b --- /dev/null +++ b/src/test/compile-fail/no_send-struct.rs @@ -0,0 +1,19 @@ +// Copyright 2013 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. + +#[no_send] +struct Foo { a: int } + +fn bar(_: T) {} + +fn main() { + let x = Foo { a: 5 }; + bar(x); //~ ERROR instantiating a type parameter with an incompatible type `Foo`, which does not fulfill `Send` +} diff --git a/src/test/compile-fail/non_owned-enum.rs b/src/test/compile-fail/non_owned-enum.rs deleted file mode 100644 index b436bfb8b0f..00000000000 --- a/src/test/compile-fail/non_owned-enum.rs +++ /dev/null @@ -1,19 +0,0 @@ -// Copyright 2013 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. - -#[no_send] -enum Foo { A } - -fn bar(_: T) {} - -fn main() { - let x = A; - bar(x); //~ ERROR instantiating a type parameter with an incompatible type `Foo`, which does not fulfill `Send` -} diff --git a/src/test/compile-fail/non_owned-struct.rs b/src/test/compile-fail/non_owned-struct.rs deleted file mode 100644 index 542c3aa212b..00000000000 --- a/src/test/compile-fail/non_owned-struct.rs +++ /dev/null @@ -1,19 +0,0 @@ -// Copyright 2013 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. - -#[no_send] -struct Foo { a: int } - -fn bar(_: T) {} - -fn main() { - let x = Foo { a: 5 }; - bar(x); //~ ERROR instantiating a type parameter with an incompatible type `Foo`, which does not fulfill `Send` -} -- cgit 1.4.1-3-g733a5