in reply to Can I include O_CREAT, O_EXCEL and O_WRONLY in my script without always requiring Fcntl?
This program compiles fine, but fails with a runtime error if you add a call to not_really_needed. Replace SomethingStupid with Fcntl and you'll have what you want.use strict; use warnings; sub not_really_needed { require SomethingStupid; import SomethingStupid qw(O_CREAT O_EXCL O_WRONLY); }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Can I include O_CREAT, O_EXCEL and O_WRONLY in my script without always requiring Fcntl?
by rzward (Monk) on Apr 13, 2006 at 18:11 UTC |