The repl-utilities Reference Manual

This is the repl-utilities Reference Manual, generated automatically by Declt version 4.0 beta 2 "William Riker" on Sun Dec 08 19:28:35 2024 GMT+0.

Table of Contents


1 Introduction


2 Systems

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


2.1 repl-utilities

Ease common tasks at the REPL.

Author

Matt Niemeir <>

License

BSD 2-clause

Source

repl-utilities.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 repl-utilities/repl-utilities.asd

Source

repl-utilities.asd.

Parent Component

repl-utilities (system).

ASDF Systems

repl-utilities.


3.1.2 repl-utilities/package.lisp

Source

repl-utilities.asd.

Parent Component

repl-utilities (system).

Packages

repl-utilities.


3.1.3 repl-utilities/utils.lisp

Dependency

package.lisp (file).

Source

repl-utilities.asd.

Parent Component

repl-utilities (system).

Public Interface
Internals

3.1.4 repl-utilities/repl-utilities.lisp

Dependency

utils.lisp (file).

Source

repl-utilities.asd.

Parent Component

repl-utilities (system).

Public Interface
Internals

4 Packages

Packages are listed by definition order.


4.1 repl-utilities

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: *bring-hooks*

List of functions to be funcalled after a package is loaded with BRING.

The functions are called with the package imported by bring as their only argument.

Package

repl-utilities.

Source

repl-utilities.lisp.

Special Variable: *dev-hooks*

List of functions to be funcalled after a package is loaded with DEV.

During execution of these functions *PACKAGE* is already set to the package being loaded, and the repl-utilities symbols which will be imported already are. The functions are called with no arguments.

Package

repl-utilities.

Source

repl-utilities.lisp.


5.1.2 Macros

Macro: bring (package &optional shadowing-import-p)

Attempt to ql:quickload or asdf:load-system a system with the same name as package. Regardless of whether the load was successful import the package’s exported symbols into the current package. If shadowing-import is nil, only the symbols which won’t cause a symbol conflict are imported.

After importing the package funcall each element of *bring-hooks* with the designated package as its argument.

Expands to an EVAL-WHEN :compile-toplevel :load-toplevel :execute

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: dbgv ((&optional where stream) &body forms)

Print WHERE, execute FORMS, and print each form and its result to the STREAM.

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: deflex (var val &optional doc)

Define a top level (global) lexical VAR with initial value VAL, which is assigned unconditionally as with DEFPARAMETER. If a DOC string is provided, it is attached to both the name |VAR| and the name *STORAGE-FOR-DEFLEX-VAR-|VAR|* as a documentation string of kind ’VARIABLE. The new VAR will have lexical scope and thus may be shadowed by LET bindings without affecting its dynamic (global) value.

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: dev (package)

Attempt to ql:quickload or asfd:load-system a system with the same name as package, then swap to the package regardless of whether the load was successful. Import repl-utilities exported symbols that don’t cause symbol conflicts into the newly swapped to package.
Mnemonic for develop.

After swapping to the package map funcall over *dev-hooks*.

Expands to an EVAL-WHEN :compile-toplevel :load-toplevel :execute

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: doc (symbol &rest ignored-arguments)

Print any documentation for the symbol.
Includes variable, function, type, compiler macro, method combination, and setf documentation.

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: excs (&optional package-name)

Print the external symbols for which find-class is truthy.

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: exfns (&optional package-name)

Print the external fboundp symbols of a package.

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: exs (&optional package-name)

Print the external symbols of package.

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: exts (&optional package-name)

Print the external symbols which are type specifiers.

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: exvs (&optional package-name)

Print the external globally special symbols of a package.

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: lex (&rest args)

Shortening of deflex: define a global lexical variable.

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: mac (expr)

Bind *gensym-counter* to 0, Macroexpand-1 the form, pprint result.

If expression starts with a quotation, unquotes it first.

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: nic (package-name nick-symbol)

Add an additional nickname to package.
Expands to an EVAL-WHEN :compile-toplevel :load-toplevel :execute

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: package-apropos (string-designator)

Print all package names and nicknames which contain the given string.

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: readme (&optional package)

Print the documentation on the exported symbols of a package.

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: repeatably (&body body)

Use the same random state seed for every execution.
Random state seed is changed when call-repeatably is reloaded.

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: rig (&body body)

Execute body with profiling and timing.
Arrange for profiling information to print before IO or timing data. Profiling is only available in SBCL and with SB-SPROF available. RIG attempts to load SB-SPROF.

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: summary (&optional package)

