-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Consider design of error type(s) #73
Comments
UnsupportedDisplayPlatform and UnsupportedWindowPlatform arguably don't need human readable name fields as the |
I think we should only really consider user-caused errors, plus a backend error. So we should have things like integer overflow, display mismatch, and calling out of sequence.
We should use the same for simplicity's sake, since they all need backend errors anyhow.
I would support this. Also, do we publicly expose the underlying |
It should at least be a Matching on the enum is useful if the caller wants to handle specific errors. Are there errors a caller is likely to want to handle? Loss of connection to the display server might be something one would want to handle. There's been some work in Wayland in allowing applications to reconnect if a compositor crashes and restarts. For backend related things it's only useful to the extent winit exposes the same kind of errors though (assuming softbuffer is used with winit). I haven't actually looked into how winit's error handling work's too much. |
x11
code currently has aswbuf_err
helper method. Any helpers like this should be inerror.rs
and used in other backends where it's useful.The text was updated successfully, but these errors were encountered: