Fix build error on non-clang++ compilers