Zig 0.17.0-dev (Split by item)

This is an example of documentation generated by ZigDoc, an alternative to Zig's built-in Auto Doc feature. See also examples in other modes/formats. The project being documented here (as the example) is the Zig library itself.

beginWriteRaw

An alternative to calling write that allows you to write directly to the .writer field, e.g. with .writer.writeAll(). Call beginWriteRaw(), then write a complete value (including any quotes if necessary) directly to the .writer field, then call endWriteRaw(). This can be useful for streaming very long strings into the output without needing it all buffered in memory.

Stringify.beginWriteRaw
pub fn beginWriteRaw(self: *Stringify) !void

File

lib/std/json/Stringify.zig:258

Code

pub fn beginWriteRaw(self: *Stringify) !void {
    if (build_mode_has_safety) {
        assert(self.raw_streaming_mode == .none);
        self.raw_streaming_mode = .value;
    }
    try self.valueStart();
}