This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
perly.y: add $$ = 0 for midrule code blocks
authorDavid Mitchell <davem@iabyn.com>
Wed, 8 Mar 2017 14:57:23 +0000 (14:57 +0000)
committerDavid Mitchell <davem@iabyn.com>
Wed, 7 Jun 2017 10:28:20 +0000 (11:28 +0100)
commit5a2060e217d73fba807a79202aa876c8b6a8888a
tree218a9674adb5db810c9d37d8ec31fbe632858355
parent8c5fc2b7832433c282c07796345b54bd79e334f3
perly.y: add $$ = 0 for midrule code blocks

In places where a rule contains multiple code blocks, ensure that
$$ is assigned a valid value at the end of midrule blocks, so that

    valgrind ./perl -Dpv ...

doesn't display zillions of

    Conditional jump or move depends on uninitialised value

errors, when perl tries to display the parse stack.

I've only done the various newish top-level grammar entries - these all
seemed to have the same defect, while from a quick glance elsewhere in the
file, it seemed like older rules already do this.
perly.act
perly.h
perly.tab
perly.y