public InnerViewBuilder(string sourceCode)
 {
     mLexer           = new Lexer(sourceCode);
     ExpectToDefVars  = new List <string>();
     ExpectToDefFuncs = new List <string>();
     mInnerView       = new InnerView();
     Instructions     = new List <Instruction>();
 }
예제 #2
0
 public Executer(String sourceCode)
 {
     //создание внуреннего представления
     mInnerView = new InnerViewBuilder(sourceCode).Build();
     if (!mInnerView.Functions.ContainsKey("main"))
     {
         throw new Exception("main is missing.");
     }
     mStackTrace    = new Stack <StackTraceItem>();
     mCurrentInstNo = 0;
     mCurrentFunc   = "main";
     mCurrentInst   = mInnerView.Functions[mCurrentFunc][mCurrentInstNo];
     mOutputMessage = new OutputMessage();
 }