The trivial-inspect Reference Manual

This is the trivial-inspect Reference Manual, version 0.0.0, generated automatically by Declt version 4.0 beta 2 "William Riker" on Fri May 15 13:08:27 2026 GMT+0.

Table of Contents


1 Introduction


2 Systems

The main system appears first, followed by any subsystem dependency.


2.1 trivial-inspect

Portable toolkit for interactive inspectors.

Author

Artyom Bologov

Home Page

https://codeberg.org/aartaka/trivial-inspect

Source Control

(GIT https://codeberg.org/aartaka/trivial-inspect.git)

Bug Tracker

https://codeberg.org/aartaka/trivial-inspect/issues

License

BSD-2 Clause

Version

0.0.0

Dependency

trivial-arguments (system).

Source

trivial-inspect.asd.

Child Components

3 Files

Files are sorted by type and then listed depth-first from the systems components trees.


3.1 Lisp


3.1.1 trivial-inspect/trivial-inspect.asd

Source

trivial-inspect.asd.

Parent Component

trivial-inspect (system).

ASDF Systems

trivial-inspect.


3.1.2 trivial-inspect/package.lisp

Source

trivial-inspect.asd.

Parent Component

trivial-inspect (system).

Packages

trivial-inspect.


3.1.3 trivial-inspect/fields.lisp

Dependency

package.lisp (file).

Source

trivial-inspect.asd.

Parent Component

trivial-inspect (system).

Public Interface
Internals

3.1.4 trivial-inspect/description.lisp

Dependency

fields.lisp (file).

Source

trivial-inspect.asd.

Parent Component

trivial-inspect (system).

Public Interface

description (generic function).

Internals

object-description (function).


4 Packages

Packages are listed by definition order.


4.1 trivial-inspect

‘trivial-inspect’ provides building blocks for interactive inspectors. Two main functions it exports are:
- ‘fields’ to get a list of inspect fields for an object.
- ‘description’ for a concise description of an object to stream.

Source

package.lisp.

Use List

common-lisp.

Public Interface
Internals

5 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


5.1 Public Interface


5.1.1 Special variables

Special Variable: *function-lambda-expression-fn*

The function to use in place of ‘function-lambda-expression’ (FLE). Because implementation specific FLE often is quite useless.

Package

trivial-inspect.

Source

fields.lisp.


5.1.2 Generic functions

Generic Function: description (object &optional stream)

Print human-readable description of OBJECT to STREAM.

Methods should include the most useful information and things that are
not suitable for the ‘fields’ key-value format.

(trivial-inspect:description t t)
;; Boolean T (external to COMMON-LISP) [bound] [class]

(trivial-inspect:description nil t)
;; Null NIL (external to COMMON-LISP) [bound]

(trivial-inspect:description 65536 t)
;; Integer 65536 (17 bits):
;; #b10000000000000000, #o200000, #x10000
;; Universal time: 21:10:16 Jan 1st, year 1900.

(trivial-inspect:description *readtable* t)
;; Readtable #<READTABLE {120003C463}>
;; A READTABLE is a data structure that maps characters into syntax
;; types for the Common Lisp expression reader.

(trivial-inspect:description (find-class ’standard-object) t)
;; Standard-class #<STANDARD-CLASS COMMON-LISP:STANDARD-OBJECT>

(defparameter *aespa* (make-hash-table :test ’equalp))
(setf (gethash "KARINA" *aespa*) "Rocket puncher"
(gethash "WINTER" *aespa*) "Armamenter"
(gethash "GISELLE" *aespa*) "Xenoglossy"
(gethash "NINGNING" *aespa*) "E.D. hacker")
(trivial-inspect:description *aespa* t)
;; Hash-table [EQUALP, 4/7]
;; (("KARINA" "Rocket punch") ("WINTER" "Weapons") ("GISELLE" "Seize the moment") ("NINGNING" "Hacking"))

Package

trivial-inspect.

Source

description.lisp.

Methods
Method: description ((object structure-object) &optional stream)
Method: description ((object standard-object) &optional stream)
Method: description ((object function) &optional stream)
Method: description ((object pathname) &optional stream)
Method: description ((object stream) &optional stream)
Method: description ((object array) &optional stream)
Method: description ((object hash-table) &optional stream)
Method: description ((object condition) &optional stream)
Method: description ((object restart) &optional stream)
Method: description ((object package) &optional stream)
Method: description ((object cons) &optional stream)
Method: description ((object character) &optional stream)
Method: description ((object complex) &optional stream)
Method: description ((object ratio) &optional stream)
Method: description ((object float) &optional stream)
Method: description ((object integer) &optional stream)
Method: description ((object symbol) &optional stream)
Method: description :before (object &optional stream)
Method: description (object &optional stream)
Generic Function: fields (object &key &allow-other-keys)

Return a list of OBJECT fields to inspect.
Every property is a list of (INDEX NAME VALUE &optional SETTER) lists, where

- INDEX is an integer showing the index by which to choose
property. Non-trivial, because sequences have their own indices
interfering with simple incrementing indices for inspect fields.

- NAME is a thing (preferably symbol) naming the property.

- VALUE is the contents of the property.

- And SETTER is a function of two arguments (new-value old-value) to
modify the property. For slots, this setter will likely be setting the ‘slot-value’.

Annotated exemplary case:

(fields #("one" "two" "three")
=>
((3 :self #("one" "two" "three"))
(4 :id 77396508623)
;; Fields are type-specific and often match CL function/accessor names
(5 class-of #<built-in-class common-lisp:simple-vector> nil)
(6 type-of (simple-vector 3))
(7 length 3)
(8 array-dimensions (3) nil)
(9 array-rank 1)
(10 array-element-type t)
(11 upgraded-array-element-type t)
;; In case of sequences and other integer-indexed structures, these numbers go first ;; Field indices are filling in the gaps (see above, :self starting at 3)
(0 0 "one" #<function (lambda (new-value _) :in fields) {120563C56B}>)
;; For many fields, there are setter functions provided.
(1 1 "two" #<function (lambda (new-value _) :in fields) {120563C58B}>)
(2 2 "three" #<function (lambda (new-value _) :in fields) {120563C5AB}>))

Package

trivial-inspect.

Source

fields.lisp.

Method Combination

reverse-append-index.

Options

:most-specific-first

Methods
Method: fields trivial-inspect::reverse-append-index (object &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object structure-object) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object standard-object) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object fdefn) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object weak-pointer) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object code-component) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object type-error) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object file-error) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object unbound-slot) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object print-not-readable) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object stream-error) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object package-error) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object cell-error) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object arithmetic-error) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object simple-condition) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object condition) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object restart) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object generic-function) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object function) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object stream) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object file-stream) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object synonym-stream) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object broadcast-stream) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object concatenated-stream) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object echo-stream) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object two-way-stream) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object hash-table) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object pathname) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object logical-pathname) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object array) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object string) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object character) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object random-state) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object readtable) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object package) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object integer) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object float) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object ratio) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object complex) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object cons) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object sequence) &key &allow-other-keys)
Method: fields trivial-inspect::reverse-append-index ((object symbol) &key &allow-other-keys)

