Potentially called from generated bytecode
421808
@SuppressWarnings({"ConstantConditions"})
  public static Object evaluate( IType type, Object lhsValue, Object rhsValue, IType lhsType, IType rhsType, int iOperator, boolean bNullSafe )
  {
    boolean bDynamic = false;
    if( lhsType instanceof IPlaceholder && ((IPlaceholder)lhsType).isPlaceholder() )
    {
      lhsType = TypeSystem.getFromObject( lhsValue );
      bDynamic = true;
    }
    if( rhsType instanceof IPlaceholder && ((IPlaceholder)rhsType).isPlaceholder() )
    {
      rhsType = TypeSystem.getFromObject( rhsValue );
      bDynamic = true;
    }
    if( bDynamic )
    {
      ArithmeticExpression overrideMethod = new MultiplicativeExpression();
      type = ParserBase.resolveRuntimeType( overrideMethod, lhsType, iOperator, rhsType );
      IMethodInfo mi = overrideMethod.getOverride();
      if( mi != null )
      {
        return mi.getCallHandler().handleCall( lhsValue, ReflectUtil.coerceArgsIfNecessary( mi.getParameters(), rhsValue ) );
      }
    }

    if( lhsValue == null )
    {
      if( bNullSafe )
      {
        return null;
      }
      throw new NullPointerException("left-hand operand was null");
    }
    if( rhsValue == null )
    {
      if( bNullSafe )
      {
        return null;
      }
      throw new NullPointerException("right-hand operand was null");
    }

    IDimension customNumberBase = null;
    if( JavaTypes.IDIMENSION().isAssignableFrom( type ) )
    {
      DimensionOperandResolver customNumberResolver = DimensionOperandResolver.resolve( type, lhsType, lhsValue, rhsType, rhsValue );
      type = customNumberResolver.getRawNumberType();
      lhsValue = customNumberResolver.getLhsValue();
      rhsValue = customNumberResolver.getRhsValue();
      customNumberBase = customNumberResolver.getBase();
    }

    Object retValue;
    ICoercionManager cm = CommonServices.getCoercionManager();
    switch( iOperator )
    {
      case '*':
      {
        if( type == JavaTypes.RATIONAL() )
        {
          retValue = cm.makeRationalFrom( lhsValue ).multiply( cm.makeRationalFrom( rhsValue ) );
        }
        else if( type == JavaTypes.BIG_DECIMAL() )
        {
          retValue = cm.makeBigDecimalFrom( lhsValue ).multiply( cm.makeBigDecimalFrom( rhsValue ) );
        }
        else if( type == JavaTypes.BIG_INTEGER() )
        {
          retValue = cm.makeBigIntegerFrom( lhsValue ).multiply( cm.makeBigIntegerFrom( rhsValue ) );
        }
        else if( type == JavaTypes.INTEGER() || type == JavaTypes.pINT() )
        {
          retValue = cm.makeIntegerFrom( lhsValue ) * cm.makeIntegerFrom( rhsValue );
        }
        else if( type == JavaTypes.LONG() || type == JavaTypes.pLONG() )
        {
          retValue = makeLong( cm.makeLongFrom( lhsValue ) * cm.makeLongFrom( rhsValue ) );
        }
        else if( type == JavaTypes.DOUBLE() || type == JavaTypes.pDOUBLE() )
        {
          retValue =  makeDoubleValue( makeDoubleValue( lhsValue ) * makeDoubleValue( rhsValue ) );
        }
        else if( type == JavaTypes.FLOAT() || type == JavaTypes.pFLOAT() )
        {
          retValue = makeFloatValue( makeFloatValue( lhsValue ) * makeFloatValue( rhsValue ) );
        }
        else if( type == JavaTypes.SHORT() || type == JavaTypes.pSHORT() )
        {
          retValue = Integer.valueOf( cm.makeIntegerFrom( lhsValue ) * cm.makeIntegerFrom( rhsValue ) ).shortValue();
        }
        else if( type == JavaTypes.BYTE() || type == JavaTypes.pBYTE() )
        {
          retValue = (byte)(cm.makeIntegerFrom( lhsValue ) * cm.makeIntegerFrom( rhsValue ));
        }
        else
        {
          throw new UnsupportedNumberTypeException(type);
        }
        break;
      }

      case '/':
      {
        if( type == JavaTypes.RATIONAL() )
        {
          retValue = cm.makeRationalFrom( lhsValue ).divide( cm.makeRationalFrom( rhsValue ) );
        }
        else if( type == JavaTypes.BIG_DECIMAL() )
        {
          retValue = cm.makeBigDecimalFrom( lhsValue ).divide( cm.makeBigDecimalFrom( rhsValue ), MathContext.DECIMAL128 );
        }
        else if( type == JavaTypes.BIG_INTEGER() )
        {
          retValue = cm.makeBigIntegerFrom( lhsValue ).divide( cm.makeBigIntegerFrom( rhsValue ) );
        }
        else if( type == JavaTypes.INTEGER() || type == JavaTypes.pINT() )
        {
          retValue = cm.makeIntegerFrom( lhsValue ) / cm.makeIntegerFrom( rhsValue );
        }
        else if( type == JavaTypes.LONG() || type == JavaTypes.pLONG() )
        {
          retValue = makeLong( cm.makeLongFrom( lhsValue ) / cm.makeLongFrom( rhsValue ) );
        }
        else if( type == JavaTypes.DOUBLE() || type == JavaTypes.pDOUBLE() )
        {
          retValue = makeDoubleValue( makeDoubleValue( lhsValue ) / makeDoubleValue( rhsValue ) );
        }
        else if( type == JavaTypes.FLOAT() || type == JavaTypes.pFLOAT() )
        {
          retValue = makeFloatValue( makeFloatValue( lhsValue ) / makeFloatValue( rhsValue ) );
        }
        else if( type == JavaTypes.SHORT() || type == JavaTypes.pSHORT() )
        {
          retValue = Integer.valueOf( cm.makeIntegerFrom( lhsValue ) / cm.makeIntegerFrom( rhsValue ) ).shortValue();
        }
        else if( type == JavaTypes.BYTE() || type == JavaTypes.pBYTE() )
        {
          retValue = (byte)(cm.makeIntegerFrom( lhsValue ) / cm.makeIntegerFrom( rhsValue ));
        }
        else
        {
          throw new UnsupportedNumberTypeException(type);
        }
        break;
      }

      case '%':
      {
        if( type == JavaTypes.RATIONAL() )
        {
          retValue = cm.makeRationalFrom( lhsValue ).modulo( cm.makeRationalFrom( rhsValue ) );
        }
        else if( type == JavaTypes.BIG_DECIMAL() )
        {
          retValue = cm.makeBigDecimalFrom( lhsValue ).remainder( cm.makeBigDecimalFrom( rhsValue ), MathContext.DECIMAL128 ).abs();
        }
        else if( type == JavaTypes.BIG_INTEGER() )
        {
          retValue = cm.makeBigIntegerFrom( lhsValue ).mod( cm.makeBigIntegerFrom( rhsValue ) );
        }
        else if( type == JavaTypes.INTEGER() || type == JavaTypes.pINT() )
        {
          retValue = cm.makeIntegerFrom( lhsValue ) % cm.makeIntegerFrom( rhsValue );
        }
        else if( type == JavaTypes.LONG() || type == JavaTypes.pLONG() )
        {
          retValue = makeLong( cm.makeLongFrom( lhsValue ) % cm.makeLongFrom( rhsValue ) );
        }
        else if( type == JavaTypes.DOUBLE() || type == JavaTypes.pDOUBLE() )
        {
          retValue = makeDoubleValue( makeDoubleValue( lhsValue ) % makeDoubleValue( rhsValue ) );
        }
        else if( type == JavaTypes.FLOAT() || type == JavaTypes.pFLOAT() )
        {
          retValue = makeFloatValue( makeFloatValue( lhsValue ) % makeFloatValue( rhsValue ) );
        }
        else if( type == JavaTypes.SHORT() || type == JavaTypes.pSHORT() )
        {
          retValue = Integer.valueOf( cm.makeIntegerFrom( lhsValue ) % cm.makeIntegerFrom( rhsValue ) ).shortValue();
        }
        else if( type == JavaTypes.BYTE() || type == JavaTypes.pBYTE() )
        {
          retValue = (byte)(cm.makeIntegerFrom( lhsValue ) % cm.makeIntegerFrom( rhsValue ));
        }
        else
        {
          throw new UnsupportedNumberTypeException(type);
        }
        break;
      }

      default:
        retValue = null;
    }

    if( retValue != null )
    {
      if( customNumberBase != null )
      {
        //noinspection unchecked
        retValue = customNumberBase.fromNumber( (Number)retValue );
      }
    }
    return retValue;
  }
