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

[netCDF #CQM-787807]: netCDF4 f90 interface - problem with



> I'm using netcdf-4.0-snapshot2008042720.
>
> I've been trying to convert the ftst_vars.F program to use the F90
> interface and struck a problem with nf90_inq_var_chunking. In the
> example nf_inq_var_chunking returns an array
>
> The f77 documentation says
>
> NF_INQ_VAR_CHUNKING(INTEGER NCID, INTEGER VARID, INTEGER CONTIGUOUS, INTEGER
CHUNKSIZES);
>
> ...
> ||
> |CHUNKSIZES|
> An array of chunk sizes. The array must have the one chunksize for
> each dimension in the variable.
>
> I think the last sentence is trying to say that the chunksizes array
> must have length equal to the number of dimensions of the variable.
>
> However in netcdf4_func.f90 the function is defined with a scalar rather
> than an array argument
>
> function nf90_inq_var_chunking(ncid, varid, contiguous, chunksizes)
> integer, intent(in) :: ncid
> integer, intent(in) :: varid
> integer, intent(out) :: contiguous
> integer, intent(out) :: chunksizes
> integer :: nf90_inq_var_chunking
>
> nf90_inq_var_chunking = nf_inq_var_chunking(ncid, varid, contiguous,
> chunksizes)
> end function nf90_inq_var_chunking
>
> If I change this to
> integer, dimension(:), intent(out) :: chunksizes
> it works as expected.
>
> Regards
>
> Martin Dix
>
>
>

Howdy Martin!

Thanks for pointing this out. I made the change you suggest and also fixed the
documentation.

Also I added a test for this one.

Thanks!

Ed

Ticket Details
===================
Ticket ID: CQM-787807
Department: Support netCDF
Priority: Normal
Status: Closed