This document includes the description of the ASTImporter from the user/client
perspective.
A subsequent patch will describe the development internals.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
- Build Status
Buildable 35961 Build 35960: arc lint + arc unit
Event Timeline
Thanks, the extra documentation is highly appreciated!
clang/docs/LibASTImporter.rst | ||
---|---|---|
19 | Stylistic note: usually LLVM documentation is written avoiding "we". So for example: In some cases it is preferable to work with more than one ``ASTContext``, for example when parsing multiple files inside one Clang-based tool. | |
33 | Importing ... copies that node ... |
Thank you for writing this up! I just have a few minor comments.
clang/docs/LibASTImporter.rst | ||
---|---|---|
110 | Maybe helpful to link to the Matching the Clang AST and AST Matcher Reference | |
283 | Note ODR is a C++ concept C does not have ODR |
Lovely documentation with practical use-cases!
I left a few inline remarks.
Also wouldn't it be nice to have a section which introduces the -ast-merge command-line option. It would be helpful to see an example where a PCH is dumped and merged into another TU. You could mention, that this can be used to debug ASTImporter functionality.
Cheers!
clang/docs/LibASTImporter.rst | ||
---|---|---|
26 | I'd prefer: | |
32 | I'd put a comma here: | |
34 | Leave the just, or rephrase: | |
42 | I'd put a comma here: | |
74 | I'd put a comma here: | |
154 | Leave the 'And' | |
190 | I'd put a comma here: | |
272 | Leave the 'And' | |
283 | I'd put a comma here: | |
347 | I'd use simple present here: | |
388 | Not a native, but this stood out: | |
402 | I'd switch these: | |
410 | I'd phrase it like this: | |
476 | I'd put a comma here: |
Thanks for the review!
clang/docs/LibASTImporter.rst | ||
---|---|---|
19 | In one hand, I accept that maybe the word "we" is overused in this document. On the other hand, I feel if all occurrences of "we" were replaced then the document would become filled with passive voice. That would make it too formal and would provide harder reading in my opinion. l have rephrased those sentences which you explicitly mentioned, please add comments to those sentences where you still feel the use of "we" inappropriate. | |
32 | I changed to Adrian's suggestion. | |
110 | Ok, I've added them to the beginning of the doc. | |
283 | Changed to | |
410 | I changed to use past perfect as well to emphasize that the node had been created before the error was recognized. |
Thanks Alexei for the review! I commited a fix for the typos.
cfe/trunk/docs/LibASTImporter.rst | ||
---|---|---|
215 ↗ | (On Diff #213556) | Indeed... Still, I did not change that to keep consistency with other parts of the examples. |
Stylistic note: usually LLVM documentation is written avoiding "we". So for example: