glfw: Revert error denormalization

This commit is contained in:
InKryption 2021-11-22 00:34:38 +01:00 committed by Stephen Gutekanst
parent 44fee8f1f1
commit ef7ada052c
10 changed files with 146 additions and 146 deletions

View file

@ -53,12 +53,12 @@ pub inline fn getTime() f64 {
/// base time is not atomic, so it needs to be externally synchronized with calls to glfw.getTime.
///
/// see also: time
pub inline fn setTime(time: f64) error{ InvalidValue }!void {
pub inline fn setTime(time: f64) Error!void {
internal_debug.assertInitialized();
c.glfwSetTime(time);
getError() catch |err| return switch (err) {
// TODO: Consider whether to use GLFW error handling, or assert that 'time' is a valid value
Error.InvalidValue => @errSetCast(error{ InvalidValue }, err),
Error.InvalidValue => err,
else => unreachable,
};
}