5.2 Internals


5.2.1 Special variables

Special Variable: *documentation-fn*

An (OBJECT DOC-TYPE) function to use instead of standard ‘documentation’.

Package

trivial-inspect.

Source

fields.lisp.

Special Variable: sbcl-props-to-ignore
Package

trivial-inspect.

Source

fields.lisp.


5.2.2 Macros

Macro: -> (name (&rest arg-types) &optional return-type)

Shorter ftype declaration for NAME.

Package

trivial-inspect.

Source

fields.lisp.

Macro: deffield (specifier name function)
Package

trivial-inspect.

Source

fields.lisp.

Macro: deffields ((name specifier) &body fields)
Package

trivial-inspect.

Source

fields.lisp.


5.2.3 Ordinary functions

Function: all-symbols (package)
Package

trivial-inspect.

Source

fields.lisp.

Function: dotted-p (cons)
Package

trivial-inspect.

Source

fields.lisp.

Function: except-sbcl-props (object)
Package

trivial-inspect.

Source

fields.lisp.

Function: external-symbols (package)
Package

trivial-inspect.

Source

fields.lisp.

Function: field-indices (fields)

Map integer indices to every property in FIELDS. Implies that FIELDS have a (KEY VALUE . ARGS) structure Non-trivial, because some of the FIELDS have integer keys.

