~lattis/muon

ref: 49a50d56c57dfdf470b4bcbffc16bc5ec92dcb4e muon/src/functions/disabler.c -rw-r--r-- 475 bytes
49a50d56Stone Tickle support comma seperated option array 8 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#include "posix.h"

#include "functions/common.h"
#include "functions/disabler.h"
#include "lang/interpreter.h"
#include "log.h"

static bool
func_disabler_found(struct workspace *wk, obj rcvr, uint32_t args_node, obj *res)
{
	if (!interp_args(wk, args_node, NULL, NULL, NULL)) {
		return false;
	}

	make_obj(wk, res, obj_bool)->dat.boolean = false;
	return true;
}

const struct func_impl_name impl_tbl_disabler[] = {
	{ "found", func_disabler_found },
	{ NULL, NULL },
};