diff options
Diffstat (limited to 'absl')
-rw-r--r-- | absl/strings/str_cat.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/absl/strings/str_cat.h b/absl/strings/str_cat.h index ea2c4dca..bc8ea7d4 100644 --- a/absl/strings/str_cat.h +++ b/absl/strings/str_cat.h @@ -93,6 +93,7 @@ #include <cstddef> #include <cstdint> #include <cstring> +#include <initializer_list> #include <string> #include <type_traits> #include <utility> @@ -312,6 +313,10 @@ class AlphaNum { // No bool ctor -- bools convert to an integral type. // A bool ctor would also convert incoming pointers (bletch). + // Prevent brace initialization + template <typename T> + AlphaNum(std::initializer_list<T>) = delete; // NOLINT(runtime/explicit) + AlphaNum(int x) // NOLINT(runtime/explicit) : piece_(digits_, static_cast<size_t>( numbers_internal::FastIntToBuffer(x, digits_) - |