[splint-discuss] keyword 'near'
Roland Illig
roland.illig at gmx.de
Thu Apr 10 23:36:40 PDT 2008
Putten Bob van der schrieb:
> Hello all,
> The following declaration resulted in a parsing error:
> long rmpa_instruction (short near *s1, short near *s2, unsigned short n);
> It seems that the word 'near' is the problem
> How can I solve this?
In a commonly used header file, which should be included very early by
every source file, write:
#ifdef S_SPLINT_S
#define near /* nothing */
#endif
SPlint doesn't need the information about near and far pointers; but
sure, if someone was to hack SPlint's source code, it could analyze them
too, and detect inconsistencies. But in almost all cases, your program
will crash early anyway if you make a mistake in this area.
Roland
More information about the splint-discuss
mailing list