Skip to content

Commit

Permalink
Register snapshots
Browse files Browse the repository at this point in the history
  • Loading branch information
brson committed Nov 28, 2012
1 parent be6613e commit 8179e26
Show file tree
Hide file tree
Showing 78 changed files with 475 additions and 5,514 deletions.
9 changes: 0 additions & 9 deletions src/compiletest/common.rs
Original file line number Diff line number Diff line change
@@ -1,14 +1,5 @@
enum mode { mode_compile_fail, mode_run_fail, mode_run_pass, mode_pretty, }

#[cfg(stage0)]
impl mode : cmp::Eq {
pure fn eq(other: &mode) -> bool {
(*other) as int == self as int
}
pure fn ne(other: &mode) -> bool { !self.eq(other) }
}
#[cfg(stage1)]
#[cfg(stage2)]
impl mode : cmp::Eq {
pure fn eq(&self, other: &mode) -> bool {
(*other) as int == (*self) as int
Expand Down
41 changes: 0 additions & 41 deletions src/libcargo/cargo.rc
Original file line number Diff line number Diff line change
Expand Up @@ -65,25 +65,6 @@ struct Package {
}

impl Package : cmp::Ord {
#[cfg(stage0)]
pure fn lt(other: &Package) -> bool {
if self.name.lt(&(*other).name) { return true; }
if (*other).name.lt(&self.name) { return false; }
if self.uuid.lt(&(*other).uuid) { return true; }
if (*other).uuid.lt(&self.uuid) { return false; }
if self.url.lt(&(*other).url) { return true; }
if (*other).url.lt(&self.url) { return false; }
if self.method.lt(&(*other).method) { return true; }
if (*other).method.lt(&self.method) { return false; }
if self.description.lt(&(*other).description) { return true; }
if (*other).description.lt(&self.description) { return false; }
if self.tags.lt(&(*other).tags) { return true; }
if (*other).tags.lt(&self.tags) { return false; }
if self.versions.lt(&(*other).versions) { return true; }
return false;
}
#[cfg(stage1)]
#[cfg(stage2)]
pure fn lt(&self, other: &Package) -> bool {
if (*self).name.lt(&(*other).name) { return true; }
if (*other).name.lt(&(*self).name) { return false; }
Expand All @@ -100,20 +81,8 @@ impl Package : cmp::Ord {
if (*self).versions.lt(&(*other).versions) { return true; }
return false;
}
#[cfg(stage0)]
pure fn le(other: &Package) -> bool { !(*other).lt(&self) }
#[cfg(stage1)]
#[cfg(stage2)]
pure fn le(&self, other: &Package) -> bool { !(*other).lt(&(*self)) }
#[cfg(stage0)]
pure fn ge(other: &Package) -> bool { !self.lt(other) }
#[cfg(stage1)]
#[cfg(stage2)]
pure fn ge(&self, other: &Package) -> bool { !(*self).lt(other) }
#[cfg(stage0)]
pure fn gt(other: &Package) -> bool { (*other).lt(&self) }
#[cfg(stage1)]
#[cfg(stage2)]
pure fn gt(&self, other: &Package) -> bool { (*other).lt(&(*self)) }
}

Expand Down Expand Up @@ -160,19 +129,9 @@ struct Options {
enum Mode { SystemMode, UserMode, LocalMode }

impl Mode : cmp::Eq {
#[cfg(stage0)]
pure fn eq(other: &Mode) -> bool {
(self as uint) == ((*other) as uint)
}
#[cfg(stage1)]
#[cfg(stage2)]
pure fn eq(&self, other: &Mode) -> bool {
((*self) as uint) == ((*other) as uint)
}
#[cfg(stage0)]
pure fn ne(other: &Mode) -> bool { !self.eq(other) }
#[cfg(stage1)]
#[cfg(stage2)]
pure fn ne(&self, other: &Mode) -> bool { !(*self).eq(other) }
}

Expand Down
273 changes: 0 additions & 273 deletions src/libcore/alternate_crate.rc

This file was deleted.

8 changes: 0 additions & 8 deletions src/libcore/bool.rs
Original file line number Diff line number Diff line change
Expand Up @@ -66,15 +66,7 @@ pub fn all_values(blk: fn(v: bool)) {
pub pure fn to_bit(v: bool) -> u8 { if v { 1u8 } else { 0u8 } }

impl bool : cmp::Eq {
#[cfg(stage0)]
pure fn eq(other: &bool) -> bool { self == (*other) }
#[cfg(stage1)]
#[cfg(stage2)]
pure fn eq(&self, other: &bool) -> bool { (*self) == (*other) }
#[cfg(stage0)]
pure fn ne(other: &bool) -> bool { self != (*other) }
#[cfg(stage1)]
#[cfg(stage2)]
pure fn ne(&self, other: &bool) -> bool { (*self) != (*other) }
}

Expand Down
Loading

0 comments on commit 8179e26

Please sign in to comment.