Lisp HUG Maillist Archive

Function type cannot be used for discrimination?

Hi,

Did anyone ever encounter a runtime error of the following kind?

"Error: The type specifier (FUNCTION NIL T) cannot be used for discrimination."

Any idea what this means and why I would get that? I'm pretty sure that my type declarations are correct...


Pascal

-- 
Pascal Costanza, mailto:pc@p-cos.net, http://p-cos.net
Vrije Universiteit Brussel
Software Languages Lab
Pleinlaan 2, B-1050 Brussel, Belgium







Re: Function type cannot be used for discrimination?

Pascal Costanza <pc@p-cos.net> writes:

> Hi,
>
> Did anyone ever encounter a runtime error of the following kind?
>
> "Error: The type specifier (FUNCTION NIL T) cannot be used for discrimination."
>
> Any idea what this means and why I would get that? I'm pretty sure
> that my type declarations are correct...

clhs typep

    type-specifier---any type specifier except values, or a type specifier
    list whose first element is either function or values.

By extension, it applies to typecase and method dispatching too.


-- 
__Pascal Bourguignon__                     http://www.informatimago.com/
A bad day in () is better than a good day in {}.


Re: Function type cannot be used for discrimination?

Unable to parse email body. Email id is 10739

Updated at: 2020-12-10 08:38 UTC