This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
pad.h: Don’t use pad_compname_type
authorFather Chrysostomos <sprout@cpan.org>
Fri, 21 Nov 2014 08:19:27 +0000 (00:19 -0800)
committerFather Chrysostomos <sprout@cpan.org>
Sun, 30 Nov 2014 19:48:36 +0000 (11:48 -0800)
We only use PAD_COMPNAME_TYPE in one place, so wrapping it in a func-
tion doesn’t save us anything, and probably slows things down if
anything.  Furthermore, PadnameTYPE will soon become even simpler
than before.

pad.h

diff --git a/pad.h b/pad.h
index 049b1c4..7624b21 100644 (file)
--- a/pad.h
+++ b/pad.h
@@ -409,7 +409,7 @@ ling pad (lvalue) to C<gen>.  Note that C<SvUV_set> is hijacked for this purpose
 #define PAD_COMPNAME_FLAGS_isOUR(po) SvPAD_OUR(PAD_COMPNAME_SV(po))
 #define PAD_COMPNAME_PV(po)    PadnamePV(PAD_COMPNAME(po))
 
-#define PAD_COMPNAME_TYPE(po) pad_compname_type(po)
+#define PAD_COMPNAME_TYPE(po)  PadnameTYPE(PAD_COMPNAME(po))
 
 #define PAD_COMPNAME_OURSTASH(po) \
     (SvOURSTASH(PAD_COMPNAME_SV(po)))