1152959
@Override
    public void sawOpcode(int seen) {

        try {
            stack.precomputation(this);

            if ((seen == Const.INVOKEVIRTUAL) || (seen == Const.INVOKEINTERFACE)) {
                FQMethod key = new FQMethod(getClassConstantOperand(), getNameConstantOperand(), getSigConstantOperand());

                Object posObject = characterMethods.get(key);
                if (posObject instanceof Integer) {
                    if (checkSingleParamMethod(((Integer) posObject).intValue()) && !isInlineAppend(key)) {
                        reportBug();
                    }
                } else if ((posObject instanceof IntPair) && checkDoubleParamMethod((IntPair) posObject)) {
                    reportBug();
                }

            } else if (seen == Const.DUP) {
                if (stack.getStackDepth() > 0) {
                    OpcodeStack.Item itm = stack.getStackItem(0);
                    String duppedSig = itm.getSignature();
                    if (Values.SIG_JAVA_UTIL_STRINGBUILDER.equals(duppedSig) || Values.SIG_JAVA_UTIL_STRINGBUFFER.equals(duppedSig)) {
                        itm.setUserValue(UCPMUserValue.INLINE);
                    }
                }
            } else if ((seen == Const.PUTFIELD) || (((seen == Const.PUTSTATIC) || OpcodeUtils.isAStore(seen)) && (stack.getStackDepth() > 0))) {
                OpcodeStack.Item itm = stack.getStackItem(0);
                itm.setUserValue(null);
            }
        } finally {
            UCPMUserValue uv = callHasInline(seen);

            stack.sawOpcode(this, seen);
            if ((uv == UCPMUserValue.INLINE) && (stack.getStackDepth() > 0)) {
                OpcodeStack.Item itm = stack.getStackItem(0);
                itm.setUserValue(uv);
            }
        }
    }
