Make Compiler::sess
private.
Like `Compiler::codegen_backend`.
This commit is contained in:
parent
4a57b80f3f
commit
9582172964
2 changed files with 2 additions and 2 deletions
|
@ -38,7 +38,7 @@ pub type Result<T> = result::Result<T, ErrorGuaranteed>;
|
||||||
/// Can be used to run `rustc_interface` queries.
|
/// Can be used to run `rustc_interface` queries.
|
||||||
/// Created by passing [`Config`] to [`run_compiler`].
|
/// Created by passing [`Config`] to [`run_compiler`].
|
||||||
pub struct Compiler {
|
pub struct Compiler {
|
||||||
pub(crate) sess: Session,
|
sess: Session,
|
||||||
codegen_backend: Box<dyn CodegenBackend>,
|
codegen_backend: Box<dyn CodegenBackend>,
|
||||||
pub(crate) override_queries: Option<fn(&Session, &mut Providers)>,
|
pub(crate) override_queries: Option<fn(&Session, &mut Providers)>,
|
||||||
}
|
}
|
||||||
|
|
|
@ -102,7 +102,7 @@ impl<'tcx> Queries<'tcx> {
|
||||||
}
|
}
|
||||||
|
|
||||||
fn session(&self) -> &Session {
|
fn session(&self) -> &Session {
|
||||||
&self.compiler.sess
|
&self.compiler.session()
|
||||||
}
|
}
|
||||||
|
|
||||||
fn codegen_backend(&self) -> &dyn CodegenBackend {
|
fn codegen_backend(&self) -> &dyn CodegenBackend {
|
||||||
|
|
Loading…
Add table
Reference in a new issue