Skip to content
Permalink
Browse files

VideoVulkan/ShaderCompiler: Use non-member std::size instead of Array…

…Size()

Now that we're on C++17, we can use its non-member std::size function
instead of ours. This provides no functional change.
  • Loading branch information...
lioncash committed May 30, 2019
1 parent d6a6005 commit 1831dcbe6f3a2119bebc572654805045f0f0c473
Showing with 1 addition and 2 deletions.
  1. +1 −2 Source/Core/VideoBackends/Vulkan/ShaderCompiler.cpp
@@ -17,7 +17,6 @@
#include "ShaderLang.h"
#include "disassemble.h"

#include "Common/CommonFuncs.h"
#include "Common/FileUtil.h"
#include "Common/Logging/Log.h"
#include "Common/MsgHandler.h"
@@ -127,7 +126,7 @@ std::optional<SPIRVCodeVector> CompileShaderToSPV(EShLanguage stage, const char*
int pass_source_code_length = static_cast<int>(source.size());
if (!header.empty())
{
constexpr size_t subgroup_helper_header_length = ArraySize(SUBGROUP_HELPER_HEADER) - 1;
constexpr size_t subgroup_helper_header_length = std::size(SUBGROUP_HELPER_HEADER) - 1;
full_source_code.reserve(header.size() + subgroup_helper_header_length + source.size());
full_source_code.append(header);
if (g_vulkan_context->SupportsShaderSubgroupOperations())

0 comments on commit 1831dcb

Please sign in to comment.
You can’t perform that action at this time.