in reply to Redirecting STDOUT, lexically scoped
- Millerprint "Hello world\n"; { local(*STDOUT); open(STDOUT, ">some_other_world.txt") or die $!; print "Hi other world\n"; close STDOUT; } print "Goodbye world\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Redirecting STDOUT, lexically scoped
by moritz (Cardinal) on Jul 31, 2007 at 10:12 UTC | |
by radiantmatrix (Parson) on Jul 31, 2007 at 14:51 UTC | |
by mfwitten (Initiate) on Apr 11, 2009 at 02:29 UTC |