From 4065f596ada672c58787a0f9faa2278621545ab9 Mon Sep 17 00:00:00 2001 From: Jean-Marc Lasgouttes Date: Wed, 19 Oct 2016 17:51:32 +0200 Subject: [PATCH] Remove unused methods in anononymous namespace These have been flagged by gcc 6. --- src/frontends/qt4/Menus.cpp | 8 -------- src/mathed/MathAutoCorrect.cpp | 14 +++++++------- src/mathed/MathParser.cpp | 18 ------------------ 3 files changed, 7 insertions(+), 33 deletions(-) diff --git a/src/frontends/qt4/Menus.cpp b/src/frontends/qt4/Menus.cpp index 78639b9e35..da1160a185 100644 --- a/src/frontends/qt4/Menus.cpp +++ b/src/frontends/qt4/Menus.cpp @@ -319,8 +319,6 @@ public: /// size_t size() const { return items_.size(); } /// - MenuItem const & operator[](size_t) const; - /// const_iterator begin() const { return items_.begin(); } /// const_iterator end() const { return items_.end(); } @@ -682,12 +680,6 @@ void MenuDefinition::read(Lexer & lex) } -MenuItem const & MenuDefinition::operator[](size_type i) const -{ - return items_[i]; -} - - bool MenuDefinition::hasFunc(FuncRequest const & func) const { for (const_iterator it = begin(), et = end(); it != et; ++it) diff --git a/src/mathed/MathAutoCorrect.cpp b/src/mathed/MathAutoCorrect.cpp index 2af6c4b77d..17431114b8 100644 --- a/src/mathed/MathAutoCorrect.cpp +++ b/src/mathed/MathAutoCorrect.cpp @@ -75,13 +75,6 @@ bool Correction::read(idocstream & is) } -void Correction::write(odocstream & os) const -{ - os << "from: '" << from1_ << "' and '" << from2_ - << "' to '" << to_ << '\'' << endl; -} - - bool Correction::correct(MathAtom & at, char_type c) const { //LYXERR(Debug::MATHED, @@ -98,6 +91,13 @@ bool Correction::correct(MathAtom & at, char_type c) const #if 0 +void Correction::write(odocstream & os) const +{ + os << "from: '" << from1_ << "' and '" << from2_ + << "' to '" << to_ << '\'' << endl; +} + + idocstream & operator>>(idocstream & is, Correction & corr) { corr.read(is); diff --git a/src/mathed/MathParser.cpp b/src/mathed/MathParser.cpp index 1e615d248b..4b0e5386c6 100644 --- a/src/mathed/MathParser.cpp +++ b/src/mathed/MathParser.cpp @@ -401,8 +401,6 @@ public: bool parse1(InsetMathGrid & grid, unsigned flags, mode_type mode, bool numbered); /// - MathData parse(unsigned flags, mode_type mode); - /// int lineno() const { return lineno_; } /// void putback(); @@ -435,8 +433,6 @@ private: /// void push_back(Token const & t); /// - void pop_back(); - /// Token const & prevToken() const; /// Token const & nextToken() const; @@ -501,12 +497,6 @@ void Parser::push_back(Token const & t) } -void Parser::pop_back() -{ - tokens_.pop_back(); -} - - Token const & Parser::prevToken() const { static const Token dummy; @@ -786,14 +776,6 @@ docstring Parser::parse_verbatim_item() } -MathData Parser::parse(unsigned flags, mode_type mode) -{ - MathData ar(buffer_); - parse(ar, flags, mode); - return ar; -} - - bool Parser::parse(MathData & array, unsigned flags, mode_type mode) { InsetMathGrid grid(buffer_, 1, 1); -- 2.39.5