Add a libclang .rst file with some code examples, going over the most important types and functions of libclang.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Thank you for adding this new documentation! In general, this is looking fantastic. Given how closely tied the C indexing APIs are with the rest of the compiler internals, I think it'd be helpful to add links to https://clang.llvm.org/docs/InternalsManual.html to various parts of this documentation to link the user back to more details. e.g., the section on source locations can link to https://clang.llvm.org/docs/InternalsManual.html#the-sourcelocation-and-sourcemanager-classes, etc. WDYT?
clang/docs/LibClang.rst | ||
---|---|---|
5–6 | Sphinx will complain if the underlines aren't the same length as what's being underlined. | |
24–25 | ||
34 | Should we name this .cpp instead of .hpp? It's pretty weird to compile a header file, so using .cpp makes it clear that the TU is parsed as C++ code rather than as a header. | |
38–39 | Pretty sure Sphinx will want a newline here. | |
87 | ||
115–117 | I noticed this in a few places -- you should make sure the punctuation is consistent for list elements. | |
142–146 | I don't think we should document the data field in this way -- that's an implementation detail. Users should assume data is not something they can inspect or modify. Instead, users should use indexing APIs like clang_equalTypes(). | |
151 | ||
184 | ||
261 |
Thanks a lot for carefully going through this. I will dispose of the documentation for CXType after accepting.
Hmm, something seems to have gone sideways somewhere because it looks like none of the comments were addressed -- did you perhaps re-upload the original patch?
LGTM, thank you! Do you need me to commit this on your behalf? If so, what name and email address would you like me to use for patch attribution? (I'll build the docs locally and correct any remaining formatting mistakes before landing.)
Thank you for the new documentation, it's really appreciated! I've landed this on your behalf in 12d72e4fdee91b3f1e314759d6aa33d25fb38f86
Sphinx will complain if the underlines aren't the same length as what's being underlined.