Skip to content

Commit 5e025f1

Browse files
authored
Documentation! (#141)
* Fixing spelling errors in comment. * Adding Doxygen and preset. * Documentation now building locally. * Moving machines - still warnings to resolve. * Update doxyfile * More documentation fixes. * More test cleanup and fixing unit tests. * Small improvements to functional * Fixing doxygen warnings. * Checkpoint in doxygen warning fixes. * Cleaning out final doxygen warnings.
1 parent 3bf8e5e commit 5e025f1

File tree

336 files changed

+1821
-58438
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

336 files changed

+1821
-58438
lines changed

.github/workflows/doxygen.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Doxygen
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- name: Checkout code
14+
uses: actions/checkout@v2
15+
16+
- name: Install Doxygen
17+
run: sudo apt-get update && sudo apt-get install -y doxygen
18+
19+
- name: Build documentation
20+
run: doxygen documentation/doxyfile
21+
22+
- name: Deploy to GitHub Pages
23+
uses: peaceiris/actions-gh-pages@v3
24+
with:
25+
github_token: ${{ secrets.GITHUB_TOKEN }}
26+
publish_dir: build/asl-docs/html

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,4 @@ documentation/doxyfile.bak
99
build_asl/
1010
.vs/
1111
.vscode/settings.json
12+
/.cache

CMakeLists.txt

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,16 @@ endif(NOT DEFINED CMAKE_CXX_STANDARD)
1717

1818
set(CMAKE_XCODE_ATTRIBUTE_CLANG_CXX_LIBRARY "libc++")
1919

20+
# Create symlink to compile_commands.json for clangd
21+
if(CMAKE_EXPORT_COMPILE_COMMANDS)
22+
add_custom_target(clangd_compile_commands ALL
23+
COMMAND ${CMAKE_COMMAND} -E create_symlink
24+
${CMAKE_BINARY_DIR}/compile_commands.json
25+
${CMAKE_SOURCE_DIR}/compile_commands.json
26+
COMMENT "Creating symlink to compile_commands.json for clangd"
27+
)
28+
endif()
29+
2030
project(adobe-source-libraries CXX)
2131

2232
# https://github.com/boostorg/boost/releases
@@ -49,3 +59,18 @@ add_subdirectory(source)
4959
if(BUILD_TESTING)
5060
add_subdirectory(test)
5161
endif()
62+
63+
find_package(Doxygen)
64+
65+
if(DOXYGEN_FOUND)
66+
set(DOXYGEN_IN ${CMAKE_CURRENT_SOURCE_DIR}/documentation/doxyfile)
67+
68+
add_custom_target(doxygen ALL
69+
COMMAND ${DOXYGEN_EXECUTABLE} ${DOXYGEN_IN}
70+
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
71+
COMMENT "Generating API documentation with Doxygen"
72+
VERBATIM
73+
)
74+
else()
75+
message(WARNING "Doxygen not found - documentation will not be built")
76+
endif()

CMakePresets.json

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,16 @@
138138
"enableClangTidyCodeAnalysis": true
139139
}
140140
}
141+
},
142+
{
143+
"name": "docs",
144+
"displayName": "docs",
145+
"description": "Build Doxygen documentation",
146+
"generator": "Ninja",
147+
"binaryDir": "${sourceParentDir}/build/asl-docs",
148+
"cacheVariables": {
149+
"CMAKE_BUILD_TYPE": "DEBUG"
150+
}
141151
}
142152
],
143153
"buildPresets": [
@@ -146,6 +156,13 @@
146156
"description": "",
147157
"displayName": "",
148158
"configurePreset": "debug"
159+
},
160+
{
161+
"name": "docs",
162+
"description": "",
163+
"displayName": "",
164+
"configurePreset": "docs",
165+
"targets": [ "doxygen" ]
149166
}
150167
],
151168
"testPresets": [

adobe/adam.hpp

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,11 @@
2525

2626
/*
2727
28-
REVISIT (sparent) : It would be best to detangle the sheet from
29-
the virtual machine. The way to do this is to allow for funciton
28+
REVISIT (sparent) : It would be best to untangle the sheet from
29+
the virtual machine. The way to do this is to allow for function
3030
objects to be passed instead of line positions and expression
3131
arrays. The function object could bind to the line_position_t and
32-
the array.... This would allow for easier programatic driving.
32+
the array.... This would allow for easier programmatic driving.
3333
3434
*/
3535

@@ -190,8 +190,6 @@ class sheet_t : boost::noncopyable {
190190
\param name name of the cell being added.
191191
192192
\param value value for the cell.
193-
194-
\param initializer expression to be evaluated for the cell's value.
195193
*/
196194
void add_constant(name_t name, any_regular_t value);
197195

@@ -233,7 +231,7 @@ class sheet_t : boost::noncopyable {
233231
\param linked specifies whether or not the output value is
234232
automatically applied back to the input value of the cell.
235233
236-
\param position position in the parse of the initializer definition.
234+
\param position1 position in the parse of the initializer definition.
237235
238236
\param initializer expression to be evaluated for the cell's value
239237
@@ -254,7 +252,7 @@ class sheet_t : boost::noncopyable {
254252
255253
\param name name of the cell being added.
256254
257-
\param inital initial value of the cell.
255+
\param initial initial value of the cell.
258256
*/
259257
void add_interface(name_t name, any_regular_t initial);
260258

@@ -288,7 +286,7 @@ class sheet_t : boost::noncopyable {
288286
Establishes a callback for a cell to be called when the value of the
289287
cell changes.
290288
291-
\param cell the name of the cell to monitor.
289+
\param name the name of the cell to monitor.
292290
293291
\param proc the \ref concept_convertible_to_function to be called
294292
with the new cell value.

adobe/algorithm.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ using.
9494
- \ref minmax
9595
- \ref rotate
9696
97-
\sa \ref stldoc_index
97+
9898
9999
\defgroup mutating_algorithm Mutating Algorithms
100100
\ingroup algorithm

adobe/algorithm/binary_search.hpp

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,8 @@ to [1] \c x if such a value s present and \c l if no such elment exists. \c bina
5151
takes an optional comparision function and uses \c adobe::less() if not provided.
5252
5353
\requirements
54-
- \c I is a model of \ref stldoc_ForwardIterator.
55-
- \c C is a model of \ref stldoc_LessThanComparable.
54+
- \c I is a model of [ForwardIterator](https://www.boost.org/sgi/stl/ForwardIterator.html).
55+
- \c C is a model of [LessThanComparable](https://www.boost.org/sgi/stl/LessThanComparable.html).
5656
- <code>value_type(I) == argument_type(C)</code>
5757
5858
\pre
@@ -63,31 +63,31 @@ of iterators \c i and \c j in <code>[f, l)</code> such that \c i precedes \c j,
6363
6464
\complexity
6565
The number of comparisons is logarithmic: at most <code>log(l - f) + 2</code>. If I is a
66-
\ref stldoc_RandomAccessIterator then the number of steps through the range is also logarithmic;
66+
[RandomAccessIterator](https://www.boost.org/sgi/stl/RandomAccessIterator.html) then the number of steps through the range is also logarithmic;
6767
otherwise, the number of steps is proportional to last - first. [2]
6868
6969
\notes
7070
[1] Note that you may use an ordering that is a strict weak ordering but not a total ordering; that
7171
is, there might be values x and y such that x < y, x > y, and x == y are all false.
72-
(See the \ref stldoc_LessThanComparable requirements for a more complete discussion.) Finding \c x
72+
(See the [LessThanComparable](https://www.boost.org/sgi/stl/LessThanComparable.html) requirements for a more complete discussion.) Finding \c x
7373
in the range <code>[f, l)</code>, then, doesn't mean finding an element that is equal to \c x but
7474
rather one that is equivalent to \c x: one that is neither greater than nor less than \c x. If
7575
you're using a total ordering, however (if you're using \c strcmp, for example, or if you're using
7676
ordinary arithmetic comparison on integers), then you can ignore this technical distinction: for a
7777
total ordering, equality and equivalence are the same.
7878
79-
[2] This difference between \ref stldoc_RandomAccessIterator and \ref stldoc_ForwardIterator is
80-
simply because advance is constant time for \ref stldoc_RandomAccessIterator and linear time for
81-
\ref stldoc_ForwardIterator.
79+
[2] This difference between [RandomAccessIterator](https://www.boost.org/sgi/stl/RandomAccessIterator.html) and [ForwardIterator](https://www.boost.org/sgi/stl/ForwardIterator.html) is
80+
simply because advance is constant time for [RandomAccessIterator](https://www.boost.org/sgi/stl/RandomAccessIterator.html) and linear time for
81+
[ForwardIterator](https://www.boost.org/sgi/stl/ForwardIterator.html).
8282
8383
\note
84-
\c binary_search() differs from \ref stldoc_binary_search in that it returns an iterator to the
84+
\c binary_search() differs from [std::binary_search](https://www.boost.org/sgi/stl/binary_search.html) in that it returns an iterator to the
8585
first element rather than simply a \c bool. This is commonly a more useful function.
8686
\c binary_search is similar to \ref lower_bound except it returns \c l if no element matching \c x
8787
exists.
8888
8989
\see
90-
- STL documentation for \ref stldoc_binary_search
90+
- [STL documentation for binary_search](https://www.boost.org/sgi/stl/binary_search.html)
9191
- \ref lower_bound
9292
- \ref upper_bound
9393
- \ref equal_range

adobe/algorithm/copy.hpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,9 @@ namespace adobe {
2727
\ingroup mutating_algorithm
2828
2929
\see
30-
- STL documentation for \ref stldoc_copy
31-
- STL documentation for \ref stldoc_copy_n
32-
- STL documentation for \ref stldoc_copy_backward
30+
- [STL documentation for copy](https://www.boost.org/sgi/stl/copy.html)
31+
- [STL documentation for copy_n](https://www.boost.org/sgi/stl/copy_n.html)
32+
- [STL documentation for copy_backward](https://www.boost.org/sgi/stl/copy_backward.html)
3333
*/
3434
/**************************************************************************************************/
3535

adobe/algorithm/count.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@ namespace adobe {
2727
\ingroup non_mutating_algorithm
2828
2929
\see
30-
- STL documentation for \ref stldoc_count
31-
- STL documentation for \ref stldoc_count_if
30+
- [STL documentation for count](https://www.boost.org/sgi/stl/count.html)
31+
- [STL documentation for count_if](https://www.boost.org/sgi/stl/count_if.html)
3232
*/
3333
/**************************************************************************************************/
3434
/*!

adobe/algorithm/equal.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ namespace adobe {
2626
\ingroup non_mutating_algorithm
2727
2828
\see
29-
- STL documentation for \ref stldoc_equal
29+
- [STL documentation for equal](https://www.boost.org/sgi/stl/equal.html)
3030
*/
3131
/**************************************************************************************************/
3232
/*!

0 commit comments

Comments
 (0)