On 23.06.2022 09:37, Roberto Bagnara wrote: > Rule 8.1 only applies to C90 code, as all the violating instances are > syntax errors in C99 and later versions of the language. So, > the following line does not contain a violation of Rule 8.1: > > unsigned x; > > It does contain a violation of Directive 4.6, though, whose correct > handling depends on the intention (uint32_t, uin64_t, size_t, ...).
Interesting - this goes straight against a rule we have set in ./CODING_STYLE. I'm also puzzled by you including size_t in your list of examples, when the spec doesn't. The sole "goal" of the directive (which is advisory only anyway) is to be able to determine allocation size. size_t size, however, varies as much as short, int, long, etc do. Jan