glfw: amend and update various TODOs pertaining to force-init changes

This commit is contained in:
InKryption 2021-11-22 13:53:40 +01:00 committed by Stephen Gutekanst
parent da392d89a7
commit d9e2505b59
7 changed files with 41 additions and 40 deletions

View file

@ -84,7 +84,7 @@ pub inline fn createStandard(shape: Shape) Error!Cursor {
internal_debug.assertInitialized();
const cursor = c.glfwCreateStandardCursor(@intCast(c_int, @enumToInt(shape)));
getError() catch |err| return switch (err) {
// TODO: should be impossible given that only the values in 'Shape' are available, unless the user explicitly gives us a bad value via casting
// should be unreachable given that only the values in 'Shape' are available, unless the user explicitly gives us a bad value via casting
Error.InvalidEnum => unreachable,
Error.PlatformError => err,
else => unreachable,
@ -111,7 +111,7 @@ pub inline fn destroy(self: Cursor) void {
internal_debug.assertInitialized();
c.glfwDestroyCursor(self.ptr);
getError() catch |err| return switch (err) {
Error.PlatformError => {}, // TODO: See 'todo' in 'internal_debug.zig' concerning 'PlatformError'
Error.PlatformError => std.log.debug("{}: was unable to destroy Cursor.\n", .{ err }),
else => unreachable,
};
}