diff options
author | Neil <nyamatongwe@gmail.com> | 2021-08-28 09:42:05 +1000 |
---|---|---|
committer | Neil <nyamatongwe@gmail.com> | 2021-08-28 09:42:05 +1000 |
commit | f0e6ea3f244af47843a5c2d42066054467771685 (patch) | |
tree | 6a9e90896e3311b9ed69561917c72a3607e931a9 | |
parent | 2413db664abc3389f11be3a6839acc618a70d1d0 (diff) | |
download | scintilla-mirror-f0e6ea3f244af47843a5c2d42066054467771685.tar.gz |
Follow rule-of-zero by removing unnecessary destructors.
-rw-r--r-- | src/Decoration.cxx | 6 | ||||
-rw-r--r-- | src/Selection.cxx | 3 | ||||
-rw-r--r-- | src/Selection.h | 1 |
3 files changed, 0 insertions, 10 deletions
diff --git a/src/Decoration.cxx b/src/Decoration.cxx index 163347ce9..a26eecd1c 100644 --- a/src/Decoration.cxx +++ b/src/Decoration.cxx @@ -88,7 +88,6 @@ class DecorationList : public IDecorationList { public: DecorationList(); - ~DecorationList() override; const std::vector<const IDecoration*> &View() const noexcept override { return decorationView; @@ -127,11 +126,6 @@ DecorationList<POS>::DecorationList() : currentIndicator(0), currentValue(1), cu } template <typename POS> -DecorationList<POS>::~DecorationList() { - current = nullptr; -} - -template <typename POS> Decoration<POS> *DecorationList<POS>::DecorationFromIndicator(int indicator) noexcept { for (const std::unique_ptr<Decoration<POS>> &deco : decorationList) { if (deco->Indicator() == indicator) { diff --git a/src/Selection.cxx b/src/Selection.cxx index 9cf4e6f09..fbdc474eb 100644 --- a/src/Selection.cxx +++ b/src/Selection.cxx @@ -194,9 +194,6 @@ Selection::Selection() : mainRange(0), moveExtends(false), tentativeMain(false), AddSelection(SelectionRange(SelectionPosition(0))); } -Selection::~Selection() { -} - bool Selection::IsRectangular() const noexcept { return (selType == SelTypes::rectangle) || (selType == SelTypes::thin); } diff --git a/src/Selection.h b/src/Selection.h index 7912d03e5..2e554f999 100644 --- a/src/Selection.h +++ b/src/Selection.h @@ -148,7 +148,6 @@ public: SelTypes selType; Selection(); - ~Selection(); bool IsRectangular() const noexcept; Sci::Position MainCaret() const noexcept; Sci::Position MainAnchor() const noexcept; |