|
From: | Paul Eggert |
Subject: | Re: warnings in unit tests |
Date: | Tue, 8 Jun 2021 09:42:55 -0700 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.8.1 |
It'd be OK with me to disable the troublesome warnings globally for the tests subdirectory, using -Wno-missing-prototypes or whatever.
For the -Wnull-dereference issue it may be worthwhile to use a circumlocution that fools GCC into not issuing the warning. After all, a compiler smart enough to warn about '*(volatile int *) 0 = 42' might also be smart enough to see that it's undefined behavior and therefore omit the assignment's effect entirely. Perhaps something like the attached (untested) patch?
gnulib.diff
Description: Text Data
[Prev in Thread] | Current Thread | [Next in Thread] |