All Manuals > LispWorks User Guide and Reference Manual > 40 The SYSTEM Package

NextPrevUpTopContentsIndex

pointer-from-address

Function
Summary

Returns the object into which the given address is pointing.

Package

system

Signature

pointer-from-address address => object

Arguments

address

An integer giving the address of the object.

Values

object

The object pointed to by address .

Description

The function pointer-from-address returns the object into which the given integer address is pointing. Note that this address may not be pointing into this object after a garbage collection, unless the object is static and is still referenced by another Lisp variable or object.

Example
CL-USER 8 > (setq static-string
                  (make-array 3 
                              :element-type 'base-char 
                              :allocation :static))
Warning: Setting unbound variable STATIC-STRING
")?"
 
CL-USER 9 > (sys:object-address static-string)
537166552
 
CL-USER 10 > (sys:pointer-from-address *)
")?"
 
CL-USER 11 > (eq * static-string)
T
See also

object-address


LispWorks User Guide and Reference Manual - 21 Dec 2011

NextPrevUpTopContentsIndex