When I compile a simple program with GCC I get no errors and it runs fine
When I compole the same simple program with Xcode (Command Line C) I get these errors:
Warning: return type defaults to 'int'
Warning: control reaches end of non-void function
They do not stop the build from succeeding but I was wondering what I am doing wrong to make these errors happen. This code is from K&R
Code:#include <stdio.h> main() { int c; c = getchar(); while (c != EOF) { putchar(c); c = getchar(); } }



LinkBack URL
About LinkBacks



