1 7578 bc99092 --- aspell-0.60.4/modules/speller/default/affix.cpp-orig 2006-01-25 12:48:22.221889000 -0800 2 7578 bc99092 +++ aspell-0.60.4/modules/speller/default/affix.cpp 2006-01-25 12:48:39.274322000 -0800 3 7578 bc99092 @@ -172,8 +172,8 @@ struct AffixLess 4 7578 bc99092 // typedef const char * Value; 5 7578 bc99092 // typedef const char * Key; 6 7578 bc99092 // static const bool is_multi = false; 7 7578 bc99092 -// hash<const char *> hfun; 8 7578 bc99092 -// size_t hash(const char * s) {return hfun(s);} 9 7578 bc99092 +// hash<const char *> thehash; 10 7578 bc99092 +// size_t hash(const char * s) {return thehash(s);} 11 7578 bc99092 // bool equal(const char * x, const char * y) {return strcmp(x,y) == 0;} 12 7578 bc99092 // const char * key(const char * c) {return c;} 13 7578 bc99092 // }; 14 7578 bc99092 @@ -193,8 +193,8 @@ struct CondsLookupParms { 15 7578 bc99092 typedef const Conds * Value; 16 7578 bc99092 typedef const char * Key; 17 7578 bc99092 static const bool is_multi = false; 18 7578 bc99092 - hash<const char *> hfun; 19 7578 bc99092 - size_t hash(const char * s) {return hfun(s);} 20 7578 bc99092 + hash<const char *> thehash; 21 7578 bc99092 + size_t hash(const char * s) {return thehash(s);} 22 7578 bc99092 bool equal(const char * x, const char * y) {return strcmp(x,y) == 0;} 23 7578 bc99092 const char * key(const Conds * c) {return c->str;} 24 7578 bc99092 }; 25 7578 bc99092 --- aspell-0.60.4/modules/speller/default/affix.hpp-orig 2006-01-25 08:56:19.726654000 -0800 26 7578 bc99092 +++ aspell-0.60.4/modules/speller/default/affix.hpp 2006-01-25 08:56:33.890263000 -0800 27 7578 bc99092 @@ -107,7 +107,7 @@ namespace aspeller { 28 7578 bc99092 { 29 7578 bc99092 return expand(word,aff,buf,0); 30 7578 bc99092 } 31 7578 bc99092 - WordAff * expand_suffix(ParmString word, const unsigned char * new_aff, 32 7578 bc99092 + WordAff * expand_suffix(ParmString word, const unsigned char * aff, 33 7578 bc99092 ObjStack &, int limit = INT_MAX, 34 7578 bc99092 unsigned char * new_aff = 0, WordAff * * * l = 0, 35 7578 bc99092 ParmString orig_word = 0) const; 36 7578 bc99092 --- aspell-0.60.4/common/string.hpp-orig 2006-01-25 08:48:03.868105000 -0800 37 7578 bc99092 +++ aspell-0.60.4/common/string.hpp 2006-01-25 08:48:10.228839000 -0800 38 7578 bc99092 @@ -492,7 +492,7 @@ namespace acommon { 39 3056 laca 40 7578 bc99092 namespace std 41 7578 bc99092 { 42 7578 bc99092 - template<> static inline void swap(acommon::String & x, acommon::String & y) {return x.swap(y);} 43 7578 bc99092 + template<> inline void swap(acommon::String & x, acommon::String & y) {return x.swap(y);} 44 7578 bc99092 } 45 3056 laca 46 7578 bc99092 #endif 47 7578 bc99092 --- aspell-0.60.4/common/convert.cpp-orig 2006-01-25 08:51:18.821841000 -0800 48 7578 bc99092 +++ aspell-0.60.4/common/convert.cpp 2006-01-25 08:54:00.865108000 -0800 49 7578 bc99092 @@ -238,7 +238,7 @@ namespace acommon { 50 3056 laca } 51 3056 laca 52 7578 bc99092 template <class T> 53 7578 bc99092 - static void free_norm_table(NormTable<T> * d) 54 7578 bc99092 + void free_norm_table(NormTable<T> * d) 55 7578 bc99092 { 56 7578 bc99092 for (T * cur = d->data; cur != d->end; ++cur) { 57 7578 bc99092 if (cur->sub_table) 58 7578 bc99092 --- aspell-0.60.4/prog/aspell.cpp-orig 2006-01-25 10:47:40.169624000 -0800 59 7578 bc99092 +++ aspell-0.60.4/prog/aspell.cpp 2006-01-25 10:48:01.320279000 -0800 60 7578 bc99092 @@ -1880,7 +1880,7 @@ struct SML_Parms { 61 7578 bc99092 typedef SML_WordEntry Value; 62 7578 bc99092 typedef const char * Key; 63 7578 bc99092 static const bool is_multi = false; 64 7578 bc99092 - hash<const char *> hash; 65 7578 bc99092 + hash<const char *> thehash; 66 7578 bc99092 bool equal(Key x, Key y) {return strcmp(x,y) == 0;} 67 7578 bc99092 Key key(const Value & v) {return v.word;} 68 7578 bc99092 }; 69 7578 bc99092 @@ -2031,7 +2031,7 @@ struct CML_Parms { 70 7578 bc99092 typedef CML_Entry Value; 71 7578 bc99092 typedef const char * Key; 72 7578 bc99092 static const bool is_multi = true; 73 7578 bc99092 - hash<const char *> hash; 74 7578 bc99092 + hash<const char *> thehash; 75 7578 bc99092 bool equal(Key x, Key y) {return strcmp(x,y) == 0;} 76 7578 bc99092 Key key(const Value & v) {return v.word;} 77 7578 bc99092 }; 78 7578 bc99092 --- aspell-0.60.4/common/hash-t.hpp-orig 2006-01-25 10:48:42.926184000 -0800 79 7578 bc99092 +++ aspell-0.60.4/common/hash-t.hpp 2006-01-25 11:21:46.641457000 -0800 80 7578 bc99092 @@ -136,7 +136,7 @@ namespace acommon { 81 7578 bc99092 template <class P> 82 7578 bc99092 typename HashTable<P>::iterator HashTable<P>::find_i(const Key & to_find, bool & have) 83 7578 bc99092 { 84 7578 bc99092 - Size pos = parms_.hash(to_find) % table_size_; 85 7578 bc99092 + Size pos = parms_.thehash(to_find) % table_size_; 86 7578 bc99092 Node * * n = table_ + pos; 87 7578 bc99092 have = false; 88 7578 bc99092 while (true) { 89 7578 bc99092 @@ -199,7 +199,7 @@ namespace acommon { 90 7578 bc99092 for (Node * * i = old_table; i != old_end; ++i) { 91 7578 bc99092 Node * n = *i; 92 7578 bc99092 while (n != 0) { 93 7578 bc99092 - Node * * put_me_here = table_ + (parms_.hash(parms_.key(n->data)) % table_size_); 94 7578 bc99092 + Node * * put_me_here = table_ + (parms_.thehash(parms_.key(n->data)) % table_size_); 95 7578 bc99092 Node * tmp = n; 96 7578 bc99092 n = n->next; 97 7578 bc99092 tmp->next = *put_me_here; 98 7578 bc99092 --- aspell-0.60.4/common/hash.hpp-orig 2006-01-25 11:41:57.215601000 -0800 99 7578 bc99092 +++ aspell-0.60.4/common/hash.hpp 2006-01-25 11:43:22.913496000 -0800 100 7578 bc99092 @@ -259,10 +259,10 @@ namespace acommon { 101 7578 bc99092 typedef K Value; 102 7578 bc99092 typedef const K Key; 103 7578 bc99092 static const bool is_multi = m; 104 7578 bc99092 - HF hash; 105 7578 bc99092 + HF thehash; 106 7578 bc99092 E equal; 107 7578 bc99092 const K & key(const K & v) {return v;} 108 7578 bc99092 - HashSetParms(const HF & h = HF(), const E & e = E()) : hash(h), equal(e) {} 109 7578 bc99092 + HashSetParms(const HF & h = HF(), const E & e = E()) : thehash(h), equal(e) {} 110 7578 bc99092 }; 111 3056 laca 112 7578 bc99092 template <typename K, typename HF = hash<K>, typename E = std::equal_to<K> > 113 7578 bc99092 @@ -293,12 +293,12 @@ namespace acommon { 114 7578 bc99092 typedef std::pair<const K,V> Value; 115 7578 bc99092 typedef const K Key; 116 7578 bc99092 static const bool is_multi = m; 117 7578 bc99092 - HF hash; 118 7578 bc99092 + HF thehash; 119 7578 bc99092 E equal; 120 7578 bc99092 const K & key(const Value & v) {return v.first;} 121 7578 bc99092 HashMapParms() {} 122 7578 bc99092 - HashMapParms(const HF & h) : hash(h) {} 123 7578 bc99092 - HashMapParms(const HF & h, const E & e) : hash(h), equal(e) {} 124 7578 bc99092 + HashMapParms(const HF & h) : thehash(h) {} 125 7578 bc99092 + HashMapParms(const HF & h, const E & e) : thehash(h), equal(e) {} 126 3056 laca }; 127 3056 laca 128 7578 bc99092 template <typename K, typename V, typename HF = hash<K>, typename E = std::equal_to<K> > 129 7578 bc99092 --- aspell-0.60.4/modules/speller/default/readonly_ws.cpp-orig 2006-01-25 08:58:10.945381000 -0800 130 7578 bc99092 +++ aspell-0.60.4/modules/speller/default/readonly_ws.cpp 2006-01-25 09:36:00.510958000 -0800 131 7578 bc99092 @@ -197,7 +197,7 @@ namespace { 132 7578 bc99092 struct WordLookupParms { 133 7578 bc99092 const char * block_begin; 134 7578 bc99092 WordLookupParms() {} 135 7578 bc99092 - typedef BlockVector<const u32int> Vector; 136 7578 bc99092 + typedef BlockVector<const u32int> TheVector; 137 7578 bc99092 typedef u32int Value; 138 7578 bc99092 typedef const char * Key; 139 7578 bc99092 static const bool is_multi = false; 140 7578 bc99092 @@ -727,7 +727,7 @@ namespace { 141 7578 bc99092 struct WordLookupParms { 142 7578 bc99092 const char * block_begin; 143 7578 bc99092 WordLookupParms() {} 144 7578 bc99092 - typedef Vector<u32int> Vector; 145 7578 bc99092 + typedef Vector<u32int> TheVector; 146 7578 bc99092 typedef u32int Value; 147 7578 bc99092 typedef const char * Key; 148 7578 bc99092 static const bool is_multi = false; 149 7578 bc99092 --- aspell-0.60.4/modules/speller/default/vector_hash.hpp-orig 2006-01-25 09:36:22.487585000 -0800 150 7578 bc99092 +++ aspell-0.60.4/modules/speller/default/vector_hash.hpp 2006-01-25 09:37:36.261195000 -0800 151 7578 bc99092 @@ -147,9 +147,9 @@ namespace aspeller { 152 3056 laca 153 7578 bc99092 template <class Parms> 154 7578 bc99092 class VectorHashTable { 155 7578 bc99092 - typedef typename Parms::Vector Vector; 156 7578 bc99092 + typedef typename Parms::TheVector Vector; 157 7578 bc99092 public: 158 7578 bc99092 - typedef typename Parms::Vector vector_type; 159 7578 bc99092 + typedef typename Parms::TheVector vector_type; 160 7578 bc99092 typedef typename Vector::value_type value_type; 161 7578 bc99092 typedef typename Vector::size_type size_type; 162 7578 bc99092 typedef typename Vector::difference_type difference_type; 163 7578 bc99092 --- aspell-0.60.4/common/string_map.hpp-orig 2006-01-25 12:10:54.229184000 -0800 164 7578 bc99092 +++ aspell-0.60.4/common/string_map.hpp 2006-01-25 12:11:01.101685000 -0800 165 7578 bc99092 @@ -28,7 +28,7 @@ public: // but don't use 166 7578 bc99092 typedef const char * Key; 167 7578 bc99092 const char * key(const Value & v) {return v.first;} 168 7578 bc99092 static const bool is_multi = false; 169 7578 bc99092 - acommon::hash<const char *> hash; 170 7578 bc99092 + acommon::hash<const char *> thehash; 171 7578 bc99092 bool equal(const char * x, const char * y) {return strcmp(x,y) == 0;} 172 7578 bc99092 }; 173 7578 bc99092 typedef StringPair Value_; 174 7578 bc99092 --- aspell-0.60.4/gen/mk-static-filter.pl-orig 2006-01-25 13:22:28.191252000 -0800 175 7578 bc99092 +++ aspell-0.60.4/gen/mk-static-filter.pl 2006-01-25 13:36:24.392225000 -0800 176 7578 bc99092 @@ -158,11 +158,17 @@ while ($filter = shift @filterhashes) { 177 7578 bc99092 printf STATICFILTERS "\n };\n"; 178 7578 bc99092 printf STATICFILTERS "\n const KeyInfo * ".${$filter}{"NAME"}."_options_begin = ". 179 7578 bc99092 ${$filter}{"NAME"}."_options;\n"; 180 7578 bc99092 +# If structure is empty, set options_end to same as options_begin. 181 7578 bc99092 +if ($firstopt == 1) { 182 7578 bc99092 + printf STATICFILTERS "\n const KeyInfo * ".${$filter}{"NAME"}."_options_end = ". 183 7578 bc99092 + ${$filter}{"NAME"}."_options;\n"; 184 7578 bc99092 +} else { 185 7578 bc99092 printf STATICFILTERS "\n const KeyInfo * ".${$filter}{"NAME"}."_options_end = ". 186 7578 bc99092 ${$filter}{"NAME"}."_options+sizeof(". 187 7578 bc99092 ${$filter}{"NAME"}."_options)/". 188 7578 bc99092 "sizeof(KeyInfo);\n"; 189 7180 dc144907 } 190 7578 bc99092 +} 191 7405 dc144907 192 7578 bc99092 #finally create filter modules list. 193 7578 bc99092 printf STATICFILTERS "\n\n static ConfigModule filter_modules[] = {\n"; 194