File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
compiler/rustc_mir_transform/src Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -11,14 +11,15 @@ use crate::lint::lint_body;
1111use crate :: { errors, validate} ;
1212
1313thread_local ! {
14- static PASS_NAMES : RefCell <FxHashMap <& ' static str , & ' static str >> = {
14+ /// Maps MIR pass names to a snake case form to match profiling naming style
15+ static PASS_TO_PROFILER_NAMES : RefCell <FxHashMap <& ' static str , & ' static str >> = {
1516 RefCell :: new( FxHashMap :: default ( ) )
1617 } ;
1718}
1819
1920/// Converts a MIR pass name into a snake case form to match the profiling naming style.
2021fn to_profiler_name ( type_name : & ' static str ) -> & ' static str {
21- PASS_NAMES . with ( |names| match names. borrow_mut ( ) . entry ( type_name) {
22+ PASS_TO_PROFILER_NAMES . with ( |names| match names. borrow_mut ( ) . entry ( type_name) {
2223 Entry :: Occupied ( e) => * e. get ( ) ,
2324 Entry :: Vacant ( e) => {
2425 let snake_case: String = type_name
You can’t perform that action at this time.
0 commit comments