diff options
author | Eugene Sandulenko | 2006-03-23 22:59:38 +0000 |
---|---|---|
committer | Eugene Sandulenko | 2006-03-23 22:59:38 +0000 |
commit | 5d1b4d8f78352f4bfb0073d0ab53647377c98f96 (patch) | |
tree | 13c0be604d399a4ea4d9793d0c7425fe5fe2820d /gui | |
parent | f5966123443f89e1f1a1b6859dc077c679f6e715 (diff) | |
download | scummvm-rg350-5d1b4d8f78352f4bfb0073d0ab53647377c98f96.tar.gz scummvm-rg350-5d1b4d8f78352f4bfb0073d0ab53647377c98f96.tar.bz2 scummvm-rg350-5d1b4d8f78352f4bfb0073d0ab53647377c98f96.zip |
Implementation of AssociativeArray. Transferred GUI to it. Now it is much
faster.
svn-id: r21419
Diffstat (limited to 'gui')
-rw-r--r-- | gui/eval.h | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/gui/eval.h b/gui/eval.h index 69389c58c9..fc4f12c11d 100644 --- a/gui/eval.h +++ b/gui/eval.h @@ -25,12 +25,12 @@ #include "common/stdafx.h" #include "common/str.h" -#include "common/map.h" +#include "common/assocarray.h" namespace GUI { using Common::String; -using Common::Map; +using Common::AssocArray; #define EVAL_UNDEF_VAR -13375 @@ -49,10 +49,6 @@ enum evalErrors { eUndefVar }; -struct IgnoreCaseComparator { - int operator()(const String& x, const String& y) const { return strcmp(x.c_str(), y.c_str()); } -}; - class Eval { public: Eval(); @@ -71,8 +67,8 @@ public: void reset(); - typedef Map<String, int, IgnoreCaseComparator> VariablesMap; - typedef Map<String, String, IgnoreCaseComparator> AliasesMap; + typedef AssocArray<String, int> VariablesMap; + typedef AssocArray<String, String> AliasesMap; private: void getToken(); |