New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[PATCH] Add four NOT_REACHED to quiet warnings #15897
Comments
From @petdanceCreated by @petdanceAdd four NOT_REACHED lines to quiet warnings that come up with clang Perl Info
|
From @petdance0001-Add-NOT_REACHED-to-quiet-clang-Weverything-warnings.patchFrom a0ac08519f56e859ff7049497cc4e6aadff13e33 Mon Sep 17 00:00:00 2001
From: Andy Lester <andy@petdance.com>
Date: Sun, 26 Feb 2017 21:15:46 -0600
Subject: [PATCH] Add NOT_REACHED to quiet clang -Weverything warnings
---
gv.c | 1 +
sv.c | 3 +++
2 files changed, 4 insertions(+)
diff --git a/gv.c b/gv.c
index 8c85614..915fee8 100644
--- a/gv.c
+++ b/gv.c
@@ -385,6 +385,7 @@ Perl_gv_init_pvn(pTHX_ GV *gv, HV *stash, const char *name, STRLEN len, U32 flag
case SVt_PVIO:
Perl_croak(aTHX_ "Cannot convert a reference to %s to typeglob",
sv_reftype(has_constant, 0));
+ NOT_REACHED; /* NOTREACHED */
break;
default: NOOP;
diff --git a/sv.c b/sv.c
index e90ea84..5ae4ce3 100644
--- a/sv.c
+++ b/sv.c
@@ -1651,6 +1651,7 @@ Perl_sv_setiv(pTHX_ SV *const sv, const IV i)
/* diag_listed_as: Can't coerce %s to %s in %s */
Perl_croak(aTHX_ "Can't coerce %s to integer in %s", sv_reftype(sv,0),
OP_DESC(PL_op));
+ NOT_REACHED; /* NOTREACHED */
break;
default: NOOP;
}
@@ -1763,6 +1764,7 @@ Perl_sv_setnv(pTHX_ SV *const sv, const NV num)
/* diag_listed_as: Can't coerce %s to %s in %s */
Perl_croak(aTHX_ "Can't coerce %s to number in %s", sv_reftype(sv,0),
OP_DESC(PL_op));
+ NOT_REACHED; /* NOTREACHED */
break;
default: NOOP;
}
@@ -13876,6 +13878,7 @@ S_sv_dup_common(pTHX_ const SV *const sstr, CLONE_PARAMS *const param)
switch (sv_type) {
default:
Perl_croak(aTHX_ "Bizarre SvTYPE [%" IVdf "]", (IV)SvTYPE(sstr));
+ NOT_REACHED; /* NOTREACHED */
break;
case SVt_PVGV:
--
1.8.3.1
|
From @jkeenanOn Mon, 27 Feb 2017 03:26:23 GMT, petdance wrote:
Due to code freeze, consideration of this patch will have to await perl-5.27.1. Linking to the relevant META ticket. Thank you very much. -- |
From [Unknown Contact. See original ticket]On Mon, 27 Feb 2017 03:26:23 GMT, petdance wrote:
Due to code freeze, consideration of this patch will have to await perl-5.27.1. Linking to the relevant META ticket. Thank you very much. -- |
From @petdance
No biggie. It's just maintenance. -- |
From @jkeenanOn Mon, 27 Feb 2017 03:40:12 GMT, petdance wrote:
Pushed to blead in commit c9a0dcd. Will monitor for <= 7 days, then close. Thank you very much. |
The RT System itself - Status changed from 'new' to 'open' |
From @jkeenanOn Thu, 01 Jun 2017 15:05:16 GMT, jkeenan wrote:
No adverse reactions observed. The patient is discharged. Thank you very much. -- |
@jkeenan - Status changed from 'open' to 'resolved' |
Migrated from rt.perl.org#130872 (status was 'resolved')
Searchable as RT130872$
The text was updated successfully, but these errors were encountered: