Skip to content

Commit

Permalink
Update to smallvec 0.3
Browse files Browse the repository at this point in the history
  • Loading branch information
mbrubeck committed Dec 6, 2016
1 parent 64c1635 commit 9be9c83
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ language: rust
sudo: false

rust:
- 1.8.0
- 1.9.0
- stable
- beta
- nightly
Expand Down
8 changes: 4 additions & 4 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ environment:
- TARGET: nightly-i686-pc-windows-msvc
- TARGET: nightly-x86_64-pc-windows-gnu
- TARGET: nightly-i686-pc-windows-gnu
- TARGET: 1.8.0-x86_64-pc-windows-msvc
- TARGET: 1.8.0-i686-pc-windows-msvc
- TARGET: 1.8.0-x86_64-pc-windows-gnu
- TARGET: 1.8.0-i686-pc-windows-gnu
- TARGET: 1.9.0-x86_64-pc-windows-msvc
- TARGET: 1.9.0-i686-pc-windows-msvc
- TARGET: 1.9.0-x86_64-pc-windows-gnu
- TARGET: 1.9.0-i686-pc-windows-gnu

install:
- SET PATH=C:\Python27;C:\Python27\Scripts;%PATH%;%APPDATA%\Python\Scripts
Expand Down
2 changes: 1 addition & 1 deletion core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ repository = "https://github.com/Amanieu/parking_lot"
keywords = ["mutex", "condvar", "rwlock", "once", "thread"]

[dependencies]
smallvec = "0.1"
smallvec = "0.3"
rand = "0.3"

[target.'cfg(unix)'.dependencies]
Expand Down
6 changes: 3 additions & 3 deletions core/src/parking_lot.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ use std::time::{Instant, Duration};
use std::cell::{Cell, UnsafeCell};
use std::ptr;
use std::mem;
use smallvec::SmallVec8;
use smallvec::SmallVec;
use rand::{self, XorShiftRng, Rng};
use thread_parker::ThreadParker;
use word_lock::WordLock;
Expand Down Expand Up @@ -723,7 +723,7 @@ pub unsafe fn unpark_all(key: usize, unpark_token: UnparkToken) -> usize {
let mut link = &bucket.queue_head;
let mut current = bucket.queue_head.get();
let mut previous = ptr::null();
let mut threads = SmallVec8::new();
let mut threads = SmallVec::<[_; 8]>::new();
while !current.is_null() {
if (*current).key.load(Ordering::Relaxed) == key {
// Remove the thread from the queue
Expand Down Expand Up @@ -942,7 +942,7 @@ unsafe fn unpark_filter_internal(key: usize,
let mut link = &bucket.queue_head;
let mut current = bucket.queue_head.get();
let mut previous = ptr::null();
let mut threads = SmallVec8::new();
let mut threads = SmallVec::<[_; 8]>::new();
let mut result = UnparkResult {
unparked_threads: 0,
have_more_threads: false,
Expand Down

0 comments on commit 9be9c83

Please sign in to comment.