guile-user
[Top][All Lists]
Advanced

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

Unspecified?


From: Maciek Godek
Subject: Unspecified?
Date: Fri, 14 Nov 2008 11:38:40 +0100

Hey all yoh!
Is there any "official" way to check whether or not
a function returns a (specified) value?

As I ran into the problem, I quickly came with a workaround:
(define unspecified (if #f #t))
which allows to define the most basic predicates:
(define (unspecified? x) (eq? x unspecified))
(define (specified? x) (not (unspecified? x)))

but I find it kinda surprising that these are not available
by default in the system.

Best regards
M.




reply via email to

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