This article covers features introduced in SpiderMonkey 24
Convert a C integer or floating-point value to a JS::Value
.
Syntax
JS::Value JS::NumberValue(float f) JS::Value JS::NumberValue(double dbl) JS::Value JS::NumberValue(int8_t i) JS::Value JS::NumberValue(uint8_t i) JS::Value JS::NumberValue(int16_t i) JS::Value JS::NumberValue(uint16_t i) JS::Value JS::NumberValue(int32_t i) JS::Value JS::NumberValue(uint32_t i)
Name | Type | Description |
---|---|---|
f or dbl or i |
any | C integer or floating-point value to convert. |
Description
JS::NumberValue
converts a C integer or floating-point value to JS::Value
, the type of JavaScript values.