Eclipse and Compiler Errors - how to fix?
Posted: Wed Aug 08, 2012 8:49 am
I have a bit of an issue (more of an annoyance). It appears that the compiler and Eclipse have a different idea of what is an error. For example:
char mystring[32];
snprintf(mystring, 32, "Example Code...");
This compiles fine. However Eclipse marks it with a bug and indicates in my project Explorer that I have an error in the file. It says that the arguments are invalid. It does this for memset(), strncpy() and other functions from string.h I think.
Pretty much right now I ignore it since it does not produce a compiler error... however it would be nice to know how to fix it.
Thanks, Chris F.
char mystring[32];
snprintf(mystring, 32, "Example Code...");
This compiles fine. However Eclipse marks it with a bug and indicates in my project Explorer that I have an error in the file. It says that the arguments are invalid. It does this for memset(), strncpy() and other functions from string.h I think.
Pretty much right now I ignore it since it does not produce a compiler error... however it would be nice to know how to fix it.
Thanks, Chris F.