diff options
-rw-r--r-- | include/clang-c/Index.h | 4 | ||||
-rw-r--r-- | tools/libclang/CXCursor.cpp | 8 | ||||
-rw-r--r-- | tools/libclang/libclang.exports | 1 |
3 files changed, 10 insertions, 3 deletions
diff --git a/include/clang-c/Index.h b/include/clang-c/Index.h index 6bd0286d6e..fbeb14d365 100644 --- a/include/clang-c/Index.h +++ b/include/clang-c/Index.h @@ -1557,9 +1557,7 @@ CINDEX_LINKAGE unsigned clang_equalCursors(CXCursor, CXCursor); /** * \brief Returns non-zero if \arg cursor is null. */ -static inline int clang_Cursor_isNull(CXCursor cursor) { - return clang_equalCursors(cursor, clang_getNullCursor()); -} +int clang_Cursor_isNull(CXCursor); /** * \brief Compute a hash value for the given cursor. diff --git a/tools/libclang/CXCursor.cpp b/tools/libclang/CXCursor.cpp index c0e038467f..6205c0a5da 100644 --- a/tools/libclang/CXCursor.cpp +++ b/tools/libclang/CXCursor.cpp @@ -522,10 +522,18 @@ bool cxcursor::isFirstInDeclGroup(CXCursor C) { // libclang CXCursor APIs //===----------------------------------------------------------------------===// +extern "C" { + +int clang_Cursor_isNull(CXCursor cursor) { + return clang_equalCursors(cursor, clang_getNullCursor()); +} + CXTranslationUnit clang_Cursor_getTranslationUnit(CXCursor cursor) { return getCursorTU(cursor); } +} // end: extern "C" + //===----------------------------------------------------------------------===// // CXCursorSet. //===----------------------------------------------------------------------===// diff --git a/tools/libclang/libclang.exports b/tools/libclang/libclang.exports index 71cd261438..019110a5e7 100644 --- a/tools/libclang/libclang.exports +++ b/tools/libclang/libclang.exports @@ -21,6 +21,7 @@ clang_createIndex clang_createTranslationUnit clang_createTranslationUnitFromSourceFile clang_Cursor_getTranslationUnit +clang_Cursor_isNull clang_defaultCodeCompleteOptions clang_defaultDiagnosticDisplayOptions clang_defaultEditingTranslationUnitOptions |