commit 437fef65aa1862deb1f6337062cd44a1263d9073 Author: Yuriy Skalko <yuriy.ska...@gmail.com> Date: Sun Nov 8 23:26:36 2020 +0200
Simplify operator== for ParConstIterator Comment out it while it is unused. --- src/ParIterator.cpp | 7 +++---- src/ParIterator.h | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/ParIterator.cpp b/src/ParIterator.cpp index 09cee80..7289889 100644 --- a/src/ParIterator.cpp +++ b/src/ParIterator.cpp @@ -134,14 +134,13 @@ ParagraphList const & ParConstIterator::plist() const return text()->paragraphs(); } +#if 0 bool operator==(ParConstIterator const & iter1, ParConstIterator const & iter2) { - DocIterator const * dit1 = &iter1; - DocIterator const * dit2 = &iter2; - return *dit1 == *dit2; + return static_cast<DocIterator const &>(iter1) == static_cast<DocIterator const &>(iter2); } -#if 0 + bool operator!=(ParConstIterator const & iter1, ParConstIterator const & iter2) { return !(iter1 == iter2); diff --git a/src/ParIterator.h b/src/ParIterator.h index e67732f..f1e2752 100644 --- a/src/ParIterator.h +++ b/src/ParIterator.h @@ -115,7 +115,7 @@ public: ParagraphList const & plist() const; }; -bool operator==(ParConstIterator const & it1, ParConstIterator const & it2); +//bool operator==(ParConstIterator const & it1, ParConstIterator const & it2); //bool operator!=(ParConstIterator const & it1, ParConstIterator const & it2); -- lyx-cvs mailing list lyx-cvs@lists.lyx.org http://lists.lyx.org/mailman/listinfo/lyx-cvs