Skip to content

Commit

Permalink
libcore: rename private cmp macros
Browse files Browse the repository at this point in the history
eq_impl! => partial_eq_impl!
totaleq_impl! => eq_impl!
ord_impl! => partial_ord_impl!
totalord_impl! => ord_impl!
  • Loading branch information
liigo committed Aug 13, 2014
1 parent e189122 commit 0186246
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions src/libcore/cmp.rs
Expand Up @@ -273,7 +273,7 @@ mod impls {
Less, Greater, Equal};
use option::{Option, Some, None};

macro_rules! eq_impl(
macro_rules! partial_eq_impl(
($($t:ty)*) => ($(
#[unstable = "Trait is unstable."]
impl PartialEq for $t {
Expand All @@ -293,18 +293,18 @@ mod impls {
fn ne(&self, _other: &()) -> bool { false }
}

eq_impl!(bool char uint u8 u16 u32 u64 int i8 i16 i32 i64 f32 f64)
partial_eq_impl!(bool char uint u8 u16 u32 u64 int i8 i16 i32 i64 f32 f64)

macro_rules! totaleq_impl(
macro_rules! eq_impl(
($($t:ty)*) => ($(
#[unstable = "Trait is unstable."]
impl Eq for $t {}
)*)
)

totaleq_impl!(() bool char uint u8 u16 u32 u64 int i8 i16 i32 i64)
eq_impl!(() bool char uint u8 u16 u32 u64 int i8 i16 i32 i64)

macro_rules! ord_impl(
macro_rules! partial_ord_impl(
($($t:ty)*) => ($(
#[unstable = "Trait is unstable."]
impl PartialOrd for $t {
Expand Down Expand Up @@ -345,9 +345,9 @@ mod impls {
}
}

ord_impl!(char uint u8 u16 u32 u64 int i8 i16 i32 i64 f32 f64)
partial_ord_impl!(char uint u8 u16 u32 u64 int i8 i16 i32 i64 f32 f64)

macro_rules! totalord_impl(
macro_rules! ord_impl(
($($t:ty)*) => ($(
#[unstable = "Trait is unstable."]
impl Ord for $t {
Expand Down Expand Up @@ -375,7 +375,7 @@ mod impls {
}
}

totalord_impl!(char uint u8 u16 u32 u64 int i8 i16 i32 i64)
ord_impl!(char uint u8 u16 u32 u64 int i8 i16 i32 i64)

// & pointers
#[unstable = "Trait is unstable."]
Expand Down

5 comments on commit 0186246

@bors
Copy link
Contributor

@bors bors commented on 0186246 Aug 14, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

saw approval from brson
at liigo@0186246

@bors
Copy link
Contributor

@bors bors commented on 0186246 Aug 14, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

merging liigo/rust/rename-private-cmp-macros = 0186246 into auto

@bors
Copy link
Contributor

@bors bors commented on 0186246 Aug 14, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

liigo/rust/rename-private-cmp-macros = 0186246 merged ok, testing candidate = e99eeb5

@bors
Copy link
Contributor

@bors bors commented on 0186246 Aug 14, 2014

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fast-forwarding master to auto = e99eeb5

Please sign in to comment.