Rename LambdaTransformert to AnonymousObjectTransformer

This commit is contained in:
Mikhael Bogdanov
2014-04-25 12:38:45 +04:00
parent 30e921fa89
commit b025d0b76c
2 changed files with 8 additions and 3 deletions
@@ -34,7 +34,7 @@ import org.jetbrains.org.objectweb.asm.tree.*;
import java.io.IOException;
import java.util.*;
public class LambdaTransformer {
public class AnonymousObjectTransformer {
protected final GenerationState state;
@@ -54,7 +54,12 @@ public class LambdaTransformer {
private final Map<String, List<String>> fieldNames = new HashMap<String, List<String>>();
public LambdaTransformer(@NotNull String objectInternalName, @NotNull InliningContext inliningContext, boolean isSameModule, @NotNull Type newLambdaType) {
public AnonymousObjectTransformer(
@NotNull String objectInternalName,
@NotNull InliningContext inliningContext,
boolean isSameModule,
@NotNull Type newLambdaType
) {
this.isSameModule = isSameModule;
this.state = inliningContext.state;
this.typeMapper = state.getTypeMapper();
@@ -141,7 +141,7 @@ public class MethodInliner {
//TODO: need poping of type but what to do with local funs???
Type newLambdaType = Type.getObjectType(inliningContext.nameGenerator.genLambdaClassName());
currentTypeMapping.put(invocation.getOwnerInternalName(), newLambdaType.getInternalName());
LambdaTransformer transformer = new LambdaTransformer(invocation.getOwnerInternalName(),
AnonymousObjectTransformer transformer = new AnonymousObjectTransformer(invocation.getOwnerInternalName(),
inliningContext.subInline(inliningContext.nameGenerator, currentTypeMapping).classRegeneration(),
isSameModule, newLambdaType);