id,summary,reporter,owner,description,type,status,milestone,component,version,severity,resolution,keywords,cc 1828,is_class maybe triggering a VC8 compiler bug,Stefan,John Maddock,"The following code compiles with an error. However there shouldn't be an error. Basically, the line in main() fails to compile because the compiler thinks sizeof(&Der::foo) is 16, which just can't be so. This case is very intricate, and any modifications to the code compile cleanly. For example, if instead of is_class, we use is_void, the code compiles; if hasher is not partially specialized for pointers, it compiles; if 'base' doesn't use CRTP, it compiles; if hasher isn't a member variable, it compiles; if hasher is parametrized by T* or something else, it compiles. #include template struct hasher {}; template struct hasher : boost::is_class {}; template struct hash_set { hasher hash; }; template struct base { hash_set set; }; struct Der : public base { void foo(); }; int main() { char x[sizeof(&Der::foo) == 16 ? -1 : 1]; } I don't think this is a boost bug - the failing conditions look too much like a compiler-specific bug. Also, this code compiles cleanly on gcc 3.4.2 I'd like to hear your opinion, and forward the bug to Microsoft if it's really their bug.",Bugs,closed,Boost 1.36.0,type_traits,Boost 1.34.1,Problem,fixed,,