zipper icon indicating copy to clipboard operation
zipper copied to clipboard

Add basic error_code handeling to unzipper

Open Togtja opened this issue 4 years ago • 5 comments

Here is an example that should help with #88 I do not remove exeption to keep compatibility with the old API, similar to what can be found in std::filesystem

Togtja avatar May 10 '21 14:05 Togtja

@Togtja Is this still in draft ? Do you want to be merged in dev branch ?

Lecrapouille avatar Jun 19 '21 14:06 Lecrapouille

I think there are more places where the an exception is thrown where I have not gotten to. So as is now it will add replacements for exceptions for the Unzipper class, but I have not done this for other places (Zipper class). I might get some time to look at it at some point, but atm I am quite busy, so anybody feel free to continue, doing something similar to the Zipper class.

Togtja avatar Jun 21 '21 11:06 Togtja

@Togtja: Have you any progress/news about your PR?

Neustradamus avatar Mar 06 '22 05:03 Neustradamus

@Togtja: Have you any progress/news about your PR?

@Neustradamus I haven't worked on it, a mixture of forgetting and time. I might get to look at it, but no promises

Togtja avatar Mar 06 '22 14:03 Togtja

@Lecrapouille @Neustradamus I have added the possibility to use std::error_code for all calls that used to throw when failing. I have not tested this thoroughly. So feel free to write some simple programs that both trigger and not trigger exceptions, using both std::error_code and not.

(Edit: Also forgot that this pull request will be a pain to merge, but once it is tested, I'll get on that)

Togtja avatar Jun 24 '22 13:06 Togtja

Closing since I'm currently working on it. See https://github.com/sebastiandev/zipper/issues/88

Lecrapouille avatar Sep 07 '22 21:09 Lecrapouille