fix(templates): fix FNoncopyable to satisfy the CMovable concept
This commit is contained in:
		@@ -9,17 +9,21 @@ NAMESPACE_MODULE_BEGIN(Utility)
 | 
				
			|||||||
/** A class indicates that a derived class cannot be copied. */
 | 
					/** A class indicates that a derived class cannot be copied. */
 | 
				
			||||||
struct FNoncopyable
 | 
					struct FNoncopyable
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	FNoncopyable() = default;
 | 
						FNoncopyable()                               = default;
 | 
				
			||||||
	FNoncopyable(const FNoncopyable&) = delete;
 | 
						FNoncopyable(const FNoncopyable&)            = delete;
 | 
				
			||||||
 | 
						FNoncopyable(FNoncopyable&&)                 = default;
 | 
				
			||||||
	FNoncopyable& operator=(const FNoncopyable&) = delete;
 | 
						FNoncopyable& operator=(const FNoncopyable&) = delete;
 | 
				
			||||||
 | 
						FNoncopyable& operator=(FNoncopyable&&)      = default;
 | 
				
			||||||
};
 | 
					};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
/** A class indicates that a derived class cannot be moved. */
 | 
					/** A class indicates that a derived class cannot be moved. */
 | 
				
			||||||
struct FNonmovable
 | 
					struct FNonmovable
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	FNonmovable() = default;
 | 
						FNonmovable()                              = default;
 | 
				
			||||||
	FNonmovable(FNonmovable&&) = delete;
 | 
						FNonmovable(const FNonmovable&)            = default;
 | 
				
			||||||
	FNonmovable& operator=(FNonmovable&&) = delete;
 | 
						FNonmovable(FNonmovable&&)                 = delete;
 | 
				
			||||||
 | 
						FNonmovable& operator=(const FNonmovable&) = default;
 | 
				
			||||||
 | 
						FNonmovable& operator=(FNonmovable&&)      = delete;
 | 
				
			||||||
};
 | 
					};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
/** A class indicates that a derived class cannot be copied or moved. */
 | 
					/** A class indicates that a derived class cannot be copied or moved. */
 | 
				
			||||||
@@ -27,11 +31,11 @@ struct FSingleton // : FNoncopyable, FNonmovable
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
	// NOTE: Multiple inheritance is no longer used here, as that would break the EBO in MSVC
 | 
						// NOTE: Multiple inheritance is no longer used here, as that would break the EBO in MSVC
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	FSingleton() = default;
 | 
						FSingleton()                             = default;
 | 
				
			||||||
	FSingleton(const FSingleton&) = delete;
 | 
						FSingleton(const FSingleton&)            = delete;
 | 
				
			||||||
	FSingleton(FSingleton&&) = delete;
 | 
						FSingleton(FSingleton&&)                 = delete;
 | 
				
			||||||
	FSingleton& operator=(const FSingleton&) = delete;
 | 
						FSingleton& operator=(const FSingleton&) = delete;
 | 
				
			||||||
	FSingleton& operator=(FSingleton&&) = delete;
 | 
						FSingleton& operator=(FSingleton&&)      = delete;
 | 
				
			||||||
};
 | 
					};
 | 
				
			||||||
 | 
					
 | 
				
			||||||
NAMESPACE_MODULE_END(Utility)
 | 
					NAMESPACE_MODULE_END(Utility)
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user