develooper Front page | perl.perl5.porters | Postings from September 2016

Re: [perl #129196] Segmentation fault: "evalbytes S"

Thread Previous | Thread Next
From:
ilmari
Date:
September 5, 2016 13:49
Subject:
Re: [perl #129196] Segmentation fault: "evalbytes S"
Message ID:
d8j60qa1mpz.fsf@dalvik.ping.uio.no
Dave Mitchell <davem@iabyn.com> writes:

> On Sun, Sep 04, 2016 at 09:30:44PM -0700, Father Chrysostomos via RT wrote:
> Around the time this commit was pushed, win32 smokers and Jenkins have
> been failing to compile, with
>
> ..\toke.c(7586) : error C2105: '--' needs l-value
>
> However, your commit doesn't touch the affected area of code, which hasn't
> changed since 2011:
>
> 7584: 	case KEY_evalbytes:
> 7585: 	    PL_expect = XTERM;
> 7586: 	    UNIBRACK(-OP_ENTEREVAL);
>
> The error would seem to imply that OP_ENTEREVAL has been defined to a
> negative value, but it's been 345 in opnames.h for a month now.
>
> So I can't see what the problem is.

UNIBRACK(f) is defined as UNIUNI3(f,0,0), which as of 9bde5622 does 

   PL_last_lop_op = f < 0 ? -f : f;

So this expands to '-345 < 0 ? --345 : -345'.  Changing it to '-(f)'
(and '(f)', for consistency) shold fix it.

-- 
"The surreality of the universe tends towards a maximum" -- Skud's Law
"Never formulate a law or axiom that you're not prepared to live with
 the consequences of."                              -- Skud's Meta-Law


Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About