diff options
author | V3n3RiX <venerix@koprulu.sector> | 2022-06-29 12:04:12 +0100 |
---|---|---|
committer | V3n3RiX <venerix@koprulu.sector> | 2022-06-29 12:04:12 +0100 |
commit | 0f558761aa2dee1017b4751e4017205e015a9560 (patch) | |
tree | 037df795519468a25d9362b4e95cdaeb84eb1cf9 /dev-cpp/abseil-cpp/files/abseil-cpp-20211102.0-r2-cuda11.6-compile-fix.patch | |
parent | 752d6256e5204b958b0ef7905675a940b5e9172f (diff) |
gentoo resync : 29.12.2022
Diffstat (limited to 'dev-cpp/abseil-cpp/files/abseil-cpp-20211102.0-r2-cuda11.6-compile-fix.patch')
-rw-r--r-- | dev-cpp/abseil-cpp/files/abseil-cpp-20211102.0-r2-cuda11.6-compile-fix.patch | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/dev-cpp/abseil-cpp/files/abseil-cpp-20211102.0-r2-cuda11.6-compile-fix.patch b/dev-cpp/abseil-cpp/files/abseil-cpp-20211102.0-r2-cuda11.6-compile-fix.patch new file mode 100644 index 000000000000..59efc0f321e3 --- /dev/null +++ b/dev-cpp/abseil-cpp/files/abseil-cpp-20211102.0-r2-cuda11.6-compile-fix.patch @@ -0,0 +1,24 @@ +diff --git a/absl/strings/internal/string_constant.h b/absl/strings/internal/string_constant.h +index a11336b..e1596b1 100644 +--- a/absl/strings/internal/string_constant.h ++++ b/absl/strings/internal/string_constant.h +@@ -35,12 +35,18 @@ namespace strings_internal { + // below. + template <typename T> + struct StringConstant { ++ private: ++ static constexpr bool ValidateConstant(absl::string_view view) { ++ return view.empty() || 2 * view[0] != 1; ++ } ++ ++public: + static constexpr absl::string_view value = T{}(); + constexpr absl::string_view operator()() const { return value; } + + // Check to be sure `view` points to constant data. + // Otherwise, it can't be constant evaluated. +- static_assert(value.empty() || 2 * value[0] != 1, ++ static_assert(ValidateConstant(value), + "The input string_view must point to constant data."); + }; + |