161253
@Override
    public void visitCode(Code obj) {

        Method m = getMethod();
        if (m.isSynthetic()) {
            return;
        }

        if (isEnum && "values".equals(m.getName())) {
            return;
        }

        String sig = m.getSignature();
        int sigPos = sig.indexOf(")[");
        if (sigPos < 0) {
            return;
        }
        if (INITIAL_VALUE.equals(m.getName())) {
            try {
                if ((THREAD_LOCAL_CLASS == null) || getClassContext().getJavaClass().instanceOf(THREAD_LOCAL_CLASS)) {
                    return;
                }
            } catch (ClassNotFoundException e) {
                bugReporter.reportMissingClass(e);
                return;
            }
        }

        stack.resetForMethodEntry(this);
        returnArraySig = sig.substring(sigPos + 1);
        uninitializedRegs.clear();
        arrayAliases.clear();
        storedUVs.clear();
        super.visitCode(obj);
    }
249407
void generateOutboundCode(Definition def)
   {
      if (def.isSupportOutbound())
      {
         if (def.getMcfDefs() == null)
            throw new IllegalStateException("Should define at least one mcf class");

         for (int num = 0; num < def.getMcfDefs().size(); num++)
         {
            generateMultiMcfClassCode(def, "Mcf", num);
            generateMultiMcfClassCode(def, "Mc", num);
            generateMultiMcfClassCode(def, "McMeta", num);

            if (!def.getMcfDefs().get(num).isUseCciConnection())
            {
               generateMultiMcfClassCode(def, "CfInterface", num);
               generateMultiMcfClassCode(def, "Cf", num);
               generateMultiMcfClassCode(def, "ConnInterface", num);
               generateMultiMcfClassCode(def, "ConnImpl", num);
            }
            else
            {
               generateMultiMcfClassCode(def, "CciConn", num);
               generateMultiMcfClassCode(def, "CciConnFactory", num);
               generateMultiMcfClassCode(def, "ConnMeta", num);
               generateMultiMcfClassCode(def, "ConnSpec", num);
            }
         }
      }
   }
