Skip to content

as.hexmode(big number) fails in R-3.1.2

1 message · William Dunlap

#
There was recently a discussion here on how to tell if a number was
integral.
Did that prod someone into change as.hexmode in R-3.1.2 so that it aborts if
given a number to big to fit into a 32-bit integer?  It returned NA, with
two warnings
in R-3.1.1.

% R-3.1.2 --quiet --vanilla
Error in if (is.double(x) && all(is.na(x) | x == as.integer(x))) x <-
as.integer(x) :
  missing value where TRUE/FALSE needed
In addition: Warning message:
In as.hexmode(c(10^c(0, 9, 18))) : NAs introduced by coercion
% R-3.1.1 --quiet --vanilla
[1] "00000001" "3b9aca00" NA
Warning messages:
1: In as.hexmode(c(10^c(0, 9, 18))) : NAs introduced by coercion
2: In as.hexmode(c(10^c(0, 9, 18))) : NAs introduced by coercion

Bill Dunlap
TIBCO Software
wdunlap tibco.com