Package

trivial-inspect.

Source

fields.lisp.

Function: function-closure-p (function)
Package

trivial-inspect.

Source

fields.lisp.

Function: id (object)
Package

trivial-inspect.

Source

fields.lisp.

Function: inherited-symbols (package)
Package

trivial-inspect.

Source

fields.lisp.

Function: inspect-slots (object)
Package

trivial-inspect.

Source

fields.lisp.

Function: internal-symbols (package)
Package

trivial-inspect.

Source

fields.lisp.

Function: object-description (object stream)
Package

trivial-inspect.

Source

description.lisp.

Function: object-slots (object)
Package

trivial-inspect.

Source

fields.lisp.

Function: restart-interactive (restart)
Package

trivial-inspect.

Source

fields.lisp.

Function: reverse-append-index (&rest lists)
Package

trivial-inspect.

Source

fields.lisp.

Function: scalar-p (object)

Return true if OBJECT is of one of the following types: - symbol,
- character,
- string,
- non-complex number.

Package

trivial-inspect.

Source

fields.lisp.

Function: symbol-visibility (symbol)
Package

trivial-inspect.

Source

fields.lisp.


5.2.4 Method combinations

Method Combination: reverse-append-index (&optional order)
Package

trivial-inspect.

Source

fields.lisp.

Client Functions

fields.

Operator

reverse-append-index (function).

Identity with one argument

t


Appendix A Indexes


A.1 Concepts


A.2 Functions

Jump to:   -  
A   D   E   F   G   I   M   O   R   S  
Index Entry  Section

-
->: Private macros

A
all-symbols: Private ordinary functions

D
deffield: Private macros
deffields: Private macros
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
description: Public generic functions
dotted-p: Private ordinary functions

E
except-sbcl-props: Private ordinary functions
external-symbols: Private ordinary functions

F
field-indices: Private ordinary functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
fields: Public generic functions
Function, all-symbols: Private ordinary functions
Function, dotted-p: Private ordinary functions
Function, except-sbcl-props: Private ordinary functions
Function, external-symbols: Private ordinary functions
Function, field-indices: Private ordinary functions
Function, function-closure-p: Private ordinary functions
Function, id: Private ordinary functions
Function, inherited-symbols: Private ordinary functions
Function, inspect-slots: Private ordinary functions
Function, internal-symbols: Private ordinary functions
Function, object-description: Private ordinary functions
Function, object-slots: Private ordinary functions
Function, restart-interactive: Private ordinary functions
Function, reverse-append-index: Private ordinary functions
Function, scalar-p: Private ordinary functions
Function, symbol-visibility: Private ordinary functions
function-closure-p: Private ordinary functions

G
Generic Function, description: Public generic functions
Generic Function, fields: Public generic functions

I
id: Private ordinary functions
inherited-symbols: Private ordinary functions
inspect-slots: Private ordinary functions
internal-symbols: Private ordinary functions

M
Macro, ->: Private macros
Macro, deffield: Private macros
Macro, deffields: Private macros
Method Combination, reverse-append-index: Private method combinations
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, description: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions
Method, fields: Public generic functions

O
object-description: Private ordinary functions
object-slots: Private ordinary functions

R
restart-interactive: Private ordinary functions
reverse-append-index: Private ordinary functions
reverse-append-index: Private method combinations

S
scalar-p: Private ordinary functions
symbol-visibility: Private ordinary functions