384726
@Override
    public void sawOpcode(int seen) {
        try {
            stack.precomputation(this);

            if (unsafeCallOccurred && OpcodeUtils.isAStore(seen)) {
                int storeReg = RegisterUtils.getAStoreReg(this, seen);
                if (storeReg >= 0) {
                    unsafeAliases.set(storeReg);
                }
            }

            if ((seen == Const.INVOKEVIRTUAL) || (seen == Const.INVOKESPECIAL) || (seen == Const.INVOKEINTERFACE) || (seen == Const.INVOKEDYNAMIC)) {
                String methodSig = getSigConstantOperand();

                MethodInfo mi = Statistics.getStatistics().getMethodStatistics(getClassConstantOperand(), getNameConstantOperand(), methodSig);
                if (mi.getModifiesState()) {
                    unsafeCallOccurred = true;
                } else {
                    if (!Values.SIG_VOID.equals(SignatureUtils.getReturnSignature(methodSig))) {
                        int parmCount = SignatureUtils.getNumParameters(methodSig);
                        if (stack.getStackDepth() > parmCount) {
                            OpcodeStack.Item itm = stack.getStackItem(parmCount);
                            unsafeCallOccurred = unsafeAliases.get(itm.getRegisterNumber());
                        } else {
                            unsafeCallOccurred = false;
                        }
                    } else {
                        unsafeCallOccurred = false;
                    }
                }
            } else if (seen == Const.INVOKESTATIC) {
                unsafeCallOccurred = getDottedClassConstantOperand().equals(this.getClassContext().getJavaClass().getClassName());
            } else if (((seen >= Const.IFEQ) && (seen <= Const.GOTO)) || (seen == Const.GOTO_W)) {
                Integer from = Integer.valueOf(getPC());
                Integer to = Integer.valueOf(getBranchTarget());
                branchInfo.put(from, to);
                unsafeCallOccurred = false;
            } else {
                unsafeCallOccurred = false;
            }

            if (seen == Const.MONITORENTER) {
                if (syncPC < 0) {
                    syncPC = getPC();
                    if (stack.getStackDepth() > 0) {
                        OpcodeStack.Item itm = stack.getStackItem(0);
                        int monitorReg = itm.getRegisterNumber();
                        if (monitorReg >= 0) {
                            unsafeAliases.set(monitorReg);
                        }
                    }
                }
            } else if (seen == Const.MONITOREXIT) {
                syncPC = -1;
            } else if (syncPC >= 0) {
                processSyncBlockInstruction(seen);
            }
        } finally {
            stack.sawOpcode(this, seen);
        }
    }
311454
@Override
    public void sawOpcode(int seen) {
        if (isInitializer) {
            lookForCustomThreadFactoriesInConstructors(seen);
            return;
        }

        try {
            stack.precomputation(this);

            if ((seen == Const.INVOKEVIRTUAL) || (seen == Const.INVOKEINTERFACE)) {
                processInvoke();
            }
            // TODO Should not include private methods
            else if (seen == Const.ARETURN) {
                removeFieldsThatGetReturned();
            } else if (seen == Const.PUTFIELD) {
                XField f = getXFieldOperand();
                if (f != null) {
                    reportOverwrittenField(f);
                }
            } else if (seen == Const.IFNONNULL) {
                // indicates a null check, which means that we get an exemption
                // until the end of the branch
                OpcodeStack.Item nullCheckItem = stack.getStackItem(0);
                XField fieldWhichWasNullChecked = nullCheckItem.getXField();
                if (fieldWhichWasNullChecked != null) {
                    exemptExecutors.put(fieldWhichWasNullChecked, Integer.valueOf(getPC() + getBranchOffset()));
                }
            }
        } finally {
            stack.sawOpcode(this, seen);
        }
    }
446149
private void process() {
    if (hasExternsRoot()) {
      sourceKind = SourceKind.EXTERN;
      NodeTraversal.traverse(compiler, externsRoot, new BuildGlobalNamespace());
    }
    sourceKind = SourceKind.CODE;

    NodeTraversal.traverse(compiler, root, new BuildGlobalNamespace());
    generated = true;
    externsScope = null;
  }
630229
@Override
    public void sawOpcode(int seen) {
        if (seenReturn && seenTransferOfControl && seenStateChange) {
            return;
        }

        if (DEBUG) {
            System.out.println(stack);
            System.out.println(getPC() + " : " + Const.getOpcodeName(seen));
        }

        if ((seen == Const.INVOKEVIRTUAL || seen == Const.INVOKEINTERFACE) && "add".equals(getNameConstantOperand())
                && "(Ljava/lang/Object;)Z".equals(getSigConstantOperand()) && stack.getStackDepth() >= 2) {
            OpcodeStack.Item it0 = stack.getStackItem(0);
            int r0 = it0.getRegisterNumber();
            OpcodeStack.Item it1 = stack.getStackItem(1);
            int r1 = it1.getRegisterNumber();
            if (r0 == r1 && r0 > 0) {
                bugReporter.reportBug(new BugInstance(this, "IL_CONTAINER_ADDED_TO_ITSELF", NORMAL_PRIORITY).addClassAndMethod(
                        this).addSourceLine(this));
            }
        }

        if ((seen == Const.INVOKEVIRTUAL || seen == Const.INVOKESPECIAL || seen == Const.INVOKEINTERFACE || seen == Const.INVOKESTATIC)
                && getNameConstantOperand().equals(getMethodName())
                && getSigConstantOperand().equals(getMethodSig())
                && (seen == Const.INVOKESTATIC) == getMethod().isStatic()
                && (seen == Const.INVOKESPECIAL) == (getMethod().isPrivate() && !getMethod().isStatic() || Const.CONSTRUCTOR_NAME.equals(getMethodName()))) {
            Type arguments[] = getMethod().getArgumentTypes();
            // stack.getStackDepth() >= parameters
            int parameters = arguments.length;
            if (!getMethod().isStatic()) {
                parameters++;
            }
            XMethod xMethod = XFactory.createReferencedXMethod(this);
            if (DEBUG) {
                System.out.println("IL: Checking...");
                System.out.println(xMethod);
                System.out.println("vs. " + getClassName() + "." + getMethodName() + " : " + getMethodSig());

            }
            if (xMethod.getClassName().replace('.', '/').equals(getClassName()) || seen == Const.INVOKEINTERFACE) {
                // Invocation of same method
                // Now need to see if parameters are the same
                int firstParameter = 0;
                if (Const.CONSTRUCTOR_NAME.equals(getMethodName())) {
                    firstParameter = 1;
                }

                // match1 should be true if it is any call to the exact same
                // method
                // and no state has been change.
                // if match1 is true, the method may not always perform
                // a recursive infinite loop, but this particular method call is
                // an infinite
                // recursive loop

                boolean match1 = !seenStateChange;
                for (int i = firstParameter; match1 && i < parameters; i++) {
                    OpcodeStack.Item it = stack.getStackItem(parameters - 1 - i);
                    if (!it.isInitialParameter() || it.getRegisterNumber() != i) {
                        match1 = false;
                    }
                }

                boolean sameMethod = seen == Const.INVOKESTATIC || Const.CONSTRUCTOR_NAME.equals(getNameConstantOperand());
                if (!sameMethod) {
                    // Have to check if first parmeter is the same
                    // know there must be a this argument
                    if (DEBUG) {
                        System.out.println("Stack is " + stack);
                    }
                    OpcodeStack.Item p = stack.getStackItem(parameters - 1);
                    if (DEBUG) {
                        System.out.println("parameters = " + parameters + ", Item is " + p);
                    }
                    String sig = p.getSignature();
                    sameMethod = p.isInitialParameter() && p.getRegisterNumber() == 0 && sig.equals("L" + getClassName() + ";");

                }

                // match2 and match3 are two different ways of seeing if the
                // call site
                // postdominates the method entry.

                // technically, we use (!seenTransferOfControl || !seenReturn &&
                // largestBranchTarget < getPC())
                // as a check that the call site postdominates the method entry.
                // If those are true,
                // and sameMethod is true, we have a guaranteed IL.

                boolean match2 = sameMethod && !seenTransferOfControl;
                boolean match3 = sameMethod && !seenReturn && largestBranchTarget < getPC();
                if (match1 || match2 || match3) {
                    if (DEBUG) {
                        System.out.println("IL: " + sameMethod + " " + match1 + " " + match2 + " " + match3);
                    }
                    //                    int priority = HIGH_PRIORITY;
                    //                    if (!match1 && !match2 && seenThrow)
                    //                        priority = NORMAL_PRIORITY;
                    //                    if (seen == Const.INVOKEINTERFACE)
                    //                        priority = NORMAL_PRIORITY;
                    bugReporter.reportBug(new BugInstance(this, "IL_INFINITE_RECURSIVE_LOOP", HIGH_PRIORITY).addClassAndMethod(
                            this).addSourceLine(this));
                }
            }
        }

        switch (seen) {
        case Const.ARETURN:
        case Const.IRETURN:
        case Const.LRETURN:
        case Const.RETURN:
        case Const.DRETURN:
        case Const.FRETURN:
            seenReturn = true;
            seenTransferOfControl = true;
            break;
        case Const.ATHROW:
            //            seenThrow = true;
            seenTransferOfControl = true;
            break;
        case Const.PUTSTATIC:
        case Const.PUTFIELD:
        case Const.IASTORE:
        case Const.AASTORE:
        case Const.DASTORE:
        case Const.FASTORE:
        case Const.LASTORE:
        case Const.SASTORE:
        case Const.CASTORE:
        case Const.BASTORE:
            seenStateChange = true;
            break;
        case Const.INVOKEVIRTUAL:
        case Const.INVOKESPECIAL:
        case Const.INVOKEINTERFACE:
        case Const.INVOKESTATIC:
            if ("print".equals(getNameConstantOperand()) || "println".equals(getNameConstantOperand())
                    || "log".equals(getNameConstantOperand()) || "toString".equals(getNameConstantOperand())) {
                break;
            }
            seenStateChange = true;
            break;
        default:
            break;
        }
    }
