about summary refs log tree commit diff
path: root/compiler/rustc_mir_transform/src/coverage/mod.rs
diff options
context:
space:
mode:
authorNoah Lev <camelidcamel@gmail.com>2021-09-04 18:29:03 -0700
committerNoah Lev <camelidcamel@gmail.com>2021-09-04 18:31:00 -0700
commit486d79f1243135564931c574ce5cfff946ee3867 (patch)
tree465218c1b84863b430215a08ec45b34ae4cc6068 /compiler/rustc_mir_transform/src/coverage/mod.rs
parentb89e01cd8e831f4e831dd6dd9596488509fe1802 (diff)
downloadrust-486d79f1243135564931c574ce5cfff946ee3867.tar.gz
rust-486d79f1243135564931c574ce5cfff946ee3867.zip
Fix 2021 `dyn` suggestion that used code as label
The arguments to `span_suggestion` were in the wrong order, so the error
looked like this:

    error[E0783]: trait objects without an explicit `dyn` are deprecated
      --> src/test/ui/editions/dyn-trait-sugg-2021.rs:10:5
       |
    10 |     Foo::hi(123);
       |     ^^^ help: <dyn Foo>: `use `dyn``

Now the error looks like this, as expected:

    error[E0783]: trait objects without an explicit `dyn` are deprecated
      --> src/test/ui/editions/dyn-trait-sugg-2021.rs:10:5
       |
    10 |     Foo::hi(123);
       |     ^^^ help: use `dyn`: `<dyn Foo>`

This issue was only present in the 2021 error; the 2018 lint was
correct.
Diffstat (limited to 'compiler/rustc_mir_transform/src/coverage/mod.rs')
0 files changed, 0 insertions, 0 deletions