@@ -29,7 +29,7 @@ def kernel(x):
2929```
3030
3131Signature arguments must match the variables you pass to ` me_compile() ` by name
32- (order does not matter). (Callback functions registered via ` me_variable_ex ` are
32+ (order does not matter). (Callback functions registered via ` me_variable ` are
3333not listed in the signature.)
3434
3535Note: The order of the variables array still defines the pointer order passed to
@@ -323,7 +323,7 @@ Logical operator precedence matches Python: `not` binds tighter than `and`, whic
323323- Predicates: `startswith(a, b)`, `endswith(a, b)`, `contains(a, b)` (string-to-string)
324324
325325String variables must be provided with dtype `ME_STRING` and a fixed `itemsize`
326- via `me_variable_ex ` (itemsize is bytes per element and must be a multiple of 4).
326+ via `me_variable ` (itemsize is bytes per element and must be a multiple of 4).
327327String expressions always yield boolean output.
328328
329329Example (element-wise string match with a scalar condition):
@@ -407,7 +407,7 @@ print(sum(a))
407407### User-defined Functions
408408
409409You can register custom C functions or closures and call them from DSL by
410- including them in the `me_variable_ex ` list passed to `me_compile_ex ()`.
410+ including them in the `me_variable ` list passed to `me_compile ()`.
411411
412412Rules:
413413- Function/closure entries must use `ME_FUNCTION*` or `ME_CLOSURE*` in `type`.
@@ -422,14 +422,14 @@ static double clamp01(double x) {
422422 return x < 0.0 ? 0.0 : (x > 1.0 ? 1.0 : x);
423423}
424424
425- me_variable_ex vars[ ] = {
425+ me_variable vars[ ] = {
426426 {"x", ME_FLOAT64, x, ME_VARIABLE, NULL, 0},
427427 {"clamp01", ME_FLOAT64, clamp01, ME_FUNCTION1 | ME_FLAG_PURE, NULL, 0},
428428};
429429
430430me_expr * expr = NULL;
431431int err = 0;
432- me_compile_ex ("def kernel(x):\n return clamp01(x)\n", vars, 2, ME_FLOAT64, &err, &expr);
432+ me_compile ("def kernel(x):\n return clamp01(x)\n", vars, 2, ME_FLOAT64, &err, &expr);
433433```
434434
435435Example (closure with context):
@@ -439,7 +439,7 @@ static double scale(void *ctx, double x) {
439439}
440440
441441double factor = 2.0;
442- me_variable_ex vars[ ] = {
442+ me_variable vars[ ] = {
443443 {"x", ME_FLOAT64, x, ME_VARIABLE, NULL, 0},
444444 {"scale", ME_FLOAT64, scale, ME_CLOSURE1 | ME_FLAG_PURE, &factor, 0},
445445};
0 commit comments