From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 18215 invoked by alias); 25 Apr 2009 11:03:51 -0000 Received: (qmail 14903 invoked by uid 48); 25 Apr 2009 11:03:31 -0000 Date: Sat, 25 Apr 2009 11:03:00 -0000 Message-ID: <20090425110331.14902.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug libstdc++/39880] Specialisation is_error_code_enum should not exist In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "chris_kohlhoff at internet-mail dot org" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2009-04/txt/msg02293.txt.bz2 ------- Comment #3 from chris_kohlhoff at internet-mail dot org 2009-04-25 11:03 ------- It's the intended behaviour that the conversion constructor and assignment operator be disabled. That is, the std::errc type should not be implicitly convertible to error_code, only to error_condition. If users want to create an error_code from a std::errc then they can use make_error_code(): error_code ec = make_error_code(errc::not_supported); In a nutshell, ErrorConditionEnum concept means implicitly convertible to error_condition but no implicit conversion to error_code. Likewise ErrorCodeEnum means implicitly convertible to error_code but not to error_condition. (N.B. bugs 39881 and 39882 also have to be fixed to make this conversion work.) -- chris_kohlhoff at internet-mail dot org changed: What |Removed |Added ---------------------------------------------------------------------------- Status|WAITING |NEW http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39880