]> git.lizzy.rs Git - rust.git/commit - src/tools/miri
Rollup merge of #81914 - kper:fixing-81885, r=estebank
authorDylan DPC <dylan.dpc@gmail.com>
Sun, 14 Feb 2021 15:54:47 +0000 (16:54 +0100)
committerGitHub <noreply@github.com>
Sun, 14 Feb 2021 15:54:47 +0000 (16:54 +0100)
commita6809d00aed27db9ac99841d2bd34060a77d2708
treea94621efcee625e1699086d48da838f5060e9ba3
parent25315635ef50e57e70cc680a0f70926ec24ed0db
parent1adc6be23f93c2a348cbf568fb89dc546319e199
Rollup merge of #81914 - kper:fixing-81885, r=estebank

Fixing bad suggestion for `_` in `const` type when a function #81885

Closes #81885

```
error[E0121]: the type placeholder `_` is not allowed within types on item signatures
  --> $DIR/typeck_type_placeholder_item_help.rs:13:22
   |
LL | const TEST4: fn() -> _ = 42;
   |                      ^
   |                      |
   |                      not allowed in type signatures
   |                      help: use type parameters instead: `T`
```

Do not show the suggestion `help: use type parameters instead: T` when `fn`
compiler/rustc_typeck/src/astconv/mod.rs
compiler/rustc_typeck/src/collect.rs