~ubuntu-branches/ubuntu/quantal/gclcvs/quantal

« back to all changes in this revision

Viewing changes to info/sequence.texi

  • Committer: Bazaar Package Importer
  • Author(s): Camm Maguire
  • Date: 2004-06-24 15:13:46 UTC
  • Revision ID: james.westby@ubuntu.com-20040624151346-xh0xaaktyyp7aorc
Tags: 2.7.0-26
C_GC_OFFSET is 2 on m68k-linux

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
@node Sequences and Arrays and Hash Tables, Characters, Numbers, Top
 
2
@chapter Sequences and Arrays and Hash Tables
 
3
 
 
4
@defun VECTOR (&rest objects)
 
5
Package:LISP
 
6
 
 
7
Constructs a Simple-Vector from the given objects.
 
8
 
 
9
 
 
10
@end defun
 
11
 
 
12
@defun SUBSEQ (sequence start &optional (end (length sequence)))
 
13
Package:LISP
 
14
 
 
15
Returns a copy of a subsequence of SEQUENCE between START (inclusive) and
 
16
END (exclusive).
 
17
 
 
18
 
 
19
@end defun
 
20
 
 
21
@defun COPY-SEQ (sequence)
 
22
Package:LISP
 
23
 
 
24
Returns a copy of SEQUENCE.
 
25
 
 
26
 
 
27
@end defun
 
