delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
X-SWARE-Spam-Status: | No, hits=-1.5 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_NONE,RCVD_IN_HOSTKARMA_YE |
X-Spam-Check-By: | sourceware.org |
X-Mail-Handler: | Dyn Standard SMTP by Dyn |
X-Report-Abuse-To: | abuse AT dyndns DOT com (see http://www.dyndns.com/services/sendlabs/outbound_abuse.html for abuse reporting information) |
X-MHO-User: | U2FsdGVkX19Di/XKOpxkfkef/jyr6iF5 |
Date: | Mon, 14 Jan 2013 16:17:56 -0500 |
From: | Christopher Faylor <cgf-use-the-mailinglist-please AT cygwin DOT com> |
To: | cygwin AT cygwin DOT com |
Subject: | Re: adding noreturn attribute to pthread_exit |
Message-ID: | <20130114211756.GA824@ednor.casa.cgf.cx> |
Reply-To: | cygwin AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
References: | <50F470CA DOT 5030400 AT iki DOT fi> |
MIME-Version: | 1.0 |
In-Reply-To: | <50F470CA.5030400@iki.fi> |
User-Agent: | Mutt/1.5.20 (2009-06-14) |
Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
List-Id: | <cygwin.cygwin.com> |
List-Unsubscribe: | <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com> |
List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
List-Archive: | <http://sourceware.org/ml/cygwin/> |
List-Post: | <mailto:cygwin AT cygwin DOT com> |
List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
Sender: | cygwin-owner AT cygwin DOT com |
Mail-Followup-To: | cygwin AT cygwin DOT com |
Delivered-To: | mailing list cygwin AT cygwin DOT com |
On Mon, Jan 14, 2013 at 09:55:38PM +0100, Antti Kantee wrote: >Hi, > >Calling pthread_exit() at the end of a routine marked noreturn produces >a compiler warning/error on cygwin: > >error: 'noreturn' function does return > >Is it possible to add the attribute to the cygwin pthread.h: > >--- pthread.h.orig 2012-10-19 14:40:13.000000000 +0200 >+++ pthread.h 2013-01-14 21:40:00.018198900 +0100 >@@ -137,7 +137,7 @@ > void *(*)(void *), void *); > int pthread_detach (pthread_t); > int pthread_equal (pthread_t, pthread_t); >-void pthread_exit (void *); >+void pthread_exit (void *) __attribute__((__noreturn__)); > int pthread_getcpuclockid (pthread_t, clockid_t *); > int pthread_getschedparam (pthread_t, int *, struct sched_param *); > void *pthread_getspecific (pthread_key_t); I added a ChangeLog entry and checked this in. Thanks for the patch. cgf -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |