|
30 | 30 | #endif // no system header
|
31 | 31 |
|
32 | 32 | #include <thrust/detail/config/compiler.h> // IWYU pragma: export
|
33 |
| -#include <thrust/detail/config/deprecated.h> // IWYU pragma: export |
34 | 33 |
|
35 | 34 | // Deprecation warnings may be silenced by defining the following macros. These
|
36 | 35 | // may be combined.
|
|
87 | 86 |
|
88 | 87 | #endif // !THRUST_CPP_DIALECT
|
89 | 88 |
|
| 89 | +// Macros to suppress deprecation compiler warnings, from "deprecated.h" |
| 90 | +// TODO: These macros start with `LIBCUDACXX`. So, when libhipcxx is |
| 91 | +// available in this scope, we should remove these macros and use the ones |
| 92 | +// from libhipcxx. |
| 93 | +// Check for deprecation opt-outs |
| 94 | +#if defined(LIBCUDACXX_IGNORE_DEPRECATED_CPP_DIALECT) || defined(CCCL_IGNORE_DEPRECATED_CPP_DIALECT) \ |
| 95 | + || defined(CUB_IGNORE_DEPRECATED_CPP_DIALECT) |
| 96 | +# if !defined(THRUST_IGNORE_DEPRECATED_CPP_DIALECT) |
| 97 | +# define THRUST_IGNORE_DEPRECATED_CPP_DIALECT |
| 98 | +# endif |
| 99 | +#endif // suppress all dialect deprecation warnings |
| 100 | +#if defined(LIBCUDACXX_IGNORE_DEPRECATED_CPP_14) || defined(CCCL_IGNORE_DEPRECATED_CPP_14) \ |
| 101 | + || defined(CUB_IGNORE_DEPRECATED_CPP_14) || defined(THRUST_IGNORE_DEPRECATED_CPP_DIALECT) |
| 102 | +# if !defined(THRUST_IGNORE_DEPRECATED_CPP_14) |
| 103 | +# define THRUST_IGNORE_DEPRECATED_CPP_14 |
| 104 | +# endif |
| 105 | +#endif // suppress all c++14 dialect deprecation warnings |
| 106 | +#if defined(LIBCUDACXX_IGNORE_DEPRECATED_CPP_11) || defined(CCCL_IGNORE_DEPRECATED_CPP_11) \ |
| 107 | + || defined(CUB_IGNORE_DEPRECATED_CPP_11) || defined(THRUST_IGNORE_DEPRECATED_CPP_DIALECT) \ |
| 108 | + || defined(THRUST_IGNORE_DEPRECATED_CPP_14) |
| 109 | +# if !defined(THRUST_IGNORE_DEPRECATED_CPP_11) |
| 110 | +# define THRUST_IGNORE_DEPRECATED_CPP_11 |
| 111 | +# endif |
| 112 | +#endif // suppress all c++11 dialect deprecation warnings |
| 113 | +#if defined(LIBCUDACXX_IGNORE_DEPRECATED_COMPILER) || defined(CCCL_IGNORE_DEPRECATED_COMPILER) \ |
| 114 | + || defined(CUB_IGNORE_DEPRECATED_COMPILER) || defined(THRUST_IGNORE_DEPRECATED_CPP_DIALECT) \ |
| 115 | + || defined(THRUST_IGNORE_DEPRECATED_CPP_14) || defined(THRUST_IGNORE_DEPRECATED_CPP_11) |
| 116 | +# if !defined(THRUST_IGNORE_DEPRECATED_COMPILER) |
| 117 | +# define THRUST_IGNORE_DEPRECATED_COMPILER |
| 118 | +# endif |
| 119 | +#endif // suppress all compiler deprecation warnings |
| 120 | + |
90 | 121 | // Constexpr feature macros:
|
91 | 122 | #if THRUST_CPP_DIALECT >= 2023
|
92 | 123 | # define THRUST_CONSTEXPR_SINCE_CXX23 constexpr
|
@@ -149,7 +180,7 @@ THRUST_COMPILER_DEPRECATION_SOFT(C++ 17, C++ 11);
|
149 | 180 | #elif THRUST_CPP_DIALECT == 2014 && !defined(THRUST_IGNORE_DEPRECATED_CPP_14)
|
150 | 181 | // =C++14. Soft upgrade message:
|
151 | 182 | THRUST_COMPILER_DEPRECATION_SOFT(C++ 17, C++ 14);
|
152 |
| -#endif // THRUST_CPP_DIALECT >= 2017 |
| 183 | +#endif // THRUST_CPP_DIALECT < 2011 |
153 | 184 |
|
154 | 185 | #undef THRUST_COMPILER_DEPRECATION_SOFT
|
155 | 186 | #undef THRUST_COMPILER_DEPRECATION
|
|
0 commit comments