-
Notifications
You must be signed in to change notification settings - Fork 17
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
8460e1f
commit 744eaee
Showing
20 changed files
with
3,326 additions
and
48 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,3 +8,5 @@ | |
/test-files/py | ||
/test-files/**/*.adoc | ||
/test-files/**/*.bad.xml | ||
docs/node_modules | ||
docs/build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
:linkcss: | ||
:stylesdir: https://cppalliance.github.io/mrdox/_/stylesheets | ||
:stylesheet: site.css |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# npm install | ||
# npx antora --fetch antora-playbook.yml | ||
site: | ||
title: MrDox | ||
url: https://cppalliance.github.io/mrdox/ | ||
start_page: mrdox::index.adoc | ||
robots: allow | ||
keys: | ||
repo_url: 'https://github.com/cppalliance/mrdox' | ||
|
||
content: | ||
branches: [ master, develop ] | ||
tags: [ v* ] | ||
edit_url: 'https://github.com/cppalliance/mrdox/edit/{refname}/{path}' | ||
sources: | ||
- url: https://github.com/cppalliance/mrdox.git | ||
start_path: docs | ||
edit_url: 'https://github.com/cppalliance/mrdox/edit/{refname}/{path}' | ||
|
||
ui: | ||
bundle: | ||
url: https://gitlab.com/antora/antora-ui-default/-/jobs/artifacts/HEAD/raw/build/ui-bundle.zip?job=bundle-stable | ||
snapshot: true | ||
|
||
antora: | ||
extensions: | ||
- require: '@antora/lunr-extension' # https://gitlab.com/antora/antora-lunr-extension | ||
index_latest_only: true | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
name: mrdox | ||
title: MrDox | ||
version: true | ||
start_page: index.adoc | ||
asciidoc: | ||
attributes: | ||
source-language: asciidoc@ | ||
table-caption: false | ||
nav: | ||
- modules/ROOT/nav.adoc |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# npm install | ||
# npx antora --fetch local-antora-playbook.yml | ||
site: | ||
title: MrDox | ||
url: https://cppalliance.github.io/mrdox/ | ||
start_page: mrdox::index.adoc | ||
robots: allow | ||
keys: | ||
repo_url: 'https://github.com/cppalliance/mrdox' | ||
|
||
content: | ||
sources: | ||
- url: .. | ||
start_path: docs | ||
edit_url: 'https://github.com/cppalliance/mrdox/edit/{refname}/{path}' | ||
|
||
ui: | ||
bundle: | ||
url: https://gitlab.com/antora/antora-ui-default/-/jobs/artifacts/HEAD/raw/build/ui-bundle.zip?job=bundle-stable | ||
snapshot: true | ||
|
||
antora: | ||
extensions: | ||
- require: '@antora/lunr-extension' # https://gitlab.com/antora/antora-lunr-extension | ||
index_latest_only: true | ||
|
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
* xref:index.adoc[] | ||
* xref:install.adoc[] | ||
* xref:design-notes.adoc[] | ||
* xref:usage.adoc[] | ||
* xref:contribute.adoc[] | ||
* xref:license.adoc[] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
= Contribute | ||
|
||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
= Design Notes | ||
|
||
== AST Traversal | ||
|
||
During the AST traversal stage, the complete AST (generated by the clang frontend) is walked beginning with the root `TranslationUnitDecl` node. | ||
It is during this stage that USRs (universal symbol references) are generated and hashed with SHA1 to form the 160 bit `SymbolID` for an entity. | ||
With the exception of built-in types, *all* entities referenced in the corpus will be traversed and be assigned a `SymbolID`; including those from the standard library. | ||
This is necessary to generate the full interface for user-defined types. | ||
|
||
== Bitcode | ||
|
||
AST traversal is performed in parallel on a per-translation-unit basis. | ||
To maximize the size of the code base MrDox is capable of processing, `Info` types generated during traversal are serialized to a compressed bitcode representation. | ||
Once AST traversal is complete for all translation units, the bitcode is deserialized back into `Info` types, and then merged to form the corpus. | ||
The merging step is necessary as there may be multiple identical definitions of the same entity (e.g. for class types, templates, inline functions, etc), as well as functions declared in one translation unit & defined in another. | ||
|
||
== The Corpus | ||
|
||
After AST traversal and `Info` merging, the result is stored as a map of `Info`s indexed by their respective `SymbolID`s. Documentation generators may traverse this structure by calling `Corpus::traverse` with a `Corpus::Visitor` derived visitor and the `SymbolID` of the entity to visit (e.g. the global namespace). | ||
|
||
== Namespaces | ||
|
||
Namespaces do not have a source location. | ||
This is because there can be many namespaces. | ||
We probably don't want to store any javadocs for namespaces either. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
= MrDox | ||
Alan Freitas <alandefreitas@gmail.com> | ||
:description: MrDox: A Clang/LLVM tool for building reference documentation from C++ code and javadoc comments. | ||
:sectanchors: | ||
:url-repo: https://github.com/cppalliance/mrdox | ||
:page-tags: mrdox | ||
:navtitle: Home | ||
|
||
image::MrDoxBanner.png[] | ||
|
||
Welcome to MrDox, the ultimate solution for generating comprehensive reference documentation from your {cpp} codebase and javadoc comments. MrDox harnesses the power of Clang/LLVM, offering a seamless and efficient way to document your {cpp} projects. | ||
|
||
With MrDox, you can effortlessly extract valuable insights and produce detailed documentation for your {cpp} code. By leveraging the rich semantic knowledge provided by Clang/LLVM, MrDox accurately captures the nuances of your codebase, including class hierarchies, functions, and their respective parameters and return types. This ensures that your documentation is not only informative but also up-to-date, eliminating the need for manual documentation maintenance. | ||
|
||
The integration of javadoc-style comments takes your documentation to the next level. With MrDox, you can easily embed human-readable explanations, usage examples, and additional contextual information directly within your code. These comments serve as a valuable resource for both developers and consumers of your code, promoting clarity and understanding. | ||
|
||
MrDox seamlessly fits into your development workflow, with the freedom to customize the output format to suit your project requirements. MrDox offers versatile options for output formats, including XML and Asciidoc. In addition to the provided output formats, MrDox empowers users to bring their own creativity and customization to the documentation generation process. With support for handlebars templates, you can create and apply your own unique templates to the generated documentation. This allows you to customize the styling, layout, and overall presentation of your documentation, making it truly personalized and aligned with your project's branding. | ||
|
||
MrDox empowers you to produce high-quality documentation that benefits both developers and users. Explore the power of MrDox today and experience the ease of building comprehensive reference documentation for your {cpp} projects. Say goodbye to tedious manual documentation and embrace the efficiency and accuracy of MrDox. | ||
|
||
== Comparison | ||
|
||
=== Doxygen: | ||
|
||
* tries to work for many languages | ||
* use the inferior libclang API | ||
* old program with lots of technical debt | ||
* not written by me | ||
|
||
=== MrDox: | ||
|
||
* narrow and deep focus on {cpp} only | ||
* uses clang's unstable libtooling API: | ||
** Understands ALL C++: if clang can compile it, MrDox knows about it | ||
** This includes up to {cpp}20 and even experimental things in {cpp}23 | ||
* brand-new program with no technical debt | ||
* written by me | ||
|
Oops, something went wrong.