https://issues.dlang.org/show_bug.cgi?id=18854
Vladimir Panteleev <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |[email protected] --- Comment #1 from Vladimir Panteleev <[email protected]> --- StatsCollector.deallocate is "Defined whether or not `Allocator.deallocate` is defined". I'm really not sure this was a great idea, because it opens the door to silent memory leaks, and breaks introspection of any allocators that might use this information to switch to a different method of tracking allocations. There's two ways to fix this: - Make deallocate always return false (and not count allocations) when ParentAllocator doesn't support deallocation. - Don't define deallocate if the parent allocator doesn't. I feel like the first one would defeat the point of always having a deallocate method. Still, the way things are now is obviously broken. Andrei, any thoughts? --
