Package zz.jinterp.JPrimitive

Examples of zz.jinterp.JPrimitive.JShort


     
      case SASTORE: {
        JPrimitive value = (JPrimitive) pop();
        JInt index = (JInt) pop();
        JArray array = (JArray) pop();
        array.set(index.v, new JShort((short) value.intValue()));
      } break;
       
      case POP:
        pop();
        break;
       
      case POP2:
        throw new UnsupportedOperationException();
       
      case DUP: {
        JObject o = pop();
        push(o);
        push(o);
      } break;
       
      case DUP_X1: {
        JObject o1 = pop();
        JObject o2 = pop();
        push(o1);
        push(o2);
        push(o1);
      } break;
       
      case DUP_X2:
        throw new UnsupportedOperationException();
       
      case DUP2:
        throw new UnsupportedOperationException();
       
      case DUP2_X1:
        throw new UnsupportedOperationException();
       
      case DUP2_X2:
        throw new UnsupportedOperationException();
       
      case SWAP: {
        JObject o1 = pop();
        JObject o2 = pop();
        push(o1);
        push(o2);
      } break;
       
      case IADD:
      case LADD:
      case FADD:
      case DADD: {
        JNumber n2 = (JNumber) pop();
        JNumber n1 = (JNumber) pop();
        push(n1.add(n2));
      } break;
       
      case ISUB:
      case LSUB:
      case FSUB:
      case DSUB: {
        JNumber n2 = (JNumber) pop();
        JNumber n1 = (JNumber) pop();
        push(n1.sub(n2));
      } break;
       
      case IMUL:
      case LMUL:
      case FMUL:
      case DMUL: {
        JNumber n2 = (JNumber) pop();
        JNumber n1 = (JNumber) pop();
        push(n1.mul(n2));
      } break;
       
      case IDIV:
      case LDIV:
      case FDIV:
      case DDIV: {
        JNumber n2 = (JNumber) pop();
        JNumber n1 = (JNumber) pop();
        push(n1.div(n2));
      } break;
       
      case IREM:
      case LREM:
      case FREM:
      case DREM: {
        JNumber n2 = (JNumber) pop();
        JNumber n1 = (JNumber) pop();
        push(n1.rem(n2));
      } break;
       
      case INEG:
      case LNEG:
      case FNEG:
      case DNEG: {
        JNumber n = (JNumber) pop();
        push(n.neg());
      } break;
       
      case ISHL:
      case LSHL: {
        JInt n2 = (JInt) pop();
        JBitNumber n1 = (JBitNumber) pop();
        push(n1.shl(n2.v));
      } break;
       
      case ISHR:
      case LSHR: {
        JInt n2 = (JInt) pop();
        JBitNumber n1 = (JBitNumber) pop();
        push(n1.shr(n2.v));
      } break;
       
      case IUSHR:
      case LUSHR: {
        JInt n2 = (JInt) pop();
        JBitNumber n1 = (JBitNumber) pop();
        push(n1.ushr(n2.v));
      } break;
       
      case IAND:
      case LAND: {
        JBitNumber n2 = (JBitNumber) pop();
        JBitNumber n1 = (JBitNumber) pop();
        push(n1.and(n2));
      } break;
       
      case IOR:
      case LOR: {
        JBitNumber n2 = (JBitNumber) pop();
        JBitNumber n1 = (JBitNumber) pop();
        push(n1.or(n2));
      } break;
       
      case IXOR:
      case LXOR: {
        JBitNumber n2 = (JBitNumber) pop();
        JBitNumber n1 = (JBitNumber) pop();
        push(n1.xor(n2));
      } break;
       
      case I2L: {
        JInt i = (JInt) pop();
        push(new JLong(i.v));
      } break;
       
      case I2F: {
        JInt i = (JInt) pop();
        push(new JFloat(i.v));
      } break;
       
      case I2D: {
        JInt i = (JInt) pop();
        push(new JDouble(i.v));
      } break;
       
      case L2I: {
        JLong i = (JLong) pop();
        push(new JInt((int) i.v));
      } break;
       
      case L2F: {
        JLong i = (JLong) pop();
        push(new JFloat(i.v));
      } break;
       
      case L2D: {
        JLong i = (JLong) pop();
        push(new JDouble(i.v));
      } break;
       
      case F2I: {
        JFloat i = (JFloat) pop();
        push(new JInt((int) i.v));
      } break;
       
      case F2L: {
        JFloat i = (JFloat) pop();
        push(new JLong((long) i.v));
      } break;
       
      case F2D: {
        JFloat i = (JFloat) pop();
        push(new JDouble(i.v));
      } break;
       
      case D2I: {
        JDouble i = (JDouble) pop();
        push(new JInt((int) i.v));
      } break;
       
      case D2L: {
        JDouble i = (JDouble) pop();
        push(new JLong((long) i.v));
      } break;
       
      case D2F: {
        JDouble i = (JDouble) pop();
        push(new JFloat((float) i.v));
      } break;
       
      case I2B: {
        JInt i = (JInt) pop();
        push(new JByte((byte) i.v));
      } break;
       
      case I2C: {
        JInt i = (JInt) pop();
        push(new JChar((char) i.v));
      } break;
       
      case I2S: {
        JInt i = (JInt) pop();
        push(new JShort((short) i.v));
      } break;
       
      case LCMP: {
        JLong l2 = (JLong) pop();
        JLong l1 = (JLong) pop();
View Full Code Here


    {
      return new JBoolean((Boolean) aObject);
    }
    else if (aObject instanceof Short)
    {
      return new JShort((Short) aObject);
    }
    else if (aObject instanceof Byte)
    {
      return new JByte((Byte) aObject);
    }
View Full Code Here

TOP

Related Classes of zz.jinterp.JPrimitive.JShort

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.