diff options
| author | Brendan Zabarauskas <bjzaba@yahoo.com.au> | 2013-09-07 17:16:56 +1000 |
|---|---|---|
| committer | Brendan Zabarauskas <bjzaba@yahoo.com.au> | 2013-09-08 13:48:46 +1000 |
| commit | 8445009a846877fe66160d126566e9757db05cd2 (patch) | |
| tree | c1be9c73f32385fae72afffc0e2a17d0e7d2f59f /src/libstd/num | |
| parent | 0fcb85997db852350c104b40e3d7c78214bb0708 (diff) | |
| download | rust-8445009a846877fe66160d126566e9757db05cd2.tar.gz rust-8445009a846877fe66160d126566e9757db05cd2.zip | |
Add Clone and DeepClone constraints to Primitive trait
Diffstat (limited to 'src/libstd/num')
| -rw-r--r-- | src/libstd/num/num.rs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/libstd/num/num.rs b/src/libstd/num/num.rs index 724bc6dda01..135124b04c1 100644 --- a/src/libstd/num/num.rs +++ b/src/libstd/num/num.rs @@ -15,6 +15,7 @@ #[allow(missing_doc)]; +use clone::{Clone, DeepClone}; use cmp::{Eq, ApproxEq, Ord}; use ops::{Add, Sub, Mul, Div, Rem, Neg}; use ops::{Not, BitAnd, BitOr, BitXor, Shl, Shr}; @@ -274,7 +275,9 @@ pub trait Bounded { /// Specifies the available operations common to all of Rust's core numeric primitives. /// These may not always make sense from a purely mathematical point of view, but /// may be useful for systems programming. -pub trait Primitive: Num +pub trait Primitive: Clone + + DeepClone + + Num + NumCast + Bounded + Neg<Self> |
