-
Notifications
You must be signed in to change notification settings - Fork 178
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
Use std::error_code instead of exceptions #43
Comments
I'm sorry, but it would break the standard. As an example see 'Exceptions' for std::filesystem::absolute at Error handling ist described in [fs.err.report] (30.10.7 in C++17):
So a std::filesystem implementation without exceptions would break the specification. And as stated in the readme, I am open for changes but none breaking compatibility with code expecting a filesystem implementation to throw. So while the standard says nothing about disabling exceptions and handling disabled exceptions inside their standard library is a compiler implementation specific issue, I could go down the route to try to test if exceptions are enabled or introduce a new option to disable exceptions and and simply call If I get a clean PR that uses |
My bad! |
Is your feature request related to a problem? Please describe.
I'm currently trying to use this library in a codebase that should be compiled without exceptions.
Describe the solution you'd like
Replace throwing exceptions with std::error_code. Since exceptions seem to be only used in the detail:: namespace this should not break compatibility with the std:: implementation.
Describe alternatives you've considered
Write my own?
The text was updated successfully, but these errors were encountered: