View source code
Display the source code in std/experimental/allocator/building_blocks/segregator.d from which this page was generated on github.
Report a bug
If you spot a problem with this page, click here to create a Bugzilla issue.
Improve this page
Quickly fork, edit online, and submit a pull request for this page. Requires a signed-in GitHub account. This works well for small changes. If you'd like to make larger changes you may want to consider using local clone.

Module std.experimental.allocator.building_blocks.segregator


Segregator Dispatches allocations (and deallocations) between two allocators (SmallAllocator and LargeAllocator) depending on the size allocated, as follows. All allocations smaller than or equal to threshold will be dispatched to SmallAllocator. The others will go to LargeAllocator.


Segregator Segregator!(Args[cutPoint],.Segregator!(Args[0..cutPoint],Args[cutPoint+1]),.Segregator!(Args[cutPoint+2..__dollar])) A Segregator with more than three arguments expands to a composition of elemental Segregators, as illustrated by the following example: