Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

xcode 7 how to suppress warning "overrides a member function but is not marked 'override'"

I updated xcode to 7 today. After the update the project I am working on has the warning "overrides a member function but is not marked 'override'". Since our project set "treade warning as error" to true. I got lots of errors.

I double checked "Other Linker Flags" and pretty sure the flag "-Wsuggest-override" is not included.

Since it is a big project I prefer to suppress the warning instead add the keyword "override" everywhere.

Any suggestion for disabling the warning?

Thanks

like image 248
Rong Yang Avatar asked Sep 17 '15 08:09

Rong Yang


1 Answers

You need to turn off the -Winconsistent-missing-override flag which automatically gets added with -Wall on recent versions of clang. You can do this by passing the -Wno-inconsistent-missing-override flag. See.

like image 194
sjdowling Avatar answered Sep 18 '22 14:09

sjdowling