From 7b8d257043b9db9af6118cff4782526e848d4e73 Mon Sep 17 00:00:00 2001 From: Jim Blandy Date: Fri, 29 Apr 2022 21:00:15 -0700 Subject: [PATCH] Correct error message for `Handle` index overflow. This function is used from both `Arena` and `UniqueArena`. When its code moved from `Arena` to `Handle`, the error message was adapted incorrectly. --- src/arena.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/arena.rs b/src/arena.rs index 77f425d1f..c7611ebf9 100644 --- a/src/arena.rs +++ b/src/arena.rs @@ -101,7 +101,7 @@ impl Handle { let handle_index = u32::try_from(index + 1) .ok() .and_then(Index::new) - .expect("Failed to insert into UniqueArena. Handle overflows"); + .expect("Failed to insert into arena. Handle overflows"); Handle::new(handle_index) }