User Tools


Function FORMAT

Syntax

  • format destination control-string &rest argsresult

Arguments and Values

Description

format produces formatted output by outputting the characters of control-string and observing that a tilde introduces a directive. The character after the tilde, possibly preceded by prefix parameters and modifiers, specifies what kind of formatting is desired. Most directives use one or more elements of args to create their output.

If destination is a string, a stream, or t, then the result is nil. Otherwise, the result is a string containing the "output".

format is useful for producing nicely formatted text, producing good-looking messages, and so on. format can generate and return a string or output to destination.

For details on how the control-string is interpreted, see section {\secref\FormattedOutput}.

Examples

None.

Affected By

Exceptional Situations

If destination is a string with a fill pointer, the consequences are undefined if destructive modifications are performed directly on the string during the dynamic extent of the call.

See Also

Notes

None.

\issue{FORMAT-STRING-ARGUMENTS:SPECIFY} \issue{STRING-OUTPUT-STREAM-BASHING:UNDEFINED}