1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 05:38:11 +00:00

AK: Rename create<T> => make_ref_counted<T>

And also try_create<T> => try_make_ref_counted<T>.

A global "create" was a bit much. The new name matches make<T> better,
which we've used for making single-owner objects since forever.
This commit is contained in:
Andreas Kling 2021-09-03 00:07:29 +02:00
parent 43a800a838
commit eaf88cc78a
17 changed files with 137 additions and 137 deletions

View file

@ -48,7 +48,7 @@ KResultOr<NonnullRefPtr<VMObject>> AnonymousVMObject::try_clone()
// one would keep the one it still has. This ensures that the original
// one and this one, as well as the clone have sufficient resources
// to cow all pages as needed
auto new_shared_committed_cow_pages = try_create<SharedCommittedCowPages>(committed_pages.release_value());
auto new_shared_committed_cow_pages = try_make_ref_counted<SharedCommittedCowPages>(committed_pages.release_value());
if (!new_shared_committed_cow_pages)
return ENOMEM;