Name

typecase

Usage

macro

Syntax

(typecase keyform normal-clause* [otherwise-clause])

Description

normal-clause := '(' type form* ')'
otherwise-clause := '(' {true|otherwise} form* ')'
type := symbol corresponding to a (imported) class
user > (let s 'aap)
it: s
user > (typecase s
           (integer
                (print-line 1))
           (symbol
                (print-line 2))
           (otherwise
                (print-line 3)))
2
it: null