Skip to content

Commit

Permalink
remove several 'ne' methods
Browse files Browse the repository at this point in the history
  • Loading branch information
eamartin committed Aug 31, 2013
1 parent 8002a09 commit babe20f
Show file tree
Hide file tree
Showing 10 changed files with 0 additions and 24 deletions.
3 changes: 0 additions & 3 deletions src/librustpkg/package_id.rs
Expand Up @@ -40,9 +40,6 @@ impl Eq for PkgId {
fn eq(&self, p: &PkgId) -> bool {
p.path == self.path && p.version == self.version
}
fn ne(&self, p: &PkgId) -> bool {
!(self.eq(p))
}
}

impl PkgId {
Expand Down
3 changes: 0 additions & 3 deletions src/librustpkg/version.rs
Expand Up @@ -40,9 +40,6 @@ impl Eq for Version {
_ => false
}
}
fn ne(&self, other: &Version) -> bool {
!self.eq(other)
}
}

impl Ord for Version {
Expand Down
2 changes: 0 additions & 2 deletions src/libstd/bool.rs
Expand Up @@ -321,8 +321,6 @@ impl TotalOrd for bool {
impl Eq for bool {
#[inline]
fn eq(&self, other: &bool) -> bool { (*self) == (*other) }
#[inline]
fn ne(&self, other: &bool) -> bool { (*self) != (*other) }
}

#[cfg(not(test))]
Expand Down
2 changes: 0 additions & 2 deletions src/libstd/char.rs
Expand Up @@ -397,8 +397,6 @@ impl Char for char {
impl Eq for char {
#[inline]
fn eq(&self, other: &char) -> bool { (*self) == (*other) }
#[inline]
fn ne(&self, other: &char) -> bool { (*self) != (*other) }
}

#[cfg(not(test))]
Expand Down
2 changes: 0 additions & 2 deletions src/libstd/num/f32.rs
Expand Up @@ -171,8 +171,6 @@ impl Num for f32 {}
impl Eq for f32 {
#[inline]
fn eq(&self, other: &f32) -> bool { (*self) == (*other) }
#[inline]
fn ne(&self, other: &f32) -> bool { (*self) != (*other) }
}

#[cfg(not(test))]
Expand Down
2 changes: 0 additions & 2 deletions src/libstd/num/f64.rs
Expand Up @@ -194,8 +194,6 @@ impl Num for f64 {}
impl Eq for f64 {
#[inline]
fn eq(&self, other: &f64) -> bool { (*self) == (*other) }
#[inline]
fn ne(&self, other: &f64) -> bool { (*self) != (*other) }
}

#[cfg(not(test))]
Expand Down
2 changes: 0 additions & 2 deletions src/libstd/num/float.rs
Expand Up @@ -331,8 +331,6 @@ impl Num for float {}
impl Eq for float {
#[inline]
fn eq(&self, other: &float) -> bool { (*self) == (*other) }
#[inline]
fn ne(&self, other: &float) -> bool { (*self) != (*other) }
}

#[cfg(not(test))]
Expand Down
2 changes: 0 additions & 2 deletions src/libstd/num/int_macros.rs
Expand Up @@ -147,8 +147,6 @@ impl Ord for $T {
impl Eq for $T {
#[inline]
fn eq(&self, other: &$T) -> bool { return (*self) == (*other); }
#[inline]
fn ne(&self, other: &$T) -> bool { return (*self) != (*other); }
}

impl Orderable for $T {
Expand Down
2 changes: 0 additions & 2 deletions src/libstd/num/uint_macros.rs
Expand Up @@ -148,8 +148,6 @@ impl Ord for $T {
impl Eq for $T {
#[inline]
fn eq(&self, other: &$T) -> bool { return (*self) == (*other); }
#[inline]
fn ne(&self, other: &$T) -> bool { return (*self) != (*other); }
}

impl Orderable for $T {
Expand Down
4 changes: 0 additions & 4 deletions src/libstd/str.rs
Expand Up @@ -1180,17 +1180,13 @@ pub mod traits {
fn eq(&self, other: &~str) -> bool {
eq_slice((*self), (*other))
}
#[inline]
fn ne(&self, other: &~str) -> bool { !(*self).eq(other) }
}

impl Eq for @str {
#[inline]
fn eq(&self, other: &@str) -> bool {
eq_slice((*self), (*other))
}
#[inline]
fn ne(&self, other: &@str) -> bool { !(*self).eq(other) }
}

impl<'self> TotalEq for &'self str {
Expand Down

0 comments on commit babe20f

Please sign in to comment.