aboutsummaryrefslogtreecommitdiffstats
path: root/util/src
diff options
context:
space:
mode:
authorAndrey Turbanov <turbanoff@gmail.com>2021-12-18 15:20:43 +0300
committerAndrey Turbanov <turbanoff@gmail.com>2021-12-18 15:20:43 +0300
commit4c8c90de69b4e3cdeea0f598fea5a5358ac2c861 (patch)
tree6b1526b6d91bde9f3a1e00bace4e12cde6b6dfd4 /util/src
parent4021ffcbfe320a1b91bb2bcee7a112f7122ef82d (diff)
downloadaspectj-4c8c90de69b4e3cdeea0f598fea5a5358ac2c861.tar.gz
aspectj-4c8c90de69b4e3cdeea0f598fea5a5358ac2c861.zip
Reduce empty array allocations
Diffstat (limited to 'util/src')
-rw-r--r--util/src/main/java/org/aspectj/util/GenericSignature.java2
-rw-r--r--util/src/main/java/org/aspectj/util/GenericSignatureParser.java2
2 files changed, 2 insertions, 2 deletions
diff --git a/util/src/main/java/org/aspectj/util/GenericSignature.java b/util/src/main/java/org/aspectj/util/GenericSignature.java
index e68a78b7e..3ac878771 100644
--- a/util/src/main/java/org/aspectj/util/GenericSignature.java
+++ b/util/src/main/java/org/aspectj/util/GenericSignature.java
@@ -38,7 +38,7 @@ public class GenericSignature {
}
public static class MethodTypeSignature {
- public FormalTypeParameter[] formalTypeParameters = new FormalTypeParameter[0];
+ public FormalTypeParameter[] formalTypeParameters = FormalTypeParameter.NONE;
public TypeSignature[] parameters = new TypeSignature[0];
public TypeSignature returnType;
public FieldTypeSignature[] throwsSignatures = new FieldTypeSignature[0];
diff --git a/util/src/main/java/org/aspectj/util/GenericSignatureParser.java b/util/src/main/java/org/aspectj/util/GenericSignatureParser.java
index 3f1f3d52a..b6fbe4b4b 100644
--- a/util/src/main/java/org/aspectj/util/GenericSignatureParser.java
+++ b/util/src/main/java/org/aspectj/util/GenericSignatureParser.java
@@ -71,7 +71,7 @@ public class GenericSignatureParser {
this.inputString = sig;
tokenStream = tokenize(sig);
tokenIndex = 0;
- FormalTypeParameter[] formals = new FormalTypeParameter[0];
+ FormalTypeParameter[] formals = FormalTypeParameter.NONE;
TypeSignature returnType = null;
// FormalTypeParameters-opt
if (maybeEat("<")) {