Fossil SCM

Add end-tags to the anchors in the [doc/trunk/src/makeheaders.html] document.

drh 2011-01-28 19:09 trunk
Commit b6a4e8592d58ead7878f4a072fc6c4da71c7ea97
1 file changed +16 -16
--- src/makeheaders.html
+++ src/makeheaders.html
@@ -43,11 +43,11 @@
4343
<li><a href=makeheaders.html#H0015>4.0 Using Makeheaders To Generate Documentation</a>
4444
4545
<li><a href=makeheaders.html#H0016>5.0 Compiling The Makeheaders Program</a>
4646
4747
<li><a href=makeheaders.html#H0017>6.0 Summary And Conclusion</a>
48
-</ul><a name=H0002>
48
+</ul><a name="H0002"></a>
4949
<h2>1.0 Background</h2>
5050
5151
<p>
5252
A piece of C source code can be one of two things:
5353
a <em>declaration</em> or a <em>definition</em>.
@@ -98,11 +98,11 @@
9898
source code when the .c file is compiled.
9999
In this way, the .h files define the interface to a subsystem and
100100
the .c files define how the subsystem is implemented.
101101
</p>
102102
103
-<a name=H0003>
103
+<a name="H0003"></a>
104104
<h3>1.1 Problems With The Traditional Approach</h3>
105105
106106
<p>
107107
As the art of computer programming continues to advance, and the size
108108
and complexity of programs continues to swell, the traditional C
@@ -152,11 +152,11 @@
152152
especially when the declarations involved are spread out over several
153153
files.
154154
</ol>
155155
</p>
156156
157
-<a name=H0004>
157
+<a name="H0004"></a>
158158
<h3>1.2 The Makeheaders Solution</h3>
159159
160160
<p>
161161
The makeheaders program is designed to ameliorate the problems associated
162162
with the traditional C programming model by automatically generating
@@ -215,11 +215,11 @@
215215
And the burden of running makeheaders is light.
216216
It will easily process tens of thousands of lines of source
217217
code per second.
218218
</p>
219219
220
-<a name=H0005>
220
+<a name="H0005"></a>
221221
<h2>2.0 Running The Makeheaders Program</h2>
222222
223223
<p>
224224
The makeheaders program is very easy to run.
225225
If you have a collection of C source code and include files in the working
@@ -363,11 +363,11 @@
363363
Or, you can insert the special option ``--'' on the command
364364
line to cause all subsequent command line arguments to be treated as
365365
filenames even if their names beginn with ``-''.
366366
</p>
367367
368
-<a name=H0006>
368
+<a name="H0006"></a>
369369
<h2>3.0 Preparing Source Files For Use With Makeheaders</h2>
370370
371371
<p>
372372
Very little has to be done to prepare source files for use with
373373
makeheaders since makeheaders will read and understand ordinary
@@ -375,11 +375,11 @@
375375
But it is important that you structure your files in a way that
376376
makes sense in the makeheaders context.
377377
This section will describe several typical uses of makeheaders.
378378
</p>
379379
380
-<a name=H0007>
380
+<a name="H0007"></a>
381381
<h3>3.1 The Basic Setup</h3>
382382
383383
<p>
384384
The simpliest way to use makeheaders is to put all definitions in
385385
one or more .c files and all structure and type declarations in
@@ -474,11 +474,11 @@
474474
But that is not a problem.
475475
The makeheaders program will recognize and ignore any files it
476476
has previously generated that show up on its input list.
477477
</p>
478478
479
-<a name=H0008>
479
+<a name="H0008"></a>
480480
<h3>3.2 What Declarations Get Copied</h3>
481481
482482
<p>
483483
The following list details all of the code constructs that makeheaders
484484
will extract and place in
@@ -577,11 +577,11 @@
577577
If the declaration of some structure ``X'' requires a prior
578578
declaration of another structure ``Y'', then Y will appear
579579
first in the generated headers.
580580
</p>
581581
582
-<a name=H0009>
582
+<a name="H0009"></a>
583583
<h3>3.3 How To Avoid Having To Write Any Header Files</h3>
584584
585585
<p>
586586
In my experience, large projects work better if all of the manually
587587
written code is placed in .c files and all .h files are generated
@@ -644,11 +644,11 @@
644644
come from.
645645
You should also note that a single .c file can contain as many
646646
``#if INTERFACE'' regions as desired.
647647
</p>
648648
649
-<a name=H0010>
649
+<a name="H0010"></a>
650650
<h3>3.4 Designating Declarations For Export</h3>
651651
652652
<p>
653653
In a large project, one will often construct a hierarchy of
654654
interfaces.
@@ -733,11 +733,11 @@
733733
(The ``#if INTERFACE'' can also be used in both .h and .c files,
734734
but since it's use in a .h file would be redundant, we haven't mentioned
735735
it before.)
736736
</p>
737737
738
-<a name=H0011>
738
+<a name="H0011"></a>
739739
<h3>3.5 Local declarations processed by makeheaders</h3>
740740
741741
<p>
742742
Structure declarations and typedefs that appear in .c files are normally
743743
ignored by makeheaders.
@@ -771,11 +771,11 @@
771771
blocks described above, except that makeheaders insures that the
772772
objects declared in a LOCAL_INTERFACE are only visible to the
773773
file containing the LOCAL_INTERFACE.
774774
</p>
775775
776
-<a name=H0012>
776
+<a name="H0012"></a>
777777
<h3>3.6 Using Makeheaders With C++ Code</h3>
778778
779779
<p>
780780
You can use makeheaders to generate header files for C++ code, in
781781
addition to C.
@@ -870,11 +870,11 @@
870870
Makeheaders does not understand more recent
871871
C++ syntax such as templates and namespaces.
872872
Perhaps these issued will be addressed in future revisions.
873873
</p>
874874
875
-<a name=H0013>
875
+<a name="H0013"></a>
876876
<h3>3.7 Conditional Compilation</h3>
877877
878878
<p>
879879
The makeheaders program understands and tracks the conditional
880880
compilation constructs in the source code files it scans.
@@ -903,11 +903,11 @@
903903
#endif
904904
</pre>
905905
and treats the enclosed text as a comment.
906906
</p>
907907
908
-<a name=H0014>
908
+<a name="H0014"></a>
909909
<h3>3.8 Caveats</h3>
910910
911911
<p>
912912
The makeheaders system is designed to be robust
913913
but it is possible for a devious programmer to fool the system,
@@ -973,11 +973,11 @@
973973
As long as you avoid excessive cleverness, makeheaders will
974974
probably be able to figure out what you want and will do the right
975975
thing.
976976
</p>
977977
978
-<a name=H0015>
978
+<a name="H0015"></a>
979979
<h2>4.0 Using Makeheaders To Generate Documentation</h2>
980980
981981
<p>
982982
Many people have observed the advantages of generating program
983983
documentation directly from the source code:
@@ -1037,11 +1037,11 @@
10371037
The exact output format will not be described here.
10381038
It is simple to understand and parse and should be obvious to
10391039
anyone who inspects some sample output.
10401040
</p>
10411041
1042
-<a name=H0016>
1042
+<a name="H0016"></a>
10431043
<h2>5.0 Compiling The Makeheaders Program</h2>
10441044
10451045
<p>
10461046
The source code for makeheaders is a single file of ANSI-C code,
10471047
less than 3000 lines in length.
@@ -1050,11 +1050,11 @@
10501050
and on most operating systems.
10511051
It is known to compile using several variations of GCC for Unix
10521052
as well as Cygwin32 and MSVC 5.0 for Win32.
10531053
</p>
10541054
1055
-<a name=H0017>
1055
+<a name="H0017"></a>
10561056
<h2>6.0 Summary And Conclusion</h2>
10571057
10581058
<p>
10591059
The makeheaders program will automatically generate a minimal header file
10601060
for each of a set of C source and header files, and will
10611061
--- src/makeheaders.html
+++ src/makeheaders.html
@@ -43,11 +43,11 @@
43 <li><a href=makeheaders.html#H0015>4.0 Using Makeheaders To Generate Documentation</a>
44
45 <li><a href=makeheaders.html#H0016>5.0 Compiling The Makeheaders Program</a>
46
47 <li><a href=makeheaders.html#H0017>6.0 Summary And Conclusion</a>
48 </ul><a name=H0002>
49 <h2>1.0 Background</h2>
50
51 <p>
52 A piece of C source code can be one of two things:
53 a <em>declaration</em> or a <em>definition</em>.
@@ -98,11 +98,11 @@
98 source code when the .c file is compiled.
99 In this way, the .h files define the interface to a subsystem and
100 the .c files define how the subsystem is implemented.
101 </p>
102
103 <a name=H0003>
104 <h3>1.1 Problems With The Traditional Approach</h3>
105
106 <p>
107 As the art of computer programming continues to advance, and the size
108 and complexity of programs continues to swell, the traditional C
@@ -152,11 +152,11 @@
152 especially when the declarations involved are spread out over several
153 files.
154 </ol>
155 </p>
156
157 <a name=H0004>
158 <h3>1.2 The Makeheaders Solution</h3>
159
160 <p>
161 The makeheaders program is designed to ameliorate the problems associated
162 with the traditional C programming model by automatically generating
@@ -215,11 +215,11 @@
215 And the burden of running makeheaders is light.
216 It will easily process tens of thousands of lines of source
217 code per second.
218 </p>
219
220 <a name=H0005>
221 <h2>2.0 Running The Makeheaders Program</h2>
222
223 <p>
224 The makeheaders program is very easy to run.
225 If you have a collection of C source code and include files in the working
@@ -363,11 +363,11 @@
363 Or, you can insert the special option ``--'' on the command
364 line to cause all subsequent command line arguments to be treated as
365 filenames even if their names beginn with ``-''.
366 </p>
367
368 <a name=H0006>
369 <h2>3.0 Preparing Source Files For Use With Makeheaders</h2>
370
371 <p>
372 Very little has to be done to prepare source files for use with
373 makeheaders since makeheaders will read and understand ordinary
@@ -375,11 +375,11 @@
375 But it is important that you structure your files in a way that
376 makes sense in the makeheaders context.
377 This section will describe several typical uses of makeheaders.
378 </p>
379
380 <a name=H0007>
381 <h3>3.1 The Basic Setup</h3>
382
383 <p>
384 The simpliest way to use makeheaders is to put all definitions in
385 one or more .c files and all structure and type declarations in
@@ -474,11 +474,11 @@
474 But that is not a problem.
475 The makeheaders program will recognize and ignore any files it
476 has previously generated that show up on its input list.
477 </p>
478
479 <a name=H0008>
480 <h3>3.2 What Declarations Get Copied</h3>
481
482 <p>
483 The following list details all of the code constructs that makeheaders
484 will extract and place in
@@ -577,11 +577,11 @@
577 If the declaration of some structure ``X'' requires a prior
578 declaration of another structure ``Y'', then Y will appear
579 first in the generated headers.
580 </p>
581
582 <a name=H0009>
583 <h3>3.3 How To Avoid Having To Write Any Header Files</h3>
584
585 <p>
586 In my experience, large projects work better if all of the manually
587 written code is placed in .c files and all .h files are generated
@@ -644,11 +644,11 @@
644 come from.
645 You should also note that a single .c file can contain as many
646 ``#if INTERFACE'' regions as desired.
647 </p>
648
649 <a name=H0010>
650 <h3>3.4 Designating Declarations For Export</h3>
651
652 <p>
653 In a large project, one will often construct a hierarchy of
654 interfaces.
@@ -733,11 +733,11 @@
733 (The ``#if INTERFACE'' can also be used in both .h and .c files,
734 but since it's use in a .h file would be redundant, we haven't mentioned
735 it before.)
736 </p>
737
738 <a name=H0011>
739 <h3>3.5 Local declarations processed by makeheaders</h3>
740
741 <p>
742 Structure declarations and typedefs that appear in .c files are normally
743 ignored by makeheaders.
@@ -771,11 +771,11 @@
771 blocks described above, except that makeheaders insures that the
772 objects declared in a LOCAL_INTERFACE are only visible to the
773 file containing the LOCAL_INTERFACE.
774 </p>
775
776 <a name=H0012>
777 <h3>3.6 Using Makeheaders With C++ Code</h3>
778
779 <p>
780 You can use makeheaders to generate header files for C++ code, in
781 addition to C.
@@ -870,11 +870,11 @@
870 Makeheaders does not understand more recent
871 C++ syntax such as templates and namespaces.
872 Perhaps these issued will be addressed in future revisions.
873 </p>
874
875 <a name=H0013>
876 <h3>3.7 Conditional Compilation</h3>
877
878 <p>
879 The makeheaders program understands and tracks the conditional
880 compilation constructs in the source code files it scans.
@@ -903,11 +903,11 @@
903 #endif
904 </pre>
905 and treats the enclosed text as a comment.
906 </p>
907
908 <a name=H0014>
909 <h3>3.8 Caveats</h3>
910
911 <p>
912 The makeheaders system is designed to be robust
913 but it is possible for a devious programmer to fool the system,
@@ -973,11 +973,11 @@
973 As long as you avoid excessive cleverness, makeheaders will
974 probably be able to figure out what you want and will do the right
975 thing.
976 </p>
977
978 <a name=H0015>
979 <h2>4.0 Using Makeheaders To Generate Documentation</h2>
980
981 <p>
982 Many people have observed the advantages of generating program
983 documentation directly from the source code:
@@ -1037,11 +1037,11 @@
1037 The exact output format will not be described here.
1038 It is simple to understand and parse and should be obvious to
1039 anyone who inspects some sample output.
1040 </p>
1041
1042 <a name=H0016>
1043 <h2>5.0 Compiling The Makeheaders Program</h2>
1044
1045 <p>
1046 The source code for makeheaders is a single file of ANSI-C code,
1047 less than 3000 lines in length.
@@ -1050,11 +1050,11 @@
1050 and on most operating systems.
1051 It is known to compile using several variations of GCC for Unix
1052 as well as Cygwin32 and MSVC 5.0 for Win32.
1053 </p>
1054
1055 <a name=H0017>
1056 <h2>6.0 Summary And Conclusion</h2>
1057
1058 <p>
1059 The makeheaders program will automatically generate a minimal header file
1060 for each of a set of C source and header files, and will
1061
--- src/makeheaders.html
+++ src/makeheaders.html
@@ -43,11 +43,11 @@
43 <li><a href=makeheaders.html#H0015>4.0 Using Makeheaders To Generate Documentation</a>
44
45 <li><a href=makeheaders.html#H0016>5.0 Compiling The Makeheaders Program</a>
46
47 <li><a href=makeheaders.html#H0017>6.0 Summary And Conclusion</a>
48 </ul><a name="H0002"></a>
49 <h2>1.0 Background</h2>
50
51 <p>
52 A piece of C source code can be one of two things:
53 a <em>declaration</em> or a <em>definition</em>.
@@ -98,11 +98,11 @@
98 source code when the .c file is compiled.
99 In this way, the .h files define the interface to a subsystem and
100 the .c files define how the subsystem is implemented.
101 </p>
102
103 <a name="H0003"></a>
104 <h3>1.1 Problems With The Traditional Approach</h3>
105
106 <p>
107 As the art of computer programming continues to advance, and the size
108 and complexity of programs continues to swell, the traditional C
@@ -152,11 +152,11 @@
152 especially when the declarations involved are spread out over several
153 files.
154 </ol>
155 </p>
156
157 <a name="H0004"></a>
158 <h3>1.2 The Makeheaders Solution</h3>
159
160 <p>
161 The makeheaders program is designed to ameliorate the problems associated
162 with the traditional C programming model by automatically generating
@@ -215,11 +215,11 @@
215 And the burden of running makeheaders is light.
216 It will easily process tens of thousands of lines of source
217 code per second.
218 </p>
219
220 <a name="H0005"></a>
221 <h2>2.0 Running The Makeheaders Program</h2>
222
223 <p>
224 The makeheaders program is very easy to run.
225 If you have a collection of C source code and include files in the working
@@ -363,11 +363,11 @@
363 Or, you can insert the special option ``--'' on the command
364 line to cause all subsequent command line arguments to be treated as
365 filenames even if their names beginn with ``-''.
366 </p>
367
368 <a name="H0006"></a>
369 <h2>3.0 Preparing Source Files For Use With Makeheaders</h2>
370
371 <p>
372 Very little has to be done to prepare source files for use with
373 makeheaders since makeheaders will read and understand ordinary
@@ -375,11 +375,11 @@
375 But it is important that you structure your files in a way that
376 makes sense in the makeheaders context.
377 This section will describe several typical uses of makeheaders.
378 </p>
379
380 <a name="H0007"></a>
381 <h3>3.1 The Basic Setup</h3>
382
383 <p>
384 The simpliest way to use makeheaders is to put all definitions in
385 one or more .c files and all structure and type declarations in
@@ -474,11 +474,11 @@
474 But that is not a problem.
475 The makeheaders program will recognize and ignore any files it
476 has previously generated that show up on its input list.
477 </p>
478
479 <a name="H0008"></a>
480 <h3>3.2 What Declarations Get Copied</h3>
481
482 <p>
483 The following list details all of the code constructs that makeheaders
484 will extract and place in
@@ -577,11 +577,11 @@
577 If the declaration of some structure ``X'' requires a prior
578 declaration of another structure ``Y'', then Y will appear
579 first in the generated headers.
580 </p>
581
582 <a name="H0009"></a>
583 <h3>3.3 How To Avoid Having To Write Any Header Files</h3>
584
585 <p>
586 In my experience, large projects work better if all of the manually
587 written code is placed in .c files and all .h files are generated
@@ -644,11 +644,11 @@
644 come from.
645 You should also note that a single .c file can contain as many
646 ``#if INTERFACE'' regions as desired.
647 </p>
648
649 <a name="H0010"></a>
650 <h3>3.4 Designating Declarations For Export</h3>
651
652 <p>
653 In a large project, one will often construct a hierarchy of
654 interfaces.
@@ -733,11 +733,11 @@
733 (The ``#if INTERFACE'' can also be used in both .h and .c files,
734 but since it's use in a .h file would be redundant, we haven't mentioned
735 it before.)
736 </p>
737
738 <a name="H0011"></a>
739 <h3>3.5 Local declarations processed by makeheaders</h3>
740
741 <p>
742 Structure declarations and typedefs that appear in .c files are normally
743 ignored by makeheaders.
@@ -771,11 +771,11 @@
771 blocks described above, except that makeheaders insures that the
772 objects declared in a LOCAL_INTERFACE are only visible to the
773 file containing the LOCAL_INTERFACE.
774 </p>
775
776 <a name="H0012"></a>
777 <h3>3.6 Using Makeheaders With C++ Code</h3>
778
779 <p>
780 You can use makeheaders to generate header files for C++ code, in
781 addition to C.
@@ -870,11 +870,11 @@
870 Makeheaders does not understand more recent
871 C++ syntax such as templates and namespaces.
872 Perhaps these issued will be addressed in future revisions.
873 </p>
874
875 <a name="H0013"></a>
876 <h3>3.7 Conditional Compilation</h3>
877
878 <p>
879 The makeheaders program understands and tracks the conditional
880 compilation constructs in the source code files it scans.
@@ -903,11 +903,11 @@
903 #endif
904 </pre>
905 and treats the enclosed text as a comment.
906 </p>
907
908 <a name="H0014"></a>
909 <h3>3.8 Caveats</h3>
910
911 <p>
912 The makeheaders system is designed to be robust
913 but it is possible for a devious programmer to fool the system,
@@ -973,11 +973,11 @@
973 As long as you avoid excessive cleverness, makeheaders will
974 probably be able to figure out what you want and will do the right
975 thing.
976 </p>
977
978 <a name="H0015"></a>
979 <h2>4.0 Using Makeheaders To Generate Documentation</h2>
980
981 <p>
982 Many people have observed the advantages of generating program
983 documentation directly from the source code:
@@ -1037,11 +1037,11 @@
1037 The exact output format will not be described here.
1038 It is simple to understand and parse and should be obvious to
1039 anyone who inspects some sample output.
1040 </p>
1041
1042 <a name="H0016"></a>
1043 <h2>5.0 Compiling The Makeheaders Program</h2>
1044
1045 <p>
1046 The source code for makeheaders is a single file of ANSI-C code,
1047 less than 3000 lines in length.
@@ -1050,11 +1050,11 @@
1050 and on most operating systems.
1051 It is known to compile using several variations of GCC for Unix
1052 as well as Cygwin32 and MSVC 5.0 for Win32.
1053 </p>
1054
1055 <a name="H0017"></a>
1056 <h2>6.0 Summary And Conclusion</h2>
1057
1058 <p>
1059 The makeheaders program will automatically generate a minimal header file
1060 for each of a set of C source and header files, and will
1061

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button