36 |
/* Maintain each of the builtins implemented in this modules along |
/* Maintain each of the builtins implemented in this modules along |
37 |
with their details in a single table for easy maintenance. |
with their details in a single table for easy maintenance. |
38 |
|
|
39 |
function macros blind */ |
function macros blind minargs maxargs */ |
40 |
#define builtin_functions \ |
#define builtin_functions \ |
41 |
BUILTIN(mpeval, FALSE, TRUE ) |
BUILTIN(mpeval, FALSE, TRUE, 2, 4 ) \ |
42 |
|
|
43 |
|
|
44 |
|
|
79 |
#define numb_decr(n) numb_minus(n,numb_ONE) |
#define numb_decr(n) numb_minus(n,numb_ONE) |
80 |
|
|
81 |
/* Generate prototypes for each builtin handler function. */ |
/* Generate prototypes for each builtin handler function. */ |
82 |
#define BUILTIN(handler, macros, blind) M4BUILTIN(handler) |
#define BUILTIN(handler, macros, blind, min, max) M4BUILTIN(handler) |
83 |
builtin_functions |
builtin_functions |
84 |
#undef BUILTIN |
#undef BUILTIN |
85 |
|
|
87 |
/* Generate a table for mapping m4 symbol names to handler functions. */ |
/* Generate a table for mapping m4 symbol names to handler functions. */ |
88 |
m4_builtin m4_builtin_table[] = |
m4_builtin m4_builtin_table[] = |
89 |
{ |
{ |
90 |
#define BUILTIN(handler, macros, blind) \ |
#define BUILTIN(handler, macros, blind, min, max) \ |
91 |
{ STR(handler), CONC(builtin_, handler), macros, blind }, |
{ STR(handler), CONC(builtin_, handler), macros, blind, min, max }, |
92 |
builtin_functions |
builtin_functions |
93 |
#undef BUILTIN |
#undef BUILTIN |
94 |
|
|
95 |
{ 0, 0, FALSE, FALSE }, |
{ 0, 0, FALSE, FALSE, 0, 0 }, |
96 |
}; |
}; |
97 |
|
|
98 |
|
|