Use std.experimental.allocator and remove the custom allocator module.
This commit is contained in:
parent
55a06c30f3
commit
f74c30a9f3
9 changed files with 278 additions and 915 deletions
|
@ -10,7 +10,7 @@ module vibe.internal.string;
|
|||
public import std.string;
|
||||
|
||||
import vibe.internal.array;
|
||||
import vibe.internal.memory;
|
||||
import vibe.internal.allocator;
|
||||
|
||||
import std.algorithm;
|
||||
import std.array;
|
||||
|
@ -186,7 +186,7 @@ sizediff_t matchBracket(string str, bool nested = true)
|
|||
}
|
||||
|
||||
/// Same as std.string.format, just using an allocator.
|
||||
string formatAlloc(ARGS...)(Allocator alloc, string fmt, ARGS args)
|
||||
string formatAlloc(ARGS...)(IAllocator alloc, string fmt, ARGS args)
|
||||
{
|
||||
auto app = AllocAppender!string(alloc);
|
||||
formattedWrite(&app, fmt, args);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue