You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The following code triggers an assert in core.lifetime.emplace due to the allocated pointer for S not being aligned to __traits(classInstanceAlignment, S):
classS{}
voidmain(){
importstd.experimental.allocator: make;
importstd.experimental.allocator.building_blocks: BitmappedBlock;
auto alloc = BitmappedBlock!(17,1)(newubyte[](64));
auto a = make!S(alloc);
auto b = make!S(alloc); //core.exception.AssertError@/dlang/ldc-1.41.0/bin/../import/core/lifetime.d(207): chunk is not aligned.
}
BitmappedBlock implements alignedAllocate, which make could use to trivially avoid this issue.