If you need to represent error codes specific to your domain, you can use the std::error_code customization mechanism. A custom implementation has three parts: - an enum representing the domain-specific error codes - a corresponding error category that translates the error codes into text descriptions - a mapping from the enum type to the category type Compiler Explorer link: https://lnkd.in/ePJMCKZx #cpp #cplusplus #coding #programming #dailybiteofcpp
Cool! Are there any reason why you not done a static_cast on the condition variable to be able to use the TransactionError enum in the switch-case?
cool, didnt know you have std functions for this. always implemented by my self
A version that works with C++17 https://compiler-explorer.com/z/xKP9E46Wj