mirror of
https://github.com/MorizzG/MLox.git
synced 2025-12-06 04:22:41 +00:00
added If, And, Or
This commit is contained in:
parent
77e57cd8c2
commit
dbcdbc216f
5 changed files with 120 additions and 58 deletions
|
|
@ -14,3 +14,6 @@ let type_string_of_lox_value lox_value =
|
|||
| Number _ -> "Number"
|
||||
| Bool _ -> "Bool"
|
||||
| Nil -> "Nil"
|
||||
|
||||
let lox_value_to_bool lox_value =
|
||||
match lox_value with String _ -> true | Number _ -> true | Bool b -> b | Nil -> false
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue