diff --git a/.clang-tidy b/.clang-tidy index 0231053c..85de2f59 100644 --- a/.clang-tidy +++ b/.clang-tidy @@ -16,7 +16,7 @@ Checks: "-*,\ -readability-magic-numbers,\ -readability-identifier-length,\ -readability-function-cognitive-complexity" -WarningsAsErrors: '' +WarningsAsErrors: '*' CheckOptions: - key: 'bugprone-argument-comment.StrictMode' value: 'true' diff --git a/include/thinks/tph_poisson.h b/include/thinks/tph_poisson.h index d9bc9b6c..866fa50b 100644 --- a/include/thinks/tph_poisson.h +++ b/include/thinks/tph_poisson.h @@ -39,11 +39,9 @@ extern "C" { #define TPH_POISSON_CEIL ceilf #define TPH_POISSON_FLOOR floorf #endif -/* clang-format on */ typedef TPH_POISSON_REAL_TYPE tph_poisson_real; -/* clang-format off */ typedef struct tph_poisson_args_ tph_poisson_args; typedef struct tph_poisson_allocator_ tph_poisson_allocator; typedef struct tph_poisson_sampling_ tph_poisson_sampling; @@ -1063,8 +1061,10 @@ int tph_poisson_create(const tph_poisson_args *args, /* Add first sample randomly within bounds. No need to check (non-existing) neighbors. */ tph_poisson_rand_sample(&ctx, ctx.sample); - ret = tph_poisson_add_sample(&ctx, internal, ctx.sample); - TPH_POISSON_ASSERT(ret == TPH_POISSON_SUCCESS); + tph_poisson_add_sample(&ctx, internal, ctx.sample); + (void)tph_poisson_add_sample(&ctx, internal, ctx.sample); + // ret = tph_poisson_add_sample(&ctx, internal, ctx.sample); + // TPH_POISSON_ASSERT(ret == TPH_POISSON_SUCCESS); TPH_POISSON_ASSERT(tph_poisson_vec_size(&ctx.active_indices) / (ptrdiff_t)sizeof(ptrdiff_t) == 1); ptrdiff_t active_index_count = 1; diff --git a/test/src/tph_poisson_alloc_test.c b/test/src/tph_poisson_alloc_test.c index ffbca405..8c18c799 100644 --- a/test/src/tph_poisson_alloc_test.c +++ b/test/src/tph_poisson_alloc_test.c @@ -188,6 +188,8 @@ static void test_destroyed_alloc(void) tph_poisson_destroy(&sampling); } +static void test_arena_alloc(void) {} + int main(int argc, char *argv[]) { (void)argc; @@ -202,7 +204,7 @@ int main(int argc, char *argv[]) printf("test_destroyed_alloc...\n"); test_destroyed_alloc(); - printf("test_arena_alloc"); + printf("test_arena_alloc...\n"); test_arena_alloc(); return EXIT_SUCCESS;