2012-08-16 01:00:30 +01:00
|
|
|
#ifndef BUILTIN_H
|
|
|
|
|
#define BUILTIN_H
|
|
|
|
|
|
2013-11-30 02:05:42 -06:00
|
|
|
#include "jq.h"
|
2013-06-18 01:36:18 +01:00
|
|
|
#include "bytecode.h"
|
2012-09-16 17:08:56 +01:00
|
|
|
#include "compile.h"
|
2012-08-16 01:00:30 +01:00
|
|
|
|
2013-11-30 02:05:42 -06:00
|
|
|
int builtins_bind(jq_state *, block*);
|
2012-08-16 01:00:30 +01:00
|
|
|
|
2023-08-04 00:12:48 +02:00
|
|
|
#define BINOPS \
|
|
|
|
|
BINOP(plus) \
|
|
|
|
|
BINOP(minus) \
|
|
|
|
|
BINOP(multiply) \
|
|
|
|
|
BINOP(divide) \
|
|
|
|
|
BINOP(mod) \
|
|
|
|
|
BINOP(equal) \
|
|
|
|
|
BINOP(notequal) \
|
|
|
|
|
BINOP(less) \
|
|
|
|
|
BINOP(lesseq) \
|
|
|
|
|
BINOP(greater) \
|
|
|
|
|
BINOP(greatereq) \
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#define BINOP(name) jv binop_ ## name(jv, jv);
|
|
|
|
|
BINOPS
|
|
|
|
|
#undef BINOP
|
|
|
|
|
|
2012-08-16 01:00:30 +01:00
|
|
|
#endif
|