summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Snopek <dsnopek@gmail.com>2024-07-15 12:15:53 -0500
committerGitHub <noreply@github.com>2024-07-15 12:15:53 -0500
commit8012716ee3cdeab4e60373cccac7386f590ed12b (patch)
tree07213518eacc7cad3125b0619e158de7d2ca891b
parent6d939e6878c3fb14ae521207ad2d2f0267fd0a9b (diff)
parente65ec904b89766f34585ef7bddba0ab86c802442 (diff)
downloadredot-cpp-8012716ee3cdeab4e60373cccac7386f590ed12b.tar.gz
Merge pull request #1510 from dsnopek/memnew-better-crash-message
Remind developers about `memnew()` in crash message when missing binding callbacks
-rw-r--r--src/classes/wrapped.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/classes/wrapped.cpp b/src/classes/wrapped.cpp
index 52d4495..ffca4f9 100644
--- a/src/classes/wrapped.cpp
+++ b/src/classes/wrapped.cpp
@@ -84,8 +84,7 @@ Wrapped::Wrapped(const StringName p_godot_class) {
godot::internal::gdextension_interface_object_set_instance_binding(_owner, godot::internal::token, this, _constructing_class_binding_callbacks);
_constructing_class_binding_callbacks = nullptr;
} else {
- ERR_PRINT("BUG: create a Godot Object without binding callbacks.");
- CRASH_NOW_MSG("BUG: create a Godot Object without binding callbacks.");
+ CRASH_NOW_MSG("BUG: Godot Object created without binding callbacks. Did you forget to use memnew()?");
}
}