diff options
| author | Brian Anderson <banderson@mozilla.com> | 2012-11-28 12:38:53 -0800 |
|---|---|---|
| committer | Brian Anderson <banderson@mozilla.com> | 2012-11-28 13:17:33 -0800 |
| commit | fc06114ddfd2bcdbc4f29076c226a7a1d66ea8d6 (patch) | |
| tree | bd9de2c450f23b8ff0e09130ab59d784ace5b5e3 /src/libcore/task.rs | |
| parent | 669fbddc4435a9ab152332df06a7fcca789c8059 (diff) | |
| parent | 8179e268efd86ae5c1bcf21b4f8d4e01eea7c193 (diff) | |
| download | rust-fc06114ddfd2bcdbc4f29076c226a7a1d66ea8d6.tar.gz rust-fc06114ddfd2bcdbc4f29076c226a7a1d66ea8d6.zip | |
Merge remote-tracking branch 'brson/companion' into incoming
Conflicts: src/compiletest/compiletest.rs src/libcargo/cargo.rs src/libcore/core.rs src/librustc/rustc.rs src/librustdoc/rustdoc.rc
Diffstat (limited to 'src/libcore/task.rs')
| -rw-r--r-- | src/libcore/task.rs | 64 |
1 files changed, 0 insertions, 64 deletions
diff --git a/src/libcore/task.rs b/src/libcore/task.rs index 3a6fa2d3931..a2b5c3229ad 100644 --- a/src/libcore/task.rs +++ b/src/libcore/task.rs @@ -43,15 +43,7 @@ pub enum Task { } impl Task : cmp::Eq { - #[cfg(stage0)] - pure fn eq(other: &Task) -> bool { *self == *(*other) } - #[cfg(stage1)] - #[cfg(stage2)] pure fn eq(&self, other: &Task) -> bool { *(*self) == *(*other) } - #[cfg(stage0)] - pure fn ne(other: &Task) -> bool { !self.eq(other) } - #[cfg(stage1)] - #[cfg(stage2)] pure fn ne(&self, other: &Task) -> bool { !(*self).eq(other) } } @@ -72,25 +64,12 @@ pub enum TaskResult { } impl TaskResult : Eq { - #[cfg(stage0)] - pure fn eq(other: &TaskResult) -> bool { - match (self, (*other)) { - (Success, Success) | (Failure, Failure) => true, - (Success, _) | (Failure, _) => false - } - } - #[cfg(stage1)] - #[cfg(stage2)] pure fn eq(&self, other: &TaskResult) -> bool { match ((*self), (*other)) { (Success, Success) | (Failure, Failure) => true, (Success, _) | (Failure, _) => false } } - #[cfg(stage0)] - pure fn ne(other: &TaskResult) -> bool { !self.eq(other) } - #[cfg(stage1)] - #[cfg(stage2)] pure fn ne(&self, other: &TaskResult) -> bool { !(*self).eq(other) } } @@ -114,43 +93,6 @@ pub enum SchedMode { } impl SchedMode : cmp::Eq { - #[cfg(stage0)] - pure fn eq(other: &SchedMode) -> bool { - match self { - SingleThreaded => { - match (*other) { - SingleThreaded => true, - _ => false - } - } - ThreadPerCore => { - match (*other) { - ThreadPerCore => true, - _ => false - } - } - ThreadPerTask => { - match (*other) { - ThreadPerTask => true, - _ => false - } - } - ManualThreads(e0a) => { - match (*other) { - ManualThreads(e0b) => e0a == e0b, - _ => false - } - } - PlatformThread => { - match (*other) { - PlatformThread => true, - _ => false - } - } - } - } - #[cfg(stage1)] - #[cfg(stage2)] pure fn eq(&self, other: &SchedMode) -> bool { match (*self) { SingleThreaded => { @@ -185,12 +127,6 @@ impl SchedMode : cmp::Eq { } } } - #[cfg(stage0)] - pure fn ne(other: &SchedMode) -> bool { - !self.eq(other) - } - #[cfg(stage1)] - #[cfg(stage2)] pure fn ne(&self, other: &SchedMode) -> bool { !(*self).eq(other) } |
