Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ script:
- cargo doc --no-deps
- cargo doc --no-deps --manifest-path futures-cpupool/Cargo.toml
- if [ "$BENCH" = "1" ]; then cargo bench; fi
- if [[ "$TRAVIS_RUST_VERSION" == nightly ]]; then cargo test --features nightly; fi
env:
global:
- secure: "iwVcMVIF7ZSY82fK5UyyUvVvJxMSYrbZawh1+4Oi8pvOdYq1gptcDoOC8jxWwCwrNF1b+/85n+jlEUngEqqSmV5PjAbWPjoc+u4Zn7CRi1AlxoUlvHPiQm4vM4Mkkd6GsqoIZttCeedU9m/w0nQ18uUtK8uD6vr2FVdcMnUnkYQAxuGOowGLrwidukzfBXMCu/JrwKMIbt61knAFiI/KJknu0h1mRrhpeF/sQ3tJFzRRcQeFJkbfwDzltMpPo1hq5D3HI4ONjYi/qO2pwUhDk4umfp9cLW9MS8rQvptxJTQmWemHi+f2/U4ld6a0URL6kEuMkt/EbH0A74eFtlicfRs44dX9MlWoqbLypnC3ymqmHcpwcwNA3HmZyg800MTuU+BPK41HIPdO9tPpxjHEiqvNDknH7qs+YBnis0eH7DHJgEjXq651PjW7pm+rnHPwsj+OzKE1YBNxBQZZDkS3VnZJz+O4tVsOzc3IOz0e+lf7VVuI17C9haj117nKp3umC4MVBA0S8RfreFgqpyDeY2zwcqOr0YOlEGGRl0vyWP8Qcxx12kQ7+doLolt6Kxda4uO0hKRmIF6+qki1T+L7v8BOGOtCncz4f7IX48eQ7+Wu0OtglRn45qAa3CxjUuW6xX3KSNH66PCXV0Jtp8Ga2SSevX2wtbbFu9f+9R+PQY4="
Expand Down
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ appveyor = { repository = "rust-lang-nursery/futures-rs" }
[dependencies]

[features]
nightly = []
use_std = []
with-deprecated = []
default = ["use_std", "with-deprecated"]
Expand Down
1 change: 1 addition & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,7 @@
#![no_std]
#![deny(missing_docs, missing_debug_implementations)]
#![doc(html_root_url = "https://docs.rs/futures/0.1")]
#![cfg_attr(feature = "nightly", feature(pin))]

#[macro_use]
#[cfg(feature = "use_std")]
Expand Down
8 changes: 8 additions & 0 deletions src/task_impl/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -712,3 +712,11 @@ impl<T: Notify> From<&'static T> for NotifyHandle {
unsafe { NotifyHandle::new(src as *const _ as *mut StaticRef<T>) }
}
}

#[cfg(feature = "nightly")]
mod nightly {
use super::NotifyHandle;
use core::marker::Unpin;

impl Unpin for NotifyHandle {}
}
9 changes: 9 additions & 0 deletions src/task_impl/std/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -700,3 +700,12 @@ impl<T> From<Arc<T>> for NotifyHandle
}
}
}

#[cfg(feature = "nightly")]
mod nightly {
use super::{TaskUnpark, UnparkEvents};
use core::marker::Unpin;

impl Unpin for TaskUnpark {}
impl Unpin for UnparkEvents {}
}