From bc969d22db11323e7339ca1c462a8b2a2a43a8d2 Mon Sep 17 00:00:00 2001 From: Jack Stouffer Date: Fri, 16 Sep 2016 11:06:13 +0100 Subject: [PATCH] Remove package several global imports from std.outbuffer --- std/outbuffer.d | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/std/outbuffer.d b/std/outbuffer.d index e5ba6a485..4d8c7e37b 100644 --- a/std/outbuffer.d +++ b/std/outbuffer.d @@ -10,15 +10,7 @@ Serialize data to $(D ubyte) arrays. */ module std.outbuffer; -private -{ - import core.memory; - import core.stdc.stdarg; - import core.stdc.stdio; - import core.stdc.stdlib; - import std.algorithm; - import std.string; -} +import core.stdc.stdarg; // : va_list; /********************************************* * OutBuffer provides a way to build up an array of bytes out @@ -257,6 +249,10 @@ class OutBuffer void vprintf(string format, va_list args) @trusted nothrow { + import std.string : toStringz; + import core.stdc.stdio : vsnprintf; + import core.stdc.stdlib : alloca; + version (unittest) char[3] buffer = void; // trigger reallocation else @@ -415,6 +411,7 @@ class OutBuffer @safe unittest { + import std.string : cmp; //printf("Starting OutBuffer test\n"); OutBuffer buf = new OutBuffer();