CLCS
Constant Variable

t

Constant Value

t.

Description

The boolean representing true, and the canonical generalized boolean representing true. Although any object other than nil is considered true, t is generally used when there is no special reason to prefer one such object over another.

The symbol t is also sometimes used for other purposes as well. For example, as the name of a class, as a designator (e.g., a stream designator) or as a special symbol for some syntactic reason (e.g., in case and typecase to label the otherwise-clause).

Examples

 t ⇒  T 
 (eq t 't) ⇒  true
 (find-class 't) ⇒  #<CLASS T 610703333>
 (case 'a (a 1) (t 2)) ⇒  1
 (case 'b (a 1) (t 2)) ⇒  2
 (prin1 'hello t)
 |>  HELLO
⇒  HELLO

See Also

NIL

Backlinks

*print-readably*, adjust-array, and, and, arithmetic-error, array, atom, base-char, base-string, bignum, bit-and, bit-andc1, bit-andc2, bit-eqv, bit-ior, bit-nand, bit-nor, bit-not, bit-orc1, bit-orc2, bit-xor, bit-vector, bit, boolean, broadcast-stream, built-in-class, case, ccase, ecase, cell-error, change-class, character, class, close, coerce, compiled-function, complex, concatenate, concatenated-stream, condition, cons, Constant Variables, constantp, Constituent Traits, control-error, Data and Control Flow Dictionary, defmethod, describe, Destructuring, division-by-zero, documentation, (setf documentation), echo-stream, end-of-file, error, Examples of Class Precedence List Determination, extended-char, file-error, file-stream, find-method, fixnum, float, floating-point-inexact, floating-point-invalid-operation, floating-point-overflow, floating-point-underflow, format, Formatted Output, function, generic-function, hash-table, Inheritance of Slots and Slot Options, initialize-instance, integer, Integrating Types and Classes, Introduction to Classes, Introduction to Methods, Introduction to Slots, Introduction, keyword, Lambda-list-directed Destructuring by Lambda Lists, list, load-time-value, Local Variable Initializations, logical-pathname, make-array, make-random-state, make-sequence, map, merge, method-combination, method, nil, no-applicable-method, not, Notes about FORMAT, null, null, number, package-error, package, parse-error, pathname, peek-char, print-not-readable, program-error, random-state, ratio, rational, reader-error, readtable, real, restart, room, sequence, serious-condition, set-pprint-dispatch, shared-initialize, Sharpsign, short-float, single-float, double-float, long-float, signed-byte, simple-array, simple-base-string, simple-bit-vector, simple-condition, simple-error, simple-string, simple-type-error, simple-vector, simple-warning, slot-missing, slot-unbound, Specialized Arrays, Standard Characters, standard-char, standard-class, standard-generic-function, standard-method, standard-object, storage-condition, stream-error, stream, string-stream, string, structure-class, structure-object, style-warning, Summary of Termination Test Clauses, symbol, Symbols in the COMMON-LISP Package, synonym-stream, t, Termination Test Clauses, The "Method Signature" Section of a Dictionary Entry, Tilde C: Character, Tilde S: Standard, two-way-stream, Type Relationships, Type Specifiers, type-error, unbound-slot, unbound-variable, undefined-function, unsigned-byte, vector, warning, with-hash-table-iterator, with-package-iterator, with-simple-restart, with-standard-io-syntax