[patch] Use a more idiomatic bool operator in ErrorOr

Rafael EspĂ­ndola rafael.espindola at gmail.com
Thu Jan 16 14:45:55 PST 2014


> Do we have types with any such dangerous duplicate conversions? I'd say
> that's likely bad design even in a world with explicit bool conversion & I'd
> treat those as code/design bugs and on that basis I'd still prefer to nuke
> safe bools and use LLVM_EXPLICIT entirely.

Same here. We already use LLVM_EXPLICIT in OwningPtr.h. IMHO MSVC 2012
is not a big enough reason to avoid it. We have enough compilers that
do support it to avoid bad bool conversions showing up in the
codebase.

Cheers,
Rafael



More information about the llvm-commits mailing list