![]() | Fun 0.41.5 The programming language that makes You have fun |
Implements the OP_GCD opcode for greatest common divisor. More...
Go to the source code of this file.
Functions | |
| if (!((va.type==VAL_INT)||(va.type==VAL_FLOAT))||!((vb.type==VAL_INT)||(vb.type==VAL_FLOAT))) | |
| if (a==INT64_MIN) | |
| free_value (va) | |
| free_value (vb) | |
| push_value (vm, res) | |
Variables | |
| case | OP_GCD |
| Value | va = pop_value(vm) |
| int64_t | a = (va.type == VAL_INT) ? va.i : (int64_t)va.d |
| int64_t | b = (vb.type == VAL_INT) ? vb.i : (int64_t)vb.d |
| Value | res = make_int(a) |
| break | |
Implements the OP_GCD opcode for greatest common divisor.
Behavior:
Stack effect:
Types:
Definition in file gcd.c.
| free_value | ( | va | ) |
| free_value | ( | vb | ) |
| if | ( | ! | (va.type==VAL_INT)||(va.type==VAL_FLOAT))||!((vb.type==VAL_INT)||(vb.type==VAL_FLOAT) | ) |
| push_value | ( | vm | , |
| res | ) |