Userdata equality should always be valid to check, even when no explicit operator is given for it

This commit is contained in:
2019-09-12 17:10:44 +02:00
parent bd343c1b7e
commit ff4af34478
3 changed files with 16 additions and 11 deletions

View File

@@ -25,7 +25,7 @@ namespace Porygon::UserData {
delete _userData;
}
RetrievedUserData* GetUserData() const{
[[nodiscard]] RetrievedUserData* GetUserData() const{
return _userData;
}

View File

@@ -22,7 +22,7 @@ namespace Porygon::UserData {
_obj = obj;
}
~UserDataValue(){
~UserDataValue() final{
delete _userData;
}
@@ -74,7 +74,7 @@ namespace Porygon::UserData {
delete value;
}
inline void* GetObjectPointer() const{
[[nodiscard]] inline void* GetObjectPointer() const{
return _obj;
}