IDEA-197665 Decompiler decompiles references to static fields inside class incorrectly
This commit is contained in:
@@ -1,14 +1,11 @@
|
||||
// Copyright 2000-2017 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
|
||||
// Copyright 2000-2018 JetBrains s.r.o. Use of this source code is governed by the Apache 2.0 license that can be found in the LICENSE file.
|
||||
package org.jetbrains.java.decompiler.struct.attr;
|
||||
|
||||
import org.jetbrains.java.decompiler.struct.consts.ConstantPool;
|
||||
import org.jetbrains.java.decompiler.util.DataInputFullStream;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.*;
|
||||
import java.util.stream.Collectors;
|
||||
import java.util.stream.Stream;
|
||||
|
||||
@@ -67,7 +64,7 @@ public class StructLocalVariableTableAttribute extends StructGeneralAttribute {
|
||||
}
|
||||
|
||||
public boolean containsName(String name) {
|
||||
return localVariables.stream().anyMatch(v -> v.name == name);
|
||||
return localVariables.stream().anyMatch(v -> Objects.equals(v.name, name));
|
||||
}
|
||||
|
||||
public Map<Integer, String> getMapParamNames() {
|
||||
|
||||
Binary file not shown.
@@ -3,8 +3,8 @@ package pkg;
|
||||
public class TestStaticNameClash {
|
||||
public static String property;
|
||||
|
||||
public static void setProperty(String var0) {
|
||||
property = var0;// 8
|
||||
public static void setProperty(String property) {
|
||||
TestStaticNameClash.property = property;// 8
|
||||
}// 9
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user