Print the exported symbols along with the first line of their docstrings.

Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: trace-package (&optional package inheritedp)

Trace all of the symbols in *package*.

This won’t attempt to trace any symbols in :cl

Package

repl-utilities.

Source

repl-utilities.lisp.


5.1.3 Ordinary functions

Function: arglist (fname)

Return the arglist for the given function name. Implementations taken from slime.

Package

repl-utilities.

Source

utils.lisp.

Function: de (&rest rest)

Shortening of describe. A Rob Warnock function.

Package

repl-utilities.

Source

repl-utilities.lisp.

Function: dependency-locations (system-name &optional print-system-names-p operation)

Print the pathname of the system and of the systems needed to load it.

Package

repl-utilities.

Source

repl-utilities.lisp.

Function: print-hash (hash-table)

Print the hash table as: Key, Value~%

Package

repl-utilities.

Source

repl-utilities.lisp.

Function: shadowed-import (symbols &optional package print-when-shadowed-p)

Import each symbol into PACKAGE, unless a symbol of the same name is present. If print-when-shadowed-p is true, print a message for each not-imported symbol indicating that it was not imported.

Package

repl-utilities.

Source

utils.lisp.


5.2 Internals


5.2.1 Special variables

Special Variable: *documentation-types*

Types that might work with (documentation obj type)

Package

repl-utilities.

Source

utils.lisp.

Special Variable: *repl-utilities-rt*

A readtable where [ql quickload] reads as
‘(find-symbol ,(symbol-name ’quickload) ,(symbol-name ’ql))

Package

repl-utilities.

Source

utils.lisp.


5.2.2 Macros

Macro: define-external-symbol-printers (&body name-type-docs)
Package

repl-utilities.

Source

repl-utilities.lisp.

Macro: first-form (&rest forms)

Return the first form; useful when you want one of multiple possible conditionally read forms.

Package

repl-utilities.

Source

utils.lisp.

Macro: with-gensyms ((&rest names) &body body)
Package

repl-utilities.

Source

utils.lisp.


5.2.3 Ordinary functions

Function: bring% (package-designator shadowing-import-p)
Package

repl-utilities.

Source

repl-utilities.lisp.

Function: call-repeatably (thunk)
Package

repl-utilities.

Source

repl-utilities.lisp.

Function: dev% (package)
Package

repl-utilities.

Source

repl-utilities.lisp.

Function: doc% (symbol)
Package

repl-utilities.

Source

repl-utilities.lisp.

Function: ensure-unquoted (form)

If form is quoted, remove one level of quoting. Otherwise return form. This is a useful for defining convenience for macros which may be passed a quoted or unquoted symbol.

Package

repl-utilities.

Source

utils.lisp.

Function: first-line (string)
Package

repl-utilities.

Source

utils.lisp.

Function: load-system-or-print (system-designator &optional control-string &rest format-args)
Package

repl-utilities.

Source

utils.lisp.

Function: package-apropos% (string-designator)
Package

repl-utilities.

Source

repl-utilities.lisp.

Function: print-asdf-description (package)
Package

repl-utilities.

Source

utils.lisp.

Function: print-symbols (package-designator type)
Package

repl-utilities.

Source

repl-utilities.lisp.

Function: readme% (&optional package)
Package

repl-utilities.

Source

repl-utilities.lisp.

Function: require-once (string)
Package

repl-utilities.

Source

utils.lisp.

Function: run-time-symbol-reader (stream char)
Package

repl-utilities.

Source

utils.lisp.

Function: specialp (x)
Package

repl-utilities.

Source

utils.lisp.

Function: split-by (test sequence)
Package

repl-utilities.

Source

utils.lisp.

Function: string-sort (list)
Package

repl-utilities.

Source

utils.lisp.

Function: summary% (&optional package-designator)
Package

repl-utilities.

Source

repl-utilities.lisp.

Function: trace-package% (&optional package inheritedp)
Package

repl-utilities.

Source

repl-utilities.lisp.

Function: type-specifier-p (symbol)
Package

repl-utilities.

Source

utils.lisp.


5.2.4 Generic functions

Generic Function: exists-as (symbol type)
Package

repl-utilities.

Source

utils.lisp.

