diff options
Diffstat (limited to 'stdlib/functiontype.c')
| -rw-r--r-- | stdlib/functiontype.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/stdlib/functiontype.c b/stdlib/functiontype.c index ce07c063..b62ef2a7 100644 --- a/stdlib/functiontype.c +++ b/stdlib/functiontype.c @@ -1,6 +1,9 @@ // Logic for handling function type values +#include <stdbool.h> + #include "datatypes.h" +#include "functiontype.h" #include "tables.h" #include "text.h" #include "types.h" @@ -32,4 +35,9 @@ public Text_t Func$as_text(const void *fn, bool colorize, const TypeInfo_t *type return text; } +public PUREFUNC bool Func$is_none(const void *obj, const TypeInfo_t*) +{ + return *(void**)obj == NULL; +} + // vim: ts=4 sw=0 et cino=L2,l1,(0,W4,m1,\:0 |
