mirror of
https://github.com/zenorogue/hyperrogue.git
synced 2026-08-06 16:08:51 +00:00
Remove USE_UNORDERED_MAP because it has bit-rotted.
Trying to compile with `-DUSE_UNORDERED_MAP` produces lots of compiler errors
like these, because of missing `std::hash` specializations.
Also, `#define unordered_map map` is just evil!
```
./nonisotropic.cpp:875:36: note: in instantiation of template class 'std::__1::unordered_map<hr::nilv::mvec, hr::heptagon *,
std::__1::hash<hr::nilv::mvec>, std::__1::equal_to<hr::nilv::mvec>, std::__1::allocator<std::__1::pair<const hr::nilv::mvec, hr::heptagon
*> > >' requested here
unordered_map<mvec, heptagon*> at;
^
./nonisotropic.cpp:239:58: note: in instantiation of template class 'std::__1::unordered_map<std::__1::pair<hr::heptagon *, hr::heptagon *>,
hr::heptagon *, std::__1::hash<std::__1::pair<hr::heptagon *, hr::heptagon *> >, std::__1::equal_to<std::__1::pair<hr::heptagon *,
hr::heptagon *> >, std::__1::allocator<std::__1::pair<const std::__1::pair<hr::heptagon *, hr::heptagon *>, hr::heptagon *> > >'
requested here
unordered_map<pair<heptagon*, heptagon*>, heptagon*> at;
^
./nonisotropic.cpp:457:49: error: no matching member function for call to 'iadj'
while(h1->distance < h2->distance) back = iadj(h2, down) * back, h2 = h2->cmove(down);
^~~~
cell.cpp:42:15: note: candidate function not viable: no known conversion from 'hr::sn::hrmap_solnih' to 'hr::hrmap' for object argument
transmatrix iadj(heptagon *h, int d) {
^
cell.cpp:41:22: note: candidate function not viable: no known conversion from 'hr::sn::hrmap_solnih' to 'hr::hrmap' for object argument
struct transmatrix iadj(cell *c, int i) { cell *c1 = c->cmove(i); return adj(c1, c->c.spin(i)); }
^
```
This commit is contained in:
@@ -601,8 +601,8 @@ EX namespace reg3 {
|
||||
hrmap *binary_map;
|
||||
hrmap_quotient3 *quotient_map;
|
||||
|
||||
unordered_map<heptagon*, pair<heptagon*, transmatrix>> reg_gmatrix;
|
||||
unordered_map<heptagon*, vector<pair<heptagon*, transmatrix> > > altmap;
|
||||
map<heptagon*, pair<heptagon*, transmatrix>> reg_gmatrix;
|
||||
map<heptagon*, vector<pair<heptagon*, transmatrix> > > altmap;
|
||||
|
||||
vector<cell*> spherecells;
|
||||
|
||||
@@ -1439,7 +1439,7 @@ ld adistance(cell *c) {
|
||||
return regmap()->reg_gmatrix[c->master].first->distance * log(2) - h[0];
|
||||
}
|
||||
|
||||
unordered_map<pair<cell*, cell*>, int> memo;
|
||||
map<pair<cell*, cell*>, int> memo;
|
||||
|
||||
bool cdd;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user