Skip to content

Commit af53f8e

Browse files
authored
fix compile error with gcc 14 because of missing necessary header (#19, thank @xyz1001)
1 parent 579b2fd commit af53f8e

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

include/nonstd/scope.hpp

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -249,7 +249,8 @@ namespace nonstd
249249
#define scope_HAVE_IS_NOTHROW_ASSIGNABLE scope_CPP11_110
250250
#define scope_HAVE_IS_NOTHROW_MOVE_ASSIGNABLE scope_CPP11_110
251251

252-
#define scope_HAVE_REFERENCE_WRAPPER scope_CPP11_110
252+
#define scope_HAVE_FUNCATIONAL scope_CPP11_110
253+
#define scope_HAVE_REFERENCE_WRAPPER scope_HAVE_FUNCATIONAL
253254

254255
#define scope_HAVE_REMOVE_CV scope_CPP11_90
255256
#define scope_HAVE_REMOVE_REFERENCE scope_CPP11_90
@@ -329,6 +330,10 @@ namespace nonstd
329330
#include <limits> // std::numeric_limits<>
330331
#include <utility> // move(), forward<>(), swap()
331332

333+
#if scope_HAVE_FUNCATIONAL
334+
# include <functional>
335+
#endif
336+
332337
#if scope_HAVE_TYPE_TRAITS
333338
# include <type_traits>
334339
#elif scope_HAVE_TR1_TYPE_TRAITS

0 commit comments

Comments
 (0)