@@ -14,12 +14,12 @@ use rustc_ast::ptr::P as AstP;
14
14
use rustc_ast:: * ;
15
15
use rustc_data_structures:: stack:: ensure_sufficient_stack;
16
16
use rustc_hir as hir;
17
- use rustc_hir:: def:: { DefKind , Res } ;
17
+ use rustc_hir:: def:: Res ;
18
18
use rustc_hir:: HirId ;
19
19
use rustc_middle:: span_bug;
20
20
use rustc_session:: errors:: report_lit_error;
21
21
use rustc_span:: source_map:: { respan, Spanned } ;
22
- use rustc_span:: symbol:: { kw , sym, Ident , Symbol } ;
22
+ use rustc_span:: symbol:: { sym, Ident , Symbol } ;
23
23
use rustc_span:: DUMMY_SP ;
24
24
use rustc_span:: { DesugaringKind , Span } ;
25
25
use thin_vec:: { thin_vec, ThinVec } ;
@@ -377,18 +377,8 @@ impl<'hir> LoweringContext<'_, 'hir> {
377
377
let mut generic_args = ThinVec :: new ( ) ;
378
378
for ( idx, arg) in args. into_iter ( ) . enumerate ( ) {
379
379
if legacy_args_idx. contains ( & idx) {
380
- let parent_def_id = self . current_hir_id_owner ;
381
380
let node_id = self . next_node_id ( ) ;
382
381
383
- // Add a definition for the in-band const def.
384
- self . create_def (
385
- parent_def_id. def_id ,
386
- node_id,
387
- kw:: Empty ,
388
- DefKind :: AnonConst ,
389
- f. span ,
390
- ) ;
391
-
392
382
let anon_const = AnonConst { id : node_id, value : arg } ;
393
383
generic_args. push ( AngleBracketedArg :: Arg ( GenericArg :: Const ( anon_const) ) ) ;
394
384
} else {
0 commit comments