async-std icon indicating copy to clipboard operation
async-std copied to clipboard

docs compile failure on nightly

Open Fishrock123 opened this issue 4 years ago • 0 comments

error[E0433]: failed to resolve: could not find `windows` in `os`
  --> src/os/windows/fs.rs:29:37
   |
29 |     spawn_blocking(move || std::os::windows::fs::symlink_dir(&src, &dst)).await
   |                                     ^^^^^^^ could not find `windows` in `os`

error[E0433]: failed to resolve: could not find `windows` in `os`
  --> src/os/windows/fs.rs:54:37
   |
54 |     spawn_blocking(move || std::os::windows::fs::symlink_file(&src, &dst)).await
   |                                     ^^^^^^^ could not find `windows` in `os`

warning: hidden lifetime parameters in types are deprecated
   --> src/future/future/mod.rs:131:48
    |
131 |         fn poll(self: Pin<&mut Self>, cx: &mut Context) -> Poll<Self::Output>;
    |                                                ^^^^^^^- help: indicate the anonymous lifetime: `<'_>`
    |
note: the lint level is defined here
   --> src/lib.rs:280:54
    |
280 | #![warn(missing_docs, missing_debug_implementations, rust_2018_idioms)]
    |                                                      ^^^^^^^^^^^^^^^^
    = note: `#[warn(elided_lifetimes_in_paths)]` implied by `#[warn(rust_2018_idioms)]`

warning: unknown `doc` attribute `unstable`
   --> src/utils.rs:145:46
    |
145 |               #[cfg_attr(feature = "docs", doc(unstable))]
    |                                                ^^^^^^^^
    |
   ::: src/lib.rs:336:1
    |
336 | / cfg_unstable_default! {
337 | |     #[doc(inline)]
338 | |     pub use std::{write, writeln};
339 | | }
    | |_- in this macro invocation
    |
    = note: `#[warn(invalid_doc_attributes)]` on by default
    = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
    = note: for more information, see issue #82730 <https://github.com/rust-lang/rust/issues/82730>
    = note: this warning originates in the macro `cfg_unstable_default` (in Nightly builds, run with -Z macro-backtrace for more info)

warning: unknown `doc` attribute `unstable`
   --> src/utils.rs:145:46
    |
145 |               #[cfg_attr(feature = "docs", doc(unstable))]
    |                                                ^^^^^^^^
    |
   ::: src/lib.rs:336:1
    |
336 | / cfg_unstable_default! {
337 | |     #[doc(inline)]
338 | |     pub use std::{write, writeln};
339 | | }
    | |_- in this macro invocation
    |
    = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
    = note: for more information, see issue #82730 <https://github.com/rust-lang/rust/issues/82730>
    = note: this warning originates in the macro `cfg_unstable_default` (in Nightly builds, run with -Z macro-backtrace for more info)

warning: unknown `doc` attribute `unstable`
   --> src/utils.rs:145:46
    |
145 |               #[cfg_attr(feature = "docs", doc(unstable))]
    |                                                ^^^^^^^^
    |
   ::: src/future/future/mod.rs:19:1
    |
19  | / cfg_unstable_default! {
20  | |     use crate::future::timeout::TimeoutFuture;
21  | | }
    | |_- in this macro invocation
    |
    = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
    = note: for more information, see issue #82730 <https://github.com/rust-lang/rust/issues/82730>
    = note: this warning originates in the macro `cfg_unstable_default` (in Nightly builds, run with -Z macro-backtrace for more info)

warning: the trait `stream::stream::Stream` cannot be made into an object
   --> src/stream/stream/mod.rs:263:12
    |
263 |         fn next(&mut self) -> impl Future<Output = Option<Self::Item>> + '_ [NextFuture<'_, Self>]
    |            ^^^^
    |
    = note: `#[warn(where_clauses_object_safety)]` on by default
    = warning: this was previously accepted by the compiler but is being phased out; it will become a hard error in a future release!
    = note: for more information, see issue #51443 <https://github.com/rust-lang/rust/issues/51443>
note: for a trait to be "object safe" it needs to allow building a vtable to allow the call to be resolvable dynamically; for more information visit <https://doc.rust-lang.org/reference/items/traits.html#object-safety>
   --> src/stream/stream/mod.rs:263:12
    |
172 |     pub trait Stream {
    |               ------ this trait cannot be made into an object...
...
263 |         fn next(&mut self) -> impl Future<Output = Option<Self::Item>> + '_ [NextFuture<'_, Self>]
    |            ^^^^ ...because method `next` references the `Self` type in its `where` clause
    = help: consider moving `next` to another trait

error[E0038]: the trait `stream::stream::Stream` cannot be made into an object
    --> src/os/unix/net/listener.rs:180:23
     |
180  |     incoming: Pin<Box<dyn Stream<Item = io::Result<Async<StdUnixStream>>> + Send + Sync + 'a>>,
     |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ `stream::stream::Stream` cannot be made into an object
     |
     = help: consider moving `by_ref` to another trait
note: for a trait to be "object safe" it needs to allow building a vtable to allow the call to be resolvable dynamically; for more information visit <https://doc.rust-lang.org/reference/items/traits.html#object-safety>
    --> src/stream/stream/mod.rs:1516:33
     |
172  |     pub trait Stream {
     |               ------ this trait cannot be made into an object...
...
1516 |         fn by_ref(&mut self) -> &mut Self {
     |                                 ^^^^^^^^^ ...because method `by_ref` references the `Self` type in its return type

error[E0038]: the trait `stream::stream::Stream` cannot be made into an object
    --> src/net/tcp/listener.rs:189:23
     |
189  |     incoming: Pin<Box<dyn Stream<Item = io::Result<Async<StdTcpStream>>> + Send + Sync + 'a>>,
     |                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ `stream::stream::Stream` cannot be made into an object
     |
     = help: consider moving `by_ref` to another trait
note: for a trait to be "object safe" it needs to allow building a vtable to allow the call to be resolvable dynamically; for more information visit <https://doc.rust-lang.org/reference/items/traits.html#object-safety>
    --> src/stream/stream/mod.rs:1516:33
     |
172  |     pub trait Stream {
     |               ------ this trait cannot be made into an object...
...
1516 |         fn by_ref(&mut self) -> &mut Self {
     |                                 ^^^^^^^^^ ...because method `by_ref` references the `Self` type in its return type

Some errors have detailed explanations: E0038, E0433.
For more information about an error, try `rustc --explain E0038`.
warning: `async-std` (lib) generated 5 warnings
error: could not compile `async-std` due to 4 previous errors; 5 warnings emitted

cargo +nightly check --features docs

Fishrock123 avatar Aug 11 '21 19:08 Fishrock123