rust/src/test
bors dfd43f0fdd Auto merge of #63870 - estebank:async-fn-call, r=oli-obk
Suggest call fn ctor passed as arg to fn with type param bounds

_Reviewer note: the relevant changes are in the second commit, the first is simple and mechanical, but verbose._

When forgetting to call a fn in an argument position to an fn that has a generic bound:

```rust
async fn foo() {}

fn bar(f: impl Future<Output=()>) {}

fn main() {
    bar(foo); // <- should be `bar(foo());`
}
```

suggest calling it:

```
error[E0277]: the trait bound `fn() -> impl std::future::Future {foo}: std::future::Future` is not satisfied
  --> $DIR/async-fn-ctor-passed-as-arg-where-it-should-have-been-called.rs:9:5
   |
LL | fn bar(f: impl Future<Output=()>) {}
   | --------------------------------- required by `bar`
...
LL |     bar(foo);
   |     ^^^ the trait `std::future::Future` is not implemented for `fn() -> impl std::future::Future {foo}`
   |
   = help: it looks like you forgot to use parentheses to call the function: `foo()`
```

Fix #63100. Follow up to #63833 and #63337.
2019-09-01 18:04:49 +00:00
..
assembly
auxiliary rustc_target: avoid negative register counts in the SysV x86_64 ABI. 2019-07-05 13:24:25 +03:00
codegen Small improvement for Ord implementation of integers 2019-08-29 03:52:18 +00:00
codegen-units
compile-fail move error with diverging output to compile-fail 2019-08-06 10:28:09 -07:00
debuginfo debuginfo: always include disambiguator in type names 2019-08-27 10:36:27 +10:00
incremental Auto merge of #63580 - wesleywiser:move_promoted_out, r=oli-obk 2019-08-26 07:48:24 +00:00
mir-opt ignore tests on wasm32-bare 2019-08-15 12:54:56 +02:00
pretty pprust: Do not print spaces before some tokens 2019-08-25 21:23:17 +03:00
run-fail
run-make Add very simple edition check to tidy; and add missing edition = 2018s. 2019-07-30 01:56:03 +08:00
run-make-fulldeps rustc: Handle modules in "fat" LTO more robustly 2019-08-27 13:51:14 -07:00
run-pass-valgrind
rustdoc Rollup merge of #62734 - GuillaumeGomez:hide-default-methods, r=Mark-Simulacrum 2019-08-29 17:13:57 +02:00
rustdoc-js
rustdoc-js-std
rustdoc-ui Auto merge of #63703 - tommilligan:warn-empty-doctest, r=ollie27 2019-08-31 20:10:20 +00:00
rustfix
ui Auto merge of #63870 - estebank:async-fn-call, r=oli-obk 2019-09-01 18:04:49 +00:00
ui-fulldeps Deprecate using rustc_plugin without the rustc_driver dylib. 2019-08-20 00:21:32 +02:00
COMPILER_TESTS.md doc: fix broken sentence 2019-08-06 02:36:59 +02:00