fixed clang build on darwin