mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-16 08:27:05 +00:00
clang/gcc: enable a bunch more warnings (#91)
* clang/gcc: enable -pedantic warnings * suppress a GCC-specific warning in stb_image * And some clang-specific warnings * -Wconversion (clang) -Wold-style-cast (clang+gcc) and fix a few warnings that show up with these (and a few more with -Wconversion on gcc, even though that's not enabled by default) * bunch more warnings * fixes * remove merge error
This commit is contained in:
@@ -203,7 +203,7 @@ TEST(CommandAllocator, LargeCommands) {
|
||||
|
||||
const int kCommandCount = 5;
|
||||
|
||||
int count = 0;
|
||||
uint32_t count = 0;
|
||||
for (int i = 0; i < kCommandCount; i++) {
|
||||
CommandBig* big = allocator.Allocate<CommandBig>(CommandType::Big);
|
||||
for (int j = 0; j < kBigBufferSize; j++) {
|
||||
@@ -260,14 +260,15 @@ TEST(CommandAllocator, ManySmallCommands) {
|
||||
iterator.DataWasDestroyed();
|
||||
}
|
||||
|
||||
// ________
|
||||
// / \
|
||||
// | POUIC! |
|
||||
// \_ ______/
|
||||
// v
|
||||
// ()_()
|
||||
// (O.o)
|
||||
// (> <)o
|
||||
/* ________
|
||||
* / \
|
||||
* | POUIC! |
|
||||
* \_ ______/
|
||||
* v
|
||||
* ()_()
|
||||
* (O.o)
|
||||
* (> <)o
|
||||
*/
|
||||
|
||||
// Test usage of iterator.Reset
|
||||
TEST(CommandAllocator, IteratorReset) {
|
||||
|
||||
@@ -64,7 +64,7 @@ TEST(Math, AlignPtr) {
|
||||
|
||||
ASSERT_GE(aligned - unaligned, 0);
|
||||
ASSERT_LT(static_cast<size_t>(aligned - unaligned), kTestAlignment);
|
||||
ASSERT_EQ(reinterpret_cast<intptr_t>(aligned) & (kTestAlignment -1), 0);
|
||||
ASSERT_EQ(reinterpret_cast<uintptr_t>(aligned) & (kTestAlignment -1), 0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user