|Types and Enumerations|
|typedef void(*||LLVMFatalErrorHandler )(const char *Reason)|
|void||LLVMInitializeCore (LLVMPassRegistryRef R)|
|char *||LLVMCreateMessage (const char *Message)|
|void||LLVMDisposeMessage (char *Message)|
|void||LLVMInstallFatalErrorHandler (LLVMFatalErrorHandler Handler)|
This modules provide an interface to libLLVMCore, which implements the LLVM intermediate representation as well as other related types and utilities.
LLVM uses a polymorphic type hierarchy which C cannot represent, therefore parameters must be passed as base types. Despite the declared types, most of the functions provided operate only on branches of the type hierarchy. The declared parameter names are descriptive and specify which type is required. Additionally, each type hierarchy is documented along with the functions that operate upon it. For more detail, refer to LLVM's C++ code. If in doubt, refer to Core.cpp, which performs parameter downcasts in the form unwrap<RequiredType>(Param).
Many exotic languages can interoperate with C code but have a harder time with C++ due to name mangling. So in addition to C, this interface enables tools written in such languages.
Install a fatal error handler. By default, if LLVM detects a fatal error, it will call exit(1). This may not be appropriate in many contexts. For example, doing exit(1) will bypass many crash reporting/tracing system tools. This function allows you to install a callback that will be invoked prior to the call to exit(1).