about summary refs log tree commit diff
path: root/src/libcore
diff options
context:
space:
mode:
authorPatrick Walton <pcwalton@mimiga.net>2013-02-14 21:17:26 -0800
committerPatrick Walton <pcwalton@mimiga.net>2013-02-15 16:59:56 -0800
commitbb833ca0f0e878d381c3dc0c9afe958a810e4427 (patch)
tree7766fd3354b2b0f0418c5ff317df0696b41dbcc1 /src/libcore
parent566bcf2225634ee4d4698247fe89364440eb534c (diff)
downloadrust-bb833ca0f0e878d381c3dc0c9afe958a810e4427.tar.gz
rust-bb833ca0f0e878d381c3dc0c9afe958a810e4427.zip
librustc: Stop parsing `impl Type : Trait` and fix several declarations that slipped through. r=tjc
Diffstat (limited to 'src/libcore')
-rw-r--r--src/libcore/at_vec.rs2
-rw-r--r--src/libcore/num/f32.rs2
-rw-r--r--src/libcore/num/f64.rs2
-rw-r--r--src/libcore/num/float.rs2
-rw-r--r--src/libcore/num/int-template/i16.rs2
-rw-r--r--src/libcore/num/int-template/i32.rs2
-rw-r--r--src/libcore/num/int-template/i64.rs2
-rw-r--r--src/libcore/num/int-template/i8.rs2
-rw-r--r--src/libcore/num/int-template/int.rs2
-rw-r--r--src/libcore/num/uint-template/u16.rs2
-rw-r--r--src/libcore/num/uint-template/u32.rs2
-rw-r--r--src/libcore/num/uint-template/u64.rs2
-rw-r--r--src/libcore/num/uint-template/u8.rs2
-rw-r--r--src/libcore/num/uint-template/uint.rs4
-rw-r--r--src/libcore/pipes.rs6
-rw-r--r--src/libcore/str.rs2
-rw-r--r--src/libcore/to_bytes.rs4
17 files changed, 21 insertions, 21 deletions
diff --git a/src/libcore/at_vec.rs b/src/libcore/at_vec.rs
index 71af60314da..565fe11d3f4 100644
--- a/src/libcore/at_vec.rs
+++ b/src/libcore/at_vec.rs
@@ -173,7 +173,7 @@ pub mod traits {
     use kinds::Copy;
     use ops::Add;
 
-    pub impl<T: Copy> @[T] : Add<&[const T],@[T]> {
+    pub impl<T: Copy> Add<&[const T],@[T]> for @[T] {
         #[inline(always)]
         pure fn add(&self, rhs: & &self/[const T]) -> @[T] {
             append(*self, (*rhs))
diff --git a/src/libcore/num/f32.rs b/src/libcore/num/f32.rs
index 8350ba42591..59c4ce6b9dc 100644
--- a/src/libcore/num/f32.rs
+++ b/src/libcore/num/f32.rs
@@ -282,7 +282,7 @@ impl num::One for f32 {
     static pure fn one() -> f32 { 1.0 }
 }
 
-pub impl f32: NumCast {
+pub impl NumCast for f32 {
     /**
      * Cast `n` to an `f32`
      */
diff --git a/src/libcore/num/f64.rs b/src/libcore/num/f64.rs
index 474067a1860..b24c76a5e0a 100644
--- a/src/libcore/num/f64.rs
+++ b/src/libcore/num/f64.rs
@@ -297,7 +297,7 @@ impl cmp::Ord for f64 {
     pure fn gt(&self, other: &f64) -> bool { (*self) > (*other) }
 }
 
-pub impl f64: NumCast {
+pub impl NumCast for f64 {
     /**
      * Cast `n` to an `f64`
      */
diff --git a/src/libcore/num/float.rs b/src/libcore/num/float.rs
index 0f0b721e462..51b115e84c3 100644
--- a/src/libcore/num/float.rs
+++ b/src/libcore/num/float.rs
@@ -415,7 +415,7 @@ impl num::One for float {
     static pure fn one() -> float { 1.0 }
 }
 
-pub impl float: NumCast {
+pub impl NumCast for float {
     /**
      * Cast `n` to a `float`
      */
diff --git a/src/libcore/num/int-template/i16.rs b/src/libcore/num/int-template/i16.rs
index 76725e3895b..1352959306a 100644
--- a/src/libcore/num/int-template/i16.rs
+++ b/src/libcore/num/int-template/i16.rs
@@ -17,7 +17,7 @@ mod inst {
     pub const bits: uint = ::u16::bits;
 }
 
-pub impl i16: NumCast {
+pub impl NumCast for i16 {
     /**
      * Cast `n` to a `i16`
      */
diff --git a/src/libcore/num/int-template/i32.rs b/src/libcore/num/int-template/i32.rs
index 1c2d60a80ee..e8dd603d507 100644
--- a/src/libcore/num/int-template/i32.rs
+++ b/src/libcore/num/int-template/i32.rs
@@ -17,7 +17,7 @@ mod inst {
     pub const bits: uint = ::u32::bits;
 }
 
-pub impl i32: NumCast {
+pub impl NumCast for i32 {
     /**
      * Cast `n` to a `i32`
      */
diff --git a/src/libcore/num/int-template/i64.rs b/src/libcore/num/int-template/i64.rs
index d7413920a64..6f1371f8ee2 100644
--- a/src/libcore/num/int-template/i64.rs
+++ b/src/libcore/num/int-template/i64.rs
@@ -17,7 +17,7 @@ mod inst {
     pub const bits: uint = ::u64::bits;
 }
 
-pub impl i64: NumCast {
+pub impl NumCast for i64 {
     /**
      * Cast `n` to a `i64`
      */
diff --git a/src/libcore/num/int-template/i8.rs b/src/libcore/num/int-template/i8.rs
index f2577020128..46c734b9548 100644
--- a/src/libcore/num/int-template/i8.rs
+++ b/src/libcore/num/int-template/i8.rs
@@ -17,7 +17,7 @@ mod inst {
     pub const bits: uint = ::u8::bits;
 }
 
-pub impl i8: NumCast {
+pub impl NumCast for i8 {
     /**
      * Cast `n` to a `i8`
      */
diff --git a/src/libcore/num/int-template/int.rs b/src/libcore/num/int-template/int.rs
index 4ba1570e135..83ef421b705 100644
--- a/src/libcore/num/int-template/int.rs
+++ b/src/libcore/num/int-template/int.rs
@@ -58,7 +58,7 @@ mod inst {
     }
 }
 
-pub impl int: NumCast {
+pub impl NumCast for int {
     /**
      * Cast `n` to a `int`
      */
diff --git a/src/libcore/num/uint-template/u16.rs b/src/libcore/num/uint-template/u16.rs
index 57e1f5283f6..315ff84cc23 100644
--- a/src/libcore/num/uint-template/u16.rs
+++ b/src/libcore/num/uint-template/u16.rs
@@ -19,7 +19,7 @@ mod inst {
     pub const bits: uint = 16;
 }
 
-pub impl u16: NumCast {
+pub impl NumCast for u16 {
     /**
      * Cast `n` to a `u16`
      */
diff --git a/src/libcore/num/uint-template/u32.rs b/src/libcore/num/uint-template/u32.rs
index 7099d15c40b..834feff292c 100644
--- a/src/libcore/num/uint-template/u32.rs
+++ b/src/libcore/num/uint-template/u32.rs
@@ -19,7 +19,7 @@ mod inst {
     pub const bits: uint = 32;
 }
 
-pub impl u32: NumCast {
+pub impl NumCast for u32 {
     /**
      * Cast `n` to a `u32`
      */
diff --git a/src/libcore/num/uint-template/u64.rs b/src/libcore/num/uint-template/u64.rs
index f4d1482de90..b661b3b20b1 100644
--- a/src/libcore/num/uint-template/u64.rs
+++ b/src/libcore/num/uint-template/u64.rs
@@ -19,7 +19,7 @@ mod inst {
     pub const bits: uint = 64;
 }
 
-pub impl u64: num::NumCast {
+pub impl NumCast for u64 {
     /**
      * Cast `n` to a `u64`
      */
diff --git a/src/libcore/num/uint-template/u8.rs b/src/libcore/num/uint-template/u8.rs
index e2f8e00db81..c2be9e252d9 100644
--- a/src/libcore/num/uint-template/u8.rs
+++ b/src/libcore/num/uint-template/u8.rs
@@ -26,7 +26,7 @@ mod inst {
     pub pure fn is_ascii(x: T) -> bool { return 0 as T == x & 128 as T; }
 }
 
-pub impl u8: NumCast {
+pub impl NumCast for u8 {
     /**
      * Cast `n` to a `u8`
      */
diff --git a/src/libcore/num/uint-template/uint.rs b/src/libcore/num/uint-template/uint.rs
index cfb445cbdc8..475ae243915 100644
--- a/src/libcore/num/uint-template/uint.rs
+++ b/src/libcore/num/uint-template/uint.rs
@@ -110,7 +110,7 @@ pub mod inst {
         return true;
     }
 
-    pub impl uint: iter::Times {
+    pub impl iter::Times for uint {
         #[inline(always)]
         /**
         * A convenience form for basic iteration. Given a uint `x`,
@@ -209,7 +209,7 @@ pub mod inst {
     }
 }
 
-pub impl uint: NumCast {
+pub impl NumCast for uint {
     /**
      * Cast `n` to a `uint`
      */
diff --git a/src/libcore/pipes.rs b/src/libcore/pipes.rs
index b9e07135f2c..f0108fe85b7 100644
--- a/src/libcore/pipes.rs
+++ b/src/libcore/pipes.rs
@@ -1211,11 +1211,11 @@ pub trait Select2<T: Owned, U: Owned> {
     fn select() -> Either<T, U>;
 }
 
-impl<T: Owned, U: Owned,
+impl<T: Owned,
+     U: Owned,
      Left: Selectable GenericPort<T>,
      Right: Selectable GenericPort<U>>
-    (Left, Right): Select2<T, U> {
-
+     Select2<T,U> for (Left, Right) {
     fn select() -> Either<T, U> {
         match self {
           (ref lp, ref rp) => match select2i(lp, rp) {
diff --git a/src/libcore/str.rs b/src/libcore/str.rs
index a95d4236ce9..3c15a89081d 100644
--- a/src/libcore/str.rs
+++ b/src/libcore/str.rs
@@ -2328,7 +2328,7 @@ pub trait OwnedStr {
     fn push_char(&mut self, c: char);
 }
 
-pub impl ~str : OwnedStr {
+pub impl OwnedStr for ~str {
     fn push_str(&mut self, v: &str) {
         push_str(self, v);
     }
diff --git a/src/libcore/to_bytes.rs b/src/libcore/to_bytes.rs
index 58ecf2560ac..10efa9196a7 100644
--- a/src/libcore/to_bytes.rs
+++ b/src/libcore/to_bytes.rs
@@ -170,7 +170,7 @@ impl IterBytes for char {
 pub mod x32 {
     use to_bytes::{Cb, IterBytes};
 
-    pub impl uint: IterBytes {
+    pub impl IterBytes for uint {
         #[inline(always)]
         pure fn iter_bytes(&self, lsb0: bool, f: Cb) {
             (*self as u32).iter_bytes(lsb0, f)
@@ -182,7 +182,7 @@ pub mod x32 {
 pub mod x64 {
     use to_bytes::{Cb, IterBytes};
 
-    pub impl uint: IterBytes {
+    pub impl IterBytes for uint {
         #[inline(always)]
         pure fn iter_bytes(&self, lsb0: bool, f: Cb) {
             (*self as u64).iter_bytes(lsb0, f)