overrides the visitor reset the stack

@param obj the context object of the currently parsed code block
551276
@Override
    public void visitCode(Code obj) {

        stack.resetForMethodEntry(this);
        localSpecialObjects.clear();
        sawTernary = false;
        super.visitCode(obj);

        for (Integer pc : localSpecialObjects.values()) {
            bugReporter.reportBug(
                    makeLocalBugInstance().addClass(this).addMethod(this).addSourceLine(this, pc.intValue()));
        }
    }
638625
@SuppressWarnings("unchecked")
    public void finish(final Object obj) {
        finish(request.getJsonConvert(), (Type) null, obj);
    }
653885
@Override
    public void visitCode(Code obj) {
        stack.resetForMethodEntry(this);
        changedAttributes.clear();
        savedAttributes.clear();
        super.visitCode(obj);
        for (Integer pc : changedAttributes.values()) {
            bugReporter.reportBug(new BugInstance(this, BugType.SCSS_SUSPICIOUS_CLUSTERED_SESSION_SUPPORT.name(), NORMAL_PRIORITY).addClass(this)
                    .addMethod(this).addSourceLine(this, pc.intValue()));
        }
    }
587520
@Override
    public void visitMethod(Method obj) {
        stack.resetForMethodEntry(this);
        enumRegs.clear();
        super.visitMethod(obj);
    }
1056165
@Override
    public void visitCode(final Code obj) {
        try {
            if (methodSignatureIsConstrained) {
                return;
            }

            if (obj.getCode() == null) {
                return;
            }
            Method m = getMethod();

            if (m.isSynthetic()) {
                return;
            }

            if (m.getName().startsWith("access$")) {
                return;
            }

            methodIsStatic = m.isStatic();
            parmCount = m.getArgumentTypes().length;

            if (parmCount == 0) {
                return;
            }

            parameterDefiners.clear();
            usedParameters.clear();
            stack.resetForMethodEntry(this);

            if (buildParameterDefiners()) {
                try {
                    super.visitCode(obj);
                    reportBugs();
                } catch (StopOpcodeParsingException e) {
                    // no more possible parameter definers
                }
            }
        } catch (ClassNotFoundException cnfe) {
            bugReporter.reportMissingClass(cnfe);
        }
    }
661261
function(self, obj)
{
   self.stack = '';
   for(var key in obj)
   {
      self[key] = obj[key];
   }
}
1323473
@Override
    public void visitCode(Code obj) {
        if (prescreen(obj, getMethod())) {
            stack.resetForMethodEntry(this);
            catchInfos.clear();
            exceptions = collectExceptions(obj.getExceptionTable());
            exReg.clear();
            lastWasExitPoint = false;
            super.visitCode(obj);
        }
    }
828688
@Override
    public void visitCode(Code obj) {
        unusedParms.clear();
        regToParm.clear();
        stack.resetForMethodEntry(this);
        Method m = getMethod();
        String methodName = m.getName();
        if (IGNORE_METHODS.contains(methodName)) {
            return;
        }

        int accessFlags = m.getAccessFlags();
        if (((accessFlags & (Const.ACC_STATIC | Const.ACC_PRIVATE)) == 0) || ((accessFlags & Const.ACC_SYNTHETIC) != 0)) {
            return;
        }

        List<String> parmTypes = SignatureUtils.getParameterSignatures(m.getSignature());

        if (parmTypes.isEmpty()) {
            return;
        }
        int firstReg = 0;
        if ((accessFlags & Const.ACC_STATIC) == 0) {
            ++firstReg;
        }

        int reg = firstReg;
        for (int i = 0; i < parmTypes.size(); ++i) {
            unusedParms.set(reg);
            regToParm.put(Integer.valueOf(reg), Integer.valueOf(i + 1));
            String parmSig = parmTypes.get(i);
            reg += SignatureUtils.getSignatureSize(parmSig);
        }

        try {
            super.visitCode(obj);

            if (!unusedParms.isEmpty()) {
                LocalVariableTable lvt = m.getLocalVariableTable();

                reg = unusedParms.nextSetBit(firstReg);
                while (reg >= 0) {
                    LocalVariable lv = (lvt == null) ? null : lvt.getLocalVariable(reg, 0);
                    if (lv != null) {
                        String parmName = lv.getName();
                        bugReporter.reportBug(new BugInstance(this, BugType.UP_UNUSED_PARAMETER.name(), NORMAL_PRIORITY).addClass(this).addMethod(this)
                                .addString("Parameter " + regToParm.get(Integer.valueOf(reg)) + ": " + parmName));
                    }
                    reg = unusedParms.nextSetBit(reg + 1);
                }
            }
        } catch (StopOpcodeParsingException e) {
            // no unusedParms left
        }
    }
