diff options
author | Brian Fraser <fraserbn@gmail.com> | 2014-05-31 01:19:27 +0200 |
---|---|---|
committer | Brian Fraser <fraserbn@gmail.com> | 2014-06-13 00:00:32 +0200 |
commit | 117af67d6291466ff217023a9cf58832c511d1a0 (patch) | |
tree | 0505c6623503294e013390ad7f308523c87b4839 /util.c | |
parent | eb212a1c9a3761a08a3701a8559b60cdaf819dd1 (diff) | |
download | perl-117af67d6291466ff217023a9cf58832c511d1a0.tar.gz |
Mark several functions with __attribute__noreturn__
Namely, die_nocontext, die, die_sv, and screaminstr. They
all croak and never return, so let's mark them as non-returning.
Diffstat (limited to 'util.c')
-rw-r--r-- | util.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -925,7 +925,7 @@ Perl_screaminstr(pTHX_ SV *bigstr, SV *littlestr, I32 start_shift, I32 end_shift /* This function must only ever be called on a scalar with study magic, but those do not happen any more. */ Perl_croak(aTHX_ "panic: screaminstr"); - return NULL; + NORETURN_FUNCTION_END; } /* @@ -1568,7 +1568,7 @@ Perl_die_sv(pTHX_ SV *baseex) PERL_ARGS_ASSERT_DIE_SV; croak_sv(baseex); assert(0); /* NOTREACHED */ - return NULL; + NORETURN_FUNCTION_END; } /* @@ -1591,7 +1591,7 @@ Perl_die_nocontext(const char* pat, ...) vcroak(pat, &args); assert(0); /* NOTREACHED */ va_end(args); - return NULL; + NORETURN_FUNCTION_END; } #endif /* PERL_IMPLICIT_CONTEXT */ @@ -1603,7 +1603,7 @@ Perl_die(pTHX_ const char* pat, ...) vcroak(pat, &args); assert(0); /* NOTREACHED */ va_end(args); - return NULL; + NORETURN_FUNCTION_END; } /* |