While.Parsing.Parser.Program C# (CSharp) Метод

Program() публичный Метод

public Program ( ) : void
Результат void
        void Program()
        {
            StatementSequence statements = null;
            ProcedureSequence procs = new ProcedureSequence();
            Token startTok = null, endTok = null;
            if (IsProcProgram()) {
            Expect(3);
            startTok = t;
            Proc(procs);
            while (la.kind == 5) {
                Proc(procs);
            }
            StmtSeq(out statements);
            Expect(4);
            endTok = t;
            } else if (StartOf(1)) {
            StmtSeq(out statements);
            } else SynErr(50);
            WhileProgram.Instance = new WhileProgram(procs, statements);
            if (startTok != null && endTok != null) {
            WhileProgram.Instance.AddSequencePoint(startTok);
            WhileProgram.Instance.AddSequencePoint(endTok);
            }
        }