Question

In light of the Apple's recent goto fail, I've decided to add -Wunreachable-code to existing LLVM flags (-Wall and -Wextra). However, the flag doesn't (seem to) work. For example, placing code after return; doesn't trigger the warning. Is the flag even functional (GCC supposedly removed it)? What am I missing?

Était-ce utile?

La solution

It works for me when:

  1. I enter the flag here warning setting
  2. Then clean project
  3. I receive this warning when I do a rebuild warning output
Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top