diff --git a/weaver/src/org/aspectj/weaver/bcel/BcelAdvice.java b/weaver/src/org/aspectj/weaver/bcel/BcelAdvice.java index 64d6a10..7b780c7 100644 --- a/weaver/src/org/aspectj/weaver/bcel/BcelAdvice.java +++ b/weaver/src/org/aspectj/weaver/bcel/BcelAdvice.java @@ -243,12 +243,13 @@ class BcelAdvice extends Advice { containsInvokedynamic = 1; LazyMethodGen lmg = boType.getLazyClassGen().getLazyMethodGen(this.signature.getName(), this.signature.getSignature(), true); // Check Java8 supertypes + BcelObjectType bot = boType; while (lmg == null) { - ResolvedType superType = boType.getSuperclass(); + ResolvedType superType = bot.getSuperclass(); if (superType == null) break; ReferenceTypeDelegate rtd = ((ReferenceType)superType).getDelegate(); if (rtd instanceof BcelObjectType) { - BcelObjectType bot = (BcelObjectType)rtd; + bot = (BcelObjectType)rtd; if (bot.javaClass.getMajor() < Constants.MAJOR_1_8) { break; }