From: Martin Baute Date: Sun, 13 Mar 2016 06:43:07 +0000 (+0100) Subject: is defined to be just this. Including it in a C++ context is the... X-Git-Url: https://pd.if.org/git/?p=pdclib;a=commitdiff_plain;h=0bfd3aa28ccec8c35481fe04d1dc82a0f1f522e6 is defined to be just this. Including it in a C++ context is the user's fault; no need to protect against this. --- diff --git a/includes/stdnoreturn.h b/includes/stdnoreturn.h index 5997ff6..c425308 100644 --- a/includes/stdnoreturn.h +++ b/includes/stdnoreturn.h @@ -1,16 +1,12 @@ -#ifndef _PDCLIB_STDNORETURN_H -#define _PDCLIB_STDNORETURN_H -#include <_PDCLIB_aux.h> +/* _Noreturn -#ifndef __cplusplus -/* This is problematic - if we don't define it, then C code can't be compiled - * on a C++ compiler. If we do define it, then we break all instances of C++ - * [[noreturn]] - * - * This does not appear well thought out... - */ -#define noreturn _PDCLIB_noreturn -#endif + This file is part of the Public Domain C Library (PDCLib). + Permission is granted to use, modify, and / or redistribute at will. +*/ + +#ifndef _PDCLIB_STDNORETURN_H +#define _PDCLIB_STDNORETURN_H _PDCLIB_STDNORETURN_H +#define noreturn _Noreturn #endif