From 94fcd414575e04d8b809003ba7bca1216090abff Mon Sep 17 00:00:00 2001 From: Nicholas Clark Date: Thu, 4 Oct 2007 10:39:05 +0000 Subject: [PATCH] S_dopoptosub() is just a wrapper for S_dopoptosub_at(), so make it a macro. (Also slightly shrinks the object code for x86 with -Os) p4raw-id: //depot/perl@32024 --- embed.fnc | 1 - embed.h | 2 -- pp_ctl.c | 9 ++------- proto.h | 3 --- 4 files changed, 2 insertions(+), 13 deletions(-) diff --git a/embed.fnc b/embed.fnc index 03fffa4..02dc1ab 100644 --- a/embed.fnc +++ b/embed.fnc @@ -1319,7 +1319,6 @@ sR |I32 |dopoptoeval |I32 startingblock sR |I32 |dopoptogiven |I32 startingblock sR |I32 |dopoptolabel |NN const char *label sR |I32 |dopoptoloop |I32 startingblock -sR |I32 |dopoptosub |I32 startingblock sR |I32 |dopoptosub_at |NN const PERL_CONTEXT* cxstk|I32 startingblock sR |I32 |dopoptowhen |I32 startingblock s |void |save_lines |NULLOK AV *array|NN SV *sv diff --git a/embed.h b/embed.h index e97d5db..bdcc615 100644 --- a/embed.h +++ b/embed.h @@ -1300,7 +1300,6 @@ #define dopoptogiven S_dopoptogiven #define dopoptolabel S_dopoptolabel #define dopoptoloop S_dopoptoloop -#define dopoptosub S_dopoptosub #define dopoptosub_at S_dopoptosub_at #define dopoptowhen S_dopoptowhen #define save_lines S_save_lines @@ -3581,7 +3580,6 @@ #define dopoptogiven(a) S_dopoptogiven(aTHX_ a) #define dopoptolabel(a) S_dopoptolabel(aTHX_ a) #define dopoptoloop(a) S_dopoptoloop(aTHX_ a) -#define dopoptosub(a) S_dopoptosub(aTHX_ a) #define dopoptosub_at(a,b) S_dopoptosub_at(aTHX_ a,b) #define dopoptowhen(a) S_dopoptowhen(aTHX_ a) #define save_lines(a,b) S_save_lines(aTHX_ a,b) diff --git a/pp_ctl.c b/pp_ctl.c index a822614..b512686 100644 --- a/pp_ctl.c +++ b/pp_ctl.c @@ -38,6 +38,8 @@ #define DOCATCH(o) ((CATCH_GET == TRUE) ? docatch(o) : (o)) +#define dopoptosub(plop) dopoptosub_at(cxstack, (plop)) + PP(pp_wantarray) { dVAR; @@ -1300,13 +1302,6 @@ Perl_is_lvalue_sub(pTHX) } STATIC I32 -S_dopoptosub(pTHX_ I32 startingblock) -{ - dVAR; - return dopoptosub_at(cxstack, startingblock); -} - -STATIC I32 S_dopoptosub_at(pTHX_ const PERL_CONTEXT *cxstk, I32 startingblock) { dVAR; diff --git a/proto.h b/proto.h index 28cfdef..69bf681 100644 --- a/proto.h +++ b/proto.h @@ -3525,9 +3525,6 @@ STATIC I32 S_dopoptolabel(pTHX_ const char *label) STATIC I32 S_dopoptoloop(pTHX_ I32 startingblock) __attribute__warn_unused_result__; -STATIC I32 S_dopoptosub(pTHX_ I32 startingblock) - __attribute__warn_unused_result__; - STATIC I32 S_dopoptosub_at(pTHX_ const PERL_CONTEXT* cxstk, I32 startingblock) __attribute__warn_unused_result__ __attribute__nonnull__(pTHX_1); -- 2.7.4