in reply to Won't print unless newline is included?
But stop and consider for a moment that buffering is on by default for a reason. Turning it off will affect file IO speeds, which generally improve with buffering.
One thing you can do is to localize the damage done by turning on autoflush. That can be done lexically as follows:
print "Beginning test.\n"; print "This is not autoflushed..."; sleep 3; { local $| = 1; print "This is autoflushed..."; sleep 3; } print "This is not autoflushed..."; sleep 3;
Dave
|
|---|