r209477 - Use error_code::success() instead of make_error_code(llvm::errc::success).

Alexander Kornienko alexfh at google.com
Fri May 23 00:11:14 PDT 2014


On 23 May 2014 09:04, "Tobias Grosser" <tobias at grosser.es> wrote:
>
> On 23/05/2014 09:02, Alexander Kornienko wrote:
>>
>> Slightly shorter and more expensive, I would say.
>
>
> It is just a minor change, but more expensive? That does not sound
beneficial?

s/expensive/expressive/ (Android keyboard...)

>
> Also, you missed this question:
>
>
>>>         }
>>>>
>>>>      }
>>>>      return llvm::make_error_code(llvm::errc::not_supported);
>>>>
>>>
>>> Should this line be changed too?

AFAIK, there's no shortcut for this error code. Success code is special, it
has a dedicated static member for simplicity and expressiveness.

>
>
> Cheers,
> Tobias
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20140523/9e9d5485/attachment.html>


More information about the cfe-commits mailing list