[Scummvm-git-logs] scummvm master -> 3ff4e1c9c4809814d7a8d3335c9305deb911dbf7

sev- noreply at scummvm.org
Sun Mar 6 16:46:26 UTC 2022


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
3ff4e1c9c4 COMMON: Moved Node struct from private to public so that HashMap can be


Commit: 3ff4e1c9c4809814d7a8d3335c9305deb911dbf7
    https://github.com/scummvm/scummvm/commit/3ff4e1c9c4809814d7a8d3335c9305deb911dbf7
Author: kevinlaurier (kevinlaurier at gmail.com)
Date: 2022-03-06T17:46:23+01:00

Commit Message:
COMMON: Moved Node struct from private to public so that HashMap can be
used with Common::find_if from algorithm.h - this is required as part of
the lambda or function object signature when passed as a predicate.

Changed paths:
    common/hashmap.h


diff --git a/common/hashmap.h b/common/hashmap.h
index 297b20eb0ff..01e6d648850 100644
--- a/common/hashmap.h
+++ b/common/hashmap.h
@@ -88,10 +88,6 @@ class HashMap {
 public:
 	typedef uint size_type;
 
-private:
-
-	typedef HashMap<Key, Val, HashFunc, EqualFunc> HM_t;
-
 	struct Node {
 		Val _value;
 		const Key _key;
@@ -99,6 +95,10 @@ private:
 		Node() : _key(), _value() {}
 	};
 
+private:
+
+	typedef HashMap<Key, Val, HashFunc, EqualFunc> HM_t;
+
 	enum {
 		HASHMAP_PERTURB_SHIFT = 5,
 		HASHMAP_MIN_CAPACITY = 16,




More information about the Scummvm-git-logs mailing list