forked from qt-creator/qt-creator
Clang: Fix warnings about unused members
Remove the unused members and remove also ClangAssistProposalModel::[m_]replaceDotForArrow, which is a needled indirection. Change-Id: If6e0f65678b05fabd5fa16823a7a4c634b9fbdef Reviewed-by: Marco Bubke <marco.bubke@theqtcompany.com>
This commit is contained in:
@@ -42,7 +42,7 @@ ClangAssistProposal::ClangAssistProposal(int cursorPos, TextEditor::GenericPropo
|
||||
|
||||
bool ClangAssistProposal::isCorrective() const
|
||||
{
|
||||
return ClangAssistProposalModel::replaceDotForArrow(model());
|
||||
return false;
|
||||
}
|
||||
|
||||
void ClangAssistProposal::makeCorrection(TextEditor::TextEditorWidget *editorWidget)
|
||||
|
@@ -45,9 +45,6 @@ public:
|
||||
|
||||
virtual bool isCorrective() const;
|
||||
virtual void makeCorrection(TextEditor::TextEditorWidget *editorWidget);
|
||||
|
||||
private:
|
||||
bool m_replaceDotForArrow;
|
||||
};
|
||||
|
||||
} // namespace Internal
|
||||
|
@@ -39,13 +39,6 @@
|
||||
namespace ClangCodeModel {
|
||||
namespace Internal {
|
||||
|
||||
bool ClangAssistProposalModel::replaceDotForArrow(TextEditor::IAssistProposalModel *model)
|
||||
{
|
||||
auto clangAssistProposalModel = static_cast<ClangAssistProposalModel*>(model);
|
||||
|
||||
return clangAssistProposalModel->m_replaceDotForArrow;
|
||||
}
|
||||
|
||||
bool ClangAssistProposalModel::isSortable(const QString &/*prefix*/) const
|
||||
{
|
||||
return true;
|
||||
|
@@ -41,21 +41,8 @@ namespace Internal {
|
||||
class ClangAssistProposalModel : public TextEditor::GenericProposalModel
|
||||
{
|
||||
public:
|
||||
ClangAssistProposalModel()
|
||||
: m_sortable(false)
|
||||
, m_completionOperator(CPlusPlus::T_EOF_SYMBOL)
|
||||
, m_replaceDotForArrow(false)
|
||||
{}
|
||||
|
||||
bool isSortable(const QString &prefix) const override;
|
||||
void sort(const QString &prefix) override;
|
||||
|
||||
static bool replaceDotForArrow(IAssistProposalModel *model);
|
||||
|
||||
private:
|
||||
bool m_sortable;
|
||||
unsigned m_completionOperator;
|
||||
bool m_replaceDotForArrow;
|
||||
};
|
||||
|
||||
} // namespace Internal
|
||||
|
Reference in New Issue
Block a user