[e288c6]: ref_c_characters.xml Maximize Restore History

Download this file

ref_c_characters.xml    316 lines (257 with data), 12.4 kB

  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
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE book [
<!ENTITY % eclent SYSTEM "ecl.ent">
%eclent;
]>
<book xmlns="http://docbook.org/ns/docbook" version="5.0" xml:lang="en">
<chapter>
<title>Characters</title>
<section xml:id="ansi.characters.c-dict">
<title>C Reference</title>
<refentry xml:id="ansi.characters.c-types">
<refnamediv>
<refname>C types</refname>
<refpurpose>C character types</refpurpose>
</refnamediv>
<refsynopsisdiv>
<title>Type names</title>
<simplelist columns="2" type="horiz">
<member><type>ecl_character</type></member>
<member><type>character</type></member>
<member><type>ecl_base_char</type></member>
<member><type>base-char</type></member>
</simplelist>
</refsynopsisdiv>
<refsect1>
<title>Description</title>
<para>&ECL; defines two C types to hold its characters: <type>ecl_base_char</type> and <type>ecl_character</type>.</para>
<itemizedlist>
<listitem><para>When &ECL; is built without Unicode, they both coincide and typically match <type>unsigned char</type>, to cover the 256 codes that are needed.</para></listitem>
<listitem><para>When &ECL; is built with Unicode, the two types are no longer equivalent, with <type>ecl_character</type> being larger.</para></listitem>
</itemizedlist>
<para>For your code to be portable and future proof, use both types to really express what you intend to do.</para>
</refsect1>
</refentry>
<refentry>
<refnamediv>
<refname>Constructors</refname>
<refpurpose>Creating and extracting characters from Lisp objects</refpurpose>
</refnamediv>
<refsynopsisdiv>
<title>Functions and macros</title>
<funcsynopsis>
<funcprototype>
<?dbhtml funcsynopsis-style='ansi'?>
<funcdef>cl_object <function>ECL_CODE_CHAR</function></funcdef>
<paramdef><type>ecl_character</type> <parameter>code</parameter></paramdef>
</funcprototype>
</funcsynopsis>
<funcsynopsis>
<funcprototype>
<?dbhtml funcsynopsis-style='ansi'?>
<funcdef>ecl_character <function>ECL_CHAR_CODE</function></funcdef>
<paramdef><type>cl_object</type> <parameter>o</parameter></paramdef>
</funcprototype>
</funcsynopsis>
<funcsynopsis>
<funcprototype>
<?dbhtml funcsynopsis-style='ansi'?>
<funcdef>cl_object <function>ecl_char_code</function></funcdef>
<paramdef><type>ecl_character</type> <parameter>code</parameter></paramdef>
</funcprototype>
</funcsynopsis>
<funcsynopsis>
<funcprototype>
<?dbhtml funcsynopsis-style='ansi'?>
<funcdef>ecl_base_char <function>ecl_base_char_code</function></funcdef>
<paramdef><type>cl_object</type> <parameter>o</parameter></paramdef>
</funcprototype>
</funcsynopsis>
</refsynopsisdiv>
<refsect1>
<title>Description</title>
<para>These functions and macros convert back and forth from C character types to Lisp. The macros <function>ECL_CHAR_CODE</function> and <function>ECL_CODE_CHAR</function> perform this coercion without checking the arguments. The functions <function>ecl_char_code</function> and <function>ecl_base_char_code</function>, on the other hand, verify that the argument has the right type and signal an error otherwise.</para>
</refsect1>
</refentry>
<refentry>
<refnamediv>
<refname>Predicates</refname>
<refpurpose>C predicates for Lisp characters</refpurpose>
</refnamediv>
<refsynopsisdiv>
<title>Functions and macros</title>
<funcsynopsis>
<funcprototype>
<?dbhtml funcsynopsis-style='ansi'?>
<funcdef>bool <function>ecl_base_char_p</function></funcdef>
<paramdef><type>ecl_character</type> <parameter>c</parameter></paramdef>
</funcprototype>
</funcsynopsis>
<funcsynopsis>
<funcprototype>
<?dbhtml funcsynopsis-style='ansi'?>
<funcdef>bool <function>ecl_alpha_char_p</function></funcdef>
<paramdef><type>ecl_character</type> <parameter>c</parameter></paramdef>
</funcprototype>
</funcsynopsis>
<funcsynopsis>
<funcprototype>
<?dbhtml funcsynopsis-style='ansi'?>
<funcdef>bool <function>ecl_alphanumeric_p</function></funcdef>
<paramdef><type>ecl_character</type> <parameter>c</parameter></paramdef>
</funcprototype>
</funcsynopsis>
<funcsynopsis>
<funcprototype>
<?dbhtml funcsynopsis-style='ansi'?>
<funcdef>bool <function>ecl_graphic_char_p</function></funcdef>
<paramdef><type>ecl_character</type> <parameter>c</parameter></paramdef>
</funcprototype>
</funcsynopsis>
<funcsynopsis>
<funcprototype>
<?dbhtml funcsynopsis-style='ansi'?>
<funcdef>bool <function>ecl_digit_p</function></funcdef>
<paramdef><type>ecl_character</type> <parameter>c</parameter></paramdef>
</funcprototype>
</funcsynopsis>
<funcsynopsis>
<funcprototype>
<?dbhtml funcsynopsis-style='ansi'?>
<funcdef>bool <function>ecl_standard_char_p</function></funcdef>
<paramdef><type>ecl_character</type> <parameter>c</parameter></paramdef>
</funcprototype>
</funcsynopsis>
</refsynopsisdiv>
<refsect1>
<title>Description</title>
<para>These functions are equivalent to their Lisp equivalents but return C booleans.</para>
</refsect1>
</refentry>
<refentry>
<refnamediv>
<refname>Character case</refname>
<refpurpose>C functions related to the character case</refpurpose>
</refnamediv>
<refsynopsisdiv>
<title>Functions and macros</title>
<funcsynopsis>
<funcprototype>
<?dbhtml funcsynopsis-style='ansi'?>
<funcdef>bool <function>ecl_upper_case_p</function></funcdef>
<paramdef><type>ecl_character</type> <parameter>c</parameter></paramdef>
</funcprototype>
</funcsynopsis>
<funcsynopsis>
<funcprototype>
<?dbhtml funcsynopsis-style='ansi'?>
<funcdef>bool <function>ecl_lower_case_p</function></funcdef>
<paramdef><type>ecl_character</type> <parameter>c</parameter></paramdef>
</funcprototype>
</funcsynopsis>
<funcsynopsis>
<funcprototype>
<?dbhtml funcsynopsis-style='ansi'?>
<funcdef>bool <function>ecl_both_case_p</function></funcdef>
<paramdef><type>ecl_character</type> <parameter>c</parameter></paramdef>
</funcprototype>
</funcsynopsis>
<funcsynopsis>
<funcprototype>
<?dbhtml funcsynopsis-style='ansi'?>
<funcdef>ecl_character <function>ecl_char_downcase</function></funcdef>
<paramdef><type>ecl_character</type> <parameter>c</parameter></paramdef>
</funcprototype>
</funcsynopsis>
<funcsynopsis>
<funcprototype>
<?dbhtml funcsynopsis-style='ansi'?>
<funcdef>ecl_character <function>ecl_char_upcase</function></funcdef>
<paramdef><type>ecl_character</type> <parameter>c</parameter></paramdef>
</funcprototype>
</funcsynopsis>
</refsynopsisdiv>
<refsect1>
<title>Description</title>
<para>These functions check or change the case of a character. Note that in an Unicode context, the output of these functions might not be accurate (for instance when the uppercase character has two or more codepoints).</para>
</refsect1>
</refentry>
<refentry>
<refnamediv>
<refname>ANSI Dictionary</refname>
<refpurpose>&ANSI-C-Dict;</refpurpose>
</refnamediv>
<refsynopsisdiv>
<simplelist columns="2" type="horiz">
<member>Lisp symbol</member>
<member>C function</member>
<member><ulink url="&clhs;f_chareq.htm"><symbol>char=</symbol></ulink></member>
<member><code>cl_object cl_charE(cl_narg narg, ...)</code></member>
<member><ulink url="&clhs;f_chareq.htm"><symbol>char/=</symbol></ulink></member>
<member><code>cl_object cl_charNE(cl_narg narg, ...)</code></member>
<member><ulink url="&clhs;f_chareq.htm"><symbol>char&lt;</symbol></ulink></member>
<member><code>cl_object cl_charL(cl_narg narg, ...)</code></member>
<member><ulink url="&clhs;f_chareq.htm"><symbol>char&gt;</symbol></ulink></member>
<member><code>cl_object cl_charG(cl_narg narg, ...)</code></member>
<member><ulink url="&clhs;f_chareq.htm"><symbol>char&lt;=</symbol></ulink></member>
<member><code>cl_object cl_charLE(cl_narg narg, ...)</code></member>
<member><ulink url="&clhs;f_chareq.htm"><symbol>char&gt;=</symbol></ulink></member>
<member><code>cl_object cl_charGE(cl_narg narg, ...)</code></member>
<member><ulink url="&clhs;f_chareq.htm"><symbol>char-equal</symbol></ulink></member>
<member><code>cl_object cl_char_equal(cl_narg narg, ...)</code></member>
<member><ulink url="&clhs;f_chareq.htm"><symbol>char-not-equal</symbol></ulink></member>
<member><code>cl_object cl_char_not_equal(cl_narg narg, ...)</code></member>
<member><ulink url="&clhs;f_chareq.htm"><symbol>char-lessp</symbol></ulink></member>
<member><code>cl_object cl_char_lessp(cl_narg narg, ...)</code></member>
<member><ulink url="&clhs;f_chareq.htm"><symbol>char-greaterp</symbol></ulink></member>
<member><code>cl_object cl_char_greaterp(cl_narg narg, ...)</code></member>
<member><ulink url="&clhs;f_chareq.htm"><symbol>char-not-greaterp</symbol></ulink></member>
<member><code>cl_object cl_char_not_greaterp(cl_narg narg, ...)</code></member>
<member><ulink url="&clhs;f_chareq.htm"><symbol>char-not-lessp</symbol></ulink></member>
<member><code>cl_object cl_char_not_lessp(cl_narg narg, ...)</code></member>
<member><ulink url="&clhs;f_ch.htm"><symbol>character</symbol></ulink></member>
<member><code>cl_object cl_character(cl_object char_designator)</code></member>
<member><ulink url="&clhs;f_chp.htm"><symbol>characterp</symbol></ulink></member>
<member><code>cl_object cl_characterp(cl_object object)</code></member>
<member><ulink url="&clhs;f_alpha_.htm"><symbol>alpha-char-p</symbol></ulink></member>
<member><code>cl_object cl_alpha_char_p(cl_object character)</code></member>
<member><ulink url="&clhs;f_alphan.htm"><symbol>alphanumericp</symbol></ulink></member>
<member><code>cl_object cl_alphanumericp(cl_object character)</code></member>
<member><ulink url="&clhs;f_digit_.htm"><symbol>digit-char</symbol></ulink></member>
<member><code>cl_object cl_digit_char(cl_narg narg, cl_object character, ...)</code></member>
<member><ulink url="&clhs;f_digi_1.htm"><symbol>digit-char-p</symbol></ulink></member>
<member><code>cl_object cl_digit_char_p(cl_narg narg, cl_object character, ...)</code></member>
<member><ulink url="&clhs;f_graphi.htm"><symbol>graphic-char-p</symbol></ulink></member>
<member><code>cl_object cl_graphic_char_p(cl_object character)</code></member>
<member><ulink url="&clhs;f_std_ch.htm"><symbol>standard-char-p</symbol></ulink></member>
<member><code>cl_object cl_standard_char_p(cl_object character)</code></member>
<member><ulink url="&clhs;f_char_u.htm"><symbol>char_upcase</symbol></ulink></member>
<member><code>cl_object cl_char_upcase(cl_object character)</code></member>
<member><ulink url="&clhs;f_char_u.htm"><symbol>char-downcase</symbol></ulink></member>
<member><code>cl_object cl_char_downcase(cl_object character)</code></member>
<member><ulink url="&clhs;f_upper_.htm"><symbol>upper-case-p</symbol></ulink></member>
<member><code>cl_object cl_upper_case_p(cl_object character)</code></member>
<member><ulink url="&clhs;f_upper_.htm"><symbol>lower-case-p</symbol></ulink></member>
<member><code>cl_object cl_lower_case_p(cl_object character)</code></member>
<member><ulink url="&clhs;f_upper_.htm"><symbol>both-case-p</symbol></ulink></member>
<member><code>cl_object cl_both_case_p(cl_object character)</code></member>
<member><ulink url="&clhs;f_char_c.htm"><symbol>char-code</symbol></ulink></member>
<member><code>cl_object cl_char_code(cl_object character)</code></member>
<member><ulink url="&clhs;f_char_i.htm"><symbol>char-int</symbol></ulink></member>
<member><code>cl_object cl_char_int(cl_object character)</code></member>
<member><ulink url="&clhs;f_code_c.htm"><symbol>code-char</symbol></ulink></member>
<member><code>cl_object cl_code_char(cl_object code)</code></member>
<member><ulink url="&clhs;f_char_n.htm"><symbol>char-name</symbol></ulink></member>
<member><code>cl_object cl_char_name(cl_object character)</code></member>
<member><ulink url="&clhs;f_name_c.htm"><symbol>name-char</symbol></ulink></member>
<member><code>cl_object cl_name_char(cl_object name)</code></member>
</simplelist>
</refsynopsisdiv>
<refsect1>
<title>Description</title>
<para></para>
</refsect1>
</refentry>
</section>
</chapter>
</book>