Skip to content

Commit 5da8bf8

Browse files
author
Ariel Ben-Yehuda
committed
stop having 'static in dump-mir names
1 parent 63cdd7a commit 5da8bf8

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

src/librustc_mir/transform/simplify_branches.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,4 +60,7 @@ impl<'l> Pass for SimplifyBranches<'l> {
6060
fn disambiguator<'a>(&'a self) -> Option<Box<fmt::Display+'a>> {
6161
Some(Box::new(self.label))
6262
}
63+
64+
// avoid calling `type_name` - it contains `<'static>`
65+
fn name(&self) -> &str { "SimplifyBranches" }
6366
}

src/librustc_mir/transform/simplify_cfg.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,9 @@ impl<'l> Pass for SimplifyCfg<'l> {
6262
fn disambiguator<'a>(&'a self) -> Option<Box<fmt::Display+'a>> {
6363
Some(Box::new(self.label))
6464
}
65+
66+
// avoid calling `type_name` - it contains `<'static>`
67+
fn name(&self) -> &str { "SimplifyCfg" }
6568
}
6669

6770
pub struct CfgSimplifier<'a, 'tcx: 'a> {

0 commit comments

Comments
 (0)