develooper Front page | perl.perl5.porters | Postings from September 2006

seek beyond length

Thread Next
September 28, 2006 05:14
seek beyond length
Message ID:
Is this a bug or a feature? :)

    perl -e'open my $fh, ">", \my $foo; print {$fh} 42; seek $fh, 5000, 0;
    print {$fh} 42; print $foo;'

Also, Perl should probably check the readonly flag here, and scream a

    perl -le'open my $fh, ">", \undef; print {$fh} 42; print undef;
    print defined undef'

Why are large parts of source code in memory, by the way? Is this free
memory that will be overwritten, or wasted? Would it be useful to skip
\N+ in POD and comments, to save some memory?
korajn salutojn,

  juerd waalboer:  perl hacker  <>  <>
  convolution:     ict solutions and consultancy <>

Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About