sys: get rid of shape functions

borrowed pointers already implement Eq and Ord with deep comparisons
This commit is contained in:
Daniel Micay 2013-06-04 19:00:19 -04:00
parent 69511c219c
commit 5148e2f78b

View file

@ -52,20 +52,6 @@ pub mod rustrt {
}
}
/// Compares contents of two pointers using the default method.
/// Equivalent to `*x1 == *x2`. Useful for hashtables.
pub fn shape_eq<T:Eq>(x1: &T, x2: &T) -> bool {
*x1 == *x2
}
pub fn shape_lt<T:Ord>(x1: &T, x2: &T) -> bool {
*x1 < *x2
}
pub fn shape_le<T:Ord>(x1: &T, x2: &T) -> bool {
*x1 <= *x2
}
/**
* Returns a pointer to a type descriptor.
*