diff --git a/src/core/lib/resource_quota/arena.h b/src/core/lib/resource_quota/arena.h index edcab2caf87..fdc93621c3c 100644 --- a/src/core/lib/resource_quota/arena.h +++ b/src/core/lib/resource_quota/arena.h @@ -173,6 +173,8 @@ class Arena { } } + // Allocates T from the arena. + // The caller is responsible for calling p->~T(), but should NOT delete. // TODO(roth): We currently assume that all callers need alignment of 16 // bytes, which may be wrong in some cases. When we have time, we should // change this to instead use the alignment of the type being allocated by @@ -185,6 +187,7 @@ class Arena { } // Like New, but has the arena call p->~T() at arena destruction time. + // The caller should NOT delete. template T* ManagedNew(Args&&... args) { auto* p = New>(std::forward(args)...);