meta_handle: deleted copy constructor (close #661)
This commit is contained in:
@@ -573,6 +573,25 @@ struct meta_handle {
|
||||
/*! @brief Default constructor. */
|
||||
meta_handle() = default;
|
||||
|
||||
|
||||
/*! @brief Default copy constructor, deleted on purpose. */
|
||||
meta_handle(const meta_handle &) = delete;
|
||||
|
||||
/*! @brief Default move constructor. */
|
||||
meta_handle(meta_handle &&) = default;
|
||||
|
||||
/**
|
||||
* @brief Default copy assignment operator, deleted on purpose.
|
||||
* @return This meta handle.
|
||||
*/
|
||||
meta_handle & operator=(const meta_handle &) = delete;
|
||||
|
||||
/**
|
||||
* @brief Default move assignment operator.
|
||||
* @return This meta handle.
|
||||
*/
|
||||
meta_handle & operator=(meta_handle &&) = default;
|
||||
|
||||
/**
|
||||
* @brief Creates a handle that points to an unmanaged object.
|
||||
* @tparam Type Type of object to use to initialize the handle.
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
struct clazz_t {
|
||||
void incr() { ++value; }
|
||||
void decr() { --value; }
|
||||
int value;
|
||||
int value{};
|
||||
};
|
||||
|
||||
struct MetaHandle: ::testing::Test {
|
||||
|
||||
Reference in New Issue
Block a user