But what's with the "panic: top_env" message? And why doesn't it print out a diagnostic too?
This panic: message doesn't actually seem to be implemented as a warn or die; it just does the equivalent of print STDERR "panic: top_env\n"; and then bails out of the parser with an error. Perhaps this is also a bug :)

You can still get the diagnostics by piping STDERR to the splain utility:

$ perl -e'qr/(?{rand < 5})/' 2>&1 |splain Warning: Use of "rand" without parentheses is ambiguous at (re_eval 1) + line 1 (# 1) (S ambiguous) You wrote a unary operator followed by something tha +t looks like a binary operator that could also have been interpreted + as a term or unary operator. For instance, if you know that the rand function has a default argument of 1.0, and you write rand + 5; you may THINK you wrote the same thing as rand() + 5; but in actual fact, you got rand(+5); So put in parentheses to say what you really mean. panic: top_env (#2) (P) The compiler attempted to do a goto, or something weird like t +hat.

In reply to Re: "panic: top_env": Is this error resulting from a Perl bug? by ysth
in thread "panic: top_env": Is this error resulting from a Perl bug? by davido

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.