Ejemplo n.º 1
0
        public override AstNode Visit(DereferenceOperation node)
        {
            // Begin the node.
            builder.BeginNode(node);

            // Get the pointer expression.
            Expression pointer = node.GetPointer();
            pointer.Accept(this);

            // Perform pointer coercion.
            IChelaType pointerType = pointer.GetNodeType();
            IChelaType coercionType = node.GetCoercionType();
            if(pointerType != coercionType)
                Cast(node, pointer.GetNodeValue(), pointerType, coercionType);

            return builder.EndNode();
        }