summaryrefslogtreecommitdiff
path: root/core/templates
diff options
context:
space:
mode:
Diffstat (limited to 'core/templates')
-rw-r--r--core/templates/hash_map.h4
-rw-r--r--core/templates/set.h3
-rw-r--r--core/templates/vector.h1
3 files changed, 5 insertions, 3 deletions
diff --git a/core/templates/hash_map.h b/core/templates/hash_map.h
index 82b3546f9d..fa5677cc70 100644
--- a/core/templates/hash_map.h
+++ b/core/templates/hash_map.h
@@ -40,7 +40,6 @@
/**
* @class HashMap
- * @author Juan Linietsky <reduzio@gmail.com>
*
* Implementation of a standard Hashing HashMap, for quick lookups of Data associated with a Key.
* The implementation provides hashers for the default types, if you need a special kind of hasher, provide
@@ -48,7 +47,8 @@
* @param TKey Key, search is based on it, needs to be hasheable. It is unique in this container.
* @param TData Data, data associated with the key
* @param Hasher Hasher object, needs to provide a valid static hash function for TKey
- * @param Comparator comparator object, needs to be able to safely compare two TKey values. It needs to ensure that x == x for any items inserted in the map. Bear in mind that nan != nan when implementing an equality check.
+ * @param Comparator comparator object, needs to be able to safely compare two TKey values.
+ * It needs to ensure that x == x for any items inserted in the map. Bear in mind that nan != nan when implementing an equality check.
* @param MIN_HASH_TABLE_POWER Miminum size of the hash table, as a power of two. You rarely need to change this parameter.
* @param RELATIONSHIP Relationship at which the hash table is resized. if amount of elements is RELATIONSHIP
* times bigger than the hash table, table is resized to solve this condition. if RELATIONSHIP is zero, table is always MIN_HASH_TABLE_POWER.
diff --git a/core/templates/set.h b/core/templates/set.h
index 9107459884..cdc6e8447d 100644
--- a/core/templates/set.h
+++ b/core/templates/set.h
@@ -582,6 +582,9 @@ public:
}
Element *lower_bound(const T &p_value) const {
+ if (!_data._root) {
+ return nullptr;
+ }
return _lower_bound(p_value);
}
diff --git a/core/templates/vector.h b/core/templates/vector.h
index 4ada3b597a..e53c502f67 100644
--- a/core/templates/vector.h
+++ b/core/templates/vector.h
@@ -33,7 +33,6 @@
/**
* @class Vector
- * @author Juan Linietsky
* Vector container. Regular Vector Container. Use with care and for smaller arrays when possible. Use Vector for large arrays.
*/