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++/43881] warning attached to a function is emitted even though the function is not being called



------- Comment #3 from bruno at clisp dot org  2010-04-24 23:54 -------
When the line
  static int (*safe_close) (int fd) = close;
is changed to
  static int (*safe_close) (int fd) = ((void)0, close);
the warning also disappears, but then the generate code is suboptimal:
the variable safe_close is not eliminated from the 'data' section.
Therefore I cannot use this as a workaround.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=43881


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