glfw: Eliminate InvalidEnum
This commit is contained in:
parent
a465d2e021
commit
fb0c695bd1
5 changed files with 31 additions and 64 deletions
|
|
@ -243,7 +243,6 @@ pub const Key = enum(c_int) {
|
|||
internal_debug.assertInitialized();
|
||||
const scancode = cc.glfwGetKeyScancode(@enumToInt(self));
|
||||
getError() catch |err| return switch (err) {
|
||||
Error.InvalidEnum => unreachable, // Should be unreachable for any valid 'Key' value.
|
||||
Error.PlatformError => err,
|
||||
else => unreachable,
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue