Add bitshift operators

This commit is contained in:
AmazingPP 2022-07-21 10:59:19 +08:00
parent 1d2c12e980
commit f2bfa61fc6
10 changed files with 57 additions and 4 deletions

View file

@ -89,6 +89,10 @@ string CPPCompile::GenExpr(const Expr* e, GenType gt, bool top_level)
return GenBinary(e, gt, "|", "or");
case EXPR_XOR:
return GenBinary(e, gt, "^", "xor");
case EXPR_LSHIFT:
return GenBinary(e, gt, "<<", "lshift");
case EXPR_RSHIFT:
return GenBinary(e, gt, ">>", "rshift");
case EXPR_AND_AND:
return GenBinary(e, gt, "&&", "andand");
case EXPR_OR_OR: