diff options
author | Lukas Mai <l.mai@web.de> | 2014-11-29 12:37:50 +0100 |
---|---|---|
committer | Father Chrysostomos <sprout@cpan.org> | 2014-11-29 06:05:16 -0800 |
commit | e59642234eb8b658c16fed728636bfbbc49c4514 (patch) | |
tree | 3387394bff0e7e2f7ac09564be7493e6a71619d2 /pad.c | |
parent | b7bea5dafa8e0cb5ca70b7525fbd6b51eb723815 (diff) | |
download | perl-e59642234eb8b658c16fed728636bfbbc49c4514.tar.gz |
make more use of NOT_REACHED
In particular, remove all instances of 'assert(0);'.
Diffstat (limited to 'pad.c')
-rw-r--r-- | pad.c | 12 |
1 files changed, 3 insertions, 9 deletions
@@ -200,19 +200,13 @@ void Perl_set_padlist(CV * cv, PADLIST *padlist){ PERL_ARGS_ASSERT_SET_PADLIST; # if PTRSIZE == 8 - if((Size_t)padlist == UINT64_C(0xEFEFEFEFEFEFEFEF)){ - assert(0); - } + assert((Size_t)padlist != UINT64_C(0xEFEFEFEFEFEFEFEF)); # elif PTRSIZE == 4 - if((Size_t)padlist == UINT64_C(0xEFEFEFEF)){ - assert(0); - } + assert((Size_t)padlist != UINT64_C(0xEFEFEFEF)); # else # error unknown pointer size # endif - if(CvISXSUB(cv)){ - assert(0); - } + assert(!CvISXSUB(cv)); ((XPVCV*)MUTABLE_PTR(SvANY(cv)))->xcv_padlist_u.xcv_padlist = padlist; } #endif |