aboutsummaryrefslogtreecommitdiff
path: root/src/types.c
diff options
context:
space:
mode:
authorMustafa Quraish <[email protected]>2022-02-05 01:38:34 -0500
committerMustafa Quraish <[email protected]>2022-02-05 08:56:15 -0500
commit81a0df76cbcd46799134e688dabb8dc870da5351 (patch)
treec272607d270b3ae8f1ba95cb6f6b28c9d0bc6075 /src/types.c
parentMiscellaneous stdlib additions (diff)
downloadcup-81a0df76cbcd46799134e688dabb8dc870da5351.tar.xz
cup-81a0df76cbcd46799134e688dabb8dc870da5351.zip
Add support for some more binary ops: |, &, ^
Diffstat (limited to 'src/types.c')
-rw-r--r--src/types.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/types.c b/src/types.c
index c44f88d..c8a9b72 100644
--- a/src/types.c
+++ b/src/types.c
@@ -298,6 +298,9 @@ Node *handle_binary_expr_types(Node *node, Token *token)
case OP_GT:
case OP_LEQ:
case OP_GEQ:
+ case OP_BWAND:
+ case OP_BWOR:
+ case OP_XOR:
case OP_AND:
case OP_OR: {
node->expr_type = type_new(TYPE_INT);