Brian Fraser wrote:
On Sat, Nov 5, 2011 at 7:25 PM, John W. Krahn<jwkr...@shaw.ca>  wrote:

Brian Fraser wrote:

On Sat, Nov 5, 2011 at 3:54 PM, Shawn H Corey<shawnhco...@gmail.com>
  wrote:

  On 11-11-05 02:40 PM, Brian Fraser wrote:

     See `perldoc readline`. $! will be undefined if no error occurs.

No.


$! will be undefined, not `undef`

  That's silly. Perl has no spec -- You can't have undefined behavior. You
can tell exactly what's going to happen if you look at the source.


perldoc perlsyn
[snip]

    NOTE: The behaviour of a "my" statement modified with a statement
          ^^^^^^^^^^^^^^^^
    modifier conditional or loop construct (e.g. "my $x if ...") is
                                                                 ^^
    undefined.  The value of the "my" variable may be "undef", any
    ^^^^^^^^^
    previously assigned value, or possibly anything else.  Don't rely
    on it.  Future versions of perl might do something different from
    the version of perl you try it out on.  Here be dragons.




Not anymore it's not : )

$ perldoc perlsyn | grep NOTE

Well of course that won't find it because it is spelled "Note" now.

Try it like this:

$ perldoc -T perlsyn | grep -Ei '^ +note'



John
--
Any intelligent fool can make things bigger and
more complex... It takes a touch of genius -
and a lot of courage to move in the opposite
direction.                   -- Albert Einstein

--
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to