summaryrefslogtreecommitdiff
path: root/absl/base
diff options
context:
space:
mode:
authorGravatar Abseil Team <absl-team@google.com>2020-08-14 12:57:11 -0700
committerGravatar Gennadiy Rozental <rogeeff@google.com>2020-08-14 18:40:01 -0400
commitd0c433455801e1c1fb6f486f0b447e22f946ab52 (patch)
treeeb73eb80204eeb515d3050e0b88818c427fcbc9b /absl/base
parentc6b3f2cf583d8fec124f9d70a172b513363506fe (diff)
Export of internal Abseil changes
-- daabc2a08b55696424add36e8fd6ed0ab397dadc by Derek Mauro <dmauro@google.com>: Internal change PiperOrigin-RevId: 326713082 GitOrigin-RevId: daabc2a08b55696424add36e8fd6ed0ab397dadc Change-Id: Ibe91394988bc3bcfaae7ac16bdc1e9b5dfd16588
Diffstat (limited to 'absl/base')
-rw-r--r--absl/base/casts.h15
1 files changed, 9 insertions, 6 deletions
diff --git a/absl/base/casts.h b/absl/base/casts.h
index 322cc1d2..83c69126 100644
--- a/absl/base/casts.h
+++ b/absl/base/casts.h
@@ -159,16 +159,19 @@ inline Dest bit_cast(const Source& source) {
return dest;
}
-// NOTE: This overload is only picked if the requirements of bit_cast are not
-// met. It is therefore UB, but is provided temporarily as previous versions of
-// this function template were unchecked. Do not use this in new code.
+// NOTE: This overload is only picked if the requirements of bit_cast are
+// not met. It is therefore UB, but is provided temporarily as previous
+// versions of this function template were unchecked. Do not use this in
+// new code.
template <
typename Dest, typename Source,
typename std::enable_if<
- !internal_casts::is_bitcastable<Dest, Source>::value, int>::type = 0>
+ !internal_casts::is_bitcastable<Dest, Source>::value,
+ int>::type = 0>
ABSL_DEPRECATED(
- "absl::bit_cast type requirements were violated. Update the types being "
- "used such that they are the same size and are both TriviallyCopyable.")
+ "absl::bit_cast type requirements were violated. Update the types "
+ "being used such that they are the same size and are both "
+ "TriviallyCopyable.")
inline Dest bit_cast(const Source& source) {
static_assert(sizeof(Dest) == sizeof(Source),
"Source and destination types should have equal sizes.");