diff options
author | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2020-10-20 10:13:49 +0200 |
---|---|---|
committer | Allan Sandfeld Jensen <allan.jensen@qt.io> | 2020-10-24 19:45:59 +0200 |
commit | c2cf5f824a09adf0362f015c1b9d1817dabb04c3 (patch) | |
tree | 54cb2e3bf0bc02d86ccf8f0e8286daaf7092fe59 /src/corelib/kernel/qmath.h | |
parent | c4245e7b8ceb233a06cea1ace9439795738adbf8 (diff) |
Whitespace cleanup in corelib/kernel
Change-Id: If061ef0af5ced4384e20a82afcea3712fa7e45d7
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Diffstat (limited to 'src/corelib/kernel/qmath.h')
-rw-r--r-- | src/corelib/kernel/qmath.h | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/corelib/kernel/qmath.h b/src/corelib/kernel/qmath.h index 98251c0b57..176e7d7978 100644 --- a/src/corelib/kernel/qmath.h +++ b/src/corelib/kernel/qmath.h @@ -229,7 +229,7 @@ inline qreal qFastCos(qreal x) constexpr inline float qDegreesToRadians(float degrees) { - return degrees * float(M_PI/180); + return degrees * float(M_PI / 180); } constexpr inline double qDegreesToRadians(double degrees) @@ -250,7 +250,7 @@ constexpr inline double qDegreesToRadians(T degrees) constexpr inline float qRadiansToDegrees(float radians) { - return radians * float(180/M_PI); + return radians * float(180 / M_PI); } constexpr inline double qRadiansToDegrees(double radians) @@ -268,7 +268,8 @@ constexpr inline long double qRadiansToDegrees(long double radians) // using integral datatypes... namespace QtPrivate { -constexpr inline quint32 qConstexprNextPowerOfTwo(quint32 v) { +constexpr inline quint32 qConstexprNextPowerOfTwo(quint32 v) +{ v |= v >> 1; v |= v >> 2; v |= v >> 4; @@ -278,7 +279,8 @@ constexpr inline quint32 qConstexprNextPowerOfTwo(quint32 v) { return v; } -constexpr inline quint64 qConstexprNextPowerOfTwo(quint64 v) { +constexpr inline quint64 qConstexprNextPowerOfTwo(quint64 v) +{ v |= v >> 1; v |= v >> 2; v |= v >> 4; |