fix clang++ compile issue on mac