Page MenuHomePhabricator

[Support] Require llvm::Error passed to formatv() to be wrapped in fmt_consume()

Authored by sammccall on Jul 11 2018, 1:20 AM.



Someone must be responsible for handling an Error. When formatv takes
ownership of an Error, the formatv_object destructor must take care of this.

Passing an error by value to formatv() is not considered explicit enough to mark
the error as handled (see D49013), so we require callers to use a format adapter
to confirm this intent.

Diff Detail