RETURN;
}
-PP(pp_scalar)
-{
- return NORMAL;
-}
-
/* Pushy stuff. */
PP(pp_padav)
RETURN;
}
-PP(pp_padany)
-{
- DIE(aTHX_ "NOT IMPL LINE %d",__LINE__);
-}
-
/* Translations. */
PP(pp_rv2gv)
const char *pv;
SV * const sv = POPs;
- if (sv && SvGMAGICAL(sv))
- mg_get(sv);
+ if (sv)
+ SvGETMAGIC(sv);
if (!sv || !SvROK(sv))
RETPUSHNO;
RETPUSHYES;
break;
default:
- if (SvGMAGICAL(sv))
- mg_get(sv);
+ SvGETMAGIC(sv);
if (SvOK(sv))
RETPUSHYES;
}
{
register IV count;
dPOPss;
- if (SvGMAGICAL(sv))
- mg_get(sv);
+ SvGETMAGIC(sv);
if (SvIOKp(sv)) {
if (SvUOK(sv)) {
const UV uv = SvUV(sv);
dSP; dATARGET; tryAMAGICbin(band,opASSIGN);
{
dPOPTOPssrl;
- if (SvGMAGICAL(left)) mg_get(left);
- if (SvGMAGICAL(right)) mg_get(right);
+ SvGETMAGIC(left);
+ SvGETMAGIC(right);
if (SvNIOKp(left) || SvNIOKp(right)) {
if (PL_op->op_private & HINT_INTEGER) {
const IV i = SvIV_nomg(left) & SvIV_nomg(right);
dSP; dATARGET; tryAMAGICbin(bxor,opASSIGN);
{
dPOPTOPssrl;
- if (SvGMAGICAL(left)) mg_get(left);
- if (SvGMAGICAL(right)) mg_get(right);
+ SvGETMAGIC(left);
+ SvGETMAGIC(right);
if (SvNIOKp(left) || SvNIOKp(right)) {
if (PL_op->op_private & HINT_INTEGER) {
const IV i = (USE_LEFT(left) ? SvIV_nomg(left) : 0) ^ SvIV_nomg(right);
dSP; dATARGET; tryAMAGICbin(bor,opASSIGN);
{
dPOPTOPssrl;
- if (SvGMAGICAL(left)) mg_get(left);
- if (SvGMAGICAL(right)) mg_get(right);
+ SvGETMAGIC(left);
+ SvGETMAGIC(right);
if (SvNIOKp(left) || SvNIOKp(right)) {
if (PL_op->op_private & HINT_INTEGER) {
const IV i = (USE_LEFT(left) ? SvIV_nomg(left) : 0) | SvIV_nomg(right);
{
dTOPss;
const int flags = SvFLAGS(sv);
- if (SvGMAGICAL(sv))
- mg_get(sv);
+ SvGETMAGIC(sv);
if ((flags & SVf_IOK) || ((flags & (SVp_IOK | SVp_NOK)) == SVp_IOK)) {
/* It's publicly an integer, or privately an integer-not-float */
oops_its_an_int:
dSP; dTARGET; tryAMAGICun(compl);
{
dTOPss;
- if (SvGMAGICAL(sv))
- mg_get(sv);
+ SvGETMAGIC(sv);
if (SvNIOKp(sv)) {
if (PL_op->op_private & HINT_INTEGER) {
const IV i = ~SvIV_nomg(sv);
}
s = (U8*)SvPV_force_nomg(sv, len);
if (len) {
- const register U8 *send = s + len;
+ register const U8 *send = s + len;
if (IN_LOCALE_RUNTIME) {
TAINT;
dSP; dTARGET;
SV * const sv = TOPs;
STRLEN len;
- const register char *s = SvPV_const(sv,len);
+ register const char *s = SvPV_const(sv,len);
SvUTF8_off(TARG); /* decontaminate */
if (len) {
RETURN;
}
-PP(pp_values)
-{
- return do_kv();
-}
-
-PP(pp_keys)
-{
- return do_kv();
-}
-
PP(pp_delete)
{
dSP;
call_method("PUSH",G_SCALAR|G_DISCARD);
LEAVE;
SPAGAIN;
+ SP = ORIGMARK;
+ PUSHi( AvFILL(ary) + 1 );
}
else {
- /* Why no pre-extend of ary here ? */
for (++MARK; MARK <= SP; MARK++) {
SV * const sv = NEWSV(51, 0);
if (*MARK)
sv_setsv(sv, *MARK);
- av_push(ary, sv);
+ av_store(ary, AvFILLp(ary)+1, sv);
}
+ SP = ORIGMARK;
+ PUSHi( AvFILLp(ary) + 1 );
}
- SP = ORIGMARK;
- PUSHi( AvFILL(ary) + 1 );
RETURN;
}
RETURN;
}
-PP(pp_threadsv)
+
+PP(unimplemented_op)
{
- DIE(aTHX_ "tried to access per-thread data in non-threaded perl");
+ DIE(aTHX_ "panic: unimplemented op %s (#%d) called", OP_NAME(PL_op),
+ PL_op->op_type);
}
/*