about summary refs log tree commit diff
path: root/compiler/rustc_errors/src/lib.rs
diff options
context:
space:
mode:
authorJohn Kåre Alsaker <john.kare.alsaker@gmail.com>2023-08-31 12:50:44 +0200
committerJohn Kåre Alsaker <john.kare.alsaker@gmail.com>2023-09-07 13:04:23 +0200
commitc5996b80beaba54502fa86583b48cd6980b17b18 (patch)
treeef26a4468e70f96e01664e16444a3cf464a4af5c /compiler/rustc_errors/src/lib.rs
parentf00c1399987c60b4e884afc42f4aa6226855e9ae (diff)
downloadrust-c5996b80beaba54502fa86583b48cd6980b17b18.tar.gz
rust-c5996b80beaba54502fa86583b48cd6980b17b18.zip
Use `Freeze` for `SourceFile.external_src`
Diffstat (limited to 'compiler/rustc_errors/src/lib.rs')
-rw-r--r--compiler/rustc_errors/src/lib.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_errors/src/lib.rs b/compiler/rustc_errors/src/lib.rs
index 55c4ec66cd9..6cb6549a00b 100644
--- a/compiler/rustc_errors/src/lib.rs
+++ b/compiler/rustc_errors/src/lib.rs
@@ -273,7 +273,7 @@ impl CodeSuggestion {
                 assert!(!lines.lines.is_empty() || bounding_span.is_dummy());
 
                 // We can't splice anything if the source is unavailable.
-                if !sm.ensure_source_file_source_present(lines.file.clone()) {
+                if !sm.ensure_source_file_source_present(&lines.file) {
                     return None;
                 }