public void visitArray(Attribute.Array a) {
            Type elemtype = env.jctypes.elemtype(a.type);

            if (elemtype.tsym == env.symtab.classType.tsym) {   // Class[]
                // Construct a proxy for a MirroredTypesException
                ArrayList<TypeMirror> elems = new ArrayList<TypeMirror>();
                for (int i = 0; i < a.values.length; i++) {
                    Type elem = ((Attribute.Class) a.values[i]).type;
                    elems.add(env.typeMaker.getType(elem));
                }
                value = new MirroredTypesExceptionProxy(elems);

            } else {
                int len = a.values.length;
                Class<?> runtimeTypeSaved = runtimeType;
                runtimeType = runtimeType.getComponentType();
                try {
                    Object res = Array.newInstance(runtimeType, len);
                    for (int i = 0; i < len; i++) {
                        a.values[i].accept(this);
                        if (value == null || value instanceof ExceptionProxy) {
                            return;
                        }
                        try {
                            Array.set(res, i, value);
                        } catch (IllegalArgumentException e) {
                            value = null;       // indicates a type mismatch
                            return;
                        }
                    }
                    value = res;
                } finally {
                    runtimeType = runtimeTypeSaved;
                }
            }
        }