[patch] Finishing touch for the std::error_code transition

Chandler Carruth chandlerc at google.com
Fri Jun 13 09:54:47 PDT 2014

On Fri, Jun 13, 2014 at 5:50 PM, Rafael EspĂ­ndola <
rafael.espindola at gmail.com> wrote:

> On 13 June 2014 12:32, Chandler Carruth <chandlerc at google.com> wrote:
> > This is a pretty nifty hack. =D
> >
> > One question, can we really use std::generic_category for all of these
> > codes? The actual standard library splits betwene generic_category and
> > system_category IIRC. I'm wondering if we have to implement our own
> category
> > that manages extracting the relevant bits of information under the hood.
> >
> > Thoughts?
> I think we can.
> Using std::make_error_code(std::errc::..) creates an error_code with
> the generic category. Since we use the same values, this is just
> another code path for creating the same error_code.

It means that there are std::errc::... values which we will hand to the
generic_category virtual methods which would never get handed to them in
the standard library because in the standard library these values are
always paired with system_category.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140613/5125ced3/attachment.html>

More information about the llvm-commits mailing list