On Saturday, 22 May 2021 at 03:07:10 UTC, cc wrote:
Ahh, in that case it would appear formattedWrite isn't @safe at all. Looks like you have to stick with put()?
```d
@safe void toString(W)(ref W writer) if (isOutputRange!(W, char)) {
        //writer.formattedWrite!("FOO:%s", x); // fails
        import std.conv;
        put(writer, "FOO:");
        put(writer, x.to!string);
}
```

Oops, disregard this.  I had an error in my imports.😓
It does in fact work in @safe.

Reply via email to