Skip to content

Make CI successful #1407

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jan 14, 2019
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
8 changes: 7 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ matrix:

# When updating this, the reminder to update the minimum required version in README.md.
- name: cargo test (minimum required version)
rust: nightly-2018-12-26
rust: nightly-2019-01-11

- name: cargo clippy
rust: nightly
Expand Down Expand Up @@ -64,8 +64,10 @@ matrix:
script:
- cargo build --manifest-path futures/Cargo.toml --features tokio-compat,io-compat

# Allow build fail until #1396 is fixed.
- name: cargo build --target=thumbv6m-none-eabi
rust: nightly
env: ALLOW_FAILURES=true
install:
- rustup target add thumbv6m-none-eabi
script:
Expand Down Expand Up @@ -100,6 +102,10 @@ matrix:
- git commit -m "Add API docs for $TRAVIS_TAG"
- git push origin master

allow_failures:
- rust: nightly
env: ALLOW_FAILURES=true

script:
- cargo test --all --all-features
- cargo test --all --all-features --release
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ Now, you can use futures-rs:
use futures::future::Future; // Note: It's not `futures_preview`
```

The current version of futures-rs requires Rust nightly 2018-12-26 or later.
The current version of futures-rs requires Rust nightly 2019-01-11 or later.

### Feature `std`

Expand Down
2 changes: 1 addition & 1 deletion futures-util/src/future/fuse.rs
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ impl<Fut: Future> Future for Fuse<Fut> {
None => return Poll::Pending,
};

Pin::set(self.as_mut().future(), None);
Pin::set(&mut self.as_mut().future(), None);
Poll::Ready(v)
}
}
2 changes: 1 addition & 1 deletion futures-util/src/future/into_stream.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ impl<Fut: Future> Stream for IntoStream<Fut> {
None => return Poll::Ready(None),
};

Pin::set(self.as_mut().future(), None);
Pin::set(&mut self.as_mut().future(), None);
Poll::Ready(Some(v))
}
}
2 changes: 1 addition & 1 deletion futures-util/src/future/maybe_done.rs
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ impl<Fut: Future> Future for MaybeDone<Fut> {
MaybeDone::Gone => panic!("MaybeDone polled after value taken"),
}
};
Pin::set(self, MaybeDone::Done(res));
Pin::set(&mut self, MaybeDone::Done(res));
Poll::Ready(())
}
}
2 changes: 1 addition & 1 deletion futures-util/src/sink/with_flat_map.rs
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ where
};
}
}
Pin::set(stream, None);
Pin::set(&mut stream, None);
Poll::Ready(Ok(()))
}
}
Expand Down
2 changes: 1 addition & 1 deletion futures-util/src/stream/unfold.rs
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ impl<T, F, Fut, It> Stream for Unfold<T, F, Fut>
) -> Poll<Option<It>> {
if let Some(state) = self.as_mut().state().take() {
let fut = (self.as_mut().f())(state);
Pin::set(self.as_mut().fut(), Some(fut));
Pin::set(&mut self.as_mut().fut(), Some(fut));
}

let step = ready!(self.as_mut().fut().as_pin_mut().unwrap().poll(lw));
Expand Down
4 changes: 2 additions & 2 deletions futures-util/src/try_future/flatten_sink.rs
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ where
Waiting(f) => try_ready!(f.try_poll(lw)),
Closed => panic!("poll_ready called after eof"),
};
Pin::set(self.as_mut(), FlattenSink(Ready(resolved_stream)));
Pin::set(&mut self.as_mut(), FlattenSink(Ready(resolved_stream)));
if let Ready(resolved_stream) = self.project_pin() {
resolved_stream.poll_ready(lw)
} else {
Expand Down Expand Up @@ -99,7 +99,7 @@ where
Waiting(_) | Closed => Poll::Ready(Ok(())),
};
if res.is_ready() {
Pin::set(self, FlattenSink(Closed));
Pin::set(&mut self, FlattenSink(Closed));
}
res
}
Expand Down
4 changes: 2 additions & 2 deletions futures-util/src/try_stream/try_for_each.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,12 @@ impl<St, Fut, F> Future for TryForEach<St, Fut, F>
if let Some(future) = self.as_mut().future().as_pin_mut() {
try_ready!(future.try_poll(lw));
}
Pin::set(self.as_mut().future(), None);
Pin::set(&mut self.as_mut().future(), None);

match ready!(self.as_mut().stream().try_poll_next(lw)) {
Some(Ok(e)) => {
let future = (self.as_mut().f())(e);
Pin::set(self.as_mut().future(), Some(future));
Pin::set(&mut self.as_mut().future(), Some(future));
}
Some(Err(e)) => return Poll::Ready(Err(e)),
None => return Poll::Ready(Ok(())),
Expand Down