From 3d92926a902017e7cf1f5738e99ff62da596ce12 Mon Sep 17 00:00:00 2001 From: Ethan Werner Date: Sun, 9 Aug 2026 15:02:21 +0400 Subject: refactor --- test/gen_test_data.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'test/gen_test_data.c') diff --git a/test/gen_test_data.c b/test/gen_test_data.c index 6ef54af..30bb7ff 100644 --- a/test/gen_test_data.c +++ b/test/gen_test_data.c @@ -1,6 +1,7 @@ /* gen_test_data.c - Validate all ts functions run without error. * Note: excluded from default build. Fix and add target to use. */ +#define _POSIX_C_SOURCE 200809L #include #include #include @@ -41,7 +42,11 @@ int main(void) { size_t nsamples = sizeof(samples) / sizeof(samples[0]); for (size_t fi = 0; fi < nsamples; fi++) { - typeof(samples[fi]) f = samples[fi]; + struct { + const char *name; + int (*func)(fp_t * const y[], fp_t const * const x[], uint_t, ts_constant_t const *); + uint_t x_n, y_n; + } f = samples[fi]; /* Allocate input arrays */ fp_t **x = calloc(f.x_n, sizeof(fp_t *)); -- cgit v1.3.1