public InnerViewBuilder(string sourceCode) { mLexer = new Lexer(sourceCode); ExpectToDefVars = new List <string>(); ExpectToDefFuncs = new List <string>(); mInnerView = new InnerView(); Instructions = new List <Instruction>(); }
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(); }