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

c++ - Delete matches in OpenCV (Keypoints and descriptors) -

java - Could not locate OpenAL library -

sorting - opencl Bitonic sort with 64 bits keys -