From 5d716fd0e96c4408ad13e5e82df364fb1e984540 Mon Sep 17 00:00:00 2001 From: Nicholas Nethercote Date: Tue, 11 Oct 2022 11:43:25 +1100 Subject: Add a comment to `Compiler`. It took me a while to work this out. --- compiler/rustc_interface/src/interface.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'compiler/rustc_interface/src/interface.rs') diff --git a/compiler/rustc_interface/src/interface.rs b/compiler/rustc_interface/src/interface.rs index a3bf7cde9ff..89aaa0b95e4 100644 --- a/compiler/rustc_interface/src/interface.rs +++ b/compiler/rustc_interface/src/interface.rs @@ -25,7 +25,10 @@ use std::result; pub type Result = result::Result; -/// Represents a compiler session. +/// Represents a compiler session. Note that every `Compiler` contains a +/// `Session`, but `Compiler` also contains some things that cannot be in +/// `Session`, due to `Session` being in a crate that has many fewer +/// dependencies than this crate. /// /// Can be used to run `rustc_interface` queries. /// Created by passing [`Config`] to [`run_compiler`]. -- cgit 1.4.1-3-g733a5