From: Enblend <enb...@li...> - 2019-11-23 13:00:12
|
branch: details: http://enblend.hg.sourceforge.net/hgweb/enblend/enblend/hg/p/enblend/code/rev/affc3d4dcc67 changeset: 1534:affc3d4dcc67 user: Chris <cs...@us...> date: Sat Nov 23 13:41:24 2019 +0100 description: Remove "optional_transitional.hpp" as it is no longer needed with C++17. diffstat: VERSION | 2 +- configure.ac | 2 - src/CMakeLists.txt | 2 - src/Makefile.am | 4 +- src/enblend.cc | 4 +- src/enfuse.cc | 4 +- src/minimizer.h | 5 +- src/optional_transitional.hpp | 71 ------------------------------------------- 8 files changed, 9 insertions(+), 85 deletions(-) diffs (214 lines): diff -r 51a1e6b03cc6 -r affc3d4dcc67 VERSION --- a/VERSION Fri Nov 08 16:49:12 2019 +0100 +++ b/VERSION Sat Nov 23 13:41:24 2019 +0100 @@ -1,1 +1,1 @@ -4.3-561d2f7b156b +4.3-51a1e6b03cc6 diff -r 51a1e6b03cc6 -r affc3d4dcc67 configure.ac --- a/configure.ac Fri Nov 08 16:49:12 2019 +0100 +++ b/configure.ac Sat Nov 23 13:41:24 2019 +0100 @@ -279,8 +279,6 @@ AC_CHECK_HEADERS([fenv.h limits.h stdlib.h string.h unistd.h]) -AC_CHECK_HEADERS([optional optional.hpp boost/optional.hpp], break) - AC_CHECK_HEADER(sys/times.h, [AC_DEFINE([HAVE_SYS_TIMES_H], [1], [Define if <sys/times.h> exists.])]) AC_CHECK_HEADER(tiffio.h, [], diff -r 51a1e6b03cc6 -r affc3d4dcc67 src/CMakeLists.txt --- a/src/CMakeLists.txt Fri Nov 08 16:49:12 2019 +0100 +++ b/src/CMakeLists.txt Sat Nov 23 13:41:24 2019 +0100 @@ -73,7 +73,6 @@ timer.h timer.cc minimizer.h minimizer.cc muopt.h - optional_transitional.hpp ) set(ENFUSE_SOURCES functoraccessor.hxx rect2d.hxx stride.hxx @@ -100,7 +99,6 @@ timer.h timer.cc minimizer.h minimizer.cc muopt.h - optional_transitional.hpp ) set(additional_libs) diff -r 51a1e6b03cc6 -r affc3d4dcc67 src/Makefile.am --- a/src/Makefile.am Fri Nov 08 16:49:12 2019 +0100 +++ b/src/Makefile.am Sat Nov 23 13:41:24 2019 +0100 @@ -30,7 +30,7 @@ tiff_message.h tiff_message.cc \ timer.h timer.cc \ minimizer.h minimizer.cc \ - muopt.h optional_transitional.hpp + muopt.h enblend_LDFLAGS = $(AM_LDFLAGS) enblend_LDADD = layer_selection/liblayersel.a \ $(GSL_LIBS) $(STATIC_LIBS) \ @@ -64,7 +64,7 @@ tiff_message.h tiff_message.cc \ timer.h timer.cc \ minimizer.h minimizer.cc \ - muopt.h optional_transitional.hpp + muopt.h enfuse_LDFLAGS = $(AM_LDFLAGS) enfuse_LDADD = dynamic_loader/libdynamic_loader.a \ layer_selection/liblayersel.a \ diff -r 51a1e6b03cc6 -r affc3d4dcc67 src/enblend.cc --- a/src/enblend.cc Fri Nov 08 16:49:12 2019 +0100 +++ b/src/enblend.cc Sat Nov 23 13:41:24 2019 +0100 @@ -1,6 +1,6 @@ /* * Copyright (C) 2004-2009 Andrew Mihal - * Copyright (C) 2009-2017 Christoph Spiel + * Copyright (C) 2009-2019 Christoph Spiel * * This file is part of Enblend. * @@ -48,6 +48,7 @@ #include <iostream> #include <list> #include <memory> // std::unique_ptr +#include <optional> #include <set> #include <vector> @@ -82,7 +83,6 @@ #include "alternativepercentage.h" #include "global.h" #include "layer_selection.h" -#include "optional_transitional.hpp" #include "parameter.h" #include "selector.h" #include "self_test.h" diff -r 51a1e6b03cc6 -r affc3d4dcc67 src/enfuse.cc --- a/src/enfuse.cc Fri Nov 08 16:49:12 2019 +0100 +++ b/src/enfuse.cc Sat Nov 23 13:41:24 2019 +0100 @@ -1,6 +1,6 @@ /* * Copyright (C) 2004-2009 Andrew Mihal - * Copyright (C) 2009-2017 Christoph Spiel + * Copyright (C) 2009-2019 Christoph Spiel * * This file is part of Enblend. * @@ -48,6 +48,7 @@ #include <iostream> #include <list> #include <memory> // std::unique_ptr +#include <optional> #include <set> #include <vector> @@ -86,7 +87,6 @@ #include "exposure_weight.h" #include "global.h" #include "layer_selection.h" -#include "optional_transitional.hpp" #include "parameter.h" #include "selector.h" #include "self_test.h" diff -r 51a1e6b03cc6 -r affc3d4dcc67 src/minimizer.h --- a/src/minimizer.h Fri Nov 08 16:49:12 2019 +0100 +++ b/src/minimizer.h Sat Nov 23 13:41:24 2019 +0100 @@ -1,5 +1,5 @@ /* - * Copyright (C) 2012-2017 Dr. Christoph L. Spiel + * Copyright (C) 2012-2019 Dr. Christoph L. Spiel * * This file is part of Enblend. * @@ -26,6 +26,7 @@ #include <config.h> #endif +#include <optional> #include <string> #include <stdexcept> #include <vector> @@ -34,8 +35,6 @@ #include <gsl/gsl_multimin.h> #include <gsl/gsl_vector.h> -#include "optional_transitional.hpp" - class Minimizer { diff -r 51a1e6b03cc6 -r affc3d4dcc67 src/optional_transitional.hpp --- a/src/optional_transitional.hpp Fri Nov 08 16:49:12 2019 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,71 +0,0 @@ -// Copyright (C) 2016, 2017 Christoph L. Spiel -// -// This file is part of Enblend. -// -// Enblend is free software; you can redistribute it and/or modify -// it under the terms of the GNU General Public License as published by -// the Free Software Foundation; either version 2 of the License, or -// (at your option) any later version. -// -// Enblend is distributed in the hope that it will be useful, -// but WITHOUT ANY WARRANTY; without even the implied warranty of -// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -// GNU General Public License for more details. -// -// You should have received a copy of the GNU General Public License -// along with Enblend; if not, write to the Free Software -// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - - -#ifndef OPTIONAL_TRANSITIONAL_HEADER_INCLUDED -#define OPTIONAL_TRANSITIONAL_HEADER_INCLUDED - - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - - -#if defined(HAVE_OPTIONAL) || defined(HAVE_OPTIONAL_HPP) - -#if defined(HAVE_OPTIONAL) -#include <optional> -#elif defined(HAVE_OPTIONAL_HPP) -#include <optional.hpp> -#endif - -#if __cplusplus < 201500L && (!defined _MSC_VER || _MSC_VER<1916) -namespace std -{ - template <typename t> using optional = ::std::experimental::optional<t>; - using experimental::nullopt; -} -#endif - -#elif defined(HAVE_BOOST_OPTIONAL_HPP) - -#include <boost/optional.hpp> -#include <boost/version.hpp> -namespace std -{ - template <typename t> using optional = ::boost::optional<t>; -#if defined(BOOST_VERSION) && (BOOST_VERSION >= 106000) - const ::boost::none_t nullopt((::boost::none_t::init_tag())); -#else - constexpr ::boost::none_t nullopt; -#endif -} - -#else - -#error "no viable, C++-17-compatible <optional> header file defined" - -#endif - - -#endif // OPTIONAL_TRANSITIONAL_HEADER_INCLUDED - - -// Local Variables: -// mode: c++ -// End: |