Auto merge of #28454 - GSam:master, r=nrc

This is so that the resolution results can be used after analysis, potentially for tool support
This commit is contained in:
bors 2015-09-17 08:28:33 +00:00
commit d3fc6e1858
2 changed files with 5 additions and 1 deletions

View File

@ -601,6 +601,8 @@ options! {DebuggingOptions, DebuggingSetter, basic_debugging_options,
"For every macro invocation, print its name and arguments"),
enable_nonzeroing_move_hints: bool = (false, parse_bool,
"Force nonzeroing move optimization on"),
keep_mtwt_tables: bool = (false, parse_bool,
"Don't clear the resolution tables after analysis"),
}
pub fn default_lib_output() -> CrateType {

View File

@ -675,7 +675,9 @@ pub fn phase_3_run_analysis_passes<'tcx, F, R>(sess: Session,
|| resolve::resolve_crate(&sess, &ast_map, make_glob_map));
// Discard MTWT tables that aren't required past resolution.
syntax::ext::mtwt::clear_tables();
if !sess.opts.debugging_opts.keep_mtwt_tables {
syntax::ext::mtwt::clear_tables();
}
let named_region_map = time(time_passes, "lifetime resolution",
|| middle::resolve_lifetime::krate(&sess, krate, &def_map));