File tree 2 files changed +6
-2
lines changed
2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -806,7 +806,7 @@ impl<'a> CrateLoader<'a> {
806
806
}
807
807
808
808
info ! ( "injecting a dep from {} to {}" , cnum, krate) ;
809
- data. dependencies . borrow_mut ( ) . push ( krate) ;
809
+ data. push_dependency ( krate) ;
810
810
} ) ;
811
811
}
812
812
Original file line number Diff line number Diff line change @@ -95,7 +95,7 @@ crate struct CrateMetadata {
95
95
/// IDs as they are seen from the current compilation session.
96
96
crate cnum_map : CrateNumMap ,
97
97
/// Same ID set as `cnum_map` plus maybe some injected crates like panic runtime.
98
- crate dependencies : Lock < Vec < CrateNum > > ,
98
+ dependencies : Lock < Vec < CrateNum > > ,
99
99
/// How to link (or not link) this crate to the currently compiled crate.
100
100
dep_kind : Lock < DepKind > ,
101
101
/// Filesystem location of this crate.
@@ -1134,6 +1134,10 @@ impl<'a, 'tcx> CrateMetadata {
1134
1134
1135
1135
dep_node_index
1136
1136
}
1137
+
1138
+ crate fn push_dependency ( & self , krate : CrateNum ) {
1139
+ self . dependencies . borrow_mut ( ) . push ( krate) ;
1140
+ }
1137
1141
}
1138
1142
1139
1143
// Cannot be implemented on 'ProcMacro', as libproc_macro
You can’t perform that action at this time.
0 commit comments