Methods
Method: exists-as (symbol (type (eql t)))
Method: exists-as (symbol (type (eql function)))
Method: exists-as (symbol (type (eql setf)))
Method: exists-as (symbol (type (eql type)))
Method: exists-as (symbol (type (eql class)))
Method: exists-as (symbol (type (eql variable)))
Method: exists-as (symbol (type (eql compiler-macro)))
Method: exists-as (symbol (type (eql method-combination)))

5.2.5 Conditions

Condition: unsupported
Package

repl-utilities.

Source

utils.lisp.

Direct superclasses

condition.


Appendix A Indexes


A.1 Concepts


A.2 Functions

Jump to:   A   B   C   D   E   F   G   L   M   N   P   R   S   T   W  
Index Entry  Section

A
arglist: Public ordinary functions

B
bring: Public macros
bring%: Private ordinary functions

C
call-repeatably: Private ordinary functions

D
dbgv: Public macros
de: Public ordinary functions
define-external-symbol-printers: Private macros
deflex: Public macros
dependency-locations: Public ordinary functions
dev: Public macros
dev%: Private ordinary functions
doc: Public macros
doc%: Private ordinary functions

E
ensure-unquoted: Private ordinary functions
excs: Public macros
exfns: Public macros
exists-as: Private generic functions
exists-as: Private generic functions
exists-as: Private generic functions
exists-as: Private generic functions
exists-as: Private generic functions
exists-as: Private generic functions
exists-as: Private generic functions
exists-as: Private generic functions
exists-as: Private generic functions
exs: Public macros
exts: Public macros
exvs: Public macros

F
first-form: Private macros
first-line: Private ordinary functions
Function, arglist: Public ordinary functions
Function, bring%: Private ordinary functions
Function, call-repeatably: Private ordinary functions
Function, de: Public ordinary functions
Function, dependency-locations: Public ordinary functions
Function, dev%: Private ordinary functions
Function, doc%: Private ordinary functions
Function, ensure-unquoted: Private ordinary functions
Function, first-line: Private ordinary functions
Function, load-system-or-print: Private ordinary functions
Function, package-apropos%: Private ordinary functions
Function, print-asdf-description: Private ordinary functions
Function, print-hash: Public ordinary functions
Function, print-symbols: Private ordinary functions
Function, readme%: Private ordinary functions
Function, require-once: Private ordinary functions
Function, run-time-symbol-reader: Private ordinary functions
Function, shadowed-import: Public ordinary functions
Function, specialp: Private ordinary functions
Function, split-by: Private ordinary functions
Function, string-sort: Private ordinary functions
Function, summary%: Private ordinary functions
Function, trace-package%: Private ordinary functions
Function, type-specifier-p: Private ordinary functions

G
Generic Function, exists-as: Private generic functions

L
lex: Public macros
load-system-or-print: Private ordinary functions

M
mac: Public macros
Macro, bring: Public macros
Macro, dbgv: Public macros
Macro, define-external-symbol-printers: Private macros
Macro, deflex: Public macros
Macro, dev: Public macros
Macro, doc: Public macros
Macro, excs: Public macros
Macro, exfns: Public macros
Macro, exs: Public macros
Macro, exts: Public macros
Macro, exvs: Public macros
Macro, first-form: Private macros
Macro, lex: Public macros
Macro, mac: Public macros
Macro, nic: Public macros
Macro, package-apropos: Public macros
Macro, readme: Public macros
Macro, repeatably: Public macros
Macro, rig: Public macros
Macro, summary: Public macros
Macro, trace-package: Public macros
Macro, with-gensyms: Private macros
Method, exists-as: Private generic functions
Method, exists-as: Private generic functions
Method, exists-as: Private generic functions
Method, exists-as: Private generic functions
Method, exists-as: Private generic functions
Method, exists-as: Private generic functions
Method, exists-as: Private generic functions
Method, exists-as: Private generic functions

N
nic: Public macros

P
package-apropos: Public macros
package-apropos%: Private ordinary functions
print-asdf-description: Private ordinary functions
print-hash: Public ordinary functions
print-symbols: Private ordinary functions

R
readme: Public macros
readme%: Private ordinary functions
repeatably: Public macros
require-once: Private ordinary functions
rig: Public macros
run-time-symbol-reader: Private ordinary functions

S
shadowed-import: Public ordinary functions
specialp: Private ordinary functions
split-by: Private ordinary functions
string-sort: Private ordinary functions
summary: Public macros
summary%: Private ordinary functions

T
trace-package: Public macros
trace-package%: Private ordinary functions
type-specifier-p: Private ordinary functions

W
with-gensyms: Private macros