glfw: document why unreachable is valid

This commit is contained in:
Lee Cannon 2022-02-09 21:45:27 +00:00 committed by Stephen Gutekanst
parent 0cdac6c68a
commit bc8ce57e53
8 changed files with 36 additions and 1 deletions

View file

@ -54,6 +54,7 @@ pub inline fn getClipboardString() error{ FormatUnavailable, PlatformError }![:0
Error.FormatUnavailable, Error.PlatformError => |e| e,
else => unreachable,
};
// `glfwGetClipboardString` returns `null` only for errors
unreachable;
}