float_sum
Concepts
Section titled “Concepts”Behaviour
Section titled “Behaviour”- Compute the addition of two XFL (xls17) floating point numbers
- Return a new XFL as an int64_t
- Sums two float representations.
- Returns an error code or the sum as a bigint.
Definition
Section titled “Definition”int64_t float_sum ( int64_t float1, int64_t float2);
function float_sum(f1: bigint, f2: bigint): ErrorCode | bigint
Example
Section titled “Example”int64_t two = float_sum(float_one(), float_one());
const two = float_sum(float_one(), float_one());
Parameters
Section titled “Parameters”Name | Type | Description |
---|---|---|
float1 | int64_t | An XFL floating point enclosing number representing the first operand to the addition |
float2 | int64_t | An XFL floating point enclosing number representing the second operand to the addition |
Name | Type | Description |
---|---|---|
f1 | bigint | The first float to sum. |
f2 | bigint | The second float to sum. |
Return Code
Section titled “Return Code”Type | Description |
---|---|
int64_t | The XFL (xls17) enclosing number |
Type | Description |
---|---|
ErrorCode or bigint | An error code or the sum as a bigint. |