1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-03-24 07:41:54 -07:00

Fix the build for gcc on os x: gcc warns about the missing return in protcatchthread, but we don't want to add one because that would be unreachable code. so use __attribute__((__noreturn__)) instead.

Copied from Perforce
 Change: 185461
 ServerID: perforce.ravenbrook.com
This commit is contained in:
Gareth Rees 2014-04-11 12:42:26 +01:00
parent 24aef39a77
commit fb2443daaa
2 changed files with 11 additions and 0 deletions

View file

@ -231,6 +231,16 @@
#define ATTRIBUTE_NO_SANITIZE_ADDRESS
#endif
/* Attribute for functions that do not return.
* GCC: <http://gcc.gnu.org/onlinedocs/gcc/Function-Attributes.html>
* Clang: <http://clang.llvm.org/docs/AttributeReference.html#id1>
*/
#if defined(MPS_BUILD_GC) || defined(MPS_BUILD_LL)
#define ATTRIBUTE_NORETURN __attribute__((__noreturn__))
#else
#define ATTRIBUTE_NORETURN
#endif
/* EPVMDefaultSubsequentSegSIZE is a default for the alignment of
* subsequent segments (non-initial at each save level) in EPVM. See

View file

@ -282,6 +282,7 @@ static void protCatchOne(void)
* handler won't cause a deadlock.
*/
ATTRIBUTE_NORETURN
static void *protCatchThread(void *p) {
UNUSED(p);
for (;;)