Keep info on pre-desugaring expression for better "incorrect .await
" suggestion
Keep the `HirId` of `.await`ed expressions so in the case of a `fn` call on on a sync `fn`, we can suggest maybe turning it into an `async fn`.
This commit is contained in:
parent
d45e030c04
commit
f640438b40
14 changed files with 138 additions and 36 deletions
|
@ -286,7 +286,7 @@ impl<'hir> Sig for hir::Ty<'hir> {
|
|||
refs: vec![SigElement { id, start, end }],
|
||||
})
|
||||
}
|
||||
hir::TyKind::Path(hir::QPath::LangItem(lang_item, _)) => {
|
||||
hir::TyKind::Path(hir::QPath::LangItem(lang_item, _, _)) => {
|
||||
Ok(text_sig(format!("#[lang = \"{}\"]", lang_item.name())))
|
||||
}
|
||||
hir::TyKind::TraitObject(bounds, ..) => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue