File: README.c.rtf

package info (click to toggle)
cxref 1.5c-9
  • links: PTS
  • area: main
  • in suites: woody
  • size: 1,504 kB
  • ctags: 1,359
  • sloc: ansic: 16,721; yacc: 1,930; sh: 722; lex: 416; makefile: 345; lisp: 256; python: 80; perl: 78
file content (170 lines) | stat: -rw-r--r-- 7,301 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
{\rtf\ansi
\deff0
{\fonttbl
{\f0\froman Times New Roman;}
{\f1\fmodern Courier New;}
}
{\stylesheet
{\s0\f0\fs24 Normal;}
{\s1\f0\fs40\b\sb400\sa200\keepn\keep Heading 1;}
{\s2\f0\fs32\b\sb200\sa100\keepn\keep Heading 2;}
{\s3\f0\fs28\b\sb100\sa100\keepn\keep Heading 3;}
{\s4\f0\fs24\b\sb100\sa50\keepn\keep Heading 4;}
{\s5\f1\fs20\ql\sb50\sa50 Code;}
}
{\info{\comment This RTF file generated by cxref. cxref program (c) Andrew M. Bishop 1995,96,97,98,99.}}
\paperw11880\paperh16848\margl1440\margr1440\margt1440\margb1440
\sectd\plain
\s0\f0\fs24
{\s1\f0\fs40\b\sb400\sa200\keepn\keep File README.c\par}
{\b RCS Header: /home/amb/cxref/RCS/README.c 1.4 1997/05/26 11:23:40 amb Exp}\par
A comment for the file, RCS header comments are treated specially when first.\par
{\s2\f0\fs32\b\sb200\sa100\keepn\keep Included Files\par}
A #include comment\par
{\s5\f1\fs20\ql\sb50\sa50 #include <stdio.h>\par}
An alternative #include comment.\par
{\s5\f1\fs20\ql\sb50\sa50 #include <math.h>\par}
{\s2\f0\fs32\b\sb200\sa100\keepn\keep Preprocessor definitions\par}
A #define comment.\par
{\s5\f1\fs20\ql\sb50\sa50 #define def1 1\par}
An alternative #define comment.\par
{\s5\f1\fs20\ql\sb50\sa50 #define def2 2\par}
A #define with args\par
{\s5\f1\fs20\ql\sb50\sa50 #define def3( arg1, arg2 )\par}
{\s5\f1\fs20\ql\sb50\sa50arg1\par}
{\s6\f0\fs24\ql\li720 The first arg\par}
{\s5\f1\fs20\ql\sb50\sa50arg2\par}
{\s6\f0\fs24\ql\li720 The second arg\par}
An alternative #define with args.\par
{\s5\f1\fs20\ql\sb50\sa50 #define def4( arg1, arg2 )\par}
{\s5\f1\fs20\ql\sb50\sa50arg1\par}
{\s6\f0\fs24\ql\li720 The first arg\par}
{\s5\f1\fs20\ql\sb50\sa50arg2\par}
{\s6\f0\fs24\ql\li720 The second arg\par}
{\s2\f0\fs32\b\sb200\sa100\keepn\keep Type definitions\par}
{\s3\f0\fs28\b\sb100\sa100\keepn\keep Typedef type1\par}
An example typedef comment\par
{\s5\f1\fs20\ql\sb50\sa50 typedef enum \{...\} type1\par}
\trowd\trgaph120\cellx2880\cellx9000
\intbl\plain
{\s5\f1\fs20\ql\sb50\sa50 enum}\cell\cell\row
{\s5\f1\fs20\ql\sb50\sa50 \{}\cell\cell\row
	{\s5\f1\fs20\ql\sb50\sa50 one;}\cell one value\cell\row
	{\s5\f1\fs20\ql\sb50\sa50 two;}\cell another value\cell\row
{\s5\f1\fs20\ql\sb50\sa50 \}}\cell\cell\row
\intbl0
{\s3\f0\fs28\b\sb100\sa100\keepn\keep Type union bar\par}
Nested structs and unions also work.\par
\trowd\trgaph120\cellx2880\cellx9000
\intbl\plain
{\s5\f1\fs20\ql\sb50\sa50 union bar}\cell\cell\row
{\s5\f1\fs20\ql\sb50\sa50 \{}\cell\cell\row
	{\s5\f1\fs20\ql\sb50\sa50 char a;}\cell Each element\cell\row
	{\s5\f1\fs20\ql\sb50\sa50 int b;}\cell of a struct\cell\row
	{\s5\f1\fs20\ql\sb50\sa50 int c;}\cell or a union\cell\row
	{\s5\f1\fs20\ql\sb50\sa50 long d;}\cell can have a comment\cell\row
{\s5\f1\fs20\ql\sb50\sa50 \}}\cell\cell\row
\intbl0
{\s3\f0\fs28\b\sb100\sa100\keepn\keep Typedef type2\par}
Another example typedef comment, a type that is a struct.\par
{\s5\f1\fs20\ql\sb50\sa50 typedef struct \{...\} type2\par}
\trowd\trgaph120\cellx2880\cellx9000
\intbl\plain
{\s5\f1\fs20\ql\sb50\sa50 struct}\cell\cell\row
{\s5\f1\fs20\ql\sb50\sa50 \{}\cell\cell\row
	{\s5\f1\fs20\ql\sb50\sa50 int a;}\cell A variable in a struct.\cell\row
	{\s5\f1\fs20\ql\sb50\sa50 union bar}\cell\cell\row
	{\s5\f1\fs20\ql\sb50\sa50 \{}\cell\cell\row
		{\s5\f1\fs20\ql\sb50\sa50 char a;}\cell Each element\cell\row
		{\s5\f1\fs20\ql\sb50\sa50 int b;}\cell of a struct\cell\row
		{\s5\f1\fs20\ql\sb50\sa50 int c;}\cell or a union\cell\row
		{\s5\f1\fs20\ql\sb50\sa50 long d;}\cell can have a comment\cell\row
	{\s5\f1\fs20\ql\sb50\sa50 \}}\cell\cell\row
	{\s5\f1\fs20\ql\sb50\sa50 e;}\cell Nested structs and unions also work.\par
{\s5\f1\fs20\ql\sb50\sa50 \}}\cell\cell\row
\intbl0
{\s3\f0\fs28\b\sb100\sa100\keepn\keep Typedef ptype2\par}
Another example typedef comment, a pointer to a struct type.\par
{\s5\f1\fs20\ql\sb50\sa50 typedef struct \{...\}* ptype2\par}
See:	Typedef type2\par
{\s2\f0\fs32\b\sb200\sa100\keepn\keep Variables\par}
{\s3\f0\fs28\b\sb100\sa100\keepn\keep Variable var1\par}
A leading comment only.\par
{\s5\f1\fs20\ql\sb50\sa50 int var1\par}
\trowd\trgaph120\cellx1440\cellx5220\cellx9000
\intbl\plain
Visible in:\cell README.c\cell\cell\row
Used in:\cell function1()\cell README.c\cell\row
\intbl0
{\s3\f0\fs28\b\sb100\sa100\keepn\keep Variable var2\par}
A leading comment only.\par
{\s5\f1\fs20\ql\sb50\sa50 int var2\par}
\trowd\trgaph120\cellx1440\cellx5220\cellx9000
\intbl\plain
Visible in:\cell README.c\cell\cell\row
\intbl0
{\s3\f0\fs28\b\sb100\sa100\keepn\keep Variable var4\par}
A variable for one thing.\par
{\s5\f1\fs20\ql\sb50\sa50 int var4\par}
\trowd\trgaph120\cellx1440\cellx5220\cellx9000
\intbl\plain
Visible in:\cell README.c\cell\cell\row
Used in:\cell function1()\cell README.c\cell\row
\intbl0
{\s3\f0\fs28\b\sb100\sa100\keepn\keep Variable var5\par}
A variable for a second thing.\par
{\s5\f1\fs20\ql\sb50\sa50 int var5\par}
\trowd\trgaph120\cellx1440\cellx5220\cellx9000
\intbl\plain
Visible in:\cell README.c\cell\cell\row
\intbl0
{\s3\f0\fs28\b\sb100\sa100\keepn\keep Variable var6\par}
A variable for a third thing.\par
{\s5\f1\fs20\ql\sb50\sa50 int var6\par}
\trowd\trgaph120\cellx1440\cellx5220\cellx9000
\intbl\plain
Visible in:\cell README.c\cell\cell\row
\intbl0
{\s3\f0\fs28\b\sb100\sa100\keepn\keep Local Variables\par}
{\s4\f0\fs24\b\sb100\sa50\keepn\keep Variable var3\par}
A trailing comment only.\par
{\s5\f1\fs20\ql\sb50\sa50 static int var3\par}
\trowd\trgaph120\cellx1440\cellx5220\cellx9000
\intbl\plain
Used in:\cell function1()\cell\cell\row
\intbl0
{\s2\f0\fs32\b\sb200\sa100\keepn\keep Functions\par}
{\s3\f0\fs28\b\sb100\sa100\keepn\keep Global Function function1()\par}
A function comment (the comments for the args need to be separated by a blank line). Some more comments An internal comment in a function that appears as a new paragraph at the end of the comment.\par
{\s5\f1\fs20\ql\sb50\sa50 int function1 ( int arg1, int arg2 )\par}
{\s5\f1\fs20\ql\sb50\sa50 int function1\par}
{\s6\f0\fs24\ql\li720 The return value.\par}
{\s5\f1\fs20\ql\sb50\sa50 int arg1\par}
{\s6\f0\fs24\ql\li720 The first argument.\par}
{\s5\f1\fs20\ql\sb50\sa50 int arg2\par}
{\s6\f0\fs24\ql\li720 The second argument.\par}
\trowd\trgaph120\cellx1440\cellx5220\cellx9000
\intbl\plain
Calls: \cell function2()\cell README.c\cell\row
Used in:\cell function2()\cell README.c\cell\row
Refs Var:\cell var1\cell README.c\cell\row
\cell var3\cell README.c\cell\row
\cell var4\cell README.c\cell\row
\intbl0
{\s3\f0\fs28\b\sb100\sa100\keepn\keep Global Function function2()\par}
An alternative function comment\par
{\s5\f1\fs20\ql\sb50\sa50 int function2 ( int arg1, int arg2, void )\par}
{\s5\f1\fs20\ql\sb50\sa50 int function2\par}
{\s6\f0\fs24\ql\li720 Returns a value\par}
{\s5\f1\fs20\ql\sb50\sa50 int arg1\par}
{\s6\f0\fs24\ql\li720 The first argument.\par}
{\s5\f1\fs20\ql\sb50\sa50 int arg2\par}
{\s6\f0\fs24\ql\li720 The second argument.\par}
{\s5\f1\fs20\ql\sb50\sa50 void\par}
{\s6\f0\fs24\ql\li720 \par}
\trowd\trgaph120\cellx1440\cellx5220\cellx9000
\intbl\plain
Called by:\cell function1()\cell README.c\cell\row
Refs Func:\cell function1()\cell README.c\cell\row
\intbl0
}