From 2ab86aa91508ca977b12c3ec794ae3ddbb80f1dc Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Mon, 16 May 2022 19:11:33 +0100 Subject: Work around weird GCC 11.3 error const-expr copying an optional --- icespider/core/xwwwFormUrlEncoded.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/icespider/core/xwwwFormUrlEncoded.cpp b/icespider/core/xwwwFormUrlEncoded.cpp index 42bbddd..0414cf7 100644 --- a/icespider/core/xwwwFormUrlEncoded.cpp +++ b/icespider/core/xwwwFormUrlEncoded.cpp @@ -99,9 +99,9 @@ constexpr HexIn hexin = []() { size_t firstHex = std::min({'0', 'a', 'A'}); size_t lastHex = std::max({'9', 'f', 'F'}); for (auto first = firstHex; first <= lastHex; first++) { - if (const auto ch1 = hextable[first]) { + if (const auto & ch1 = hextable[first]) { for (auto second = firstHex; second <= lastHex; second++) { - if (const auto ch2 = hextable[second]) { + if (const auto & ch2 = hextable[second]) { hexin[first][second] = static_cast((*ch1 << 4U) + *ch2); } } -- cgit v1.2.3