Ejemplo n.º 1
0
    public virtual Constant AddConstant(InputElement id, MessageWriter msg)
    {
        Constant t = new Constant(id, members);

        t.Add(id, msg);
        return(t);
    }
Ejemplo n.º 2
0
    public Constant AddConstant(InputElement id, MessageWriter msg)
    {
        Symbol s = LookupLocal(id);

        if (s != null)
        {
            msg.Error(id, "constant '{0}' already defined in this or a parent scope at {1}",
                      id.str, new Coordinate(s.id).ToString());
        }
        Constant t = new Constant(id, locals);

        t.Add(id, locals, msg);
        return(t);
    }