avr-gcc-list
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [avr-gcc-list] AVR Libc int32_t and uint32_t typedefs are incorrect


From: Volker Kuhlmann
Subject: Re: [avr-gcc-list] AVR Libc int32_t and uint32_t typedefs are incorrect
Date: Thu, 12 Jan 2012 19:28:43 +1300

On Thu 12 Jan 2012 07:00:03 NZDT +1300, Paul McClean wrote:

> Unfortunately the static analysis tool I am using isn't aware of
> uint32_t, etc. Instead it requires to be told what are the sizes of the
> standard types on the target and it will then check that there are no
> dangerous casts, comparisons, etc. It works out what any typedefs are
> based upon interpreting the headers itself, but doesn't understand the
> special GCC syntax.

Your analysis tool is correct in not having uintX_t predefined. K&R
quite clearly says that they are defined in a lib header file. Your tool
is also correct in not dealing with proprietary input that is
non-standard C. Unfortunately once you remove the gcc-specials from those
typedefs you're left with the same definition for each of them. The
avr-libc developers made clear that they have no intention of fixing
this. The easiest way to move forward is to just change the appropriate
header file yourself so it doesn't affect code generation but is
understood correctly by your analysis tool. What exactly you have to put
in might depend on the tool and its configuration and should be easy to
work out.

HTH,

Volker

-- 
Volker Kuhlmann
http://volker.dnsalias.net/     Please do not CC list postings to me.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]