Dynamic array ot not
forkit
forkit at gmail.com
Mon Jan 17 03:58:00 UTC 2022
On Monday, 17 January 2022 at 03:11:50 UTC, Steven Schveighoffer
wrote:
>
> The profile=gc appears to only show GC allocations that the
> *compiler* initiates (i.e. via `new`, array operations (like
> appending) or closure allocations). It does not detect that the
> functions that actually allocate memory themselves (such as
> `core.memory.GC.malloc`) are GC allocations. This actually does
> not care whether a function might or might not allocate, but
> records when it actually does allocate.
>
> -Steve
yes, that seems to be the case:
// -----
module test;
import std;
@safe void main()
{
int[][] mArr2;
mArr2 ~= iota(1, 9).chunks(2).map!array.array; //
profilegc.log created ok.
}
// ----
More information about the Digitalmars-d-learn
mailing list