+2012-06-24 Paul Eggert <eggert@cs.ucla.edu>
+
+ Switch from NO_RETURN to C11's _Noreturn (Bug#11750).
+ We might as well use the spelling standardized by C11,
+ as in the long run that should simplify maintenance.
+ * configure.in (NO_RETURN): Remove. All uses replaced by _Noreturn.
+
2012-06-24 Eli Zaretskii <eliz@gnu.org>
* lib/makefile.w32-in ($(BLD)/dtotimespec.$(O)):
#include <string.h>
#include <stdlib.h>
-#if defined __GNUC__ && (__GNUC__ > 2 \
- || (__GNUC__ == 2 && __GNUC_MINOR__ >= 5))
-#define NO_RETURN __attribute__ ((__noreturn__))
-#else
-#define NO_RETURN /* nothing */
-#endif
-
#if __GNUC__ >= 3 /* On GCC 3.0 we might get a warning. */
#define NO_INLINE __attribute__((noinline))
#else
+2012-06-24 Paul Eggert <eggert@cs.ucla.edu>
+
+ Switch from NO_RETURN to C11's _Noreturn (Bug#11750).
+ * ebrowse.c (usage, version):
+ * emacsclient.c (print_help_and_exit, fail):
+ * etags.c (suggest_asking_for_help, fatal, pfatal):
+ * hexl.c (usage):
+ * make-docfile.c (fatal):
+ * movemail.c (fatal, pfatal_with_name, pfatal_and_delete):
+ * update-game-score.c (usage):
+ * ebrowse.c (usage, version):
+ * emacsclient.c (print_help_and_exit, fail):
+ Use _Noreturn rather than NO_RETURN.
+ No need for separate decl merely because of _Noreturn.
+
2012-06-24 Samuel Bronson <naesten@gmail.com> (tiny change)
* emacsclient.c (set_local_socket): Fix compiler warning (Bug#7838).
static void class_definition (struct sym *, int, int, int);
static char *operator_name (int *);
static void parse_qualified_param_ident_or_type (char **);
-static void usage (int) NO_RETURN;
-static void version (void) NO_RETURN;
-
-
\f
/***********************************************************************
Utilities
--version display version info\n\
"
-static void
+static _Noreturn void
usage (int error)
{
puts (USAGE);
# define VERSION "21"
#endif
-static void
+static _Noreturn void
version (void)
{
/* Makes it easier to update automatically. */
be used for the new frame */
const char *frame_parameters = NULL;
-static void print_help_and_exit (void) NO_RETURN;
-static void fail (void) NO_RETURN;
+static _Noreturn void print_help_and_exit (void);
struct option longopts[] =
}
\f
-static void
+static _Noreturn void
print_help_and_exit (void)
{
/* Spaces and tabs are significant in this message; they're chosen so the
defined-- exit with an errorcode.
Uses argv, but gets it from the global variable main_argv.
*/
-static void
+static _Noreturn void
fail (void)
{
if (alternate_editor)
static void free_regexps (void);
static void regex_tag_multiline (void);
static void error (const char *, ...) ATTRIBUTE_FORMAT_PRINTF (1, 2);
-static void suggest_asking_for_help (void) NO_RETURN;
-void fatal (const char *, const char *) NO_RETURN;
-static void pfatal (const char *) NO_RETURN;
+static _Noreturn void suggest_asking_for_help (void);
+_Noreturn void fatal (const char *, const char *);
+static _Noreturn void pfatal (const char *);
static void add_node (node *, node **);
static void init (void);
int group_by = DEFAULT_GROUPING;
char *progname;
-void usage (void) NO_RETURN;
+_Noreturn void usage (void);
int
main (int argc, char **argv)
static int scan_file (char *filename);
static int scan_lisp_file (const char *filename, const char *mode);
static int scan_c_file (char *filename, const char *mode);
-static void fatal (const char *s1, const char *s2) NO_RETURN;
static void start_globals (void);
static void write_globals (void);
/* Print error message and exit. */
/* VARARGS1 */
-static void
+static _Noreturn void
fatal (const char *s1, const char *s2)
{
error (s1, s2);
char *strerror (int);
#endif
-static void fatal (const char *s1, const char *s2, const char *s3) NO_RETURN;
+static _Noreturn void fatal (const char *s1, const char *s2, const char *s3);
static void error (const char *s1, const char *s2, const char *s3);
-static void pfatal_with_name (char *name) NO_RETURN;
-static void pfatal_and_delete (char *name) NO_RETURN;
+static _Noreturn void pfatal_with_name (char *name);
+static _Noreturn void pfatal_and_delete (char *name);
static char *concat (const char *s1, const char *s2, const char *s3);
static long *xmalloc (unsigned int size);
#ifdef MAIL_USE_POP
#include <sys/stat.h>
#include <getopt.h>
-static int usage (int err) NO_RETURN;
-
#define MAX_ATTEMPTS 5
#define MAX_SCORES 200
#define MAX_DATA_LEN 1024
#define difftime(t1, t0) (double)((t1) - (t0))
#endif
-static int
+static _Noreturn void
usage (int err)
{
fprintf (stdout, "Usage: update-game-score [-m MAX] [-r] [-d DIR] game/scorefile SCORE DATA\n");
static int write_scores (const char *filename,
const struct score_entry *scores, int count);
-static void lose (const char *msg) NO_RETURN;
-
-static void
+static _Noreturn void
lose (const char *msg)
{
fprintf (stderr, "%s\n", msg);
exit (EXIT_FAILURE);
}
-static void lose_syserr (const char *msg) NO_RETURN;
-
/* Taken from sysdep.c. */
#ifndef HAVE_STRERROR
#ifndef WINDOWSNT
#endif /* not WINDOWSNT */
#endif /* ! HAVE_STRERROR */
-static void
+static _Noreturn void
lose_syserr (const char *msg)
{
fprintf (stderr, "%s: %s\n", msg, strerror (errno));
+2012-06-24 Paul Eggert <eggert@cs.ucla.edu>
+
+ Switch from NO_RETURN to C11's _Noreturn (Bug#11750).
+ * xlwmenu.c (abort_gracefully):
+ Use _Noreturn rather than NO_RETURN.
+ No need for separate decl merely because of _Noreturn.
+
2012-05-31 Paul Eggert <eggert@cs.ucla.edu>
Remove obsolete '#define static' cruft.
static void Nothing(Widget w, XEvent *ev, String *params, Cardinal *num_params);
static int separator_height (enum menu_separator);
static void pop_up_menu (XlwMenuWidget, XButtonPressedEvent *);
-static void abort_gracefully (Widget w) NO_RETURN;
static XtActionsRec
xlwMenuActionsList [] =
/* Like abort, but remove grabs from widget W before. */
-static void
+static _Noreturn void
abort_gracefully (Widget w)
{
if (XtIsShell (XtParent (w)))
+2012-06-24 Paul Eggert <eggert@cs.ucla.edu>
+
+ Switch from NO_RETURN to C11's _Noreturn (Bug#11750).
+ * config.nt (_Noreturn): New macro.
+ (NO_RETURN): Remove. All uses replaced with _Noreturn.
+ (w32_abort) [HAVE_NTGUI]: Use _Noreturn rather than NO_RETURN.
+
2012-06-24 Eli Zaretskii <eliz@gnu.org>
* inc/sys/time.h (struct timespec): Don't define it here, it is
#endif
#include <stdlib.h>
-#ifndef NO_RETURN
-#if defined __GNUC__ && (__GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR >= 5))
-#define NO_RETURN __attribute__ ((__noreturn__))
-#else
-#define NO_RETURN /* nothing */
-#endif
+/* The _Noreturn keyword of C11. */
+#if ! (defined _Noreturn \
+ || (defined __STDC_VERSION__ && 201112 <= __STDC_VERSION__))
+# if (3 <= __GNUC__ || (__GNUC__ == 2 && 8 <= __GNUC_MINOR__) \
+ || 0x5110 <= __SUNPRO_C)
+# define _Noreturn __attribute__ ((__noreturn__))
+# elif defined _MSC_VER && 1200 <= _MSC_VER
+# define _Noreturn __declspec (noreturn)
+# else
+# define _Noreturn
+# endif
#endif
/* Redefine abort. */
#ifdef HAVE_NTGUI
#define abort w32_abort
-void w32_abort (void) NO_RETURN;
+_Noreturn void w32_abort (void);
#endif
/* Prevent accidental use of features unavailable in
* s/ms-w32.h (struct timespec): Definition moved from
nt/inc/sys/time.h. Suggested by Paul Eggert <eggert@cs.ucla.edu>.
+2012-06-24 Paul Eggert <eggert@cs.ucla.edu>
+
+ Switch from NO_RETURN to C11's _Noreturn (Bug#11750).
+ * buffer.h (buffer_slot_type_mismatch):
+ * data.c (arith_error) [!FORWARD_SIGNAL_TO_MAIN_THREAD]:
+ * eval.c (unwind_to_catch):
+ * image.c (my_png_error, my_error_exit):
+ * keyboard.c (quit_throw_to_read_char, user_error)
+ (Fexit_recursive_edit, Fabort_recursive_edit):
+ * lisp.h (die, args_out_of_range, args_out_of_range_3)
+ (wrong_type_argument, buffer_overflow, __executable_start)
+ (memory_full, buffer_memory_full, string_overflow, Fthrow)
+ (xsignal, xsignal0, xsignal1, xsignal2, xsignal3, signal_error)
+ (error, verror, nsberror, report_file_error, Ftop_level, Fkill_emacs)
+ (fatal):
+ (child_setup) [!DOS_NT]:
+ * lread.c (end_of_file_error, invalid_syntax):
+ * process.c (send_process_trap) [!FORWARD_SIGNAL_TO_MAIN_THREAD]:
+ * puresize.h (pure_write_error):
+ * search.c (matcher_overflow):
+ * sound.c (sound_perror, alsa_sound_perror):
+ * sysdep.c, syssignal.h (croak):
+ * term.c (maybe_fatal, vfatal):
+ * textprop.c (text_read_only):
+ * undo.c (user_error):
+ * unexmacosx.c (unexec_error):
+ * xterm.c (x_ins_del_lines, x_delete_glyphs):
+ Use _Noreturn rather than NO_RETURN.
+ No need for separate decl merely because of _Noreturn.
+ * sound.c (sound_warning, parse_sound):
+ Remove unnecessary forward decls.
+
2012-06-24 Paul Eggert <eggert@cs.ucla.edu>
Fix bug when time_t is unsigned and as wide as intmax_t (Bug#9000).
extern void set_buffer_temp (struct buffer *);
extern Lisp_Object buffer_local_value_1 (Lisp_Object, Lisp_Object);
extern void record_buffer (Lisp_Object);
-extern void buffer_slot_type_mismatch (Lisp_Object, int) NO_RETURN;
+extern _Noreturn void buffer_slot_type_mismatch (Lisp_Object, int);
extern void fix_overlays_before (struct buffer *, ptrdiff_t, ptrdiff_t);
extern void mmap_set_vars (int);
}
#ifndef FORWARD_SIGNAL_TO_MAIN_THREAD
-static void arith_error (int) NO_RETURN;
+_Noreturn
#endif
-
static void
arith_error (int signo)
{
Lisp_Object inhibit_lisp_code;
static Lisp_Object funcall_lambda (Lisp_Object, ptrdiff_t, Lisp_Object *);
-static void unwind_to_catch (struct catchtag *, Lisp_Object) NO_RETURN;
static int interactive_p (int);
static Lisp_Object apply_lambda (Lisp_Object fun, Lisp_Object args);
static Lisp_Object Ffetch_bytecode (Lisp_Object);
This is used for correct unwinding in Fthrow and Fsignal. */
-static void
+static _Noreturn void
unwind_to_catch (struct catchtag *catch, Lisp_Object value)
{
- register int last_time;
+ int last_time;
/* Save the value in the tag. */
catch->val = value;
/* Error and warning handlers installed when the PNG library
is initialized. */
-static void my_png_error (png_struct *, const char *) NO_RETURN;
-static void
+static _Noreturn void
my_png_error (png_struct *png_ptr, const char *msg)
{
xassert (png_ptr != NULL);
};
-static void my_error_exit (j_common_ptr) NO_RETURN;
-static void
+static _Noreturn void
my_error_exit (j_common_ptr cinfo)
{
struct my_jpeg_error_mgr *mgr = (struct my_jpeg_error_mgr *) cinfo->err;
static Lisp_Object (Fcommand_execute) (Lisp_Object, Lisp_Object, Lisp_Object,
Lisp_Object);
static void handle_interrupt (void);
-static void quit_throw_to_read_char (int) NO_RETURN;
+static _Noreturn void quit_throw_to_read_char (int);
static void process_special_events (void);
static void timer_start_idle (void);
static void timer_stop_idle (void);
Fthrow (Qtop_level, Qnil);
}
-static void user_error (const char*) NO_RETURN;
-static void user_error (const char *msg)
+static _Noreturn void
+user_error (const char *msg)
{
xsignal1 (Quser_error, build_string (msg));
}
-static Lisp_Object Fexit_recursive_edit (void) NO_RETURN;
+_Noreturn
DEFUN ("exit-recursive-edit", Fexit_recursive_edit, Sexit_recursive_edit, 0, 0, "",
doc: /* Exit from the innermost recursive edit or minibuffer. */)
(void)
user_error ("No recursive edit is in progress");
}
-static Lisp_Object Fabort_recursive_edit (void) NO_RETURN;
+_Noreturn
DEFUN ("abort-recursive-edit", Fabort_recursive_edit, Sabort_recursive_edit, 0, 0, "",
doc: /* Abort the command that requested this recursive edit or minibuffer input. */)
(void)
# define eassert(X) ((void) (0 && (X))) /* Check that X compiles. */
#else /* ENABLE_CHECKING */
-extern void die (const char *, const char *, int) NO_RETURN;
+extern _Noreturn void die (const char *, const char *, int);
/* The suppress_checking variable is initialized to 0 in alloc.c. Set
it to 1 using a debugger to temporarily disable aborting on
extern uintmax_t cons_to_unsigned (Lisp_Object, uintmax_t);
extern struct Lisp_Symbol *indirect_variable (struct Lisp_Symbol *);
-extern void args_out_of_range (Lisp_Object, Lisp_Object) NO_RETURN;
-extern void args_out_of_range_3 (Lisp_Object, Lisp_Object,
- Lisp_Object) NO_RETURN;
-extern Lisp_Object wrong_type_argument (Lisp_Object, Lisp_Object) NO_RETURN;
+extern _Noreturn void args_out_of_range (Lisp_Object, Lisp_Object);
+extern _Noreturn void args_out_of_range_3 (Lisp_Object, Lisp_Object,
+ Lisp_Object);
+extern _Noreturn Lisp_Object wrong_type_argument (Lisp_Object, Lisp_Object);
extern Lisp_Object do_symval_forwarding (union Lisp_Fwd *);
extern void set_internal (Lisp_Object, Lisp_Object, Lisp_Object, int);
extern void syms_of_data (void);
extern Lisp_Object Qinhibit_modification_hooks;
extern void move_gap (ptrdiff_t);
extern void move_gap_both (ptrdiff_t, ptrdiff_t);
-extern void buffer_overflow (void) NO_RETURN;
+extern _Noreturn void buffer_overflow (void);
extern void make_gap (ptrdiff_t);
extern ptrdiff_t copy_text (const unsigned char *, unsigned char *,
ptrdiff_t, int, int);
/* Defined in dispnew.c */
#if (defined PROFILING \
&& (defined __FreeBSD__ || defined GNU_LINUX || defined __MINGW32__))
-void __executable_start (void) NO_RETURN;
+_Noreturn void __executable_start (void);
#endif
extern Lisp_Object selected_frame;
extern Lisp_Object Vwindow_system;
extern void reset_malloc_hooks (void);
extern void uninterrupt_malloc (void);
extern void malloc_warning (const char *);
-extern void memory_full (size_t) NO_RETURN;
-extern void buffer_memory_full (ptrdiff_t) NO_RETURN;
+extern _Noreturn void memory_full (size_t);
+extern _Noreturn void buffer_memory_full (ptrdiff_t);
extern int survives_gc_p (Lisp_Object);
extern void mark_object (Lisp_Object);
#if defined REL_ALLOC && !defined SYSTEM_MALLOC
EXFUN (Fvector, MANY);
EXFUN (Fmake_symbol, 1);
EXFUN (Fmake_marker, 0);
-extern void string_overflow (void) NO_RETURN;
+extern _Noreturn void string_overflow (void);
EXFUN (Fmake_string, 2);
extern Lisp_Object build_string (const char *);
extern Lisp_Object make_string (const char *, ptrdiff_t);
(ptrdiff_t nargs, Lisp_Object *args));
EXFUN (Fprogn, UNEVALLED);
EXFUN (Finteractive_p, 0);
-EXFUN (Fthrow, 2) NO_RETURN;
+_Noreturn EXFUN (Fthrow, 2);
EXFUN (Fsignal, 2);
-extern void xsignal (Lisp_Object, Lisp_Object) NO_RETURN;
-extern void xsignal0 (Lisp_Object) NO_RETURN;
-extern void xsignal1 (Lisp_Object, Lisp_Object) NO_RETURN;
-extern void xsignal2 (Lisp_Object, Lisp_Object, Lisp_Object) NO_RETURN;
-extern void xsignal3 (Lisp_Object, Lisp_Object, Lisp_Object, Lisp_Object) NO_RETURN;
-extern void signal_error (const char *, Lisp_Object) NO_RETURN;
+extern _Noreturn void xsignal (Lisp_Object, Lisp_Object);
+extern _Noreturn void xsignal0 (Lisp_Object);
+extern _Noreturn void xsignal1 (Lisp_Object, Lisp_Object);
+extern _Noreturn void xsignal2 (Lisp_Object, Lisp_Object, Lisp_Object);
+extern _Noreturn void xsignal3 (Lisp_Object, Lisp_Object, Lisp_Object,
+ Lisp_Object);
+extern _Noreturn void signal_error (const char *, Lisp_Object);
EXFUN (Fcommandp, 2);
EXFUN (Ffunctionp, 1);
EXFUN (Feval, 2);
extern void specbind (Lisp_Object, Lisp_Object);
extern void record_unwind_protect (Lisp_Object (*) (Lisp_Object), Lisp_Object);
extern Lisp_Object unbind_to (ptrdiff_t, Lisp_Object);
-extern void error (const char *, ...) NO_RETURN ATTRIBUTE_FORMAT_PRINTF (1, 2);
-extern void verror (const char *, va_list)
- NO_RETURN ATTRIBUTE_FORMAT_PRINTF (1, 0);
+extern _Noreturn void error (const char *, ...) ATTRIBUTE_FORMAT_PRINTF (1, 2);
+extern _Noreturn void verror (const char *, va_list)
+ ATTRIBUTE_FORMAT_PRINTF (1, 0);
extern void do_autoload (Lisp_Object, Lisp_Object);
extern Lisp_Object un_autoload (Lisp_Object);
extern void init_eval_once (void);
EXFUN (Fwiden, 0);
EXFUN (Fuser_login_name, 1);
EXFUN (Fsystem_name, 0);
-extern void time_overflow (void) NO_RETURN;
+extern _Noreturn void time_overflow (void);
EXFUN (Fcurrent_time, 0);
EXFUN (Fget_internal_run_time, 0);
extern Lisp_Object make_buffer_string (ptrdiff_t, ptrdiff_t, int);
/* Defined in buffer.c */
extern int mouse_face_overlay_overlaps (Lisp_Object);
-extern void nsberror (Lisp_Object) NO_RETURN;
+extern _Noreturn void nsberror (Lisp_Object);
EXFUN (Fset_buffer_multibyte, 1);
EXFUN (Foverlay_start, 1);
EXFUN (Foverlay_end, 1);
EXFUN (Fread_file_name, 6);
extern Lisp_Object close_file_unwind (Lisp_Object);
extern Lisp_Object restore_point_unwind (Lisp_Object);
-extern void report_file_error (const char *, Lisp_Object) NO_RETURN;
+extern _Noreturn void report_file_error (const char *, Lisp_Object);
extern int internal_delete_file (Lisp_Object);
extern void syms_of_fileio (void);
extern Lisp_Object make_temp_name (Lisp_Object, int);
extern int input_pending;
EXFUN (Fdiscard_input, 0);
EXFUN (Frecursive_edit, 0);
-EXFUN (Ftop_level, 0) NO_RETURN;
+_Noreturn EXFUN (Ftop_level, 0);
extern Lisp_Object menu_bar_items (Lisp_Object);
extern Lisp_Object tool_bar_items (Lisp_Object, int *);
extern void discard_mouse_events (void);
extern void fatal_error_signal (int);
#endif
extern Lisp_Object Qkill_emacs;
-EXFUN (Fkill_emacs, 1) NO_RETURN;
+_Noreturn EXFUN (Fkill_emacs, 1);
#if HAVE_SETLOCALE
void fixup_locale (void);
void synchronize_system_messages_locale (void);
extern void setup_process_coding_systems (Lisp_Object);
EXFUN (Fcall_process, MANY);
-extern int child_setup (int, int, int, char **, int, Lisp_Object)
#ifndef DOS_NT
- NO_RETURN
+ _Noreturn
#endif
- ;
+extern int child_setup (int, int, int, char **, int, Lisp_Object);
extern void init_callproc_1 (void);
extern void init_callproc (void);
extern void set_initial_environment (void);
extern int *char_ins_del_vector;
extern void mark_ttys (void);
extern void syms_of_term (void);
-extern void fatal (const char *msgid, ...)
- NO_RETURN ATTRIBUTE_FORMAT_PRINTF (1, 2);
+extern _Noreturn void fatal (const char *msgid, ...)
+ ATTRIBUTE_FORMAT_PRINTF (1, 2);
/* Defined in terminal.c */
EXFUN (Fframe_terminal, 1);
Lisp_Object, Lisp_Object);
static Lisp_Object load_unwind (Lisp_Object);
static Lisp_Object load_descriptor_unwind (Lisp_Object);
-
-static void invalid_syntax (const char *) NO_RETURN;
-static void end_of_file_error (void) NO_RETURN;
-
\f
/* Functions that read one byte from the current source READCHARFUN
or unreads one byte. If the integer argument C is -1, it returns
/* Signal an `end-of-file' error, if possible with file name
information. */
-static void
+static _Noreturn void
end_of_file_error (void)
{
if (STRINGP (Vload_file_name))
/* Signal Qinvalid_read_syntax error.
S is error string of length N (if > 0) */
-static void
+static _Noreturn void
invalid_syntax (const char *s)
{
xsignal1 (Qinvalid_read_syntax, build_string (s));
static Lisp_Object process_sent_to;
#ifndef FORWARD_SIGNAL_TO_MAIN_THREAD
-static void send_process_trap (int) NO_RETURN;
+static _Noreturn void send_process_trap (int);
#endif
static void
{ if (PURE_P (obj)) \
pure_write_error (); }
-extern void pure_write_error (void) NO_RETURN;
+extern _Noreturn void pure_write_error (void);
\f
/* Define PURE_P. */
static EMACS_INT search_buffer (Lisp_Object, ptrdiff_t, ptrdiff_t,
ptrdiff_t, ptrdiff_t, EMACS_INT, int,
Lisp_Object, Lisp_Object, int);
-static void matcher_overflow (void) NO_RETURN;
-static void
+static _Noreturn void
matcher_overflow (void)
{
error ("Stack overflow in regexp matcher");
SOUND_ATTR_SENTINEL
};
-#ifdef HAVE_ALSA
-static void alsa_sound_perror (const char *, int) NO_RETURN;
-#endif
-static void sound_perror (const char *) NO_RETURN;
-static void sound_warning (const char *);
-static int parse_sound (Lisp_Object, Lisp_Object *);
-
/* END: Common Definitions */
/* BEGIN: Non Windows Definitions */
/* Like perror, but signals an error. */
-static void
+static _Noreturn void
sound_perror (const char *msg)
{
int saved_errno = errno;
#define DEFAULT_ALSA_SOUND_DEVICE "default"
#endif
-static void
+static _Noreturn void
alsa_sound_perror (const char *msg, int err)
{
error ("%s: %s", msg, snd_strerror (err));
static int emacs_get_tty (int, struct emacs_tty *);
static int emacs_set_tty (int, struct emacs_tty *, int);
#if defined TIOCNOTTY || defined USG5 || defined CYGWIN
-static void croak (char *) NO_RETURN;
+static _Noreturn void croak (char *);
#endif
/* Declare here, including term.h is problematic on some systems. */
sigset_t sys_sigunblock (sigset_t new_mask);
sigset_t sys_sigsetmask (sigset_t new_mask);
#if ! (defined TIOCNOTTY || defined USG5 || defined CYGWIN)
-void croak (char *) NO_RETURN;
+_Noreturn void croak (char *);
#endif
#define sys_sigdel(MASK,SIG) sigdelset (&MASK,SIG)
static void set_tty_hooks (struct terminal *terminal);
static void dissociate_if_controlling_tty (int fd);
static void delete_tty (struct terminal *);
-static void maybe_fatal (int must_succeed, struct terminal *terminal,
- const char *str1, const char *str2, ...)
- NO_RETURN ATTRIBUTE_FORMAT_PRINTF (3, 5) ATTRIBUTE_FORMAT_PRINTF (4, 5);
-static void vfatal (const char *str, va_list ap)
- NO_RETURN ATTRIBUTE_FORMAT_PRINTF (1, 0);
+static _Noreturn void maybe_fatal (int must_succeed, struct terminal *terminal,
+ const char *str1, const char *str2, ...)
+ ATTRIBUTE_FORMAT_PRINTF (3, 5) ATTRIBUTE_FORMAT_PRINTF (4, 5);
+static _Noreturn void vfatal (const char *str, va_list ap)
+ ATTRIBUTE_FORMAT_PRINTF (1, 0);
#define OUTPUT(tty, a) \
static Lisp_Object interval_insert_behind_hooks;
static Lisp_Object interval_insert_in_front_hooks;
-static void text_read_only (Lisp_Object) NO_RETURN;
static Lisp_Object Fprevious_property_change (Lisp_Object, Lisp_Object,
Lisp_Object);
/* Signal a `text-read-only' error. This function makes it easier
to capture that error in GDB by putting a breakpoint on it. */
-static void
+static _Noreturn void
text_read_only (Lisp_Object propval)
{
if (STRINGP (propval))
unbind_to (count, Qnil);
}
-static void user_error (const char*) NO_RETURN;
-static void user_error (const char *msg)
+static _Noreturn void
+user_error (const char *msg)
{
xsignal1 (Quser_error, build_string (msg));
}
static struct segment_command *data_segment_scp;
-static void unexec_error (const char *format, ...) NO_RETURN;
-
/* Read N bytes from infd into memory starting at address DEST.
Return true if successful, false otherwise. */
static int
/* Debugging and informational messages routines. */
-static void
+static _Noreturn void
unexec_error (const char *format, ...)
{
va_list ap;
static void XTset_terminal_modes (struct terminal *);
static void XTreset_terminal_modes (struct terminal *);
static void x_clear_frame (struct frame *);
-static void x_ins_del_lines (struct frame *, int, int) NO_RETURN;
+static _Noreturn void x_ins_del_lines (struct frame *, int, int);
static void frame_highlight (struct frame *);
static void frame_unhighlight (struct frame *);
static void x_new_focus_frame (struct x_display_info *, struct frame *);
#ifdef USE_GTK
static int x_dispatch_event (XEvent *, Display *);
#endif
-/* Don't declare this NO_RETURN because we want no
+/* Don't declare this _Noreturn because we want no
interference with debugging failing X calls. */
static void x_connection_closed (Display *, const char *);
static void x_wm_set_window_state (struct frame *, int);
static void x_draw_composite_glyph_string_foreground (struct glyph_string *);
static void x_draw_glyph_string_box (struct glyph_string *);
static void x_draw_glyph_string (struct glyph_string *);
-static void x_delete_glyphs (struct frame *, int) NO_RETURN;
+static _Noreturn void x_delete_glyphs (struct frame *, int);
static void x_compute_glyph_string_overhangs (struct glyph_string *);
static void x_set_cursor_gc (struct glyph_string *);
static void x_set_mode_line_face_gc (struct glyph_string *);