blob: c741bdbe6034af4f25af33234c80d32ff9e9b77d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
// Copyright 2009 the Sputnik authors. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
description: If abs(base) is 1 and exponent is +∞, the result is NaN.
esid: sec-applying-the-exp-operator
---*/
var exponent = +Infinity;
var base = new Array();
base[0] = -1;
base[1] = 1
var basenum = 2;
for (var i = 0; i < basenum; i++) {
assert.sameValue(
Math.pow(base[i], exponent),
NaN,
"(" + base[i] + ", " + exponent + ")"
);
}
reportCompare(0, 0);
|