From 62d1ebe465fb0314daeefb2cfe6f1470817a5365 Mon Sep 17 00:00:00 2001 From: Ahmad Samir Date: Tue, 21 Mar 2023 23:38:36 +0200 Subject: [PATCH] QLocale: move QSimpleParsedNumber to qlocale_p.h It was defined in qlocale_tools_p.h which already includes qlocale_p.h. Change-Id: I43464a27ec15266ce8632ca30dcd1c57d94b1f25 Reviewed-by: Edward Welbourne Reviewed-by: Thiago Macieira --- src/corelib/text/qlocale_p.h | 8 ++++++++ src/corelib/text/qlocale_tools_p.h | 8 -------- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/corelib/text/qlocale_p.h b/src/corelib/text/qlocale_p.h index 2c36f9bdaf..45983e9cd5 100644 --- a/src/corelib/text/qlocale_p.h +++ b/src/corelib/text/qlocale_p.h @@ -32,6 +32,14 @@ QT_BEGIN_NAMESPACE +template struct QSimpleParsedNumber +{ + T result; + // When used < 0, -used is how much was used, but it was an error. + qsizetype used; + bool ok() const { return used > 0; } +}; + template struct QCharacterSetMatch { static constexpr int MaxRange = std::numeric_limits::digits; diff --git a/src/corelib/text/qlocale_tools_p.h b/src/corelib/text/qlocale_tools_p.h index df58c88963..9b02403ea4 100644 --- a/src/corelib/text/qlocale_tools_p.h +++ b/src/corelib/text/qlocale_tools_p.h @@ -26,14 +26,6 @@ enum StrayCharacterMode { WhitespacesAllowed }; -template struct QSimpleParsedNumber -{ - T result; - // When used < 0, -used is how much was used, but it was an error. - qsizetype used; - bool ok() const { return used > 0; } -}; - // API note: this function can't process a number with more than 2.1 billion digits [[nodiscard]] QSimpleParsedNumber qt_asciiToDouble(const char *num, qsizetype numLen,