Some tests involving futures-rs
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

12345678910111213141516171819202122232425
  1. Compiling futuretest v0.1.0 (file:///mnt/c/Users/Mahmoud/git/futuretest)
  2. error[E0271]: type mismatch resolving `<futures::FutureResult<(), std::string::String> as futures::IntoFuture>::Error == &str`
  3. --> src/main.rs:12:10
  4. |
  5. 12 | .and_then(|_|
  6. | ^^^^^^^^ expected struct `std::string::String`, found &str
  7. |
  8. = note: expected type `std::string::String`
  9. found type `&str`
  10. error[E0271]: type mismatch resolving `<futures::FutureResult<(), std::string::String> as futures::IntoFuture>::Error == &str`
  11. --> src/main.rs:19:10
  12. |
  13. 19 | core.run(f).unwrap();
  14. | ^^^ expected struct `std::string::String`, found &str
  15. |
  16. = note: expected type `std::string::String`
  17. found type `&str`
  18. = note: required because of the requirements on the impl of `futures::Future` for `futures::AndThen<futures::MapErr<futures::FutureResult<(), ()>, [closure@src/main.rs:11:18: 11:43]>, futures::FutureResult<(), std::string::String>, [closure@src/main.rs:12:19: 15:14]>`
  19. error: aborting due to 2 previous errors
  20. error: Could not compile `futuretest`.
  21. To learn more, run the command again with --verbose.