Compiler-Interpreter.deploy.js 86 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541
  1. smalltalk.addPackage('Compiler-Interpreter');
  2. smalltalk.addClass('AIBlockClosure', smalltalk.BlockClosure, ['interpreter', 'node', 'context'], 'Compiler-Interpreter');
  3. smalltalk.addMethod(
  4. smalltalk.method({
  5. selector: "applyTo:arguments:",
  6. fn: function (anObject,aCollection){
  7. var self=this;
  8. return smalltalk.withContext(function($ctx1) {
  9. self._interpreterError();
  10. return self}, function($ctx1) {$ctx1.fill(self,"applyTo:arguments:",{anObject:anObject,aCollection:aCollection},smalltalk.AIBlockClosure)})},
  11. messageSends: ["interpreterError"]}),
  12. smalltalk.AIBlockClosure);
  13. smalltalk.addMethod(
  14. smalltalk.method({
  15. selector: "compiledSource",
  16. fn: function (){
  17. var self=this;
  18. return smalltalk.withContext(function($ctx1) {
  19. return "[ AST Block closure ]";
  20. }, function($ctx1) {$ctx1.fill(self,"compiledSource",{},smalltalk.AIBlockClosure)})},
  21. messageSends: []}),
  22. smalltalk.AIBlockClosure);
  23. smalltalk.addMethod(
  24. smalltalk.method({
  25. selector: "currySelf",
  26. fn: function (){
  27. var self=this;
  28. return smalltalk.withContext(function($ctx1) {
  29. self._interpreterError();
  30. return self}, function($ctx1) {$ctx1.fill(self,"currySelf",{},smalltalk.AIBlockClosure)})},
  31. messageSends: ["interpreterError"]}),
  32. smalltalk.AIBlockClosure);
  33. smalltalk.addMethod(
  34. smalltalk.method({
  35. selector: "initializeWithInterpreter:context:node:",
  36. fn: function (anInterpreter,aContext,aNode){
  37. var self=this;
  38. return smalltalk.withContext(function($ctx1) {
  39. self["@interpreter"]=anInterpreter;
  40. self["@node"]=aNode;
  41. self["@context"]=aContext;
  42. return self}, function($ctx1) {$ctx1.fill(self,"initializeWithInterpreter:context:node:",{anInterpreter:anInterpreter,aContext:aContext,aNode:aNode},smalltalk.AIBlockClosure)})},
  43. messageSends: []}),
  44. smalltalk.AIBlockClosure);
  45. smalltalk.addMethod(
  46. smalltalk.method({
  47. selector: "interpreterError",
  48. fn: function (){
  49. var self=this;
  50. function $AIInterpreterError(){return smalltalk.AIInterpreterError||(typeof AIInterpreterError=="undefined"?nil:AIInterpreterError)}
  51. return smalltalk.withContext(function($ctx1) {
  52. _st($AIInterpreterError())._signal_("Method cannot be interpreted by the interpreter.");
  53. return self}, function($ctx1) {$ctx1.fill(self,"interpreterError",{},smalltalk.AIBlockClosure)})},
  54. messageSends: ["signal:"]}),
  55. smalltalk.AIBlockClosure);
  56. smalltalk.addMethod(
  57. smalltalk.method({
  58. selector: "numArgs",
  59. fn: function (){
  60. var self=this;
  61. return smalltalk.withContext(function($ctx1) {
  62. var $1;
  63. $1=_st(_st(self["@node"])._temps())._size();
  64. return $1;
  65. }, function($ctx1) {$ctx1.fill(self,"numArgs",{},smalltalk.AIBlockClosure)})},
  66. messageSends: ["size", "temps"]}),
  67. smalltalk.AIBlockClosure);
  68. smalltalk.addMethod(
  69. smalltalk.method({
  70. selector: "value",
  71. fn: function (){
  72. var self=this;
  73. return smalltalk.withContext(function($ctx1) {
  74. var $1;
  75. $1=self._valueWithPossibleArguments_([]);
  76. return $1;
  77. }, function($ctx1) {$ctx1.fill(self,"value",{},smalltalk.AIBlockClosure)})},
  78. messageSends: ["valueWithPossibleArguments:"]}),
  79. smalltalk.AIBlockClosure);
  80. smalltalk.addMethod(
  81. smalltalk.method({
  82. selector: "value:",
  83. fn: function (anArgument){
  84. var self=this;
  85. return smalltalk.withContext(function($ctx1) {
  86. var $1;
  87. $1=self._valueWithPossibleArguments_(["anArgument"]);
  88. return $1;
  89. }, function($ctx1) {$ctx1.fill(self,"value:",{anArgument:anArgument},smalltalk.AIBlockClosure)})},
  90. messageSends: ["valueWithPossibleArguments:"]}),
  91. smalltalk.AIBlockClosure);
  92. smalltalk.addMethod(
  93. smalltalk.method({
  94. selector: "value:value:",
  95. fn: function (firstArgument,secondArgument){
  96. var self=this;
  97. return smalltalk.withContext(function($ctx1) {
  98. var $1;
  99. $1=self._valueWithPossibleArguments_(["firstArgument", "secondArgument"]);
  100. return $1;
  101. }, function($ctx1) {$ctx1.fill(self,"value:value:",{firstArgument:firstArgument,secondArgument:secondArgument},smalltalk.AIBlockClosure)})},
  102. messageSends: ["valueWithPossibleArguments:"]}),
  103. smalltalk.AIBlockClosure);
  104. smalltalk.addMethod(
  105. smalltalk.method({
  106. selector: "value:value:value:",
  107. fn: function (firstArgument,secondArgument,thirdArgument){
  108. var self=this;
  109. return smalltalk.withContext(function($ctx1) {
  110. var $1;
  111. $1=self._valueWithPossibleArguments_(["firstArgument", "secondArgument", "thirdArgument"]);
  112. return $1;
  113. }, function($ctx1) {$ctx1.fill(self,"value:value:value:",{firstArgument:firstArgument,secondArgument:secondArgument,thirdArgument:thirdArgument},smalltalk.AIBlockClosure)})},
  114. messageSends: ["valueWithPossibleArguments:"]}),
  115. smalltalk.AIBlockClosure);
  116. smalltalk.addMethod(
  117. smalltalk.method({
  118. selector: "valueWithPossibleArguments:",
  119. fn: function (aCollection){
  120. var self=this;
  121. return smalltalk.withContext(function($ctx1) {
  122. var $1,$2;
  123. _st(_st(self["@node"])._parameters())._withIndexDo_((function(each,index){
  124. return smalltalk.withContext(function($ctx2) {
  125. return _st(self["@context"])._localAt_put_(each,_st(aCollection)._at_ifAbsent_(index,(function(){
  126. return smalltalk.withContext(function($ctx3) {
  127. return nil;
  128. }, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)})})));
  129. }, function($ctx2) {$ctx2.fillBlock({each:each,index:index},$ctx1,1)})}));
  130. $1=self["@interpreter"];
  131. _st($1)._context_(self["@context"]);
  132. _st($1)._node_(_st(_st(_st(self["@node"])._nodes())._first())._nextChild());
  133. $2=_st($1)._step();
  134. return self}, function($ctx1) {$ctx1.fill(self,"valueWithPossibleArguments:",{aCollection:aCollection},smalltalk.AIBlockClosure)})},
  135. messageSends: ["withIndexDo:", "parameters", "localAt:put:", "at:ifAbsent:", "context:", "node:", "nextChild", "first", "nodes", "step"]}),
  136. smalltalk.AIBlockClosure);
  137. smalltalk.addMethod(
  138. smalltalk.method({
  139. selector: "forInterpreter:context:node:",
  140. fn: function (anInterpreter,aContext,aNode){
  141. var self=this;
  142. return smalltalk.withContext(function($ctx1) {
  143. var $2,$3,$1;
  144. $2=self._new();
  145. _st($2)._initializeWithInterpreter_context_node_(anInterpreter,aContext,aNode);
  146. $3=_st($2)._yourself();
  147. $1=$3;
  148. return $1;
  149. }, function($ctx1) {$ctx1.fill(self,"forInterpreter:context:node:",{anInterpreter:anInterpreter,aContext:aContext,aNode:aNode},smalltalk.AIBlockClosure.klass)})},
  150. messageSends: ["initializeWithInterpreter:context:node:", "new", "yourself"]}),
  151. smalltalk.AIBlockClosure.klass);
  152. smalltalk.addClass('AIContext', smalltalk.Object, ['outerContext', 'innerContext', 'pc', 'locals', 'method', 'index', 'ast', 'interpreter', 'methodContext'], 'Compiler-Interpreter');
  153. smalltalk.addMethod(
  154. smalltalk.method({
  155. selector: "arguments",
  156. fn: function (){
  157. var self=this;
  158. return smalltalk.withContext(function($ctx1) {
  159. var $1;
  160. $1=_st(_st(self._ast())._arguments())._collect_((function(each){
  161. return smalltalk.withContext(function($ctx2) {
  162. return self._localAt_(each);
  163. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)})}));
  164. return $1;
  165. }, function($ctx1) {$ctx1.fill(self,"arguments",{},smalltalk.AIContext)})},
  166. messageSends: ["collect:", "arguments", "ast", "localAt:"]}),
  167. smalltalk.AIContext);
  168. smalltalk.addMethod(
  169. smalltalk.method({
  170. selector: "asString",
  171. fn: function (){
  172. var self=this;
  173. return smalltalk.withContext(function($ctx1) {
  174. var $1;
  175. $1=_st(self["@methodContext"])._asString();
  176. return $1;
  177. }, function($ctx1) {$ctx1.fill(self,"asString",{},smalltalk.AIContext)})},
  178. messageSends: ["asString"]}),
  179. smalltalk.AIContext);
  180. smalltalk.addMethod(
  181. smalltalk.method({
  182. selector: "ast",
  183. fn: function (){
  184. var self=this;
  185. return smalltalk.withContext(function($ctx1) {
  186. var $1,$2,$3,$4;
  187. $1=self._isBlockContext();
  188. if(smalltalk.assert($1)){
  189. $2=_st(self._outerContext())._ast();
  190. return $2;
  191. };
  192. $3=self["@ast"];
  193. if(($receiver = $3) == nil || $receiver == undefined){
  194. self._initializeAST();
  195. } else {
  196. $3;
  197. };
  198. $4=self["@ast"];
  199. return $4;
  200. }, function($ctx1) {$ctx1.fill(self,"ast",{},smalltalk.AIContext)})},
  201. messageSends: ["ifTrue:", "isBlockContext", "ast", "outerContext", "ifNil:", "initializeAST"]}),
  202. smalltalk.AIContext);
  203. smalltalk.addMethod(
  204. smalltalk.method({
  205. selector: "index",
  206. fn: function (){
  207. var self=this;
  208. return smalltalk.withContext(function($ctx1) {
  209. var $2,$1;
  210. $2=self["@index"];
  211. if(($receiver = $2) == nil || $receiver == undefined){
  212. $1=(0);
  213. } else {
  214. $1=$2;
  215. };
  216. return $1;
  217. }, function($ctx1) {$ctx1.fill(self,"index",{},smalltalk.AIContext)})},
  218. messageSends: ["ifNil:"]}),
  219. smalltalk.AIContext);
  220. smalltalk.addMethod(
  221. smalltalk.method({
  222. selector: "index:",
  223. fn: function (anInteger){
  224. var self=this;
  225. return smalltalk.withContext(function($ctx1) {
  226. self["@index"]=anInteger;
  227. return self}, function($ctx1) {$ctx1.fill(self,"index:",{anInteger:anInteger},smalltalk.AIContext)})},
  228. messageSends: []}),
  229. smalltalk.AIContext);
  230. smalltalk.addMethod(
  231. smalltalk.method({
  232. selector: "initializeAST",
  233. fn: function (){
  234. var self=this;
  235. function $SemanticAnalyzer(){return smalltalk.SemanticAnalyzer||(typeof SemanticAnalyzer=="undefined"?nil:SemanticAnalyzer)}
  236. return smalltalk.withContext(function($ctx1) {
  237. self["@ast"]=_st(self._method())._ast();
  238. _st(_st($SemanticAnalyzer())._on_(_st(self._method())._methodClass()))._visit_(self["@ast"]);
  239. return self}, function($ctx1) {$ctx1.fill(self,"initializeAST",{},smalltalk.AIContext)})},
  240. messageSends: ["ast", "method", "visit:", "on:", "methodClass"]}),
  241. smalltalk.AIContext);
  242. smalltalk.addMethod(
  243. smalltalk.method({
  244. selector: "initializeFromMethodContext:",
  245. fn: function (aMethodContext){
  246. var self=this;
  247. return smalltalk.withContext(function($ctx1) {
  248. var $1,$2,$3,$4;
  249. self["@methodContext"]=aMethodContext;
  250. $1=self;
  251. _st($1)._pc_(_st(aMethodContext)._pc());
  252. _st($1)._index_(_st(aMethodContext)._index());
  253. _st($1)._receiver_(_st(aMethodContext)._receiver());
  254. $2=_st($1)._method_(_st(aMethodContext)._method());
  255. $3=_st(aMethodContext)._outerContext();
  256. if(($receiver = $3) == nil || $receiver == undefined){
  257. $3;
  258. } else {
  259. var outer;
  260. outer=$receiver;
  261. $4=_st(outer)._methodContext();
  262. if(($receiver = $4) == nil || $receiver == undefined){
  263. $4;
  264. } else {
  265. self._outerContext_(_st(self._class())._fromMethodContext_(_st(aMethodContext)._outerContext()));
  266. };
  267. _st(_st(aMethodContext)._locals())._keysAndValuesDo_((function(key,value){
  268. return smalltalk.withContext(function($ctx2) {
  269. return _st(self._locals())._at_put_(key,value);
  270. }, function($ctx2) {$ctx2.fillBlock({key:key,value:value},$ctx1,3)})}));
  271. };
  272. return self}, function($ctx1) {$ctx1.fill(self,"initializeFromMethodContext:",{aMethodContext:aMethodContext},smalltalk.AIContext)})},
  273. messageSends: ["pc:", "pc", "index:", "index", "receiver:", "receiver", "method:", "method", "ifNotNil:", "outerContext", "methodContext", "outerContext:", "fromMethodContext:", "class", "keysAndValuesDo:", "locals", "at:put:"]}),
  274. smalltalk.AIContext);
  275. smalltalk.addMethod(
  276. smalltalk.method({
  277. selector: "initializeInterpreter",
  278. fn: function (){
  279. var self=this;
  280. function $Interpreter(){return smalltalk.Interpreter||(typeof Interpreter=="undefined"?nil:Interpreter)}
  281. return smalltalk.withContext(function($ctx1) {
  282. var $1,$2,$3;
  283. $1=_st($Interpreter())._new();
  284. _st($1)._context_(self);
  285. _st($1)._node_(self._retrieveNode());
  286. $2=_st($1)._yourself();
  287. self["@interpreter"]=$2;
  288. $3=_st(_st(self._innerContext())._notNil())._and_((function(){
  289. return smalltalk.withContext(function($ctx2) {
  290. return _st(_st(self._innerContext())._isBlockContext())._not();
  291. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)})}));
  292. if(smalltalk.assert($3)){
  293. self._setupInterpreter_(self["@interpreter"]);
  294. };
  295. return self}, function($ctx1) {$ctx1.fill(self,"initializeInterpreter",{},smalltalk.AIContext)})},
  296. messageSends: ["context:", "new", "node:", "retrieveNode", "yourself", "ifTrue:", "and:", "notNil", "innerContext", "not", "isBlockContext", "setupInterpreter:"]}),
  297. smalltalk.AIContext);
  298. smalltalk.addMethod(
  299. smalltalk.method({
  300. selector: "initializeLocals",
  301. fn: function (){
  302. var self=this;
  303. function $Dictionary(){return smalltalk.Dictionary||(typeof Dictionary=="undefined"?nil:Dictionary)}
  304. return smalltalk.withContext(function($ctx1) {
  305. self["@locals"]=_st($Dictionary())._new();
  306. _st(self["@locals"])._at_put_("thisContext",self);
  307. return self}, function($ctx1) {$ctx1.fill(self,"initializeLocals",{},smalltalk.AIContext)})},
  308. messageSends: ["new", "at:put:"]}),
  309. smalltalk.AIContext);
  310. smalltalk.addMethod(
  311. smalltalk.method({
  312. selector: "innerContext",
  313. fn: function (){
  314. var self=this;
  315. return smalltalk.withContext(function($ctx1) {
  316. var $1;
  317. $1=self["@innerContext"];
  318. return $1;
  319. }, function($ctx1) {$ctx1.fill(self,"innerContext",{},smalltalk.AIContext)})},
  320. messageSends: []}),
  321. smalltalk.AIContext);
  322. smalltalk.addMethod(
  323. smalltalk.method({
  324. selector: "innerContext:",
  325. fn: function (anAIContext){
  326. var self=this;
  327. return smalltalk.withContext(function($ctx1) {
  328. self["@innerContext"]=anAIContext;
  329. return self}, function($ctx1) {$ctx1.fill(self,"innerContext:",{anAIContext:anAIContext},smalltalk.AIContext)})},
  330. messageSends: []}),
  331. smalltalk.AIContext);
  332. smalltalk.addMethod(
  333. smalltalk.method({
  334. selector: "interpreter",
  335. fn: function (){
  336. var self=this;
  337. return smalltalk.withContext(function($ctx1) {
  338. var $1,$2;
  339. $1=self["@interpreter"];
  340. if(($receiver = $1) == nil || $receiver == undefined){
  341. self._initializeInterpreter();
  342. } else {
  343. $1;
  344. };
  345. $2=self["@interpreter"];
  346. return $2;
  347. }, function($ctx1) {$ctx1.fill(self,"interpreter",{},smalltalk.AIContext)})},
  348. messageSends: ["ifNil:", "initializeInterpreter"]}),
  349. smalltalk.AIContext);
  350. smalltalk.addMethod(
  351. smalltalk.method({
  352. selector: "isBlockContext",
  353. fn: function (){
  354. var self=this;
  355. return smalltalk.withContext(function($ctx1) {
  356. var $1;
  357. $1=_st(self["@methodContext"])._isBlockContext();
  358. return $1;
  359. }, function($ctx1) {$ctx1.fill(self,"isBlockContext",{},smalltalk.AIContext)})},
  360. messageSends: ["isBlockContext"]}),
  361. smalltalk.AIContext);
  362. smalltalk.addMethod(
  363. smalltalk.method({
  364. selector: "localAt:",
  365. fn: function (aString){
  366. var self=this;
  367. return smalltalk.withContext(function($ctx1) {
  368. var $1;
  369. $1=_st(self._locals())._at_ifAbsent_(aString,(function(){
  370. return smalltalk.withContext(function($ctx2) {
  371. return nil;
  372. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)})}));
  373. return $1;
  374. }, function($ctx1) {$ctx1.fill(self,"localAt:",{aString:aString},smalltalk.AIContext)})},
  375. messageSends: ["at:ifAbsent:", "locals"]}),
  376. smalltalk.AIContext);
  377. smalltalk.addMethod(
  378. smalltalk.method({
  379. selector: "localAt:put:",
  380. fn: function (aString,anObject){
  381. var self=this;
  382. return smalltalk.withContext(function($ctx1) {
  383. _st(self._locals())._at_put_(aString,anObject);
  384. return self}, function($ctx1) {$ctx1.fill(self,"localAt:put:",{aString:aString,anObject:anObject},smalltalk.AIContext)})},
  385. messageSends: ["at:put:", "locals"]}),
  386. smalltalk.AIContext);
  387. smalltalk.addMethod(
  388. smalltalk.method({
  389. selector: "locals",
  390. fn: function (){
  391. var self=this;
  392. return smalltalk.withContext(function($ctx1) {
  393. var $1,$2;
  394. $1=self["@locals"];
  395. if(($receiver = $1) == nil || $receiver == undefined){
  396. self._initializeLocals();
  397. } else {
  398. $1;
  399. };
  400. $2=self["@locals"];
  401. return $2;
  402. }, function($ctx1) {$ctx1.fill(self,"locals",{},smalltalk.AIContext)})},
  403. messageSends: ["ifNil:", "initializeLocals"]}),
  404. smalltalk.AIContext);
  405. smalltalk.addMethod(
  406. smalltalk.method({
  407. selector: "method",
  408. fn: function (){
  409. var self=this;
  410. return smalltalk.withContext(function($ctx1) {
  411. var $1;
  412. $1=self["@method"];
  413. return $1;
  414. }, function($ctx1) {$ctx1.fill(self,"method",{},smalltalk.AIContext)})},
  415. messageSends: []}),
  416. smalltalk.AIContext);
  417. smalltalk.addMethod(
  418. smalltalk.method({
  419. selector: "method:",
  420. fn: function (aCompiledMethod){
  421. var self=this;
  422. return smalltalk.withContext(function($ctx1) {
  423. self["@method"]=aCompiledMethod;
  424. return self}, function($ctx1) {$ctx1.fill(self,"method:",{aCompiledMethod:aCompiledMethod},smalltalk.AIContext)})},
  425. messageSends: []}),
  426. smalltalk.AIContext);
  427. smalltalk.addMethod(
  428. smalltalk.method({
  429. selector: "outerContext",
  430. fn: function (){
  431. var self=this;
  432. return smalltalk.withContext(function($ctx1) {
  433. var $1;
  434. $1=self["@outerContext"];
  435. return $1;
  436. }, function($ctx1) {$ctx1.fill(self,"outerContext",{},smalltalk.AIContext)})},
  437. messageSends: []}),
  438. smalltalk.AIContext);
  439. smalltalk.addMethod(
  440. smalltalk.method({
  441. selector: "outerContext:",
  442. fn: function (anAIContext){
  443. var self=this;
  444. return smalltalk.withContext(function($ctx1) {
  445. self["@outerContext"]=anAIContext;
  446. _st(self["@outerContext"])._innerContext_(self);
  447. return self}, function($ctx1) {$ctx1.fill(self,"outerContext:",{anAIContext:anAIContext},smalltalk.AIContext)})},
  448. messageSends: ["innerContext:"]}),
  449. smalltalk.AIContext);
  450. smalltalk.addMethod(
  451. smalltalk.method({
  452. selector: "pc",
  453. fn: function (){
  454. var self=this;
  455. return smalltalk.withContext(function($ctx1) {
  456. var $2,$1;
  457. $2=self["@pc"];
  458. if(($receiver = $2) == nil || $receiver == undefined){
  459. self["@pc"]=(0);
  460. $1=self["@pc"];
  461. } else {
  462. $1=$2;
  463. };
  464. return $1;
  465. }, function($ctx1) {$ctx1.fill(self,"pc",{},smalltalk.AIContext)})},
  466. messageSends: ["ifNil:"]}),
  467. smalltalk.AIContext);
  468. smalltalk.addMethod(
  469. smalltalk.method({
  470. selector: "pc:",
  471. fn: function (anInteger){
  472. var self=this;
  473. return smalltalk.withContext(function($ctx1) {
  474. self["@pc"]=anInteger;
  475. return self}, function($ctx1) {$ctx1.fill(self,"pc:",{anInteger:anInteger},smalltalk.AIContext)})},
  476. messageSends: []}),
  477. smalltalk.AIContext);
  478. smalltalk.addMethod(
  479. smalltalk.method({
  480. selector: "receiver",
  481. fn: function (){
  482. var self=this;
  483. return smalltalk.withContext(function($ctx1) {
  484. var $1;
  485. $1=self._localAt_("self");
  486. return $1;
  487. }, function($ctx1) {$ctx1.fill(self,"receiver",{},smalltalk.AIContext)})},
  488. messageSends: ["localAt:"]}),
  489. smalltalk.AIContext);
  490. smalltalk.addMethod(
  491. smalltalk.method({
  492. selector: "receiver:",
  493. fn: function (anObject){
  494. var self=this;
  495. return smalltalk.withContext(function($ctx1) {
  496. self._localAt_put_("self",anObject);
  497. return self}, function($ctx1) {$ctx1.fill(self,"receiver:",{anObject:anObject},smalltalk.AIContext)})},
  498. messageSends: ["localAt:put:"]}),
  499. smalltalk.AIContext);
  500. smalltalk.addMethod(
  501. smalltalk.method({
  502. selector: "retrieveNode",
  503. fn: function (){
  504. var self=this;
  505. function $ASTPCNodeVisitor(){return smalltalk.ASTPCNodeVisitor||(typeof ASTPCNodeVisitor=="undefined"?nil:ASTPCNodeVisitor)}
  506. return smalltalk.withContext(function($ctx1) {
  507. var $2,$3,$1;
  508. $2=_st($ASTPCNodeVisitor())._new();
  509. _st($2)._context_(self);
  510. _st($2)._visit_(self._ast());
  511. $3=_st($2)._currentNode();
  512. $1=$3;
  513. return $1;
  514. }, function($ctx1) {$ctx1.fill(self,"retrieveNode",{},smalltalk.AIContext)})},
  515. messageSends: ["context:", "new", "visit:", "ast", "currentNode"]}),
  516. smalltalk.AIContext);
  517. smalltalk.addMethod(
  518. smalltalk.method({
  519. selector: "selector",
  520. fn: function (){
  521. var self=this;
  522. return smalltalk.withContext(function($ctx1) {
  523. var $2,$1;
  524. $2=self._method();
  525. if(($receiver = $2) == nil || $receiver == undefined){
  526. $1=$2;
  527. } else {
  528. $1=_st(self._method())._selector();
  529. };
  530. return $1;
  531. }, function($ctx1) {$ctx1.fill(self,"selector",{},smalltalk.AIContext)})},
  532. messageSends: ["ifNotNil:", "method", "selector"]}),
  533. smalltalk.AIContext);
  534. smalltalk.addMethod(
  535. smalltalk.method({
  536. selector: "setupInterpreter:",
  537. fn: function (anInterpreter){
  538. var self=this;
  539. return smalltalk.withContext(function($ctx1) {
  540. _st(_st(_st(self._innerContext())._arguments())._reversed())._do_((function(each){
  541. return smalltalk.withContext(function($ctx2) {
  542. return _st(anInterpreter)._push_(each);
  543. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)})}));
  544. _st(anInterpreter)._push_(_st(self._innerContext())._receiver());
  545. return self}, function($ctx1) {$ctx1.fill(self,"setupInterpreter:",{anInterpreter:anInterpreter},smalltalk.AIContext)})},
  546. messageSends: ["do:", "reversed", "arguments", "innerContext", "push:", "receiver"]}),
  547. smalltalk.AIContext);
  548. smalltalk.addMethod(
  549. smalltalk.method({
  550. selector: "fromMethodContext:",
  551. fn: function (aMethodContext){
  552. var self=this;
  553. return smalltalk.withContext(function($ctx1) {
  554. var $2,$3,$1;
  555. $2=self._new();
  556. _st($2)._initializeFromMethodContext_(aMethodContext);
  557. $3=_st($2)._yourself();
  558. $1=$3;
  559. return $1;
  560. }, function($ctx1) {$ctx1.fill(self,"fromMethodContext:",{aMethodContext:aMethodContext},smalltalk.AIContext.klass)})},
  561. messageSends: ["initializeFromMethodContext:", "new", "yourself"]}),
  562. smalltalk.AIContext.klass);
  563. smalltalk.addClass('AIInterpreterError', smalltalk.Error, [], 'Compiler-Interpreter');
  564. smalltalk.addClass('ASTDebugger', smalltalk.Object, ['interpreter', 'context'], 'Compiler-Interpreter');
  565. smalltalk.addMethod(
  566. smalltalk.method({
  567. selector: "atEnd",
  568. fn: function (){
  569. var self=this;
  570. return smalltalk.withContext(function($ctx1) {
  571. var $1;
  572. $1=_st(self._interpreter())._atEnd();
  573. return $1;
  574. }, function($ctx1) {$ctx1.fill(self,"atEnd",{},smalltalk.ASTDebugger)})},
  575. messageSends: ["atEnd", "interpreter"]}),
  576. smalltalk.ASTDebugger);
  577. smalltalk.addMethod(
  578. smalltalk.method({
  579. selector: "buildAST",
  580. fn: function (){
  581. var self=this;
  582. var ast;
  583. function $Smalltalk(){return smalltalk.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
  584. function $SemanticAnalyzer(){return smalltalk.SemanticAnalyzer||(typeof SemanticAnalyzer=="undefined"?nil:SemanticAnalyzer)}
  585. return smalltalk.withContext(function($ctx1) {
  586. var $1;
  587. ast=_st(_st($Smalltalk())._current())._parse_(_st(self._method())._source());
  588. _st(_st($SemanticAnalyzer())._on_(_st(_st(self._context())._receiver())._class()))._visit_(ast);
  589. $1=ast;
  590. return $1;
  591. }, function($ctx1) {$ctx1.fill(self,"buildAST",{ast:ast},smalltalk.ASTDebugger)})},
  592. messageSends: ["parse:", "current", "source", "method", "visit:", "on:", "class", "receiver", "context"]}),
  593. smalltalk.ASTDebugger);
  594. smalltalk.addMethod(
  595. smalltalk.method({
  596. selector: "context",
  597. fn: function (){
  598. var self=this;
  599. return smalltalk.withContext(function($ctx1) {
  600. var $1;
  601. $1=self["@context"];
  602. return $1;
  603. }, function($ctx1) {$ctx1.fill(self,"context",{},smalltalk.ASTDebugger)})},
  604. messageSends: []}),
  605. smalltalk.ASTDebugger);
  606. smalltalk.addMethod(
  607. smalltalk.method({
  608. selector: "context:",
  609. fn: function (aContext){
  610. var self=this;
  611. return smalltalk.withContext(function($ctx1) {
  612. self["@context"]=aContext;
  613. return self}, function($ctx1) {$ctx1.fill(self,"context:",{aContext:aContext},smalltalk.ASTDebugger)})},
  614. messageSends: []}),
  615. smalltalk.ASTDebugger);
  616. smalltalk.addMethod(
  617. smalltalk.method({
  618. selector: "defaultInterpreterClass",
  619. fn: function (){
  620. var self=this;
  621. function $ASTSteppingInterpreter(){return smalltalk.ASTSteppingInterpreter||(typeof ASTSteppingInterpreter=="undefined"?nil:ASTSteppingInterpreter)}
  622. return smalltalk.withContext(function($ctx1) {
  623. var $1;
  624. $1=$ASTSteppingInterpreter();
  625. return $1;
  626. }, function($ctx1) {$ctx1.fill(self,"defaultInterpreterClass",{},smalltalk.ASTDebugger)})},
  627. messageSends: []}),
  628. smalltalk.ASTDebugger);
  629. smalltalk.addMethod(
  630. smalltalk.method({
  631. selector: "initializeInterpreter",
  632. fn: function (){
  633. var self=this;
  634. var ast,next;
  635. function $ASTPCNodeVisitor(){return smalltalk.ASTPCNodeVisitor||(typeof ASTPCNodeVisitor=="undefined"?nil:ASTPCNodeVisitor)}
  636. return smalltalk.withContext(function($ctx1) {
  637. var $1,$2;
  638. ast=self._buildAST();
  639. $1=_st($ASTPCNodeVisitor())._new();
  640. _st($1)._context_(self._context());
  641. _st($1)._visit_(ast);
  642. $2=_st($1)._currentNode();
  643. next=$2;
  644. _st(self._interpreter())._interpret_(next);
  645. return self}, function($ctx1) {$ctx1.fill(self,"initializeInterpreter",{ast:ast,next:next},smalltalk.ASTDebugger)})},
  646. messageSends: ["buildAST", "context:", "new", "context", "visit:", "currentNode", "interpret:", "interpreter"]}),
  647. smalltalk.ASTDebugger);
  648. smalltalk.addMethod(
  649. smalltalk.method({
  650. selector: "initializeWithContext:",
  651. fn: function (aContext){
  652. var self=this;
  653. return smalltalk.withContext(function($ctx1) {
  654. self._context_(aContext);
  655. self._initializeInterpreter();
  656. return self}, function($ctx1) {$ctx1.fill(self,"initializeWithContext:",{aContext:aContext},smalltalk.ASTDebugger)})},
  657. messageSends: ["context:", "initializeInterpreter"]}),
  658. smalltalk.ASTDebugger);
  659. smalltalk.addMethod(
  660. smalltalk.method({
  661. selector: "interpreter",
  662. fn: function (){
  663. var self=this;
  664. return smalltalk.withContext(function($ctx1) {
  665. var $2,$1;
  666. $2=self["@interpreter"];
  667. if(($receiver = $2) == nil || $receiver == undefined){
  668. self["@interpreter"]=_st(self._defaultInterpreterClass())._new();
  669. $1=self["@interpreter"];
  670. } else {
  671. $1=$2;
  672. };
  673. return $1;
  674. }, function($ctx1) {$ctx1.fill(self,"interpreter",{},smalltalk.ASTDebugger)})},
  675. messageSends: ["ifNil:", "new", "defaultInterpreterClass"]}),
  676. smalltalk.ASTDebugger);
  677. smalltalk.addMethod(
  678. smalltalk.method({
  679. selector: "interpreter:",
  680. fn: function (anInterpreter){
  681. var self=this;
  682. return smalltalk.withContext(function($ctx1) {
  683. self["@interpreter"]=anInterpreter;
  684. return self}, function($ctx1) {$ctx1.fill(self,"interpreter:",{anInterpreter:anInterpreter},smalltalk.ASTDebugger)})},
  685. messageSends: []}),
  686. smalltalk.ASTDebugger);
  687. smalltalk.addMethod(
  688. smalltalk.method({
  689. selector: "method",
  690. fn: function (){
  691. var self=this;
  692. return smalltalk.withContext(function($ctx1) {
  693. var $1;
  694. $1=_st(self._context())._method();
  695. return $1;
  696. }, function($ctx1) {$ctx1.fill(self,"method",{},smalltalk.ASTDebugger)})},
  697. messageSends: ["method", "context"]}),
  698. smalltalk.ASTDebugger);
  699. smalltalk.addMethod(
  700. smalltalk.method({
  701. selector: "nextNode",
  702. fn: function (){
  703. var self=this;
  704. return smalltalk.withContext(function($ctx1) {
  705. var $1;
  706. $1=_st(self._interpreter())._nextNode();
  707. return $1;
  708. }, function($ctx1) {$ctx1.fill(self,"nextNode",{},smalltalk.ASTDebugger)})},
  709. messageSends: ["nextNode", "interpreter"]}),
  710. smalltalk.ASTDebugger);
  711. smalltalk.addMethod(
  712. smalltalk.method({
  713. selector: "proceed",
  714. fn: function (){
  715. var self=this;
  716. return smalltalk.withContext(function($ctx1) {
  717. self._shouldBeImplemented();
  718. return self}, function($ctx1) {$ctx1.fill(self,"proceed",{},smalltalk.ASTDebugger)})},
  719. messageSends: ["shouldBeImplemented"]}),
  720. smalltalk.ASTDebugger);
  721. smalltalk.addMethod(
  722. smalltalk.method({
  723. selector: "restart",
  724. fn: function (){
  725. var self=this;
  726. return smalltalk.withContext(function($ctx1) {
  727. self._shouldBeImplemented();
  728. return self}, function($ctx1) {$ctx1.fill(self,"restart",{},smalltalk.ASTDebugger)})},
  729. messageSends: ["shouldBeImplemented"]}),
  730. smalltalk.ASTDebugger);
  731. smalltalk.addMethod(
  732. smalltalk.method({
  733. selector: "step",
  734. fn: function (){
  735. var self=this;
  736. return smalltalk.withContext(function($ctx1) {
  737. _st((function(){
  738. return smalltalk.withContext(function($ctx2) {
  739. return _st(_st(_st(_st(self._interpreter())._nextNode())._notNil())._and_((function(){
  740. return smalltalk.withContext(function($ctx3) {
  741. return _st(_st(self._interpreter())._nextNode())._stopOnStepping();
  742. }, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)})})))._or_((function(){
  743. return smalltalk.withContext(function($ctx3) {
  744. return _st(_st(self._interpreter())._atEnd())._not();
  745. }, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)})}));
  746. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)})}))._whileFalse_((function(){
  747. return smalltalk.withContext(function($ctx2) {
  748. _st(self._interpreter())._step();
  749. return self._step();
  750. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,4)})}));
  751. return self}, function($ctx1) {$ctx1.fill(self,"step",{},smalltalk.ASTDebugger)})},
  752. messageSends: ["whileFalse:", "or:", "and:", "notNil", "nextNode", "interpreter", "stopOnStepping", "not", "atEnd", "step"]}),
  753. smalltalk.ASTDebugger);
  754. smalltalk.addMethod(
  755. smalltalk.method({
  756. selector: "stepInto",
  757. fn: function (){
  758. var self=this;
  759. return smalltalk.withContext(function($ctx1) {
  760. self._shouldBeImplemented();
  761. return self}, function($ctx1) {$ctx1.fill(self,"stepInto",{},smalltalk.ASTDebugger)})},
  762. messageSends: ["shouldBeImplemented"]}),
  763. smalltalk.ASTDebugger);
  764. smalltalk.addMethod(
  765. smalltalk.method({
  766. selector: "stepOver",
  767. fn: function (){
  768. var self=this;
  769. return smalltalk.withContext(function($ctx1) {
  770. self._step();
  771. return self}, function($ctx1) {$ctx1.fill(self,"stepOver",{},smalltalk.ASTDebugger)})},
  772. messageSends: ["step"]}),
  773. smalltalk.ASTDebugger);
  774. smalltalk.addMethod(
  775. smalltalk.method({
  776. selector: "context:",
  777. fn: function (aContext){
  778. var self=this;
  779. return smalltalk.withContext(function($ctx1) {
  780. var $2,$3,$1;
  781. $2=self._new();
  782. _st($2)._initializeWithContext_(aContext);
  783. $3=_st($2)._yourself();
  784. $1=$3;
  785. return $1;
  786. }, function($ctx1) {$ctx1.fill(self,"context:",{aContext:aContext},smalltalk.ASTDebugger.klass)})},
  787. messageSends: ["initializeWithContext:", "new", "yourself"]}),
  788. smalltalk.ASTDebugger.klass);
  789. smalltalk.addClass('ASTInterpreter', smalltalk.Object, ['currentNode', 'nextNode', 'context', 'shouldReturn', 'result'], 'Compiler-Interpreter');
  790. smalltalk.addMethod(
  791. smalltalk.method({
  792. selector: "assign:to:",
  793. fn: function (aNode,anObject){
  794. var self=this;
  795. return smalltalk.withContext(function($ctx1) {
  796. var $2,$1;
  797. $2=_st(_st(aNode)._binding())._isInstanceVar();
  798. if(smalltalk.assert($2)){
  799. $1=_st(_st(self._context())._receiver())._instVarAt_put_(_st(aNode)._value(),anObject);
  800. } else {
  801. $1=_st(self._context())._localAt_put_(_st(aNode)._value(),anObject);
  802. };
  803. return $1;
  804. }, function($ctx1) {$ctx1.fill(self,"assign:to:",{aNode:aNode,anObject:anObject},smalltalk.ASTInterpreter)})},
  805. messageSends: ["ifTrue:ifFalse:", "isInstanceVar", "binding", "instVarAt:put:", "receiver", "context", "value", "localAt:put:"]}),
  806. smalltalk.ASTInterpreter);
  807. smalltalk.addMethod(
  808. smalltalk.method({
  809. selector: "context",
  810. fn: function (){
  811. var self=this;
  812. function $AIContext(){return smalltalk.AIContext||(typeof AIContext=="undefined"?nil:AIContext)}
  813. return smalltalk.withContext(function($ctx1) {
  814. var $2,$1;
  815. $2=self["@context"];
  816. if(($receiver = $2) == nil || $receiver == undefined){
  817. self["@context"]=_st($AIContext())._new();
  818. $1=self["@context"];
  819. } else {
  820. $1=$2;
  821. };
  822. return $1;
  823. }, function($ctx1) {$ctx1.fill(self,"context",{},smalltalk.ASTInterpreter)})},
  824. messageSends: ["ifNil:", "new"]}),
  825. smalltalk.ASTInterpreter);
  826. smalltalk.addMethod(
  827. smalltalk.method({
  828. selector: "context:",
  829. fn: function (anAIContext){
  830. var self=this;
  831. return smalltalk.withContext(function($ctx1) {
  832. self["@context"]=anAIContext;
  833. return self}, function($ctx1) {$ctx1.fill(self,"context:",{anAIContext:anAIContext},smalltalk.ASTInterpreter)})},
  834. messageSends: []}),
  835. smalltalk.ASTInterpreter);
  836. smalltalk.addMethod(
  837. smalltalk.method({
  838. selector: "continue:value:",
  839. fn: function (aBlock,anObject){
  840. var self=this;
  841. return smalltalk.withContext(function($ctx1) {
  842. self["@result"]=anObject;
  843. _st(aBlock)._value_(anObject);
  844. return self}, function($ctx1) {$ctx1.fill(self,"continue:value:",{aBlock:aBlock,anObject:anObject},smalltalk.ASTInterpreter)})},
  845. messageSends: ["value:"]}),
  846. smalltalk.ASTInterpreter);
  847. smalltalk.addMethod(
  848. smalltalk.method({
  849. selector: "currentNode",
  850. fn: function (){
  851. var self=this;
  852. return smalltalk.withContext(function($ctx1) {
  853. var $1;
  854. $1=self["@currentNode"];
  855. return $1;
  856. }, function($ctx1) {$ctx1.fill(self,"currentNode",{},smalltalk.ASTInterpreter)})},
  857. messageSends: []}),
  858. smalltalk.ASTInterpreter);
  859. smalltalk.addMethod(
  860. smalltalk.method({
  861. selector: "eval:",
  862. fn: function (aString){
  863. var self=this;
  864. var source,function_;
  865. function $String(){return smalltalk.String||(typeof String=="undefined"?nil:String)}
  866. function $Compiler(){return smalltalk.Compiler||(typeof Compiler=="undefined"?nil:Compiler)}
  867. return smalltalk.withContext(function($ctx1) {
  868. var $1,$2,$3;
  869. source=_st($String())._streamContents_((function(str){
  870. return smalltalk.withContext(function($ctx2) {
  871. _st(str)._nextPutAll_("(function(");
  872. _st(_st(_st(self._context())._locals())._keys())._do_separatedBy_((function(each){
  873. return smalltalk.withContext(function($ctx3) {
  874. return _st(str)._nextPutAll_(each);
  875. }, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,2)})}),(function(){
  876. return smalltalk.withContext(function($ctx3) {
  877. return _st(str)._nextPutAll_(",");
  878. }, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)})}));
  879. $1=str;
  880. _st($1)._nextPutAll_("){ return (function() {");
  881. _st($1)._nextPutAll_(aString);
  882. $2=_st($1)._nextPutAll_("})() })");
  883. return $2;
  884. }, function($ctx2) {$ctx2.fillBlock({str:str},$ctx1,1)})}));
  885. function_=_st(_st($Compiler())._new())._eval_(source);
  886. $3=_st(function_)._valueWithPossibleArguments_(_st(_st(self._context())._locals())._values());
  887. return $3;
  888. }, function($ctx1) {$ctx1.fill(self,"eval:",{aString:aString,source:source,function_:function_},smalltalk.ASTInterpreter)})},
  889. messageSends: ["streamContents:", "nextPutAll:", "do:separatedBy:", "keys", "locals", "context", "eval:", "new", "valueWithPossibleArguments:", "values"]}),
  890. smalltalk.ASTInterpreter);
  891. smalltalk.addMethod(
  892. smalltalk.method({
  893. selector: "initialize",
  894. fn: function (){
  895. var self=this;
  896. return smalltalk.withContext(function($ctx1) {
  897. smalltalk.Object.fn.prototype._initialize.apply(_st(self), []);
  898. self["@shouldReturn"]=false;
  899. return self}, function($ctx1) {$ctx1.fill(self,"initialize",{},smalltalk.ASTInterpreter)})},
  900. messageSends: ["initialize"]}),
  901. smalltalk.ASTInterpreter);
  902. smalltalk.addMethod(
  903. smalltalk.method({
  904. selector: "interpret:",
  905. fn: function (aNode){
  906. var self=this;
  907. return smalltalk.withContext(function($ctx1) {
  908. self["@shouldReturn"]=false;
  909. self._interpret_continue_(aNode,(function(value){
  910. return smalltalk.withContext(function($ctx2) {
  911. self["@result"]=value;
  912. return self["@result"];
  913. }, function($ctx2) {$ctx2.fillBlock({value:value},$ctx1,1)})}));
  914. return self}, function($ctx1) {$ctx1.fill(self,"interpret:",{aNode:aNode},smalltalk.ASTInterpreter)})},
  915. messageSends: ["interpret:continue:"]}),
  916. smalltalk.ASTInterpreter);
  917. smalltalk.addMethod(
  918. smalltalk.method({
  919. selector: "interpret:continue:",
  920. fn: function (aNode,aBlock){
  921. var self=this;
  922. return smalltalk.withContext(function($ctx1) {
  923. var $1,$2,$3;
  924. $1=self["@shouldReturn"];
  925. if(smalltalk.assert($1)){
  926. $2=self;
  927. return $2;
  928. };
  929. $3=_st(aNode)._isNode();
  930. if(smalltalk.assert($3)){
  931. self["@currentNode"]=aNode;
  932. self["@currentNode"];
  933. self._interpretNode_continue_(aNode,(function(value){
  934. return smalltalk.withContext(function($ctx2) {
  935. return self._continue_value_(aBlock,value);
  936. }, function($ctx2) {$ctx2.fillBlock({value:value},$ctx1,3)})}));
  937. } else {
  938. self._continue_value_(aBlock,aNode);
  939. };
  940. return self}, function($ctx1) {$ctx1.fill(self,"interpret:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  941. messageSends: ["ifTrue:", "ifTrue:ifFalse:", "isNode", "interpretNode:continue:", "continue:value:"]}),
  942. smalltalk.ASTInterpreter);
  943. smalltalk.addMethod(
  944. smalltalk.method({
  945. selector: "interpretAll:continue:",
  946. fn: function (aCollection,aBlock){
  947. var self=this;
  948. function $OrderedCollection(){return smalltalk.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
  949. return smalltalk.withContext(function($ctx1) {
  950. self._interpretAll_continue_result_(aCollection,aBlock,_st($OrderedCollection())._new());
  951. return self}, function($ctx1) {$ctx1.fill(self,"interpretAll:continue:",{aCollection:aCollection,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  952. messageSends: ["interpretAll:continue:result:", "new"]}),
  953. smalltalk.ASTInterpreter);
  954. smalltalk.addMethod(
  955. smalltalk.method({
  956. selector: "interpretAll:continue:result:",
  957. fn: function (nodes,aBlock,aCollection){
  958. var self=this;
  959. return smalltalk.withContext(function($ctx1) {
  960. var $1;
  961. $1=_st(nodes)._isEmpty();
  962. if(smalltalk.assert($1)){
  963. self._continue_value_(aBlock,aCollection);
  964. } else {
  965. self._interpret_continue_(_st(nodes)._first(),(function(value){
  966. return smalltalk.withContext(function($ctx2) {
  967. return self._interpretAll_continue_result_(_st(nodes)._allButFirst(),aBlock,_st(aCollection).__comma([value]));
  968. }, function($ctx2) {$ctx2.fillBlock({value:value},$ctx1,3)})}));
  969. };
  970. return self}, function($ctx1) {$ctx1.fill(self,"interpretAll:continue:result:",{nodes:nodes,aBlock:aBlock,aCollection:aCollection},smalltalk.ASTInterpreter)})},
  971. messageSends: ["ifTrue:ifFalse:", "isEmpty", "continue:value:", "interpret:continue:", "first", "interpretAll:continue:result:", "allButFirst", ","]}),
  972. smalltalk.ASTInterpreter);
  973. smalltalk.addMethod(
  974. smalltalk.method({
  975. selector: "interpretAssignmentNode:continue:",
  976. fn: function (aNode,aBlock){
  977. var self=this;
  978. return smalltalk.withContext(function($ctx1) {
  979. self._interpret_continue_(_st(aNode)._right(),(function(value){
  980. return smalltalk.withContext(function($ctx2) {
  981. return self._continue_value_(aBlock,self._assign_to_(_st(aNode)._left(),value));
  982. }, function($ctx2) {$ctx2.fillBlock({value:value},$ctx1,1)})}));
  983. return self}, function($ctx1) {$ctx1.fill(self,"interpretAssignmentNode:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  984. messageSends: ["interpret:continue:", "right", "continue:value:", "assign:to:", "left"]}),
  985. smalltalk.ASTInterpreter);
  986. smalltalk.addMethod(
  987. smalltalk.method({
  988. selector: "interpretBlockNode:continue:",
  989. fn: function (aNode,aBlock){
  990. var self=this;
  991. return smalltalk.withContext(function($ctx1) {
  992. var $1,$2;
  993. self._continue_value_(aBlock,(function(){
  994. return smalltalk.withContext(function($ctx2) {
  995. return self._withBlockContext_((function(){
  996. return smalltalk.withContext(function($ctx3) {
  997. $1=self;
  998. _st($1)._interpret_(_st(_st(aNode)._nodes())._first());
  999. $2=_st($1)._result();
  1000. return $2;
  1001. }, function($ctx3) {$ctx3.fillBlock({},$ctx2,2)})}));
  1002. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)})}));
  1003. return self}, function($ctx1) {$ctx1.fill(self,"interpretBlockNode:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  1004. messageSends: ["continue:value:", "withBlockContext:", "interpret:", "first", "nodes", "result"]}),
  1005. smalltalk.ASTInterpreter);
  1006. smalltalk.addMethod(
  1007. smalltalk.method({
  1008. selector: "interpretBlockSequenceNode:continue:",
  1009. fn: function (aNode,aBlock){
  1010. var self=this;
  1011. return smalltalk.withContext(function($ctx1) {
  1012. self._interpretSequenceNode_continue_(aNode,aBlock);
  1013. return self}, function($ctx1) {$ctx1.fill(self,"interpretBlockSequenceNode:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  1014. messageSends: ["interpretSequenceNode:continue:"]}),
  1015. smalltalk.ASTInterpreter);
  1016. smalltalk.addMethod(
  1017. smalltalk.method({
  1018. selector: "interpretCascadeNode:continue:",
  1019. fn: function (aNode,aBlock){
  1020. var self=this;
  1021. return smalltalk.withContext(function($ctx1) {
  1022. self._interpret_continue_(_st(aNode)._receiver(),(function(receiver){
  1023. return smalltalk.withContext(function($ctx2) {
  1024. _st(_st(aNode)._nodes())._do_((function(each){
  1025. return smalltalk.withContext(function($ctx3) {
  1026. return _st(each)._receiver_(receiver);
  1027. }, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,2)})}));
  1028. return self._interpretAll_continue_(_st(_st(aNode)._nodes())._allButLast(),(function(){
  1029. return smalltalk.withContext(function($ctx3) {
  1030. return self._interpret_continue_(_st(_st(aNode)._nodes())._last(),(function(val){
  1031. return smalltalk.withContext(function($ctx4) {
  1032. return self._continue_value_(aBlock,val);
  1033. }, function($ctx4) {$ctx4.fillBlock({val:val},$ctx3,4)})}));
  1034. }, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)})}));
  1035. }, function($ctx2) {$ctx2.fillBlock({receiver:receiver},$ctx1,1)})}));
  1036. return self}, function($ctx1) {$ctx1.fill(self,"interpretCascadeNode:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  1037. messageSends: ["interpret:continue:", "receiver", "do:", "nodes", "receiver:", "interpretAll:continue:", "allButLast", "last", "continue:value:"]}),
  1038. smalltalk.ASTInterpreter);
  1039. smalltalk.addMethod(
  1040. smalltalk.method({
  1041. selector: "interpretClassReferenceNode:continue:",
  1042. fn: function (aNode,aBlock){
  1043. var self=this;
  1044. function $Smalltalk(){return smalltalk.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
  1045. return smalltalk.withContext(function($ctx1) {
  1046. self._continue_value_(aBlock,_st(_st($Smalltalk())._current())._at_(_st(aNode)._value()));
  1047. return self}, function($ctx1) {$ctx1.fill(self,"interpretClassReferenceNode:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  1048. messageSends: ["continue:value:", "at:", "current", "value"]}),
  1049. smalltalk.ASTInterpreter);
  1050. smalltalk.addMethod(
  1051. smalltalk.method({
  1052. selector: "interpretDynamicArrayNode:continue:",
  1053. fn: function (aNode,aBlock){
  1054. var self=this;
  1055. return smalltalk.withContext(function($ctx1) {
  1056. self._interpretAll_continue_(_st(aNode)._nodes(),(function(array){
  1057. return smalltalk.withContext(function($ctx2) {
  1058. return self._continue_value_(aBlock,array);
  1059. }, function($ctx2) {$ctx2.fillBlock({array:array},$ctx1,1)})}));
  1060. return self}, function($ctx1) {$ctx1.fill(self,"interpretDynamicArrayNode:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  1061. messageSends: ["interpretAll:continue:", "nodes", "continue:value:"]}),
  1062. smalltalk.ASTInterpreter);
  1063. smalltalk.addMethod(
  1064. smalltalk.method({
  1065. selector: "interpretDynamicDictionaryNode:continue:",
  1066. fn: function (aNode,aBlock){
  1067. var self=this;
  1068. function $HashedCollection(){return smalltalk.HashedCollection||(typeof HashedCollection=="undefined"?nil:HashedCollection)}
  1069. return smalltalk.withContext(function($ctx1) {
  1070. self._interpretAll_continue_(_st(aNode)._nodes(),(function(array){
  1071. var hashedCollection;
  1072. return smalltalk.withContext(function($ctx2) {
  1073. hashedCollection=_st($HashedCollection())._new();
  1074. hashedCollection;
  1075. _st(array)._do_((function(each){
  1076. return smalltalk.withContext(function($ctx3) {
  1077. return _st(hashedCollection)._add_(each);
  1078. }, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,2)})}));
  1079. return self._continue_value_(aBlock,hashedCollection);
  1080. }, function($ctx2) {$ctx2.fillBlock({array:array,hashedCollection:hashedCollection},$ctx1,1)})}));
  1081. return self}, function($ctx1) {$ctx1.fill(self,"interpretDynamicDictionaryNode:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  1082. messageSends: ["interpretAll:continue:", "nodes", "new", "do:", "add:", "continue:value:"]}),
  1083. smalltalk.ASTInterpreter);
  1084. smalltalk.addMethod(
  1085. smalltalk.method({
  1086. selector: "interpretJSStatementNode:continue:",
  1087. fn: function (aNode,aBlock){
  1088. var self=this;
  1089. return smalltalk.withContext(function($ctx1) {
  1090. self["@shouldReturn"]=true;
  1091. self._continue_value_(aBlock,self._eval_(_st(aNode)._source()));
  1092. return self}, function($ctx1) {$ctx1.fill(self,"interpretJSStatementNode:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  1093. messageSends: ["continue:value:", "eval:", "source"]}),
  1094. smalltalk.ASTInterpreter);
  1095. smalltalk.addMethod(
  1096. smalltalk.method({
  1097. selector: "interpretMethodNode:continue:",
  1098. fn: function (aNode,aBlock){
  1099. var self=this;
  1100. return smalltalk.withContext(function($ctx1) {
  1101. self._interpretAll_continue_(_st(aNode)._nodes(),(function(array){
  1102. return smalltalk.withContext(function($ctx2) {
  1103. return self._continue_value_(aBlock,_st(array)._first());
  1104. }, function($ctx2) {$ctx2.fillBlock({array:array},$ctx1,1)})}));
  1105. return self}, function($ctx1) {$ctx1.fill(self,"interpretMethodNode:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  1106. messageSends: ["interpretAll:continue:", "nodes", "continue:value:", "first"]}),
  1107. smalltalk.ASTInterpreter);
  1108. smalltalk.addMethod(
  1109. smalltalk.method({
  1110. selector: "interpretNode:continue:",
  1111. fn: function (aNode,aBlock){
  1112. var self=this;
  1113. return smalltalk.withContext(function($ctx1) {
  1114. _st(aNode)._interpreter_continue_(self,aBlock);
  1115. return self}, function($ctx1) {$ctx1.fill(self,"interpretNode:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  1116. messageSends: ["interpreter:continue:"]}),
  1117. smalltalk.ASTInterpreter);
  1118. smalltalk.addMethod(
  1119. smalltalk.method({
  1120. selector: "interpretReturnNode:continue:",
  1121. fn: function (aNode,aBlock){
  1122. var self=this;
  1123. return smalltalk.withContext(function($ctx1) {
  1124. self._interpret_continue_(_st(_st(aNode)._nodes())._first(),(function(value){
  1125. return smalltalk.withContext(function($ctx2) {
  1126. self["@shouldReturn"]=true;
  1127. self["@shouldReturn"];
  1128. return self._continue_value_(aBlock,value);
  1129. }, function($ctx2) {$ctx2.fillBlock({value:value},$ctx1,1)})}));
  1130. return self}, function($ctx1) {$ctx1.fill(self,"interpretReturnNode:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  1131. messageSends: ["interpret:continue:", "first", "nodes", "continue:value:"]}),
  1132. smalltalk.ASTInterpreter);
  1133. smalltalk.addMethod(
  1134. smalltalk.method({
  1135. selector: "interpretSendNode:continue:",
  1136. fn: function (aNode,aBlock){
  1137. var self=this;
  1138. return smalltalk.withContext(function($ctx1) {
  1139. self._interpret_continue_(_st(aNode)._receiver(),(function(receiver){
  1140. return smalltalk.withContext(function($ctx2) {
  1141. return self._interpretAll_continue_(_st(aNode)._arguments(),(function(args){
  1142. return smalltalk.withContext(function($ctx3) {
  1143. return self._messageFromSendNode_arguments_do_(aNode,args,(function(message){
  1144. return smalltalk.withContext(function($ctx4) {
  1145. _st(self._context())._pc_(_st(_st(self._context())._pc()).__plus((1)));
  1146. return self._continue_value_(aBlock,self._sendMessage_to_superSend_(message,receiver,_st(aNode)._superSend()));
  1147. }, function($ctx4) {$ctx4.fillBlock({message:message},$ctx3,3)})}));
  1148. }, function($ctx3) {$ctx3.fillBlock({args:args},$ctx2,2)})}));
  1149. }, function($ctx2) {$ctx2.fillBlock({receiver:receiver},$ctx1,1)})}));
  1150. return self}, function($ctx1) {$ctx1.fill(self,"interpretSendNode:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  1151. messageSends: ["interpret:continue:", "receiver", "interpretAll:continue:", "arguments", "messageFromSendNode:arguments:do:", "pc:", "context", "+", "pc", "continue:value:", "sendMessage:to:superSend:", "superSend"]}),
  1152. smalltalk.ASTInterpreter);
  1153. smalltalk.addMethod(
  1154. smalltalk.method({
  1155. selector: "interpretSequenceNode:continue:",
  1156. fn: function (aNode,aBlock){
  1157. var self=this;
  1158. return smalltalk.withContext(function($ctx1) {
  1159. self._interpretAll_continue_(_st(aNode)._nodes(),(function(array){
  1160. return smalltalk.withContext(function($ctx2) {
  1161. return self._continue_value_(aBlock,_st(array)._last());
  1162. }, function($ctx2) {$ctx2.fillBlock({array:array},$ctx1,1)})}));
  1163. return self}, function($ctx1) {$ctx1.fill(self,"interpretSequenceNode:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  1164. messageSends: ["interpretAll:continue:", "nodes", "continue:value:", "last"]}),
  1165. smalltalk.ASTInterpreter);
  1166. smalltalk.addMethod(
  1167. smalltalk.method({
  1168. selector: "interpretValueNode:continue:",
  1169. fn: function (aNode,aBlock){
  1170. var self=this;
  1171. return smalltalk.withContext(function($ctx1) {
  1172. self._continue_value_(aBlock,_st(aNode)._value());
  1173. return self}, function($ctx1) {$ctx1.fill(self,"interpretValueNode:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  1174. messageSends: ["continue:value:", "value"]}),
  1175. smalltalk.ASTInterpreter);
  1176. smalltalk.addMethod(
  1177. smalltalk.method({
  1178. selector: "interpretVariableNode:continue:",
  1179. fn: function (aNode,aBlock){
  1180. var self=this;
  1181. return smalltalk.withContext(function($ctx1) {
  1182. var $1,$2,$4,$3;
  1183. $1=self;
  1184. $2=aBlock;
  1185. $4=_st(_st(aNode)._binding())._isInstanceVar();
  1186. if(smalltalk.assert($4)){
  1187. $3=_st(_st(self._context())._receiver())._instVarAt_(_st(aNode)._value());
  1188. } else {
  1189. $3=_st(self._context())._localAt_(_st(aNode)._value());
  1190. };
  1191. _st($1)._continue_value_($2,$3);
  1192. return self}, function($ctx1) {$ctx1.fill(self,"interpretVariableNode:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  1193. messageSends: ["continue:value:", "ifTrue:ifFalse:", "isInstanceVar", "binding", "instVarAt:", "receiver", "context", "value", "localAt:"]}),
  1194. smalltalk.ASTInterpreter);
  1195. smalltalk.addMethod(
  1196. smalltalk.method({
  1197. selector: "messageFromSendNode:arguments:do:",
  1198. fn: function (aSendNode,aCollection,aBlock){
  1199. var self=this;
  1200. function $Message(){return smalltalk.Message||(typeof Message=="undefined"?nil:Message)}
  1201. return smalltalk.withContext(function($ctx1) {
  1202. var $1,$2;
  1203. $1=_st($Message())._new();
  1204. _st($1)._selector_(_st(aSendNode)._selector());
  1205. _st($1)._arguments_(aCollection);
  1206. $2=_st($1)._yourself();
  1207. self._continue_value_(aBlock,$2);
  1208. return self}, function($ctx1) {$ctx1.fill(self,"messageFromSendNode:arguments:do:",{aSendNode:aSendNode,aCollection:aCollection,aBlock:aBlock},smalltalk.ASTInterpreter)})},
  1209. messageSends: ["continue:value:", "selector:", "new", "selector", "arguments:", "yourself"]}),
  1210. smalltalk.ASTInterpreter);
  1211. smalltalk.addMethod(
  1212. smalltalk.method({
  1213. selector: "nextNode",
  1214. fn: function (){
  1215. var self=this;
  1216. return smalltalk.withContext(function($ctx1) {
  1217. var $2,$1;
  1218. $2=self["@nextNode"];
  1219. if(($receiver = $2) == nil || $receiver == undefined){
  1220. $1=self._currentNode();
  1221. } else {
  1222. $1=$2;
  1223. };
  1224. return $1;
  1225. }, function($ctx1) {$ctx1.fill(self,"nextNode",{},smalltalk.ASTInterpreter)})},
  1226. messageSends: ["ifNil:", "currentNode"]}),
  1227. smalltalk.ASTInterpreter);
  1228. smalltalk.addMethod(
  1229. smalltalk.method({
  1230. selector: "nextNode:",
  1231. fn: function (aNode){
  1232. var self=this;
  1233. return smalltalk.withContext(function($ctx1) {
  1234. self["@nextNode"]=aNode;
  1235. return self}, function($ctx1) {$ctx1.fill(self,"nextNode:",{aNode:aNode},smalltalk.ASTInterpreter)})},
  1236. messageSends: []}),
  1237. smalltalk.ASTInterpreter);
  1238. smalltalk.addMethod(
  1239. smalltalk.method({
  1240. selector: "result",
  1241. fn: function (){
  1242. var self=this;
  1243. return smalltalk.withContext(function($ctx1) {
  1244. var $1;
  1245. $1=self["@result"];
  1246. return $1;
  1247. }, function($ctx1) {$ctx1.fill(self,"result",{},smalltalk.ASTInterpreter)})},
  1248. messageSends: []}),
  1249. smalltalk.ASTInterpreter);
  1250. smalltalk.addMethod(
  1251. smalltalk.method({
  1252. selector: "sendMessage:to:superSend:",
  1253. fn: function (aMessage,anObject,aBoolean){
  1254. var self=this;
  1255. var method;
  1256. return smalltalk.withContext(function($ctx1) {
  1257. var $1,$2,$3,$4,$5,$6;
  1258. var $early={};
  1259. try {
  1260. $1=aBoolean;
  1261. if(! smalltalk.assert($1)){
  1262. $2=_st(aMessage)._sendTo_(anObject);
  1263. return $2;
  1264. };
  1265. $3=_st(_st(anObject)._class())._superclass();
  1266. if(($receiver = $3) == nil || $receiver == undefined){
  1267. $4=self._messageNotUnderstood_receiver_(aMessage,anObject);
  1268. return $4;
  1269. } else {
  1270. $3;
  1271. };
  1272. method=_st(_st(_st(_st(anObject)._class())._superclass())._methodDictionary())._at_ifAbsent_(_st(aMessage)._selector(),(function(){
  1273. return smalltalk.withContext(function($ctx2) {
  1274. $5=self._messageNotUnderstood_receiver_(aMessage,anObject);
  1275. throw $early=[$5];
  1276. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)})}));
  1277. $6=_st(_st(method)._fn())._applyTo_arguments_(anObject,_st(aMessage)._arguments());
  1278. return $6;
  1279. }
  1280. catch(e) {if(e===$early)return e[0]; throw e}
  1281. }, function($ctx1) {$ctx1.fill(self,"sendMessage:to:superSend:",{aMessage:aMessage,anObject:anObject,aBoolean:aBoolean,method:method},smalltalk.ASTInterpreter)})},
  1282. messageSends: ["ifFalse:", "sendTo:", "ifNil:", "superclass", "class", "messageNotUnderstood:receiver:", "at:ifAbsent:", "methodDictionary", "selector", "applyTo:arguments:", "fn", "arguments"]}),
  1283. smalltalk.ASTInterpreter);
  1284. smalltalk.addMethod(
  1285. smalltalk.method({
  1286. selector: "shouldReturn",
  1287. fn: function (){
  1288. var self=this;
  1289. return smalltalk.withContext(function($ctx1) {
  1290. var $2,$1;
  1291. $2=self["@shouldReturn"];
  1292. if(($receiver = $2) == nil || $receiver == undefined){
  1293. $1=false;
  1294. } else {
  1295. $1=$2;
  1296. };
  1297. return $1;
  1298. }, function($ctx1) {$ctx1.fill(self,"shouldReturn",{},smalltalk.ASTInterpreter)})},
  1299. messageSends: ["ifNil:"]}),
  1300. smalltalk.ASTInterpreter);
  1301. smalltalk.addMethod(
  1302. smalltalk.method({
  1303. selector: "withBlockContext:",
  1304. fn: function (aBlock){
  1305. var self=this;
  1306. var blockResult;
  1307. function $AIContext(){return smalltalk.AIContext||(typeof AIContext=="undefined"?nil:AIContext)}
  1308. return smalltalk.withContext(function($ctx1) {
  1309. var $1,$2,$3;
  1310. $1=_st($AIContext())._new();
  1311. _st($1)._outerContext_(self._context());
  1312. $2=_st($1)._yourself();
  1313. self._context_($2);
  1314. blockResult=_st(aBlock)._value();
  1315. self._context_(_st(self._context())._outerContext());
  1316. $3=blockResult;
  1317. return $3;
  1318. }, function($ctx1) {$ctx1.fill(self,"withBlockContext:",{aBlock:aBlock,blockResult:blockResult},smalltalk.ASTInterpreter)})},
  1319. messageSends: ["context:", "outerContext:", "new", "context", "yourself", "value", "outerContext"]}),
  1320. smalltalk.ASTInterpreter);
  1321. smalltalk.addClass('ASTSteppingInterpreter', smalltalk.ASTInterpreter, ['continuation', 'nextNode'], 'Compiler-Interpreter');
  1322. smalltalk.addMethod(
  1323. smalltalk.method({
  1324. selector: "atEnd",
  1325. fn: function (){
  1326. var self=this;
  1327. return smalltalk.withContext(function($ctx1) {
  1328. var $1;
  1329. $1=_st(self._shouldReturn())._or_((function(){
  1330. return smalltalk.withContext(function($ctx2) {
  1331. return _st(self._nextNode()).__eq_eq(self._currentNode());
  1332. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)})}));
  1333. return $1;
  1334. }, function($ctx1) {$ctx1.fill(self,"atEnd",{},smalltalk.ASTSteppingInterpreter)})},
  1335. messageSends: ["or:", "shouldReturn", "==", "nextNode", "currentNode"]}),
  1336. smalltalk.ASTSteppingInterpreter);
  1337. smalltalk.addMethod(
  1338. smalltalk.method({
  1339. selector: "initialize",
  1340. fn: function (){
  1341. var self=this;
  1342. return smalltalk.withContext(function($ctx1) {
  1343. smalltalk.ASTInterpreter.fn.prototype._initialize.apply(_st(self), []);
  1344. self["@continuation"]=(function(){
  1345. return smalltalk.withContext(function($ctx2) {
  1346. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)})});
  1347. return self}, function($ctx1) {$ctx1.fill(self,"initialize",{},smalltalk.ASTSteppingInterpreter)})},
  1348. messageSends: ["initialize"]}),
  1349. smalltalk.ASTSteppingInterpreter);
  1350. smalltalk.addMethod(
  1351. smalltalk.method({
  1352. selector: "interpret:continue:",
  1353. fn: function (aNode,aBlock){
  1354. var self=this;
  1355. return smalltalk.withContext(function($ctx1) {
  1356. self["@nextNode"]=aNode;
  1357. self["@continuation"]=(function(){
  1358. return smalltalk.withContext(function($ctx2) {
  1359. return smalltalk.ASTInterpreter.fn.prototype._interpret_continue_.apply(_st(self), [aNode,aBlock]);
  1360. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)})});
  1361. return self}, function($ctx1) {$ctx1.fill(self,"interpret:continue:",{aNode:aNode,aBlock:aBlock},smalltalk.ASTSteppingInterpreter)})},
  1362. messageSends: ["interpret:continue:"]}),
  1363. smalltalk.ASTSteppingInterpreter);
  1364. smalltalk.addMethod(
  1365. smalltalk.method({
  1366. selector: "nextNode",
  1367. fn: function (){
  1368. var self=this;
  1369. return smalltalk.withContext(function($ctx1) {
  1370. var $1;
  1371. $1=self["@nextNode"];
  1372. return $1;
  1373. }, function($ctx1) {$ctx1.fill(self,"nextNode",{},smalltalk.ASTSteppingInterpreter)})},
  1374. messageSends: []}),
  1375. smalltalk.ASTSteppingInterpreter);
  1376. smalltalk.addMethod(
  1377. smalltalk.method({
  1378. selector: "step",
  1379. fn: function (){
  1380. var self=this;
  1381. return smalltalk.withContext(function($ctx1) {
  1382. _st(self["@continuation"])._value();
  1383. return self}, function($ctx1) {$ctx1.fill(self,"step",{},smalltalk.ASTSteppingInterpreter)})},
  1384. messageSends: ["value"]}),
  1385. smalltalk.ASTSteppingInterpreter);
  1386. smalltalk.addClass('ASTPCNodeVisitor', smalltalk.NodeVisitor, ['useInlinings', 'pc', 'context', 'blockIndex', 'currentNode'], 'Compiler-Interpreter');
  1387. smalltalk.addMethod(
  1388. smalltalk.method({
  1389. selector: "blockIndex",
  1390. fn: function (){
  1391. var self=this;
  1392. return smalltalk.withContext(function($ctx1) {
  1393. var $2,$1;
  1394. $2=self["@blockIndex"];
  1395. if(($receiver = $2) == nil || $receiver == undefined){
  1396. self["@blockIndex"]=(0);
  1397. $1=self["@blockIndex"];
  1398. } else {
  1399. $1=$2;
  1400. };
  1401. return $1;
  1402. }, function($ctx1) {$ctx1.fill(self,"blockIndex",{},smalltalk.ASTPCNodeVisitor)})},
  1403. messageSends: ["ifNil:"]}),
  1404. smalltalk.ASTPCNodeVisitor);
  1405. smalltalk.addMethod(
  1406. smalltalk.method({
  1407. selector: "context",
  1408. fn: function (){
  1409. var self=this;
  1410. return smalltalk.withContext(function($ctx1) {
  1411. var $1;
  1412. $1=self["@context"];
  1413. return $1;
  1414. }, function($ctx1) {$ctx1.fill(self,"context",{},smalltalk.ASTPCNodeVisitor)})},
  1415. messageSends: []}),
  1416. smalltalk.ASTPCNodeVisitor);
  1417. smalltalk.addMethod(
  1418. smalltalk.method({
  1419. selector: "context:",
  1420. fn: function (aContext){
  1421. var self=this;
  1422. return smalltalk.withContext(function($ctx1) {
  1423. self["@context"]=aContext;
  1424. return self}, function($ctx1) {$ctx1.fill(self,"context:",{aContext:aContext},smalltalk.ASTPCNodeVisitor)})},
  1425. messageSends: []}),
  1426. smalltalk.ASTPCNodeVisitor);
  1427. smalltalk.addMethod(
  1428. smalltalk.method({
  1429. selector: "currentNode",
  1430. fn: function (){
  1431. var self=this;
  1432. return smalltalk.withContext(function($ctx1) {
  1433. var $1;
  1434. $1=self["@currentNode"];
  1435. return $1;
  1436. }, function($ctx1) {$ctx1.fill(self,"currentNode",{},smalltalk.ASTPCNodeVisitor)})},
  1437. messageSends: []}),
  1438. smalltalk.ASTPCNodeVisitor);
  1439. smalltalk.addMethod(
  1440. smalltalk.method({
  1441. selector: "increaseBlockIndex",
  1442. fn: function (){
  1443. var self=this;
  1444. return smalltalk.withContext(function($ctx1) {
  1445. self["@blockIndex"]=_st(self._blockIndex()).__plus((1));
  1446. return self}, function($ctx1) {$ctx1.fill(self,"increaseBlockIndex",{},smalltalk.ASTPCNodeVisitor)})},
  1447. messageSends: ["+", "blockIndex"]}),
  1448. smalltalk.ASTPCNodeVisitor);
  1449. smalltalk.addMethod(
  1450. smalltalk.method({
  1451. selector: "pc",
  1452. fn: function (){
  1453. var self=this;
  1454. return smalltalk.withContext(function($ctx1) {
  1455. var $2,$1;
  1456. $2=self["@pc"];
  1457. if(($receiver = $2) == nil || $receiver == undefined){
  1458. $1=(0);
  1459. } else {
  1460. $1=$2;
  1461. };
  1462. return $1;
  1463. }, function($ctx1) {$ctx1.fill(self,"pc",{},smalltalk.ASTPCNodeVisitor)})},
  1464. messageSends: ["ifNil:"]}),
  1465. smalltalk.ASTPCNodeVisitor);
  1466. smalltalk.addMethod(
  1467. smalltalk.method({
  1468. selector: "pc:",
  1469. fn: function (anInteger){
  1470. var self=this;
  1471. return smalltalk.withContext(function($ctx1) {
  1472. self["@pc"]=anInteger;
  1473. return self}, function($ctx1) {$ctx1.fill(self,"pc:",{anInteger:anInteger},smalltalk.ASTPCNodeVisitor)})},
  1474. messageSends: []}),
  1475. smalltalk.ASTPCNodeVisitor);
  1476. smalltalk.addMethod(
  1477. smalltalk.method({
  1478. selector: "useInlinings",
  1479. fn: function (){
  1480. var self=this;
  1481. return smalltalk.withContext(function($ctx1) {
  1482. var $2,$1;
  1483. $2=self["@useInlinings"];
  1484. if(($receiver = $2) == nil || $receiver == undefined){
  1485. $1=true;
  1486. } else {
  1487. $1=$2;
  1488. };
  1489. return $1;
  1490. }, function($ctx1) {$ctx1.fill(self,"useInlinings",{},smalltalk.ASTPCNodeVisitor)})},
  1491. messageSends: ["ifNil:"]}),
  1492. smalltalk.ASTPCNodeVisitor);
  1493. smalltalk.addMethod(
  1494. smalltalk.method({
  1495. selector: "useInlinings:",
  1496. fn: function (aBoolean){
  1497. var self=this;
  1498. return smalltalk.withContext(function($ctx1) {
  1499. self["@useInlinings"]=aBoolean;
  1500. return self}, function($ctx1) {$ctx1.fill(self,"useInlinings:",{aBoolean:aBoolean},smalltalk.ASTPCNodeVisitor)})},
  1501. messageSends: []}),
  1502. smalltalk.ASTPCNodeVisitor);
  1503. smalltalk.addMethod(
  1504. smalltalk.method({
  1505. selector: "visitBlockNode:",
  1506. fn: function (aNode){
  1507. var self=this;
  1508. return smalltalk.withContext(function($ctx1) {
  1509. var $1;
  1510. $1=_st(self._blockIndex()).__gt_eq(_st(self._context())._index());
  1511. if(! smalltalk.assert($1)){
  1512. self._increaseBlockIndex();
  1513. smalltalk.NodeVisitor.fn.prototype._visitBlockNode_.apply(_st(self), [aNode]);
  1514. };
  1515. return self}, function($ctx1) {$ctx1.fill(self,"visitBlockNode:",{aNode:aNode},smalltalk.ASTPCNodeVisitor)})},
  1516. messageSends: ["ifFalse:", ">=", "blockIndex", "index", "context", "increaseBlockIndex", "visitBlockNode:"]}),
  1517. smalltalk.ASTPCNodeVisitor);
  1518. smalltalk.addMethod(
  1519. smalltalk.method({
  1520. selector: "visitJSStatementNode:",
  1521. fn: function (aNode){
  1522. var self=this;
  1523. return smalltalk.withContext(function($ctx1) {
  1524. self["@currentNode"]=aNode;
  1525. return self}, function($ctx1) {$ctx1.fill(self,"visitJSStatementNode:",{aNode:aNode},smalltalk.ASTPCNodeVisitor)})},
  1526. messageSends: []}),
  1527. smalltalk.ASTPCNodeVisitor);
  1528. smalltalk.addMethod(
  1529. smalltalk.method({
  1530. selector: "visitSendNode:",
  1531. fn: function (aNode){
  1532. var self=this;
  1533. return smalltalk.withContext(function($ctx1) {
  1534. var $1,$2,$3;
  1535. smalltalk.NodeVisitor.fn.prototype._visitSendNode_.apply(_st(self), [aNode]);
  1536. $1=_st(self._pc()).__eq(_st(self._context())._pc());
  1537. if(! smalltalk.assert($1)){
  1538. $2=_st(aNode)._shouldBeInlined();
  1539. if(! smalltalk.assert($2)){
  1540. $3=_st(self._blockIndex()).__eq(_st(self._context())._index());
  1541. if(smalltalk.assert($3)){
  1542. self._pc_(_st(self._pc()).__plus((1)));
  1543. self["@currentNode"]=aNode;
  1544. self["@currentNode"];
  1545. };
  1546. };
  1547. };
  1548. return self}, function($ctx1) {$ctx1.fill(self,"visitSendNode:",{aNode:aNode},smalltalk.ASTPCNodeVisitor)})},
  1549. messageSends: ["visitSendNode:", "ifFalse:", "=", "pc", "context", "shouldBeInlined", "ifTrue:", "blockIndex", "index", "pc:", "+"]}),
  1550. smalltalk.ASTPCNodeVisitor);
  1551. smalltalk.addClass('Interpreter', smalltalk.NodeVisitor, ['node', 'context', 'stack', 'returnValue'], 'Compiler-Interpreter');
  1552. smalltalk.addMethod(
  1553. smalltalk.method({
  1554. selector: "assign:to:",
  1555. fn: function (aNode,anObject){
  1556. var self=this;
  1557. return smalltalk.withContext(function($ctx1) {
  1558. var $1;
  1559. $1=_st(_st(aNode)._binding())._isInstanceVar();
  1560. if(smalltalk.assert($1)){
  1561. _st(_st(self._context())._receiver())._instVarAt_put_(_st(aNode)._value(),anObject);
  1562. } else {
  1563. _st(self._context())._localAt_put_(_st(aNode)._value(),anObject);
  1564. };
  1565. return self}, function($ctx1) {$ctx1.fill(self,"assign:to:",{aNode:aNode,anObject:anObject},smalltalk.Interpreter)})},
  1566. messageSends: ["ifTrue:ifFalse:", "isInstanceVar", "binding", "instVarAt:put:", "receiver", "context", "value", "localAt:put:"]}),
  1567. smalltalk.Interpreter);
  1568. smalltalk.addMethod(
  1569. smalltalk.method({
  1570. selector: "atEnd",
  1571. fn: function (){
  1572. var self=this;
  1573. return smalltalk.withContext(function($ctx1) {
  1574. var $1;
  1575. $1=_st(self._shouldReturn())._or_((function(){
  1576. return smalltalk.withContext(function($ctx2) {
  1577. return _st(self._node())._isNil();
  1578. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)})}));
  1579. return $1;
  1580. }, function($ctx1) {$ctx1.fill(self,"atEnd",{},smalltalk.Interpreter)})},
  1581. messageSends: ["or:", "shouldReturn", "isNil", "node"]}),
  1582. smalltalk.Interpreter);
  1583. smalltalk.addMethod(
  1584. smalltalk.method({
  1585. selector: "context",
  1586. fn: function (){
  1587. var self=this;
  1588. return smalltalk.withContext(function($ctx1) {
  1589. var $1;
  1590. $1=self["@context"];
  1591. return $1;
  1592. }, function($ctx1) {$ctx1.fill(self,"context",{},smalltalk.Interpreter)})},
  1593. messageSends: []}),
  1594. smalltalk.Interpreter);
  1595. smalltalk.addMethod(
  1596. smalltalk.method({
  1597. selector: "context:",
  1598. fn: function (aContext){
  1599. var self=this;
  1600. return smalltalk.withContext(function($ctx1) {
  1601. self["@context"]=aContext;
  1602. return self}, function($ctx1) {$ctx1.fill(self,"context:",{aContext:aContext},smalltalk.Interpreter)})},
  1603. messageSends: []}),
  1604. smalltalk.Interpreter);
  1605. smalltalk.addMethod(
  1606. smalltalk.method({
  1607. selector: "eval:",
  1608. fn: function (aString){
  1609. var self=this;
  1610. var source,function_;
  1611. function $String(){return smalltalk.String||(typeof String=="undefined"?nil:String)}
  1612. function $Compiler(){return smalltalk.Compiler||(typeof Compiler=="undefined"?nil:Compiler)}
  1613. return smalltalk.withContext(function($ctx1) {
  1614. var $1,$2,$3;
  1615. source=_st($String())._streamContents_((function(str){
  1616. return smalltalk.withContext(function($ctx2) {
  1617. _st(str)._nextPutAll_("(function(");
  1618. _st(_st(_st(self._context())._locals())._keys())._do_separatedBy_((function(each){
  1619. return smalltalk.withContext(function($ctx3) {
  1620. return _st(str)._nextPutAll_(each);
  1621. }, function($ctx3) {$ctx3.fillBlock({each:each},$ctx2,2)})}),(function(){
  1622. return smalltalk.withContext(function($ctx3) {
  1623. return _st(str)._nextPutAll_(",");
  1624. }, function($ctx3) {$ctx3.fillBlock({},$ctx2,3)})}));
  1625. $1=str;
  1626. _st($1)._nextPutAll_("){ return (function() {");
  1627. _st($1)._nextPutAll_(aString);
  1628. $2=_st($1)._nextPutAll_("})() })");
  1629. return $2;
  1630. }, function($ctx2) {$ctx2.fillBlock({str:str},$ctx1,1)})}));
  1631. function_=_st(_st($Compiler())._new())._eval_(source);
  1632. $3=_st(function_)._valueWithPossibleArguments_(_st(_st(self._context())._locals())._values());
  1633. return $3;
  1634. }, function($ctx1) {$ctx1.fill(self,"eval:",{aString:aString,source:source,function_:function_},smalltalk.Interpreter)})},
  1635. messageSends: ["streamContents:", "nextPutAll:", "do:separatedBy:", "keys", "locals", "context", "eval:", "new", "valueWithPossibleArguments:", "values"]}),
  1636. smalltalk.Interpreter);
  1637. smalltalk.addMethod(
  1638. smalltalk.method({
  1639. selector: "interpret",
  1640. fn: function (){
  1641. var self=this;
  1642. return smalltalk.withContext(function($ctx1) {
  1643. self._visit_(self._node());
  1644. return self}, function($ctx1) {$ctx1.fill(self,"interpret",{},smalltalk.Interpreter)})},
  1645. messageSends: ["visit:", "node"]}),
  1646. smalltalk.Interpreter);
  1647. smalltalk.addMethod(
  1648. smalltalk.method({
  1649. selector: "interpret:",
  1650. fn: function (aNode){
  1651. var self=this;
  1652. return smalltalk.withContext(function($ctx1) {
  1653. self._node_(aNode);
  1654. self._interpret();
  1655. return self}, function($ctx1) {$ctx1.fill(self,"interpret:",{aNode:aNode},smalltalk.Interpreter)})},
  1656. messageSends: ["node:", "interpret"]}),
  1657. smalltalk.Interpreter);
  1658. smalltalk.addMethod(
  1659. smalltalk.method({
  1660. selector: "messageFromSendNode:arguments:",
  1661. fn: function (aSendNode,aCollection){
  1662. var self=this;
  1663. function $Message(){return smalltalk.Message||(typeof Message=="undefined"?nil:Message)}
  1664. return smalltalk.withContext(function($ctx1) {
  1665. var $2,$3,$1;
  1666. $2=_st($Message())._new();
  1667. _st($2)._selector_(_st(aSendNode)._selector());
  1668. _st($2)._arguments_(aCollection);
  1669. $3=_st($2)._yourself();
  1670. $1=$3;
  1671. return $1;
  1672. }, function($ctx1) {$ctx1.fill(self,"messageFromSendNode:arguments:",{aSendNode:aSendNode,aCollection:aCollection},smalltalk.Interpreter)})},
  1673. messageSends: ["selector:", "new", "selector", "arguments:", "yourself"]}),
  1674. smalltalk.Interpreter);
  1675. smalltalk.addMethod(
  1676. smalltalk.method({
  1677. selector: "messageNotUnderstood:receiver:",
  1678. fn: function (aMessage,anObject){
  1679. var self=this;
  1680. function $MessageNotUnderstood(){return smalltalk.MessageNotUnderstood||(typeof MessageNotUnderstood=="undefined"?nil:MessageNotUnderstood)}
  1681. return smalltalk.withContext(function($ctx1) {
  1682. var $1,$2;
  1683. $1=_st($MessageNotUnderstood())._new();
  1684. _st($1)._meesage_(aMessage);
  1685. _st($1)._receiver_(anObject);
  1686. $2=_st($1)._signal();
  1687. return self}, function($ctx1) {$ctx1.fill(self,"messageNotUnderstood:receiver:",{aMessage:aMessage,anObject:anObject},smalltalk.Interpreter)})},
  1688. messageSends: ["meesage:", "new", "receiver:", "signal"]}),
  1689. smalltalk.Interpreter);
  1690. smalltalk.addMethod(
  1691. smalltalk.method({
  1692. selector: "next",
  1693. fn: function (){
  1694. var self=this;
  1695. return smalltalk.withContext(function($ctx1) {
  1696. self._node_(_st(self._node())._nextNode());
  1697. return self}, function($ctx1) {$ctx1.fill(self,"next",{},smalltalk.Interpreter)})},
  1698. messageSends: ["node:", "nextNode", "node"]}),
  1699. smalltalk.Interpreter);
  1700. smalltalk.addMethod(
  1701. smalltalk.method({
  1702. selector: "node",
  1703. fn: function (){
  1704. var self=this;
  1705. return smalltalk.withContext(function($ctx1) {
  1706. var $1;
  1707. $1=self["@node"];
  1708. return $1;
  1709. }, function($ctx1) {$ctx1.fill(self,"node",{},smalltalk.Interpreter)})},
  1710. messageSends: []}),
  1711. smalltalk.Interpreter);
  1712. smalltalk.addMethod(
  1713. smalltalk.method({
  1714. selector: "node:",
  1715. fn: function (aNode){
  1716. var self=this;
  1717. return smalltalk.withContext(function($ctx1) {
  1718. self["@node"]=aNode;
  1719. return self}, function($ctx1) {$ctx1.fill(self,"node:",{aNode:aNode},smalltalk.Interpreter)})},
  1720. messageSends: []}),
  1721. smalltalk.Interpreter);
  1722. smalltalk.addMethod(
  1723. smalltalk.method({
  1724. selector: "peek",
  1725. fn: function (){
  1726. var self=this;
  1727. return smalltalk.withContext(function($ctx1) {
  1728. var $1;
  1729. $1=_st(self._stack())._last();
  1730. return $1;
  1731. }, function($ctx1) {$ctx1.fill(self,"peek",{},smalltalk.Interpreter)})},
  1732. messageSends: ["last", "stack"]}),
  1733. smalltalk.Interpreter);
  1734. smalltalk.addMethod(
  1735. smalltalk.method({
  1736. selector: "pop",
  1737. fn: function (){
  1738. var self=this;
  1739. var value;
  1740. return smalltalk.withContext(function($ctx1) {
  1741. var $1;
  1742. value=self._peek();
  1743. _st(self._stack())._removeLast();
  1744. $1=value;
  1745. return $1;
  1746. }, function($ctx1) {$ctx1.fill(self,"pop",{value:value},smalltalk.Interpreter)})},
  1747. messageSends: ["peek", "removeLast", "stack"]}),
  1748. smalltalk.Interpreter);
  1749. smalltalk.addMethod(
  1750. smalltalk.method({
  1751. selector: "proceed",
  1752. fn: function (){
  1753. var self=this;
  1754. return smalltalk.withContext(function($ctx1) {
  1755. _st((function(){
  1756. return smalltalk.withContext(function($ctx2) {
  1757. return self._atEnd();
  1758. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)})}))._whileFalse_((function(){
  1759. return smalltalk.withContext(function($ctx2) {
  1760. return self._step();
  1761. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)})}));
  1762. return self}, function($ctx1) {$ctx1.fill(self,"proceed",{},smalltalk.Interpreter)})},
  1763. messageSends: ["whileFalse:", "atEnd", "step"]}),
  1764. smalltalk.Interpreter);
  1765. smalltalk.addMethod(
  1766. smalltalk.method({
  1767. selector: "push:",
  1768. fn: function (anObject){
  1769. var self=this;
  1770. return smalltalk.withContext(function($ctx1) {
  1771. var $1;
  1772. $1=_st(self._stack())._add_(anObject);
  1773. return $1;
  1774. }, function($ctx1) {$ctx1.fill(self,"push:",{anObject:anObject},smalltalk.Interpreter)})},
  1775. messageSends: ["add:", "stack"]}),
  1776. smalltalk.Interpreter);
  1777. smalltalk.addMethod(
  1778. smalltalk.method({
  1779. selector: "restart",
  1780. fn: function (){
  1781. var self=this;
  1782. return smalltalk.withContext(function($ctx1) {
  1783. self._node_(_st(_st(self._context())._ast())._nextChild());
  1784. return self}, function($ctx1) {$ctx1.fill(self,"restart",{},smalltalk.Interpreter)})},
  1785. messageSends: ["node:", "nextChild", "ast", "context"]}),
  1786. smalltalk.Interpreter);
  1787. smalltalk.addMethod(
  1788. smalltalk.method({
  1789. selector: "result",
  1790. fn: function (){
  1791. var self=this;
  1792. return smalltalk.withContext(function($ctx1) {
  1793. var $2,$1;
  1794. $2=self._returnValue();
  1795. if(($receiver = $2) == nil || $receiver == undefined){
  1796. $1=_st(self._context())._receiver();
  1797. } else {
  1798. $1=$2;
  1799. };
  1800. return $1;
  1801. }, function($ctx1) {$ctx1.fill(self,"result",{},smalltalk.Interpreter)})},
  1802. messageSends: ["ifNil:", "returnValue", "receiver", "context"]}),
  1803. smalltalk.Interpreter);
  1804. smalltalk.addMethod(
  1805. smalltalk.method({
  1806. selector: "returnValue",
  1807. fn: function (){
  1808. var self=this;
  1809. return smalltalk.withContext(function($ctx1) {
  1810. var $1;
  1811. $1=self["@returnValue"];
  1812. return $1;
  1813. }, function($ctx1) {$ctx1.fill(self,"returnValue",{},smalltalk.Interpreter)})},
  1814. messageSends: []}),
  1815. smalltalk.Interpreter);
  1816. smalltalk.addMethod(
  1817. smalltalk.method({
  1818. selector: "returnValue:",
  1819. fn: function (anObject){
  1820. var self=this;
  1821. return smalltalk.withContext(function($ctx1) {
  1822. self["@returnValue"]=anObject;
  1823. return self}, function($ctx1) {$ctx1.fill(self,"returnValue:",{anObject:anObject},smalltalk.Interpreter)})},
  1824. messageSends: []}),
  1825. smalltalk.Interpreter);
  1826. smalltalk.addMethod(
  1827. smalltalk.method({
  1828. selector: "sendMessage:to:superSend:",
  1829. fn: function (aMessage,anObject,aBoolean){
  1830. var self=this;
  1831. var method;
  1832. return smalltalk.withContext(function($ctx1) {
  1833. var $1,$2,$3,$4,$5,$6;
  1834. var $early={};
  1835. try {
  1836. $1=aBoolean;
  1837. if(! smalltalk.assert($1)){
  1838. $2=_st(aMessage)._sendTo_(anObject);
  1839. return $2;
  1840. };
  1841. $3=_st(_st(anObject)._class())._superclass();
  1842. if(($receiver = $3) == nil || $receiver == undefined){
  1843. $4=self._messageNotUnderstood_receiver_(aMessage,anObject);
  1844. return $4;
  1845. } else {
  1846. $3;
  1847. };
  1848. method=_st(_st(_st(_st(anObject)._class())._superclass())._methodDictionary())._at_ifAbsent_(_st(aMessage)._selector(),(function(){
  1849. return smalltalk.withContext(function($ctx2) {
  1850. $5=self._messageNotUnderstood_receiver_(aMessage,anObject);
  1851. throw $early=[$5];
  1852. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,3)})}));
  1853. $6=_st(method)._sendTo_arguments_(anObject,_st(aMessage)._arguments());
  1854. return $6;
  1855. }
  1856. catch(e) {if(e===$early)return e[0]; throw e}
  1857. }, function($ctx1) {$ctx1.fill(self,"sendMessage:to:superSend:",{aMessage:aMessage,anObject:anObject,aBoolean:aBoolean,method:method},smalltalk.Interpreter)})},
  1858. messageSends: ["ifFalse:", "sendTo:", "ifNil:", "superclass", "class", "messageNotUnderstood:receiver:", "at:ifAbsent:", "methodDictionary", "selector", "sendTo:arguments:", "arguments"]}),
  1859. smalltalk.Interpreter);
  1860. smalltalk.addMethod(
  1861. smalltalk.method({
  1862. selector: "shouldReturn",
  1863. fn: function (){
  1864. var self=this;
  1865. return smalltalk.withContext(function($ctx1) {
  1866. var $1;
  1867. $1=_st(self._returnValue())._notNil();
  1868. return $1;
  1869. }, function($ctx1) {$ctx1.fill(self,"shouldReturn",{},smalltalk.Interpreter)})},
  1870. messageSends: ["notNil", "returnValue"]}),
  1871. smalltalk.Interpreter);
  1872. smalltalk.addMethod(
  1873. smalltalk.method({
  1874. selector: "skip",
  1875. fn: function (){
  1876. var self=this;
  1877. return smalltalk.withContext(function($ctx1) {
  1878. self._next();
  1879. return self}, function($ctx1) {$ctx1.fill(self,"skip",{},smalltalk.Interpreter)})},
  1880. messageSends: ["next"]}),
  1881. smalltalk.Interpreter);
  1882. smalltalk.addMethod(
  1883. smalltalk.method({
  1884. selector: "stack",
  1885. fn: function (){
  1886. var self=this;
  1887. function $OrderedCollection(){return smalltalk.OrderedCollection||(typeof OrderedCollection=="undefined"?nil:OrderedCollection)}
  1888. return smalltalk.withContext(function($ctx1) {
  1889. var $2,$1;
  1890. $2=self["@stack"];
  1891. if(($receiver = $2) == nil || $receiver == undefined){
  1892. self["@stack"]=_st($OrderedCollection())._new();
  1893. $1=self["@stack"];
  1894. } else {
  1895. $1=$2;
  1896. };
  1897. return $1;
  1898. }, function($ctx1) {$ctx1.fill(self,"stack",{},smalltalk.Interpreter)})},
  1899. messageSends: ["ifNil:", "new"]}),
  1900. smalltalk.Interpreter);
  1901. smalltalk.addMethod(
  1902. smalltalk.method({
  1903. selector: "step",
  1904. fn: function (){
  1905. var self=this;
  1906. return smalltalk.withContext(function($ctx1) {
  1907. var $1,$2;
  1908. $1=self;
  1909. _st($1)._interpret();
  1910. $2=_st($1)._next();
  1911. return self}, function($ctx1) {$ctx1.fill(self,"step",{},smalltalk.Interpreter)})},
  1912. messageSends: ["interpret", "next"]}),
  1913. smalltalk.Interpreter);
  1914. smalltalk.addMethod(
  1915. smalltalk.method({
  1916. selector: "stepOver",
  1917. fn: function (){
  1918. var self=this;
  1919. return smalltalk.withContext(function($ctx1) {
  1920. self._step();
  1921. _st((function(){
  1922. return smalltalk.withContext(function($ctx2) {
  1923. return _st(self._node())._isSteppingNode();
  1924. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,1)})}))._whileFalse_((function(){
  1925. return smalltalk.withContext(function($ctx2) {
  1926. return self._step();
  1927. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)})}));
  1928. return self}, function($ctx1) {$ctx1.fill(self,"stepOver",{},smalltalk.Interpreter)})},
  1929. messageSends: ["step", "whileFalse:", "isSteppingNode", "node"]}),
  1930. smalltalk.Interpreter);
  1931. smalltalk.addMethod(
  1932. smalltalk.method({
  1933. selector: "visit:",
  1934. fn: function (aNode){
  1935. var self=this;
  1936. return smalltalk.withContext(function($ctx1) {
  1937. var $1;
  1938. $1=self._shouldReturn();
  1939. if(! smalltalk.assert($1)){
  1940. smalltalk.NodeVisitor.fn.prototype._visit_.apply(_st(self), [aNode]);
  1941. };
  1942. return self}, function($ctx1) {$ctx1.fill(self,"visit:",{aNode:aNode},smalltalk.Interpreter)})},
  1943. messageSends: ["ifFalse:", "shouldReturn", "visit:"]}),
  1944. smalltalk.Interpreter);
  1945. smalltalk.addMethod(
  1946. smalltalk.method({
  1947. selector: "visitAssignmentNode:",
  1948. fn: function (aNode){
  1949. var self=this;
  1950. var value;
  1951. return smalltalk.withContext(function($ctx1) {
  1952. value=self._pop();
  1953. self._pop();
  1954. self._push_(value);
  1955. self._assign_to_(_st(aNode)._left(),value);
  1956. return self}, function($ctx1) {$ctx1.fill(self,"visitAssignmentNode:",{aNode:aNode,value:value},smalltalk.Interpreter)})},
  1957. messageSends: ["pop", "push:", "assign:to:", "left"]}),
  1958. smalltalk.Interpreter);
  1959. smalltalk.addMethod(
  1960. smalltalk.method({
  1961. selector: "visitBlockNode:",
  1962. fn: function (aNode){
  1963. var self=this;
  1964. var blockContext,block;
  1965. function $AIBlockClosure(){return smalltalk.AIBlockClosure||(typeof AIBlockClosure=="undefined"?nil:AIBlockClosure)}
  1966. return smalltalk.withContext(function($ctx1) {
  1967. block=_st($AIBlockClosure())._forInterpreter_context_node_(self,self._context(),aNode);
  1968. self._push_(block);
  1969. return self}, function($ctx1) {$ctx1.fill(self,"visitBlockNode:",{aNode:aNode,blockContext:blockContext,block:block},smalltalk.Interpreter)})},
  1970. messageSends: ["forInterpreter:context:node:", "context", "push:"]}),
  1971. smalltalk.Interpreter);
  1972. smalltalk.addMethod(
  1973. smalltalk.method({
  1974. selector: "visitClassReferenceNode:",
  1975. fn: function (aNode){
  1976. var self=this;
  1977. function $Smalltalk(){return smalltalk.Smalltalk||(typeof Smalltalk=="undefined"?nil:Smalltalk)}
  1978. return smalltalk.withContext(function($ctx1) {
  1979. self._push_(_st(_st($Smalltalk())._current())._at_(_st(aNode)._value()));
  1980. return self}, function($ctx1) {$ctx1.fill(self,"visitClassReferenceNode:",{aNode:aNode},smalltalk.Interpreter)})},
  1981. messageSends: ["push:", "at:", "current", "value"]}),
  1982. smalltalk.Interpreter);
  1983. smalltalk.addMethod(
  1984. smalltalk.method({
  1985. selector: "visitDynamicArrayNode:",
  1986. fn: function (aNode){
  1987. var self=this;
  1988. var array;
  1989. return smalltalk.withContext(function($ctx1) {
  1990. array=[];
  1991. _st(_st(aNode)._nodes())._do_((function(each){
  1992. return smalltalk.withContext(function($ctx2) {
  1993. return _st(array)._addFirst_(self._pop());
  1994. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)})}));
  1995. self._push_(array);
  1996. return self}, function($ctx1) {$ctx1.fill(self,"visitDynamicArrayNode:",{aNode:aNode,array:array},smalltalk.Interpreter)})},
  1997. messageSends: ["do:", "nodes", "addFirst:", "pop", "push:"]}),
  1998. smalltalk.Interpreter);
  1999. smalltalk.addMethod(
  2000. smalltalk.method({
  2001. selector: "visitDynamicDictionaryNode:",
  2002. fn: function (aNode){
  2003. var self=this;
  2004. var hashedCollection;
  2005. function $HashedCollection(){return smalltalk.HashedCollection||(typeof HashedCollection=="undefined"?nil:HashedCollection)}
  2006. return smalltalk.withContext(function($ctx1) {
  2007. hashedCollection=_st($HashedCollection())._new();
  2008. _st(_st(aNode)._nodes())._do_((function(each){
  2009. return smalltalk.withContext(function($ctx2) {
  2010. return _st(hashedCollection)._add_(self._pop());
  2011. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)})}));
  2012. self._push_(hashedCollection);
  2013. return self}, function($ctx1) {$ctx1.fill(self,"visitDynamicDictionaryNode:",{aNode:aNode,hashedCollection:hashedCollection},smalltalk.Interpreter)})},
  2014. messageSends: ["new", "do:", "nodes", "add:", "pop", "push:"]}),
  2015. smalltalk.Interpreter);
  2016. smalltalk.addMethod(
  2017. smalltalk.method({
  2018. selector: "visitJSStatementNode:",
  2019. fn: function (aNode){
  2020. var self=this;
  2021. return smalltalk.withContext(function($ctx1) {
  2022. self._returnValue_(self._eval_(_st(aNode)._source()));
  2023. return self}, function($ctx1) {$ctx1.fill(self,"visitJSStatementNode:",{aNode:aNode},smalltalk.Interpreter)})},
  2024. messageSends: ["returnValue:", "eval:", "source"]}),
  2025. smalltalk.Interpreter);
  2026. smalltalk.addMethod(
  2027. smalltalk.method({
  2028. selector: "visitNode:",
  2029. fn: function (aNode){
  2030. var self=this;
  2031. return smalltalk.withContext(function($ctx1) {
  2032. return self}, function($ctx1) {$ctx1.fill(self,"visitNode:",{aNode:aNode},smalltalk.Interpreter)})},
  2033. messageSends: []}),
  2034. smalltalk.Interpreter);
  2035. smalltalk.addMethod(
  2036. smalltalk.method({
  2037. selector: "visitReturnNode:",
  2038. fn: function (aNode){
  2039. var self=this;
  2040. return smalltalk.withContext(function($ctx1) {
  2041. self._returnValue_(self._pop());
  2042. return self}, function($ctx1) {$ctx1.fill(self,"visitReturnNode:",{aNode:aNode},smalltalk.Interpreter)})},
  2043. messageSends: ["returnValue:", "pop"]}),
  2044. smalltalk.Interpreter);
  2045. smalltalk.addMethod(
  2046. smalltalk.method({
  2047. selector: "visitSendNode:",
  2048. fn: function (aNode){
  2049. var self=this;
  2050. var receiver,args,message,result;
  2051. return smalltalk.withContext(function($ctx1) {
  2052. var $1;
  2053. args=_st(_st(aNode)._arguments())._collect_((function(each){
  2054. return smalltalk.withContext(function($ctx2) {
  2055. return self._pop();
  2056. }, function($ctx2) {$ctx2.fillBlock({each:each},$ctx1,1)})}));
  2057. receiver=self._pop();
  2058. message=self._messageFromSendNode_arguments_(aNode,_st(args)._reversed());
  2059. result=self._sendMessage_to_superSend_(message,receiver,_st(aNode)._superSend());
  2060. _st(self._context())._pc_(_st(_st(self._context())._pc()).__plus((1)));
  2061. $1=_st(_st(aNode)._isCascadeSendNode())._and_((function(){
  2062. return smalltalk.withContext(function($ctx2) {
  2063. return _st(_st(aNode)._isLastChild())._not();
  2064. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)})}));
  2065. if(smalltalk.assert($1)){
  2066. self._push_(receiver);
  2067. } else {
  2068. self._push_(result);
  2069. };
  2070. return self}, function($ctx1) {$ctx1.fill(self,"visitSendNode:",{aNode:aNode,receiver:receiver,args:args,message:message,result:result},smalltalk.Interpreter)})},
  2071. messageSends: ["collect:", "arguments", "pop", "messageFromSendNode:arguments:", "reversed", "sendMessage:to:superSend:", "superSend", "pc:", "context", "+", "pc", "ifTrue:ifFalse:", "and:", "isCascadeSendNode", "not", "isLastChild", "push:"]}),
  2072. smalltalk.Interpreter);
  2073. smalltalk.addMethod(
  2074. smalltalk.method({
  2075. selector: "visitValueNode:",
  2076. fn: function (aNode){
  2077. var self=this;
  2078. return smalltalk.withContext(function($ctx1) {
  2079. self._push_(_st(aNode)._value());
  2080. return self}, function($ctx1) {$ctx1.fill(self,"visitValueNode:",{aNode:aNode},smalltalk.Interpreter)})},
  2081. messageSends: ["push:", "value"]}),
  2082. smalltalk.Interpreter);
  2083. smalltalk.addMethod(
  2084. smalltalk.method({
  2085. selector: "visitVariableNode:",
  2086. fn: function (aNode){
  2087. var self=this;
  2088. return smalltalk.withContext(function($ctx1) {
  2089. var $1,$2,$3,$5,$4;
  2090. $1=_st(_st(aNode)._binding())._isUnknownVar();
  2091. if(smalltalk.assert($1)){
  2092. $2=self._push_(_st(window)._at_ifAbsent_(_st(aNode)._value(),(function(){
  2093. return smalltalk.withContext(function($ctx2) {
  2094. return self._error_("Unknown variable");
  2095. }, function($ctx2) {$ctx2.fillBlock({},$ctx1,2)})})));
  2096. return $2;
  2097. };
  2098. $3=self;
  2099. $5=_st(_st(aNode)._binding())._isInstanceVar();
  2100. if(smalltalk.assert($5)){
  2101. $4=_st(_st(self._context())._receiver())._instVarAt_(_st(aNode)._value());
  2102. } else {
  2103. $4=_st(self._context())._localAt_(_st(aNode)._value());
  2104. };
  2105. _st($3)._push_($4);
  2106. return self}, function($ctx1) {$ctx1.fill(self,"visitVariableNode:",{aNode:aNode},smalltalk.Interpreter)})},
  2107. messageSends: ["ifTrue:", "isUnknownVar", "binding", "push:", "at:ifAbsent:", "value", "error:", "ifTrue:ifFalse:", "isInstanceVar", "instVarAt:", "receiver", "context", "localAt:"]}),
  2108. smalltalk.Interpreter);
  2109. smalltalk.addMethod(
  2110. smalltalk.method({
  2111. selector: "interpreter:continue:",
  2112. fn: function (anInterpreter,aBlock){
  2113. var self=this;
  2114. return smalltalk.withContext(function($ctx1) {
  2115. var $1;
  2116. $1=_st(anInterpreter)._interpretNode_continue_(self,aBlock);
  2117. return $1;
  2118. }, function($ctx1) {$ctx1.fill(self,"interpreter:continue:",{anInterpreter:anInterpreter,aBlock:aBlock},smalltalk.Node)})},
  2119. messageSends: ["interpretNode:continue:"]}),
  2120. smalltalk.Node);
  2121. smalltalk.addMethod(
  2122. smalltalk.method({
  2123. selector: "isSteppingNode",
  2124. fn: function (){
  2125. var self=this;
  2126. return smalltalk.withContext(function($ctx1) {
  2127. return false;
  2128. }, function($ctx1) {$ctx1.fill(self,"isSteppingNode",{},smalltalk.Node)})},
  2129. messageSends: []}),
  2130. smalltalk.Node);
  2131. smalltalk.addMethod(
  2132. smalltalk.method({
  2133. selector: "interpreter:continue:",
  2134. fn: function (anInterpreter,aBlock){
  2135. var self=this;
  2136. return smalltalk.withContext(function($ctx1) {
  2137. var $1;
  2138. $1=_st(anInterpreter)._interpretAssignmentNode_continue_(self,aBlock);
  2139. return $1;
  2140. }, function($ctx1) {$ctx1.fill(self,"interpreter:continue:",{anInterpreter:anInterpreter,aBlock:aBlock},smalltalk.AssignmentNode)})},
  2141. messageSends: ["interpretAssignmentNode:continue:"]}),
  2142. smalltalk.AssignmentNode);
  2143. smalltalk.addMethod(
  2144. smalltalk.method({
  2145. selector: "isSteppingNode",
  2146. fn: function (){
  2147. var self=this;
  2148. return smalltalk.withContext(function($ctx1) {
  2149. return true;
  2150. }, function($ctx1) {$ctx1.fill(self,"isSteppingNode",{},smalltalk.AssignmentNode)})},
  2151. messageSends: []}),
  2152. smalltalk.AssignmentNode);
  2153. smalltalk.addMethod(
  2154. smalltalk.method({
  2155. selector: "interpreter:continue:",
  2156. fn: function (anInterpreter,aBlock){
  2157. var self=this;
  2158. return smalltalk.withContext(function($ctx1) {
  2159. var $1;
  2160. $1=_st(anInterpreter)._interpretBlockNode_continue_(self,aBlock);
  2161. return $1;
  2162. }, function($ctx1) {$ctx1.fill(self,"interpreter:continue:",{anInterpreter:anInterpreter,aBlock:aBlock},smalltalk.BlockNode)})},
  2163. messageSends: ["interpretBlockNode:continue:"]}),
  2164. smalltalk.BlockNode);
  2165. smalltalk.addMethod(
  2166. smalltalk.method({
  2167. selector: "isSteppingNode",
  2168. fn: function (){
  2169. var self=this;
  2170. return smalltalk.withContext(function($ctx1) {
  2171. return true;
  2172. }, function($ctx1) {$ctx1.fill(self,"isSteppingNode",{},smalltalk.BlockNode)})},
  2173. messageSends: []}),
  2174. smalltalk.BlockNode);
  2175. smalltalk.addMethod(
  2176. smalltalk.method({
  2177. selector: "interpreter:continue:",
  2178. fn: function (anInterpreter,aBlock){
  2179. var self=this;
  2180. return smalltalk.withContext(function($ctx1) {
  2181. var $1;
  2182. $1=_st(anInterpreter)._interpretCascadeNode_continue_(self,aBlock);
  2183. return $1;
  2184. }, function($ctx1) {$ctx1.fill(self,"interpreter:continue:",{anInterpreter:anInterpreter,aBlock:aBlock},smalltalk.CascadeNode)})},
  2185. messageSends: ["interpretCascadeNode:continue:"]}),
  2186. smalltalk.CascadeNode);
  2187. smalltalk.addMethod(
  2188. smalltalk.method({
  2189. selector: "interpreter:continue:",
  2190. fn: function (anInterpreter,aBlock){
  2191. var self=this;
  2192. return smalltalk.withContext(function($ctx1) {
  2193. var $1;
  2194. $1=_st(anInterpreter)._interpretDynamicArrayNode_continue_(self,aBlock);
  2195. return $1;
  2196. }, function($ctx1) {$ctx1.fill(self,"interpreter:continue:",{anInterpreter:anInterpreter,aBlock:aBlock},smalltalk.DynamicArrayNode)})},
  2197. messageSends: ["interpretDynamicArrayNode:continue:"]}),
  2198. smalltalk.DynamicArrayNode);
  2199. smalltalk.addMethod(
  2200. smalltalk.method({
  2201. selector: "isSteppingNode",
  2202. fn: function (){
  2203. var self=this;
  2204. return smalltalk.withContext(function($ctx1) {
  2205. return true;
  2206. }, function($ctx1) {$ctx1.fill(self,"isSteppingNode",{},smalltalk.DynamicArrayNode)})},
  2207. messageSends: []}),
  2208. smalltalk.DynamicArrayNode);
  2209. smalltalk.addMethod(
  2210. smalltalk.method({
  2211. selector: "interpreter:continue:",
  2212. fn: function (anInterpreter,aBlock){
  2213. var self=this;
  2214. return smalltalk.withContext(function($ctx1) {
  2215. var $1;
  2216. $1=_st(anInterpreter)._interpretDynamicDictionaryNode_continue_(self,aBlock);
  2217. return $1;
  2218. }, function($ctx1) {$ctx1.fill(self,"interpreter:continue:",{anInterpreter:anInterpreter,aBlock:aBlock},smalltalk.DynamicDictionaryNode)})},
  2219. messageSends: ["interpretDynamicDictionaryNode:continue:"]}),
  2220. smalltalk.DynamicDictionaryNode);
  2221. smalltalk.addMethod(
  2222. smalltalk.method({
  2223. selector: "isSteppingNode",
  2224. fn: function (){
  2225. var self=this;
  2226. return smalltalk.withContext(function($ctx1) {
  2227. return true;
  2228. }, function($ctx1) {$ctx1.fill(self,"isSteppingNode",{},smalltalk.DynamicDictionaryNode)})},
  2229. messageSends: []}),
  2230. smalltalk.DynamicDictionaryNode);
  2231. smalltalk.addMethod(
  2232. smalltalk.method({
  2233. selector: "interpreter:continue:",
  2234. fn: function (anInterpreter,aBlock){
  2235. var self=this;
  2236. return smalltalk.withContext(function($ctx1) {
  2237. var $1;
  2238. $1=_st(anInterpreter)._interpretJSStatementNode_continue_(self,aBlock);
  2239. return $1;
  2240. }, function($ctx1) {$ctx1.fill(self,"interpreter:continue:",{anInterpreter:anInterpreter,aBlock:aBlock},smalltalk.JSStatementNode)})},
  2241. messageSends: ["interpretJSStatementNode:continue:"]}),
  2242. smalltalk.JSStatementNode);
  2243. smalltalk.addMethod(
  2244. smalltalk.method({
  2245. selector: "isSteppingNode",
  2246. fn: function (){
  2247. var self=this;
  2248. return smalltalk.withContext(function($ctx1) {
  2249. return true;
  2250. }, function($ctx1) {$ctx1.fill(self,"isSteppingNode",{},smalltalk.JSStatementNode)})},
  2251. messageSends: []}),
  2252. smalltalk.JSStatementNode);
  2253. smalltalk.addMethod(
  2254. smalltalk.method({
  2255. selector: "interpreter:continue:",
  2256. fn: function (anInterpreter,aBlock){
  2257. var self=this;
  2258. return smalltalk.withContext(function($ctx1) {
  2259. var $1;
  2260. $1=_st(anInterpreter)._interpretMethodNode_continue_(self,aBlock);
  2261. return $1;
  2262. }, function($ctx1) {$ctx1.fill(self,"interpreter:continue:",{anInterpreter:anInterpreter,aBlock:aBlock},smalltalk.MethodNode)})},
  2263. messageSends: ["interpretMethodNode:continue:"]}),
  2264. smalltalk.MethodNode);
  2265. smalltalk.addMethod(
  2266. smalltalk.method({
  2267. selector: "interpreter:continue:",
  2268. fn: function (anInterpreter,aBlock){
  2269. var self=this;
  2270. return smalltalk.withContext(function($ctx1) {
  2271. var $1;
  2272. $1=_st(anInterpreter)._interpretReturnNode_continue_(self,aBlock);
  2273. return $1;
  2274. }, function($ctx1) {$ctx1.fill(self,"interpreter:continue:",{anInterpreter:anInterpreter,aBlock:aBlock},smalltalk.ReturnNode)})},
  2275. messageSends: ["interpretReturnNode:continue:"]}),
  2276. smalltalk.ReturnNode);
  2277. smalltalk.addMethod(
  2278. smalltalk.method({
  2279. selector: "interpreter:continue:",
  2280. fn: function (anInterpreter,aBlock){
  2281. var self=this;
  2282. return smalltalk.withContext(function($ctx1) {
  2283. var $1;
  2284. $1=_st(anInterpreter)._interpretSendNode_continue_(self,aBlock);
  2285. return $1;
  2286. }, function($ctx1) {$ctx1.fill(self,"interpreter:continue:",{anInterpreter:anInterpreter,aBlock:aBlock},smalltalk.SendNode)})},
  2287. messageSends: ["interpretSendNode:continue:"]}),
  2288. smalltalk.SendNode);
  2289. smalltalk.addMethod(
  2290. smalltalk.method({
  2291. selector: "isSteppingNode",
  2292. fn: function (){
  2293. var self=this;
  2294. return smalltalk.withContext(function($ctx1) {
  2295. return true;
  2296. }, function($ctx1) {$ctx1.fill(self,"isSteppingNode",{},smalltalk.SendNode)})},
  2297. messageSends: []}),
  2298. smalltalk.SendNode);
  2299. smalltalk.addMethod(
  2300. smalltalk.method({
  2301. selector: "interpreter:continue:",
  2302. fn: function (anInterpreter,aBlock){
  2303. var self=this;
  2304. return smalltalk.withContext(function($ctx1) {
  2305. var $1;
  2306. $1=_st(anInterpreter)._interpretSequenceNode_continue_(self,aBlock);
  2307. return $1;
  2308. }, function($ctx1) {$ctx1.fill(self,"interpreter:continue:",{anInterpreter:anInterpreter,aBlock:aBlock},smalltalk.SequenceNode)})},
  2309. messageSends: ["interpretSequenceNode:continue:"]}),
  2310. smalltalk.SequenceNode);
  2311. smalltalk.addMethod(
  2312. smalltalk.method({
  2313. selector: "interpreter:continue:",
  2314. fn: function (anInterpreter,aBlock){
  2315. var self=this;
  2316. return smalltalk.withContext(function($ctx1) {
  2317. var $1;
  2318. $1=_st(anInterpreter)._interpretBlockSequenceNode_continue_(self,aBlock);
  2319. return $1;
  2320. }, function($ctx1) {$ctx1.fill(self,"interpreter:continue:",{anInterpreter:anInterpreter,aBlock:aBlock},smalltalk.BlockSequenceNode)})},
  2321. messageSends: ["interpretBlockSequenceNode:continue:"]}),
  2322. smalltalk.BlockSequenceNode);
  2323. smalltalk.addMethod(
  2324. smalltalk.method({
  2325. selector: "interpreter:continue:",
  2326. fn: function (anInterpreter,aBlock){
  2327. var self=this;
  2328. return smalltalk.withContext(function($ctx1) {
  2329. var $1;
  2330. $1=_st(anInterpreter)._interpretValueNode_continue_(self,aBlock);
  2331. return $1;
  2332. }, function($ctx1) {$ctx1.fill(self,"interpreter:continue:",{anInterpreter:anInterpreter,aBlock:aBlock},smalltalk.ValueNode)})},
  2333. messageSends: ["interpretValueNode:continue:"]}),
  2334. smalltalk.ValueNode);
  2335. smalltalk.addMethod(
  2336. smalltalk.method({
  2337. selector: "interpreter:continue:",
  2338. fn: function (anInterpreter,aBlock){
  2339. var self=this;
  2340. return smalltalk.withContext(function($ctx1) {
  2341. var $1;
  2342. $1=_st(anInterpreter)._interpretVariableNode_continue_(self,aBlock);
  2343. return $1;
  2344. }, function($ctx1) {$ctx1.fill(self,"interpreter:continue:",{anInterpreter:anInterpreter,aBlock:aBlock},smalltalk.VariableNode)})},
  2345. messageSends: ["interpretVariableNode:continue:"]}),
  2346. smalltalk.VariableNode);
  2347. smalltalk.addMethod(
  2348. smalltalk.method({
  2349. selector: "interpreter:continue:",
  2350. fn: function (anInterpreter,aBlock){
  2351. var self=this;
  2352. return smalltalk.withContext(function($ctx1) {
  2353. var $1;
  2354. $1=_st(anInterpreter)._interpretClassReferenceNode_continue_(self,aBlock);
  2355. return $1;
  2356. }, function($ctx1) {$ctx1.fill(self,"interpreter:continue:",{anInterpreter:anInterpreter,aBlock:aBlock},smalltalk.ClassReferenceNode)})},
  2357. messageSends: ["interpretClassReferenceNode:continue:"]}),
  2358. smalltalk.ClassReferenceNode);