diff options
author | Vincent Pit <perl@profvince.com> | 2010-06-03 11:55:20 +0200 |
---|---|---|
committer | Vincent Pit <perl@profvince.com> | 2010-06-03 14:00:49 +0200 |
commit | 483ce06a4f6c720f66285117b98747911f62226a (patch) | |
tree | 54d8d4366c900b8f77ccf74f85d153d7ec1363f0 | |
parent | 789bd863840ef4ff6c46f7c2ee0f3f64e0b5daa6 (diff) | |
download | perl-483ce06a4f6c720f66285117b98747911f62226a.tar.gz |
The UNDERBAR macro should use find_rundefsv() as well
-rw-r--r-- | XSUB.h | 11 | ||||
-rw-r--r-- | pod/perl5132delta.pod | 5 |
2 files changed, 10 insertions, 6 deletions
@@ -72,8 +72,9 @@ Sets up the C<ix> variable for an XSUB which has aliases. This is usually handled automatically by C<xsubpp>. =for apidoc Ams||dUNDERBAR -Sets up the C<padoff_du> variable for an XSUB that wishes to use -C<UNDERBAR>. +Sets up any variable needed by the C<UNDERBAR> macro. It used to define +C<padoff_du>, but it is currently a noop. However, it is strongly adviced +to still use it for ensuring past and future compatibility. =for apidoc AmU||UNDERBAR The SV* corresponding to the $_ variable. Works even if there @@ -166,10 +167,8 @@ is a lexical $_ in scope. #define XSINTERFACE_FUNC_SET(cv,f) \ CvXSUBANY(cv).any_dxptr = (void (*) (pTHX_ void*))(f) -#define dUNDERBAR PADOFFSET padoff_du = find_rundefsvoffset() -#define UNDERBAR ((padoff_du == NOT_IN_PAD \ - || PAD_COMPNAME_FLAGS_isOUR(padoff_du)) \ - ? DEFSV : PAD_SVl(padoff_du)) +#define dUNDERBAR dNOOP +#define UNDERBAR find_rundefsv() /* Simple macros to put new mortal values onto the stack. */ /* Typically used to return values from XS functions. */ diff --git a/pod/perl5132delta.pod b/pod/perl5132delta.pod index 613f8144c6..92d3b0d4cd 100644 --- a/pod/perl5132delta.pod +++ b/pod/perl5132delta.pod @@ -184,6 +184,11 @@ XXX Changes which affect the interface available to C<XS> code go here. The following new functions or macros have been added to the public API: C<SvNV_nomg>, C<sv_2nv_flags>, C<find_rundefsv>. +=item * + +The C<UNDERBAR> macro now calls C<find_rundefsv>. C<dUNDERBAR> is now a +noop but should still be used to ensure past and future compatibility. + =back =head1 New Tests |