| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
tryAMAGICunDEREF() isn't used anywhere in the core. Add tests for it.
|
|
|
|
| |
Nothing outside the core was using this macro.
|
|
|
|
|
|
|
|
|
| |
This removes around 300 bytes of object code from each place it was previously
inlined. It also provides a better interface - quite a lot of the core
currently bodges things by creating a local variable C<SV **sp = &sv> to use
the macro.
Change the XS::APItest wrapper to amagic_deref_call().
|
|
|
|
|
|
|
| |
Only Perl_amagic_call() was using RvDEEPCP() when it was added in 5.000, and I
believe that it's never had any other users (in the core, on CPAN, or anywhere
else visible to Google codesearch). Hence it seems an ideal candidates to be
inlined and eliminated.
|
|
|
|
|
|
|
|
| |
Yes, it was a while loop implemented using goto, although this only became
clear by untangling the macros. I believe it need never have been implemented
as goto, given that the other user of tryAMAGICunW_var "broke" out of the
"if"'s block using a return, hence that "if" could have been a "while" all
along.
|
|
|
|
|
| |
Aside from the 2 callers where it can be replaced with AMG_CALLun().
AMG_CALLun_var was only used in core.
|
|
|
|
|
|
|
| |
This also inlines and eliminates FORCE_SETs and setAGAIN.
The three eliminated macros were not referenced from anywhere else. (The core,
CPAN, code visible to Google codesearch.)
|
|
|
|
|
| |
tryAMAGICunW was only used within pp.h itself, and not referenced from anywhere
else. (The core, CPAN, code visible to Google codesearch.)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since commit 6f1401dc2acd2a2b, many AMAGIC macros in pp.h are no longer used
in core, nor in modules or CPAN, nor in code visible to Google codesearch.
Specifically:
tryAMAGICbinW_var
tryAMAGICbinW
tryAMAGICbin_var
tryAMAGICbin
tryAMAGICbinSET
tryAMAGICbinSET_var
tryAMAGICbinW_var
AMG_CALLbinL
tryAMAGICun_var
tryAMAGICun
tryAMAGICunSET_var
tryAMAGICunSET
tryAMAGICftest
|
|
|
|
|
|
|
|
|
| |
Much simplification ensues - witness the diffstat.
Changes Perl_die_unwind() to use Perl_croak() rather than DIE().
Reverses an unwise part of bb4c52e023e0fcad.
Reverts 9e95c6350a60744d and 805bf316c58ab2d7.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In most places, ops checked their args for overload *before* doing
mg_get(). This meant that, among other issues, tied vars that
returned overloaded objects wouldn't trigger calling the
overloaded method. (Actually, for tied and arrays and hashes, it
still often would since mg_get gets called beforehand in rvalue
context).
This patch does the following:
Makes sure get magic is called first.
Moves most of the overload code formerly included by macros at the
start of each pp function into the separate helper functions
Perl_try_amagic_bin, Perl_try_amagic_un, S_try_amagic_ftest,
with 3 new wrapper macros:
tryAMAGICbin_MG, tryAMAGICun_MG, tryAMAGICftest_MG.
This made the code 3800 bytes smaller.
Makes sure that FETCH is not called multiple times. Much of this
bit was helped by some earlier work from Father Chrysostomos.
Added new functions and macros sv_inc_nomg(), sv_dec_nomg(),
dPOPnv_nomg, dPOPXiirl_ul_nomg, dPOPTOPnnrl_nomg, dPOPTOPiirl_ul_nomg
dPOPTOPiirl_nomg, SvIV_please_nomg, SvNV_nomg (again, some of
these were based on Father Chrysostomos's work).
Fixed the list version of the repeat operator (x): it now only
calls overloaded methods for the scalar version:
(1,2,$overloaded) x 10
no longer erroneously calls
x_method($overloaded,10))
The only thing I haven't checked/fixed yet is overloading the
iterator operator, <>.
|
| |
|
|
|
|
|
|
| |
Filetest ops don't always expect an op on the stack, so we should use
TOPs only if we're sure that we're not stat'ing the _ filehandle.
This is indicated by OPf_KIDS (as checked in ck_ftst).
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
pp_hslice
|
|
|
| |
p4raw-id: //depot/perl@34585
|
|
|
|
|
|
| |
From: Rick Delaney (via RT) <perlbug-followup@perl.org>
Message-ID: <rt-3.6.HEAD-22068-1213469460-652.55786-75-0@perl.org>
p4raw-id: //depot/perl@34055
|
|
|
|
|
| |
results in slightly smaller object code. (No extra work is done.)
p4raw-id: //depot/perl@32834
|
|
|
|
|
|
|
|
|
| |
The macros all create new mortals using sv_newmortal(), and those
cannot be magical. This is in contrary to the X?PUSH macros, which
operate on TARG, which can be magical.
With that in mind, mentioning whether or not mX?PUSH can handle
'set' magic doesn't make sense any longer.
p4raw-id: //depot/perl@32824
|
|
|
|
|
|
| |
and mortalizing them. Use these macros where possible. And also
mX?PUSH[inpu] where possible.
p4raw-id: //depot/perl@32821
|
|
|
| |
p4raw-id: //depot/perl@32237
|
|
|
|
|
| |
Message-ID: <prol131i8b27re246alnhmem4mj13fcl2b@4ax.com>
p4raw-id: //depot/perl@30879
|
|
|
| |
p4raw-id: //depot/perl@29907
|
|
|
|
|
| |
space saving to merge them. Hopefully this will reduce L2 cache misses.
p4raw-id: //depot/perl@29836
|
|
|
|
|
|
| |
files that generate .h files, so they'll be ready
next time.
p4raw-id: //depot/perl@29695
|
|
|
|
|
| |
The overloading tests are not free.
p4raw-id: //depot/perl@27126
|
|
|
|
|
| |
which don't do the pre-processor string manipulation internally.
p4raw-id: //depot/perl@27122
|
|
|
|
|
| |
(Since change 17990 added version object overloading)
p4raw-id: //depot/perl@26516
|
|
|
|
|
|
|
| |
Message-ID: <20051227203939.GC1781@petdance.com>
Includes a small fix to the changes in tryAMAGICbinW_var() in pp.h.
p4raw-id: //depot/perl@26505
|
|
|
|
|
|
| |
macros, to avoid needing C pre-processor string concatenation within
the lowest level expansion.
p4raw-id: //depot/perl@26015
|
|
|
|
|
| |
Message-ID: <533D273D4014D411AB1D00062938C4D90849C75C@hotel.npl.co.uk>
p4raw-id: //depot/perl@25237
|
|
|
|
|
| |
Message-ID: <20050622144059.GA19598@petdance.com>
p4raw-id: //depot/perl@24945
|
|
|
| |
p4raw-id: //depot/perl@24757
|
|
|
|
|
| |
Elminate a lot of C<n_a>s
p4raw-id: //depot/perl@24748
|
|
|
| |
p4raw-id: //depot/perl@24723
|
|
|
|
|
| |
Message-ID: <20050516151353.GA25387@petdance.com>
p4raw-id: //depot/perl@24489
|
|
|
|
|
|
| |
Message-ID: <20050419000925.GA21640@mccoy.peters.homeunix.org>
Date: Mon, 18 Apr 2005 19:09:25 -0500
p4raw-id: //depot/perl@24248
|
|
|
| |
p4raw-id: //depot/perl@24106
|
|
|
|
|
| |
Message-ID: <533D273D4014D411AB1D00062938C4D90849C55A@hotel.npl.co.uk>
p4raw-id: //depot/perl@23767
|
|
|
|
|
| |
Message-Id: <cqf0q1$9cc$1@post.home.lunix>
p4raw-id: //depot/perl@23680
|
|
|
| |
p4raw-id: //depot/perl@22895
|
|
|
|
|
|
| |
Subject: Re: [PATCH] Document limitations in PUSHi et al macros and add new mPUSHi et al macros
Message-Id: <20040503200328.24efcda5@r2d2>
p4raw-id: //depot/perl@22779
|
|
|
|
|
|
| |
should handle 'set' magic, just like the X?PUSH[inup]
counterparts.
p4raw-id: //depot/perl@22757
|
|
|
|
|
| |
Message-ID: <40921749.3050600@uk.radan.com>
p4raw-id: //depot/perl@22756
|
|
|
|
|
|
|
|
|
| |
Message-ID: <20030101225459.A2320@cs839290-a.mtth.phub.net.cable.rogers.com>
(Pity the first patch fell through the cracks back then.
Not that forbidding non-object copy constructors is the right
thing to do but the bug could use fixing.)
p4raw-id: //depot/perl@21276
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
[ 19738]
Subject: Re: [PATCH: maint @ 19733] CL compiler warnings on MSWin32
From: "Marcus Holland-Moritz" <mhx-perl@gmx.net>
Message-ID: <011701c32f8c$62d85ee0$0c2f1fac@R2D2>
p4raw-link: @19738 on //depot/perl: 5a1dd2ab5c9ca51eda95e7e0025702bdfcd91d9fon //depot/maint-5.8/perl: c43a4d73e4c3d92928dd743544b60e43ce02ee9c
p4raw-id: //depot/perl@19739
p4raw-integrated: from //depot/maint-5.8/perl@19738 'copy in'
ext/Encode/encengine.c (@18665..) ext/List/Util/Util.xs
(@18791..) ext/Storable/Storable.xs (@19551..)
ext/POSIX/POSIX.xs (@19704..) ext/threads/threads.xs (@19722..)
'merge in' ext/Thread/Thread.xs (@18145..) pp.h (@19400..) sv.c
(@19653..) perl.c (@19704..) op.c (@19732..)
|