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

[netCDF #EAM-622298]: Missing: "unsigned long"



Ed,

> In fact, support for NC_LONG, required from netCDF-4 for backward
> compatibility, cost me considerable trouble. The problem is that the
> long type may be the same as an int (and this is the usual case), or
> it may be the same as a "long long." ...

Also, just to be clear, there is no portability issue here.  The
function nc_get_vara_ulong() would convert the netCDF data of whatever
numeric type to the unsigned long type on the platform on which it is
built.  This is just a matter of copying the numeric type into a variable
declared to be of type "unsigned long".  It doesn't matter whether it is
the same as int or long long, it just needs to be whatever the type
"unsigned long" is on the platform on which the library is built.  

I think if you look at how you already implementted his for long, you'll
see the issue of the size of longs does not come up, and that code is
unrelated to NC_INT, NC_INT64, or NC_LONG.

--Russ



Ticket Details
===================
Ticket ID: EAM-622298
Department: Support netCDF
Priority: Normal
Status: Open