Designer: Pass strings by reference

Change-Id: I86395393f5b79a2ade99e4422453bec5395d2898
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@digia.com>
This commit is contained in:
Orgad Shaneh
2014-05-19 23:33:14 +03:00
committed by Orgad Shaneh
parent b3a5604634
commit ee26fdf32c

View File

@@ -95,7 +95,7 @@ private:
class DocumentContainsDeclaration: protected SymbolVisitor
{
public:
bool operator()(Scope *scope, const QString function)
bool operator()(Scope *scope, const QString &function)
{
if (!scope)
return false;
@@ -139,13 +139,13 @@ private:
Overview m_overview;
};
bool documentContainsFunctionDefinition(const Document::Ptr &document, const QString function)
bool documentContainsFunctionDefinition(const Document::Ptr &document, const QString &function)
{
return DocumentContainsFunctionDefinition()(document->globalNamespace(), function);
}
bool documentContainsMemberFunctionDeclaration(const Document::Ptr &document,
const QString declaration)
const QString &declaration)
{
return DocumentContainsDeclaration()(document->globalNamespace(), declaration);
}