clang API Documentation

CXErrorCode.h
Go to the documentation of this file.
00001 /*===-- clang-c/CXErrorCode.h - C Index Error Codes  --------------*- C -*-===*\
00002 |*                                                                            *|
00003 |*                     The LLVM Compiler Infrastructure                       *|
00004 |*                                                                            *|
00005 |* This file is distributed under the University of Illinois Open Source      *|
00006 |* License. See LICENSE.TXT for details.                                      *|
00007 |*                                                                            *|
00008 |*===----------------------------------------------------------------------===*|
00009 |*                                                                            *|
00010 |* This header provides the CXErrorCode enumerators.                          *|
00011 |*                                                                            *|
00012 \*===----------------------------------------------------------------------===*/
00013 
00014 #ifndef LLVM_CLANG_C_CXERRORCODE_H
00015 #define LLVM_CLANG_C_CXERRORCODE_H
00016 
00017 #include "clang-c/Platform.h"
00018 
00019 #ifdef __cplusplus
00020 extern "C" {
00021 #endif
00022 
00023 /**
00024  * \brief Error codes returned by libclang routines.
00025  *
00026  * Zero (\c CXError_Success) is the only error code indicating success.  Other
00027  * error codes, including not yet assigned non-zero values, indicate errors.
00028  */
00029 enum CXErrorCode {
00030   /**
00031    * \brief No error.
00032    */
00033   CXError_Success = 0,
00034 
00035   /**
00036    * \brief A generic error code, no further details are available.
00037    *
00038    * Errors of this kind can get their own specific error codes in future
00039    * libclang versions.
00040    */
00041   CXError_Failure = 1,
00042 
00043   /**
00044    * \brief libclang crashed while performing the requested operation.
00045    */
00046   CXError_Crashed = 2,
00047 
00048   /**
00049    * \brief The function detected that the arguments violate the function
00050    * contract.
00051    */
00052   CXError_InvalidArguments = 3,
00053 
00054   /**
00055    * \brief An AST deserialization error has occurred.
00056    */
00057   CXError_ASTReadError = 4
00058 };
00059 
00060 #ifdef __cplusplus
00061 }
00062 #endif
00063 #endif
00064