osx - Error when trying to compile C program code in C99 mode -


when i'm compiling simple program 'hello world', i'm getting warning @ printf function. here error message:

hey.c:4:5: warning: implicit declaration of function 'puts' invalid in c99   [-wimplicit-function-declaration] puts("hello world!"); ^ 1 warning generated. ld: can't write output file: a.out architecture x86_64 clang: error: linker command failed exit code 1 (use -v see invocation) 

yes need include stdio.h in code . compilers allow use printf without header file generate warning


Comments

Popular posts from this blog

node.js - How to mock a third-party api calls in the backend -

node.js - Why do I get "SOCKS connection failed. Connection not allowed by ruleset" for some .onion sites? -

matlab - 0-by-1 sym - What do I need to change in order to get proper symbolic results? -