ams: prefer construct_at/destroy_at over placement new/explicit destructor

This commit is contained in:
Michael Scire
2021-03-21 20:30:40 -07:00
parent aff0da9427
commit d84dcb653d
49 changed files with 217 additions and 171 deletions

View File

@@ -127,7 +127,8 @@ namespace ams::sf::cmif {
if (storage == nullptr) {
return nullptr;
}
return new (storage) Domain(this);
return std::construct_at(static_cast<Domain *>(storage), this);
}
public:
static void DestroyDomainServiceObject(DomainServiceObject *obj) {