Merge pull request #4443 from wting/4386_add_privs

Adds priv qualifiers where they have been commented out before implementation.
This commit is contained in:
Tim Chevalier 2013-01-11 20:11:57 -08:00
commit 0bc730f9b0
3 changed files with 7 additions and 6 deletions

View File

@ -160,6 +160,7 @@ pub unsafe fn annihilate() {
extern mod rustrt {
#[legacy_exports];
#[rust_stack]
/*priv*/ unsafe fn rust_get_task() -> *c_void;
// FIXME (#4386): Unable to make following method private.
/* priv */ unsafe fn rust_get_task() -> *c_void;
}

View File

@ -31,7 +31,7 @@ use core::task;
#[doc = "The future type"]
pub struct Future<A> {
/*priv*/ mut state: FutureState<A>,
priv mut state: FutureState<A>,
}
// FIXME(#2829) -- futures should not be copyable, because they close

View File

@ -449,9 +449,9 @@ struct RWlockInner {
* unwinds.
*/
struct RWlock {
/* priv */ order_lock: Semaphore,
/* priv */ access_lock: Sem<~[mut Waitqueue]>,
/* priv */ state: Exclusive<RWlockInner>
priv order_lock: Semaphore,
priv access_lock: Sem<~[mut Waitqueue]>,
priv state: Exclusive<RWlockInner>
}
/// Create a new rwlock, with one associated condvar.
@ -683,7 +683,7 @@ fn RWlockReleaseDowngrade(lock: &r/RWlock) -> RWlockReleaseDowngrade/&r {
}
/// The "write permission" token used for rwlock.write_downgrade().
pub struct RWlockWriteMode { /* priv */ lock: &RWlock }
pub struct RWlockWriteMode { priv lock: &RWlock }
impl RWlockWriteMode : Drop { fn finalize(&self) {} }
/// The "read permission" token used for rwlock.write_downgrade().
pub struct RWlockReadMode { priv lock: &RWlock }