summaryrefslogtreecommitdiff
path: root/core/map.h
diff options
context:
space:
mode:
Diffstat (limited to 'core/map.h')
-rw-r--r--core/map.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/core/map.h b/core/map.h
index acf1d608d8..ef0f75fc9b 100644
--- a/core/map.h
+++ b/core/map.h
@@ -599,9 +599,9 @@ public:
const V &operator[](const K &p_key) const {
- ERR_FAIL_COND_V(!_data._root, *(V *)NULL); // crash on purpose
+ CRASH_COND(!_data._root);
const Element *e = find(p_key);
- ERR_FAIL_COND_V(!e, *(V *)NULL); // crash on purpose
+ CRASH_COND(!e);
return e->_value;
}
V &operator[](const K &p_key) {
@@ -613,7 +613,7 @@ public:
if (!e)
e = insert(p_key, V());
- ERR_FAIL_COND_V(!e, *(V *)NULL); // crash on purpose
+ CRASH_COND(!e);
return e->_value;
}