public inbox for gcc-prs@sourceware.org
help / color / mirror / Atom feed
From: h.b.furuseth@usit.uio.no
To: gcc-gnats@gcc.gnu.org
Cc: h.b.furuseth@usit.uio.no
Subject: c/3408: spurious, misplaced warning: 'will never be executed'
Date: Mon, 25 Jun 2001 08:16:00 -0000	[thread overview]
Message-ID: <E15EY1B-0003VP-00@bombur.uio.no> (raw)

>Number:         3408
>Category:       c
>Synopsis:       spurious, misplaced warning: 'will never be executed'
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Jun 25 08:16:00 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator:     Hallvard B Furuseth
>Release:        3.0
>Organization:
>Environment:
System: SunOS bombur.uio.no 5.8 Generic_108528-03 sun4u sparc SUNW,Ultra-5_10
Architecture: sun4

	
host: sparc-sun-solaris2.8
build: sparc-sun-solaris2.8
target: sparc-sun-solaris2.8
configured with: ./configure --quiet --prefix=/usit/bombur/hbf --program-suffix=-3.0
>Description:
	`-O3 -Wunreachable-code' gives a spurious `will never be executed'
	warning.  It is misplaced as well; the warning it refers to
	function `c' - at line 6 which ends function `b'.

>How-To-Repeat:
	bash$ cat a.c
	void a(void);
	
	void b(void)
	{
	  a();
	}       /* line 6 */
	
	void c(int i)
	{
	  if (i)
	    b();
	}
	
	bash$ ./xgcc -B./ -O3 -Wunreachable-code -S a.c
	a.c: In function `c':
	a.c:6: warning: will never be executed
>Fix:
>Release-Note:
>Audit-Trail:
>Unformatted:


                 reply	other threads:[~2001-06-25  8:16 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=E15EY1B-0003VP-00@bombur.uio.no \
    --to=h.b.furuseth@usit.uio.no \
    --cc=gcc-gnats@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).