Merge pull request #13116 from mitaclaw/ranges-modernization-8-trivial-of

Ranges Algorithms Modernization - Of
This commit is contained in:
JMC47
2024-12-26 16:51:53 -05:00
committed by GitHub
59 changed files with 148 additions and 166 deletions

View File

@ -304,8 +304,8 @@ void OGLGfx::DispatchComputeShader(const AbstractShader* shader, u32 groupsize_x
static_cast<const OGLPipeline*>(m_current_pipeline)->GetProgram()->shader.Bind();
// Barrier to texture can be used for reads.
if (std::any_of(m_bound_image_textures.begin(), m_bound_image_textures.end(),
[](auto image) { return image != nullptr; }))
if (std::ranges::any_of(m_bound_image_textures,
[](const auto* image) { return image != nullptr; }))
{
glMemoryBarrier(GL_TEXTURE_UPDATE_BARRIER_BIT);
}

View File

@ -929,8 +929,8 @@ void VulkanContext::DisableDebugUtils()
bool VulkanContext::SupportsDeviceExtension(const char* name) const
{
return std::any_of(m_device_extensions.begin(), m_device_extensions.end(),
[name](const std::string& extension) { return extension == name; });
return std::ranges::any_of(m_device_extensions,
[name](const std::string& extension) { return extension == name; });
}
static bool DriverIsMesa(VkDriverId driver_id)