about summary refs log tree commit diff
path: root/compiler/rustc_span/src/source_map
diff options
context:
space:
mode:
authorVadim Petrochenkov <vadim.petrochenkov@gmail.com>2024-04-03 17:49:59 +0300
committerVadim Petrochenkov <vadim.petrochenkov@gmail.com>2024-04-03 19:06:22 +0300
commitb40ea03f8a9a94c294679b9f261b86ded120454f (patch)
tree18e32ab93e0d4506cc8c973e3be253ebe079c03f /compiler/rustc_span/src/source_map
parentceab6128fa48a616bfd3e3adf4bc80133b8ee223 (diff)
downloadrust-b40ea03f8a9a94c294679b9f261b86ded120454f.tar.gz
rust-b40ea03f8a9a94c294679b9f261b86ded120454f.zip
rustc_index: Add a `ZERO` constant to index types
It is commonly used.
Diffstat (limited to 'compiler/rustc_span/src/source_map')
-rw-r--r--compiler/rustc_span/src/source_map/tests.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_span/src/source_map/tests.rs b/compiler/rustc_span/src/source_map/tests.rs
index 81a9e470688..dcb02da3719 100644
--- a/compiler/rustc_span/src/source_map/tests.rs
+++ b/compiler/rustc_span/src/source_map/tests.rs
@@ -243,7 +243,7 @@ fn t10() {
         src_hash,
         stable_id,
         source_len.to_u32(),
-        CrateNum::new(0),
+        CrateNum::ZERO,
         FreezeLock::new(lines.read().clone()),
         multibyte_chars,
         non_narrow_chars,