aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2023-11-11 10:59:33 -0500
committerDavid Robillard <d@drobilla.net>2023-11-11 10:59:33 -0500
commitad651857ee2435582115e7de0e50e645e0aa9fc7 (patch)
tree450c52b2cdec6e2a0c857c2233a0ca0ee3da8a05
parent61980dbb9e6968f9d99df9cbd4bbe2f46f0c5050 (diff)
downloadpugl-ad651857ee2435582115e7de0e50e645e0aa9fc7.tar.gz
pugl-ad651857ee2435582115e7de0e50e645e0aa9fc7.tar.bz2
pugl-ad651857ee2435582115e7de0e50e645e0aa9fc7.zip
Suppress new warnings in clang-tidy 16
-rw-r--r--examples/.clang-tidy6
-rw-r--r--examples/cube_view.h2
-rw-r--r--examples/sybok.hpp6
-rw-r--r--test/.clang-tidy3
4 files changed, 11 insertions, 6 deletions
diff --git a/examples/.clang-tidy b/examples/.clang-tidy
index 500dff1..7dde8bb 100644
--- a/examples/.clang-tidy
+++ b/examples/.clang-tidy
@@ -1,4 +1,4 @@
-# Copyright 2020-2022 David Robillard <d@drobilla.net>
+# Copyright 2020-2023 David Robillard <d@drobilla.net>
# SPDX-License-Identifier: 0BSD OR ISC
Checks: >
@@ -13,6 +13,7 @@ Checks: >
-cert-dcl37-c,
-cert-dcl51-cpp,
-cert-err33-c,
+ -cert-err34-c,
-concurrency-mt-unsafe,
-cppcoreguidelines-avoid-const-or-ref-data-members,
-cppcoreguidelines-avoid-non-const-global-variables,
@@ -36,4 +37,7 @@ Checks: >
-performance-no-int-to-ptr,
-readability-function-cognitive-complexity,
-readability-implicit-bool-conversion,
+CheckOptions:
+ - key: cppcoreguidelines-avoid-do-while.IgnoreMacros
+ value: true
InheritParentConfig: true
diff --git a/examples/cube_view.h b/examples/cube_view.h
index 647134c..399f625 100644
--- a/examples/cube_view.h
+++ b/examples/cube_view.h
@@ -4,7 +4,7 @@
#ifndef EXAMPLES_CUBE_VIEW_H
#define EXAMPLES_CUBE_VIEW_H
-#define GL_SILENCE_DEPRECATION 1
+#define GL_SILENCE_DEPRECATION 1 // NOLINT(modernize-macro-to-enum)
#include "demo_utils.h"
diff --git a/examples/sybok.hpp b/examples/sybok.hpp
index 4fe4886..49abdf0 100644
--- a/examples/sybok.hpp
+++ b/examples/sybok.hpp
@@ -1530,7 +1530,7 @@ public:
{
VkBool32 s = {};
- if (VkResult r = vkGetPhysicalDeviceSurfaceSupportKHR(
+ if (const VkResult r = vkGetPhysicalDeviceSurfaceSupportKHR(
physicalDevice, queueFamilyIndex, surface, &s)) {
return r;
}
@@ -2015,8 +2015,8 @@ public:
VkResult end() noexcept
{
if (_commandBuffer) {
- VkResult r = _api.vkEndCommandBuffer(_commandBuffer);
- _commandBuffer = {};
+ const VkResult r = _api.vkEndCommandBuffer(_commandBuffer);
+ _commandBuffer = {};
return r;
}
diff --git a/test/.clang-tidy b/test/.clang-tidy
index f8a23aa..8ecb90f 100644
--- a/test/.clang-tidy
+++ b/test/.clang-tidy
@@ -1,9 +1,10 @@
-# Copyright 2020-2022 David Robillard <d@drobilla.net>
+# Copyright 2020-2023 David Robillard <d@drobilla.net>
# SPDX-License-Identifier: 0BSD OR ISC
Checks: >
-bugprone-suspicious-include,
-cert-err33-c,
+ -cert-err34-c,
-google-runtime-references,
-hicpp-multiway-paths-covered,
-hicpp-signed-bitwise,