On Tuesday, 4 June 2013 at 12:20:24 UTC, bearophile wrote: > David: > >> mykeys.map!(x => x.dup.toStringz).array > > Is toStringz already dup-ping the buffer? Not necessarily. IIRC, if the string already has a null terminator then it just returns the string ptr. Only dups if it needs to.