summaryrefslogtreecommitdiffstats
path: root/clang/include/clang-c
diff options
context:
space:
mode:
authorDmitri Gribenko <gribozavr@gmail.com>2012-08-07 17:54:38 +0000
committerDmitri Gribenko <gribozavr@gmail.com>2012-08-07 17:54:38 +0000
commit740c0fbe0e025c4ae3ac4e08917816b96b8dbe32 (patch)
treefd44d0115efe8ba4daff6ee6ef03bb6dcdd9a53b /clang/include/clang-c
parentaf9aec0cd7a1339785423607b5b36ddca7d58d94 (diff)
downloadbcm5719-llvm-740c0fbe0e025c4ae3ac4e08917816b96b8dbe32.tar.gz
bcm5719-llvm-740c0fbe0e025c4ae3ac4e08917816b96b8dbe32.zip
libclang API for comment-to-xml conversion.
The implementation also includes a Relax NG schema and tests for the schema itself. The schema is used in c-index-test to verify that XML documents we produce are valid. In order to do the validation, we add an optional libxml2 dependency for c-index-test. Credits for CMake part go to Doug Gregor. Credits for Autoconf part go to Eric Christopher. Thanks! llvm-svn: 161431
Diffstat (limited to 'clang/include/clang-c')
-rw-r--r--clang/include/clang-c/Index.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/clang/include/clang-c/Index.h b/clang/include/clang-c/Index.h
index c725bcfad1c..edd3cbb4a7f 100644
--- a/clang/include/clang-c/Index.h
+++ b/clang/include/clang-c/Index.h
@@ -3687,6 +3687,21 @@ CINDEX_LINKAGE CXString clang_HTMLTagComment_getAsString(CXComment Comment);
CINDEX_LINKAGE CXString clang_FullComment_getAsHTML(CXComment Comment);
/**
+ * \brief Convert a given full parsed comment to an XML document.
+ *
+ * A Relax NG schema for the XML can be found in comment-xml-schema.rng file
+ * inside clang source tree.
+ *
+ * \param TU the translation unit \c Comment belongs to.
+ *
+ * \param Comment a \c CXComment_FullComment AST node.
+ *
+ * \returns string containing an XML document.
+ */
+CINDEX_LINKAGE CXString clang_FullComment_getAsXML(CXTranslationUnit TU,
+ CXComment Comment);
+
+/**
* @}
*/
OpenPOWER on IntegriCloud