about summary refs log tree commit diff
diff options
context:
space:
mode:
authorNicholas Nethercote <n.nethercote@gmail.com>2024-03-04 16:32:37 +1100
committerNicholas Nethercote <n.nethercote@gmail.com>2024-03-04 16:32:37 +1100
commit4260f7ec679dca38911e983113a0243fb8f905dc (patch)
treecc26af5dddd1413b86ddc973233e294224ec094f
parent0d4ebe1c1bec2d147bf5b1411a30403d68f64c63 (diff)
downloadrust-4260f7ec679dca38911e983113a0243fb8f905dc.tar.gz
rust-4260f7ec679dca38911e983113a0243fb8f905dc.zip
Rename a misnamed `Session` parameter.
-rw-r--r--compiler/rustc_expand/src/base.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/compiler/rustc_expand/src/base.rs b/compiler/rustc_expand/src/base.rs
index 485f0e7e46d..984c7403720 100644
--- a/compiler/rustc_expand/src/base.rs
+++ b/compiler/rustc_expand/src/base.rs
@@ -1217,7 +1217,7 @@ impl<'a> ExtCtxt<'a> {
 ///
 /// This unifies the logic used for resolving `include_X!`.
 pub fn resolve_path(
-    parse_sess: &Session,
+    sess: &Session,
     path: impl Into<PathBuf>,
     span: Span,
 ) -> PResult<'_, PathBuf> {
@@ -1227,15 +1227,15 @@ pub fn resolve_path(
     // after macro expansion (that is, they are unhygienic).
     if !path.is_absolute() {
         let callsite = span.source_callsite();
-        let mut result = match parse_sess.source_map().span_to_filename(callsite) {
+        let mut result = match sess.source_map().span_to_filename(callsite) {
             FileName::Real(name) => name
                 .into_local_path()
                 .expect("attempting to resolve a file path in an external file"),
             FileName::DocTest(path, _) => path,
             other => {
-                return Err(parse_sess.dcx().create_err(errors::ResolveRelativePath {
+                return Err(sess.dcx().create_err(errors::ResolveRelativePath {
                     span,
-                    path: parse_sess.source_map().filename_for_diagnostics(&other).to_string(),
+                    path: sess.source_map().filename_for_diagnostics(&other).to_string(),
                 }));
             }
         };