[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

Re: [MacPerl] Stepping through large text files



At 12:55 -0500 18.2.98, Kevin Lindsey wrote:

> Apparently, MacPerl needs as much free memory (plus a little more)
> as the size of the file that it is reading in.

The only time I've run out of memory while processing large files was
when I hadn't set $/ to reflect the line breaks in the file being
processed, causing MacPerl to keep reading until it found an EOL that
wasn't there.

Eg, if it's a unix file, you need to

	$/ = "\x0a";

before you try reading line-by-line.

Stephan

***** Want to unsubscribe from this list?
***** Send mail with body "unsubscribe" to mac-perl-request@iis.ee.ethz.ch