You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

30 lines
427 B

/*===
Infinity
===*/
/* Exponent overflow/underflow test; caused some valgrind issues. */
function buildNumber(exp) {
var t;
t = '1';
while (exp-- > 0) { t += '0'; }
return t;
}
function expOverflowUnderflowTest() {
var str, radix, val;
radix = 2;
str = buildNumber(1024);
val = parseInt(str, radix);
print(val);
}
try {
expOverflowUnderflowTest();
} catch (e) {
print(e);
}