summaryrefslogtreecommitdiff
path: root/src/plugins/cpptools
diff options
context:
space:
mode:
authorChristian Kandeler <christian.kandeler@digia.com>2014-07-01 11:08:26 +0200
committerhjk <hjk121@nokiamail.com>2014-07-01 11:52:08 +0200
commit93304df0381cbeabf4c8435aec0ad55fbc7f8fe7 (patch)
tree7cbe348b1e3f88041b7e159aa335031e2c41bfc8 /src/plugins/cpptools
parent139449239c7cd63ab933d13e20b37cd717a45fe7 (diff)
downloadqt-creator-93304df0381cbeabf4c8435aec0ad55fbc7f8fe7.tar.gz
Always pass Core::Id by value.
Currently we pass in some places by value, elsewhere by const ref and for some weird reason also by const value in a lot of places. The latter is particularly annoying, as it is also used in interfaces and therefore forces all implementors to do the same, since leaving the "const" off is causing compiler warnings with MSVC. Change-Id: I65b87dc3cce0986b8a55ff6119cb752361027803 Reviewed-by: hjk <hjk121@nokiamail.com>
Diffstat (limited to 'src/plugins/cpptools')
-rw-r--r--src/plugins/cpptools/cppcompletionassistprovider.cpp2
-rw-r--r--src/plugins/cpptools/cppcompletionassistprovider.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/cpptools/cppcompletionassistprovider.cpp b/src/plugins/cpptools/cppcompletionassistprovider.cpp
index c6a5dacfe4..69c3b05709 100644
--- a/src/plugins/cpptools/cppcompletionassistprovider.cpp
+++ b/src/plugins/cpptools/cppcompletionassistprovider.cpp
@@ -41,7 +41,7 @@ using namespace CppTools;
// ---------------------------
// CppCompletionAssistProvider
// ---------------------------
-bool CppCompletionAssistProvider::supportsEditor(const Core::Id &editorId) const
+bool CppCompletionAssistProvider::supportsEditor(Core::Id editorId) const
{
return editorId == CppEditor::Constants::CPPEDITOR_ID;
}
diff --git a/src/plugins/cpptools/cppcompletionassistprovider.h b/src/plugins/cpptools/cppcompletionassistprovider.h
index aaf2cdde41..8873fd3518 100644
--- a/src/plugins/cpptools/cppcompletionassistprovider.h
+++ b/src/plugins/cpptools/cppcompletionassistprovider.h
@@ -55,7 +55,7 @@ class CPPTOOLS_EXPORT CppCompletionAssistProvider : public TextEditor::Completio
Q_OBJECT
public:
- bool supportsEditor(const Core::Id &editorId) const QTC_OVERRIDE;
+ bool supportsEditor(Core::Id editorId) const QTC_OVERRIDE;
int activationCharSequenceLength() const QTC_OVERRIDE;
bool isActivationCharSequence(const QString &sequence) const QTC_OVERRIDE;
bool isContinuationChar(const QChar &c) const QTC_OVERRIDE;