Fixed compilation with clang that is stricter than gcc on some issues