coreaudio-rs
coreaudio-rs copied to clipboard
Stop using monolithic `Error` enum and use error types specific to each part of the API
Although convenient for us, the biggest problem with using the same Error type everywhere is that rather than only representing the possible errors that may occur for each particular part of the API, it enumerates all errors, making it difficult for the user to determine what errors might actually occur when using certain parts of the API. Each method/function should have it's own error type which only enumerates the actual possible errors. This will be tricky as the coreaudio documentation rarely enumerates the possible errors that might actually occur, and in most places just returns a generic error code.