22794
@Override
    public void sawOpcode(int seen) {
        boolean sawSBToString = false;
        try {

            stack.precomputation(this);
            if ((seen >= Const.IRETURN) && (seen <= Const.ARETURN)) {
                if (stack.getStackDepth() > 0) {
                    OpcodeStack.Item item = stack.getStackItem(0);

                    Integer register = Integer.valueOf(item.getRegisterNumber());
                    Object constant = registerConstants.get(register);
                    if (CONSTANT_DOESNT_EXIST.equals(constant)) {
                        throw new StopOpcodeParsingException();
                    }

                    String returnSig = item.getSignature();
                    if ((returnSig != null) && returnSig.startsWith(Values.SIG_ARRAY_PREFIX)) {
                        XField f = item.getXField();
                        if ((f == null) || (!f.isStatic())) {
                            throw new StopOpcodeParsingException();
                        }
                    }

                    constant = item.getConstant();
                    if (constant == null) {
                        throw new StopOpcodeParsingException();
                    }
                    if (Boolean.TRUE.equals(item.getUserValue()) && ("".equals(constant))) {
                        throw new StopOpcodeParsingException();
                    }
                    if ((returnConstant != null) && (!returnConstant.equals(constant))) {
                        throw new StopOpcodeParsingException();
                    }

                    returnRegister = Integer.valueOf(item.getRegisterNumber());
                    returnConstant = constant;
                    returnPC = getPC();
                }
            } else if ((seen == Const.GOTO) || (seen == Const.GOTO_W)) {
                if (stack.getStackDepth() > 0) {
                    // Ternaries confuse us too much, if the code has a ternary well - oh well
                    throw new StopOpcodeParsingException();
                }
            } else if (seen == Const.ATHROW) {
                throw new StopOpcodeParsingException();
            } else if (seen == Const.INVOKEVIRTUAL) {
                String clsName = getClassConstantOperand();
                if (SignatureUtils.isPlainStringConvertableClass(clsName)) {
                    sawSBToString = Values.TOSTRING.equals(getNameConstantOperand());
                }
            } else if (((seen >= Const.ISTORE) && (seen <= Const.ASTORE_3)) || (seen == Const.IINC)) {
                Integer register = Integer.valueOf(getRegisterOperand());
                if ((returnRegister.intValue() != -1) && (register.equals(returnRegister))) {
                    throw new StopOpcodeParsingException();
                }

                if (stack.getStackDepth() > 0) {
                    OpcodeStack.Item item = stack.getStackItem(0);
                    Object constant = item.getConstant();

                    Object regConstant = registerConstants.get(register);
                    if (regConstant != null) {
                        if ((constant == null) || !constant.equals(regConstant)) {
                            registerConstants.put(register, CONSTANT_DOESNT_EXIST);
                        }
                    } else {
                        if (item.getSignature().contains(Values.SIG_ARRAY_PREFIX)) {
                            registerConstants.put(register, CONSTANT_DOESNT_EXIST);
                        } else {
                            registerConstants.put(register, constant == null ? CONSTANT_DOESNT_EXIST : constant);
                        }
                    }
                } else {
                    registerConstants.put(register, CONSTANT_DOESNT_EXIST);
                }

                if (returnRegister.equals(register)) {
                    Object constant = registerConstants.get(returnRegister);
                    if (CONSTANT_DOESNT_EXIST.equals(constant)) {
                        throw new StopOpcodeParsingException();
                    }
                }
            }

        } finally {
            TernaryPatcher.pre(stack, seen);
            stack.sawOpcode(this, seen);
            TernaryPatcher.post(stack, seen);
            if (sawSBToString && (stack.getStackDepth() > 0)) {
                OpcodeStack.Item item = stack.getStackItem(0);
                item.setUserValue(Boolean.TRUE);
            }
        }
    }
