MCPcopy Create free account
hub / github.com/ChaiScript/ChaiScript / operator=

Method operator=

unittests/catch.hpp:5748–5755  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5746 }
5747
5748 auto operator=( ResultValueBase const &other ) -> ResultValueBase & {
5749 if( m_type == ResultBase::Ok )
5750 m_value.~T();
5751 ResultBase::operator=(other);
5752 if( m_type == ResultBase::Ok )
5753 new( &m_value ) T( other.m_value );
5754 return *this;
5755 }
5756
5757 ~ResultValueBase() override {
5758 if( m_type == Ok )

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected