Compiler-Interpreter.deploy.js 88 KB

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