public Object visit(final ArrayLookup node) {
            // generate expression
            final Expression expr = node.getExpression();
            generate(expr);

            // generate null-safe check if necessary
            generateNullSafe(node, expr, new NullSafeCallback() {
                public Type execute() {
                    Method readMethod = node.getReadMethod();
                    Expression lookup = node.getLookupIndex();

                    Type type = expr.getType();
                    Class<?> lookupClass = type.getObjectClass();
                    boolean doArrayLookup = lookupClass.isArray();

                    if (!doArrayLookup &&
                        Modifier.isStatic(readMethod.getModifiers())) {

                        // Discard the object to call method on.
                        mBuilder.pop();
                    }

                    // generate lookup portion
                    generate(lookup);
                    setLineNumber(node.getLookupToken().getSourceInfo());

                    if (!doArrayLookup) {
                        mBuilder.invoke(readMethod);
                        // TODO: do we need to checkCast here for generics?
                        //mBuilder.checkCast(makeDesc(node.getType()));
                        return node.getType();
                    }
                    else {
                        try {
                            Type elementType =
                                expr.getInitialType().getArrayElementType();
                            mBuilder.loadFromArray(makeDesc(elementType));
                            return elementType;
                        }
                        catch (IntrospectionException e) {
                            throw new RuntimeException(e.toString());
                        }
                    }
                }
            });

            // nothing to update
            return null;
        }