From 758fdf5a3d6508fdd826476ac638614f9aac394e Mon Sep 17 00:00:00 2001 From: bd-912 Date: Fri, 10 May 2024 13:37:18 -0600 Subject: Fix introduced error with ClassInstance.equals double usage --- st/ClassInstance.java | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'st/ClassInstance.java') diff --git a/st/ClassInstance.java b/st/ClassInstance.java index a794f96..a7a4500 100644 --- a/st/ClassInstance.java +++ b/st/ClassInstance.java @@ -15,6 +15,12 @@ public class ClassInstance extends AbstractInstance { } @Override public boolean equals(Object other) { + ClassInstance o; + return (other instanceof ClassInstance && + ((o = (ClassInstance) other).getName() == this.getName())); + } + + public boolean equalsOnExtend(Object other) { ClassInstance o; if (other instanceof ClassInstance) o = (ClassInstance) other; -- cgit v1.2.3