I’m trying to compile CSSTidy with Visual Studio.
The problem is that it throws
error C2245: non-existent member function ‘umap::erase’ specified as friend (member function signature does not match any overload)
pointing to the
friend void umap<keyT,valT>::erase(const typename umap<keyT,valT>::iterator& it);
which is a declaration in iterator class declared in umap class.
Can anybody tell me where should I digg into to figure out what the problem really is? AFAIK the source compiles in MinGW …
The fix, forward declare “class iterator;” at the top of class umap, and move the impl of “class iterator” to the bottom of class umap. The reason, MickySoft VS appears to have a deficiency that causes it not recognize umap::erase declared below the impl of umap::iterator.