Fixed compilation errors for gcc@linux (not all yet).

git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@181 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
twanvl
2007-01-28 19:13:01 +00:00
parent d96d150138
commit fc03b5efa1
15 changed files with 159 additions and 71 deletions
+3 -3
View File
@@ -46,7 +46,7 @@ class IndexMap : private vector<Value> {
void init(const vector<Key>& keys) {
if (this->size() == keys.size()) return;
this->reserve(keys.size());
for(vector<Key>::const_iterator it = keys.begin() ; it != keys.end() ; ++it) {
for(typename vector<Key>::const_iterator it = keys.begin() ; it != keys.end() ; ++it) {
const Key& key = *it;
assert(key);
if (key->index >= this->size()) this->resize(key->index + 1);
@@ -82,8 +82,8 @@ class IndexMap : private vector<Value> {
/// Find a value given the key name, return an iterator
template <typename Name>
const_iterator find(const Name& key) const {
for(vector<Value>::const_iterator it = begin() ; it != end() ; ++it) {
typename vector<Value>::const_iterator find(const Name& key) const {
for(typename vector<Value>::const_iterator it = begin() ; it != end() ; ++it) {
if (get_key_name(*it) == key) return it;
}
return end();