1246565
@Override
    public void visitCode(Code obj) {
        Method m = getMethod();
        if (!Values.CONSTRUCTOR.equals(m.getName())) {
            super.visitCode(obj);
        }
    }
1252043
function generateApplicationCode(swagger, codegenOptions) {
  debug('Generating application code.');

  // Build up the execution parameters for the templates.
  const templateFunc = codegenOptions.templateSet;
  const outputDirectory = codegenOptions.temporaryDirectory;
  const codegenSettings = defaults(
    templateFunc(codegenOptions.templateSettings),
    {
      output: (name, content) => {
        const fullName = path.join(outputDirectory, name);
        const parsed = path.parse(fullName);
        mkdirp.sync(parsed.dir);
        fs.writeFileSync(fullName, content);
      },
      swagger: JSON.parse(JSON.stringify(swagger)), // Clone to avoid issues
    });

  // Perform the actual code generation
  codegen(codegenSettings);
}
661088
@Override
    public void sawOpcode(int seen) {
        ImmutabilityType seenImmutable = null;
        try {
            stack.precomputation(this);

            switch (seen) {
                case Const.INVOKESTATIC: {
                    String className = getClassConstantOperand();
                    String methodName = getNameConstantOperand();

                    if (IMMUTABLE_PRODUCING_METHODS.contains(className + '.' + methodName)) {
                        seenImmutable = ImmutabilityType.IMMUTABLE;
                        break;
                    }
                }
                //$FALL-THROUGH$
                case Const.INVOKEINTERFACE:
                case Const.INVOKESPECIAL:
                case Const.INVOKEVIRTUAL: {
                    String className = getClassConstantOperand();
                    String methodName = getNameConstantOperand();
                    String signature = getSigConstantOperand();

                    MethodInfo mi = Statistics.getStatistics().getMethodStatistics(className, methodName, signature);
                    seenImmutable = mi.getImmutabilityType();
                    if (seenImmutable == ImmutabilityType.UNKNOWN) {
                        seenImmutable = null;
                    }
                }
                break;

                case Const.ARETURN: {
                    processARreturn();
                    break;
                }
                default:
                break;
            }

        } finally {
            stack.sawOpcode(this, seen);
            if ((seenImmutable != null) && (stack.getStackDepth() > 0)) {
                OpcodeStack.Item item = stack.getStackItem(0);
                item.setUserValue(seenImmutable);
            }
        }
    }
