From 70bd99294d2054a69329c362a4c2d6f4bd0714b3 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Tue, 3 Nov 2020 13:54:15 +0200 Subject: Add missing copy constructor We have a copy assigned operator and without the corresponding copy constructor we get a -Wdeprecated-copy warning with newer GCC versions. Instead of adding the copy constructor we could have also dropped the copy assignment since it is identical to what would be implied. It's not, however, clear why it was added in the first place (it was added before we started tracking development with git). Chances are, some old and broken compiler is confused by the other assignment operator. So to be on the safe side we rather add the copy constructor. --- libxsde/xsde/cxx/hybrid/sequence.hxx | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/libxsde/xsde/cxx/hybrid/sequence.hxx b/libxsde/xsde/cxx/hybrid/sequence.hxx index b7e6f3e..b5523d0 100644 --- a/libxsde/xsde/cxx/hybrid/sequence.hxx +++ b/libxsde/xsde/cxx/hybrid/sequence.hxx @@ -412,6 +412,11 @@ namespace xsde { } + var_const_iterator (const var_const_iterator& j) + : i_ (j.i_) + { + } + var_const_iterator (var_iterator j) : i_ (const_cast (j.i_)) { -- cgit v1.1