[patch] Finishing touch for the std::error_code transition
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
> > 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...
More information about the llvm-commits