Domanda

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?

È stato utile?

Soluzione

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
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top