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.
This commit is contained in:
Jim Blandy 2022-04-29 21:00:15 -07:00
parent e8723219b7
commit 7b8d257043

View File

@ -101,7 +101,7 @@ impl<T> Handle<T> {
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)
}