PStack
2.0
Stack trace printer for MSVC and GCC binaries
|
Removes the ability to use an assignment operation on derived classes. More...
#include <not_assignable.hpp>
Protected Member Functions | |
not_assignable & | operator= (not_assignable const &) const =delete |
Delete the basic assignment operator. | |
constexpr | not_assignable () noexcept |
A simple CTOR suitable for noexcept and constexpr uses. | |
~not_assignable () noexcept | |
A simple CTOR suitable for noexcept uses. | |
Removes the ability to use an assignment operation on derived classes.
In some cases, it is not desirable to be able to assign onto an existing instance of a class while still allowing the ability to construct copies (see psystem::not_copyable to prevent both). An "immutable" class is one such instance. Classes may declare themselves with psystem::not_assignable as their base to get this functionality. This class will not add any overhead at run-time.