binop: token.AND_NOT

This commit is contained in:
visualfc
2024-05-10 21:30:17 +08:00
parent aae663e5e5
commit 1fb37c37fe
3 changed files with 101 additions and 82 deletions

View File

@@ -295,7 +295,7 @@ func (b Builder) BinOp(op token.Token, x, y Expr) Expr {
}
case isLogicOp(op): // op: & | ^ << >> &^
if op == token.AND_NOT {
panic("todo")
return Expr{b.impl.CreateAnd(x.impl, b.impl.CreateNot(y.impl, ""), ""), x.Type}
}
kind := x.kind
llop := logicOpToLLVM[op-logicOpBase]