4 ms·
I'm relatively new to C++ and I found absl::StatusOr<T> and its helper macros to be extraordinarily pleasant.
by jkaptur 5y ago
I'm relatively new to C++ and I found absl::StatusOr<T> and its helper macros to be extraordinarily pleasant.
- kirbyfan64sos 5y agoIt has helper macros now? I liked StatusOr but had to write my own helper macros for it at the time.
- trimbo 5y agoEx: https://google.github.io/or-tools/cpp/status__macros_8h_source.html https://google.github.io/or-tools/cpp/status__macros_8h_sour...
- alskdjflaskjdhf 5y agoYep, these are used extensively at Google (which is where the abseil library came from, and which is famously anti-cpp-exceptions) and they work very well. If I somehow found myself writing a new C++ project I'd probably reach for abseil (and some of the other parts of the Google toolchain: GoogleTest for testing, bazel for builds).