mirror of https://github.com/OpenTTD/OpenTTD
Codechange: Create ScriptAllocator with make_unique instead of new. (#14340)
parent
b2d69ae606
commit
28cc0079f2
|
@ -508,7 +508,7 @@ bool Squirrel::CreateClassInstance(const std::string &class_name, void *real_ins
|
|||
}
|
||||
|
||||
Squirrel::Squirrel(std::string_view api_name) :
|
||||
api_name(api_name), allocator(new ScriptAllocator())
|
||||
api_name(api_name), allocator(std::make_unique<ScriptAllocator>())
|
||||
{
|
||||
this->Initialize();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue