So I'm doing some refactoring and it's really annoying that I don't get all the errors up front. How can I either increase the limit or remove the limit, so that the compiler will output all the errors it can find?
Asked
Active
Viewed 3.0k times
3 Answers
20
So I found how to do it. You add this compiler flag:
-ferror-limit=0
0 means that it will not stop because of too many errors.
This seems to be a question and answer that explains how to add a compiler flag in Xcode 4:
-
This doesn't seem to work for me in XCode 4; it seems that after hitting one or two files with errors, it simply stops compiling the rest of the files. I assume this flag at least prevents it from stopping in the middle of a file, but I'd like something that forces it to attempt to compile every file... – celticminstrel Nov 22 '13 at 19:37
7

James O'Brien
- 1,696
- 1
- 13
- 10
-
Running 6.1 here and this is exactly what I was looking for (and works). Tried checking Prefs > Behaviors, Schemes > Build, Build Settings, but this was the trick to getting more to show. – owenfi Nov 03 '14 at 10:27
-
This is basically a link-only answer. Please summarize the important information in the link. If the link rots then at least the important information will remain. – the Tin Man Jan 17 '22 at 00:10
-
3
Here is the complete syntax to compile and pass the flags to the make command:
make install CFLAGS="-ferror-limit=0"
Also as outlined in the link below: https://developer.apple.com/library/content/documentation/Porting/Conceptual/PortingUnix/compiling/compiling.html
-
1
-
The link shows the complete correct syntax on Apples developer web site to pass compiler flags to the make install command and provides context for how to perform this task on the command line. – John Nash Feb 12 '18 at 01:39
-
1This is basically a link-only answer. Please summarize the important information in the link. If the link rots then at least the important information will remain. – the Tin Man Jan 17 '22 at 00:10