I've seen some weird syntax error-ish bugs around subs that are prototyped to take a sub-ref as an argument

Yes, that seems to be the trouble here.

The problem is with the run_main prototype of (;&)
If I change that to simply (&) all seems well on 5.8, except that run_main then needs to be called with at least one argument.
That is, with a prototype specification of (;&) we can simply do run_main; on perl-5.10 and 5.12, but with a prototype specification of (&) on my perl-5.8.0, we're not allowed to do simply run_main. Instead we have to do run_main sub {} which looks very much like what you were suggesting. But that only works on my perl-5.8.0 if I also change the prototype from (;&) to (&)
That's the best I've yet been able to come up with.

This may well have been fixed in later versions of perl-5.8. I haven't checked.

Sorry it took so long to reply - I was unable to access perlmonks last night (though access to every other site was fine).

Cheers,
Rob

In reply to Re^2: syntax error - perl-5.8 only by syphilis
in thread syntax error - perl-5.8 only by syphilis

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.