mirror of
https://github.com/citra-emu/citra.git
synced 2024-11-27 23:30:04 +00:00
ResultVal: Fixed compilation when reassigning a ResultVal.
This commit is contained in:
parent
9a8d5794c7
commit
1b298ca1a3
@ -307,14 +307,14 @@ public:
|
|||||||
}
|
}
|
||||||
|
|
||||||
ResultVal& operator=(const ResultVal& o) {
|
ResultVal& operator=(const ResultVal& o) {
|
||||||
if (*this) {
|
if (!empty()) {
|
||||||
if (o) {
|
if (!o.empty()) {
|
||||||
*GetPointer() = *o.GetPointer();
|
*GetPointer() = *o.GetPointer();
|
||||||
} else {
|
} else {
|
||||||
GetPointer()->~T();
|
GetPointer()->~T();
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (o) {
|
if (!o.empty()) {
|
||||||
new (&storage) T(*o.GetPointer());
|
new (&storage) T(*o.GetPointer());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user