[rtems commit] psxtmtests - Eliminate missing prototype warnings

Joel Sherrill joel.sherrill at OARcorp.com
Mon May 14 14:08:55 UTC 2012

On 05/14/2012 08:58 AM, Sebastian Huber wrote:
> On 05/14/2012 03:50 PM, Joel Sherrill wrote:
>> On 05/13/2012 04:04 AM, Sebastian Huber wrote:
>>> Why didn't you make the init functions static?
>> Just didn't. They have always been global.
> Why?  Who is supposed to call this function?
>> Also I wasn't making value judgements on the code.
>> I was just providing prototypes.
>> FWIW While about 75% through the testsuites, I had the insight
>> that this is actually a warning of questionable quality. Each
>> of the ones I fixed was a case where the method
>> was defined above the point of its use in the code.
>> This warning was turned on without discussion and without
>> any commitment to address warnings it generated.
>> Some warnings do point out questionable code. This
>> one just seems to be uselessly pedantic and addressing
>> the things it points out does nothing IMO to improve
>> code quality. It just means we can compile with one
>> more warning enabled.
> This warning is quite useful since it marks global functions without a proper
> header file.  Placing global function prototypes in a source file is a severe
> error from my point of view.
Turning on a warning without discussing its value, how to
address what it points out and a commitment to resolve
them is bad IMO.

Our discussion points out that this warning was put in
without that.

We can always make a separate pass and move my
prototypes to a .h file.  I really don't care about the
solution. I do care about the process of evaluating
warnings, turning them on, a plan to fix them and
a commitment to do so.

Joel Sherrill, Ph.D.             Director of Research&   Development
joel.sherrill at OARcorp.com        On-Line Applications Research
Ask me about RTEMS: a free RTOS  Huntsville AL 35805
     Support Available             (256) 722-9985

More information about the devel mailing list