526603
void generateRaCode(Definition def)
   {
      if (def.isUseRa())
      {
         generateClassCode(def, "Ra");
         generateClassCode(def, "RaMeta");
      }
      if (def.isGenAdminObject())
      {
         for (int i = 0; i < def.getAdminObjects().size(); i++)
         {
            generateMultiAdminObjectClassCode(def, "AoImpl", i);
            generateMultiAdminObjectClassCode(def, "AoInterface", i);
         }
      }
   }
1293491
@Override
    public void sawOpcode(int seen) {
        try {
            stack.precomputation(this);

            if (OpcodeUtils.isStore(seen) || OpcodeUtils.isLoad(seen)) {
                int reg = getRegisterOperand();
                unusedParms.clear(reg);
            } else if (OpcodeUtils.isReturn(seen) && (stack.getStackDepth() > 0)) {
                OpcodeStack.Item item = stack.getStackItem(0);
                int reg = item.getRegisterNumber();
                if (reg >= 0) {
                    unusedParms.clear(reg);
                }
            }
            if (unusedParms.isEmpty()) {
                throw new StopOpcodeParsingException();
            }
        } finally {
            stack.sawOpcode(this, seen);
        }
    }
1229983
def to_code(self, stacksize=None):
        """"""
        if stacksize is None:
            stacksize = self.compute_stacksize()
        bc = self.to_bytecode()
        return bc.to_code(stacksize=stacksize)
1261160
@Override
    public void visitCode(Code obj) {

        Method m = getMethod();
        if ((!m.isStatic() || !Values.STATIC_INITIALIZER.equals(m.getName())) && (!m.getName().contains("enum constant"))) { // a findbugs thing!!
            byte[] code = obj.getCode();
            if (code.length >= UNJITABLE_CODE_LENGTH) {
                bugReporter.reportBug(new BugInstance(this, BugType.UJM_UNJITABLE_METHOD.name(), NORMAL_PRIORITY).addClass(this).addMethod(this)
                        .addString("Code Bytes: " + code.length));
            }
        }
    }
268794
@Override
	public void sawOpcode(final int seen) {
		try {
			stack.precomputation(this);

			if (seen == Const.INVOKEINTERFACE) {
				processInvokeInterface();
			} else if (seen == Const.INVOKEVIRTUAL) {
				processInvokeVirtual();
			} else if ((seen == Const.ARETURN) && (stack.getStackDepth() > 0)) {
				OpcodeStack.Item item = stack.getStackItem(0);
				XField field = item.getXField();
				if (field != null) {
					String fieldName = field.getName();
					fieldsReported.remove(fieldName);
					if (fieldsReported.isEmpty()) {
						throw new StopOpcodeParsingException();
					}
				}
			}
		} finally {
			stack.sawOpcode(this, seen);
		}
	}