1 % Copyright (C) 2008 Bert Burgemeister
3 % Permission is granted to copy, distribute and/or modify this
4 % document under the terms of the GNU Free Documentation License,
5 % Version 1.2 or any later version published by the Free Software
6 % Foundation; with no Invariant Sections, no Front-Cover Texts and
7 % no Back-Cover Texts. For details see file COPYING.
10 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
11 \section{Input/Output
}
12 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
14 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
15 \subsection{Predicates
}
16 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
20 \IT{\arrGOO{(
\FU*
{STREAMP
} \VAR{ foo
})\\
21 (
\FU*
{PATHNAMEP
} \VAR{ foo
})\\
22 (
\FU*
{READTABLEP
} \VAR{ foo
})
}{.
}}
24 \retval{\T} if
\VAR{foo
} is of indicated type.
27 \IT{\arrGOO{(
\FU*
{INPUT-STREAM-P
} \VAR{ stream
})\\
28 (
\FU*
{OUTPUT-STREAM-P
} \VAR{ stream
})\\
29 (
\FU*
{INTERACTIVE-STREAM-P
} \VAR{ stream
})\\
30 (
\FU*
{OPEN-STREAM-P
} \VAR{ stream
})
}{.
}}
32 Return
\retval{\T} if
\VAR{stream
} is for input, for output,
33 interactive, or open, respectively.
36 \IT{(
\FU*
{PATHNAME-MATCH-P
} \VAR{path
} \VAR{wildcard
})
}
38 \retval{\T} if
\VAR{path
} matches
\VAR{wildcard
}.
41 \IT{(
\FU*
{WILD-PATHNAME-P
} \VAR{path
}
42 \OP{\Goo{\kwd{:host
}\XOR\kwd{:device
}\XOR
43 \kwd{:directory
}\XOR\kwd{:name
}\XOR\kwd{:type
}
44 \XOR\kwd{:version
}\XOR\NIL}})
}
46 Return
\retval{\T} if indicated component in
\VAR{path
} is
47 wildcard. (
\NIL\ indicates any component.)
53 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
55 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
59 \IT{(
\xorGOO{\FU*
{Y-OR-N-P
}\\
60 \FU*
{YES-OR-NO-P
}}{\
}} \Op{\VAR{control
} \OPn{\VAR{arg
}}})
}
62 Ask user a question and return
\retval{\T} or
\retval{\NIL}
63 depending on their answer. See p.\
\pageref{section:Format
},
64 \FU{format
}, for
\VAR{control
} and
\VAR{arg
}s.
67 \IT{(
\MC*
{WITH-STANDARD-IO-SYNTAX
} \OPn{\VAR{form
}})
}
69 Evaluate
\VAR{form
}s with standard behaviour of reader and
70 printer. Return
\retval{values of
\VAR{form
}s
}.
73 \IT{(
\xorGOO{\FU*
{READ
}\\
74 \FU*
{READ-PRESERVING-WHITESPACE
}}{\
}}
75 \OP{\DES{\VAR{stream
}}\DF{\V{*standard-input*
}} \OP{\VAR{eof-err
}\DF{\T}
76 \Op{\VAR{eof-val
}\DF{\NIL} \Op{\VAR{recursive
}\DF{\NIL}}}}})
}
78 Read printed representation of
\retval{object
}.
81 \IT{(
\FU*
{READ-FROM-STRING
} \VAR{string
} \OP{\VAR{eof-error
}\DF{\T}
82 \Op{\VAR{eof-val
}\DF{\NIL}}}\orGOO{%
83 \kwd{:start
}\VAR{ start
}\DF{\LIT{0}}\\
84 \kwd{:end
}\VAR{ end
}\DF{\NIL}\\
85 \kwd{:preserve-whitespace
}\VAR{ bool
}\DF{\NIL}}{\
}})
}
87 Return
\retval{object
} read from string and
\retvalii{position
} of
91 \IT{(
\FU*
{READ-DELIMITED-LIST
} \VAR{char
}
92 \OP{\DES{\VAR{stream
}}\DF{\V{*standard-input*
}}
93 \Op{\VAR{recursive
}\DF{\NIL}}})
}
95 Continue reading until encountering
\VAR{char
}. Return
\retval{list
}
96 of objects read. Signal error if no
\VAR{char
} is found in stream.
99 \IT{(
\FU*
{READ-CHAR
} \OP{\DES{\VAR{stream
}}\DF{\V{*standard-input*
}}
100 \OP{\VAR{eof-err
}\DF{\T} \Op{\VAR{eof-val
}\DF{\NIL}
101 \Op{\VAR{recursive
}\DF{\NIL}}}}})
}
103 Return
\retval{next character
} from
\VAR{stream
}.
106 \IT{(
\FU*
{READ-CHAR-NO-HANG
}
107 \OP{\DES{\VAR{stream
}}\DF{\V{*standard-input*
}}
108 \OP{\VAR{eof-error
}\DF{\T} \Op{\VAR{eof-val
}\DF{\NIL}
109 \Op{\VAR{recursive
}\DF{\NIL}}}}})
}
111 \retval{Next character
} from
\VAR{stream
} or
\retval{\NIL} if none
116 \OP{\VAR{mode
}\DF{\NIL} \OP{\DES{\VAR{stream
}}\DF{\V{*standard-input*
}}
117 \OP{\VAR{eof-error
}\DF{\T} \Op{\VAR{eof-val
}\DF{\NIL}
118 \Op{\VAR{recursive
}\DF{\NIL}}}}}})
}
120 Next, or if
\VAR{mode
} is
\T, next non-whitespace
121 \retval{character
}, or if
\VAR{mode
} is a character,
\retval{next instance
}
122 of it, from stream without removing it there.
125 \IT{(
\FU*
{UNREAD-CHAR
} \VAR{character
}
126 \Op{\DES{\VAR{stream
}}\DF{\V{*standard-input*
}}})
}
128 Put last
\FU{read-char
}ed
\VAR{character
} back into
\VAR{stream
}; return
132 \IT{(
\FU*
{READ-BYTE
} \DES{\VAR{stream
}} \OP{\VAR{eof-err
}\DF{\T}
133 \Op{\VAR{eof-val
}\DF{\NIL}}})
}
135 Return
\retval{next byte
} from binary
\VAR{stream
}.
138 \IT{(
\FU*
{READ-LINE
} \OP{\DES{\VAR{stream
}}\DF{\V{*standard-input*
}}
139 \OP{\VAR{eof-err
}\DF{\T} \Op{\VAR{eof-val
}\DF{\NIL}
140 \Op{\VAR{recursive
}\DF{\NIL}}}}})
}
142 Return a
\retval{line of text
} from
\VAR{stream
} and
143 \retvalii{\T} if line has been ended by end of file.
146 \IT{(
\FU*
{READ-SEQUENCE
} \DES{\VAR{sequence
}} \DES{\VAR{stream
}}
147 \Op{\kwd{:start
} \VAR{start
}\DF{\LIT{0}}}\Op{\kwd{:end
}
148 \VAR{end
}\DF{\NIL}})
}
150 Replace elements of
\VAR{sequence
} between
\VAR{start
} and
\VAR{end
}
151 with elements from
\VAR{stream
}. Return
\retval{index
} of
152 \VAR{sequence
}'s first unmodified
156 \IT{(
\FU*
{READTABLE-CASE
} \VAR{readtable
})
}
158 \retval{Case sensitivity attribute
} (one of
\kwd{:upcase
},
\kwd{:downcase
},
\kwd{:preserve
},
\kwd{:invert
}) of
\VAR{readtable
}.
\kwd{setf
}able.
161 \IT{(
\FU*
{COPY-READTABLE
} \OP{\VAR{from-readtable
}\DF{\V{*readtable*
}}
162 \Op{\VAR{to
}\DF{\NIL}}})
}
164 Return
\retval{copy of
\VAR{from-readtable
}}.
167 \IT{(
\FU*
{SET-SYNTAX-FROM-CHAR
} \VAR{to-char
} \VAR{from-char
}
168 \OP{\DES{\VAR{to-readtable
}}\DF{\V{*readtable*
}}
169 \Op{\VAR{from-readtable
}\DF{standard readtable
}}})
}
171 Copy syntax of
\VAR{from-char
} to
\VAR{to-readtable
}. Return
\retval{\T}.
174 \IT{\V*
{*readtable*
}}
179 \IT{\V*
{*read-base*
}\DF{\LIT{10}}}
181 Radix for reading
\kwd{integer
}s and
\kwd{ratio
}s.
184 \IT{\V*
{*read-default-float-format*
}\DF{\kwd{single-float
}}}
186 Floating point format to use when not indicated in the number read.
189 \IT{(
\FU*
{SET-MACRO-CHARACTER
} \VAR{char
} \VAR{function
}
190 \OP{\VAR{non-term-p
}\DF{\NIL}
191 \Op{\DES{\VAR{rt
}}\DF{\V{*readtable*
}}}})
}
193 Make
\VAR{char
} a macro character associated with
194 \VAR{function
}. Return
\retval{\T}.
197 \IT{(
\FU*
{GET-MACRO-CHARACTER
} \VAR{char
}
198 \Op{\VAR{rt
}\DF{\V{*readtable*
}}})
}
200 \retval{Reader macro function
} associated with
\VAR{char
}, and
201 \retvalii{\T} if
\VAR{char
} is a non-terminating macro character.
204 \IT{(
\FU*
{MAKE-DISPATCH-MACRO-CHARACTER
} \VAR{char
}
205 \OP{\VAR{non-term-p
}\DF{\NIL}
206 \Op{\VAR{rt
}\DF{\V{*readtable*
}}}})
}
208 Make
\VAR{char
} a dispatching macro character. Return
\retval{\T}.
211 \IT{(
\FU*
{SET-DISPATCH-MACRO-CHARACTER
} \VAR{char
} \VAR{sub-char
} \VAR{function
}
212 \Op{\DES{\VAR{rt
}}\DF{\V{*readtable*
}}})
}
214 Make
\VAR{function
} a dispatch function of
\VAR{char
} followed by
215 \VAR{sub-char
}. Return
\retval{\T}.
218 \IT{(
\FU*
{GET-DISPATCH-MACRO-CHARACTER
} \VAR{char
} \VAR{sub-char
}
219 \Op{\VAR{rt
}\DF{\V{*readtable*
}}})
}
221 \retval{Dispatch function
} associated with
\VAR{char
} followed by
\VAR{sub-char
}.
226 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
227 \subsection[Macro Chars
]{Macro Characters
}
228 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
232 \IT{\arrGOO{\KWD*
{;
}\OPn{\VAR{comment
}}\\
233 \KWD{\#
\boldmath$|$
}\OPn{\VAR{comment
}}\KWD{ \boldmath$|$\#
}}{.
}}
240 Initiate reading of a list.
243 \IT{\KWD{"
}}\index{""
}
245 Begin and end of a string.
248 \IT{\KWD*
{'
}\VAR{foo
}}
250 \retval{(
\SO{quote
} \NEV{\VAR{foo
}})
}.
253 \IT{\KWD*
{`
}(
\Op{\VAR{foo
}} \Op{\KWD*
{,
}\VAR{bar
}} \Op{\KWD*
{,@
}\VAR{baz
}}
254 \Op{\KWD*
{,.
}\DES{\VAR{quux
}}} \Op{\VAR{bing
}})
}
256 \SO{quote
} \VAR{foo
} and
\VAR{bing
}; evaluate
\VAR{bar
} and splice
257 the lists
\VAR{baz
} and
\VAR{quux
} into their elements.
260 \IT{\KWD{\#
\boldmath{$
\backslash$
}}\VAR{c
}}
264 \index{\#@\#$
\backslash$
}%
266 \IT{\KWD*
{\#b
},
\KWD*
{\#o
},
\KWD*
{\#x
},
\KWD{\#
}\VAR{n
}\KWD{R
}}
269 Binary, octal or hexadecimal number, or number of base
\VAR{n
}.
272 \IT{\KWD*
{\#C(
}\VAR{a b
}\kwd{)
}}
273 {Complex number
\VAR{a
}$+$
\VAR{b
}i.
276 \IT{\KWD*
{\#'
}\VAR{foo
}}
278 Return
\retval{function named
\VAR{foo
}}.
281 \IT{\KWD{\#
}\VAR{n
}\KWD{A
}\OPn{\VAR{sequence
}}}
284 \VAR{n
}-dimensional array
287 \IT{\KWD{\#
}\Op{\VAR{n
}}\kwd{(
}\OPn{\VAR{foo
}}\kwd{)
}}
290 Vector of some, or
\VAR{n
},
291 \VAR{foo
}s filled with last
\VAR{foo
} if necessary.
294 \IT{\KWD{\#
}\Op{\VAR{n
}}\kwd{*
}\OPn{\VAR{b
}}}
297 Bit vector of some, or
\VAR{n
},
298 \VAR{b
}s filled with last
\VAR{b
} if necessary.
301 \IT{\KWD*
{\#S(
}\VAR{type
} \Goos{\VAR{slot
} \VAR{value
}}\kwd{)
}}
303 Structure of
\VAR{type
}.
306 \IT{\KWD*
{\#:
}\VAR{foo
}}
308 Uninterned Symbol
\VAR{foo
}.
311 \IT{\KWD*
{\#.
}\VAR{form
}}
313 Read-time value of
\VAR{form
}.
316 \IT{\V*
{*read-eval*
}\DF{\T}}
318 If
\NIL, a
\kwd{reader-error
} is signalled by
\kwd{\#.
}.
321 \IT{\KWD{\#
}\VAR{label
}\kwd{=
} \VAR{foo
}}
324 Give value of
\VAR{foo
} a
\VAR{label
}.
327 \IT{\KWD{\#
}\VAR{label
}\kwd{\#
}}
330 \retval{Object labelled
\VAR{label
}}.
333 \IT{\KWD*
{\#P
}\VAR{foo
}}
338 \IT{\KWD{\#
\boldmath$<$
}}
341 Have the reader signal an error.
344 \IT{\KWD*
{\#+
}\VAR{feature-expression
} \VAR{form
}}
346 Means
\VAR{form
} if
\VAR{feature-expression
} returns
\T, means whitespace
350 \IT{\KWD*
{\#--
}\VAR{feature-expression
} \VAR{form
}}
352 Means
\VAR{form
} if
\VAR{feature-expression
} returns
\NIL, means whitespace
359 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
361 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
366 \IT{(
\xorGOO{\FU*
{PRIN1
}\\
370 \VAR{foo
} \Op{\DES{\VAR{stream
}}\DF{\V{*standard-output*
}}})
}
372 Print
\retval{\VAR{foo
}} to
\VAR{stream
} \FU{read
}ably,
373 \FU{read
}ably after a newline and followed by a space,
374 \FU{read
}ably after a newline, or human-readably without any extra
375 characters, respectively.
378 \IT{\arrGOO{(
\FU*
{PRIN1-TO-STRING
} \VAR{ foo
})\\
379 (
\FU*
{PRINC-TO-STRING
} \VAR{ foo
})
}{.
}}
381 Print
\VAR{foo
} to
\retval{\VAR{string
}} \FU{read
}ably or
382 human-readably, respectively.
385 \IT{(
\GFU*
{PRINT-OBJECT
} \VAR{object
} \DES{\VAR{stream
}})
}
387 Print
\retval{\VAR{object
}} to
\VAR{stream
}.
390 \IT{(
\FU*
{PRINT-UNREADABLE-OBJECT
} (
\VAR{foo
} \DES{\VAR{stream
}}
391 \Op{\kwd{:type
} \VAR{bool
}} \Op{\kwd{:identity
} \VAR{bool
}})
394 Enclosed in
\kwd{\#
\boldmath$<$
} and
\kwd{\boldmath$>$
}, print
395 \VAR{foo
} by means of
\VAR{form
}s. Return
\retval{\NIL}.
398 \IT{(
\FU*
{TERPRI
} \Op{\DES{\VAR{stream
}}\DF{\V{*standard-output*
}}})
}
400 Output a newline to
\VAR{stream
}. Return
\retval{\NIL}.
403 \IT{(
\FU*
{FRESH-LINE
})
404 \Op{\DES{\VAR{stream
}}\DF{\V{*standard-output*
}}}}
406 Output a newline to
\VAR{stream
} and return
\retval{\T} unless
\VAR{stream
}
407 is already at the start of a line.
410 \IT{(
\FU*
{WRITE-CHAR
} \VAR{char
}
411 \Op{\DES{\VAR{stream
}}\DF{\V{*standard-output*
}}})
}
413 Output
\retval{\VAR{char
}} to
\VAR{stream
}.
416 \IT{(
\xorGOO{\FU*
{WRITE-STRING
}\\
417 \FU*
{WRITE-LINE
}}{\
}} \VAR{string
}
418 \OP{\DES{\VAR{stream
}}\DF{\V{*standard-output*
}}}
419 \orGOO{\kwd{:start
} \VAR{ start
}\DF{\LIT{0}}\\
\kwd{:end
} \VAR{
422 Write
\retval{\VAR{string
}} to
\VAR{stream
} without/with a trailing newline,
426 \IT{(
\FU*
{WRITE-BYTE
} \VAR{byte
} \DES{\VAR{stream
}})
}
428 Write one
\retval{\VAR{byte
}} to
\VAR{stream
}.
431 \IT{(
\FU*
{WRITE-SEQUENCE
} \VAR{sequence
}
432 \DES{\VAR{stream
}} \orGOO{\kwd{:start
}\VAR{ start
}\DF{\LIT{0}}\\
433 \kwd{:end
} \VAR{ end
}\DF{\NIL}}{\
}})
}
435 Write elements of
\retval{\VAR{sequence
}} to
\VAR{stream
}.
438 \IT{(
\xorGOO{\FU*
{WRITE
}\\
439 \FU*
{WRITE-TO-STRING
}}{\
}} \VAR{foo
} \orGOO{%
440 \kwd{:array
} \VAR{ bool
}\\
441 \kwd{:base
} \VAR{ radix
}\\
442 \kwd{:case
} \xorGOO{\kwd{:upcase
}\\
444 \kwd{:capitalize
}}{.
}\\
445 \kwd{:circle
} \VAR{ bool
}\\
446 \kwd{:escape
} \VAR{ bool
}\\
447 \kwd{:gensym
} \VAR{ bool
}\\
448 \kwd{:length
} \VAR{ int
}\\
449 \kwd{:level
} \VAR{ int
}\\
450 \kwd{:lines
} \VAR{ int
}\\
451 \kwd{:miser-width
} \VAR{ int
}\\
452 \kwd{:pprint-dispatch
} \VAR{ dispatch-table
}\\
453 \kwd{:pretty
} \VAR{ bool
}\\
454 \kwd{:radix
} \VAR{ bool
}\\
455 \kwd{:readably
} \VAR{ bool
}\\
456 \kwd{:right-margin
} \VAR{ int
}\\
457 \kwd{:stream
} \DES{\VAR{stream
}}\DF{\V{*standard-output*
}}%
460 Print and return
\retval{\VAR{foo
}}, or print
\VAR{foo
} into
461 \retval{string
}, respectively, after dynamically setting printer variables
462 corresponding to keyword parameters (
\kwd{:
}\VAR{bar
} becoming
463 \kwd{*print-
}\VAR{bar
}\kwd{*
}). (
\kwd{:stream
} keyword with
\FU{write
} only.)
466 \IT{(
\xorGOO{\FU*
{PPRINT-FILL
}\\
467 \FU*
{PPRINT-LINEAR
}}{\
}}
468 \DES{\VAR{stream
}} \VAR{foo
} \OP{\VAR{parenthesis
}\DF{\T}
471 Print
\VAR{foo
} to
\VAR{stream
}. If
\VAR{foo
} is a list, print as
472 many elements per line as possible; or print either all elements on
473 one line or each on its own line, respectively. Return
\retval{\NIL}.
476 \IT{(
\FU*
{PPRINT-TABULAR
} \DES{\VAR{stream
}} \VAR{foo
}
477 \OP{\VAR{parenthesis
}\DF{\T} \Op{\VAR{noop
}
478 \Op{\VAR{n
}\DF{\LIT{16}}}}})
}
480 Print
\VAR{foo
} to
\VAR{stream
}. If
\VAR{foo
} is a list, print
481 elements in a table with column width
\VAR{n
} ems. Return
\retval{\NIL}.
484 \IT{(
\MC*
{PPRINT-LOGICAL-BLOCK
} (
\DES{\VAR{stream
}} \VAR{list
}
485 \orGOO{\xorGOO{\kwd{:prefix
} \VAR{ prefix
}\\
486 \kwd{:per-line-prefix
} \VAR{ per-line-prefix
}}{\
}}\\
487 \kwd{:suffix
} \VAR{ suffix
}\DF{\LIT{""
}}}{\
}})
488 \OPn{(
\kwd{declare
} \OPn{\NEV{\VAR{decl
}}})
} \OPn{\VAR{form
}})
}
490 Evaluate
\VAR{form
}s, which should print
\VAR{list
}, with
491 \VAR{stream
} locally bound to a pretty
492 printing stream which outputs to the original
\VAR{stream
}. If
493 \VAR{list
} is in fact not a list, it is printed by
\FU{write
}.
498 \IT{(
\MC*
{PPRINT-POP
})
}
500 Take
\retval{next element
} off
\VAR{list
}. If there is no remaining
501 list in
\VAR{list
}, or
\V{*print-length*
} or
\V{*print-circle*
} indicate
502 printing should end, send element together with an appropriate
503 indicator to
\VAR{stream
}.
506 \IT{(
\FU*
{PPRINT-TAB
} \Goo{\kwd{:line
}\XOR\kwd{:line-relative
}%
507 \XOR\kwd{:section
}\XOR\kwd{:section-relative
}} \VAR{c
}
508 \VAR{i
} \Op{\DES{\VAR{stream
}}\DF{\V{*standard-output*
}}})
}
510 Move cursor forward to column number $c + ki$, $k
\geq 0$ being as small
514 \IT{(
\FU*
{PPRINT-INDENT
} \xorGOO{%
516 \kwd{:current
}}{\
}} \VAR{n
}
517 \OP{\DES{\VAR{stream
}}\DF{\V{*standard-output*
}}})
}
519 Specify indentation for innermost logical block. Return
\retval{\NIL}.
522 \IT{(
\kwd*
{PPRINT-EXIT-IF-LIST-EXHAUSTED
})
}
524 If
\VAR{list
} is empty, terminate logical block. Return
525 \retval{\NIL} otherwise.
530 \IT{(
\FU*
{PPRINT-NEWLINE
} \xorGOO{%
534 \kwd{:mandatory
}}{\
}}
535 \OP{\DES{\VAR{stream
}}\DF{\V{*standard-output*
}}})
}
537 Print a conditional newline. Return
\retval{\NIL}.
540 \IT{(
\FU*
{SET-PPRINT-DISPATCH
} \VAR{type
} \VAR{function
}
541 \OP{\VAR{priority
}\DF{\LIT{0}}
542 \Op{\VAR{table
}\DF{\V{*print-pprint-dispatch*
}}}})
}
544 Install entry comprising
\VAR{function
} of arguments stream and
545 object to print; and
\VAR{priority
} as
546 \VAR{type
} into
\VAR{table
}. If
\VAR{function
}
547 is
\NIL, remove
\VAR{type
} from
\VAR{table
}. Return
\retval{\NIL}.
550 \IT{(
\FU*
{PPRINT-DISPATCH
} \VAR{foo
}
551 \Op{\VAR{table
}\DF{\V{*print-pprint-dispatch*
}}})
}
553 Highest priority
\retval{\VAR{function
}} associated with type of
557 \IT{(
\FU*
{COPY-PPRINT-DISPATCH
}
558 \Op{\VAR{table
}\DF{\V{*print-pprint-dispatch*
}}})
}
560 Return
\retval{copy of
\VAR{table
}}.
563 \IT{\V*
{*print-pretty*
}}
568 \IT{\V*
{*print-lines*
}\DF{\NIL}}
570 Number of lines to pretty-print.
573 \IT{\V*
{*print-right-margin*
}\DF{\NIL}}
575 Right margin width in ems while pretty-printing.
578 \IT{\V*
{*print-miser-width*
}}
580 Width below which a compact pretty-printing style is used.
583 \IT{\V*
{*print-case*
}\DF{\kwd{:upcase
}}}
585 Print symbol names all uppercase (
\kwd{:upcase
}), all lowercase
586 (
\kwd{:downcase
}), capitalized (
\kwd{:capitalize
}).
589 \IT{\V*
{*print-readably*
}\DF{\NIL}}
591 If
\T, print
\FU{read
}ably or signal error
592 \kwd{print-not-readable
}.
595 \IT{\V*
{*print-array*
}}
597 If
\T, print array
\FU{read
}ably.
600 \IT{\V*
{*print-level*
}\DF{\NIL}}
602 If integer, restrict printing of nested object to that depth.
605 \IT{\V*
{*print-circle*
}\DF{\NIL}}
607 If
\T, avoid indefinite recursion while printing circular
611 \IT{\V*
{*print-escape*
}\DF{\T}}
613 If
\NIL, do not print escape characters and package prefixes.
616 \IT{\V*
{*print-gensym*
}\DF{\T}}
618 If
\T, print
\kwd{:\#
} before uninterned symbols.
621 \IT{\V*
{*print-radix*
}\DF{\NIL}}
623 If
\T, print rationals with a radix indicator.
626 \IT{\V*
{*print-base*
}\DF{\LIT{10}}}
628 Radix for printing rationals, between
2 and
36.
631 \IT{\V*
{*print-length*
}\DF{\NIL}}
633 If integer, restrict printing of objects to that number per level.
636 \IT{\V*
{*print-pprint-dispatch*
}}
638 Current pretty print dispatch table.
641 \IT{\V*
{*read-suppress*
}\DF{\NIL}}
643 If
\T, reader is syntactically more tolerant.
650 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
652 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
653 \label{section:Format
}
657 \IT{(
\MC*
{FORMATTER
} \VAR{control
})
}
659 Return
\retval{function
} of stream and a
\kwd{\&rest
} argument applying
\FU{format
} to
660 stream,
\VAR{control
}, and the
\kwd{\&rest
} argument
661 returning
\NIL\ or any excess arguments.
664 \IT{(
\FU*
{FORMAT
} \Goo{\T\XOR\NIL\XOR\VAR{out-string
}\XOR\VAR{out-stream
}}
665 \VAR{control
} \OPn{\VAR{arg
}})
}
667 Output string
\VAR{control
} which may
668 contain
\kwd{\TLD} directives possibly taking some
669 \VAR{arg
}s. Alternatively,
\VAR{control
} can be a function returned
670 by
\MC{formatter
} which is then applied to
\VAR{out-stream
} and
\OPn{\VAR{arg
}}.
671 Output to
\VAR{out-string
},
\VAR{out-stream
}, or, if first
672 argument is
\T, to
\V{*standard-output*
}. Return
\retval{\NIL}. If
673 first argument is
\NIL, return
\retval{formatted output
}.
678 \IT{\KWD{\TLD}\Op{\VAR{min-col
}\DF{\LIT{0}} \Op{\KWD{,
}\VAR{col-inc
}\DF{\LIT{1}}
679 \Op{\KWD{,
}\VAR{min-pad
}\DF{\LIT{0}}
680 \Op{\KWD{,
}\VAR{pad-char
}\DF{\LIT{\#$
\backslash$Space
}}}}}}
681 \KWD{\Op{:
}\Op{@
}\Goo{A
\XOR S
}}}
683 Print argument of any type for consumption by humans/by the
684 reader, respectively. With
\kwd{@
}, add
\VAR{pad-char
}s on the left
685 rather than on the right. With
\kwd{:
} print
\NIL\ as
\LIT{()
} rather
689 \IT{\KWD{\TLD}\Op{\VAR{radix
}\DF{\LIT{10}} \Op{\KWD{,
}\VAR{width
}
690 \Op{\KWD{,
}\VAR{pad-char
}\DF{\LIT{\#$
\backslash$Space
}}
691 \Op{\KWD{,
}\VAR{comma-char
}\DF{\KWD{,
}}
692 \Op{\KWD{,
}\VAR{comma-interval
}\DF{\LIT{3}}}}}}}
695 Print argument as number; with
\KWD{:
}, group digits
696 \VAR{comma-interval
} each; with
\kwd{@
}, always prepend a sign.
699 \IT{\Goo{\KWD{\TLD R
}\XOR\KWD{\TLD :R
}\XOR\KWD{\TLD
700 @R
}\XOR\KWD{\TLD @:R
}}}
702 Take argument as number and print it as English cardinal number,
703 as English ordinal number, as Roman numeral, or as old Roman
704 numeral, respectively.
707 \IT{\KWD{\TLD}\Op{\VAR{width
}
708 \Op{\KWD{,
}\VAR{pad-char
}\DF{\LIT{\#$
\backslash$Space
}}
709 \Op{\KWD{,
}\VAR{comma-char
}\DF{\KWD{,
}}
710 \Op{\KWD{,
}\VAR{comma-interval
}\DF{\LIT{3}}}}}} \KWD{\Op{:
}\Op{@
}\Goo{D
\XOR
713 Print integer argument as number (decimal, binary, octal, or
714 hexadecimal, respectively). With
\kwd{:
} group digits
715 \VAR{comma-interval
} each; with
\kwd{@
}, always prepend a sign.
718 \IT{\KWD{\TLD}\Op{\VAR{width
} \Op{\KWD{,
}\VAR{dec-digits
} \Op{\KWD{,
}\VAR{shift
}\DF{\LIT{0}}
719 \Op{\KWD{,
}\VAR{overflow-char
}
720 \Op{\KWD{,
}\VAR{pad-char
}\DF{\LIT{\#$
\backslash$Space
}}}}}}}
723 Print argument as floating-point number. With
\kwd{@
}, always prepend a sign.
726 \IT{\KWD{\TLD}\Op{\VAR{width
} \Op{\KWD{,
}\VAR{int-digits
} \Op{\KWD{,
}\VAR{exp-digits
}
727 \Op{\KWD{,
}\VAR{scale-factor
}\DF{\LIT{1}} \Op{\KWD{,
}\VAR{overflow-char
}
728 \Op{\KWD{,
}\VAR{pad-char
}\DF{\LIT{\#$
\backslash$Space
}}
729 \Op{\KWD{,
}\VAR{exp-char
}}}}}}}}
730 \KWD{\Op{@
}\Goo{E
\XOR G
}}}
732 Print argument as floating-point number with
\VAR{int-digits
}
733 before decimal point and
\VAR{exp-digits
} in the
734 exponent. With
\KWD{\TLD G
}, chose either
\KWD{\TLD E
} or
\KWD{\TLD F
}. With
\KWD{@
}, always prepend a sign.
737 \IT{\Goo{\KWD{\TLD C
}\XOR\KWD{\TLD :C
}\XOR\KWD{\TLD
738 @C
}\XOR\KWD{\TLD @:C
}}}
740 Print, spell out, print in
\kwd{\#$
\backslash$
} syntax, or tell how to type, respectively, argument as
741 (possibly non-printing) character.
745 \KWD{\TLD(
}\VAR{text
}\KWD{\TLD)
}\XOR
746 \KWD{\TLD:(
}\VAR{text
}\KWD{\TLD)
}\XOR
747 \KWD{\TLD @(
}\VAR{text
}\KWD{\TLD)
}\XOR
748 \KWD{\TLD:@(
}\VAR{text
}\KWD{\TLD)
}}}
750 Convert to lowercase, convert first letter of each word to
751 uppercase, capitalize first word and convert
752 the rest to lowercase, or convert to uppercase, respectively.
755 \IT{\Goo{\KWD{\TLD P
}\XOR\KWD{\TLD:P
}
756 \XOR\KWD{\TLD @P
}\XOR\KWD{\TLD:@P
}}}
758 If argument
\kwd{eql
} 1 print nothing, otherwise print
\LIT{s
};
759 do the same after backing up one argument; if argument
\kwd{eql
} 1
760 print
\LIT{y
}, otherwise print
\LIT{ies
}, do the same after
761 backing up one argument, respectively.
764 \IT{\Goo{\KWD{\TLD\%
}\XOR\KWD{\TLD}\VAR{n
}\KWD{\%
}}}
766 Print one or
\VAR{n
} newline(s).
769 \IT{\Goo{\KWD{\TLD\&
}\XOR\KWD{\TLD}\VAR{n
}\KWD{\&
}}}
771 Print one or
\VAR{n
} newline(s) unless output stream is at the
775 \IT{\Goo{\KWD{\TLD}\_\XOR\KWD{\TLD:
}\_\XOR\KWD{\TLD@
}\_\XOR\KWD{\TLD}:@
\_}}
777 Print newline like
\kwd{pprint-newline
} with argument
778 \kwd{:linear
},
\kwd{:fill
},
\kwd{:miser
}, or
\kwd{:mandatory
}, respectively.
781 \IT{\KWD{\TLD}\Op{\KWD{@
}}$
\hookleftarrow$
}
783 (Tilde-newline) Ignore newline and following
784 whitespace. With
\kwd{@
}, ignore only newline.
787 \IT{\Goo{\KWD{\TLD\boldmath$|$
}\XOR\KWD{\TLD}\VAR{n
}\KWD{\boldmath$|$
}}}
789 Print one or
\VAR{n
} page separator(s).
792 \IT{\Goo{\KWD{\TLD\TLD}\XOR\KWD{\TLD}\VAR{n
}\KWD{\TLD}}}
794 Print one or
\VAR{n
} tilde(s).
797 \IT{\KWD{\TLD}\Op{\VAR{min-col
}\DF{\LIT{0}}
798 \Op{\KWD{,
}\VAR{col-inc
}\DF{\LIT{1}}
799 \Op{\KWD{,
}\VAR{min-pad
}\DF{\LIT{0}}
800 \Op{\KWD{,
}\VAR{pad-char
}\DF{\LIT{\#$
\backslash$Space
}}}}}}
801 \KWD{\Op{:
}\Op{@
}\boldmath{$<$
}}
802 \Op{\VAR{text
}\KWD{\TLD}\VAR{a
},
\VAR{b
}\kwd{:;
}}
803 \Goos{\VAR{text
}\KWD{\TLD;
}} \KWD{\TLD\boldmath{$>$
}}}
805 Justify text produced by
\VAR{text
}s in a field of at least
806 \VAR{min-col
} columns.
809 \IT{\KWD{\TLD}\Op{\VAR{c
}\Op{\KWD{,
}\VAR{i
}}}\Op{\KWD{:
}}\Op{\KWD{@
}}\KWD{T
}}
811 Move cursor forward to column number $c + ki$, $k
\geq 0$ being as small
815 \IT{\Goo{\KWD{\TLD}\Op{\VAR{n
}\DF{\LIT{0}}}\kwd{I
}\XOR\KWD{\TLD}\Op{\VAR{n
}\DF{\LIT{0}}}\kwd{:I
}}}
817 Same as (
\kwd{pprint-indent
} \kwd{:block
} \VAR{n
}) or
818 (
\kwd{pprint-indent
} \kwd{:current
} \VAR{n
}), respectively.
821 \IT{\KWD{\TLD}\Op{\VAR{n
}\DF{\LIT{0}}}\Op{\KWD{:
}}\Op{\KWD{@
}}\KWD{*
}}
823 Jump
\VAR{n
} arguments forward, or, with
\kwd{:
}, backward. With
824 \kwd{@
}, jump to argument
\VAR{n
}.
827 \IT{\KWD{\TLD}\Op{\VAR{limit
}}\Op{\KWD{{:
}}\Op{\kwd{@
}}}%
828 \KWD{\boldmath{$\
{$
}}\VAR{text
}\KWD{\TLD\boldmath{$\
}$
}}}
830 \VAR{text
} is used repeatedly, up to
\VAR{limit
}, as control
831 string for every element of argument, which should be a list. With
832 \kwd{@
}, take all remaining arguments. With
\kwd{:
}, argument should be
833 a list of sublists. At each iteration step the elements of a
834 sublist can be used by
\VAR{str
}.
839 Leave immediately
\kwd{\TLD\boldmath{$<$
} \TLD\boldmath{$>$
}} or
840 \kwd{\TLD\boldmath{$\
{$
} \TLD\boldmath{$\
}$
}}.
843 \IT{\KWD{\TLD}\Op{\VAR{i
}}\Op{\KWD{:
}}\Op{\KWD{@
}}\KWD{[}\Goos{\VAR{text
}\KWD{\TLD;
}}\KWD{\TLD]}}
845 The
\VAR{text
}s are clauses the argumenth (or the
\VAR{i
}th if given) of which is chosen. With
846 \kwd{:
}, the argument is boolean and takes first
\VAR{text
} for
\NIL\ and
847 second
\VAR{text
} for
\T.
850 \IT{\KWD{\TLD\Op{@
}?
}}
852 Process two arguments as format string and argument list. With
853 \kwd{@
}, take one argument as format string and use then the
854 original argument list
857 \IT{\KWD{\TLD\Op{:
}\Op{@
}/
}\VAR{function
}\KWD{/
}}
859 Call
\VAR{function
} with arguments stream, format-ar\-gu\-ment,
860 bool-colon, and bool-at for printing format-argument.
863 \IT{\KWD{\TLD\Op{:
}\Op{@
}W
}}
865 Print obeying every printer control variable. With
\kwd{:
},
866 pretty-print. With
\kwd{@
}, print without limits on length or depth.
871 (Replacing one of the comma-separated prefix parameters) Take next
872 argument as prefix parameter.
877 (Replacing one of the comma-separated prefix parameters) Take as
878 prefix parameter the number of remaining unprocessed arguments.
886 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
888 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
892 \IT{(
\FU*
{OPEN
} \VAR{path
}
893 \orGOO{\kwd{:direction
} \xorGOO{\kwd{:input
}\\
896 \kwd{:probe
}}{\
}}\DF{\kwd{:input
}}\\
897 \kwd{:element-type
} \VAR{ type
}\DF{\kwd{character
}}\\
899 \xorGOO{\kwd{:new-version
}\\
902 \kwd{:rename-and-delete
}\\
907 \kwd{:if-does-not exist
} \xorGOO{\kwd{:error
}\\
910 \kwd{:external-format
} \VAR{format
}\DF{\kwd{:default
}}%
913 Open
\retval{stream to
\VAR{path
}}.
916 \IT{(
\FU*
{CLOSE
} \DES{\VAR{stream
}} \Op{\kwd{:abort
}
917 \VAR{bool
}\DF{\NIL}})
}
919 Close
\VAR{stream
}. Return
\retval{\T} if
\VAR{stream
} had been
920 open. If
\kwd{:abort
} is
\T, delete associated file.
923 \IT{(
\FU*
{MAKE-STRING-OUTPUT-STREAM
} \Op{\kwd{:element-type
}
924 \VAR{type
}\DF{\kwd{character
}}})
}
926 Return a
\retval{string stream
} accepting characters.
929 \IT{(
\FU*
{GET-OUTPUT-STREAM-STRING
} \DES{\VAR{string-stream
}})
}
931 Clear and return as a
\retval{string
} characters on
\VAR{string-stream
}.
934 \IT{(
\FU*
{MAKE-CONCATENATED-STREAM
} \OPn{\VAR{stream
}})
}
936 Return
\retval{concatenated stream
}.
939 \IT{(
\FU*
{CONCATENATED-STREAM-STREAMS
} \VAR{concatenated-stream
})
}
941 Return
\retval{list of streams
} \VAR{concatenated-stream
} still
945 \IT{(
\FU*
{MAKE-BROADCAST-STREAM
} \OPn{\VAR{stream
}})
}
947 Return
\retval{broadcast stream
}.
950 \IT{(
\FU*
{BROADCAST-STREAM-STREAMS
} \VAR{broadcast-stream
})
}
952 Return
\retval{list of streams
} \VAR{broadcast-stream
} is
956 \IT{(
\FU*
{MAKE-ECHO-STREAM
} \VAR{input-stream
} \VAR{output-stream
})
}
958 Place
\retval{echo stream
} between
\VAR{input-stream
} and
962 \IT{\arrGOO{(
\FU*
{ECHO-STREAM-INPUT-STREAM
}\VAR{ echo-stream
})\\
963 (
\FU*
{ECHO-STREAM-OUTPUT-STREAM
}\VAR{ echo-stream
})
}{.
}}
965 Return
\retval{stream
} \VAR{echo-stream
} receives from or sends
969 \IT{(
\FU*
{MAKE-STRING-INPUT-STREAM
} \VAR{string
}
970 \orGOO{\kwd{:start
}\VAR{ start
}\\
971 \kwd{:end
} \VAR{ end
}}{\
}})
}
973 Return
\retval{stream
} supplying the characters from
\VAR{string
}.
976 \IT{(
\FU*
{MAKE-SYNONYM-STREAM
} \VAR{symbol
})
}
978 Return
\retval{synonym stream
}.
981 \IT{(
\FU*
{SYNONYM-STREAM-SYMBOL
} \VAR{synonym-stream
})
}
983 Return
\retval{symbol
} of
\VAR{synonym-stream
}.
986 \IT{(
\FU*
{MAKE-TWO-WAY-STREAM
} \VAR{input-stream
}
987 \VAR{output-stream
})
}
988 {Return
\retval{two-way stream
}.
991 \IT{\arrGOO{(
\FU*
{TWO-WAY-STREAM-INPUT-STREAM
} \VAR{
993 (
\FU*
{TWO-WAY-STREAM-OUTPUT-STREAM
} \VAR{ two-way-stream
})
}{.
}}
995 Return
\retval{stream
} \VAR{two-way-stream
} receives from or sends
999 \IT{(
\FU*
{LISTEN
} \Op{\VAR{stream
}\DF{\V{*standard-input*
}}})
}
1001 \retval{\T} if there is a character in input
\VAR{stream
}.
1004 \IT{(
\FU*
{CLEAR-INPUT
}
1005 \Op{\DES{\VAR{stream
}}\DF{\V{*standard-input*
}}})
}
1007 Clear input from
\VAR{stream
}, return
\retval{\NIL}.
1010 \IT{(
\xorGOO{\FU*
{CLEAR-OUTPUT
}\\
1011 \FU*
{FORCE-OUTPUT
}\\
1012 \FU*
{FINISH-OUTPUT
}}{\
}}
1013 \Op{\DES{\VAR{stream
}}\DF{\V{*standard-output*
}}})
}
1015 End output to
\VAR{stream
} and return
\retval{\NIL} immediately,
1016 after initiating flushing of buffers, or after flushing of buffers,
1020 \IT{(
\MC*
{WITH-OPEN-STREAM
} (
\VAR{foo
} \DES{\VAR{stream
}})
1021 \OPn{(
\kwd{declare
} \OPn{\NEV{\VAR{decl
}}})
} \OPn{\VAR{form
}})
}
1023 Evaluate
\VAR{form
}s with
\VAR{foo
} locally bound to
1024 \VAR{stream
}. Return
\retval{values of
\VAR{form
}s
}.
1027 \IT{(
\MC*
{WITH-INPUT-FROM-STRING
} (
\VAR{foo
} \VAR{string
}
1028 \orGOO{\kwd{:index
} \DES{\VAR{index
}}\\
1029 \kwd{:start
} \VAR{ start
}\\
1030 \kwd{:end
} \VAR{ end
}}{\
}})
\OPn{(
\kwd{declare
}
1031 \OPn{\NEV{\VAR{decl
}}})
} \OPn{\VAR{form
}})
}
1033 Evaluate
\VAR{form
}s with
\VAR{foo
} locally bound to input stream
1034 from
\VAR{string
}.
\VAR{index
} contains the reading position in
1035 \VAR{string
} after leaving. Return
\retval{values of
\VAR{form
}s
}.
1038 \IT{(
\MC*
{WITH-OUTPUT-TO-STRING
} (
\VAR{foo
}
1039 \Op{\DES{\VAR{string
}}\DF{\NIL}} \Op{\kwd{:element-type
}
1040 \VAR{type
}\DF{\kwd{character
}}})
\OPn{(
\kwd{declare
}
1041 \OPn{\NEV{\VAR{decl
}}})
} \OPn{\VAR{form
}})
}
1043 Evaluate
\VAR{form
}s with
\VAR{foo
} locally bound to output
1044 stream. Append output to
\VAR{string
} and return
\retval{value of
1045 \VAR{foo
}} if
\VAR{string
} is given. Return
\retval{string
1046 containing output
} otherwise.
1049 \IT{(
\FU*
{STREAM-EXTERNAL-FORMAT
} \VAR{stream
})
}
1051 \retval{External file format designator
}.
1054 \IT{\V*
{*terminal-io*
}}
1056 Bidirectional stream to user terminal.
1059 \IT{\arrGOO{\V*
{*standard-input*
}\\
1060 \V*
{*standard-output*
}\\
1061 \V*
{*error-output*
}}{.
}}
1063 Standard input stream, standard output stream,
1064 or standard error output stream, respectively.
1067 \IT{\arrGOO{\V*
{*debug-io*
}\\
1068 \V*
{*query-io*
}}{.
}}
1070 Streams for debugging and user interaction.
1076 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
1078 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
1082 \IT{(
\FU*
{MAKE-PATHNAME
}
1083 \orGOO{\kwd{:host
} \VAR{ host
}\\
1084 \kwd{:device
} \VAR{ dev
}\\
1085 \kwd{:directory
} \VAR{ dir
}\\
1086 \kwd{:name
} \VAR{ name
}\\
1087 \kwd{:type
} \VAR{ type
}\\
1088 \kwd{:version
} \VAR{ ver
}\\
1089 \kwd{:defaults
} \VAR{ path
}\\
1091 \Goo{\kwd{:local
}\XOR\kwd{:common
}}\DF{\kwd{:local
}}}}{\
}})
}
1093 Construct
\retval{pathname
}.
1096 \IT{(
\FU*
{MERGE-PATHNAMES
} \VAR{pathname
}
1097 \OP{\VAR{default-pathname
}\DF{\V{*default-pathname-defaults*
}}
1098 \Op{\VAR{version
}\DF{\kwd{:newest
}}}})
}
1100 Return
\retval{\VAR{pathname
}} after filling in missing parts from defaults.
1103 \IT{\V*
{*default-pathname-defaults*
}}
1105 Pathname to use if one is needed but none supplied.
1108 \IT{(
\FU*
{PATHNAME
} \VAR{path
})
}
1110 \retval{Pathname
} of
\VAR{path
}.
1113 \IT{(
\FU*
{ENOUGH-NAMESTRING
} \VAR{path
}
1114 \Op{\VAR{root-path
}\DF{\V{*default-pathname-defaults*
}}})
}
1116 Return
\retval{minimal path string
} to sufficiently describe path relative to
\VAR{root-path.
}
1119 \IT{\arrGOO{(
\FU*
{NAMESTRING
}\VAR{ path
})\\
1120 (
\FU*
{FILE-NAMESTRING
}\VAR{ path
})\\
1121 (
\FU*
{DIRECTORY-NAMESTRING
}\VAR{ path
})\\
1122 (
\FU*
{HOST-NAMESTRING
}\VAR{ path
})
}{.
}}
1124 Return string representing
\retval{full pathname
};
\retval{name, type, and version
};
1125 \retval{directory name
}; or
\retval{host name
}, respectively, of
\VAR{path
}.
1128 \IT{(
\FU*
{PARSE-NAMESTRING
} \VAR{foo
} \OP{\VAR{host
}
1129 \Op{\VAR{default-pathname
}\DF{\V{*default-pathname-defaults*
}}}}
1130 \orGOO{\kwd{:start
} \VAR{ start
}\DF{\LIT{0}}\\
1131 \kwd{:end
} \VAR{ end
}\DF{\NIL}\\
1132 \kwd{:junk-allowed
} \VAR{ bool
}\DF{\NIL}}{\
}})
}
1134 Return
\retval{pathname
} converted from
1135 string, pathname, or stream
\VAR{foo
}; and
\retvalii{position
}
1136 where parsing stopped.
1139 \IT{(
\xorGOO{\FU*
{PATHNAME-HOST
}\\
1140 \FU*
{PATHNAME-DEVICE
}\\
1141 \FU*
{PATHNAME-DIRECTORY
}\\
1142 \FU*
{PATHNAME-NAME
}\\
1143 \FU*
{PATHNAME-TYPE
}\\
1144 \FU*
{PATHNAME-VERSION
}}{\
}}
1146 \Op{\kwd{:case
} \xorGOO{\kwd{:local
}\\
1147 \kwd{:common
}}{\
}}\DF{\kwd{:local
}}})
}
1149 Return
\retval{pathname component
}.
1152 \IT{(
\FU*
{LOGICAL-PATHNAME
} \VAR{path
})
}
1154 \retval{Logical name
} of
\VAR{path
}.
1157 \IT{(
\FU*
{TRANSLATE-PATHNAME
} \VAR{path-a
} \VAR{path-b
}
1160 Translate
\VAR{path-a
} from wildcard
\VAR{path-b
} into wildcard
1161 \VAR{path-c
}. Return
\retval{new path
}.
1164 \IT{(
\FU*
{LOGICAL-PATHNAME-TRANSLATIONS
} \VAR{host
})
}
1166 \retval{\VAR{host
}'s list of translations
}.
1169 \IT{(
\FU*
{LOAD-LOGICAL-PATHNAME-TRANSLATIONS
} \VAR{host
})
}
1171 Load
\VAR{host
}'s translations. Return
\retval{\NIL} if already
1172 loaded, return
\retval{\T} if successful.
1175 \IT{(
\FU*
{TRANSLATE-LOGICAL-PATHNAME
} \VAR{path
})
}
1177 Physical
\retval{pathname
} of
\VAR{path
}.
1180 \IT{\arrGOO{(
\FU*
{PROBE-FILE
} \VAR{ file
})\\
1181 (
\FU*
{TRUENAME
} \VAR{ file
})
}{.
}}
1183 \retval{Canonical name
} of
\VAR{file
}. If
\VAR{file
} does not exist,
1184 return
\retval{\NIL}/signal error, respectively.
1187 \IT{(
\FU*
{FILE-WRITE-DATE
} \VAR{file
})
}
1189 \retval{Time
} at which
\VAR{file
} was last written.
1192 \IT{(
\FU*
{FILE-AUTHOR
} \VAR{file
})
}
1194 Return
\retval{name of
\VAR{file
} owner
}.
1197 \IT{(
\FU*
{FILE-LENGTH
} \VAR{stream
})
}
1199 Return
\retval{length of
\VAR{stream
}}.
1202 \IT{(
\FU*
{FILE-POSITION
} \VAR{stream
} \Op{\xorGOO{\kwd{:start
}\\
1204 \VAR{position
}}{\
}}})
}
1206 Return
\retval{position within stream
}, or set it to
1207 \retval{\VAR{position
}} and return
\retval{\T} on success.
1210 \IT{(
\FU*
{FILE-STRING-LENGTH
} \VAR{stream
} \VAR{foo
})
}
1212 \retval{Length
} \VAR{foo
} would have in
\VAR{stream
}.
1215 \IT{(
\FU*
{RENAME-FILE
} \VAR{foo
} \VAR{bar
})
}
1217 Rename file
\VAR{foo
} to
\VAR{bar
}. Unspecified parts of path
1218 \VAR{bar
} default to those of
\VAR{foo
}. Return
\retval{new
1219 pathname
},
\retvalii{old file name
}, and
\retvaliii{new file name
}.
1222 \IT{(
\FU*
{DELETE-FILE
} \VAR{file
})
}
1224 Delete
\VAR{file
}, return
\retval{\T}.
1227 \IT{(
\FU*
{DIRECTORY
} \VAR{path
})
}
1229 Return
\retval{list of pathnames
}.
1232 \IT{(
\FU*
{ENSURE-DIRECTORIES-EXIST
} \VAR{path
} \Op{\kwd{:verbose
}
1235 Create parts of
\retval{\VAR{path
}} if necessary. Second return value is
1236 \retvalii{\T} if something has been created.
1239 \IT{(
\MC*
{WITH-OPEN-FILE
} (
\VAR{stream
} \VAR{path
}
1240 \OPn{\VAR{open-arg
}})
\OPn{(
\kwd{declare
} \OPn{\NEV{\VAR{decl
}}})
}
1243 Use
\FU*
{OPEN
} with
\VAR{open-arg
}s to temporarily
1244 create
\VAR{stream
} to
\VAR{path
}; return
\retval{values of
\VAR{form
}s
}.
1247 \IT{(
\FU*
{USER-HOMEDIR-PATHNAME
} \Op{\VAR{host
}})
}
1249 User's
\retval{home directory
}.
1257 % LocalWords: ies argumenth ar gu ment