Add clang_getNullCursor() and clang_equalCursors() (the latter for comparing cursors).


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89131 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/tools/CIndex/CIndex.cpp b/tools/CIndex/CIndex.cpp
index 2e0eafe..ebdba29 100644
--- a/tools/CIndex/CIndex.cpp
+++ b/tools/CIndex/CIndex.cpp
@@ -875,6 +875,18 @@
   return C;
 }
 
+CXCursor clang_getNullCursor(void) {
+  CXCursor C;
+  C.kind = CXCursor_InvalidFile;
+  C.decl = NULL;
+  C.stmt = NULL;
+  return C;
+}
+
+unsigned clang_equalCursors(CXCursor X, CXCursor Y) {
+  return X.kind == Y.kind && X.decl == Y.decl && X.stmt == Y.stmt;
+}
+  
 CXCursor clang_getCursorFromDecl(CXDecl AnonDecl)
 {
   assert(AnonDecl && "Passed null CXDecl");