diff options
| author | Camille GILLOT <gillot.camille@gmail.com> | 2025-04-03 16:19:33 +0000 |
|---|---|---|
| committer | Camille GILLOT <gillot.camille@gmail.com> | 2025-06-11 23:44:22 +0000 |
| commit | a5ff3cc3f5bbaa9fecf6a67cf5261022a0aa67d6 (patch) | |
| tree | fba5f75b74d5cb270f85e71774a2cd8562cc7ca9 /compiler/rustc_span/src/lib.rs | |
| parent | 00b526212bbdd68872d6f964fcc9a14a66c36fd8 (diff) | |
| download | rust-a5ff3cc3f5bbaa9fecf6a67cf5261022a0aa67d6.tar.gz rust-a5ff3cc3f5bbaa9fecf6a67cf5261022a0aa67d6.zip | |
Do not clone Arc when hashing span.
Diffstat (limited to 'compiler/rustc_span/src/lib.rs')
| -rw-r--r-- | compiler/rustc_span/src/lib.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/rustc_span/src/lib.rs b/compiler/rustc_span/src/lib.rs index ed74dea5f1e..c8a29a2f68f 100644 --- a/compiler/rustc_span/src/lib.rs +++ b/compiler/rustc_span/src/lib.rs @@ -2600,7 +2600,7 @@ pub trait HashStableContext { fn span_data_to_lines_and_cols( &mut self, span: &SpanData, - ) -> Option<(Arc<SourceFile>, usize, BytePos, usize, BytePos)>; + ) -> Option<(StableSourceFileId, usize, BytePos, usize, BytePos)>; fn hashing_controls(&self) -> HashingControls; } @@ -2657,7 +2657,7 @@ where }; Hash::hash(&TAG_VALID_SPAN, hasher); - Hash::hash(&file.stable_id, hasher); + Hash::hash(&file, hasher); // Hash both the length and the end location (line/column) of a span. If we // hash only the length, for example, then two otherwise equal spans with |
