[PATCH] D33960: ErrorHandling: report_fatal_error: call abort() instead of exit()
Matthias Braun via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Sep 6 16:54:01 PDT 2017
MatzeB added a comment.
In https://reviews.llvm.org/D33960#862837, @dblaikie wrote:
> Hrm.
>
> Seeing that closing stderr test - I wouldn't mind some more eyes on this change. There's a fair amount of report_fatal_error usage in LLVM tools that probably aren't abort-worthy? But I'm not sure. But maybe that's OK (I mean they're mostly internal tools anyway)
Many of the `report_fatal_error`s in LLVM are abort worthy in my opinion.
There are indeed some like the bitcode parsing failures that really should rather use one of the other mechanisms available such as passing an `Error()` value to the caller or at least using LLVMContext::diagnose(). I hope this won't stop this patch, in fact it may be nice that this patch makes these things more obvious and hopefully brings people to use more apropriate APIs there.
Repository:
rL LLVM
https://reviews.llvm.org/D33960
More information about the llvm-commits
mailing list