Skip to content

Commit

Permalink
Fix nightly build
Browse files Browse the repository at this point in the history
  • Loading branch information
nbdd0121 committed Sep 19, 2023
1 parent 9ad23c1 commit 0854be3
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
3 changes: 1 addition & 2 deletions src/ctxt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -255,10 +255,9 @@ impl<'tcx> AnalysisCtxt<'tcx> {
}

pub fn new(tcx: TyCtxt<'tcx>) -> Self {
let crate_name = tcx.crate_name(LOCAL_CRATE);
let output_filenames = tcx.output_filenames(());
let rmeta_path =
rustc_session::output::filename_for_metadata(tcx.sess, crate_name, output_filenames);
rustc_session::output::filename_for_metadata(tcx.sess, output_filenames);
let rmeta_path = rmeta_path.as_path();

// Double check that the rmeta file is .rlib or .rmeta
Expand Down
4 changes: 2 additions & 2 deletions src/monomorphize_collector.rs
Original file line number Diff line number Diff line change
Expand Up @@ -587,8 +587,8 @@ impl<'a, 'tcx> MirVisitor<'tcx> for MirUsedCollector<'a, 'tcx> {
let param_env = ty::ParamEnv::reveal_all();
let val = match literal.eval(self.tcx, param_env, None) {
Ok(v) => v,
Err(ErrorHandled::Reported(_)) => return,
Err(ErrorHandled::TooGeneric) => span_bug!(
Err(ErrorHandled::Reported(..)) => return,
Err(ErrorHandled::TooGeneric(..)) => span_bug!(
self.body.source_info(location).span,
"collection encountered polymorphic constant: {:?}",
literal
Expand Down
4 changes: 2 additions & 2 deletions src/preempt_count/check.rs
Original file line number Diff line number Diff line change
Expand Up @@ -359,8 +359,8 @@ impl<'mir, 'tcx, 'cx> MirVisitor<'tcx> for MirNeighborVisitor<'mir, 'tcx, 'cx> {
let param_env = ty::ParamEnv::reveal_all();
let val = match literal.eval(self.cx.tcx, param_env, None) {
Ok(v) => v,
Err(ErrorHandled::Reported(_)) => return,
Err(ErrorHandled::TooGeneric) => {
Err(ErrorHandled::Reported(..)) => return,
Err(ErrorHandled::TooGeneric(..)) => {
self.result = Err(Error::TooGeneric);
return;
}
Expand Down

0 comments on commit 0854be3

Please sign in to comment.