Conversation
|
Thanks for your pull request and interest in making D better, @pbackus! We are looking forward to reviewing it, and you should be hearing from a maintainer soon.
Please see CONTRIBUTING.md for more information. If you have addressed all reviews or aren't sure how to proceed, don't hesitate to ping us with a simple comment. Bugzilla references
Testing this PR locallyIf you don't have a local development environment setup, you can use Digger to test this PR: dub run digger -- build "master + phobos#8555" |
Looks like a flaky test. Force pushing to retry... |
09d772b to
e7d3730
Compare
e7d3730 to
38b9177
Compare
|
Rebased to pick up #8557 |
|
Can this be an alias/wrapper underneath? Hard to review this when most likely it's simply a copy-paste of existing code. |
38b9177 to
d7cccf1
Compare
|
@schveiguy Made it a wrapper. |
d7cccf1 to
3039f40
Compare
| } | ||
|
|
||
| /** | ||
| Manual allocator that allocates from the D runtime's garbage-collected heap. |
There was a problem hiding this comment.
I suggest describing the distinctions in more detail, i.e. explicitly mentioning that this allocator uses GC.free, and that the other does not.
There was a problem hiding this comment.
Updated the docs for GCHeapMallocator here; will do the same for GCAllocator in the other PR.
| pure nothrow @trusted void[] allocate(size_t bytes) shared const | ||
| { | ||
| return impl.allocate(bytes); | ||
| } | ||
|
|
There was a problem hiding this comment.
Would alias this work here, instead of explicit forwards?
There was a problem hiding this comment.
alias this to a private field doesn't work when used from outside the module, and even if it did, I don't think the implicit conversion would be desirable.
3039f40 to
81f1942
Compare
In preparation for the removal of GCAllocator.deallocate and GCAllocator.reallocate, make that functionality available via a new allocator with a different name. Users of GCAllocator that wish to continue using manual @System memory management instead of automatic @safe memory management can switch to GCHeapMallocator. For the rationale behind these changes, see PR dlang#8554 and issue 23318.
81f1942 to
7aa3c3a
Compare
|
Please see my comments on the other PR. |
In preparation for the removal of GCAllocator.deallocate and
GCAllocator.reallocate, make that functionality available via a new
allocator with a different name.
Users of GCAllocator that wish to continue using manual
@systemmemorymanagement instead of automatic
@safememory management can switch toGCHeapMallocator.
For the rationale behind these changes, see PR #8554 and issue 23318.
CC @CyberShadow @schveiguy
@atilaneves this adds a new symbol