@@ -64,7 +64,7 @@ import java.util.Vector; | |||
* operate on. That means, for every class (represented by a unique fully qualified | |||
* class name) there is exactly one Verifier. | |||
* | |||
* @version $Id: VerifierFactory.java,v 1.3 2004/11/19 16:45:19 aclement Exp $ | |||
* @version $Id: VerifierFactory.java,v 1.4 2005/02/02 09:11:39 aclement Exp $ | |||
* @author <A HREF="http://www.inf.fu-berlin.de/~ehaase"/>Enver Haase</A> | |||
* @see org.aspectj.apache.bcel.verifier.Verifier | |||
*/ | |||
@@ -91,7 +91,7 @@ public class VerifierFactory{ | |||
* @return the (only) verifier responsible for the class with the given name. | |||
*/ | |||
public static Verifier getVerifier(String fully_qualified_classname){ | |||
fully_qualified_classname = fully_qualified_classname; | |||
// fully_qualified_classname = fully_qualified_classname; | |||
Verifier v = (Verifier) (hashMap.get(fully_qualified_classname)); | |||
if (v==null){ |
@@ -86,7 +86,7 @@ import org.aspectj.apache.bcel.generic.*; | |||
* If a two-slot type is stored into a local variable, the next variable | |||
* is given the type Type.UNKNOWN. | |||
* | |||
* @version $Id: ExecutionVisitor.java,v 1.4 2004/11/22 08:31:27 aclement Exp $ | |||
* @version $Id: ExecutionVisitor.java,v 1.5 2005/02/02 09:11:39 aclement Exp $ | |||
* @author <A HREF="http://www.inf.fu-berlin.de/~ehaase"/>Enver Haase</A> | |||
* @see #visitDSTORE(DSTORE o) | |||
* @see InstConstraintVisitor | |||
@@ -748,8 +748,8 @@ public class ExecutionVisitor extends EmptyVisitor implements Visitor{ | |||
public void visitINVOKESPECIAL(INVOKESPECIAL o){ | |||
if (o.getMethodName(cpg).equals(Constants.CONSTRUCTOR_NAME)){ | |||
UninitializedObjectType t = (UninitializedObjectType) stack().peek(o.getArgumentTypes(cpg).length); | |||
if (t == frame._this){ | |||
frame._this = null; | |||
if (t == Frame._this){ | |||
Frame._this = null; | |||
} | |||
stack().initializeObject(t); | |||
locals().initializeObject(t); |
@@ -79,7 +79,7 @@ import org.aspectj.apache.bcel.verifier.exc.*; | |||
* TODO: Currently, the JVM's behaviour concerning monitors (MONITORENTER, | |||
* MONITOREXIT) is not modeled in JustIce. | |||
* | |||
* @version $Id: InstConstraintVisitor.java,v 1.3 2004/11/19 16:45:19 aclement Exp $ | |||
* @version $Id: InstConstraintVisitor.java,v 1.4 2005/02/02 09:11:39 aclement Exp $ | |||
* @author <A HREF="http://www.inf.fu-berlin.de/~ehaase"/>Enver Haase</A> | |||
* @see org.aspectj.apache.bcel.verifier.exc.StructuralCodeConstraintException | |||
* @see org.aspectj.apache.bcel.verifier.exc.LinkingConstraintException | |||
@@ -2576,7 +2576,7 @@ public class InstConstraintVisitor extends EmptyVisitor implements org.aspectj.a | |||
*/ | |||
public void visitRETURN(RETURN o){ | |||
if (mg.getName().equals(Constants.CONSTRUCTOR_NAME)){// If we leave an <init> method | |||
if ((frame._this != null) && (!(mg.getClassName().equals(Type.OBJECT.getClassName()))) ) { | |||
if ((Frame._this != null) && (!(mg.getClassName().equals(Type.OBJECT.getClassName()))) ) { | |||
constraintViolated(o, "Leaving a constructor that itself did not call a constructor."); | |||
} | |||
} |
@@ -86,7 +86,7 @@ import org.aspectj.apache.bcel.verifier.exc.VerifierConstraintViolatedException; | |||
* More detailed information is to be found at the do_verify() method's | |||
* documentation. | |||
* | |||
* @version $Id: Pass3bVerifier.java,v 1.4 2004/11/22 08:31:27 aclement Exp $ | |||
* @version $Id: Pass3bVerifier.java,v 1.5 2005/02/02 09:11:39 aclement Exp $ | |||
* @author <A HREF="http://www.inf.fu-berlin.de/~ehaase"/>Enver Haase</A> | |||
* @see #do_verify() | |||
*/ | |||
@@ -332,11 +332,11 @@ public final class Pass3bVerifier extends PassVerifier{ | |||
Frame f = new Frame(mg.getMaxLocals(),mg.getMaxStack()); | |||
if ( !mg.isStatic() ){ | |||
if (mg.getName().equals(Constants.CONSTRUCTOR_NAME)){ | |||
f._this = new UninitializedObjectType(new ObjectType(jc.getClassName())); | |||
f.getLocals().set(0, f._this); | |||
Frame._this = new UninitializedObjectType(new ObjectType(jc.getClassName())); | |||
f.getLocals().set(0, Frame._this); | |||
} | |||
else{ | |||
f._this = null; | |||
Frame._this = null; | |||
f.getLocals().set(0, new ObjectType(jc.getClassName())); | |||
} | |||
} |