Merge pull request #48 from ozkriff/master

Updated to latest Rust
This commit is contained in:
Brendan Zabarauskas 2014-02-25 01:00:39 +11:00
commit 0be56240d5
3 changed files with 5 additions and 5 deletions

View file

@ -23,8 +23,8 @@ use std::num::{One, one, Zero, zero, cast};
use approx::ApproxEq;
#[deriving(Clone, Eq, Ord, IterBytes)] pub struct Rad<S> { s: S }
#[deriving(Clone, Eq, Ord, IterBytes)] pub struct Deg<S> { s: S }
#[deriving(Clone, Eq, Ord, Hash)] pub struct Rad<S> { s: S }
#[deriving(Clone, Eq, Ord, Hash)] pub struct Deg<S> { s: S }
#[inline] pub fn rad<S: Float>(s: S) -> Rad<S> { Rad { s: s } }
#[inline] pub fn deg<S: Float>(s: S) -> Deg<S> { Deg { s: s } }

View file

@ -24,11 +24,11 @@ use array::*;
use vector::*;
/// A point in 2-dimensional space.
#[deriving(Eq, Clone, IterBytes)]
#[deriving(Eq, Clone, Hash)]
pub struct Point2<S> { x: S, y: S }
/// A point in 3-dimensional space.
#[deriving(Eq, Clone, IterBytes)]
#[deriving(Eq, Clone, Hash)]
pub struct Point3<S> { x: S, y: S, z: S }

View file

@ -80,7 +80,7 @@ pub trait Vector
// Utility macro for generating associated functions for the vectors
macro_rules! vec(
($Self:ident <$S:ident> { $($field:ident),+ }, $n:expr) => (
#[deriving(Eq, Clone, IterBytes)]
#[deriving(Eq, Clone, Hash)]
pub struct $Self<S> { $($field: S),+ }
impl<$S: Primitive> $Self<$S> {