aboutsummaryrefslogtreecommitdiff
path: root/src/nissy.h
diff options
context:
space:
mode:
authorSebastiano Tronto <sebastiano@tronto.net>2025-05-27 09:03:51 +0200
committerSebastiano Tronto <sebastiano@tronto.net>2025-05-27 09:03:51 +0200
commit7c934801f88c640970ad41b5ddd39f4e39609f28 (patch)
tree76a065db76fbcbdec818b8b6cc8b108ac1c9eb49 /src/nissy.h
parent243a852d31483d10983c50978d1d4471efd0e553 (diff)
downloadnissy-core-7c934801f88c640970ad41b5ddd39f4e39609f28.tar.gz
nissy-core-7c934801f88c640970ad41b5ddd39f4e39609f28.zip
Removed VLA notation from function parameters.
I found out that this gives undefined behavior when then size is 0. Better not to have it at all, it is confusing for other developers anyway.
Diffstat (limited to 'src/nissy.h')
-rw-r--r--src/nissy.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/nissy.h b/src/nissy.h
index 0447d66..0c1d18d 100644
--- a/src/nissy.h
+++ b/src/nissy.h
@@ -276,7 +276,7 @@ long long
276nissy_gendata( 276nissy_gendata(
277 const char *solver, 277 const char *solver,
278 unsigned long long data_size, 278 unsigned long long data_size,
279 unsigned char data[data_size] 279 unsigned char *data
280); 280);
281 281
282/* 282/*
@@ -296,7 +296,7 @@ long long
296nissy_checkdata( 296nissy_checkdata(
297 const char *solver, 297 const char *solver,
298 unsigned long long data_size, 298 unsigned long long data_size,
299 const unsigned char data[data_size] 299 const unsigned char *data
300); 300);
301 301
302/* 302/*
@@ -352,9 +352,9 @@ nissy_solve(
352 unsigned optimal, 352 unsigned optimal,
353 unsigned threads, 353 unsigned threads,
354 unsigned long long data_size, 354 unsigned long long data_size,
355 const unsigned char data[data_size], 355 const unsigned char *data,
356 unsigned sols_size, 356 unsigned sols_size,
357 char sols[sols_size], 357 char *sols,
358 long long stats[static NISSY_SIZE_SOLVE_STATS], 358 long long stats[static NISSY_SIZE_SOLVE_STATS],
359 int (*poll_status)(void *), 359 int (*poll_status)(void *),
360 void *poll_status_data 360 void *poll_status_data

Generated with cgit - Back to sebastiano.tronto.net