boolean doneAndDusted = false;
for (Iterator<NameValuePair> iterator = vals.iterator(); iterator.hasNext();) {
NameValuePair object = iterator.next();
Object o = object.getValue();
if (o instanceof EnumElementValue) {
EnumElementValue v = (EnumElementValue) object.getValue();
String s = v.getEnumTypeString();
ResolvedType rt = toType.getWorld().resolve(UnresolvedType.forSignature(s));
if (rt.equals(toType)) {
il.append(fact.createGetStatic(rt.getName(), v.getEnumValueString(), Type.getType(rt.getSignature())));
doneAndDusted = true;
}
} else if (o instanceof SimpleElementValue) {
// FIXASC types other than String will go bang bang at runtime
SimpleElementValue v = (SimpleElementValue) object.getValue();
il.append(fact.createConstant(v.getValueString()));
doneAndDusted = true;
// String s = v.getEnumTypeString();
// ResolvedType rt = toType.getWorld().resolve(UnresolvedType.forSignature(s));
// if (rt.equals(toType)) {
// il.append(fact.createGetStatic(rt.getName(), v.getEnumValueString(), Type.getType(rt.getSignature())));