From afaec781e40c64490a0418730d38f3b5492b52eb Mon Sep 17 00:00:00 2001 From: jjenista Date: Thu, 18 Sep 2008 19:57:18 +0000 Subject: [PATCH] added a test for immutable --- Robust/src/IR/TypeDescriptor.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Robust/src/IR/TypeDescriptor.java b/Robust/src/IR/TypeDescriptor.java index 9c83be1a..579b4dd5 100644 --- a/Robust/src/IR/TypeDescriptor.java +++ b/Robust/src/IR/TypeDescriptor.java @@ -221,6 +221,10 @@ public class TypeDescriptor extends Descriptor { return type==TAG; } + public boolean isImmutable() { + return isPrimitive() || isString(); + } + public TypeDescriptor(NameDescriptor name) { super(name.toString()); this.type=CLASS; -- 2.34.1