Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/OpenStarbound/OpenStarbound
/ operator new
Function
operator new
source/core/StarMemory.cpp:111–116 ·
view source on GitHub ↗
Source
from the content-addressed store, hash-verified
109
110
111
void* operator new(std::size_t size) {
112
auto ptr = Star::malloc(size);
113
if (!ptr)
114
throw std::bad_alloc();
115
return ptr;
116
}
117
118
void* operator new[](std::size_t size) {
119
auto ptr = Star::malloc(size);
Callers
nothing calls this directly
Calls
1
malloc
Function · 0.70
Tested by
no test coverage detected