Fixes issues with clang on osx