[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: fortran question...
- Subject: Re: fortran question...
- Date: Thu, 21 Sep 2006 08:19:50 -0600
Ed,
> In fortran, how do you OR together constants?
>
> For example, in C I would say NC_CLOBBER|NC_FORMAT_64BIT.
>
> But how do you do that in fortran?
In Fortran-77, use IOR, as in:
iret = nf_create('foo.nc',
IOR(NF_NOCLOBBER,NF_64BIT_OFFSET),
ncid)
In Fortran-90, use "or", as in:
iret = nf90_create(path="foo.nc",
cmode=or(nf90_clobber,nf90_64bit_offset),
ncid=ncFileID)
--Russ