1349766
@MainThread
    public void change(T obj) {
        if (!isLockEnabled) {
            throw new RuntimeException("changing of values only cen be performed in locked state");
        }

        modifiedValue = obj;
        notifyInMainThread(modifiedValue);
    }
298936
@Override
    public void visitCode(Code obj) {
        if (prescreen(getMethod())) {
            ifBlocks.clear();
            loadedRegs.clear();
            loopLocations.clear();
            stack.resetForMethodEntry(this);
            state = State.SAW_NOTHING;
            super.visitCode(obj);
        }
    }
543091
@Override
    public void visitCode(Code obj) {
        stack.resetForMethodEntry(this);
        xmlItemCount = 0;
        xmlConfidentCount = 0;
        firstPC = -1;
        super.visitCode(obj);
        if ((xmlItemCount >= lowReportingThreshold) && (xmlConfidentCount > (lowReportingThreshold >> 1))) {
            bugReporter.reportBug(new BugInstance(this, "CBX_CUSTOM_BUILT_XML",
                    (xmlItemCount >= highReportingThreshold) ? HIGH_PRIORITY : (xmlItemCount >= midReportingThreshold) ? NORMAL_PRIORITY : LOW_PRIORITY)
                            .addClass(this).addMethod(this).addSourceLine(this, firstPC));

        }
    }
863582
@Override
    public void visitCode(final Code obj) {
        try {
            localCollections = new HashMap<>();
            localScopeEnds = new HashMap<>();
            localSourceLineAnnotations = new HashMap<>();
            stack.resetForMethodEntry(this);
            super.visitCode(obj);
        } finally {
            localCollections = null;
            localScopeEnds = null;
            localSourceLineAnnotations = null;
        }
    }
1226056
@Override
    public void visitCode(final Code obj) {
        stack.resetForMethodEntry(this);
        indexToFieldMap.clear();
        super.visitCode(obj);
    }
582635
@Override
    public void visitCode(Code obj) {
        Method method = getMethod();
        if (prescreen(method)) {
            stack.resetForMethodEntry(this);
            regPriorities.clear();
            int[] parmRegs = RegisterUtils.getParameterRegisters(method);
            for (int reg : parmRegs) {
                regPriorities.put(Integer.valueOf(reg), Values.NORMAL_BUG_PRIORITY);
            }
            if (!method.isStatic()) {
                regPriorities.put(Values.ZERO, Values.LOW_BUG_PRIORITY);
            }
            super.visitCode(obj);
        }
    }
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);
    }
1121412
@Override
    public void visitCode(Code obj) {
        Method m = getMethod();
        if (prescreen(m)) {
            if (m.isSynchronized()) {
                syncPC = 0;
            } else {
                syncPC = -1;
            }
            isStatic = m.isStatic();
            unsafeAliases.clear();
            unsafeAliases.set(0);
            branchInfo.clear();
            unsafeCallOccurred = false;
            stack.resetForMethodEntry(this);
        }
    }
752144
@Override
    public void visitCode(Code obj) {
        stack.resetForMethodEntry(this);
        localLabels.clear();
        super.visitCode(obj);
        for (SourceLineAnnotation sla : localLabels.values()) {
            BugInstance bug = new BugInstance(this, BugType.S508C_NO_SETLABELFOR.name(), NORMAL_PRIORITY).addClass(this).addMethod(this);

            if (sla != null) {
                bug.addSourceLine(sla);
            }

            bugReporter.reportBug(bug);
        }
    }