From 572a9a00bde2c31306b3e4c28300dd626aec2f20 Mon Sep 17 00:00:00 2001 From: bdemsky Date: Mon, 27 Jun 2011 08:54:33 +0000 Subject: [PATCH] bug fixes --- Robust/src/IR/ClassDescriptor.java | 2 +- Robust/src/IR/SymbolTable.java | 6 ++---- Robust/src/IR/Tree/SemanticCheck.java | 4 ++-- 3 files changed, 5 insertions(+), 7 deletions(-) diff --git a/Robust/src/IR/ClassDescriptor.java b/Robust/src/IR/ClassDescriptor.java index e218c790..43923d0c 100644 --- a/Robust/src/IR/ClassDescriptor.java +++ b/Robust/src/IR/ClassDescriptor.java @@ -130,7 +130,7 @@ public class ClassDescriptor extends Descriptor { } public String getSafeSymbol() { - return safename.replace(".","___________"); + return safename.replace(".","___________").replace("$","___DOLLAR___"); } public String printTree(State state) { diff --git a/Robust/src/IR/SymbolTable.java b/Robust/src/IR/SymbolTable.java index cec4688e..86ebe7b2 100644 --- a/Robust/src/IR/SymbolTable.java +++ b/Robust/src/IR/SymbolTable.java @@ -45,10 +45,8 @@ public class SymbolTable { else hs=new HashSet(); if(this.parentIFs != null) { - for(int i = 0; i < this.parentIFs.size(); i++) { - if(this.parentIFs.elementAt(i).contains(name)) { - hs.addAll((HashSet)(this.parentIFs.elementAt(i).getPSet(name))); - } + for(int i = 0; i < parentIFs.size(); i++) { + hs.addAll(parentIFs.elementAt(i).getPSet(name)); } } if (table.containsKey(name)) { diff --git a/Robust/src/IR/Tree/SemanticCheck.java b/Robust/src/IR/Tree/SemanticCheck.java index 72d73703..f6f5df32 100644 --- a/Robust/src/IR/Tree/SemanticCheck.java +++ b/Robust/src/IR/Tree/SemanticCheck.java @@ -85,6 +85,7 @@ public class SemanticCheck { } if (oldstatus