Skip to content

Commit

Permalink
Make Compiler::sess private.
Browse files Browse the repository at this point in the history
Like `Compiler::codegen_backend`.
  • Loading branch information
nnethercote committed Nov 17, 2023
1 parent 4a57b80 commit 9582172
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion compiler/rustc_interface/src/interface.rs
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ pub type Result<T> = result::Result<T, ErrorGuaranteed>;
/// Can be used to run `rustc_interface` queries.
/// Created by passing [`Config`] to [`run_compiler`].
pub struct Compiler {
pub(crate) sess: Session,
sess: Session,
codegen_backend: Box<dyn CodegenBackend>,
pub(crate) override_queries: Option<fn(&Session, &mut Providers)>,
}
Expand Down
2 changes: 1 addition & 1 deletion compiler/rustc_interface/src/queries.rs
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ impl<'tcx> Queries<'tcx> {
}

fn session(&self) -> &Session {
&self.compiler.sess
&self.compiler.session()
}

fn codegen_backend(&self) -> &dyn CodegenBackend {
Expand Down

0 comments on commit 9582172

Please sign in to comment.