From 02dc27f1a4ac3552566d2dfdae56ad3acabdc970 Mon Sep 17 00:00:00 2001 From: jedel1043 Date: Thu, 6 Apr 2023 13:06:20 -0600 Subject: [PATCH] Reword assert message --- boa_engine/src/builtins/mod.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/boa_engine/src/builtins/mod.rs b/boa_engine/src/builtins/mod.rs index c63bbae8110..e2684f1f79b 100644 --- a/boa_engine/src/builtins/mod.rs +++ b/boa_engine/src/builtins/mod.rs @@ -435,7 +435,10 @@ impl BuiltInObjectInitializer { fn set_data(&mut self, new_data: ObjectData) { match self { BuiltInObjectInitializer::Shared(obj) => { - assert!(std::ptr::eq(obj.vtable(), new_data.internal_methods)); + assert!( + std::ptr::eq(obj.vtable(), new_data.internal_methods), + "intrinsic object's vtable didn't match with new data" + ); *obj.borrow_mut().kind_mut() = new_data.kind; } BuiltInObjectInitializer::Unique { ref mut data, .. } => *data = new_data,