4 ms·
There is a big problem AFAIK with the "effective type" (C99) or "dynamic type" (C++) rules. If you are writing your own allocator (malloc() or some arena alloc
by haberman 10y ago
There is a big problem AFAIK with the "effective type" (C99) or "dynamic type" (C++) rules. If you are writing your own allocator (malloc() or some arena allocator), there is no legal way AFAIK to seed it with global/stack memory. Your global/stack memory has a declared type of char[], and there is no way to convert this into the type-less kind of memory you need to get back from malloc().