LibJS+LibWeb: Rename Heap::allocate_without_realm to Heap::allocate

Now that the heap has no knowledge about a JavaScript realm and is
purely for managing the memory of the heap, it does not make sense
to name this function to say that it is a non-realm variant.
This commit is contained in:
Shannon Booth 2024-11-14 06:13:46 +13:00 committed by Tim Flynn
parent 9b79a686eb
commit 1e54003cb1
Notes: github-actions[bot] 2024-11-13 21:52:39 +00:00
115 changed files with 243 additions and 243 deletions

View file

@ -38,7 +38,7 @@ void Response::visit_edges(JS::Cell::Visitor& visitor)
JS::NonnullGCPtr<Response> Response::create(JS::VM& vm)
{
return vm.heap().allocate_without_realm<Response>(HeaderList::create(vm));
return vm.heap().allocate<Response>(HeaderList::create(vm));
}
// https://fetch.spec.whatwg.org/#ref-for-concept-network-error%E2%91%A3
@ -360,7 +360,7 @@ JS::NonnullGCPtr<BasicFilteredResponse> BasicFilteredResponse::create(JS::VM& vm
header_list->append(header);
}
return vm.heap().allocate_without_realm<BasicFilteredResponse>(internal_response, header_list);
return vm.heap().allocate<BasicFilteredResponse>(internal_response, header_list);
}
BasicFilteredResponse::BasicFilteredResponse(JS::NonnullGCPtr<Response> internal_response, JS::NonnullGCPtr<HeaderList> header_list)
@ -390,7 +390,7 @@ JS::NonnullGCPtr<CORSFilteredResponse> CORSFilteredResponse::create(JS::VM& vm,
header_list->append(header);
}
return vm.heap().allocate_without_realm<CORSFilteredResponse>(internal_response, header_list);
return vm.heap().allocate<CORSFilteredResponse>(internal_response, header_list);
}
CORSFilteredResponse::CORSFilteredResponse(JS::NonnullGCPtr<Response> internal_response, JS::NonnullGCPtr<HeaderList> header_list)
@ -409,7 +409,7 @@ JS::NonnullGCPtr<OpaqueFilteredResponse> OpaqueFilteredResponse::create(JS::VM&
{
// An opaque filtered response is a filtered response whose type is "opaque", URL list is the empty list,
// status is 0, status message is the empty byte sequence, header list is empty, and body is null.
return vm.heap().allocate_without_realm<OpaqueFilteredResponse>(internal_response, HeaderList::create(vm));
return vm.heap().allocate<OpaqueFilteredResponse>(internal_response, HeaderList::create(vm));
}
OpaqueFilteredResponse::OpaqueFilteredResponse(JS::NonnullGCPtr<Response> internal_response, JS::NonnullGCPtr<HeaderList> header_list)
@ -429,7 +429,7 @@ JS::NonnullGCPtr<OpaqueRedirectFilteredResponse> OpaqueRedirectFilteredResponse:
{
// An opaque-redirect filtered response is a filtered response whose type is "opaqueredirect",
// status is 0, status message is the empty byte sequence, header list is empty, and body is null.
return vm.heap().allocate_without_realm<OpaqueRedirectFilteredResponse>(internal_response, HeaderList::create(vm));
return vm.heap().allocate<OpaqueRedirectFilteredResponse>(internal_response, HeaderList::create(vm));
}
OpaqueRedirectFilteredResponse::OpaqueRedirectFilteredResponse(JS::NonnullGCPtr<Response> internal_response, JS::NonnullGCPtr<HeaderList> header_list)