diff options
| author | bors <bors@rust-lang.org> | 2013-06-29 12:02:05 -0700 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2013-06-29 12:02:05 -0700 |
| commit | c86df3a65cc239fd69b9a8d628808498cdb07e0d (patch) | |
| tree | b2557de482d3c0946cd683bd92dff65a1adf15f4 /src/libstd/at_vec.rs | |
| parent | 88830996d811be3ff833ba590c98f28daaf31f43 (diff) | |
| parent | 3bad7129ebb13d7a4c0a7965aeb5bd536cc0f5f0 (diff) | |
auto merge of #7342 : alexcrichton/rust/assort-cleanup, r=cmr
This removes usage of `&const` throughout the standard libraries/compiler, and it removes some extraneous fields in the AST now that unique boxes always inherit their mutability.
Diffstat (limited to 'src/libstd/at_vec.rs')
| -rw-r--r-- | src/libstd/at_vec.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libstd/at_vec.rs b/src/libstd/at_vec.rs index 5a2f948600a..325ce097cd5 100644 --- a/src/libstd/at_vec.rs +++ b/src/libstd/at_vec.rs @@ -108,7 +108,7 @@ pub fn build_sized_opt<A>(size: Option<uint>, /// Iterates over the `rhs` vector, copying each element and appending it to the /// `lhs`. Afterwards, the `lhs` is then returned for use again. #[inline] -pub fn append<T:Copy>(lhs: @[T], rhs: &const [T]) -> @[T] { +pub fn append<T:Copy>(lhs: @[T], rhs: &[T]) -> @[T] { do build_sized(lhs.len() + rhs.len()) |push| { for lhs.iter().advance |x| { push(copy *x); } for uint::range(0, rhs.len()) |i| { push(copy rhs[i]); } @@ -180,9 +180,9 @@ pub mod traits { use kinds::Copy; use ops::Add; - impl<'self,T:Copy> Add<&'self const [T],@[T]> for @[T] { + impl<'self,T:Copy> Add<&'self [T],@[T]> for @[T] { #[inline] - fn add(&self, rhs: & &'self const [T]) -> @[T] { + fn add(&self, rhs: & &'self [T]) -> @[T] { append(*self, (*rhs)) } } |
