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

Re: [MacPerl] sysopen





Chris Nandor wrote:
> 
> At 15.01 -0400 1999.07.12, Geoffrey C Kinnel wrote:
> >Chris Nandor wrote:
> >>
> >> What am I missing (if anything)?
> >>
> >>   #!perl -wl
> >>   use Fcntl;
> >>   sysopen FILE, "foo", O_RDWR|O_TRUNC|O_CREAT or die $!;
> >>   print FILE "ha!";
> >>   close FILE;
>
> >I think you might be missing a newer version of perlfunc.pod. The
> >one I got with v5.005.03 of 19-Apr-1999 says that the 0,1 and 2
> >MODE params don't work on the Mac (or OS/390 or VM/ESA Unix).
> >Maybe that's the problem.
> 
> That was in reference to the idea that you need to use constants, not
> numerals.  The constants should work on any platform.  Paul is right on, I
> think.
> 

Woah. It appears that Paul has the answer, and that I was hasty
in my reading of perlfunc, but isn't it a little weird that
0_RDRW would work and 2 wouldn't? 

When is a constant not a constant? (Perl koan)

My apologies for leaping before looking.

Geoff (who is running the src installer RIGHT NOW! :)

===== Want to unsubscribe from this list?
===== Send mail with body "unsubscribe" to macperl-request@macperl.org