[LLVMdev] LLVM asserts
    Jim Grosbach 
    grosbach at apple.com
       
    Wed Aug 19 09:30:16 PDT 2009
    
    
  
On Aug 19, 2009, at 9:02 AM, Kenneth Uildriks wrote:
> How do you get LLVM methods to return or throw an error to the
> caller's code rather than aborting the process?  I'd like my compiler
> to be able to print diagnostic messages, including language source
> lines, whenever LLVM reports a problem.
Do you mean things like assert() and abort() calls? Those are abnormal  
situations and internal compiler errors, not indicators of a problem  
in the user's source. If you really want to catch them and do  
something, you could install a signal handler for SIGABRT, I suppose,  
and do whatever you want there.
Regards,
   Jim
    
    
More information about the llvm-dev
mailing list