@Override
    public void sawOpcode(int seen) {
        Units unit = null;
        try {
            stack.precomputation(this);

            switch (seen) {
                case Const.INVOKEVIRTUAL:
                case Const.INVOKEINTERFACE:
                case Const.INVOKESTATIC:
                    unit = processInvoke();
                break;

                case Const.GETSTATIC:
                    String clsName = getClassConstantOperand();
                    if ("java/util/concurrent/TimeUnit".equals(clsName) || "edu/emory/matchcs/backport/java/util/concurrent/TimeUnit".equals(clsName)) {
                        unit = TIMEUNIT_TO_UNITS.get(getNameConstantOperand());
                    }
                break;

                case Const.L2I:
                case Const.I2L:
                    if (stack.getStackDepth() > 0) {
                        OpcodeStack.Item item = stack.getStackItem(0);
                        unit = (Units) item.getUserValue();
                    }
                break;

                case Const.IADD:
                case Const.ISUB:
                case Const.IMUL:
                case Const.IDIV:
                case Const.IREM:
                case Const.LADD:
                case Const.LSUB:
                case Const.LMUL:
                case Const.LDIV:
                case Const.LREM:
                    processArithmetic();
                break;

                default:
                break;
            }
        } finally {
            stack.sawOpcode(this, seen);
            if ((unit != null) && (stack.getStackDepth() > 0)) {
                OpcodeStack.Item item = stack.getStackItem(0);
                item.setUserValue(unit);
            }
        }
    }
@ Override public void sawOpcode ( int seen ) { Units unit = null ; try { stack . precomputation ( this ) ; switch ( seen ) { case Const . INVOKEVIRTUAL : case Const . INVOKEINTERFACE : case Const . INVOKESTATIC : unit = processInvoke ( ) ; break ; case Const . GETSTATIC : String clsName = getClassConstantOperand ( ) ; if ( "java/util/concurrent/TimeUnit" . equals ( clsName ) || "edu/emory/matchcs/backport/java/util/concurrent/TimeUnit" . equals ( clsName ) ) { unit = TIMEUNIT_TO_UNITS . get ( getNameConstantOperand ( ) ) ; } break ; case Const . L2I : case Const . I2L : if ( stack . getStackDepth ( ) > 0 ) { OpcodeStack . Item item = stack . getStackItem ( 0 ) ; unit = ( Units ) item . getUserValue ( ) ; } break ; case Const . IADD : case Const . ISUB : case Const . IMUL : case Const . IDIV : case Const . IREM : case Const . LADD : case Const . LSUB : case Const . LMUL : case Const . LDIV : case Const . LREM : processArithmetic ( ) ; break ; default : break ; } } finally { stack . sawOpcode ( this , seen ) ; if ( ( unit != null ) && ( stack . getStackDepth ( ) > 0 ) ) { OpcodeStack . Item item = stack . getStackItem ( 0 ) ; item . setUserValue ( unit ) ; } } }
overrides the visitor to look for operations on two time unit values that are conflicting