This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c/78068] New: warning: implicit declaration of function ‘time’; did you mean ‘nice’? [-Wimplicit-function-declaration]


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78068

            Bug ID: 78068
           Summary: warning: implicit declaration of function ‘time’; did
                    you mean ‘nice’? [-Wimplicit-function-declaration]
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: trippels at gcc dot gnu.org
                CC: dmalcolm at gcc dot gnu.org
  Target Milestone: ---

Created attachment 39864
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=39864&action=edit
unreduced testcase

Building binutils trunk on ppc64le shows:

trippels@gcc2-power8 ppc % ~/gcc_7/usr/local/bin/gcc --save-temps -c -g -O2
-DDEFAULT_INLINE=PSIM_INLINE_LOCALS -DWITH_HOST_BYTE_ORDER=LITTLE_ENDIAN
-DWITH_SMP=5 -DHAVE_TERMIOS_STRUCTURE -DHAVE_TERMIOS_CLINE -DHAVE_DEVZERO -I.
-I. -I./../../include -I../../bfd -I./../../bfd -I../../gdb -I./../../gdb
-I./../../gdb/config -DHAVE_COMMON_FPU -I../common -I./../common emul_unix.c    
emul_unix.c: In function ‘do_unix_time’:
emul_unix.c:818:16: warning: implicit declaration of function ‘time’; did you
mean ‘nice’? [-Wimplicit-function-declaration]
   time_t now = time ((time_t *)0);
                ^~~~
                nice

 % gcc -c emul_unix.i
emul_unix.c: In function ‘do_unix_time’:
emul_unix.c:818:16: warning: implicit declaration of function ‘time’; did you
mean ‘nice’? [-Wimplicit-function-declaration]

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]