aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSven van Haastregt <sven.vanhaastregt@arm.com>2023-06-21 15:15:23 +0100
committerarcady-lunarg <122813703+arcady-lunarg@users.noreply.github.com>2023-06-21 16:43:18 -0400
commit9575e33186c74a68831c469f7271edf386ea43a5 (patch)
treedc5ccc4fddac01516d1dee89d431aa3f480a128e
parent6a7ec4be7b8a22ab16cea0f294b5973dbcdd637a (diff)
downloadglslang-9575e33186c74a68831c469f7271edf386ea43a5.tar.gz
Fix unused parameter warning in Release builds
The `function` parameter is only used by an assert currently, so mark it as "maybe unused". Alternatively the parameter could be removed, but avoid such API churn for now.
-rw-r--r--SPIRV/SpvBuilder.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/SPIRV/SpvBuilder.cpp b/SPIRV/SpvBuilder.cpp
index 8d0b677b..df5f234b 100644
--- a/SPIRV/SpvBuilder.cpp
+++ b/SPIRV/SpvBuilder.cpp
@@ -2109,7 +2109,8 @@ Function* Builder::makeFunctionEntry(Decoration precision, Id returnType, const
return function;
}
-Id Builder::makeDebugFunction(Function* function, Id nameId, Id funcTypeId) {
+Id Builder::makeDebugFunction([[maybe_unused]] Function* function, Id nameId, Id funcTypeId)
+{
assert(function != nullptr);
assert(nameId != 0);
assert(funcTypeId != 0);