From 8e0c2d7d22141ea391f99a85a6f6557a07a4eb52 Mon Sep 17 00:00:00 2001 From: Marc Mutz Date: Fri, 23 Jul 2021 21:26:35 +0200 Subject: Fix various -Wdeprecated-enum-float-conversions around the code MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit In two cases, it was as easy as replacing an unnamed enum's values with constexpr variables. In the case of QSimplex, I opted for qToUnderlying(), as the enum made sense on its own. Change-Id: Ifcf5be14bd2f35e50adabdbd7ecdb2e83f6bf5b4 Reviewed-by: Qt CI Bot Reviewed-by: MÃ¥rten Nordheim Reviewed-by: Edward Welbourne --- src/widgets/graphicsview/qsimplex_p.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/widgets') diff --git a/src/widgets/graphicsview/qsimplex_p.cpp b/src/widgets/graphicsview/qsimplex_p.cpp index 38c2df5fc6..b9f7275d00 100644 --- a/src/widgets/graphicsview/qsimplex_p.cpp +++ b/src/widgets/graphicsview/qsimplex_p.cpp @@ -551,7 +551,7 @@ qreal QSimplex::solver(SolverFactor factor) // Return the value calculated by the simplex plus the value of the // fixed variables. - return (factor * valueAt(0, columns - 1)) + resultOffset; + return (qToUnderlying(factor) * valueAt(0, columns - 1)) + resultOffset; } /*! -- cgit v1.2.3