{
Type lexpType = this.mCurrentST.getExpType(node.getLExp());
Type rexpType = this.mCurrentST.getExpType(node.getRExp());
if(lexpType == Type.BUTTON) {
throw new SemanticException(
"Operands to == operator must be Int or Byte",
node.getRExp().getLine(),
node.getRExp().getPos());
}
if ( (lexpType != rexpType ) && (
( (lexpType != Type.INT) && (lexpType != Type.BYTE) ) ||
( (rexpType != Type.INT) && (rexpType != Type.BYTE) ) ) ) {
throw new SemanticException(
"Mixed Operands to == operator must be Int or Byte",
node.getLExp().getLine(),
node.getLExp().getPos());
}