X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=boost%2Fboost%2Flast_value.hpp;h=183a739eadcae3391856feccdebfe72a851d4392;hb=9c375cb606d7950f8f6bd31e7a841399dc7bbfb2;hp=a9920653aec88d53b9f0a32885c6153cebb6e978;hpb=59b6a4701a8d2b5155af08cf758b4ca120201282;p=lyx.git diff --git a/boost/boost/last_value.hpp b/boost/boost/last_value.hpp index a9920653ae..183a739ead 100644 --- a/boost/boost/last_value.hpp +++ b/boost/boost/last_value.hpp @@ -1,28 +1,23 @@ // last_value function object (documented as part of Boost.Signals) -// -// Copyright (C) 2001 Doug Gregor (gregod@cs.rpi.edu) -// -// Permission to copy, use, sell and distribute this software is granted -// provided this copyright notice appears in all copies. -// Permission to modify the code and to distribute modified code is granted -// provided this copyright notice appears in all copies, and a notice -// that the code was modified is included with the copyright notice. -// -// This software is provided "as is" without express or implied warranty, -// and with no claim as to its suitability for any purpose. - -// For more information, see http://www.boost.org + +// Copyright Douglas Gregor 2001-2003. Use, modification and +// distribution is subject to the Boost Software License, Version +// 1.0. (See accompanying file LICENSE_1_0.txt or copy at +// http://www.boost.org/LICENSE_1_0.txt) + +// For more information, see http://www.boost.org/libs/signals #ifndef BOOST_LAST_VALUE_HPP #define BOOST_LAST_VALUE_HPP #include +#include namespace boost { template struct last_value { typedef T result_type; - + template T operator()(InputIterator first, InputIterator last) const { @@ -33,14 +28,19 @@ namespace boost { return value; } }; - + template<> - class last_value { + struct last_value { +#ifdef BOOST_NO_VOID_RETURNS struct unusable {}; public: typedef unusable result_type; - +#else + public: + typedef void result_type; +#endif // BOOST_NO_VOID_RETURNS + template result_type operator()(InputIterator first, InputIterator last) const