diff options
| author | Camille GILLOT <gillot.camille@gmail.com> | 2021-10-02 17:35:27 +0200 |
|---|---|---|
| committer | Camille GILLOT <gillot.camille@gmail.com> | 2021-10-06 19:06:20 +0200 |
| commit | ce21756ed3acdd6bb4c222725214c24e1bc70915 (patch) | |
| tree | 94c435bd81d6623dda44ac5f6d6ccdf2e14a8641 /compiler/rustc_session | |
| parent | 25ec8273855fde2d72ae877b397e054de5300e10 (diff) | |
Access Session while decoding expn_id.
Diffstat (limited to 'compiler/rustc_session')
| -rw-r--r-- | compiler/rustc_session/src/cstore.rs | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/compiler/rustc_session/src/cstore.rs b/compiler/rustc_session/src/cstore.rs index 9d6bd201039..59e7abc2ea3 100644 --- a/compiler/rustc_session/src/cstore.rs +++ b/compiler/rustc_session/src/cstore.rs @@ -4,6 +4,7 @@ use crate::search_paths::PathKind; use crate::utils::NativeLibKind; +use crate::Session; use rustc_ast as ast; use rustc_data_structures::sync::{self, MetadataRef}; use rustc_hir::def_id::{CrateNum, DefId, StableCrateId, LOCAL_CRATE}; @@ -193,7 +194,13 @@ pub trait CrateStore: std::fmt::Debug { /// Fetch a DefId from a DefPathHash for a foreign crate. fn def_path_hash_to_def_id(&self, cnum: CrateNum, hash: DefPathHash) -> DefId; - fn expn_hash_to_expn_id(&self, cnum: CrateNum, index_guess: u32, hash: ExpnHash) -> ExpnId; + fn expn_hash_to_expn_id( + &self, + sess: &Session, + cnum: CrateNum, + index_guess: u32, + hash: ExpnHash, + ) -> ExpnId; } pub type CrateStoreDyn = dyn CrateStore + sync::Sync; |
