diff options
| author | bors <bors@rust-lang.org> | 2014-03-19 23:21:49 -0700 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2014-03-19 23:21:49 -0700 |
| commit | 7aded2adb6782d8188a631250ab8d72c82bd070c (patch) | |
| tree | e8b2187211cc16ac15dd6a53334dbb8429f666e3 /src/libstd/sync/mpmc_bounded_queue.rs | |
| parent | d8590e2c9ce7fd48df03d347f591d6892c6e1599 (diff) | |
| parent | ce620320a20baa1428e679c751b1b4a8d8556ca1 (diff) | |
| download | rust-7aded2adb6782d8188a631250ab8d72c82bd070c.tar.gz rust-7aded2adb6782d8188a631250ab8d72c82bd070c.zip | |
auto merge of #12772 : thestinger/rust/slice, r=alexcrichton
Closes #12702
Diffstat (limited to 'src/libstd/sync/mpmc_bounded_queue.rs')
| -rw-r--r-- | src/libstd/sync/mpmc_bounded_queue.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libstd/sync/mpmc_bounded_queue.rs b/src/libstd/sync/mpmc_bounded_queue.rs index ad0434c634a..95f592baff0 100644 --- a/src/libstd/sync/mpmc_bounded_queue.rs +++ b/src/libstd/sync/mpmc_bounded_queue.rs @@ -35,7 +35,7 @@ use num::next_power_of_two; use option::{Option, Some, None}; use sync::arc::UnsafeArc; use sync::atomics::{AtomicUint,Relaxed,Release,Acquire}; -use vec; +use slice; struct Node<T> { sequence: AtomicUint, @@ -69,8 +69,8 @@ impl<T: Send> State<T> { } else { capacity }; - let buffer = vec::from_fn(capacity, |i:uint| { - Node{sequence:AtomicUint::new(i),value:None} + let buffer = slice::from_fn(capacity, |i| { + Node { sequence:AtomicUint::new(i), value: None } }); State{ pad0: [0, ..64], |
