Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Rule 3.6: Reserved words and standard library function names
#1
Hi,

I'm using a tool from the USA called codechk.

When performing check on my code I get this message:
Code:
u16_t f29( void );
Quote:error: (REQUIRED) MISRA rule 116 ( 3.6 ) violated: Reserved words and standard library function names shall not be used { DECL }

But I dont see any reserved words or standard library function names. Can anyone help me out? Do you need some more code or infos?


Bjoern
#2
I think you are asking the question in the wrong place.

Ask the Codechk people why their tool is wrong....

The words quoted inthe error message are not the correct rule words.. This indicates they may not have authorisation to use the actual words

DO you have a link to this tool?
#3
tria1312 Wrote:
Code:
u16_t f29( void );

But I dont see any reserved words or standard library function names.

I wonder if they are thinking of the C99 wording (in 7.2.6 "Future Library Directions").

ISO/IEC 9899:1999 Wrote:The following names are grouped under individual headers for convenience. All external
names described below are reserved no matter what headers are included by the program.

and in section 7.26.8 "Integer types "

ISO/IEC 9899:1999 Wrote:Typedef names beginning with int or uint and ending with _t may be added to the
types defined in the header.

Alternatively they may be thinking of the POSIX reservation of _t names.

stephen
#4
Without more information on the tool all we can do is speculate.

However any tool that is using C99 and POSIX rules and claiming to check for MISRA-C in this fashion is to say the least dubious.
#5
From the information posted, we cannot see any violations of Rule 3.6 in this code.

Please follow this up with the tool vendor.
Posted by and on behalf of the MISRA C Working Group


Forum Jump:


Users browsing this thread: 1 Guest(s)