exceptions vs error codes
Walter Bright via Digitalmars-d
digitalmars-d at puremagic.com
Mon Jul 11 21:53:51 PDT 2016
On 7/11/2016 9:10 PM, Chris Wright wrote:
> On Mon, 11 Jul 2016 06:13:00 -0700, Walter Bright wrote:
>
>> On 7/9/2016 8:02 PM, Superstar64 wrote:
>>> Would it be possible and a good idea to have a language feature that
>>> allows some exceptions to use error code code generation.
>>
>> If you want to return an error code, return an error code. No language
>> feature is required.
>
> I think the intent is to tell the compiler: the error case is very
> common, so make that case faster at the expense of the happy path.
I really have no idea what the benefit is of telling the compiler that.
More information about the Digitalmars-d
mailing list