Fixed compatibility issues with llvm compiler