From: Florian Ragwitz Date: Mon, 2 May 2011 09:23:31 +0000 (+0200) Subject: Bail out earlier when not lexing X-Git-Tag: 0.006004~2 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=499109e04253181d44f945b645a1111fc6195c39;p=p5sagit%2FDevel-Declare.git Bail out earlier when not lexing --- diff --git a/Declare.xs b/Declare.xs index e5d0e50..2c715e2 100644 --- a/Declare.xs +++ b/Declare.xs @@ -274,6 +274,9 @@ STATIC OP *dd_ck_rv2cv(pTHX_ OP *o, void *user_data) { PERL_UNUSED_VAR(user_data); + if (!DD_AM_LEXING) + return o; /* not lexing? */ + if (in_declare) { call_done_declare(aTHX); return o; @@ -284,9 +287,6 @@ STATIC OP *dd_ck_rv2cv(pTHX_ OP *o, void *user_data) { if (kid->op_type != OP_GV) /* not a GV so ignore */ return o; - if (!DD_AM_LEXING) - return o; /* not lexing? */ - if (DD_DEBUG_TRACE) { printf("Checking GV %s -> %s\n", HvNAME(GvSTASH(kGVOP_gv)), GvNAME(kGVOP_gv)); }