![]() | Fun 0.41.5 The programming language that makes You have fun |
Implements the OP_EQ opcode for equality comparison in the VM. More...

Go to the source code of this file.
Functions | |
| if (a.type==b.type) | |
| free_value (a) | |
| free_value (b) | |
Variables | |
| case | OP_EQ |
| Value | a = pop_value(vm) |
| int | eq = 0 |
| else | |
| break | |
Implements the OP_EQ opcode for equality comparison in the VM.
This file handles the OP_EQ instruction, which checks if two values are equal. The values are popped from the stack, and the result (1 or 0) is pushed back.
Behavior:
Error Handling:
Example: // Bytecode: OP_EQ // Stack before: [42, 42] // Stack after: [1]
Definition in file eq.c.
| free_value | ( | a | ) |
| free_value | ( | b | ) |