Document type-pun in buffer_cat

This commit is contained in:
Vinnie Falco committed 2017-07-20 08:12:15 -07:00
1 parent e224d64949
commit 8fe07212f1
2 files changed
+7 -1

No files matched your search

+2
View File
@@ -82,6 +82,7 @@ class buffer_cat_helper<Bn...>::const_iterator
iter_t<I>&
iter()
{
// type-pun
return *reinterpret_cast<
iter_t<I>*>(static_cast<void*>(
buf_.data()));
@@ -91,6 +92,7 @@ class buffer_cat_helper<Bn...>::const_iterator
iter_t<I> const&
iter() const
{
// type-pun
return *reinterpret_cast<
iter_t<I> const*>(static_cast<
void const*>(buf_.data()));