Fixes compile errors with clang