tamer: sym::symbol: Use {=>diagnostic_}panic! for resolution failure

Various parts of the system have to be converted to use `diagnostic_panic!`,
which makes it very clear that this is a bug in TAMER that should be
reported.  I just happened to see this one near code I was about to touch.

DEV-13156
main
Mike Gerwitz 2022-11-01 12:04:58 -04:00
parent 2a70525275
commit 37d44e42ad
1 changed files with 3 additions and 2 deletions

View File

@ -22,7 +22,7 @@
//! See the [parent module](super) for more information.
use super::{DefaultInterner, Interner};
use crate::global;
use crate::{diagnostic_panic, global};
use std::convert::{TryFrom, TryInto};
use std::fmt::{Debug, Display};
use std::hash::Hash;
@ -263,7 +263,8 @@ impl<Ix: SymbolIndexSize> GlobalSymbolResolve for SymbolId<Ix> {
// If the system is being used properly, this should never
// happen (we'd only look up symbols allocated through this
// interner).
panic!(
diagnostic_panic!(
vec![], // no span information available
"failed to resolve SymbolId({}) using global \
interner of length {}",
self.0.into(),