From: Keith M. <kei...@to...> - 2007-05-01 15:15:14
|
A_SN wrote: > When I tried to compile a header file and its C file, I've been > surprised to see an error that I wasn't getting with any other > compiler. There are the files and the error : [...snip...] > $ gcc -c user_number_input.c > user_number_input.c:4: error: redefinition of 'getfloat' > user_number_input.h:8: error: previous definition of 'getfloat' > was here What version of GCC? I copied and pasted your example files, unchanged, and I cannot reproduce this with $ gcc --version gcc.exe (GCC) 3.4.5 (mingw special) It compiles fine, using $ gcc -c user_number_input.c with no errors reported. Regards, Keith. |