EnumMemberValue e = new EnumMemberValue(cp);
e.setType(type.getName());
e.setValue(((Enum<?>) val).name());
return e;
} else if (type.isAnnotation()) {
return new AnnotationMemberValue(createJavassistAnnotation((java.lang.annotation.Annotation) val, cp), cp);
} else if (type.isArray()) {
Class<?> arrayType = type.getComponentType();
int length = Array.getLength(val);
MemberValue arrayval = createEmptyMemberValue(arrayType, cp);
ArrayMemberValue ret = new ArrayMemberValue(arrayval, cp);