[Doc parsing]: Add available and deprecated attribute info
to XML output. // rdar://12378879


git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@165039 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/tools/libclang/CXComment.cpp b/tools/libclang/CXComment.cpp
index 1e0679f..a0a5512 100644
--- a/tools/libclang/CXComment.cpp
+++ b/tools/libclang/CXComment.cpp
@@ -1175,8 +1175,13 @@
     const AttrVec &Attrs = DI->ThisDecl->getAttrs();
     for (unsigned i = 0, e = Attrs.size(); i != e; i++) {
       const AvailabilityAttr *AA = dyn_cast<AvailabilityAttr>(Attrs[i]);
-      if (!AA)
+      if (!AA) {
+        if (isa<DeprecatedAttr>(Attrs[i]))
+          Result << "<Deprecated>true</Deprecated>";
+        else if (isa<UnavailableAttr>(Attrs[i]))
+          Result << "<Unavailable>true</Unavailable>";
         continue;
+      }
 
       // 'availability' attribute.
       Result << "<Availability";