Exemple #1
0
        static void Symbol(out Symbol symbol)
        {
            symbol = null;
            switch (la.kind)
            {
            case 2: {
                Get();
                symbol = new CompoundSymbol(t.val);
                break;
            }

            case 3: {
                Get();
                symbol = new Character(t.val);
                break;
            }

            case 4: {
                Get();
                symbol = new Macrodigit(Convert.ToInt32(t.val));
                break;
            }

            case 14: {
                Get();
                symbol = new TrueIdentifier(t.val);
                break;
            }

            case 15: {
                Get();
                symbol = new FalseIdentifier(t.val);
                break;
            }

            case 1: {
                Get();
                symbol = new Identifier(t.val);
                break;
            }

            default: SynErr(42); break;
            }
        }
Exemple #2
0
 public abstract void VisitMacrodigit(Macrodigit macrodigit);
Exemple #3
0
 public override void VisitMacrodigit(Macrodigit macrodigit)
 {
     sb.AppendFormat("{0}", macrodigit.Value);
 }
Exemple #4
0
 public override void VisitMacrodigit(Macrodigit macrodigit)
 {
     throw new NotImplementedException();
 }