On Mar 2, 2013, at 10:42 AM, Rafael Espíndola <[email protected]>
wrote:
>> libclang from the beginning has chosen to avoid crashing the process, see
>> llvm::CrashRecoveryContext.
>
> /// This class implements support for running operations in a safe context so
> /// that crashes (memory errors, stack overflow, assertion violations) can be
> /// detected and control restored to the crashing thread. Crash detection is
> /// purely "best effort", the exact set of failures which can be recovered
> from
> /// is platform dependent.
>
> This looks like exactly what we need. Instead of doing
>
> if (!foo) {
> assert(0...);
> }
>
> You can cause a "crash" and let the crash recovery mechanism handle it.
Doing that will still ignore the crash, but this time with a recovery mechanism
that, while good intentioned (not bringing down the process) it's disruptive
and should really not be triggered intentionally.
>
> Cheers,
> Rafael
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits