Skip to content

Commit bb833ca

Browse files
committed
librustc: Stop parsing impl Type : Trait and fix several declarations that slipped through. r=tjc
1 parent 566bcf2 commit bb833ca

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

82 files changed

+327
-424
lines changed

src/libcargo/cargo.rc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ pub struct Package {
7171
versions: ~[(~str, ~str)]
7272
}
7373

74-
pub impl Package : cmp::Ord {
74+
pub impl cmp::Ord for Package {
7575
pure fn lt(&self, other: &Package) -> bool {
7676
if (*self).name.lt(&(*other).name) { return true; }
7777
if (*other).name.lt(&(*self).name) { return false; }

src/libcore/at_vec.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ pub mod traits {
173173
use kinds::Copy;
174174
use ops::Add;
175175

176-
pub impl<T: Copy> @[T] : Add<&[const T],@[T]> {
176+
pub impl<T: Copy> Add<&[const T],@[T]> for @[T] {
177177
#[inline(always)]
178178
pure fn add(&self, rhs: & &self/[const T]) -> @[T] {
179179
append(*self, (*rhs))

src/libcore/num/f32.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,7 @@ impl num::One for f32 {
282282
static pure fn one() -> f32 { 1.0 }
283283
}
284284

285-
pub impl f32: NumCast {
285+
pub impl NumCast for f32 {
286286
/**
287287
* Cast `n` to an `f32`
288288
*/

src/libcore/num/f64.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@ impl cmp::Ord for f64 {
297297
pure fn gt(&self, other: &f64) -> bool { (*self) > (*other) }
298298
}
299299

300-
pub impl f64: NumCast {
300+
pub impl NumCast for f64 {
301301
/**
302302
* Cast `n` to an `f64`
303303
*/

src/libcore/num/float.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -415,7 +415,7 @@ impl num::One for float {
415415
static pure fn one() -> float { 1.0 }
416416
}
417417
418-
pub impl float: NumCast {
418+
pub impl NumCast for float {
419419
/**
420420
* Cast `n` to a `float`
421421
*/

src/libcore/num/int-template/i16.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ mod inst {
1717
pub const bits: uint = ::u16::bits;
1818
}
1919

20-
pub impl i16: NumCast {
20+
pub impl NumCast for i16 {
2121
/**
2222
* Cast `n` to a `i16`
2323
*/

src/libcore/num/int-template/i32.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ mod inst {
1717
pub const bits: uint = ::u32::bits;
1818
}
1919

20-
pub impl i32: NumCast {
20+
pub impl NumCast for i32 {
2121
/**
2222
* Cast `n` to a `i32`
2323
*/

src/libcore/num/int-template/i64.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ mod inst {
1717
pub const bits: uint = ::u64::bits;
1818
}
1919

20-
pub impl i64: NumCast {
20+
pub impl NumCast for i64 {
2121
/**
2222
* Cast `n` to a `i64`
2323
*/

src/libcore/num/int-template/i8.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ mod inst {
1717
pub const bits: uint = ::u8::bits;
1818
}
1919

20-
pub impl i8: NumCast {
20+
pub impl NumCast for i8 {
2121
/**
2222
* Cast `n` to a `i8`
2323
*/

src/libcore/num/int-template/int.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ mod inst {
5858
}
5959
}
6060

61-
pub impl int: NumCast {
61+
pub impl NumCast for int {
6262
/**
6363
* Cast `n` to a `int`
6464
*/

0 commit comments

Comments
 (0)