Jump to content
OMRON Forums

Recommended Posts

Posted

Hi all. We would like to raise the warning level of the compiler. In particular, bad code is generated if you forget to declare a function returning a double, and it gets declared implicitly. We generally compile all our other code with -Wall and -Wextra to be sure we're not wandering into any risky territory, and it seems prudent to do that with PMAC code.

 

Is there a way to add more warnings to the compiler with the IDE? Or by editing some file somewhere in the system?

 

Thanks!

 

John

  • 1 month later...
  • Replies 4
  • Created
  • Last Reply

Top Posters In This Topic

Posted

Well, I thought I would answer my question for the benefit of others, oddly enough the release version of the makefile addes -Wall to the compile command. This is very helpful to get rid of errors caused by implicit declarations and other errors in the code that the compiler accepts without complaint in the "debug" version.

 

Can someone tell me why there is no way to pass in other compiler flags to the make process?

Posted

It might make sense to make -Wall a default choice even in debug mode, as that is when you want to find the warnings and fix them!

 

Thanks for the info!

 

John

Guest
This topic is now closed to further replies.

×
×
  • Create New...