Next: Introduction, Previous: (dir), Up: (dir) [Contents][Index]
This is the cl-locatives Reference Manual, generated automatically by Declt version 3.0 "Montgomery Scott" on Sun May 15 03:56:38 2022 GMT+0.
• Introduction | What cl-locatives is all about | |
• Systems | The systems documentation | |
• Files | The files documentation | |
• Packages | The packages documentation | |
• Definitions | The symbols documentation | |
• Indexes | Concepts, functions, variables and data types |
CL-LOCATIVES ============ By Robert Smith Locatives are the Lisp equivalent of pointers, minus the arithmetic. In Lisp terms, they make the concept of "places" first-class. The main API consists of the macro LOCATIVE-FOR, which takes as an argument a place, as you would give to SETF; and the function DEREFERENCE, which extracts the value of that place, and (SETF DEREFERENCE), which sets the value of that place. The following example pretty much sums up the API: (let* ((x (make-array 5 :initial-element 0)) (l (locative-for (aref x 2)))) (setf (dereference l) 5) (list l x (dereference l))) gives (##(0 0 5 0 0) 5) as a result. We also have LOCATIVEP, and you can funcall the LOCATIVE-WRITER of a locative if you need to deal with multiple values (a rare case). This code can be very useful for porting over C code which uses pointers and by-reference values a lot.
Next: Files, Previous: Introduction, Up: Top [Contents][Index]
The main system appears first, followed by any subsystem dependency.
• The cl-locatives system |
Robert Smith <quad@symbo1ics.com>
BSD 3-clause (See LICENSE)
Implementation of locatives, pointer-like objects in Lisp.
cl-locatives.asd (file)
Files are sorted by type and then listed depth-first from the systems components trees.
• Lisp files |
• The cl-locatives.asd file | ||
• The cl-locatives/package.lisp file | ||
• The cl-locatives/cl-locatives.lisp file |
Next: The cl-locatives/package․lisp file, Previous: Lisp files, Up: Lisp files [Contents][Index]
cl-locatives.asd
cl-locatives (system)
Next: The cl-locatives/cl-locatives․lisp file, Previous: The cl-locatives․asd file, Up: Lisp files [Contents][Index]
cl-locatives (system)
package.lisp
Previous: The cl-locatives/package․lisp file, Up: Lisp files [Contents][Index]
package.lisp (file)
cl-locatives (system)
cl-locatives.lisp
Next: Definitions, Previous: Files, Up: Top [Contents][Index]
Packages are listed by definition order.
• The cl-locatives package |
A package for creating and manipulating locatives.
package.lisp (file)
loc
common-lisp
Definitions are sorted by export status, category, package, and then by lexicographic order.
• Exported definitions | ||
• Internal definitions |
Next: Internal definitions, Previous: Definitions, Up: Definitions [Contents][Index]
• Exported macros | ||
• Exported functions | ||
• Exported structures |
Next: Exported functions, Previous: Exported definitions, Up: Exported definitions [Contents][Index]
Return a locative for the place PLACE.
PLACE should be a form that can be passed as the first argument to SETF.
cl-locatives.lisp (file)
Next: Exported structures, Previous: Exported macros, Up: Exported definitions [Contents][Index]
Return a value that a locative LOCATIVE "points" to.
cl-locatives.lisp (file)
(setf dereference) (setf expander)
cl-locatives.lisp (file)
dereference (function)
cl-locatives.lisp (file)
cl-locatives.lisp (file)
Previous: Exported functions, Up: Exported definitions [Contents][Index]
A pointer-like data structure to allow, among other things, "reference passing" programming style.
cl-locatives.lisp (file)
structure-object (structure)
print-object (method)
function
(error "must provide reader function.")
locative-reader (function)
(setf locative-reader) (function)
function
(error "must provide writer function.")
locative-writer (function)
(setf locative-writer) (function)
Previous: Exported definitions, Up: Definitions [Contents][Index]
• Internal functions |
Previous: Internal definitions, Up: Internal definitions [Contents][Index]
cl-locatives.lisp (file)
cl-locatives.lisp (file)
Previous: Definitions, Up: Top [Contents][Index]
• Concept index | ||
• Function index | ||
• Variable index | ||
• Data type index |
Next: Function index, Previous: Indexes, Up: Indexes [Contents][Index]
Jump to: | C F L |
---|
Jump to: | C F L |
---|
Next: Variable index, Previous: Concept index, Up: Indexes [Contents][Index]
Jump to: | %
(
D F L M S |
---|
Jump to: | %
(
D F L M S |
---|
Next: Data type index, Previous: Function index, Up: Indexes [Contents][Index]
Jump to: | R S W |
---|
Index Entry | Section | ||
---|---|---|---|
| |||
R | |||
reader : | Exported structures | ||
| |||
S | |||
Slot, reader : | Exported structures | ||
Slot, writer : | Exported structures | ||
| |||
W | |||
writer : | Exported structures | ||
|
Jump to: | R S W |
---|
Previous: Variable index, Up: Indexes [Contents][Index]
Jump to: | C L P S |
---|
Jump to: | C L P S |
---|