From: aclement Date: Fri, 6 Jun 2008 04:24:20 +0000 (+0000) Subject: 231396: refactoring AspectJ: useless count field removed and new constants added X-Git-Tag: V1_6_1rc1~114 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=3948b598c5735c718cb81bc025bcb285df6f7d0f;p=aspectj.git 231396: refactoring AspectJ: useless count field removed and new constants added --- diff --git a/bcel-builder/src/org/aspectj/apache/bcel/classfile/FieldOrMethod.java b/bcel-builder/src/org/aspectj/apache/bcel/classfile/FieldOrMethod.java index 48b9fc2d5..37b9afd6f 100644 --- a/bcel-builder/src/org/aspectj/apache/bcel/classfile/FieldOrMethod.java +++ b/bcel-builder/src/org/aspectj/apache/bcel/classfile/FieldOrMethod.java @@ -64,14 +64,13 @@ import java.util.List; /** * Abstract super class for fields and methods. * - * @version $Id: FieldOrMethod.java,v 1.6 2008/05/28 23:53:01 aclement Exp $ + * @version $Id: FieldOrMethod.java,v 1.7 2008/06/06 04:24:20 aclement Exp $ * @author M. Dahm */ public abstract class FieldOrMethod extends Modifiers implements Cloneable, Node { protected int nameIndex; protected int signatureIndex; protected Attribute[] attributes; - protected int attributes_count;// No. of attributes protected ConstantPool cpool; private String name; // lazily initialized @@ -111,7 +110,6 @@ public abstract class FieldOrMethod extends Modifiers implements Cloneable, Node */ public void setAttributes(Attribute[] attributes) { this.attributes = attributes; - attributes_count = (attributes == null)? 0 : attributes.length; } diff --git a/bcel-builder/src/org/aspectj/apache/bcel/generic/Type.java b/bcel-builder/src/org/aspectj/apache/bcel/generic/Type.java index efb930059..8014a9ab3 100644 --- a/bcel-builder/src/org/aspectj/apache/bcel/generic/Type.java +++ b/bcel-builder/src/org/aspectj/apache/bcel/generic/Type.java @@ -65,7 +65,7 @@ import org.aspectj.apache.bcel.classfile.Utility; * Abstract super class for all possible java types, namely basic types * such as int, object types like String and array types, e.g. int[] * - * @version $Id: Type.java,v 1.8 2008/05/28 23:52:56 aclement Exp $ + * @version $Id: Type.java,v 1.9 2008/06/06 04:24:20 aclement Exp $ * @author M. Dahm * * modified: @@ -92,7 +92,12 @@ public abstract class Type implements java.io.Serializable { public static final Type[] NO_ARGS = new Type[0]; public static final ReferenceType NULL = new ReferenceType(){}; public static final Type UNKNOWN = new Type(Constants.T_UNKNOWN,""){}; - + public static final Type[] STRINGARRAY1 = new Type[]{STRING}; + public static final Type[] STRINGARRAY2 = new Type[]{STRING,STRING}; + public static final Type[] STRINGARRAY3 = new Type[]{STRING,STRING,STRING}; + public static final Type[] STRINGARRAY4 = new Type[]{STRING,STRING,STRING,STRING}; + public static final Type[] STRINGARRAY5 = new Type[]{STRING,STRING,STRING,STRING,STRING}; + protected Type(byte t, String s) { type = t; signature = s;