Skip to content

Commit

Permalink
Deprecate ext::function, ext::bind and family.
Browse files Browse the repository at this point in the history
  • Loading branch information
lballabio committed Jul 23, 2024
1 parent 5db36b3 commit 1adc1cf
Showing 1 changed file with 23 additions and 2 deletions.
25 changes: 23 additions & 2 deletions ql/functional.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,34 @@ namespace QuantLib {

namespace ext {

using std::function; // NOLINT(misc-unused-using-decls)
/*! \deprecated Use std::function instead.
Deprecated in version 1.36.
*/
template <typename... Ts>
using function [[deprecated("Use std::function instead")]] = std::function<Ts...>; // NOLINT(misc-unused-using-decls)

/*! \deprecated Use std::bind instead.
Deprecated in version 1.36.
*/
using std::bind; // NOLINT(misc-unused-using-decls)

/*! \deprecated Use std::ref instead.
Deprecated in version 1.36.
*/
using std::ref; // NOLINT(misc-unused-using-decls)

/*! \deprecated Use std::cref instead.
Deprecated in version 1.36.
*/
using std::cref; // NOLINT(misc-unused-using-decls)
namespace placeholders {

/*! \deprecated Use the std::placeholders namespace instead.
Deprecated in version 1.36.
*/
namespace [[deprecated("Use the std::placeholders namespace instead")]] placeholders {
using namespace std::placeholders; // NOLINT(misc-unused-using-decls)
}

/*! \deprecated To check if a function is empty, use it in a bool context
instead of comparing it to QL_NULL_FUNCTION.
Deprecated in version 1.32.
Expand Down

0 comments on commit 1adc1cf

Please sign in to comment.