Esempio n. 1
0
        protected override bool Visit(ASTLambda.Argument node)
        {
            if (!Visit(node.Type))
            {
                return(false);
            }

            if (node.DefaultValue != null)
            {
                if (!Visit(node.DefaultValue))
                {
                    return(false);
                }
                if (!Expect(node.Position, node.Type.TypeInfo, node.DefaultValue.TypeInfo))
                {
                    return(false);
                }
            }

            node.TypeInfo = node.Type.TypeInfo;
            return(true);
        }
Esempio n. 2
0
 // We should never visit an these nodes, as they should not be nessesary after type checking
 protected override bool Visit(ASTLambda.Argument node)
 {
     throw new NotImplementedException();
 }
Esempio n. 3
0
 protected abstract bool Visit(ASTLambda.Argument node);