aboutsummaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
Diffstat (limited to 'common')
-rw-r--r--common/list.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/common/list.h b/common/list.h
index 2fe07a5ccc..7c514fd6f4 100644
--- a/common/list.h
+++ b/common/list.h
@@ -26,6 +26,7 @@
#define COMMON_LIST_H
#include "common/scummsys.h"
+#include "common/algorithm.h"
namespace Common {
@@ -267,6 +268,10 @@ public:
const_iterator end() const {
return const_iterator(const_cast<NodeBase*>(&_anchor));
}
+
+ bool contains(const t_T &key) const {
+ return find(begin(), end(), key) != end();
+ }
};
} // End of namespace Common