diff --git a/sds.c b/sds.c index 39ad595..2ef0ae7 100644 --- a/sds.c +++ b/sds.c @@ -1266,6 +1266,7 @@ int sdsTest(void) { if (type != SDS_TYPE_5) { test_cond("sdsMakeRoomFor() free", sdsavail(x) >= step); oldfree = sdsavail(x); + (void) oldfree; } p = x+oldlen; for (j = 0; j < step; j++) { diff --git a/sds.h b/sds.h index 1bdb60d..ae1aada 100644 --- a/sds.h +++ b/sds.h @@ -272,3 +272,8 @@ int sdsTest(int argc, char *argv[]); #endif #endif + +/* GCC: Incorrect warning about empty translation units + * when using pre-compiled headers, + * (See: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64502). */ +typedef int sdsvoid;