put

Puts a variadic list of values into an output range sink.

version(WithPrinterPlugin)
package @safe
void
put
(
Flag!"colours" colours = No.colours
Sink
Args...
)
(
auto ref Sink sink
,
Args args
)
if (
isOutputRange!(Sink, char[])
)

Parameters

colours

Whether or not to accept terminal colour tokens and use them to tint the text.

sink Sink

Output range to sink items into.

args Args

Variadic list of things to put into the output range.

Examples

import std.array : Appender;

Appender!(char[]) sink;

.put(sink, "abc", long.min, "def", 456, true);
assert((sink.data == "abc-9223372036854775808def456true"), sink.data);

Meta