diff options
author | Albert Astals Cid <aacid@kde.org> | 2021-08-21 21:46:00 +0200 |
---|---|---|
committer | Albert Astals Cid <aacid@kde.org> | 2021-08-27 16:11:53 +0200 |
commit | 6aff5bbbfe06c70314ba7ea936d98aed0e48331f (patch) | |
tree | 6e69834989b2b1560b170906215be75a7d82d139 /splash | |
parent | 646a1519d965895a4126b4e5f6fee2102d9c38a6 (diff) |
CI: Enable google-explicit-constructor
I was doing some refactoring before and was hit by one of the
constructors being magically called when i didn't want that.
Since we don't really on it (was just used in some of the explicit type
conversions) I think it makes sense to enable
And 2 small qt6 clang-tidy fixes because we don't have qt6 on
the clang-tidy CI yet
There's 2 potentially source incompatible changes in the qt frontend,
but i really really hope noone was using the constructors that way
Diffstat (limited to 'splash')
-rw-r--r-- | splash/SplashClip.h | 2 | ||||
-rw-r--r-- | splash/SplashPath.h | 2 | ||||
-rw-r--r-- | splash/SplashPattern.h | 2 | ||||
-rw-r--r-- | splash/SplashScreen.h | 4 | ||||
-rw-r--r-- | splash/SplashState.h | 2 |
5 files changed, 6 insertions, 6 deletions
diff --git a/splash/SplashClip.h b/splash/SplashClip.h index 74dc616d..0b7dd149 100644 --- a/splash/SplashClip.h +++ b/splash/SplashClip.h @@ -116,7 +116,7 @@ public: int getNumPaths() { return length; } protected: - SplashClip(const SplashClip *clip); + explicit SplashClip(const SplashClip *clip); void grow(int nPaths); bool testClipPaths(int x, int y); diff --git a/splash/SplashPath.h b/splash/SplashPath.h index 4448a645..34da6c63 100644 --- a/splash/SplashPath.h +++ b/splash/SplashPath.h @@ -122,7 +122,7 @@ public: void reserve(int n); protected: - SplashPath(const SplashPath *path); + explicit SplashPath(const SplashPath *path); void grow(int nPts); bool noCurrentPoint() { return curSubpath == length; } bool onePointSubpath() { return curSubpath == length - 1; } diff --git a/splash/SplashPattern.h b/splash/SplashPattern.h index 3c93b6e8..c99302c0 100644 --- a/splash/SplashPattern.h +++ b/splash/SplashPattern.h @@ -66,7 +66,7 @@ private: class POPPLER_PRIVATE_EXPORT SplashSolidColor : public SplashPattern { public: - SplashSolidColor(SplashColorConstPtr colorA); + explicit SplashSolidColor(SplashColorConstPtr colorA); SplashPattern *copy() const override { return new SplashSolidColor(color); } diff --git a/splash/SplashScreen.h b/splash/SplashScreen.h index 64a9c1fd..8420845e 100644 --- a/splash/SplashScreen.h +++ b/splash/SplashScreen.h @@ -32,8 +32,8 @@ class SplashScreen { public: - SplashScreen(const SplashScreenParams *params); - SplashScreen(const SplashScreen *screen); + explicit SplashScreen(const SplashScreenParams *params); + explicit SplashScreen(const SplashScreen *screen); ~SplashScreen(); SplashScreen(const SplashScreen &) = delete; diff --git a/splash/SplashState.h b/splash/SplashState.h index 26fbaffd..a7e4f686 100644 --- a/splash/SplashState.h +++ b/splash/SplashState.h @@ -89,7 +89,7 @@ public: void setTransfer(unsigned char *red, unsigned char *green, unsigned char *blue, unsigned char *gray); private: - SplashState(const SplashState *state); + explicit SplashState(const SplashState *state); SplashCoord matrix[6]; SplashPattern *strokePattern; |