summary refs log tree commit diff
path: root/bin/1sh
diff options
context:
space:
mode:
authorJune McEnroe <june@causal.agency>2020-06-07 16:26:50 -0400
committerJune McEnroe <june@causal.agency>2020-06-08 16:46:02 -0400
commit3177ae700a2ba82ef2282ddc5404d8de8646cd57 (patch)
treeff48920e981a92b37d9281f636d9dbe0fa451532 /bin/1sh
parentReplace __FBSDID macros with comments (diff)
downloadsrc-3177ae700a2ba82ef2282ddc5404d8de8646cd57.tar.gz
src-3177ae700a2ba82ef2282ddc5404d8de8646cd57.zip
Replace __dead2 with __attribute__((noreturn))
sed 's/__dead2/__attribute__((noreturn))/'
Diffstat (limited to '')
-rw-r--r--bin/1sh/arith_yacc.c2
-rw-r--r--bin/1sh/error.c2
-rw-r--r--bin/1sh/error.h8
-rw-r--r--bin/1sh/exec.h2
-rw-r--r--bin/1sh/mknodes.c2
-rw-r--r--bin/1sh/parser.c4
-rw-r--r--bin/1sh/test.c2
-rw-r--r--bin/1sh/trap.h4
8 files changed, 13 insertions, 13 deletions
diff --git a/bin/1sh/arith_yacc.c b/bin/1sh/arith_yacc.c
index 08e25ab3..57285831 100644
--- a/bin/1sh/arith_yacc.c
+++ b/bin/1sh/arith_yacc.c
@@ -86,7 +86,7 @@ static const char prec[ARITH_BINOP_MAX - ARITH_BINOP_MIN] = {
 
 int letcmd(int, char **);
 
-static __dead2 void yyerror(const char *s)
+static __attribute__((noreturn)) void yyerror(const char *s)
 {
 	error("arithmetic expression: %s: \"%s\"", s, arith_startbuf);
 	/* NOTREACHED */
diff --git a/bin/1sh/error.c b/bin/1sh/error.c
index 1cc55ded..62d406f5 100644
--- a/bin/1sh/error.c
+++ b/bin/1sh/error.c
@@ -67,7 +67,7 @@ volatile sig_atomic_t suppressint;
 volatile sig_atomic_t intpending;
 
 
-static void exverror(int, const char *, va_list) __printf0like(2, 0) __dead2;
+static void exverror(int, const char *, va_list) __printf0like(2, 0) __attribute__((noreturn));
 
 /*
  * Called to raise an exception.  Since C doesn't include exceptions, we
diff --git a/bin/1sh/error.h b/bin/1sh/error.h
index b6d6b413..964d98e8 100644
--- a/bin/1sh/error.h
+++ b/bin/1sh/error.h
@@ -79,11 +79,11 @@ extern volatile sig_atomic_t intpending;
 #define CLEAR_PENDING_INT intpending = 0
 #define int_pending() intpending
 
-void exraise(int) __dead2;
-void onint(void) __dead2;
+void exraise(int) __attribute__((noreturn));
+void onint(void) __attribute__((noreturn));
 void warning(const char *, ...) __printflike(1, 2);
-void error(const char *, ...) __printf0like(1, 2) __dead2;
-void exerror(int, const char *, ...) __printf0like(2, 3) __dead2;
+void error(const char *, ...) __printf0like(1, 2) __attribute__((noreturn));
+void exerror(int, const char *, ...) __printf0like(2, 3) __attribute__((noreturn));
 
 
 /*
diff --git a/bin/1sh/exec.h b/bin/1sh/exec.h
index 86cda649..f93c14c2 100644
--- a/bin/1sh/exec.h
+++ b/bin/1sh/exec.h
@@ -63,7 +63,7 @@ struct cmdentry {
 
 extern int exerrno;		/* last exec error */
 
-void shellexec(char **, char **, const char *, int) __dead2;
+void shellexec(char **, char **, const char *, int) __attribute__((noreturn));
 char *padvance(const char **, const char **, const char *);
 void find_command(const char *, struct cmdentry *, int, const char *);
 int find_builtin(const char *, int *);
diff --git a/bin/1sh/mknodes.c b/bin/1sh/mknodes.c
index a90acff1..e5eacb14 100644
--- a/bin/1sh/mknodes.c
+++ b/bin/1sh/mknodes.c
@@ -104,7 +104,7 @@ static void indent(int, FILE *);
 static int nextfield(char *);
 static void skipbl(void);
 static int readline(FILE *);
-static void error(const char *, ...) __printf0like(1, 2) __dead2;
+static void error(const char *, ...) __printf0like(1, 2) __attribute__((noreturn));
 static char *savestr(const char *);
 
 
diff --git a/bin/1sh/parser.c b/bin/1sh/parser.c
index a6f976ed..b2f761c8 100644
--- a/bin/1sh/parser.c
+++ b/bin/1sh/parser.c
@@ -126,8 +126,8 @@ static int xxreadtoken(void);
 static int readtoken1(int, const char *, const char *, int);
 static int noexpand(char *);
 static void consumetoken(int);
-static void synexpect(int) __dead2;
-static void synerror(const char *) __dead2;
+static void synexpect(int) __attribute__((noreturn));
+static void synerror(const char *) __attribute__((noreturn));
 static void setprompt(int);
 static char *expandprompt(const char *);
 static int pgetc_linecont(void);
diff --git a/bin/1sh/test.c b/bin/1sh/test.c
index 594a7d89..71c62e11 100644
--- a/bin/1sh/test.c
+++ b/bin/1sh/test.c
@@ -38,7 +38,7 @@
 #else
 #include <locale.h>
 
-static void error(const char *, ...) __dead2 __printf0like(1, 2);
+static void error(const char *, ...) __attribute__((noreturn)) __printf0like(1, 2);
 
 static void
 error(const char *msg, ...)
diff --git a/bin/1sh/trap.h b/bin/1sh/trap.h
index 88076fc2..75427d56 100644
--- a/bin/1sh/trap.h
+++ b/bin/1sh/trap.h
@@ -46,5 +46,5 @@ int issigchldtrapped(void);
 void onsig(int);
 void dotrap(void);
 void setinteractive(void);
-void exitshell(int) __dead2;
-void exitshell_savedstatus(void) __dead2;
+void exitshell(int) __attribute__((noreturn));
+void exitshell_savedstatus(void) __attribute__((noreturn));