@@ -163,7 +163,7 @@ provide! { <'tcx> tcx, def_id, other, cdata,
163
163
}
164
164
is_mir_available => { cdata. is_item_mir_available( def_id. index) }
165
165
166
- dylib_dependency_formats => { Lrc :: new ( cdata. get_dylib_dependency_formats( ) ) }
166
+ dylib_dependency_formats => { cdata. get_dylib_dependency_formats( tcx ) }
167
167
is_panic_runtime => { cdata. root. panic_runtime }
168
168
is_compiler_builtins => { cdata. root. compiler_builtins }
169
169
has_global_allocator => { cdata. root. has_global_allocator }
@@ -172,8 +172,8 @@ provide! { <'tcx> tcx, def_id, other, cdata,
172
172
is_profiler_runtime => { cdata. root. profiler_runtime }
173
173
panic_strategy => { cdata. root. panic_strategy }
174
174
extern_crate => {
175
- let r = Lrc :: new ( * cdata. extern_crate. lock( ) ) ;
176
- r
175
+ let r = * cdata. extern_crate. lock( ) ;
176
+ r. map ( |c| & * tcx . arena . alloc ( c ) )
177
177
}
178
178
is_no_builtins => { cdata. root. no_builtins }
179
179
impl_defaultness => { cdata. get_impl_defaultness( def_id. index) }
@@ -190,7 +190,7 @@ provide! { <'tcx> tcx, def_id, other, cdata,
190
190
} )
191
191
. collect( ) ;
192
192
193
- Lrc :: new ( reachable_non_generics)
193
+ tcx . arena . alloc ( reachable_non_generics)
194
194
}
195
195
native_libraries => { Lrc :: new( cdata. get_native_libraries( tcx. sess) ) }
196
196
foreign_modules => { cdata. get_foreign_modules( tcx) }
0 commit comments