mirror of
https://github.com/ziglang/zig.git
synced 2026-02-12 20:37:54 +00:00
Update doc/langref.html.in
Co-authored-by: Joachim Schmidt <joachim.schmidt557@outlook.com>
This commit is contained in:
parent
5afa7f2545
commit
656b640e79
@ -312,7 +312,7 @@ pub fn main() !void {
|
||||
<p>
|
||||
In Zig, the standard output stream's <code>print</code> function is allowed to fail because
|
||||
it is actually a function defined for a generic output stream. Consider a generic output stream that
|
||||
represents writing data to a file and the disk is full; a write to the file will fail. However,
|
||||
represents writing data to a file. When the disk is full, a write to the file will fail. However,
|
||||
we typically do not expect writing text to the standard output stream to fail. To avoid having
|
||||
to handle the failure case of printing to a standard output, you can use alternate functions: the
|
||||
<code>std.log</code> function for proper logging or the <code>std.debug.print</code> function.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user