Closed szagi3891 closed 8 years ago
@carllerche :
When I replace this line:
-use tokio_proto::{pipeline, server, NewService};
-use tokio_service::{Service};
+use tokio_proto::{pipeline, server};
+use tokio_service::{Service, NewService};
I get new errors :
grzegorz@grzegorz:~/Pulpit/rust/tokio-minihttp$ cargo run --example hello_world
Compiling tokio-minihttp v0.1.0 (file:///home/grzegorz/Pulpit/rust/tokio-minihttp)
error[E0277]: the trait bound `futures::Map<<T as tokio_service::Service>::Future, fn(response::Response) -> tokio_proto::pipeline::Message<response::Response, futures::stream::Receiver<(), std::io::Error>>>: futures::Future` is not satisfied
--> src/lib.rs:81:9
|
81 | impl<T> Service for HttpService<T>
| ^^^^^^^ trait `futures::Map<<T as tokio_service::Service>::Future, fn(response::Response) -> tokio_proto::pipeline::Message<response::Response, futures::stream::Receiver<(), std::io::Error>>>: futures::Future` not satisfied
|
= note: required by `tokio_service::Service`
error[E0277]: the trait bound `<T as tokio_service::Service>::Future: futures::Future` is not satisfied
--> src/lib.rs:87:5
|
87 | type Future = Map<T::Future, fn(Response) -> pipeline::Message<Response, Receiver<(), io::Error>>>;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ trait `<T as tokio_service::Service>::Future: futures::Future` not satisfied
|
= help: consider adding a `where <T as tokio_service::Service>::Future: futures::Future` bound
= note: required by `futures::Map`
error[E0277]: the trait bound `<T as tokio_service::Service>::Future: futures::Future` is not satisfied
--> src/lib.rs:89:5
|
89 | fn call(&self, req: Request) -> Self::Future {
| ^ trait `<T as tokio_service::Service>::Future: futures::Future` not satisfied
|
= help: consider adding a `where <T as tokio_service::Service>::Future: futures::Future` bound
= note: required by `futures::Map`
error: aborting due to 3 previous errors
error: Could not compile `tokio-minihttp`.
To learn more, run the command again with --verbose.
grzegorz@grzegorz:~/Pulpit/rust/tokio-minihttp$
I do not know what to do with it :(
Fixed by 4249fa1c20fdd6aa206e2e274a4e755988626902