Rename #[non_sendable] to #[no_send]

This commit is contained in:
Brian Anderson 2013-06-28 14:33:58 -07:00 committed by Daniel Micay
parent e23934645a
commit 4af7ebcd8f
4 changed files with 6 additions and 6 deletions

View File

@ -36,7 +36,7 @@ struct RcBox<T> {
/// Immutable reference counted pointer type /// Immutable reference counted pointer type
#[unsafe_no_drop_flag] #[unsafe_no_drop_flag]
#[non_sendable] #[no_send]
pub struct Rc<T> { pub struct Rc<T> {
priv ptr: *mut RcBox<T>, priv ptr: *mut RcBox<T>,
} }
@ -168,7 +168,7 @@ struct RcMutBox<T> {
/// Mutable reference counted pointer type /// Mutable reference counted pointer type
#[non_owned] #[non_owned]
#[non_sendable] #[no_send]
#[mutable] #[mutable]
#[unsafe_no_drop_flag] #[unsafe_no_drop_flag]
pub struct RcMut<T> { pub struct RcMut<T> {

View File

@ -1969,7 +1969,7 @@ static TC_ONCE_CLOSURE: TypeContents = TypeContents{bits: 0b0001_0000_0000};
/// An enum with no variants. /// An enum with no variants.
static TC_EMPTY_ENUM: TypeContents = TypeContents{bits: 0b0010_0000_0000}; static TC_EMPTY_ENUM: TypeContents = TypeContents{bits: 0b0010_0000_0000};
/// Contains a type marked with `#[non_sendable]` /// Contains a type marked with `#[no_send]`
static TC_NON_SENDABLE: TypeContents = TypeContents{bits: 0b0100_0000_0000}; static TC_NON_SENDABLE: TypeContents = TypeContents{bits: 0b0100_0000_0000};
/// Is a bare vector, str, function, trait, etc (only relevant at top level). /// Is a bare vector, str, function, trait, etc (only relevant at top level).
@ -2207,7 +2207,7 @@ pub fn type_contents(cx: ctxt, ty: t) -> TypeContents {
if has_attr(cx, did, "mutable") { if has_attr(cx, did, "mutable") {
tc = tc + TC_MUTABLE; tc = tc + TC_MUTABLE;
} }
if has_attr(cx, did, "non_sendable") { if has_attr(cx, did, "no_send") {
tc = tc + TC_NON_SENDABLE; tc = tc + TC_NON_SENDABLE;
} }
tc tc

View File

@ -8,7 +8,7 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#[non_sendable] #[no_send]
enum Foo { A } enum Foo { A }
fn bar<T: Send>(_: T) {} fn bar<T: Send>(_: T) {}

View File

@ -8,7 +8,7 @@
// option. This file may not be copied, modified, or distributed // option. This file may not be copied, modified, or distributed
// except according to those terms. // except according to those terms.
#[non_sendable] #[no_send]
struct Foo { a: int } struct Foo { a: int }
fn bar<T: Send>(_: T) {} fn bar<T: Send>(_: T) {}