proxygen
folly::replaceable_detail::copy_assignment_mixin< T, true > Struct Template Reference

#include <Replaceable.h>

Public Member Functions

 copy_assignment_mixin ()=default
 
 copy_assignment_mixin (copy_assignment_mixin &&)=default
 
 copy_assignment_mixin (copy_assignment_mixin const &)=default
 
copy_assignment_mixinoperator= (copy_assignment_mixin &&)=default
 
copy_assignment_mixinoperator= (copy_assignment_mixin const &other) noexcept(std::is_nothrow_destructible< T >::value &&std::is_nothrow_copy_constructible< T >::value)
 

Detailed Description

template<class T>
struct folly::replaceable_detail::copy_assignment_mixin< T, true >

Definition at line 340 of file Replaceable.h.

Constructor & Destructor Documentation

template<class T >
folly::replaceable_detail::copy_assignment_mixin< T, true >::copy_assignment_mixin ( copy_assignment_mixin< T, true > const &  )
default

Member Function Documentation

template<class T >
copy_assignment_mixin& folly::replaceable_detail::copy_assignment_mixin< T, true >::operator= ( copy_assignment_mixin< T, true > &&  )
default
template<class T >
copy_assignment_mixin& folly::replaceable_detail::copy_assignment_mixin< T, true >::operator= ( copy_assignment_mixin< T, true > const &  other)
inlinenoexcept

Definition at line 346 of file Replaceable.h.

References upload::const, folly::launder(), and folly::T.

348  {
349  T* destruct_ptr = launder(reinterpret_cast<T*>(
350  reinterpret_cast<Replaceable<T>*>(this)->storage_));
351  destruct_ptr->~T();
352  ::new (reinterpret_cast<Replaceable<T>*>(this)->storage_)
353  T(*reinterpret_cast<Replaceable<T> const&>(other));
354  return *this;
355  }
folly::std T
const
Definition: upload.py:398
FOLLY_NODISCARD T * launder(T *in) noexcept
Definition: Launder.h:48

The documentation for this struct was generated from the following file: