From 1690169dcefcc6fe6249221c4c08cb371cc700fc Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Tue, 2 May 2017 13:05:41 +0200 Subject: Make dir_iterator move-ctor noexcept, revert previous workaround --- libbutl/filesystem.cxx | 7 ------- libbutl/filesystem.hxx | 2 +- libbutl/filesystem.ixx | 2 +- 3 files changed, 2 insertions(+), 9 deletions(-) diff --git a/libbutl/filesystem.cxx b/libbutl/filesystem.cxx index b6b6b5b..6a64073 100644 --- a/libbutl/filesystem.cxx +++ b/libbutl/filesystem.cxx @@ -1229,14 +1229,7 @@ namespace butl bool self_; bool follow_symlinks_; preopen preopen_; - - // @@ Some issue with libc++ (reproducible on FreeBSD 11 with Clang 3.8). - // -#ifdef _LIBCPP_VERSION - std::vector> iters_; -#else small_vector, 1> iters_; -#endif }; // Search for paths matching the pattern and call the specified function for diff --git a/libbutl/filesystem.hxx b/libbutl/filesystem.hxx index bf1b3af..4fa1021 100644 --- a/libbutl/filesystem.hxx +++ b/libbutl/filesystem.hxx @@ -434,7 +434,7 @@ namespace butl dir_iterator (const dir_iterator&) = delete; dir_iterator& operator= (const dir_iterator&) = delete; - dir_iterator (dir_iterator&& x); + dir_iterator (dir_iterator&&) noexcept; dir_iterator& operator= (dir_iterator&&); dir_iterator& operator++ () {next (); return *this;} diff --git a/libbutl/filesystem.ixx b/libbutl/filesystem.ixx index 43fef20..eb9984b 100644 --- a/libbutl/filesystem.ixx +++ b/libbutl/filesystem.ixx @@ -108,7 +108,7 @@ namespace butl // dir_iterator // inline dir_iterator:: - dir_iterator (dir_iterator&& x) + dir_iterator (dir_iterator&& x) noexcept : e_ (std::move (x.e_)), h_ (x.h_) { #ifndef _WIN32 -- cgit v1.1