It seems like there’s a rogue pointer around and it finally found a NUL way off into the weeds. Could you run the failing it under valgrind to see if it detects anything?
I’ve never seen this error before or heard any reports about it. But you can probably work around it by using an #if to tell vtkWrapHierarchy to ignore that part of the header file,
+#if !defined(__VTK_WRAP__)
// Accept std::string without a declaration.
template <template <typename, typename, typename> class S>
vtkOStreamWrapper& operator<<(const S<char, std::char_traits<char>, std::allocator<char>>& s)
{
return *this << reinterpret_cast<std_string const&>(s);
}
+#endif
The vtkWrapHierarchy program has an embedded C++ parser, and for some reason it is failing to parse this operator<< template on your system. Which is strange, because it succeeds without any errors on my system and everyone else’s. My best guess is this: for your build of VTK, an extra header file is being included somewhere that #defines a macro for std_string or S or for one of the other identifiers that is used in the operator<< definition.
Edit: I ran the vtkWrapHierarchy command line under valgrind and it didn’t detect any issues.