From f3280a8384bad07de9b5dac019b145eb4b5d108b Mon Sep 17 00:00:00 2001 From: Marc Mutz Date: Tue, 10 Oct 2023 18:23:06 +0200 Subject: [PATCH] QSpan: remove a stale static constexpr `extent` from a base class It's not needed, and might trigger -Wshadow on some compilers. Only the public QSpan class has the `extent` static data member, everything else uses the template argument, `E`, directly. Amends f82cf6333e4e21c96d8b6bb272392f8142ead2b7. Change-Id: If378119aff1e352d1e90854b570720444cd532a0 Reviewed-by: Thiago Macieira Reviewed-by: Dennis Oberst (cherry picked from commit 9a0ae6c13bb8ad6c883285fea6fe494b532fc5e5) Reviewed-by: Qt Cherry-pick Bot --- src/corelib/tools/qspan_p.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/corelib/tools/qspan_p.h b/src/corelib/tools/qspan_p.h index c2fc6386938..ca0a16e7b9a 100644 --- a/src/corelib/tools/qspan_p.h +++ b/src/corelib/tools/qspan_p.h @@ -151,8 +151,7 @@ protected: static constexpr qsizetype m_size = qsizetype(E); // types and constants: - - static constexpr size_t extent = E; + // (in QSpan only) // constructors (need to be public d/t the way ctor inheriting works): public: