summaryrefslogtreecommitdiffstats
path: root/include/godot_cpp/templates/hash_map.hpp
diff options
context:
space:
mode:
authorDavid Snopek <dsnopek@gmail.com>2024-04-02 14:30:01 -0500
committerGitHub <noreply@github.com>2024-04-02 14:30:01 -0500
commit44d78ec8816e57fdd0c06812d31c09a25b97d6e8 (patch)
tree502a26499fd129c80619ed290cd0125b327055f1 /include/godot_cpp/templates/hash_map.hpp
parenta62f633cebee4b36356dc903d00670733cd28fb1 (diff)
parent87f5fb06912d19b3ff3ba80b747fcea3023a1ed5 (diff)
downloadredot-cpp-44d78ec8816e57fdd0c06812d31c09a25b97d6e8.tar.gz
Merge pull request #1409 from Repiteo/class-to-typename
Enforce template syntax `typename` over `class`
Diffstat (limited to 'include/godot_cpp/templates/hash_map.hpp')
-rw-r--r--include/godot_cpp/templates/hash_map.hpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/include/godot_cpp/templates/hash_map.hpp b/include/godot_cpp/templates/hash_map.hpp
index 77c7b7a..59cd8e0 100644
--- a/include/godot_cpp/templates/hash_map.hpp
+++ b/include/godot_cpp/templates/hash_map.hpp
@@ -52,7 +52,7 @@ namespace godot {
* The assignment operator copy the pairs from one map to the other.
*/
-template <class TKey, class TValue>
+template <typename TKey, typename TValue>
struct HashMapElement {
HashMapElement *next = nullptr;
HashMapElement *prev = nullptr;
@@ -62,10 +62,10 @@ struct HashMapElement {
data(p_key, p_value) {}
};
-template <class TKey, class TValue,
- class Hasher = HashMapHasherDefault,
- class Comparator = HashMapComparatorDefault<TKey>,
- class Allocator = DefaultTypedAllocator<HashMapElement<TKey, TValue>>>
+template <typename TKey, typename TValue,
+ typename Hasher = HashMapHasherDefault,
+ typename Comparator = HashMapComparatorDefault<TKey>,
+ typename Allocator = DefaultTypedAllocator<HashMapElement<TKey, TValue>>>
class HashMap {
public:
const uint32_t MIN_CAPACITY_INDEX = 2; // Use a prime.