28
 
 
29
@defun POSITION (item sequence &key (from-end nil) (test #'eql) test-not (start 0) (end (length sequence)) (key #'identity))
 
30
Package:LISP
 
31
 
 
32
Returns the index of the first element in SEQUENCE that satisfies TEST with
 
33
ITEM; NIL if no such element exists.
 
34
 
 
35
 
 
36
@end defun
 
37
 
 
38
@defun ARRAY-RANK (array)
 
39
Package:LISP
 
40
 
 
41
Returns the number of dimensions of ARRAY.
 
42
 
 
43
 
 
44
@end defun
 
45
 
 
46
@defun SBIT (simple-bit-array &rest subscripts)
 
47
Package:LISP
 
48
 
 
49
Returns the bit from SIMPLE-BIT-ARRAY at SUBSCRIPTS.
 
50
 
 
51
 
 
52
@end defun
 
53
 
 
54
@defun STRING-CAPITALIZE (string &key (start 0) (end (length string)))
 
55
Package:LISP
 
56
 
 
57
Returns a copy of STRING with the first character of each word converted to
 
58
upper-case, and remaining characters in the word converted to lower case.
 
59
 
 
60
 
 
61
@end defun
 
62
 
 
63
@defun NSUBSTITUTE-IF-NOT (new test sequence &key (from-end nil) (start 0) (end (length sequence)) (count most-positive-fixnum) (key #'identity))
 
64
Package:LISP
 
65
 
 
66
Returns a sequence of the same kind as SEQUENCE with the same elements
 
67
 
 
68
except that all elements not satisfying TEST are replaced with NEWITEM.
 
69
SEQUENCE may be destroyed.
 
70
 
 
71
 
 
72
@end defun
 
73
 
 
74
@defun FIND-IF (test sequence &key (from-end nil) (start 0) (end (length sequence)) (key #'identity))
 
75
Package:LISP
 
76
 
 
77
Returns the index of the first element in SEQUENCE that satisfies TEST; NIL if
 
78
no such element exists.
 
79
 
 
80
 
 
81
@end defun
 
82
 
 
83
@defun BIT-EQV (bit-array1 bit-array2 &optional (result-bit-array nil))
 
84
Package:LISP
 
85
 
 
86
Performs a bit-wise logical EQV  on the elements of BIT-ARRAY1 and BIT-ARRAY2.
 
87
Puts the results into a new bit array if RESULT-BIT-ARRAY is NIL, into
 
88
BIT-ARRAY1 if RESULT-BIT-ARRAY is T, or into RESULT-BIT-ARRAY otherwise.
 
89
 
 
90
 
 
91
@end defun
 
92
 
 
93
@defun STRING< (string1 string2 &key (start1 0) (end1 (length string1)) (start2 0) (end2 (length string2)))
 
94
Package:LISP
 
95
 
 
96
If STRING1 is lexicographically less than STRING2, then returns the longest
 
97
common prefix of the strings.  Otherwise, returns NIL.
 
98
 
 
99
 
 
100
@end defun
 
101
 
 
102
@defun REVERSE (sequence)
 
103
Package:LISP
 
104
 
 
105
Returns a new sequence containing the same elements as SEQUENCE but in
 
106
reverse order.
 
107
 
 
108
 
 
109
@end defun
 
110
 
 
111
@defun NSTRING-UPCASE (string &key (start 0) (end (length string)))
 
112
Package:LISP
 
113
 
 
114
Returns STRING with all lower case characters converted to uppercase.
 
115
 
 
116
 
 
117
@end defun
 
118
 
 
119
@defun STRING>= (string1 string2 &key (start1 0) (end1 (length string1)) (start2 0) (end2 (length string2)))
 
120
Package:LISP
 
121
 
 
122
If STRING1 is lexicographically greater than or equal to STRING2, then returns
 
123
the longest common prefix of the strings.  Otherwise, returns NIL.
 
124
 
 
125
 
 
126
@end defun
 
127
 
 
128
@defun ARRAY-ROW-MAJOR-INDEX (array &rest subscripts)
 
129
Package:LISP
 
130
 
 
131
Returns the index into the data vector of ARRAY for the element of ARRAY
 
132
specified by SUBSCRIPTS.
 
133
 
 
134
 
 
135
@end defun
 
136
 
 
137
 
 
138
@defun ARRAY-DIMENSION (array axis-number)
 
139
Package:LISP
 
140
 
 
141
Returns the length of AXIS-NUMBER of ARRAY.
 
142
 
 
143
 
 
144
@end defun
 
145
 
 
146
@defun FIND (item sequence &key (from-end nil) (test #'eql) test-not (start 0) (end (length sequence)) (key #'identity))
 
147
Package:LISP
 
148
 
 
149
Returns the first element in SEQUENCE satisfying TEST with ITEM; NIL if no
 
150
such element exists.
 
151
 
 
152
 
 
153
@end defun
 
154
 
 
155
@defun STRING-NOT-EQUAL (string1 string2 &key (start1 0) (end1 (length string1)) (start2 0) (end2 (length string2)))
 
156
Package:LISP
 
157
 
 
158
Similar to STRING=, but ignores cases.
 
159
 
 
160
 
 
161
@end defun
 
162
 
 
163
@defun STRING-RIGHT-TRIM (char-bag string)
 
164
Package:LISP
 
165
 
 
166
Returns a copy of STRING with the characters in CHAR-BAG removed from the
 
167
right end.
 
168
 
 
169
 
 
170
@end defun
 
171
 
 
172
@defun DELETE-IF-NOT (test sequence &key (from-end nil) (start 0) (end (length sequence)) (count most-positive-fixnum) (key #'identity))
 
173
Package:LISP
 
174
 
 
175
Returns a sequence formed by destructively removing the elements not
 
176
satisfying TEST from SEQUENCE.
 
177
 
 
178
 
 
179
@end defun
 
180
 
 
181
@defun REMOVE-IF-NOT (test sequence &key (from-end nil) (start 0) (end (length sequence)) (count most-positive-fixnum) (key #'identity))
 
182
Package:LISP
 
183
 
 
184
Returns a copy of SEQUENCE with elements not satisfying TEST removed.
 
185
 
 
186
 
 
187
@end defun
 
188
 
 
189
@defun STRING= (string1 string2 &key (start1 0) (end1 (length string1)) (start2 0) (end2 (length string2)))
 
190
Package:LISP
 
191
 
 
192
Returns T if the two strings are character-wise CHAR=; NIL otherwise.
 
193
 
 
194
 
 
195
@end defun
 
196
 
 
197
@defun NSUBSTITUTE-IF (new test sequence &key (from-end nil) (start 0) (end (length sequence)) (count most-positive-fixnum) (key #'identity))
 
198
Package:LISP
 
199
 
 
200
Returns a sequence of the same kind as SEQUENCE with the same elements
 
201
except that all elements satisfying TEST are replaced with NEWITEM.  SEQUENCE
 
202
may be destroyed.
 
203
 
 
204
 
 
205
@end defun
 
206
 
 
207
@defun SOME (predicate sequence &rest more-sequences)
 
208
Package:LISP
 
209
 
 
210
Returns T if at least one of the elements in SEQUENCEs satisfies PREDICATE;
 
211
NIL otherwise.
 
212
 
 
213
 
 
214
@end defun
 
215
 
 
216
@defun MAKE-STRING (size &key (initial-element #\Space))
 
217
Package:LISP
 
218
 
 
219
Creates and returns a new string of SIZE length whose elements are all
 
220
INITIAL-ELEMENT.
 
221
 
 
222
 
 
223
@end defun
 
224
 
 
225
@defun NSUBSTITUTE (newitem olditem sequence &key (from-end nil) (test #'eql) test-not (start 0) (end (length sequence)) (count most-positive-fixnum) (key #'identity))
 
226
Package:LISP
 
227
 
 
228
Returns a sequence of the same kind as SEQUENCE with the same elements
 
229
except that OLDITEMs are replaced with NEWITEM.  SEQUENCE may be destroyed.
 
230
 
 
231
 
 
232
@end defun
 
233
 
 
234
@defun STRING-EQUAL (string1 string2 &key (start1 0) (end1 (length string1)) (start2 0) (end2 (length string2)))
 
235
Package:LISP
 
236
 
 
237
Given two strings (string1 and string2), and optional integers start1,
 
238
start2, end1 and end2, compares characters in string1 to characters in
 
239
string2 (using char-equal).
 
240
 
 
241
 
 
242
@end defun
 
243
 
 
244
@defun STRING-NOT-GREATERP (string1 string2 &key (start1 0) (end1 (length string1)) (start2 0) (end2 (length string2)))
 
245
Package:LISP
 
246
 
 
247
Similar to STRING<=, but ignores cases.
 
248
 
 
249
 
 
250
@end defun
 
251
 
 
252
@defun STRING> (string1 string2 &key (start1 0) (end1 (length string1)) (start2 0) (end2 (length string2)))
 
253
Package:LISP
 
254
 
 
255
If STRING1 is lexicographically greater than STRING2, then returns the
 
256
longest common prefix of the strings.  Otherwise, returns NIL.
 
257
 
 
258
 
 
259
@end defun
 
260
 
 
261
@defun STRINGP (x)
 
262
Package:LISP
 
263
 
 
264
Returns T if X is a string; NIL otherwise.
 
265
 
 
266
 
 
267
@end defun
 
268
 
 
269
@defun DELETE-IF (test sequence &key (from-end nil) (start 0) (end (length sequence)) (count most-positive-fixnum) (key #'identity))
 
270
Package:LISP
 
271
 
 
272
Returns a sequence formed by removing the elements satisfying TEST
 
273
destructively from SEQUENCE.
 
274
 
 
275
 
 
276
@end defun
 
277
 
 
278
@defun SIMPLE-STRING-P (x)
 
279
Package:LISP
 
280
 
 
281
Returns T if X is a simple string; NIL otherwise.
 
282
 
 
283
 
 
284
@end defun
 
285
 
 
286
@defun REMOVE-IF (test sequence &key (from-end nil) (start 0) (end (length sequence)) (count most-positive-fixnum) (key #'identity))
 
287
Package:LISP
 
288
 
 
289
Returns a copy of SEQUENCE with elements satisfying TEST removed.
 
290
 
 
291
 
 
292
@end defun
 
293
 
 
294
@defun HASH-TABLE-COUNT (hash-table)
 
295
Package:LISP
 
296
 
 
297
Returns the number of entries in the given Hash-Table.
 
298
 
 
299
 
 
300
@end defun
 
301
 
 
302
@defun ARRAY-DIMENSIONS (array)
 
303
Package:LISP
 
304
 
 
305
Returns a list whose elements are the dimensions of ARRAY
 
306
 
 
307
 
 
308
@end defun
 
309
 
 
310
@defun SUBSTITUTE-IF-NOT (new test sequence &key (from-end nil) (start 0) (end (length sequence)) (count most-positive-fixnum) (key #'identity))
 
311
Package:LISP
 
312
 
 
313
Returns a sequence of the same kind as SEQUENCE with the same elements
 
314
except that all elements not satisfying TEST are replaced with NEWITEM.
 
315
 
 
316
 
 
317
@end defun
 
318
 
 
319
@defun ADJUSTABLE-ARRAY-P (array)
 
320
Package:LISP
 
321
 
 
322
Returns T if ARRAY is adjustable; NIL otherwise.
 
323
 
 
324
 
 
325
@end defun
 
326
 
 
327
@defun SVREF (simple-vector index)
 
328
Package:LISP
 
329
 
 
330
Returns the INDEX-th element of SIMPLE-VECTOR.
 
331
 
 
332
 
 
333
@end defun
 
334
 
 
335
@defun VECTOR-PUSH-EXTEND (new-element vector &optional (extension (length vector)))
 
336
Package:LISP
 
337
 
 
338
Similar to VECTOR-PUSH except that, if the fill pointer gets too large,
 
339
extends VECTOR rather then simply returns NIL.
 
340
 
 
341
 
 
342
@end defun
 
343
 
 
344
@defun DELETE (item sequence &key (from-end nil) (test #'eql) test-not (start 0) (end (length sequence)) (count most-positive-fixnum) (key #'identity))
 
345
Package:LISP
 
346
 
 
347
Returns a sequence formed by removing the specified ITEM destructively from
 
348
SEQUENCE.
 
349
 
 
350
 
 
351
@end defun
 
352
 
 
353
@defun REMOVE (item sequence &key (from-end nil) (test #'eql) test-not (start 0) (end (length sequence)) (count most-positive-fixnum) (key #'identity))
 
354
Package:LISP
 
355
 
 
356
Returns a copy of SEQUENCE with ITEM removed.
 
357
 
 
358
 
 
359
@end defun
 
360
 
 
361
@defun STRING (x)
 
362
Package:LISP
 
363
 
 
364
Coerces X into a string.  If X is a string, then returns X itself.  If X is a
 
365
symbol, then returns X's print name.  If X is a character, then returns a one
 
366
element string containing that character.  Signals an error if X cannot be
 
367
coerced into a string.
 
368
 
 
369
 
 
370
@end defun
 
371
 
 
372
@defun STRING-UPCASE (string &key (start 0) (end (length string)))
 
373
Package:LISP
 
374
 
 
375
Returns a copy of STRING with all lower case characters converted to
 
376
uppercase.
 
377
 
 
378
 
 
379
@end defun
 
380
 
 
381
@defun GETHASH (key hash-table &optional (default nil))
 
382
Package:LISP
 
383
 
 
384
Finds the entry in HASH-TABLE whose key is KEY and returns the associated
 
385
value and T, as multiple values.  Returns DEFAULT and NIL if there is no
 
386
such entry.
 
387
 
 
388
 
 
389
@end defun
 
390
 
 
391
@defun MAKE-HASH-TABLE (&key (test 'eql) (size 1024) (rehash-size 1.5) (rehash-threshold 0.7))
 
392
Package:LISP
 
393
 
 
394
Creates and returns a hash table.
 
395
 
 
396
 
 
397
@end defun
 
398
 
 
399
@defun STRING/= (string1 string2 &key (start1 0) (end1 (length string1)) (start2 0) (end2 (length string2)))
 
400
Package:LISP
 
401
 
 
402
Returns NIL if STRING1 and STRING2 are character-wise CHAR=.  Otherwise,
 
403
returns the index to the longest common prefix of the strings.
 
404
 
 
405
 
 
406
@end defun
 
407
 
 
408
@defun STRING-GREATERP (string1 string2 &key (start1 0) (end1 (length string1)) (start2 0) (end2 (length string2)))
 
409
Package:LISP
 
410
 
 
411
Similar to STRING>, but ignores cases.
 
412
 
 
413
 
 
414
@end defun
 
415
 
 
416
@defun ELT (sequence index)
 
417
Package:LISP
 
418
 
 
419
Returns the INDEX-th element of SEQUENCE.
 
420
 
 
421
 
 
422
@end defun
 
423
 
 
424
@defun MAKE-ARRAY (dimensions &key (element-type t) initial-element (initial-contents nil) (adjustable nil) (fill-pointer nil) (displaced-to nil) (displaced-index-offset 0) static)
 
425
Package:LISP
 
426
 
 
427
Creates an array of the specified DIMENSIONS.  The default for INITIAL-
 
428
ELEMENT depends on ELEMENT-TYPE.
 
429
MAKE-ARRAY will always try to find the `best' array to
 
430
accommodate the element-type specified.   For example on a SUN element-type
 
431
(mod 1) --> bit
 
432
(integer 0 10) --> unsigned-char
 
433
(integer -3 10) --> signed-char
 
434
si::best-array-element-type is the function doing this.  It
 
435
is also used by the compiler, for coercing array element types.
 
436
If you are going to declare an array you should use the same
 
437
element type as was used in making it.  eg
 
438
(setq my-array (make-array 4 :element-type '(integer 0 10)))
 
439
(the (array (integer 0 10)) my-array)
 
440
    When wanting to optimize references to an array you need to
 
441
declare the array eg: (the (array (integer -3 10)) my-array) if ar
 
442
were constructed using the (integer -3 10) element-type.  You could of
 
443
course have used signed-char, but since the ranges may be
 
444
implementation dependent it is better to use -3 10 range.  MAKE-ARRAY
 
445
needs to do some calculation with the element-type if you don't
 
446
provide a primitive data-type.  One way of doing this in a machine
 
447
independent fashion:
 
448
 
 
449
  (defvar *my-elt-type* #.
 
450
      (array-element-type (make-array 1 :element-type '(integer -3 10))))
 
451
 
 
452
Then calls to (make-array n :element-type *my-elt-type*) will not have to go
 
453
through a type inclusion computation.  The keyword STATIC (GCL specific) if non
 
454
nil, will cause the array body to be non relocatable.
 
455
 
 
456
 
 
457
 
 
458
@end defun
 
459
 
 
460
@defun NSTRING-DOWNCASE (string &key (start 0) (end (length string)))
 
461
Package:LISP
 
462
 Returns STRING with all upper case
 
463
characters converted to lowercase.
 
464
 
 
465
 
 
466
@end defun
 
467
 
 
468
@defun ARRAY-IN-BOUNDS-P (array &rest subscripts)
 
469
Package:LISP
 
470
 Returns T if SUBSCRIPTS are valid subscripts for
 
471
ARRAY; NIL otherwise.
 
472
 
 
473
 
 
474
@end defun
 
475
 
 
476
@defun SORT  (sequence predicate &key (key #'identity))
 
477
Package:LISP
 
478
 Destructively sorts SEQUENCE.
 
479
PREDICATE should return non-NIL if its first argument is to precede
 
480
its second argument.
 
481
 
 
482
 
 
483
@end defun
 
484
 
 
485
@defun HASH-TABLE-P  (x)
 
486
Package:LISP
 
487
 
 
488
Returns T if X is a hash table object; NIL
 
489
otherwise.
 
490
 
 
491
 
 
492
@end defun
 
493
 
 
494
@defun COUNT-IF-NOT  (test sequence &key (from-end nil) (start 0) (end (length sequence)) (key #'identity))
 
495
Package:LISP
 
496
 
 
497
Returns the number of elements in SEQUENCE not satisfying TEST.
 
498
 
 
499
 
 
500
@end defun
 
501
 
 
502
@defun FILL-POINTER (vector)
 
503
Package:LISP
 
504
 
 
505
Returns the fill pointer of VECTOR.
 
506
 
 
507
 
 
508
@end defun
 
509
 
 
510
 
 
511
@defun ARRAYP (x)
 
512
Package:LISP
 
513
 
 
514
Returns T if X is an array; NIL otherwise.
 
515
 
 
516
 
 
517
@end defun
 
518
 
 
519
@defun REPLACE (sequence1 sequence2 &key (start1 0) (end1 (length sequence1)) (start2 0) (end2 (length sequence2)))
 
520
Package:LISP
 
521
 
 
522
Destructively modifies SEQUENCE1 by copying successive elements into it from
 
523
SEQUENCE2.
 
524
 
 
525
 
 
526
@end defun
 
527
 
 
528
@defun BIT-XOR (bit-array1 bit-array2 &optional (result-bit-array nil))
 
529
Package:LISP
 
530
 
 
531
Performs a bit-wise logical XOR on the elements of BIT-ARRAY1 and BIT-ARRAY2.
 
532
Puts the results into a new bit array if RESULT-BIT-ARRAY is NIL, into
 
533
BIT-ARRAY1 if RESULT-BIT-ARRAY is T, or into RESULT-BIT-ARRAY otherwise.
 
534
 
 
535
 
 
536
@end defun
 
537
 
 
538
@defun CLRHASH (hash-table)
 
539
Package:LISP
 
540
 
 
541
Removes all entries of HASH-TABLE and returns the hash table itself.
 
542
 
 
543
 
 
544
@end defun
 
545
 
 
546
@defun SUBSTITUTE-IF (newitem test sequence &key (from-end nil) (start 0) (end (length sequence)) (count most-positive-fixnum) (key #'identity))
 
547
Package:LISP
 
548
 
 
549
Returns a sequence of the same kind as SEQUENCE with the same elements
 
550
except that all elements satisfying TEST are replaced with NEWITEM.
 
551
 
 
552
 
 
553
@end defun
 
554
 
 
555
@defun MISMATCH (sequence1 sequence2 &key (from-end nil) (test #'eql) test-not (start1 0) (start2 0) (end1 (length sequence1)) (end2 (length sequence2)) (key #'identity))
 
556
Package:LISP
 
557
 
 
558
The specified subsequences of SEQUENCE1 and SEQUENCE2 are compared
 
559
element-wise.  If they are of equal length and match in every element, the
 
560
result is NIL.  Otherwise, the result is a non-negative integer, the index
 
561
within SEQUENCE1 of the leftmost position at which they fail to match; or, if
 
562
one is shorter than and a matching prefix of the other, the index within
 
563
SEQUENCE1 beyond the last position tested is returned.
 
564
 
 
565
 
 
566
@end defun
 
567
 
 
568
@defvr {Constant} ARRAY-TOTAL-SIZE-LIMIT 
 
569
Package:LISP
 
570
The exclusive upper bound on the total number of elements of an array.
 
571
 
 
572
 
 
573
@end defvr
 
574
 
 
575
@defun VECTOR-POP (vector)
 
576
Package:LISP
 
577
 
 
578
Attempts to decrease the fill-pointer of VECTOR by 1 and returns the element
 
579
pointed to by the new fill pointer.  Signals an error if the old value of
 
580
the fill pointer is 0.
 
581
 
 
582
 
 
583
@end defun
 
584
 
 
585
@defun SUBSTITUTE (newitem olditem sequence &key (from-end nil) (test #'eql) test-not (start 0) (end (length sequence)) (count most-positive-fixnum) (key #'identity))
 
586
Package:LISP
 
587
 
 
588
Returns a sequence of the same kind as SEQUENCE with the same elements
 
589
except that OLDITEMs are replaced with NEWITEM.
 
590
 
 
591
 
 
592
@end defun
 
593
 
 
594
@defun ARRAY-HAS-FILL-POINTER-P (array)
 
595
Package:LISP
 
596
 
 
597
Returns T if ARRAY has a fill pointer; NIL otherwise.
 
598
 
 
599
 
 
600
@end defun
 
601
 
 
602
@defun CONCATENATE (result-type &rest sequences)
 
603
Package:LISP
 
604
 
 
605
Returns a new sequence of the specified RESULT-TYPE, consisting of all
 
606
elements in SEQUENCEs.
 
607
 
 
608
 
 
609
@end defun
 
610
 
 
611
@defun VECTOR-PUSH (new-element vector)
 
612
Package:LISP
 
613
 
 
614
Attempts to set the element of ARRAY designated by its fill pointer to
 
615
NEW-ELEMENT and increments the fill pointer by one.  Returns NIL if the fill
 
616
pointer is too large.  Otherwise, returns the new fill pointer value.
 
617
 
 
618
 
 
619
@end defun
 
620
 
 
621
@defun STRING-TRIM (char-bag string)
 
622
Package:LISP
 
623
 
 
624
Returns a copy of STRING with the characters in CHAR-BAG removed from both
 
625
ends.
 
626
 
 
627
 
 
628
@end defun
 
629
 
 
630
@defun ARRAY-ELEMENT-TYPE (array)
 
631
Package:LISP
 
632
 
 
633
Returns the type of the elements of ARRAY
 
634
 
 
635
 
 
636
@end defun
 
637
 
 
638
@defun NOTANY (predicate sequence &rest more-sequences)
 
639
Package:LISP
 
640
 
 
641
Returns T if none of the elements in SEQUENCEs satisfies PREDICATE; NIL
 
642
otherwise.
 
643
 
 
644
 
 
645
@end defun
 
646
 
 
647
@defun BIT-NOT (bit-array &optional (result-bit-array nil))
 
648
Package:LISP
 
649
 
 
650
Performs a bit-wise logical NOT in the elements of BIT-ARRAY.
 
651
Puts the results into a new bit array if RESULT-BIT-ARRAY is NIL, into
 
652
BIT-ARRAY if RESULT-BIT-ARRAY is T, or into RESULT-BIT-ARRAY otherwise.
 
653
 
 
654
 
 
655
@end defun
 
656
 
 
657
@defun BIT-ORC1 (bit-array1 bit-array2 &optional (result-bit-array nil))
 
658
Package:LISP
 
659
 
 
660
Performs a bit-wise logical ORC1 on the elements of BIT-ARRAY1 and BIT-ARRAY2.
 
661
Puts the results into a new bit array if RESULT-BIT-ARRAY is NIL, into
 
662
BIT-ARRAY1 if RESULT-BIT-ARRAY is T, or into RESULT-BIT-ARRAY otherwise.
 
663
 
 
664
 
 
665
@end defun
 
666
 
 
667
@defun COUNT-IF (test sequence &key (from-end nil) (start 0) (end (length sequence)) (key #'identity))
 
668
Package:LISP
 
669
 
 
670
Returns the number of elements in SEQUENCE satisfying TEST.
 
671
 
 
672
 
 
673
@end defun
 
674
 
 
675
@defun MAP (result-type function sequence &rest more-sequences)
 
676
Package:LISP
 
677
 
 
678
FUNCTION must take as many arguments as there are sequences provided.  The 
 
679
result is a sequence such that the i-th element is the result of applying
 
680
FUNCTION to the i-th elements of the SEQUENCEs.
 
681
 
 
682
 
 
683
@end defun
 
684
 
 
685
@defvr {Constant} ARRAY-RANK-LIMIT 
 
686
Package:LISP
 
687
The exclusive upper bound on the rank of an array.
 
688
 
 
689
 
 
690
@end defvr
 
691
 
 
692
@defun COUNT (item sequence &key (from-end nil) (test #'eql) test-not (start 0) (end (length sequence)) (key #'identity))
 
693
Package:LISP
 
694
 
 
695
Returns the number of elements in SEQUENCE satisfying TEST with ITEM.
 
696
 
 
697
 
 
698
@end defun
 
699
 
 
700
@defun BIT-VECTOR-P (x)
 
701
Package:LISP
 
702
 
 
703
Returns T if X is a bit vector; NIL otherwise.
 
704
 
 
705
 
 
706
@end defun
 
707
 
 
708
@defun NSTRING-CAPITALIZE (string &key (start 0) (end (length string)))
 
709
Package:LISP
 
710
 
 
711
Returns STRING with the first character of each word converted to upper-case,
 
712
and remaining characters in the word converted to lower case.
 
713
 
 
714
 
 
715
@end defun
 
716
 
 
717
@defun ADJUST-ARRAY (array dimensions &key (element-type (array-element-type array)) initial-element (initial-contents nil) (fill-pointer nil) (displaced-to nil) (displaced-index-offset 0))
 
718
Package:LISP
 
719
 
 
720
Adjusts the dimensions of ARRAY to the given DIMENSIONS.  The default value
 
721
of INITIAL-ELEMENT depends on ELEMENT-TYPE.
 
722
 
 
723
 
 
724
@end defun
 
725
 
 
726
@defun SEARCH (sequence1 sequence2 &key (from-end nil) (test #'eql) test-not (start1 0) (start2 0) (end1 (length sequence1)) (end2 (length sequence2)) (key #'identity))
 
727
Package:LISP
 
728
 
 
729
A search is conducted for the first subsequence of SEQUENCE2 which
 
730
element-wise matches SEQUENCE1.  If there is such a subsequence in SEQUENCE2,
 
731
the index of the its leftmost element is returned; otherwise, NIL is
 
732
returned.
 
733
 
 
734
 
 
735
@end defun
 
736
 
 
737
@defun SIMPLE-BIT-VECTOR-P (x)
 
738
Package:LISP
 
739
 
 
740
Returns T if X is a simple bit-vector; NIL otherwise.
 
741
 
 
742
 
 
743
@end defun
 
744
 
 
745
@defun MAKE-SEQUENCE (type length &key initial-element)
 
746
Package:LISP
 
747
 
 
748
Returns a sequence of the given TYPE and LENGTH, with elements initialized
 
749
to INITIAL-ELEMENT.  The default value of INITIAL-ELEMENT depends on TYPE.
 
750
 
 
751
 
 
752
@end defun
 
753
 
 
754
@defun BIT-ORC2 (bit-array1 bit-array2 &optional (result-bit-array nil))
 
755
Package:LISP
 
756
 
 
757
Performs a bit-wise logical ORC2 on the elements of BIT-ARRAY1 and BIT-ARRAY2.
 
758
Puts the results into a new bit array if RESULT-BIT-ARRAY is NIL, into
 
759
BIT-ARRAY1 if RESULT-BIT-ARRAY is T, or into RESULT-BIT-ARRAY otherwise.
 
760
 
 
761
 
 
762
@end defun
 
763
 
 
764
@defun NREVERSE (sequence)
 
765
Package:LISP
 
766
 
 
767
Returns a sequence of the same elements as SEQUENCE but in reverse order.
 
768
SEQUENCE may be destroyed.
 
769
 
 
770
 
 
771
@end defun
 
772
 
 
773
@defvr {Constant} ARRAY-DIMENSION-LIMIT 
 
774
Package:LISP
 
775
The exclusive upper bound of the array dimension.
 
776
 
 
777
 
 
778
@end defvr
 
779
 
 
780
@defun NOTEVERY (predicate sequence &rest more-sequences)
 
781
Package:LISP
 
782
 
 
783
Returns T if at least one of the elements in SEQUENCEs does not satisfy
 
784
PREDICATE; NIL otherwise.
 
785
 
 
786
 
 
787
@end defun
 
788
 
 
789
@defun POSITION-IF-NOT (test sequence &key (from-end nil) (start 0) (end (length sequence)) (key #'identity))
 
790
Package:LISP
 
791
 
 
792
Returns the index of the first element in SEQUENCE that does not satisfy TEST;
 
793
NIL if no such element exists.
 
794
 
 
795
 
 
796
@end defun
 
797
 
 
798
@defun STRING-DOWNCASE (string &key (start 0) (end (length string)))
 
799
Package:LISP
 
800
 
 
801
Returns a copy of STRING with all upper case characters converted to
 
802
lowercase.
 
803
 
 
804
 
 
805
@end defun
 
806
 
 
807
@defun BIT (bit-array &rest subscripts)
 
808
Package:LISP
 
809
 
 
810
Returns the bit from BIT-ARRAY at SUBSCRIPTS.
 
811
 
 
812
 
 
813
@end defun
 
814
 
 
815
@defun STRING-NOT-LESSP (string1 string2 &key (start1 0) (end1 (length string1)) (start2 0) (end2 (length string2)))
 
816
Package:LISP
 
817
 
 
818
Similar to STRING>=, but ignores cases.
 
819
 
 
820
 
 
821
@end defun
 
822
 
 
823
@defun CHAR (string index)
 
824
Package:LISP
 
825
 
 
826
Returns the INDEX-th character in STRING.
 
827
 
 
828
 
 
829
@end defun
 
830
 
 
831
@defun AREF (array &rest subscripts)
 
832
Package:LISP
 
833
 
 
834
Returns the element of ARRAY specified by SUBSCRIPTS.
 
835
 
 
836
 
 
837
@end defun
 
838
 
 
839
@defun FILL (sequence item &key (start 0) (end (length sequence)))
 
840
Package:LISP
 
841
 
 
842
Replaces the specified elements of SEQUENCE all with ITEM.
 
843
 
 
844
 
 
845
@end defun
 
846
 
 
847
@defun STABLE-SORT (sequence predicate &key (key #'identity))
 
848
Package:LISP
 
849
 
 
850
Destructively sorts SEQUENCE.  PREDICATE should return non-NIL if its first
 
851
argument is to precede its second argument.
 
852
 
 
853
 
 
854
@end defun
 
855
 
 
856
@defun BIT-IOR (bit-array1 bit-array2 &optional (result-bit-array nil))
 
857
Package:LISP
 
858
 
 
859
Performs a bit-wise logical IOR on the elements of BIT-ARRAY1 and BIT-ARRAY2.
 
860
Puts the results into a new bit array if RESULT-BIT-ARRAY is NIL, into
 
861
BIT-ARRAY1 if RESULT-BIT-ARRAY is T, or into RESULT-BIT-ARRAY otherwise.
 
862
 
 
863
 
 
864
@end defun
 
865
 
 
866
@defun REMHASH (key hash-table)
 
867
Package:LISP
 
868
 
 
869
Removes any entry for KEY in HASH-TABLE.  Returns T if such an entry
 
870
existed; NIL otherwise.
 
871
 
 
872
 
 
873
@end defun
 
874
 
 
875
@defun VECTORP (x)
 
876
Package:LISP
 
877
 
 
878
Returns T if X is a vector; NIL otherwise.
 
879
 
 
880
 
 
881
@end defun
 
882
 
 
883
@defun STRING<= (string1 string2 &key (start1 0) (end1 (length string1)) (start2 0) (end2 (length string2)))
 
884
Package:LISP
 
885
 
 
886
If STRING1 is lexicographically less than or equal to STRING2, then returns
 
887
the longest common prefix of the two strings.  Otherwise, returns NIL.
 
888
 
 
889
 
 
890
@end defun
 
891
 
 
892
@defun SIMPLE-VECTOR-P (x)
 
893
Package:LISP
 
894
 
 
895
Returns T if X is a simple vector; NIL otherwise.
 
896
 
 
897
 
 
898
@end defun
 
899
 
 
900
@defun STRING-LEFT-TRIM (char-bag string)
 
901
Package:LISP
 
902
 
 
903
Returns a copy of STRING with the characters in CHAR-BAG removed from the
 
904
left end.
 
905
 
 
906
 
 
907
@end defun
 
908
 
 
909
@defun ARRAY-TOTAL-SIZE (array)
 
910
Package:LISP
 
911
 
 
912
Returns the total number of elements of ARRAY.
 
913
 
 
914
 
 
915
@end defun
 
916
 
 
917
@defun FIND-IF-NOT (test sequence &key (from-end nil) (start 0) (end (length sequence)) (key #'identity))
 
918
Package:LISP
 
919
 
 
920
Returns the index of the first element in SEQUENCE that does not satisfy
 
921
TEST; NIL if no such element exists.
 
922
 
 
923
 
 
924
@end defun
 
925
 
 
926
@defun DELETE-DUPLICATES (sequence &key (from-end nil) (test #'eql) test-not (start 0) (end (length sequence)) (key #'identity))
 
927
Package:LISP
 
928
 
 
929
Returns a sequence formed by removing duplicated elements destructively from
 
930
SEQUENCE.
 
931
 
 
932
 
 
933
@end defun
 
934
 
 
935
@defun REMOVE-DUPLICATES (sequence &key (from-end nil) (test #'eql) test-not (start 0) (end (length sequence)) (key #'identity))
 
936
Package:LISP
 
937
 
 
938
The elements of SEQUENCE are examined, and if any two match, one is discarded.
 
939
Returns the resulting sequence.
 
940
 
 
941
 
 
942
@end defun
 
943
 
 
944
@defun POSITION-IF (test sequence &key (from-end nil) (start 0) (end (length sequence)) (key #'identity))
 
945
Package:LISP
 
946
 
 
947
Returns the index of the first element in SEQUENCE that satisfies TEST; NIL
 
948
if no such element exists.
 
949
 
 
950
 
 
951
@end defun
 
952
 
 
953
@defun MERGE (result-type sequence1 sequence2 predicate &key (key #'identity))
 
954
Package:LISP
 
955
 
 
956
SEQUENCE1 and SEQUENCE2 are destructively merged into a sequence of type
 
957
RESULT-TYPE using PREDICATE to order the elements.
 
958
 
 
959
 
 
960
@end defun
 
961
 
 
962
@defun EVERY (predicate sequence &rest more-sequences)
 
963
Package:LISP
 
964
 
 
965
Returns T if every elements of SEQUENCEs satisfy PREDICATE; NIL otherwise.
 
966
 
 
967
 
 
968
@end defun
 
969
 
 
970
@defun REDUCE (function sequence &key (from-end nil) (start 0) (end (length sequence)) initial-value)
 
971
Package:LISP
 
972
 
 
973
Combines all the elements of SEQUENCE using a binary operation FUNCTION.
 
974
If INITIAL-VALUE is supplied, it is logically placed before the SEQUENCE.
 
975
 
 
976
 
 
977
@end defun
 
978
 
 
979
@defun STRING-LESSP (string1 string2 &key (start1 0) (end1 (length string1)) (start2 0) (end2 (length string2)))
 
980
Package:LISP
 
981
 
 
982
Similar to STRING<, but ignores cases.
 
983
 
 
984
 
 
985
@end defun