From d8c9024f3829dc3f241b16869f165f3ee01764f3 Mon Sep 17 00:00:00 2001 From: Keith Packard Date: Tue, 12 Dec 2017 15:25:51 -0800 Subject: altos/scheme: Support scheme subsetting via feature settings This provides for the creation of smaller versions of the interpreter, leaving out options like floating point numbers and vectors. Signed-off-by: Keith Packard --- src/scheme/ao_scheme_float.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/scheme/ao_scheme_float.c') diff --git a/src/scheme/ao_scheme_float.c b/src/scheme/ao_scheme_float.c index 99249030..c026c6fb 100644 --- a/src/scheme/ao_scheme_float.c +++ b/src/scheme/ao_scheme_float.c @@ -15,6 +15,8 @@ #include "ao_scheme.h" #include +#ifdef AO_SCHEME_FEATURE_FLOAT + static void float_mark(void *addr) { (void) addr; @@ -150,3 +152,4 @@ ao_scheme_do_sqrt(struct ao_scheme_cons *cons) return ao_scheme_error(AO_SCHEME_INVALID, "%s: non-numeric", ao_scheme_poly_atom(_ao_scheme_atom_sqrt)->name); return ao_scheme_float_get(sqrtf(ao_scheme_poly_number(value))); } +#endif -- cgit v1.2.3