Returns a unique key for the passed associative array. Reserves the key by assigning it a value.
Zeroes out the contents of an Appender.
string[int] aa; immutable key = aa.uniqueKey; assert(key > 0); assert(key in aa); assert(aa[key] == string.init); Appender!(int]) sink; sink.put(1); sink.put(2); sink.put(3); sink.zero(clear: false); assert(sink.data == [ 0, 0, 0 ]); sink.zero(clear: false, 42); assert(sink.data == [ 42, 42, 42 ]); sink.zero(); //(clear: true); assert(!sink.data.length);
Simple array utilities.