Replace kw_span by full span.

This commit is contained in:
Camille GILLOT
2024-07-02 09:38:49 +00:00
parent 6268d0aa34
commit 3380bfd1a0
13 changed files with 31 additions and 23 deletions

View File

@@ -124,7 +124,7 @@ pub(crate) fn expand_deriving_coerce_pointee(
GenericParamKind::Type { default: _ } => {
cx.typaram(p.span(), p.ident, p.bounds.clone(), None)
}
GenericParamKind::Const { ty, kw_span: _, default: _ } => cx
GenericParamKind::Const { ty, span: _, default: _ } => cx
.const_param(
p.span(),
p.ident,

View File

@@ -664,10 +664,10 @@ impl<'a> TraitDef<'a> {
cx.typaram(param.ident.span.with_ctxt(ctxt), param.ident, bounds, None)
}
GenericParamKind::Const { ty, kw_span, .. } => {
GenericParamKind::Const { ty, span, .. } => {
let const_nodefault_kind = GenericParamKind::Const {
ty: ty.clone(),
kw_span: kw_span.with_ctxt(ctxt),
span: span.with_ctxt(ctxt),
// We can't have default values inside impl block
default: None,