@@ -21,7 +21,7 @@ struct AffixAllocator(Allocator, Prefix, Suffix = void)
2121{
2222 import std.algorithm.comparison : min;
2323 import std.conv : emplace;
24- import std.experimental.allocator : IAllocator , theAllocator;
24+ import std.experimental.allocator : RCIAllocator , theAllocator;
2525 import std.experimental.allocator.common : stateSize, forwardToMember,
2626 roundUpToMultipleOf, alignedAt, alignDownTo, roundUpToMultipleOf,
2727 hasStaticallyKnownAlignment;
@@ -66,11 +66,11 @@ struct AffixAllocator(Allocator, Prefix, Suffix = void)
6666 static if (stateSize! Allocator)
6767 {
6868 Allocator _parent;
69- static if (is (Allocator == IAllocator ))
69+ static if (is (Allocator == RCIAllocator ))
7070 {
7171 Allocator parent ()
7272 {
73- if (_parent is null ) _parent = theAllocator;
73+ if (_parent.isNull ) _parent = theAllocator;
7474 assert (alignment <= _parent.alignment);
7575 return _parent;
7676 }
@@ -373,18 +373,18 @@ struct AffixAllocator(Allocator, Prefix, Suffix = void)
373373@system unittest
374374{
375375 import std.experimental.allocator.gc_allocator : GCAllocator;
376- import std.experimental.allocator : theAllocator, IAllocator ;
376+ import std.experimental.allocator : theAllocator, RCIAllocator ;
377377
378378 // One word before and after each allocation.
379- auto A = AffixAllocator! (IAllocator , size_t , size_t )(theAllocator);
379+ auto A = AffixAllocator! (RCIAllocator , size_t , size_t )(theAllocator);
380380 auto a = A.allocate(11 );
381381 A.prefix(a) = 0xCAFE_BABE;
382382 A.suffix(a) = 0xDEAD_BEEF;
383383 assert (A.prefix(a) == 0xCAFE_BABE
384384 && A.suffix(a) == 0xDEAD_BEEF);
385385
386386 // One word before and after each allocation.
387- auto B = AffixAllocator! (IAllocator , size_t , size_t )();
387+ auto B = AffixAllocator! (RCIAllocator , size_t , size_t )();
388388 auto b = B.allocate(11 );
389389 B.prefix(b) = 0xCAFE_BABE;
390390 B.suffix(b) = 0xDEAD_BEEF;
0 commit comments