Fixes for Mac/Clang