518 |
}; |
}; |
519 |
typedef Ref<Or,Node> OrRef; |
typedef Ref<Or,Node> OrRef; |
520 |
|
|
521 |
|
class BitwiseOr : virtual public BinaryOp, virtual public IntExpr { |
522 |
|
public: |
523 |
|
BitwiseOr(IntExprRef lhs, IntExprRef rhs) : BinaryOp(lhs,rhs) {} |
524 |
|
int evalInt(); |
525 |
|
void dump(int level = 0); |
526 |
|
}; |
527 |
|
typedef Ref<BitwiseOr,Node> BitwiseOrRef; |
528 |
|
|
529 |
class And : virtual public BinaryOp, virtual public IntExpr { |
class And : virtual public BinaryOp, virtual public IntExpr { |
530 |
public: |
public: |
531 |
And(IntExprRef lhs, IntExprRef rhs) : BinaryOp(lhs,rhs) {} |
And(IntExprRef lhs, IntExprRef rhs) : BinaryOp(lhs,rhs) {} |
534 |
}; |
}; |
535 |
typedef Ref<And,Node> AndRef; |
typedef Ref<And,Node> AndRef; |
536 |
|
|
537 |
|
class BitwiseAnd : virtual public BinaryOp, virtual public IntExpr { |
538 |
|
public: |
539 |
|
BitwiseAnd(IntExprRef lhs, IntExprRef rhs) : BinaryOp(lhs,rhs) {} |
540 |
|
int evalInt(); |
541 |
|
void dump(int level = 0); |
542 |
|
}; |
543 |
|
typedef Ref<BitwiseAnd,Node> BitwiseAndRef; |
544 |
|
|
545 |
class Not : virtual public IntExpr { |
class Not : virtual public IntExpr { |
546 |
IntExprRef expr; |
IntExprRef expr; |
547 |
public: |
public: |
553 |
}; |
}; |
554 |
typedef Ref<Not,Node> NotRef; |
typedef Ref<Not,Node> NotRef; |
555 |
|
|
556 |
|
class BitwiseNot : virtual public IntExpr { |
557 |
|
IntExprRef expr; |
558 |
|
public: |
559 |
|
BitwiseNot(IntExprRef expr) : expr(expr) {} |
560 |
|
int evalInt() { return ~expr->evalInt(); } |
561 |
|
void dump(int level = 0); |
562 |
|
bool isConstExpr() const { return expr->isConstExpr(); } |
563 |
|
bool isPolyphonic() const { return expr->isPolyphonic(); } |
564 |
|
}; |
565 |
|
typedef Ref<BitwiseNot,Node> BitwiseNotRef; |
566 |
|
|
567 |
class ParserContext : public VMParserContext { |
class ParserContext : public VMParserContext { |
568 |
public: |
public: |
569 |
struct Error { |
struct Error { |