1
Fork 0

Rollup merge of #110425 - compiler-errors:def-span-for-ct-param, r=petrochenkov

Encode def span for `ConstParam`

Fixes #110206

r? ``@petrochenkov``
This commit is contained in:
Matthias Krüger 2023-04-17 18:13:36 +02:00 committed by GitHub
commit d01c62bcef
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 32 additions and 2 deletions

View file

@ -823,6 +823,7 @@ fn should_encode_span(def_kind: DefKind) -> bool {
| DefKind::TraitAlias
| DefKind::AssocTy
| DefKind::TyParam
| DefKind::ConstParam
| DefKind::Fn
| DefKind::Const
| DefKind::Static(_)
@ -837,8 +838,7 @@ fn should_encode_span(def_kind: DefKind) -> bool {
| DefKind::Impl { .. }
| DefKind::Closure
| DefKind::Generator => true,
DefKind::ConstParam
| DefKind::ExternCrate
DefKind::ExternCrate
| DefKind::Use
| DefKind::ForeignMod
| DefKind::ImplTraitPlaceholder