commit fcea6c471ca74e71138ab487dabbb145d1546c3f
Author: Richard Kimberly Heck <[email protected]>
Date:   Thu Jan 14 03:07:33 2021 -0500

    Revert "Add move constructor and move assignment operator for FileName 
class"
    
    For now, since it's causing problems on OSX particularly.
    
    This reverts commit 854c9de8faf9eb357adc353fc9116996445d5e38.
---
 src/support/FileName.cpp |   16 ----------------
 src/support/FileName.h   |   14 ++++----------
 2 files changed, 4 insertions(+), 26 deletions(-)

diff --git a/src/support/FileName.cpp b/src/support/FileName.cpp
index b9a1d43..5295741 100644
--- a/src/support/FileName.cpp
+++ b/src/support/FileName.cpp
@@ -158,13 +158,6 @@ FileName::FileName(FileName const & rhs) : d(new Private)
 }
 
 
-FileName::FileName(FileName && rhs) noexcept
-       : d(rhs.d)
-{
-       rhs.d = nullptr;
-}
-
-
 FileName::FileName(FileName const & rhs, string const & suffix) : d(new 
Private)
 {
        set(rhs, suffix);
@@ -181,15 +174,6 @@ FileName & FileName::operator=(FileName const & rhs)
 }
 
 
-FileName & FileName::operator=(FileName && rhs) noexcept
-{
-       auto temp = rhs.d;
-       rhs.d = d;
-       d = temp;
-       return *this;
-}
-
-
 bool FileName::empty() const
 {
        return d->name.empty();
diff --git a/src/support/FileName.h b/src/support/FileName.h
index 2bc2e48..1cf1e73 100644
--- a/src/support/FileName.h
+++ b/src/support/FileName.h
@@ -42,21 +42,15 @@ public:
         */
        explicit FileName(std::string const & abs_filename);
 
-       /// copy constructor
+       /// copy constructor.
        FileName(FileName const &);
 
-       /// move constructor
-       FileName(FileName &&) noexcept;
-
-       /// constructor with base name and suffix
+       /// constructor with base name and suffix.
        FileName(FileName const & fn, std::string const & suffix);
 
-       /// copy assign
+       ///
        FileName & operator=(FileName const &);
 
-       /// move assign
-       FileName & operator=(FileName &&) noexcept;
-
        virtual ~FileName();
        /** Set a new filename.
         * \param filename the file in question. Must have an absolute path.
@@ -225,7 +219,7 @@ private:
        bool copyTo(FileName const &, bool, FileNameSet &) const;
        ///
        struct Private;
-       Private * d;
+       Private * const d;
 };
 
 
-- 
lyx-cvs mailing list
[email protected]
http://lists.lyx.org/mailman/listinfo/lyx-cvs

Reply via email to