Closed hpages closed 4 months ago
All modified and coverable lines are covered by tests :white_check_mark:
Comparison is base (
4b84fb0
) 77.51% compared to head (4a7893f
) 77.51%.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
Thanks @hpages
I probably need to make a similar change to H5Sset_extent_simple
and come up with a solution for the H5S_UNLIMITED
issue. I'll merge it once I've done that.
For the H5S_UNLIMITED
issue, you could adopt the convention that any negative dim stands for H5S_UNLIMITED
. Then replace:
if (maxdims[i] == -1)
maxdims[i] = H5S_UNLIMITED;
with:
if (REAL(_maxdims)[i] < 0)
maxdims[i] = H5S_UNLIMITED;
I don't like doing REAL(_maxdims)[i] == -1
because who knows how reliable ==
between 2 floating point representations can be. I feel that it might cause some surprises on some platforms.
Another way to go would be to use NA_real_
to mean H5S_UNLIMITED
(if it's not already used to mean something else). Then:
if (R_IsNA(REAL(_maxdims)[i]))
maxdims[i] = H5S_UNLIMITED;
Hi Mike,
When trying to create a 1D dataset with an extension >
.Machine$integer.max
, I get the following warning:The warning is coming from
H5Screate_simple()
:This PR addresses this by coercing the supplied
dims
ormaxdims
vectors to numeric instead of integer, and by turning the numeric values tohsize_t
values at the C-level.With this change:
H.