lambda?

val


Summary

Test whether val is a function

Description

Sometimes also called lambda or subroutine

Arguments

val
This argument is going to be tested

Return value

Whether val is a function

Examples

(lambda? 'abc)
#f

(lambda? (current-closure))
#f

(lambda? case)
#f

(lambda? min)
#t

Bytecode

Probably only interesting to you if you want to understand more about the Nujel VM or care very much about performance.

(    0 ($push/val :lambda))
(    2 ($get/val 'type-of))
(    4 ($get/val 'val))
(    6 ($apply 1))
(    8 ($=))
(    9 ($dup))
(   10 ($jt* 6))
(   13 ($drop))
(   14 ($push/val #f))
(   16 ($ret))