about summary refs log tree commit diff
path: root/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2021-11-20 22:33:51 +0100
committerGitHub <noreply@github.com>2021-11-20 22:33:51 +0100
commitec2f087c479bcb351156953ec9097ad3a779923f (patch)
treee8e9f3e96a9787c8c3a80ce7380e1fd619ce21a6 /compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
parentf37a6caffe0ec03b0b32da9d7045f22d35deb526 (diff)
parent1f625b739a1178e00ac36819738289b5dbc081ea (diff)
downloadrust-ec2f087c479bcb351156953ec9097ad3a779923f.tar.gz
rust-ec2f087c479bcb351156953ec9097ad3a779923f.zip
Rollup merge of #91022 - compiler-errors:modulo_infer, r=estebank
Suggest `await` in more situations where infer types are involved

Currently we use `TyS::same_type` in diagnostics that suggest adding `.await` to opaque future types.

This change makes the suggestion slightly more general, when we're comparing types like `Result<T, E>` and `Result<_, _>` which happens sometimes in places like `match` patterns or `let` statements with partially-elaborated types.

----

Question:
1. Is this change worthwhile? Totally fine if it doesn't make sense adding.
2. Should `same_type_modulo_infer` live in `rustc_infer::infer::error_reporting` or alongside the other method in `rustc_middle::ty::util`?
3. Should we generalize this change? I wanted to change all usages, but I don't want erroneous suggestions when adding `.field_name`...
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp')
0 files changed, 0 insertions, 0 deletions