functional.version.pass.cpp 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. //===----------------------------------------------------------------------===//
  2. //
  3. // The LLVM Compiler Infrastructure
  4. //
  5. // This file is dual licensed under the MIT and the University of Illinois Open
  6. // Source Licenses. See LICENSE.TXT for details.
  7. //
  8. //===----------------------------------------------------------------------===//
  9. //
  10. // <functional> feature macros
  11. /* Constant Value
  12. __cpp_lib_boyer_moore_searcher 201603L
  13. __cpp_lib_invoke 201411L
  14. __cpp_lib_not_fn 201603L
  15. __cpp_lib_result_of_sfinae 201210L
  16. __cpp_lib_transparent_operators 201510L
  17. */
  18. #include <functional>
  19. #include "test_macros.h"
  20. int main()
  21. {
  22. // ensure that the macros that are supposed to be defined in <functional> are defined.
  23. #if _TEST_STD_VER > 14
  24. # if !defined(__cpp_lib_invoke)
  25. # error "__cpp_lib_invoke is not defined"
  26. # elif __cpp_lib_invoke < 201411L
  27. # error "__cpp_lib_invoke has an invalid value"
  28. # endif
  29. #endif
  30. /*
  31. #if !defined(__cpp_lib_fooby)
  32. # error "__cpp_lib_fooby is not defined"
  33. #elif __cpp_lib_fooby < 201606L
  34. # error "__cpp_lib_fooby has an invalid value"
  35. #endif
  36. */
  37. }