[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Getting a type of a variable

From: Andy Wingo
Subject: Re: Getting a type of a variable
Date: Sat, 19 Jul 2008 10:53:57 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux)

On Fri 18 Jul 2008 23:48, "Maciek Godek" <address@hidden> writes:

> Hello,
> I'm looking for an efficient way to check the
> type of an SCM variable. I imagine that I
> could write something like:
> (define (type? x)
>   (cond ((integer? x) 'int)
>   (cond ((real? x) 'double)
> ...
> )

(oop goops)'s `class-of'


reply via email to

[Prev in Thread] Current Thread [Next in Thread]