From 715796b48a4d6656b8375bc42c3396308089c937 Mon Sep 17 00:00:00 2001 From: Tobias Hunger Date: Thu, 26 Aug 2010 18:35:30 +0200 Subject: Fix krazy issues: Use explicit constructors * Fix all warnings about non-explicit constructors except for those in 3rdparty code. --- src/libs/cplusplus/BackwardsScanner.h | 6 +++--- src/libs/cplusplus/PreprocessorClient.h | 2 +- src/libs/cplusplus/pp-macro-expander.h | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) (limited to 'src/libs/cplusplus') diff --git a/src/libs/cplusplus/BackwardsScanner.h b/src/libs/cplusplus/BackwardsScanner.h index 26b45f5667..a2cb6e6ac3 100644 --- a/src/libs/cplusplus/BackwardsScanner.h +++ b/src/libs/cplusplus/BackwardsScanner.h @@ -41,9 +41,9 @@ class CPLUSPLUS_EXPORT BackwardsScanner enum { MAX_BLOCK_COUNT = 10 }; public: - BackwardsScanner(const QTextCursor &cursor, - int maxBlockCount = MAX_BLOCK_COUNT, - const QString &suffix = QString()); + explicit BackwardsScanner(const QTextCursor &cursor, + int maxBlockCount = MAX_BLOCK_COUNT, + const QString &suffix = QString()); int startToken() const; diff --git a/src/libs/cplusplus/PreprocessorClient.h b/src/libs/cplusplus/PreprocessorClient.h index 649f6ddfe7..b9d9145fce 100644 --- a/src/libs/cplusplus/PreprocessorClient.h +++ b/src/libs/cplusplus/PreprocessorClient.h @@ -48,7 +48,7 @@ class CPLUSPLUS_EXPORT MacroArgumentReference unsigned _length; public: - MacroArgumentReference(unsigned position = 0, unsigned length = 0) + explicit MacroArgumentReference(unsigned position = 0, unsigned length = 0) : _position(position), _length(length) { } diff --git a/src/libs/cplusplus/pp-macro-expander.h b/src/libs/cplusplus/pp-macro-expander.h index f19be4111f..2021c3f2fb 100644 --- a/src/libs/cplusplus/pp-macro-expander.h +++ b/src/libs/cplusplus/pp-macro-expander.h @@ -80,7 +80,7 @@ class MacroExpander const QByteArray *resolve_formal(const QByteArray &name); public: - MacroExpander(Environment *env, pp_frame *frame = 0, Client *client = 0, unsigned start_offset = 0); + explicit MacroExpander(Environment *env, pp_frame *frame = 0, Client *client = 0, unsigned start_offset = 0); const char *operator()(const char *first, const char *last, QByteArray *result); -- cgit v1.2.1