A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://www.lispworks.com/documentation/HyperSpec/Body/f_clas_1.htm below:

CLHS: Function CLASS-OF

Function CLASS-OF

Syntax:

class-of object => class

Arguments and Values:

object---an object.

class---a class object.

Description:

Returns the class of which the object is a direct instance.

Examples:

 (class-of 'fred) =>  #<BUILT-IN-CLASS SYMBOL 610327300>
 (class-of 2/3) =>  #<BUILT-IN-CLASS RATIO 610326642>
 
 (defclass book () ()) =>  #<STANDARD-CLASS BOOK 33424745>
 (class-of (make-instance 'book)) =>  #<STANDARD-CLASS BOOK 33424745>
 
 (defclass novel (book) ()) =>  #<STANDARD-CLASS NOVEL 33424764>
 (class-of (make-instance 'novel)) =>  #<STANDARD-CLASS NOVEL 33424764>

 (defstruct kons kar kdr) =>  KONS
 (class-of (make-kons :kar 3 :kdr 4)) =>  #<STRUCTURE-CLASS KONS 250020317>

Affected By: None.

Exceptional Situations: None.

See Also:

make-instance, type-of

Notes: None.


Copyright 1996-2005, LispWorks Ltd. All rights reserved.

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4