public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/51644] New: [4.7 Regression] va_list vs. warning: ‘noreturn’ function does return is not fixable
@ 2011-12-20 21:36 jan.kratochvil at redhat dot com
  2011-12-21  9:18 ` [Bug c/51644] " burnus at gcc dot gnu.org
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: jan.kratochvil at redhat dot com @ 2011-12-20 21:36 UTC (permalink / raw)
  To: gcc-bugs

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

             Bug #: 51644
           Summary: [4.7 Regression] va_list vs. warning: ‘noreturn’
                    function does return is not fixable
    Classification: Unclassified
           Product: gcc
           Version: 4.7.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: jan.kratochvil@redhat.com


PASS: gcc (GCC) 4.6.3 20111220 (prerelease)
FAIL: gcc (GCC) 4.7.0 20111220 (experimental)

#include <stdarg.h>
extern __attribute__ ((__noreturn__)) void b (int s, va_list ap);
__attribute__ ((__noreturn__)) void a (int s, ...)
{
  va_list args;
  va_start (args, s);
  b (s, args);
  va_end (args);
}

-Wall -fexceptions

35.c:9:1: warning: ‘noreturn’ function does return [enabled by default]

It gets fixed by removing that "va_end" but I must not (suggested by Tom
Tromey):

ISO C99 7.15.1 
Each invocation of the va_start and va_copy macros shall be matched by a
corresponding invocation of the va_end macro in the same function.


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2011-12-21 15:33 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-12-20 21:36 [Bug c/51644] New: [4.7 Regression] va_list vs. warning: ‘noreturn’ function does return is not fixable jan.kratochvil at redhat dot com
2011-12-21  9:18 ` [Bug c/51644] " burnus at gcc dot gnu.org
2011-12-21  9:52 ` [Bug middle-end/51644] " rguenth at gcc dot gnu.org
2011-12-21  9:53 ` jakub at gcc dot gnu.org
2011-12-21  9:54 ` jakub at gcc dot gnu.org
2011-12-21 11:41 ` jakub at gcc dot gnu.org
2011-12-21 15:00 ` jakub at gcc dot gnu.org
2011-12-21 15:33 ` jakub at gcc dot gnu.org
2011-12-21 15:33 ` jakub at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).