upvote
Why would you say something so controversial yet so brave?
reply
Not that I like go at all but because of it my C++ is starting to look like it as I am returning tuples of [result, error].

I try to avoid exceptions, is there any better ways? (Variant looks a bit more complicated but could be a totally OK alternative)

reply
C++23 introduces std::expected, which is a simpler alternative to std::variant designed specifically for the result-or-error use case. You still don't get pattern matching, but Go-style tuples don't give you that either.
reply
its simple and it works
reply
Personally I feel go has many issues and is ugly as hell but the error handling is really the least of my worries.
reply