print 3 . 5; # 35 print 3.5; # 3.5

Warnings will catch that for you.

%foo = (bar => "xyzzy") print "-$foo{bar}-"; # -xyzzy- print "-$foo {bar}-"; # - {bar}-

Putting a space in the middle of a variable is just a wee bit different from indenting lines within a function.

$a = 1; print $a - -5; # 6 print $a -- 5; # error print q qhelloq; # hello print qqhelloq; # qqhelloq

All of these examples are highly contrived, and not at all the same as wanting to indent lines to properly reflect a nested structure and being told that no, those lines should not be indented, because the leading whitespace is significant. And as for having blank lines be significant... the English language lacks the words to describe my view of that. At this point I'm thinking I'll probably continue to use comments as I have been doing, after all. The prospect of being able to automatically generate documentation from the POD comments embedded in the code was attractive to me in principle, but apparently it's not flexible enough to be used at all the way I want.


$;=sub{$/};@;=map{my($a,$b)=($_,$;);$;=sub{$a.$b->()}} split//,".rekcah lreP rehtona tsuJ";$\=$ ;->();print$/

In reply to Re: Re: Re: Worst thing you ever made with Perl by jonadab
in thread Worst thing you ever made with Perl by Juerd

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.