1

(This is an extension to my previous question). I'm using Splint in Windows CLI.

The XC8 embedded C compiler has a custom type bit. To get Splint to parse, I can pass to it the CLI option:

-Dbit=char

However I need it to replace bit with unsigned char. The space character is a problem. How can I modify the above flag?

Community
  • 1
  • 1
Jodes
  • 14,118
  • 26
  • 97
  • 156
  • Surrounding the argument with double quotes should work. Do you any other tools like *make* or batch files? – nwellnhof Feb 24 '14 at 12:52

1 Answers1

2

It is the shell, not splint, which processes the quotes and escapes in command-line arguments. Any result where the shell ends up treating the whole string -Dbit=unsigned char as a single argument suffices, e.g., put quotes around the whole thing.

(edit: Actually, in case of Windows it may in some cases be something other than the shell that processes the quotes and escapes, but never-the-less putting double quotes around the whole thing should work.)

Arkku
  • 41,011
  • 10
  • 62
  • 84
  • Thanks. From your answer I realised that there's a difference between the flag on the CLI and the same flag in the config file (splint.rc) - they need to be formatted differently. – Jodes Feb 24 '14 at 12:54