amber.js 692 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351535253535354535553565357535853595360536153625363536453655366536753685369537053715372537353745375537653775378537953805381538253835384538553865387538853895390539153925393539453955396539753985399540054015402540354045405540654075408540954105411541254135414541554165417541854195420542154225423542454255426542754285429543054315432543354345435543654375438543954405441544254435444544554465447544854495450545154525453545454555456545754585459546054615462546354645465546654675468546954705471547254735474547554765477547854795480548154825483548454855486548754885489549054915492549354945495549654975498549955005501550255035504550555065507550855095510551155125513551455155516551755185519552055215522552355245525552655275528552955305531553255335534553555365537553855395540554155425543554455455546554755485549555055515552555355545555555655575558555955605561556255635564556555665567556855695570557155725573557455755576557755785579558055815582558355845585558655875588558955905591559255935594559555965597559855995600560156025603560456055606560756085609561056115612561356145615561656175618561956205621562256235624562556265627562856295630563156325633563456355636563756385639564056415642564356445645564656475648564956505651565256535654565556565657565856595660566156625663566456655666566756685669567056715672567356745675567656775678567956805681568256835684568556865687568856895690569156925693569456955696569756985699570057015702570357045705570657075708570957105711571257135714571557165717571857195720572157225723572457255726572757285729573057315732573357345735573657375738573957405741574257435744574557465747574857495750575157525753575457555756575757585759576057615762576357645765576657675768576957705771577257735774577557765777577857795780578157825783578457855786578757885789579057915792579357945795579657975798579958005801580258035804580558065807580858095810581158125813581458155816581758185819582058215822582358245825582658275828582958305831583258335834583558365837583858395840584158425843584458455846584758485849585058515852585358545855585658575858585958605861586258635864586558665867586858695870587158725873587458755876587758785879588058815882588358845885588658875888588958905891589258935894589558965897589858995900590159025903590459055906590759085909591059115912591359145915591659175918591959205921592259235924592559265927592859295930593159325933593459355936593759385939594059415942594359445945594659475948594959505951595259535954595559565957595859595960596159625963596459655966596759685969597059715972597359745975597659775978597959805981598259835984598559865987598859895990599159925993599459955996599759985999600060016002600360046005600660076008600960106011601260136014601560166017601860196020602160226023602460256026602760286029603060316032603360346035603660376038603960406041604260436044604560466047604860496050605160526053605460556056605760586059606060616062606360646065606660676068606960706071607260736074607560766077607860796080608160826083608460856086608760886089609060916092609360946095609660976098609961006101610261036104610561066107610861096110611161126113611461156116611761186119612061216122612361246125612661276128612961306131613261336134613561366137613861396140614161426143614461456146614761486149615061516152615361546155615661576158615961606161616261636164616561666167616861696170617161726173617461756176617761786179618061816182618361846185618661876188618961906191619261936194619561966197619861996200620162026203620462056206620762086209621062116212621362146215621662176218621962206221622262236224622562266227622862296230623162326233623462356236623762386239624062416242624362446245624662476248624962506251625262536254625562566257625862596260626162626263626462656266626762686269627062716272627362746275627662776278627962806281628262836284628562866287628862896290629162926293629462956296629762986299630063016302630363046305630663076308630963106311631263136314631563166317631863196320632163226323632463256326632763286329633063316332633363346335633663376338633963406341634263436344634563466347634863496350635163526353635463556356635763586359636063616362636363646365636663676368636963706371637263736374637563766377637863796380638163826383638463856386638763886389639063916392639363946395639663976398639964006401640264036404640564066407640864096410641164126413641464156416641764186419642064216422642364246425642664276428642964306431643264336434643564366437643864396440644164426443644464456446644764486449645064516452645364546455645664576458645964606461646264636464646564666467646864696470647164726473647464756476647764786479648064816482648364846485648664876488648964906491649264936494649564966497649864996500650165026503650465056506650765086509651065116512651365146515651665176518651965206521652265236524652565266527652865296530653165326533653465356536653765386539654065416542654365446545654665476548654965506551655265536554655565566557655865596560656165626563656465656566656765686569657065716572657365746575657665776578657965806581658265836584658565866587658865896590659165926593659465956596659765986599660066016602660366046605660666076608660966106611661266136614661566166617661866196620662166226623662466256626662766286629663066316632663366346635663666376638663966406641664266436644664566466647664866496650665166526653665466556656665766586659666066616662666366646665666666676668666966706671667266736674667566766677667866796680668166826683668466856686668766886689669066916692669366946695669666976698669967006701670267036704670567066707670867096710671167126713671467156716671767186719672067216722672367246725672667276728672967306731673267336734673567366737673867396740674167426743674467456746674767486749675067516752675367546755675667576758675967606761676267636764676567666767676867696770677167726773677467756776677767786779678067816782678367846785678667876788678967906791679267936794679567966797679867996800680168026803680468056806680768086809681068116812681368146815681668176818681968206821682268236824682568266827682868296830683168326833683468356836683768386839684068416842684368446845684668476848684968506851685268536854685568566857685868596860686168626863686468656866686768686869687068716872687368746875687668776878687968806881688268836884688568866887688868896890689168926893689468956896689768986899690069016902690369046905690669076908690969106911691269136914691569166917691869196920692169226923692469256926692769286929693069316932693369346935693669376938693969406941694269436944694569466947694869496950695169526953695469556956695769586959696069616962696369646965696669676968696969706971697269736974697569766977697869796980698169826983698469856986698769886989699069916992699369946995699669976998699970007001700270037004700570067007700870097010701170127013701470157016701770187019702070217022702370247025702670277028702970307031703270337034703570367037703870397040704170427043704470457046704770487049705070517052705370547055705670577058705970607061706270637064706570667067706870697070707170727073707470757076707770787079708070817082708370847085708670877088708970907091709270937094709570967097709870997100710171027103710471057106710771087109711071117112711371147115711671177118711971207121712271237124712571267127712871297130713171327133713471357136713771387139714071417142714371447145714671477148714971507151715271537154715571567157715871597160716171627163716471657166716771687169717071717172717371747175717671777178717971807181718271837184718571867187718871897190719171927193719471957196719771987199720072017202720372047205720672077208720972107211721272137214721572167217721872197220722172227223722472257226722772287229723072317232723372347235723672377238723972407241724272437244724572467247724872497250725172527253725472557256725772587259726072617262726372647265726672677268726972707271727272737274727572767277727872797280728172827283728472857286728772887289729072917292729372947295729672977298729973007301730273037304730573067307730873097310731173127313731473157316731773187319732073217322732373247325732673277328732973307331733273337334733573367337733873397340734173427343734473457346734773487349735073517352735373547355735673577358735973607361736273637364736573667367736873697370737173727373737473757376737773787379738073817382738373847385738673877388738973907391739273937394739573967397739873997400740174027403740474057406740774087409741074117412741374147415741674177418741974207421742274237424742574267427742874297430743174327433743474357436743774387439744074417442744374447445744674477448744974507451745274537454745574567457745874597460746174627463746474657466746774687469747074717472747374747475747674777478747974807481748274837484748574867487748874897490749174927493749474957496749774987499750075017502750375047505750675077508750975107511751275137514751575167517751875197520752175227523752475257526752775287529753075317532753375347535753675377538753975407541754275437544754575467547754875497550755175527553755475557556755775587559756075617562756375647565756675677568756975707571757275737574757575767577757875797580758175827583758475857586758775887589759075917592759375947595759675977598759976007601760276037604760576067607760876097610761176127613761476157616761776187619762076217622762376247625762676277628762976307631763276337634763576367637763876397640764176427643764476457646764776487649765076517652765376547655765676577658765976607661766276637664766576667667766876697670767176727673767476757676767776787679768076817682768376847685768676877688768976907691769276937694769576967697769876997700770177027703770477057706770777087709771077117712771377147715771677177718771977207721772277237724772577267727772877297730773177327733773477357736773777387739774077417742774377447745774677477748774977507751775277537754775577567757775877597760776177627763776477657766776777687769777077717772777377747775777677777778777977807781778277837784778577867787778877897790779177927793779477957796779777987799780078017802780378047805780678077808780978107811781278137814781578167817781878197820782178227823782478257826782778287829783078317832783378347835783678377838783978407841784278437844784578467847784878497850785178527853785478557856785778587859786078617862786378647865786678677868786978707871787278737874787578767877787878797880788178827883788478857886788778887889789078917892789378947895789678977898789979007901790279037904790579067907790879097910791179127913791479157916791779187919792079217922792379247925792679277928792979307931793279337934793579367937793879397940794179427943794479457946794779487949795079517952795379547955795679577958795979607961796279637964796579667967796879697970797179727973797479757976797779787979798079817982798379847985798679877988798979907991799279937994799579967997799879998000800180028003800480058006800780088009801080118012801380148015801680178018801980208021802280238024802580268027802880298030803180328033803480358036803780388039804080418042804380448045804680478048804980508051805280538054805580568057805880598060806180628063806480658066806780688069807080718072807380748075807680778078807980808081808280838084808580868087808880898090809180928093809480958096809780988099810081018102810381048105810681078108810981108111811281138114811581168117811881198120812181228123812481258126812781288129813081318132813381348135813681378138813981408141814281438144814581468147814881498150815181528153815481558156815781588159816081618162816381648165816681678168816981708171817281738174817581768177817881798180818181828183818481858186818781888189819081918192819381948195819681978198819982008201820282038204820582068207820882098210821182128213821482158216821782188219822082218222822382248225822682278228822982308231823282338234823582368237823882398240824182428243824482458246824782488249825082518252825382548255825682578258825982608261826282638264826582668267826882698270827182728273827482758276827782788279828082818282828382848285828682878288828982908291829282938294829582968297829882998300830183028303830483058306830783088309831083118312831383148315831683178318831983208321832283238324832583268327832883298330833183328333833483358336833783388339834083418342834383448345834683478348834983508351835283538354835583568357835883598360836183628363836483658366836783688369837083718372837383748375837683778378837983808381838283838384838583868387838883898390839183928393839483958396839783988399840084018402840384048405840684078408840984108411841284138414841584168417841884198420842184228423842484258426842784288429843084318432843384348435843684378438843984408441844284438444844584468447844884498450845184528453845484558456845784588459846084618462846384648465846684678468846984708471847284738474847584768477847884798480848184828483848484858486848784888489849084918492849384948495849684978498849985008501850285038504850585068507850885098510851185128513851485158516851785188519852085218522852385248525852685278528852985308531853285338534853585368537853885398540854185428543854485458546854785488549855085518552855385548555855685578558855985608561856285638564856585668567856885698570857185728573857485758576857785788579858085818582858385848585858685878588858985908591859285938594859585968597859885998600860186028603860486058606860786088609861086118612861386148615861686178618861986208621862286238624862586268627862886298630863186328633863486358636863786388639864086418642864386448645864686478648864986508651865286538654865586568657865886598660866186628663866486658666866786688669867086718672867386748675867686778678867986808681868286838684868586868687868886898690869186928693869486958696869786988699870087018702870387048705870687078708870987108711871287138714871587168717871887198720872187228723872487258726872787288729873087318732873387348735873687378738873987408741874287438744874587468747874887498750875187528753875487558756875787588759876087618762876387648765876687678768876987708771877287738774877587768777877887798780878187828783878487858786878787888789879087918792879387948795879687978798879988008801880288038804880588068807880888098810881188128813881488158816881788188819882088218822882388248825882688278828882988308831883288338834883588368837883888398840884188428843884488458846884788488849885088518852885388548855885688578858885988608861886288638864886588668867886888698870887188728873887488758876887788788879888088818882888388848885888688878888888988908891889288938894889588968897889888998900890189028903890489058906890789088909891089118912891389148915891689178918891989208921892289238924892589268927892889298930893189328933893489358936893789388939894089418942894389448945894689478948894989508951895289538954895589568957895889598960896189628963896489658966896789688969897089718972897389748975897689778978897989808981898289838984898589868987898889898990899189928993899489958996899789988999900090019002900390049005900690079008900990109011901290139014901590169017901890199020902190229023902490259026902790289029903090319032903390349035903690379038903990409041904290439044904590469047904890499050905190529053905490559056905790589059906090619062906390649065906690679068906990709071907290739074907590769077907890799080908190829083908490859086908790889089909090919092909390949095909690979098909991009101910291039104910591069107910891099110911191129113911491159116911791189119912091219122912391249125912691279128912991309131913291339134913591369137913891399140914191429143914491459146914791489149915091519152915391549155915691579158915991609161916291639164916591669167916891699170917191729173917491759176917791789179918091819182918391849185918691879188918991909191919291939194919591969197919891999200920192029203920492059206920792089209921092119212921392149215921692179218921992209221922292239224922592269227922892299230923192329233923492359236923792389239924092419242924392449245924692479248924992509251925292539254925592569257925892599260926192629263926492659266926792689269927092719272927392749275927692779278927992809281928292839284928592869287928892899290929192929293929492959296929792989299930093019302930393049305930693079308930993109311931293139314931593169317931893199320932193229323932493259326932793289329933093319332933393349335933693379338933993409341934293439344934593469347934893499350935193529353935493559356935793589359936093619362936393649365936693679368936993709371937293739374937593769377937893799380938193829383938493859386938793889389939093919392939393949395939693979398939994009401940294039404940594069407940894099410941194129413941494159416941794189419942094219422942394249425942694279428942994309431943294339434943594369437943894399440944194429443944494459446944794489449945094519452945394549455945694579458945994609461946294639464946594669467946894699470947194729473947494759476947794789479948094819482948394849485948694879488948994909491949294939494949594969497949894999500950195029503950495059506950795089509951095119512951395149515951695179518951995209521952295239524952595269527952895299530953195329533953495359536953795389539954095419542954395449545954695479548954995509551955295539554955595569557955895599560956195629563956495659566956795689569957095719572957395749575957695779578957995809581958295839584958595869587958895899590959195929593959495959596959795989599960096019602960396049605960696079608960996109611961296139614961596169617961896199620962196229623962496259626962796289629963096319632963396349635963696379638963996409641964296439644964596469647964896499650965196529653965496559656965796589659966096619662966396649665966696679668966996709671967296739674967596769677967896799680968196829683968496859686968796889689969096919692969396949695969696979698969997009701970297039704970597069707970897099710971197129713971497159716971797189719972097219722972397249725972697279728972997309731973297339734973597369737973897399740974197429743974497459746974797489749975097519752975397549755975697579758975997609761976297639764976597669767976897699770977197729773977497759776977797789779978097819782978397849785978697879788978997909791979297939794979597969797979897999800980198029803980498059806980798089809981098119812981398149815981698179818981998209821982298239824982598269827982898299830983198329833983498359836983798389839984098419842984398449845984698479848984998509851985298539854985598569857985898599860986198629863986498659866986798689869987098719872987398749875987698779878987998809881988298839884988598869887988898899890989198929893989498959896989798989899990099019902990399049905990699079908990999109911991299139914991599169917991899199920992199229923992499259926992799289929993099319932993399349935993699379938993999409941994299439944994599469947994899499950995199529953995499559956995799589959996099619962996399649965996699679968996999709971997299739974997599769977997899799980998199829983998499859986998799889989999099919992999399949995999699979998999910000100011000210003100041000510006100071000810009100101001110012100131001410015100161001710018100191002010021100221002310024100251002610027100281002910030100311003210033100341003510036100371003810039100401004110042100431004410045100461004710048100491005010051100521005310054100551005610057100581005910060100611006210063100641006510066100671006810069100701007110072100731007410075100761007710078100791008010081100821008310084100851008610087100881008910090100911009210093100941009510096100971009810099101001010110102101031010410105101061010710108101091011010111101121011310114101151011610117101181011910120101211012210123101241012510126101271012810129101301013110132101331013410135101361013710138101391014010141101421014310144101451014610147101481014910150101511015210153101541015510156101571015810159101601016110162101631016410165101661016710168101691017010171101721017310174101751017610177101781017910180101811018210183101841018510186101871018810189101901019110192101931019410195101961019710198101991020010201102021020310204102051020610207102081020910210102111021210213102141021510216102171021810219102201022110222102231022410225102261022710228102291023010231102321023310234102351023610237102381023910240102411024210243102441024510246102471024810249102501025110252102531025410255102561025710258102591026010261102621026310264102651026610267102681026910270102711027210273102741027510276102771027810279102801028110282102831028410285102861028710288102891029010291102921029310294102951029610297102981029910300103011030210303103041030510306103071030810309103101031110312103131031410315103161031710318103191032010321103221032310324103251032610327103281032910330103311033210333103341033510336103371033810339103401034110342103431034410345103461034710348103491035010351103521035310354103551035610357103581035910360103611036210363103641036510366103671036810369103701037110372103731037410375103761037710378103791038010381103821038310384103851038610387103881038910390103911039210393103941039510396103971039810399104001040110402104031040410405104061040710408104091041010411104121041310414104151041610417104181041910420104211042210423104241042510426104271042810429104301043110432104331043410435104361043710438104391044010441104421044310444104451044610447104481044910450104511045210453104541045510456104571045810459104601046110462104631046410465104661046710468104691047010471104721047310474104751047610477104781047910480104811048210483104841048510486104871048810489104901049110492104931049410495104961049710498104991050010501105021050310504105051050610507105081050910510105111051210513105141051510516105171051810519105201052110522105231052410525105261052710528105291053010531105321053310534105351053610537105381053910540105411054210543105441054510546105471054810549105501055110552105531055410555105561055710558105591056010561105621056310564105651056610567105681056910570105711057210573105741057510576105771057810579105801058110582105831058410585105861058710588105891059010591105921059310594105951059610597105981059910600106011060210603106041060510606106071060810609106101061110612106131061410615106161061710618106191062010621106221062310624106251062610627106281062910630106311063210633106341063510636106371063810639106401064110642106431064410645106461064710648106491065010651106521065310654106551065610657106581065910660106611066210663106641066510666106671066810669106701067110672106731067410675106761067710678106791068010681106821068310684106851068610687106881068910690106911069210693106941069510696106971069810699107001070110702107031070410705107061070710708107091071010711107121071310714107151071610717107181071910720107211072210723107241072510726107271072810729107301073110732107331073410735107361073710738107391074010741107421074310744107451074610747107481074910750107511075210753107541075510756107571075810759107601076110762107631076410765107661076710768107691077010771107721077310774107751077610777107781077910780107811078210783107841078510786107871078810789107901079110792107931079410795107961079710798107991080010801108021080310804108051080610807108081080910810108111081210813108141081510816108171081810819108201082110822108231082410825108261082710828108291083010831108321083310834108351083610837108381083910840108411084210843108441084510846108471084810849108501085110852108531085410855108561085710858108591086010861108621086310864108651086610867108681086910870108711087210873108741087510876108771087810879108801088110882108831088410885108861088710888108891089010891108921089310894108951089610897108981089910900109011090210903109041090510906109071090810909109101091110912109131091410915109161091710918109191092010921109221092310924109251092610927109281092910930109311093210933109341093510936109371093810939109401094110942109431094410945109461094710948109491095010951109521095310954109551095610957109581095910960109611096210963109641096510966109671096810969109701097110972109731097410975109761097710978109791098010981109821098310984109851098610987109881098910990109911099210993109941099510996109971099810999110001100111002110031100411005110061100711008110091101011011110121101311014110151101611017110181101911020110211102211023110241102511026110271102811029110301103111032110331103411035110361103711038110391104011041110421104311044110451104611047110481104911050110511105211053110541105511056110571105811059110601106111062110631106411065110661106711068110691107011071110721107311074110751107611077110781107911080110811108211083110841108511086110871108811089110901109111092110931109411095110961109711098110991110011101111021110311104111051110611107111081110911110111111111211113111141111511116111171111811119111201112111122111231112411125111261112711128111291113011131111321113311134111351113611137111381113911140111411114211143111441114511146111471114811149111501115111152111531115411155111561115711158111591116011161111621116311164111651116611167111681116911170111711117211173111741117511176111771117811179111801118111182111831118411185111861118711188111891119011191111921119311194111951119611197111981119911200112011120211203112041120511206112071120811209112101121111212112131121411215112161121711218112191122011221112221122311224112251122611227112281122911230112311123211233112341123511236112371123811239112401124111242112431124411245112461124711248112491125011251112521125311254112551125611257112581125911260112611126211263112641126511266112671126811269112701127111272112731127411275112761127711278112791128011281112821128311284112851128611287112881128911290112911129211293112941129511296112971129811299113001130111302113031130411305113061130711308113091131011311113121131311314113151131611317113181131911320113211132211323113241132511326113271132811329113301133111332113331133411335113361133711338113391134011341113421134311344113451134611347113481134911350113511135211353113541135511356113571135811359113601136111362113631136411365113661136711368113691137011371113721137311374113751137611377113781137911380113811138211383113841138511386113871138811389113901139111392113931139411395113961139711398113991140011401114021140311404114051140611407114081140911410114111141211413114141141511416114171141811419114201142111422114231142411425114261142711428114291143011431114321143311434114351143611437114381143911440114411144211443114441144511446114471144811449114501145111452114531145411455114561145711458114591146011461114621146311464114651146611467114681146911470114711147211473114741147511476114771147811479114801148111482114831148411485114861148711488114891149011491114921149311494114951149611497114981149911500115011150211503115041150511506115071150811509115101151111512115131151411515115161151711518115191152011521115221152311524115251152611527115281152911530115311153211533115341153511536115371153811539115401154111542115431154411545115461154711548115491155011551115521155311554115551155611557115581155911560115611156211563115641156511566115671156811569115701157111572115731157411575115761157711578115791158011581115821158311584115851158611587115881158911590115911159211593115941159511596115971159811599116001160111602116031160411605116061160711608116091161011611116121161311614116151161611617116181161911620116211162211623116241162511626116271162811629116301163111632116331163411635116361163711638116391164011641116421164311644116451164611647116481164911650116511165211653116541165511656116571165811659116601166111662116631166411665116661166711668116691167011671116721167311674116751167611677116781167911680116811168211683116841168511686116871168811689116901169111692116931169411695116961169711698116991170011701117021170311704117051170611707117081170911710117111171211713117141171511716117171171811719117201172111722117231172411725117261172711728117291173011731117321173311734117351173611737117381173911740117411174211743117441174511746117471174811749117501175111752117531175411755117561175711758117591176011761117621176311764117651176611767117681176911770117711177211773117741177511776117771177811779117801178111782117831178411785117861178711788117891179011791117921179311794117951179611797117981179911800118011180211803118041180511806118071180811809118101181111812118131181411815118161181711818118191182011821118221182311824118251182611827118281182911830118311183211833118341183511836118371183811839118401184111842118431184411845118461184711848118491185011851118521185311854118551185611857118581185911860118611186211863118641186511866118671186811869118701187111872118731187411875118761187711878118791188011881118821188311884118851188611887118881188911890118911189211893118941189511896118971189811899119001190111902119031190411905119061190711908119091191011911119121191311914119151191611917119181191911920119211192211923119241192511926119271192811929119301193111932119331193411935119361193711938119391194011941119421194311944119451194611947119481194911950119511195211953119541195511956119571195811959119601196111962119631196411965119661196711968119691197011971119721197311974119751197611977119781197911980119811198211983119841198511986119871198811989119901199111992119931199411995119961199711998119991200012001120021200312004120051200612007120081200912010120111201212013120141201512016120171201812019120201202112022120231202412025120261202712028120291203012031120321203312034120351203612037120381203912040120411204212043120441204512046120471204812049120501205112052120531205412055120561205712058120591206012061120621206312064120651206612067120681206912070120711207212073120741207512076120771207812079120801208112082120831208412085120861208712088120891209012091120921209312094120951209612097120981209912100121011210212103121041210512106121071210812109121101211112112121131211412115121161211712118121191212012121121221212312124121251212612127121281212912130121311213212133121341213512136121371213812139121401214112142121431214412145121461214712148121491215012151121521215312154121551215612157121581215912160121611216212163121641216512166121671216812169121701217112172121731217412175121761217712178121791218012181121821218312184121851218612187121881218912190121911219212193121941219512196121971219812199122001220112202122031220412205122061220712208122091221012211122121221312214122151221612217122181221912220122211222212223122241222512226122271222812229122301223112232122331223412235122361223712238122391224012241122421224312244122451224612247122481224912250122511225212253122541225512256122571225812259122601226112262122631226412265122661226712268122691227012271122721227312274122751227612277122781227912280122811228212283122841228512286122871228812289122901229112292122931229412295122961229712298122991230012301123021230312304123051230612307123081230912310123111231212313123141231512316123171231812319123201232112322123231232412325123261232712328123291233012331123321233312334123351233612337123381233912340123411234212343123441234512346123471234812349123501235112352123531235412355123561235712358123591236012361123621236312364123651236612367123681236912370123711237212373123741237512376123771237812379123801238112382123831238412385123861238712388123891239012391123921239312394123951239612397123981239912400124011240212403124041240512406124071240812409124101241112412124131241412415124161241712418124191242012421124221242312424124251242612427124281242912430124311243212433124341243512436124371243812439124401244112442124431244412445124461244712448124491245012451124521245312454124551245612457124581245912460124611246212463124641246512466124671246812469124701247112472124731247412475124761247712478124791248012481124821248312484124851248612487124881248912490124911249212493124941249512496124971249812499125001250112502125031250412505125061250712508125091251012511125121251312514125151251612517125181251912520125211252212523125241252512526125271252812529125301253112532125331253412535125361253712538125391254012541125421254312544125451254612547125481254912550125511255212553125541255512556125571255812559125601256112562125631256412565125661256712568125691257012571125721257312574125751257612577125781257912580125811258212583125841258512586125871258812589125901259112592125931259412595125961259712598125991260012601126021260312604126051260612607126081260912610126111261212613126141261512616126171261812619126201262112622126231262412625126261262712628126291263012631126321263312634126351263612637126381263912640126411264212643126441264512646126471264812649126501265112652126531265412655126561265712658126591266012661126621266312664126651266612667126681266912670126711267212673126741267512676126771267812679126801268112682126831268412685126861268712688126891269012691126921269312694126951269612697126981269912700127011270212703127041270512706127071270812709127101271112712127131271412715127161271712718127191272012721127221272312724127251272612727127281272912730127311273212733127341273512736127371273812739127401274112742127431274412745127461274712748127491275012751127521275312754127551275612757127581275912760127611276212763127641276512766127671276812769127701277112772127731277412775127761277712778127791278012781127821278312784127851278612787127881278912790127911279212793127941279512796127971279812799128001280112802128031280412805128061280712808128091281012811128121281312814128151281612817128181281912820128211282212823128241282512826128271282812829128301283112832128331283412835128361283712838128391284012841128421284312844128451284612847128481284912850128511285212853128541285512856128571285812859128601286112862128631286412865128661286712868128691287012871128721287312874128751287612877128781287912880128811288212883128841288512886128871288812889128901289112892128931289412895128961289712898128991290012901129021290312904129051290612907129081290912910129111291212913129141291512916129171291812919129201292112922129231292412925129261292712928129291293012931129321293312934129351293612937129381293912940129411294212943129441294512946129471294812949129501295112952129531295412955129561295712958129591296012961129621296312964129651296612967129681296912970129711297212973129741297512976129771297812979129801298112982129831298412985129861298712988129891299012991129921299312994129951299612997129981299913000130011300213003130041300513006130071300813009130101301113012130131301413015130161301713018130191302013021130221302313024130251302613027130281302913030130311303213033130341303513036130371303813039130401304113042130431304413045130461304713048130491305013051130521305313054130551305613057130581305913060130611306213063130641306513066130671306813069130701307113072130731307413075130761307713078130791308013081130821308313084130851308613087130881308913090130911309213093130941309513096130971309813099131001310113102131031310413105131061310713108131091311013111131121311313114131151311613117131181311913120131211312213123131241312513126131271312813129131301313113132131331313413135131361313713138131391314013141131421314313144131451314613147131481314913150131511315213153131541315513156131571315813159131601316113162131631316413165131661316713168131691317013171131721317313174131751317613177131781317913180131811318213183131841318513186131871318813189131901319113192131931319413195131961319713198131991320013201132021320313204132051320613207132081320913210132111321213213132141321513216132171321813219132201322113222132231322413225132261322713228132291323013231132321323313234132351323613237132381323913240132411324213243132441324513246132471324813249132501325113252132531325413255132561325713258132591326013261132621326313264132651326613267132681326913270132711327213273132741327513276132771327813279132801328113282132831328413285132861328713288132891329013291132921329313294132951329613297132981329913300133011330213303133041330513306133071330813309133101331113312133131331413315133161331713318133191332013321133221332313324133251332613327133281332913330133311333213333133341333513336133371333813339133401334113342133431334413345133461334713348133491335013351133521335313354133551335613357133581335913360133611336213363133641336513366133671336813369133701337113372133731337413375133761337713378133791338013381133821338313384133851338613387133881338913390133911339213393133941339513396133971339813399134001340113402134031340413405134061340713408134091341013411134121341313414134151341613417134181341913420134211342213423134241342513426134271342813429134301343113432134331343413435134361343713438134391344013441134421344313444134451344613447134481344913450134511345213453134541345513456134571345813459134601346113462134631346413465134661346713468134691347013471134721347313474134751347613477134781347913480134811348213483134841348513486134871348813489134901349113492134931349413495134961349713498134991350013501135021350313504135051350613507135081350913510135111351213513135141351513516135171351813519135201352113522135231352413525135261352713528135291353013531135321353313534135351353613537135381353913540135411354213543135441354513546135471354813549135501355113552135531355413555135561355713558135591356013561135621356313564135651356613567135681356913570135711357213573135741357513576135771357813579135801358113582135831358413585135861358713588135891359013591135921359313594135951359613597135981359913600136011360213603136041360513606136071360813609136101361113612136131361413615136161361713618136191362013621136221362313624136251362613627136281362913630136311363213633136341363513636136371363813639136401364113642136431364413645136461364713648136491365013651136521365313654136551365613657136581365913660136611366213663136641366513666136671366813669136701367113672136731367413675136761367713678136791368013681136821368313684136851368613687136881368913690136911369213693136941369513696136971369813699137001370113702137031370413705137061370713708137091371013711137121371313714137151371613717137181371913720137211372213723137241372513726137271372813729137301373113732137331373413735137361373713738137391374013741137421374313744137451374613747137481374913750137511375213753137541375513756137571375813759137601376113762137631376413765137661376713768137691377013771137721377313774137751377613777137781377913780137811378213783137841378513786137871378813789137901379113792137931379413795137961379713798137991380013801138021380313804138051380613807138081380913810138111381213813138141381513816138171381813819138201382113822138231382413825138261382713828138291383013831138321383313834138351383613837138381383913840138411384213843138441384513846138471384813849138501385113852138531385413855138561385713858138591386013861138621386313864138651386613867138681386913870138711387213873138741387513876138771387813879138801388113882138831388413885138861388713888138891389013891138921389313894138951389613897138981389913900139011390213903139041390513906139071390813909139101391113912139131391413915139161391713918139191392013921139221392313924139251392613927139281392913930139311393213933139341393513936139371393813939139401394113942139431394413945139461394713948139491395013951139521395313954139551395613957139581395913960139611396213963139641396513966139671396813969139701397113972139731397413975139761397713978139791398013981139821398313984139851398613987139881398913990139911399213993139941399513996139971399813999140001400114002140031400414005140061400714008140091401014011140121401314014140151401614017140181401914020140211402214023140241402514026140271402814029140301403114032140331403414035140361403714038140391404014041140421404314044140451404614047140481404914050140511405214053140541405514056140571405814059140601406114062140631406414065140661406714068140691407014071140721407314074140751407614077140781407914080140811408214083140841408514086140871408814089140901409114092140931409414095140961409714098140991410014101141021410314104141051410614107141081410914110141111411214113141141411514116141171411814119141201412114122141231412414125141261412714128141291413014131141321413314134141351413614137141381413914140141411414214143141441414514146141471414814149141501415114152141531415414155141561415714158141591416014161141621416314164141651416614167141681416914170141711417214173141741417514176141771417814179141801418114182141831418414185141861418714188141891419014191141921419314194141951419614197141981419914200142011420214203142041420514206142071420814209142101421114212142131421414215142161421714218142191422014221142221422314224142251422614227142281422914230142311423214233142341423514236142371423814239142401424114242142431424414245142461424714248142491425014251142521425314254142551425614257142581425914260142611426214263142641426514266142671426814269142701427114272142731427414275142761427714278142791428014281142821428314284142851428614287142881428914290142911429214293142941429514296142971429814299143001430114302143031430414305143061430714308143091431014311143121431314314143151431614317143181431914320143211432214323143241432514326143271432814329143301433114332143331433414335143361433714338143391434014341143421434314344143451434614347143481434914350143511435214353143541435514356143571435814359143601436114362143631436414365143661436714368143691437014371143721437314374143751437614377143781437914380143811438214383143841438514386143871438814389143901439114392143931439414395143961439714398143991440014401144021440314404144051440614407144081440914410144111441214413144141441514416144171441814419144201442114422144231442414425144261442714428144291443014431144321443314434144351443614437144381443914440144411444214443144441444514446144471444814449144501445114452144531445414455144561445714458144591446014461144621446314464144651446614467144681446914470144711447214473144741447514476144771447814479144801448114482144831448414485144861448714488144891449014491144921449314494144951449614497144981449914500145011450214503145041450514506145071450814509145101451114512145131451414515145161451714518145191452014521145221452314524145251452614527145281452914530145311453214533145341453514536145371453814539145401454114542145431454414545145461454714548145491455014551145521455314554145551455614557145581455914560145611456214563145641456514566145671456814569145701457114572145731457414575145761457714578145791458014581145821458314584145851458614587145881458914590145911459214593145941459514596145971459814599146001460114602146031460414605146061460714608146091461014611146121461314614146151461614617146181461914620146211462214623146241462514626146271462814629146301463114632146331463414635146361463714638146391464014641146421464314644146451464614647146481464914650146511465214653146541465514656146571465814659146601466114662146631466414665146661466714668146691467014671146721467314674146751467614677146781467914680146811468214683146841468514686146871468814689146901469114692146931469414695146961469714698146991470014701147021470314704147051470614707147081470914710147111471214713147141471514716147171471814719147201472114722147231472414725147261472714728147291473014731147321473314734147351473614737147381473914740147411474214743147441474514746147471474814749147501475114752147531475414755147561475714758147591476014761147621476314764147651476614767147681476914770147711477214773147741477514776147771477814779147801478114782147831478414785147861478714788147891479014791147921479314794147951479614797147981479914800148011480214803148041480514806148071480814809148101481114812148131481414815148161481714818148191482014821148221482314824148251482614827148281482914830148311483214833148341483514836148371483814839148401484114842148431484414845148461484714848148491485014851148521485314854148551485614857148581485914860148611486214863148641486514866148671486814869148701487114872148731487414875148761487714878148791488014881148821488314884148851488614887148881488914890148911489214893148941489514896148971489814899149001490114902149031490414905149061490714908149091491014911149121491314914149151491614917149181491914920149211492214923149241492514926149271492814929149301493114932149331493414935149361493714938149391494014941149421494314944149451494614947149481494914950149511495214953149541495514956149571495814959149601496114962149631496414965149661496714968149691497014971149721497314974149751497614977149781497914980149811498214983149841498514986149871498814989149901499114992149931499414995149961499714998149991500015001150021500315004150051500615007150081500915010150111501215013150141501515016150171501815019150201502115022150231502415025150261502715028150291503015031150321503315034150351503615037150381503915040150411504215043150441504515046150471504815049150501505115052150531505415055150561505715058150591506015061150621506315064150651506615067150681506915070150711507215073150741507515076150771507815079150801508115082150831508415085150861508715088150891509015091150921509315094150951509615097150981509915100151011510215103151041510515106151071510815109151101511115112151131511415115151161511715118151191512015121151221512315124151251512615127151281512915130151311513215133151341513515136151371513815139151401514115142151431514415145151461514715148151491515015151151521515315154151551515615157151581515915160151611516215163151641516515166151671516815169151701517115172151731517415175151761517715178151791518015181151821518315184151851518615187151881518915190151911519215193151941519515196151971519815199152001520115202152031520415205152061520715208152091521015211152121521315214152151521615217152181521915220152211522215223152241522515226152271522815229152301523115232152331523415235152361523715238152391524015241152421524315244152451524615247152481524915250152511525215253152541525515256152571525815259152601526115262152631526415265152661526715268152691527015271152721527315274152751527615277152781527915280152811528215283152841528515286152871528815289152901529115292152931529415295152961529715298152991530015301153021530315304153051530615307153081530915310153111531215313153141531515316153171531815319153201532115322153231532415325153261532715328153291533015331153321533315334153351533615337153381533915340153411534215343153441534515346153471534815349153501535115352153531535415355153561535715358153591536015361153621536315364153651536615367153681536915370153711537215373153741537515376153771537815379153801538115382153831538415385153861538715388153891539015391153921539315394153951539615397153981539915400154011540215403154041540515406154071540815409154101541115412154131541415415154161541715418154191542015421154221542315424154251542615427154281542915430154311543215433154341543515436154371543815439154401544115442154431544415445154461544715448154491545015451154521545315454154551545615457154581545915460154611546215463154641546515466154671546815469154701547115472154731547415475154761547715478154791548015481154821548315484154851548615487154881548915490154911549215493154941549515496154971549815499155001550115502155031550415505155061550715508155091551015511155121551315514155151551615517155181551915520155211552215523155241552515526155271552815529155301553115532155331553415535155361553715538155391554015541155421554315544155451554615547155481554915550155511555215553155541555515556155571555815559155601556115562155631556415565155661556715568155691557015571155721557315574155751557615577155781557915580155811558215583155841558515586155871558815589155901559115592155931559415595155961559715598155991560015601156021560315604156051560615607156081560915610156111561215613156141561515616156171561815619156201562115622156231562415625156261562715628156291563015631156321563315634156351563615637156381563915640156411564215643156441564515646156471564815649156501565115652156531565415655156561565715658156591566015661156621566315664156651566615667156681566915670156711567215673156741567515676156771567815679156801568115682156831568415685156861568715688156891569015691156921569315694156951569615697156981569915700157011570215703157041570515706157071570815709157101571115712157131571415715157161571715718157191572015721157221572315724157251572615727157281572915730157311573215733157341573515736157371573815739157401574115742157431574415745157461574715748157491575015751157521575315754157551575615757157581575915760157611576215763157641576515766157671576815769157701577115772157731577415775157761577715778157791578015781157821578315784157851578615787157881578915790157911579215793157941579515796157971579815799158001580115802158031580415805158061580715808158091581015811158121581315814158151581615817158181581915820158211582215823158241582515826158271582815829158301583115832158331583415835158361583715838158391584015841158421584315844158451584615847158481584915850158511585215853158541585515856158571585815859158601586115862158631586415865158661586715868158691587015871158721587315874158751587615877158781587915880158811588215883158841588515886158871588815889158901589115892158931589415895158961589715898158991590015901159021590315904159051590615907159081590915910159111591215913159141591515916159171591815919159201592115922159231592415925159261592715928159291593015931159321593315934159351593615937159381593915940159411594215943159441594515946159471594815949159501595115952159531595415955159561595715958159591596015961159621596315964159651596615967159681596915970159711597215973159741597515976159771597815979159801598115982159831598415985159861598715988159891599015991159921599315994159951599615997159981599916000160011600216003160041600516006160071600816009160101601116012160131601416015160161601716018160191602016021160221602316024160251602616027160281602916030160311603216033160341603516036160371603816039160401604116042160431604416045160461604716048160491605016051160521605316054160551605616057160581605916060160611606216063160641606516066160671606816069160701607116072160731607416075160761607716078160791608016081160821608316084160851608616087160881608916090160911609216093160941609516096160971609816099161001610116102161031610416105161061610716108161091611016111161121611316114161151611616117161181611916120161211612216123161241612516126161271612816129161301613116132161331613416135161361613716138161391614016141161421614316144161451614616147161481614916150161511615216153161541615516156161571615816159161601616116162161631616416165161661616716168161691617016171161721617316174161751617616177161781617916180161811618216183161841618516186161871618816189161901619116192161931619416195161961619716198161991620016201162021620316204162051620616207162081620916210162111621216213162141621516216162171621816219162201622116222162231622416225162261622716228162291623016231162321623316234162351623616237162381623916240162411624216243162441624516246162471624816249162501625116252162531625416255162561625716258162591626016261162621626316264162651626616267162681626916270162711627216273162741627516276162771627816279162801628116282162831628416285162861628716288162891629016291162921629316294162951629616297162981629916300163011630216303163041630516306163071630816309163101631116312163131631416315163161631716318163191632016321163221632316324163251632616327163281632916330163311633216333163341633516336163371633816339163401634116342163431634416345163461634716348163491635016351163521635316354163551635616357163581635916360163611636216363163641636516366163671636816369163701637116372163731637416375163761637716378163791638016381163821638316384163851638616387163881638916390163911639216393163941639516396163971639816399164001640116402164031640416405164061640716408164091641016411164121641316414164151641616417164181641916420164211642216423164241642516426164271642816429164301643116432164331643416435164361643716438164391644016441164421644316444164451644616447164481644916450164511645216453164541645516456164571645816459164601646116462164631646416465164661646716468164691647016471164721647316474164751647616477164781647916480164811648216483164841648516486164871648816489164901649116492164931649416495164961649716498164991650016501165021650316504165051650616507165081650916510165111651216513165141651516516165171651816519165201652116522165231652416525165261652716528165291653016531165321653316534165351653616537165381653916540165411654216543165441654516546165471654816549165501655116552165531655416555165561655716558165591656016561165621656316564165651656616567165681656916570165711657216573165741657516576165771657816579165801658116582165831658416585165861658716588165891659016591165921659316594165951659616597165981659916600166011660216603166041660516606166071660816609166101661116612166131661416615166161661716618166191662016621166221662316624166251662616627166281662916630166311663216633166341663516636166371663816639166401664116642166431664416645166461664716648166491665016651166521665316654166551665616657166581665916660166611666216663166641666516666166671666816669166701667116672166731667416675166761667716678166791668016681166821668316684166851668616687166881668916690166911669216693166941669516696166971669816699167001670116702167031670416705167061670716708167091671016711167121671316714167151671616717167181671916720167211672216723167241672516726167271672816729167301673116732167331673416735167361673716738167391674016741167421674316744167451674616747167481674916750167511675216753167541675516756167571675816759167601676116762167631676416765167661676716768167691677016771167721677316774167751677616777167781677916780167811678216783167841678516786167871678816789167901679116792167931679416795167961679716798167991680016801168021680316804168051680616807168081680916810168111681216813168141681516816168171681816819168201682116822168231682416825168261682716828168291683016831168321683316834168351683616837168381683916840168411684216843168441684516846168471684816849168501685116852168531685416855168561685716858168591686016861168621686316864168651686616867168681686916870168711687216873168741687516876168771687816879168801688116882168831688416885168861688716888168891689016891168921689316894168951689616897168981689916900169011690216903169041690516906169071690816909169101691116912169131691416915169161691716918169191692016921169221692316924169251692616927169281692916930169311693216933169341693516936169371693816939169401694116942169431694416945169461694716948169491695016951169521695316954169551695616957169581695916960169611696216963169641696516966169671696816969169701697116972169731697416975169761697716978169791698016981169821698316984169851698616987169881698916990169911699216993169941699516996169971699816999170001700117002170031700417005170061700717008170091701017011170121701317014170151701617017170181701917020170211702217023170241702517026170271702817029170301703117032170331703417035170361703717038170391704017041170421704317044170451704617047170481704917050170511705217053170541705517056170571705817059170601706117062170631706417065170661706717068170691707017071170721707317074170751707617077170781707917080170811708217083170841708517086170871708817089170901709117092170931709417095170961709717098170991710017101171021710317104171051710617107171081710917110171111711217113171141711517116171171711817119171201712117122171231712417125171261712717128171291713017131171321713317134171351713617137171381713917140171411714217143171441714517146171471714817149171501715117152171531715417155171561715717158171591716017161
  1. /* ====================================================================
  2. |
  3. | Amber Smalltalk
  4. | http://amber-lang.net
  5. |
  6. ======================================================================
  7. ======================================================================
  8. |
  9. | Copyright (c) 2010-2011
  10. | Nicolas Petton <petton.nicolas@gmail.com>
  11. |
  12. | Amber is released under the MIT license
  13. |
  14. | Permission is hereby granted, free of charge, to any person obtaining
  15. | a copy of this software and associated documentation files (the
  16. | 'Software'), to deal in the Software without restriction, including
  17. | without limitation the rights to use, copy, modify, merge, publish,
  18. | distribute, sublicense, and/or sell copies of the Software, and to
  19. | permit persons to whom the Software is furnished to do so, subject to
  20. | the following conditions:
  21. |
  22. | The above copyright notice and this permission notice shall be
  23. | included in all copies or substantial portions of the Software.
  24. |
  25. | THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
  26. | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
  27. | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
  28. | IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
  29. | CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
  30. | TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
  31. | SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  32. |
  33. ==================================================================== */
  34. /* Make that console is defined */
  35. if (typeof console === "undefined") {
  36. this.console = {
  37. log: function() {},
  38. warn: function() {},
  39. info: function() {},
  40. debug: function() {},
  41. error: function() {}
  42. };
  43. }
  44. /* Smalltalk constructors definition */
  45. function SmalltalkObject(){};
  46. function SmalltalkBehavior(){};
  47. function SmalltalkClass(){};
  48. function SmalltalkPackage(){};
  49. function SmalltalkMetaclass(){
  50. this.meta = true;
  51. };
  52. function SmalltalkMethod(){};
  53. function SmalltalkNil(){};
  54. function Smalltalk(){
  55. var st = this;
  56. /* This is the current call context object. While it is publicly available,
  57. Use smalltalk.getThisContext() instead which will answer a safe copy of
  58. the current context */
  59. st.thisContext = undefined;
  60. /* List of all reserved words in JavaScript. They may not be used as variables
  61. in Smalltalk. */
  62. st.reservedWords = ['break', 'case', 'catch', 'char', 'class', 'continue', 'debugger',
  63. 'default', 'delete', 'do', 'else', 'finally', 'for', 'function',
  64. 'if', 'in', 'instanceof', 'new', 'private', 'protected',
  65. 'public', 'return', 'static', 'switch', 'this', 'throw',
  66. 'try', 'typeof', 'var', 'void', 'while', 'with', 'yield'];
  67. /* We hold all Packages in a separate Object */
  68. st.packages = {};
  69. /* Smalltalk package creation. To add a Package, use smalltalk.addPackage() */
  70. function pkg(spec) {
  71. var that = new SmalltalkPackage();
  72. that.pkgName = spec.pkgName;
  73. that.properties = spec.properties || {};
  74. return that;
  75. };
  76. /* Smalltalk class creation. A class is an instance of an automatically
  77. created metaclass object. Newly created classes (not their metaclass)
  78. should be added to the smalltalk object, see smalltalk.addClass().
  79. Superclass linking is *not* handled here, see smalltalk.init() */
  80. function klass(spec) {
  81. var spec = spec || {};
  82. var that;
  83. if(spec.meta) {
  84. that = new SmalltalkMetaclass();
  85. } else {
  86. that = new (klass({meta: true})).fn;
  87. that.klass.instanceClass = that;
  88. that.className = spec.className;
  89. that.klass.className = that.className + ' class';
  90. }
  91. that.fn = spec.fn || function(){};
  92. that.superclass = spec.superclass;
  93. that.iVarNames = spec.iVarNames || [];
  94. if(that.superclass) {
  95. that.klass.superclass = that.superclass.klass;
  96. }
  97. that.pkg = spec.pkg;
  98. that.fn.prototype.methods = {};
  99. that.fn.prototype.inheritedMethods = {};
  100. that.fn.prototype.klass = that;
  101. return that;
  102. };
  103. /* Smalltalk method object. To add a method to a class,
  104. use smalltalk.addMethod() */
  105. st.method = function(spec) {
  106. var that = new SmalltalkMethod();
  107. that.selector = spec.selector;
  108. that.jsSelector = spec.jsSelector;
  109. that.args = spec.args || {};
  110. that.category = spec.category;
  111. that.source = spec.source;
  112. that.messageSends = spec.messageSends || [];
  113. that.referencedClasses = spec.referencedClasses || [];
  114. that.fn = spec.fn;
  115. return that
  116. };
  117. /* Initialize a class in its class hierarchy. Handle both class and
  118. metaclasses. */
  119. st.init = function(klass) {
  120. var subclasses = st.subclasses(klass);
  121. var methods;
  122. if(klass.superclass && klass.superclass !== nil) {
  123. methods = st.methods(klass.superclass);
  124. //Methods linking
  125. for(var i in methods) {
  126. if(!klass.fn.prototype.methods[i]) {
  127. klass.fn.prototype.inheritedMethods[i] = methods[i];
  128. klass.fn.prototype[methods[i].jsSelector] = methods[i].fn;
  129. }
  130. }
  131. }
  132. for(var i=0;i<subclasses.length;i++) {
  133. st.init(subclasses[i]);
  134. }
  135. if(klass.klass && !klass.meta) {
  136. st.init(klass.klass);
  137. }
  138. };
  139. /* Answer all registered Packages as Array */
  140. st.packages.all = function() {
  141. var packages = [];
  142. for(var i in st.packages) {
  143. if (!st.packages.hasOwnProperty(i) || typeof(st.packages[i]) === "function") continue;
  144. packages.push(st.packages[i]);
  145. }
  146. return packages
  147. };
  148. /* Answer all registered Smalltalk classes */
  149. st.classes = function() {
  150. var classes = [];
  151. for(var i in st) {
  152. if(i.search(/^[A-Z]/g) != -1) {
  153. classes.push(st[i]);
  154. }
  155. }
  156. return classes
  157. };
  158. /* Answer all methods (included inherited ones) of klass. */
  159. st.methods = function(klass) {
  160. var methods = {};
  161. for(var i in klass.fn.prototype.methods) {
  162. methods[i] = klass.fn.prototype.methods[i]
  163. }
  164. for(var i in klass.fn.prototype.inheritedMethods) {
  165. methods[i] = klass.fn.prototype.inheritedMethods[i]
  166. }
  167. return methods;
  168. }
  169. /* Answer the direct subclasses of klass. */
  170. st.subclasses = function(klass) {
  171. var subclasses = [];
  172. var classes = st.classes();
  173. for(var i in classes) {
  174. if(classes[i].fn) {
  175. //Metaclasses
  176. if(classes[i].klass && classes[i].klass.superclass === klass) {
  177. subclasses.push(classes[i].klass);
  178. }
  179. //Classes
  180. if(classes[i].superclass === klass) {
  181. subclasses.push(classes[i]);
  182. }
  183. }
  184. }
  185. return subclasses;
  186. };
  187. /* Create a new class wrapping a JavaScript constructor, and add it to the
  188. global smalltalk object. Package is lazily created if it does not exist with given name. */
  189. st.mapClassName = function(className, pkgName, fn, superclass) {
  190. var pkg = st.addPackage(pkgName);
  191. st[className] = klass({
  192. className: className,
  193. superclass: superclass,
  194. pkg: pkg,
  195. fn: fn
  196. });
  197. };
  198. /* Add a package to the smalltalk.packages object, creating a new one if needed.
  199. If pkgName is null or empty we return nil, which is an allowed package for a class.
  200. If package already exists we still update the properties of it. */
  201. st.addPackage = function(pkgName, properties) {
  202. if(!pkgName) {return nil;}
  203. if(!(st.packages[pkgName])) {
  204. st.packages[pkgName] = pkg({
  205. pkgName: pkgName,
  206. properties: properties
  207. });
  208. } else {
  209. if(properties) {
  210. st.packages[pkgName].properties = properties;
  211. }
  212. }
  213. return st.packages[pkgName];
  214. };
  215. /* Add a class to the smalltalk object, creating a new one if needed.
  216. Package is lazily created if it does not exist with given name.*/
  217. st.addClass = function(className, superclass, iVarNames, pkgName) {
  218. var pkg = st.addPackage(pkgName);
  219. if(st[className]) {
  220. st[className].superclass = superclass;
  221. st[className].iVarNames = iVarNames;
  222. st[className].pkg = pkg || st[className].pkg;
  223. } else {
  224. st[className] = klass({
  225. className: className,
  226. superclass: superclass,
  227. pkg: pkg,
  228. iVarNames: iVarNames
  229. });
  230. }
  231. };
  232. /* Add a method to a class */
  233. st.addMethod = function(jsSelector, method, klass) {
  234. klass.fn.prototype[jsSelector] = method.fn;
  235. klass.fn.prototype.methods[method.selector] = method;
  236. method.methodClass = klass;
  237. method.jsSelector = jsSelector;
  238. };
  239. /* Handles Smalltalk message send. Automatically converts undefined to the nil object.
  240. If the receiver does not understand the selector, call its #doesNotUnderstand: method */
  241. sendWithoutContext = function(receiver, selector, args, klass) {
  242. if(receiver === undefined || receiver === null) {
  243. receiver = nil;
  244. }
  245. if(!klass && receiver.klass && receiver[selector]) {
  246. return receiver[selector].apply(receiver, args);
  247. } else if(klass && klass.fn.prototype[selector]) {
  248. return klass.fn.prototype[selector].apply(receiver, args)
  249. }
  250. return messageNotUnderstood(receiver, selector, args);
  251. };
  252. /* Handles unhandled errors during message sends */
  253. sendWithContext = function(receiver, selector, args, klass) {
  254. if(st.thisContext) {
  255. return withContextSend(receiver, selector, args, klass);
  256. } else {
  257. try {return withContextSend(receiver, selector, args, klass)}
  258. catch(error) {
  259. // Reset the context stack in any case
  260. st.thisContext = undefined;
  261. if(error.smalltalkError) {
  262. handleError(error);
  263. } else {
  264. throw(error);
  265. }
  266. }
  267. }
  268. };
  269. /* Same as sendWithoutContext but creates a methodContext. */
  270. withContextSend = function(receiver, selector, args, klass) {
  271. var call, context;
  272. if(receiver === undefined || receiver === null) {
  273. receiver = nil;
  274. }
  275. if(!klass && receiver.klass && receiver[selector]) {
  276. context = pushContext(receiver, selector, args);
  277. call = receiver[selector].apply(receiver, args);
  278. popContext(context);
  279. return call;
  280. } else if(klass && klass.fn.prototype[selector]) {
  281. context = pushContext(receiver, selector, args);
  282. call = klass.fn.prototype[selector].apply(receiver, args);
  283. popContext(context);
  284. return call;
  285. }
  286. return messageNotUnderstood(receiver, selector, args);
  287. };
  288. /* Handles Smalltalk errors. Triggers the registered ErrorHandler
  289. (See the Smalltalk class ErrorHandler and its subclasses */
  290. function handleError(error) {
  291. st.thisContext = undefined;
  292. smalltalk.ErrorHandler._current()._handleError_(error);
  293. }
  294. /* Handles #dnu: *and* JavaScript method calls.
  295. if the receiver has no klass, we consider it a JS object (outside of the
  296. Amber system). Else assume that the receiver understands #doesNotUnderstand: */
  297. function messageNotUnderstood(receiver, selector, args) {
  298. /* Handles JS method calls. */
  299. if(receiver.klass === undefined || receiver.allowJavaScriptCalls) {
  300. return callJavaScriptMethod(receiver, selector, args);
  301. }
  302. /* Handles not understood messages. Also see the Amber counter-part
  303. Object>>doesNotUnderstand: */
  304. return receiver._doesNotUnderstand_(
  305. st.Message._new()
  306. ._selector_(st.convertSelector(selector))
  307. ._arguments_(args)
  308. );
  309. };
  310. /* Call a method of a JS object, or answer a property if it exists.
  311. Else try wrapping a JSObjectProxy around the receiver.
  312. Converts keyword-based selectors by using the first
  313. keyword only, but keeping all message arguments.
  314. Example:
  315. "self do: aBlock with: anObject" -> "self.do(aBlock, anObject)" */
  316. function callJavaScriptMethod(receiver, selector, args) {
  317. var jsSelector = selector._asJavaScriptSelector();
  318. var jsProperty = receiver[jsSelector];
  319. if(typeof jsProperty === "function") {
  320. return jsProperty.apply(receiver, args);
  321. } else if(jsProperty !== undefined) {
  322. if(args[0]) {
  323. receiver[jsSelector] = args[0];
  324. return nil;
  325. } else {
  326. return jsProperty
  327. }
  328. }
  329. return st.send(st.JSObjectProxy._on_(receiver), selector, args);
  330. };
  331. /* Reuse old contexts stored in oldContexts */
  332. st.oldContexts = [];
  333. /* Handle thisContext pseudo variable */
  334. st.getThisContext = function() {
  335. if(st.thisContext) {
  336. return st.thisContext.copy();
  337. } else {
  338. return undefined;
  339. }
  340. }
  341. pushContext = function(receiver, selector, temps) {
  342. if(st.thisContext) {
  343. return st.thisContext = st.thisContext.newContext(receiver, selector, temps);
  344. } else {
  345. return st.thisContext = new SmalltalkMethodContext(receiver, selector, temps);
  346. }
  347. };
  348. popContext = function(context) {
  349. if(context) {
  350. context.removeYourself();
  351. }
  352. };
  353. /* Convert a string to a valid smalltalk selector.
  354. if you modify the following functions, also change String>>asSelector
  355. accordingly */
  356. st.convertSelector = function(selector) {
  357. if(selector.match(/__/)) {
  358. return convertBinarySelector(selector);
  359. } else {
  360. return convertKeywordSelector(selector);
  361. }
  362. };
  363. function convertKeywordSelector(selector) {
  364. return selector.replace(/^_/, '').replace(/_/g, ':');
  365. };
  366. function convertBinarySelector(selector) {
  367. return selector
  368. .replace(/^_/, '')
  369. .replace(/_plus/, '+')
  370. .replace(/_minus/, '-')
  371. .replace(/_star/, '*')
  372. .replace(/_slash/, '/')
  373. .replace(/_gt/, '>')
  374. .replace(/_lt/, '<')
  375. .replace(/_eq/, '=')
  376. .replace(/_comma/, ',')
  377. .replace(/_at/, '@')
  378. };
  379. /* Converts a JavaScript object to valid Smalltalk Object */
  380. st.readJSObject = function(js) {
  381. var object = js;
  382. var readObject = (js.constructor === Object);
  383. var readArray = (js.constructor === Array);
  384. if(readObject) {
  385. object = smalltalk.Dictionary._new();
  386. }
  387. for(var i in js) {
  388. if(readObject) {
  389. object._at_put_(i, st.readJSObject(js[i]));
  390. }
  391. if(readArray) {
  392. object[i] = st.readJSObject(js[i]);
  393. }
  394. }
  395. return object;
  396. };
  397. /* Toggle deployment mode (no context will be handled during message send */
  398. st.setDeploymentMode = function() {
  399. st.send = sendWithoutContext;
  400. };
  401. st.setDevelopmentMode = function() {
  402. st.send = sendWithContext;
  403. }
  404. /* Set development mode by default */
  405. st.setDevelopmentMode();
  406. }
  407. function SmalltalkMethodContext(receiver, selector, temps, home) {
  408. var that = this;
  409. that.receiver = receiver;
  410. that.selector = selector;
  411. that.temps = temps || {};
  412. that.homeContext = home;
  413. that.copy = function() {
  414. var home = that.homeContext;
  415. if(home) {home = home.copy()}
  416. return new SmalltalkMethodContext(
  417. that.receiver,
  418. that.selector,
  419. that.temps,
  420. home
  421. );
  422. }
  423. that.newContext = function(receiver, selector, temps) {
  424. var c = smalltalk.oldContexts.pop();
  425. if(c) {
  426. c.homeContext = that;
  427. c.receiver = receiver;
  428. c.selector = selector;
  429. c.temps = temps || {};
  430. } else {
  431. c = new SmalltalkMethodContext(receiver, selector, temps, that);
  432. }
  433. return c;
  434. }
  435. that.removeYourself = function() {
  436. smalltalk.thisContext = that.homeContext;
  437. that.homeContext = undefined;
  438. smalltalk.oldContexts.push(that);
  439. }
  440. }
  441. /* Global Smalltalk objects. */
  442. var nil = new SmalltalkNil();
  443. var smalltalk = new Smalltalk();
  444. if(this.jQuery) {
  445. this.jQuery.allowJavaScriptCalls = true;
  446. }
  447. /****************************************************************************************/
  448. /* Base classes mapping. If you edit this part, do not forget to set the superclass of the
  449. object metaclass to Class after the definition of Object */
  450. smalltalk.mapClassName("Object", "Kernel", SmalltalkObject);
  451. smalltalk.mapClassName("Smalltalk", "Kernel", Smalltalk, smalltalk.Object);
  452. smalltalk.mapClassName("Package", "Kernel", SmalltalkPackage, smalltalk.Object);
  453. smalltalk.mapClassName("Behavior", "Kernel", SmalltalkBehavior, smalltalk.Object);
  454. smalltalk.mapClassName("Class", "Kernel", SmalltalkClass, smalltalk.Behavior);
  455. smalltalk.mapClassName("Metaclass", "Kernel", SmalltalkMetaclass, smalltalk.Behavior);
  456. smalltalk.mapClassName("CompiledMethod", "Kernel", SmalltalkMethod, smalltalk.Object);
  457. smalltalk.Object.klass.superclass = smalltalk.Class;
  458. smalltalk.mapClassName("Number", "Kernel", Number, smalltalk.Object);
  459. smalltalk.mapClassName("BlockClosure", "Kernel", Function, smalltalk.Object);
  460. smalltalk.mapClassName("Boolean", "Kernel", Boolean, smalltalk.Object);
  461. smalltalk.mapClassName("Date", "Kernel", Date, smalltalk.Object);
  462. smalltalk.mapClassName("UndefinedObject", "Kernel", SmalltalkNil, smalltalk.Object);
  463. smalltalk.mapClassName("Collection", "Kernel", null, smalltalk.Object);
  464. smalltalk.mapClassName("SequenceableCollection", "Kernel", null, smalltalk.Collection);
  465. smalltalk.mapClassName("String", "Kernel", String, smalltalk.SequenceableCollection);
  466. smalltalk.mapClassName("Array", "Kernel", Array, smalltalk.SequenceableCollection);
  467. smalltalk.mapClassName("RegularExpression", "Kernel", RegExp, smalltalk.String);
  468. smalltalk.mapClassName("Error", "Kernel", Error, smalltalk.Object);
  469. smalltalk.mapClassName("MethodContext", "Kernel", SmalltalkMethodContext, smalltalk.Object);
  470. smalltalk.addPackage('Kernel', {});
  471. smalltalk.addClass('Object', smalltalk.nil, [], 'Kernel');
  472. smalltalk.addMethod(
  473. unescape('__eq'),
  474. smalltalk.method({
  475. selector: unescape('%3D'),
  476. category: 'comparing',
  477. fn: function (anObject){
  478. var self=this;
  479. return smalltalk.send(self, "__eq_eq", [anObject]);
  480. return self;},
  481. args: ["anObject"],
  482. source: unescape('%3D%20anObject%0A%09%5Eself%20%3D%3D%20anObject'),
  483. messageSends: [unescape("%3D%3D")],
  484. referencedClasses: []
  485. }),
  486. smalltalk.Object);
  487. smalltalk.addMethod(
  488. unescape('_%7E_eq'),
  489. smalltalk.method({
  490. selector: unescape('%7E%3D'),
  491. category: 'comparing',
  492. fn: function (anObject){
  493. var self=this;
  494. return smalltalk.send(smalltalk.send(self, "__eq", [anObject]), "__eq", [false]);
  495. return self;},
  496. args: ["anObject"],
  497. source: unescape('%7E%3D%20anObject%0A%09%5E%28self%20%3D%20anObject%29%20%3D%20false'),
  498. messageSends: [unescape("%3D")],
  499. referencedClasses: []
  500. }),
  501. smalltalk.Object);
  502. smalltalk.addMethod(
  503. unescape('_initialize'),
  504. smalltalk.method({
  505. selector: unescape('initialize'),
  506. category: 'initialization',
  507. fn: function (){
  508. var self=this;
  509. return self;},
  510. args: [],
  511. source: unescape('initialize'),
  512. messageSends: [],
  513. referencedClasses: []
  514. }),
  515. smalltalk.Object);
  516. smalltalk.addMethod(
  517. unescape('_yourself'),
  518. smalltalk.method({
  519. selector: unescape('yourself'),
  520. category: 'accessing',
  521. fn: function (){
  522. var self=this;
  523. return self;
  524. return self;},
  525. args: [],
  526. source: unescape('yourself%0A%09%5Eself'),
  527. messageSends: [],
  528. referencedClasses: []
  529. }),
  530. smalltalk.Object);
  531. smalltalk.addMethod(
  532. unescape('_class'),
  533. smalltalk.method({
  534. selector: unescape('class'),
  535. category: 'accessing',
  536. fn: function (){
  537. var self=this;
  538. return self.klass;
  539. return self;},
  540. args: [],
  541. source: unescape('class%0A%09%3Creturn%20self.klass%3E'),
  542. messageSends: [],
  543. referencedClasses: []
  544. }),
  545. smalltalk.Object);
  546. smalltalk.addMethod(
  547. unescape('_size'),
  548. smalltalk.method({
  549. selector: unescape('size'),
  550. category: 'accessing',
  551. fn: function (){
  552. var self=this;
  553. smalltalk.send(self, "_error_", ["Object not indexable"]);
  554. return self;},
  555. args: [],
  556. source: unescape('size%0A%09self%20error%3A%20%27Object%20not%20indexable%27'),
  557. messageSends: ["error:"],
  558. referencedClasses: []
  559. }),
  560. smalltalk.Object);
  561. smalltalk.addMethod(
  562. unescape('_copy'),
  563. smalltalk.method({
  564. selector: unescape('copy'),
  565. category: 'copying',
  566. fn: function (){
  567. var self=this;
  568. return smalltalk.send(smalltalk.send(self, "_shallowCopy", []), "_postCopy", []);
  569. return self;},
  570. args: [],
  571. source: unescape('copy%0A%09%5Eself%20shallowCopy%20postCopy'),
  572. messageSends: ["postCopy", "shallowCopy"],
  573. referencedClasses: []
  574. }),
  575. smalltalk.Object);
  576. smalltalk.addMethod(
  577. unescape('_shallowCopy'),
  578. smalltalk.method({
  579. selector: unescape('shallowCopy'),
  580. category: 'copying',
  581. fn: function (){
  582. var self=this;
  583. var copy = self.klass._new();
  584. for(var i in self) {
  585. if(/^@.+/.test(i)) {
  586. copy[i] = self[i];
  587. }
  588. }
  589. return copy;
  590. ;
  591. return self;},
  592. args: [],
  593. source: unescape('shallowCopy%0A%09%3C%0A%09%20%20%20%20var%20copy%20%3D%20self.klass._new%28%29%3B%0A%09%20%20%20%20for%28var%20i%20in%20self%29%20%7B%0A%09%09if%28/%5E@.+/.test%28i%29%29%20%7B%0A%09%09%20%20%20%20copy%5Bi%5D%20%3D%20self%5Bi%5D%3B%0A%09%09%7D%0A%09%20%20%20%20%7D%0A%09%20%20%20%20return%20copy%3B%0A%09%3E'),
  594. messageSends: [],
  595. referencedClasses: []
  596. }),
  597. smalltalk.Object);
  598. smalltalk.addMethod(
  599. unescape('_deepCopy'),
  600. smalltalk.method({
  601. selector: unescape('deepCopy'),
  602. category: 'copying',
  603. fn: function (){
  604. var self=this;
  605. var copy = self.klass._new();
  606. for(var i in self) {
  607. if(/^@.+/.test(i)) {
  608. copy[i] = self[i]._deepCopy();
  609. }
  610. }
  611. return copy;
  612. ;
  613. return self;},
  614. args: [],
  615. source: unescape('deepCopy%0A%09%3C%20%20%20%20%0A%09%20%20%20%20var%20copy%20%3D%20self.klass._new%28%29%3B%0A%09%20%20%20%20for%28var%20i%20in%20self%29%20%7B%0A%09%09if%28/%5E@.+/.test%28i%29%29%20%7B%0A%09%09%20%20%20%20copy%5Bi%5D%20%3D%20self%5Bi%5D._deepCopy%28%29%3B%0A%09%09%7D%0A%09%20%20%20%20%7D%0A%09%20%20%20%20return%20copy%3B%0A%09%3E'),
  616. messageSends: [],
  617. referencedClasses: []
  618. }),
  619. smalltalk.Object);
  620. smalltalk.addMethod(
  621. unescape('_postCopy'),
  622. smalltalk.method({
  623. selector: unescape('postCopy'),
  624. category: 'copying',
  625. fn: function (){
  626. var self=this;
  627. return self;},
  628. args: [],
  629. source: unescape('postCopy'),
  630. messageSends: [],
  631. referencedClasses: []
  632. }),
  633. smalltalk.Object);
  634. smalltalk.addMethod(
  635. unescape('__minus_gt'),
  636. smalltalk.method({
  637. selector: unescape('-%3E'),
  638. category: 'converting',
  639. fn: function (anObject){
  640. var self=this;
  641. return smalltalk.send((smalltalk.Association || Association), "_key_value_", [self, anObject]);
  642. return self;},
  643. args: ["anObject"],
  644. source: unescape('-%3E%20anObject%0A%09%5EAssociation%20key%3A%20self%20value%3A%20anObject'),
  645. messageSends: ["key:value:"],
  646. referencedClasses: ["Association"]
  647. }),
  648. smalltalk.Object);
  649. smalltalk.addMethod(
  650. unescape('_asString'),
  651. smalltalk.method({
  652. selector: unescape('asString'),
  653. category: 'converting',
  654. fn: function (){
  655. var self=this;
  656. return smalltalk.send(self, "_printString", []);
  657. return self;},
  658. args: [],
  659. source: unescape('asString%0A%09%5Eself%20printString'),
  660. messageSends: ["printString"],
  661. referencedClasses: []
  662. }),
  663. smalltalk.Object);
  664. smalltalk.addMethod(
  665. unescape('_asJavascript'),
  666. smalltalk.method({
  667. selector: unescape('asJavascript'),
  668. category: 'converting',
  669. fn: function (){
  670. var self=this;
  671. return smalltalk.send(self, "_asString", []);
  672. return self;},
  673. args: [],
  674. source: unescape('asJavascript%0A%09%5Eself%20asString'),
  675. messageSends: ["asString"],
  676. referencedClasses: []
  677. }),
  678. smalltalk.Object);
  679. smalltalk.addMethod(
  680. unescape('_perform_'),
  681. smalltalk.method({
  682. selector: unescape('perform%3A'),
  683. category: 'message handling',
  684. fn: function (aSymbol){
  685. var self=this;
  686. return smalltalk.send(self, "_perform_withArguments_", [aSymbol, []]);
  687. return self;},
  688. args: ["aSymbol"],
  689. source: unescape('perform%3A%20aSymbol%0A%09%5Eself%20perform%3A%20aSymbol%20withArguments%3A%20%23%28%29'),
  690. messageSends: ["perform:withArguments:"],
  691. referencedClasses: []
  692. }),
  693. smalltalk.Object);
  694. smalltalk.addMethod(
  695. unescape('_perform_withArguments_'),
  696. smalltalk.method({
  697. selector: unescape('perform%3AwithArguments%3A'),
  698. category: 'message handling',
  699. fn: function (aSymbol, aCollection){
  700. var self=this;
  701. return smalltalk.send(self, "_basicPerform_withArguments_", [smalltalk.send(aSymbol, "_asSelector", []), aCollection]);
  702. return self;},
  703. args: ["aSymbol", "aCollection"],
  704. source: unescape('perform%3A%20aSymbol%20withArguments%3A%20aCollection%0A%09%5Eself%20basicPerform%3A%20aSymbol%20asSelector%20withArguments%3A%20aCollection'),
  705. messageSends: ["basicPerform:withArguments:", "asSelector"],
  706. referencedClasses: []
  707. }),
  708. smalltalk.Object);
  709. smalltalk.addMethod(
  710. unescape('_instVarAt_'),
  711. smalltalk.method({
  712. selector: unescape('instVarAt%3A'),
  713. category: 'accessing',
  714. fn: function (aString){
  715. var self=this;
  716. return self['@'+aString];
  717. return self;},
  718. args: ["aString"],
  719. source: unescape('instVarAt%3A%20aString%0A%09%3Creturn%20self%5B%27@%27+aString%5D%3E'),
  720. messageSends: [],
  721. referencedClasses: []
  722. }),
  723. smalltalk.Object);
  724. smalltalk.addMethod(
  725. unescape('_instVarAt_put_'),
  726. smalltalk.method({
  727. selector: unescape('instVarAt%3Aput%3A'),
  728. category: 'accessing',
  729. fn: function (aString, anObject){
  730. var self=this;
  731. self['@' + aString] = anObject;
  732. return self;},
  733. args: ["aString", "anObject"],
  734. source: unescape('instVarAt%3A%20aString%20put%3A%20anObject%0A%09%3Cself%5B%27@%27%20+%20aString%5D%20%3D%20anObject%3E'),
  735. messageSends: [],
  736. referencedClasses: []
  737. }),
  738. smalltalk.Object);
  739. smalltalk.addMethod(
  740. unescape('_basicAt_'),
  741. smalltalk.method({
  742. selector: unescape('basicAt%3A'),
  743. category: 'accessing',
  744. fn: function (aString){
  745. var self=this;
  746. return self[aString];
  747. return self;},
  748. args: ["aString"],
  749. source: unescape('basicAt%3A%20aString%0A%09%3Creturn%20self%5BaString%5D%3E'),
  750. messageSends: [],
  751. referencedClasses: []
  752. }),
  753. smalltalk.Object);
  754. smalltalk.addMethod(
  755. unescape('_basicAt_put_'),
  756. smalltalk.method({
  757. selector: unescape('basicAt%3Aput%3A'),
  758. category: 'accessing',
  759. fn: function (aString, anObject){
  760. var self=this;
  761. return self[aString] = anObject;
  762. return self;},
  763. args: ["aString", "anObject"],
  764. source: unescape('basicAt%3A%20aString%20put%3A%20anObject%0A%09%3Creturn%20self%5BaString%5D%20%3D%20anObject%3E'),
  765. messageSends: [],
  766. referencedClasses: []
  767. }),
  768. smalltalk.Object);
  769. smalltalk.addMethod(
  770. unescape('_error_'),
  771. smalltalk.method({
  772. selector: unescape('error%3A'),
  773. category: 'error handling',
  774. fn: function (aString){
  775. var self=this;
  776. smalltalk.send((smalltalk.Error || Error), "_signal_", [aString]);
  777. return self;},
  778. args: ["aString"],
  779. source: unescape('error%3A%20aString%0A%09Error%20signal%3A%20aString'),
  780. messageSends: ["signal:"],
  781. referencedClasses: ["Error"]
  782. }),
  783. smalltalk.Object);
  784. smalltalk.addMethod(
  785. unescape('_subclassResponsibility'),
  786. smalltalk.method({
  787. selector: unescape('subclassResponsibility'),
  788. category: 'error handling',
  789. fn: function (){
  790. var self=this;
  791. smalltalk.send(self, "_error_", ["This method is a responsibility of a subclass"]);
  792. return self;},
  793. args: [],
  794. source: unescape('subclassResponsibility%0A%09self%20error%3A%20%27This%20method%20is%20a%20responsibility%20of%20a%20subclass%27'),
  795. messageSends: ["error:"],
  796. referencedClasses: []
  797. }),
  798. smalltalk.Object);
  799. smalltalk.addMethod(
  800. unescape('_shouldNotImplement'),
  801. smalltalk.method({
  802. selector: unescape('shouldNotImplement'),
  803. category: 'error handling',
  804. fn: function (){
  805. var self=this;
  806. smalltalk.send(self, "_error_", [smalltalk.send("This method should not be implemented in ", "__comma", [smalltalk.send(smalltalk.send(self, "_class", []), "_name", [])])]);
  807. return self;},
  808. args: [],
  809. source: unescape('shouldNotImplement%0A%09self%20error%3A%20%27This%20method%20should%20not%20be%20implemented%20in%20%27%2C%20self%20class%20name'),
  810. messageSends: ["error:", unescape("%2C"), "name", "class"],
  811. referencedClasses: []
  812. }),
  813. smalltalk.Object);
  814. smalltalk.addMethod(
  815. unescape('_try_catch_'),
  816. smalltalk.method({
  817. selector: unescape('try%3Acatch%3A'),
  818. category: 'error handling',
  819. fn: function (aBlock, anotherBlock){
  820. var self=this;
  821. try{aBlock()} catch(e) {anotherBlock(e)};
  822. return self;},
  823. args: ["aBlock", "anotherBlock"],
  824. source: unescape('try%3A%20aBlock%20catch%3A%20anotherBlock%0A%09%3Ctry%7BaBlock%28%29%7D%20catch%28e%29%20%7BanotherBlock%28e%29%7D%3E'),
  825. messageSends: [],
  826. referencedClasses: []
  827. }),
  828. smalltalk.Object);
  829. smalltalk.addMethod(
  830. unescape('_printString'),
  831. smalltalk.method({
  832. selector: unescape('printString'),
  833. category: 'printing',
  834. fn: function (){
  835. var self=this;
  836. return smalltalk.send("a ", "__comma", [smalltalk.send(smalltalk.send(self, "_class", []), "_name", [])]);
  837. return self;},
  838. args: [],
  839. source: unescape('printString%0A%09%5E%27a%20%27%2C%20self%20class%20name'),
  840. messageSends: [unescape("%2C"), "name", "class"],
  841. referencedClasses: []
  842. }),
  843. smalltalk.Object);
  844. smalltalk.addMethod(
  845. unescape('_printNl'),
  846. smalltalk.method({
  847. selector: unescape('printNl'),
  848. category: 'printing',
  849. fn: function (){
  850. var self=this;
  851. console.log(self);
  852. return self;},
  853. args: [],
  854. source: unescape('printNl%0A%09%3Cconsole.log%28self%29%3E'),
  855. messageSends: [],
  856. referencedClasses: []
  857. }),
  858. smalltalk.Object);
  859. smalltalk.addMethod(
  860. unescape('_isKindOf_'),
  861. smalltalk.method({
  862. selector: unescape('isKindOf%3A'),
  863. category: 'testing',
  864. fn: function (aClass){
  865. var self=this;
  866. return ((($receiver = smalltalk.send(self, "_isMemberOf_", [aClass])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return true;})() : (function(){return smalltalk.send(smalltalk.send(self, "_class", []), "_inheritsFrom_", [aClass]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return true;}), (function(){return smalltalk.send(smalltalk.send(self, "_class", []), "_inheritsFrom_", [aClass]);})]));
  867. return self;},
  868. args: ["aClass"],
  869. source: unescape('isKindOf%3A%20aClass%0A%09%5E%28self%20isMemberOf%3A%20aClass%29%0A%09%20%20%20%20ifTrue%3A%20%5Btrue%5D%0A%09%20%20%20%20ifFalse%3A%20%5Bself%20class%20inheritsFrom%3A%20aClass%5D'),
  870. messageSends: ["ifTrue:ifFalse:", "isMemberOf:", "inheritsFrom:", "class"],
  871. referencedClasses: []
  872. }),
  873. smalltalk.Object);
  874. smalltalk.addMethod(
  875. unescape('_isMemberOf_'),
  876. smalltalk.method({
  877. selector: unescape('isMemberOf%3A'),
  878. category: 'testing',
  879. fn: function (aClass){
  880. var self=this;
  881. return smalltalk.send(smalltalk.send(self, "_class", []), "__eq", [aClass]);
  882. return self;},
  883. args: ["aClass"],
  884. source: unescape('isMemberOf%3A%20aClass%0A%09%5Eself%20class%20%3D%20aClass'),
  885. messageSends: [unescape("%3D"), "class"],
  886. referencedClasses: []
  887. }),
  888. smalltalk.Object);
  889. smalltalk.addMethod(
  890. unescape('_ifNil_'),
  891. smalltalk.method({
  892. selector: unescape('ifNil%3A'),
  893. category: 'testing',
  894. fn: function (aBlock){
  895. var self=this;
  896. return self;
  897. return self;},
  898. args: ["aBlock"],
  899. source: unescape('ifNil%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5Eself'),
  900. messageSends: [],
  901. referencedClasses: []
  902. }),
  903. smalltalk.Object);
  904. smalltalk.addMethod(
  905. unescape('_ifNil_ifNotNil_'),
  906. smalltalk.method({
  907. selector: unescape('ifNil%3AifNotNil%3A'),
  908. category: 'testing',
  909. fn: function (aBlock, anotherBlock){
  910. var self=this;
  911. return smalltalk.send(anotherBlock, "_value", []);
  912. return self;},
  913. args: ["aBlock", "anotherBlock"],
  914. source: unescape('ifNil%3A%20aBlock%20ifNotNil%3A%20anotherBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5EanotherBlock%20value'),
  915. messageSends: ["value"],
  916. referencedClasses: []
  917. }),
  918. smalltalk.Object);
  919. smalltalk.addMethod(
  920. unescape('_ifNotNil_'),
  921. smalltalk.method({
  922. selector: unescape('ifNotNil%3A'),
  923. category: 'testing',
  924. fn: function (aBlock){
  925. var self=this;
  926. return smalltalk.send(aBlock, "_value", []);
  927. return self;},
  928. args: ["aBlock"],
  929. source: unescape('ifNotNil%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5EaBlock%20value'),
  930. messageSends: ["value"],
  931. referencedClasses: []
  932. }),
  933. smalltalk.Object);
  934. smalltalk.addMethod(
  935. unescape('_ifNotNil_ifNil_'),
  936. smalltalk.method({
  937. selector: unescape('ifNotNil%3AifNil%3A'),
  938. category: 'testing',
  939. fn: function (aBlock, anotherBlock){
  940. var self=this;
  941. return smalltalk.send(aBlock, "_value", []);
  942. return self;},
  943. args: ["aBlock", "anotherBlock"],
  944. source: unescape('ifNotNil%3A%20aBlock%20ifNil%3A%20anotherBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5EaBlock%20value'),
  945. messageSends: ["value"],
  946. referencedClasses: []
  947. }),
  948. smalltalk.Object);
  949. smalltalk.addMethod(
  950. unescape('_isNil'),
  951. smalltalk.method({
  952. selector: unescape('isNil'),
  953. category: 'testing',
  954. fn: function (){
  955. var self=this;
  956. return false;
  957. return self;},
  958. args: [],
  959. source: unescape('isNil%0A%09%5Efalse'),
  960. messageSends: [],
  961. referencedClasses: []
  962. }),
  963. smalltalk.Object);
  964. smalltalk.addMethod(
  965. unescape('_notNil'),
  966. smalltalk.method({
  967. selector: unescape('notNil'),
  968. category: 'testing',
  969. fn: function (){
  970. var self=this;
  971. return smalltalk.send(smalltalk.send(self, "_isNil", []), "_not", []);
  972. return self;},
  973. args: [],
  974. source: unescape('notNil%0A%09%5Eself%20isNil%20not'),
  975. messageSends: ["not", "isNil"],
  976. referencedClasses: []
  977. }),
  978. smalltalk.Object);
  979. smalltalk.addMethod(
  980. unescape('_isClass'),
  981. smalltalk.method({
  982. selector: unescape('isClass'),
  983. category: 'testing',
  984. fn: function (){
  985. var self=this;
  986. return false;
  987. return self;},
  988. args: [],
  989. source: unescape('isClass%0A%09%5Efalse'),
  990. messageSends: [],
  991. referencedClasses: []
  992. }),
  993. smalltalk.Object);
  994. smalltalk.addMethod(
  995. unescape('_isMetaclass'),
  996. smalltalk.method({
  997. selector: unescape('isMetaclass'),
  998. category: 'testing',
  999. fn: function (){
  1000. var self=this;
  1001. return false;
  1002. return self;},
  1003. args: [],
  1004. source: unescape('isMetaclass%0A%09%5Efalse'),
  1005. messageSends: [],
  1006. referencedClasses: []
  1007. }),
  1008. smalltalk.Object);
  1009. smalltalk.addMethod(
  1010. unescape('_isNumber'),
  1011. smalltalk.method({
  1012. selector: unescape('isNumber'),
  1013. category: 'testing',
  1014. fn: function (){
  1015. var self=this;
  1016. return false;
  1017. return self;},
  1018. args: [],
  1019. source: unescape('isNumber%0A%09%5Efalse'),
  1020. messageSends: [],
  1021. referencedClasses: []
  1022. }),
  1023. smalltalk.Object);
  1024. smalltalk.addMethod(
  1025. unescape('_isString'),
  1026. smalltalk.method({
  1027. selector: unescape('isString'),
  1028. category: 'testing',
  1029. fn: function (){
  1030. var self=this;
  1031. return false;
  1032. return self;},
  1033. args: [],
  1034. source: unescape('isString%0A%09%5Efalse'),
  1035. messageSends: [],
  1036. referencedClasses: []
  1037. }),
  1038. smalltalk.Object);
  1039. smalltalk.addMethod(
  1040. unescape('_isParseFailure'),
  1041. smalltalk.method({
  1042. selector: unescape('isParseFailure'),
  1043. category: 'testing',
  1044. fn: function (){
  1045. var self=this;
  1046. return false;
  1047. return self;},
  1048. args: [],
  1049. source: unescape('isParseFailure%0A%09%5Efalse'),
  1050. messageSends: [],
  1051. referencedClasses: []
  1052. }),
  1053. smalltalk.Object);
  1054. smalltalk.addMethod(
  1055. unescape('_basicPerform_'),
  1056. smalltalk.method({
  1057. selector: unescape('basicPerform%3A'),
  1058. category: 'message handling',
  1059. fn: function (aSymbol){
  1060. var self=this;
  1061. return smalltalk.send(self, "_basicPerform_withArguments_", [aSymbol, []]);
  1062. return self;},
  1063. args: ["aSymbol"],
  1064. source: unescape('basicPerform%3A%20aSymbol%20%0A%09%5Eself%20basicPerform%3A%20aSymbol%20withArguments%3A%20%23%28%29'),
  1065. messageSends: ["basicPerform:withArguments:"],
  1066. referencedClasses: []
  1067. }),
  1068. smalltalk.Object);
  1069. smalltalk.addMethod(
  1070. unescape('_basicPerform_withArguments_'),
  1071. smalltalk.method({
  1072. selector: unescape('basicPerform%3AwithArguments%3A'),
  1073. category: 'message handling',
  1074. fn: function (aSymbol, aCollection){
  1075. var self=this;
  1076. return self[aSymbol].apply(self, aCollection);;
  1077. return self;},
  1078. args: ["aSymbol", "aCollection"],
  1079. source: unescape('basicPerform%3A%20aSymbol%20withArguments%3A%20aCollection%0A%09%3Creturn%20self%5BaSymbol%5D.apply%28self%2C%20aCollection%29%3B%3E'),
  1080. messageSends: [],
  1081. referencedClasses: []
  1082. }),
  1083. smalltalk.Object);
  1084. smalltalk.addMethod(
  1085. unescape('_basicDelete_'),
  1086. smalltalk.method({
  1087. selector: unescape('basicDelete%3A'),
  1088. category: 'accessing',
  1089. fn: function (aString){
  1090. var self=this;
  1091. delete self[aString];
  1092. return self;},
  1093. args: ["aString"],
  1094. source: unescape('basicDelete%3A%20aString%0A%20%20%20%20%3Cdelete%20self%5BaString%5D%3E'),
  1095. messageSends: [],
  1096. referencedClasses: []
  1097. }),
  1098. smalltalk.Object);
  1099. smalltalk.addMethod(
  1100. unescape('_doesNotUnderstand_'),
  1101. smalltalk.method({
  1102. selector: unescape('doesNotUnderstand%3A'),
  1103. category: 'error handling',
  1104. fn: function (aMessage){
  1105. var self=this;
  1106. (function($rec){smalltalk.send($rec, "_receiver_", [self]);smalltalk.send($rec, "_message_", [aMessage]);return smalltalk.send($rec, "_signal", []);})(smalltalk.send((smalltalk.MessageNotUnderstood || MessageNotUnderstood), "_new", []));
  1107. return self;},
  1108. args: ["aMessage"],
  1109. source: unescape('doesNotUnderstand%3A%20aMessage%0A%09MessageNotUnderstood%20new%0A%09%09receiver%3A%20self%3B%0A%09%09message%3A%20aMessage%3B%0A%09%09signal'),
  1110. messageSends: ["receiver:", "message:", "signal", "new"],
  1111. referencedClasses: ["MessageNotUnderstood"]
  1112. }),
  1113. smalltalk.Object);
  1114. smalltalk.addMethod(
  1115. unescape('_asJSON'),
  1116. smalltalk.method({
  1117. selector: unescape('asJSON'),
  1118. category: 'converting',
  1119. fn: function (){
  1120. var self=this;
  1121. return JSON.stringify(self._asJSONObject());
  1122. return self;},
  1123. args: [],
  1124. source: unescape('asJSON%0A%09%3Creturn%20JSON.stringify%28self._asJSONObject%28%29%29%3E'),
  1125. messageSends: [],
  1126. referencedClasses: []
  1127. }),
  1128. smalltalk.Object);
  1129. smalltalk.addMethod(
  1130. unescape('_asJSONObject'),
  1131. smalltalk.method({
  1132. selector: unescape('asJSONObject'),
  1133. category: 'converting',
  1134. fn: function (){
  1135. var self=this;
  1136. var object=nil;
  1137. object=smalltalk.send((smalltalk.Object || Object), "_new", []);
  1138. smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "_instanceVariableNames", []), "_do_", [(function(each){return smalltalk.send(object, "_basicAt_put_", [each, smalltalk.send(smalltalk.send(self, "_instVarAt_", [each]), "_asJSONObject", [])]);})]);
  1139. return object;
  1140. return self;},
  1141. args: [],
  1142. source: unescape('asJSONObject%0A%09%7C%20object%20%7C%0A%09object%20%3A%3D%20Object%20new.%0A%09self%20class%20instanceVariableNames%20do%3A%20%5B%3Aeach%20%7C%0A%09%09object%20basicAt%3A%20each%20put%3A%20%28self%20instVarAt%3A%20each%29%20asJSONObject%5D.%0A%09%5Eobject'),
  1143. messageSends: ["new", "do:", "instanceVariableNames", "class", "basicAt:put:", "asJSONObject", "instVarAt:"],
  1144. referencedClasses: ["Object"]
  1145. }),
  1146. smalltalk.Object);
  1147. smalltalk.addMethod(
  1148. unescape('_halt'),
  1149. smalltalk.method({
  1150. selector: unescape('halt'),
  1151. category: 'error handling',
  1152. fn: function (){
  1153. var self=this;
  1154. smalltalk.send(self, "_error_", ["Halt encountered"]);
  1155. return self;},
  1156. args: [],
  1157. source: unescape('halt%0A%09self%20error%3A%20%27Halt%20encountered%27'),
  1158. messageSends: ["error:"],
  1159. referencedClasses: []
  1160. }),
  1161. smalltalk.Object);
  1162. smalltalk.addMethod(
  1163. unescape('_log_block_'),
  1164. smalltalk.method({
  1165. selector: unescape('log%3Ablock%3A'),
  1166. category: 'printing',
  1167. fn: function (aString, aBlock){
  1168. var self=this;
  1169. var result=nil;
  1170. smalltalk.send((typeof console == 'undefined' ? nil : console), "_log_", [smalltalk.send(smalltalk.send(aString, "__comma", [" time: "]), "__comma", [smalltalk.send(smalltalk.send((smalltalk.Date || Date), "_millisecondsToRun_", [(function(){return result=smalltalk.send(aBlock, "_value", []);})]), "_printString", [])])]);
  1171. return result;
  1172. return self;},
  1173. args: ["aString", "aBlock"],
  1174. source: unescape('log%3A%20aString%20block%3A%20aBlock%0A%0A%09%7C%20result%20%7C%0A%09console%20log%3A%20%20aString%2C%20%20%27%20time%3A%20%27%2C%20%28Date%20millisecondsToRun%3A%20%5Bresult%20%3A%3D%20aBlock%20value%5D%29%20printString.%0A%09%5Eresult'),
  1175. messageSends: ["log:", unescape("%2C"), "printString", "millisecondsToRun:", "value"],
  1176. referencedClasses: ["Date"]
  1177. }),
  1178. smalltalk.Object);
  1179. smalltalk.addMethod(
  1180. unescape('__eq_eq'),
  1181. smalltalk.method({
  1182. selector: unescape('%3D%3D'),
  1183. category: 'comparing',
  1184. fn: function (anObject){
  1185. var self=this;
  1186. return self === anObject;
  1187. return self;},
  1188. args: ["anObject"],
  1189. source: unescape('%3D%3D%20anObject%0A%09%3Creturn%20self%20%3D%3D%3D%20anObject%3E'),
  1190. messageSends: [],
  1191. referencedClasses: []
  1192. }),
  1193. smalltalk.Object);
  1194. smalltalk.addMethod(
  1195. unescape('_%7E%7E'),
  1196. smalltalk.method({
  1197. selector: unescape('%7E%7E'),
  1198. category: 'comparing',
  1199. fn: function (anObject){
  1200. var self=this;
  1201. return smalltalk.send(smalltalk.send(self, "__eq_eq", [anObject]), "__eq", [false]);
  1202. return self;},
  1203. args: ["anObject"],
  1204. source: unescape('%7E%7E%20anObject%0A%09%5E%28self%20%3D%3D%20anObject%29%20%3D%20false'),
  1205. messageSends: [unescape("%3D"), unescape("%3D%3D")],
  1206. referencedClasses: []
  1207. }),
  1208. smalltalk.Object);
  1209. smalltalk.addMethod(
  1210. unescape('_deprecatedAPI'),
  1211. smalltalk.method({
  1212. selector: unescape('deprecatedAPI'),
  1213. category: 'error handling',
  1214. fn: function (){
  1215. var self=this;
  1216. smalltalk.send((typeof console == 'undefined' ? nil : console), "_warn_", [smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.getThisContext()), "_home", []), "_asString", []), "__comma", [unescape("%20is%20deprecated%21")])]);
  1217. return self;},
  1218. args: [],
  1219. source: unescape('deprecatedAPI%0A%09%22Just%20a%20simple%20way%20to%20deprecate%20methods.%0A%09%23deprecatedAPI%20is%20in%20the%20%27error%20handling%27%20protocol%20even%20if%20it%20doesn%27t%20throw%20an%20error%2C%0A%09but%20it%20could%20in%20the%20future.%22%0A%09console%20warn%3A%20thisContext%20home%20asString%2C%20%27%20is%20deprecated%21%27'),
  1220. messageSends: ["warn:", unescape("%2C"), "asString", "home"],
  1221. referencedClasses: []
  1222. }),
  1223. smalltalk.Object);
  1224. smalltalk.addMethod(
  1225. unescape('_storeString'),
  1226. smalltalk.method({
  1227. selector: unescape('storeString'),
  1228. category: 'printing',
  1229. fn: function (){
  1230. var self=this;
  1231. return smalltalk.send((smalltalk.String || String), "_streamContents_", [(function(s){return smalltalk.send(self, "_storeOn_", [s]);})]);
  1232. return self;},
  1233. args: [],
  1234. source: unescape('storeString%0A%09%22Answer%20a%20String%20representation%20of%20the%20receiver%20from%20which%20the%20receiver%20%0A%09can%20be%20reconstructed.%22%0A%0A%09%5E%20String%20streamContents%3A%20%5B%3As%20%7C%20self%20storeOn%3A%20s%5D'),
  1235. messageSends: ["streamContents:", "storeOn:"],
  1236. referencedClasses: ["String"]
  1237. }),
  1238. smalltalk.Object);
  1239. smalltalk.addMethod(
  1240. unescape('_storeOn_'),
  1241. smalltalk.method({
  1242. selector: unescape('storeOn%3A'),
  1243. category: 'printing',
  1244. fn: function (aStream){
  1245. var self=this;
  1246. smalltalk.send(aStream, "_nextPutAll_", [smalltalk.send(self, "_printString", [])]);
  1247. return self;},
  1248. args: ["aStream"],
  1249. source: unescape('storeOn%3A%20aStream%0A%09aStream%20nextPutAll%3A%20self%20printString'),
  1250. messageSends: ["nextPutAll:", "printString"],
  1251. referencedClasses: []
  1252. }),
  1253. smalltalk.Object);
  1254. smalltalk.addMethod(
  1255. unescape('_initialize'),
  1256. smalltalk.method({
  1257. selector: unescape('initialize'),
  1258. category: 'initialization',
  1259. fn: function (){
  1260. var self=this;
  1261. return self;},
  1262. args: [],
  1263. source: unescape('initialize%0A%09%22no%20op%22'),
  1264. messageSends: [],
  1265. referencedClasses: []
  1266. }),
  1267. smalltalk.Object.klass);
  1268. smalltalk.addClass('Smalltalk', smalltalk.Object, [], 'Kernel');
  1269. smalltalk.addMethod(
  1270. unescape('_classes'),
  1271. smalltalk.method({
  1272. selector: unescape('classes'),
  1273. category: 'accessing',
  1274. fn: function (){
  1275. var self=this;
  1276. return self.classes();
  1277. return self;},
  1278. args: [],
  1279. source: unescape('classes%0A%09%3Creturn%20self.classes%28%29%3E'),
  1280. messageSends: [],
  1281. referencedClasses: []
  1282. }),
  1283. smalltalk.Smalltalk);
  1284. smalltalk.addMethod(
  1285. unescape('_at_'),
  1286. smalltalk.method({
  1287. selector: unescape('at%3A'),
  1288. category: 'accessing',
  1289. fn: function (aString){
  1290. var self=this;
  1291. return self[aString];
  1292. return self;},
  1293. args: ["aString"],
  1294. source: unescape('at%3A%20aString%0A%09%3Creturn%20self%5BaString%5D%3E'),
  1295. messageSends: [],
  1296. referencedClasses: []
  1297. }),
  1298. smalltalk.Smalltalk);
  1299. smalltalk.addMethod(
  1300. unescape('_removeClass_'),
  1301. smalltalk.method({
  1302. selector: unescape('removeClass%3A'),
  1303. category: 'classes',
  1304. fn: function (aClass){
  1305. var self=this;
  1306. ((($receiver = smalltalk.send(aClass, "_isMetaclass", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self, "_error_", [smalltalk.send(smalltalk.send(aClass, "_asString", []), "__comma", [unescape("%20is%20a%20Metaclass%20and%20cannot%20be%20removed%21")])]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(self, "_error_", [smalltalk.send(smalltalk.send(aClass, "_asString", []), "__comma", [unescape("%20is%20a%20Metaclass%20and%20cannot%20be%20removed%21")])]);})]));
  1307. smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_methodDictionary", []), "_values", []), "_do_", [(function(each){return smalltalk.send(aClass, "_removeCompiledMethod_", [each]);})]);
  1308. smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_class", []), "_methodDictionary", []), "_values", []), "_do_", [(function(each){return smalltalk.send(smalltalk.send(aClass, "_class", []), "_removeCompiledMethod_", [each]);})]);
  1309. smalltalk.send(self, "_basicDelete_", [smalltalk.send(aClass, "_name", [])]);
  1310. return self;},
  1311. args: ["aClass"],
  1312. source: unescape('removeClass%3A%20aClass%0A%09aClass%20isMetaclass%20ifTrue%3A%20%5Bself%20error%3A%20aClass%20asString%2C%20%27%20is%20a%20Metaclass%20and%20cannot%20be%20removed%21%27%5D.%0A%09aClass%20methodDictionary%20values%20do%3A%20%5B%3Aeach%20%7C%0A%09%09aClass%20removeCompiledMethod%3A%20each%5D.%0A%09aClass%20class%20methodDictionary%20values%20do%3A%20%5B%3Aeach%20%7C%0A%09%09aClass%20class%20removeCompiledMethod%3A%20each%5D.%0A%09self%20basicDelete%3A%20aClass%20name'),
  1313. messageSends: ["ifTrue:", "isMetaclass", "error:", unescape("%2C"), "asString", "do:", "values", "methodDictionary", "removeCompiledMethod:", "class", "basicDelete:", "name"],
  1314. referencedClasses: []
  1315. }),
  1316. smalltalk.Smalltalk);
  1317. smalltalk.addMethod(
  1318. unescape('_basicParse_'),
  1319. smalltalk.method({
  1320. selector: unescape('basicParse%3A'),
  1321. category: 'accessing',
  1322. fn: function (aString){
  1323. var self=this;
  1324. return smalltalk.parser.parse(aString);
  1325. return self;},
  1326. args: ["aString"],
  1327. source: unescape('basicParse%3A%20aString%0A%09%3Creturn%20smalltalk.parser.parse%28aString%29%3E'),
  1328. messageSends: [],
  1329. referencedClasses: []
  1330. }),
  1331. smalltalk.Smalltalk);
  1332. smalltalk.addMethod(
  1333. unescape('_parse_'),
  1334. smalltalk.method({
  1335. selector: unescape('parse%3A'),
  1336. category: 'accessing',
  1337. fn: function (aString){
  1338. var self=this;
  1339. var result=nil;
  1340. smalltalk.send(self, "_try_catch_", [(function(){return result=smalltalk.send(self, "_basicParse_", [aString]);}), (function(ex){return smalltalk.send(smalltalk.send(self, "_parseError_parsing_", [ex, aString]), "_signal", []);})]);
  1341. return result;
  1342. return self;},
  1343. args: ["aString"],
  1344. source: unescape('parse%3A%20aString%0A%09%7C%20result%20%7C%20%0A%09self%20try%3A%20%5Bresult%20%3A%3D%20self%20basicParse%3A%20aString%5D%20catch%3A%20%5B%3Aex%20%7C%20%28self%20parseError%3A%20ex%20parsing%3A%20aString%29%20signal%5D.%0A%09%5Eresult'),
  1345. messageSends: ["try:catch:", "basicParse:", "signal", "parseError:parsing:"],
  1346. referencedClasses: []
  1347. }),
  1348. smalltalk.Smalltalk);
  1349. smalltalk.addMethod(
  1350. unescape('_parseError_parsing_'),
  1351. smalltalk.method({
  1352. selector: unescape('parseError%3Aparsing%3A'),
  1353. category: 'accessing',
  1354. fn: function (anException, aString){
  1355. var self=this;
  1356. var row=nil;
  1357. var col=nil;
  1358. var message=nil;
  1359. var lines=nil;
  1360. var badLine=nil;
  1361. var code=nil;
  1362. row = anException.line;
  1363. col = anException.column;
  1364. message = anException.message;;
  1365. lines=smalltalk.send(aString, "_lines", []);
  1366. badLine=smalltalk.send(lines, "_at_", [row]);
  1367. badLine=smalltalk.send(smalltalk.send(smalltalk.send(badLine, "_copyFrom_to_", [(1), ((($receiver = col).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)]))]), "__comma", [unescape("%20%3D%3D%3D%3E")]), "__comma", [smalltalk.send(badLine, "_copyFrom_to_", [col, smalltalk.send(badLine, "_size", [])])]);
  1368. smalltalk.send(lines, "_at_put_", [row, badLine]);
  1369. code=smalltalk.send((smalltalk.String || String), "_streamContents_", [(function(s){return smalltalk.send(lines, "_withIndexDo_", [(function(l, i){return smalltalk.send(s, "_nextPutAll_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(i, "_asString", []), "__comma", [": "]), "__comma", [l]), "__comma", [smalltalk.send((smalltalk.String || String), "_lf", [])])]);})]);})]);
  1370. return smalltalk.send(smalltalk.send((smalltalk.Error || Error), "_new", []), "_messageText_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send("Parse error on line ", "__comma", [row]), "__comma", [" column "]), "__comma", [col]), "__comma", [" : "]), "__comma", [message]), "__comma", [unescape("%20Below%20is%20code%20with%20line%20numbers%20and%20%3D%3D%3D%3E%20marker%20inserted%3A")]), "__comma", [smalltalk.send((smalltalk.String || String), "_lf", [])]), "__comma", [code])]);
  1371. return self;},
  1372. args: ["anException", "aString"],
  1373. source: unescape('parseError%3A%20anException%20parsing%3A%20aString%0A%09%7C%20row%20col%20message%20lines%20badLine%20code%20%7C%0A%09%3Crow%20%3D%20anException.line%3B%0A%09col%20%3D%20anException.column%3B%0A%09message%20%3D%20anException.message%3B%3E.%0A%09lines%20%3A%3D%20aString%20lines.%0A%09badLine%20%3A%3D%20lines%20at%3A%20row.%0A%09badLine%20%3A%3D%20%28badLine%20copyFrom%3A%201%20to%3A%20col%20-%201%29%2C%20%27%20%3D%3D%3D%3E%27%2C%20%28badLine%20copyFrom%3A%20%20col%20to%3A%20badLine%20size%29.%0A%09lines%20at%3A%20row%20put%3A%20badLine.%0A%09code%20%3A%3D%20String%20streamContents%3A%20%5B%3As%20%7C%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20lines%20withIndexDo%3A%20%5B%3Al%20%3Ai%20%7C%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20s%20nextPutAll%3A%20i%20asString%2C%20%27%3A%20%27%2C%20l%2C%20String%20lf%5D%5D.%0A%09%5E%20Error%20new%20messageText%3A%20%28%27Parse%20error%20on%20line%20%27%20%2C%20row%20%2C%20%27%20column%20%27%20%2C%20col%20%2C%20%27%20%3A%20%27%20%2C%20message%20%2C%20%27%20Below%20is%20code%20with%20line%20numbers%20and%20%3D%3D%3D%3E%20marker%20inserted%3A%27%20%2C%20String%20lf%2C%20code%29'),
  1374. messageSends: ["lines", "at:", unescape("%2C"), "copyFrom:to:", unescape("-"), "size", "at:put:", "streamContents:", "withIndexDo:", "nextPutAll:", "asString", "lf", "messageText:", "new"],
  1375. referencedClasses: ["String", "Error"]
  1376. }),
  1377. smalltalk.Smalltalk);
  1378. smalltalk.addMethod(
  1379. unescape('_packages'),
  1380. smalltalk.method({
  1381. selector: unescape('packages'),
  1382. category: 'packages',
  1383. fn: function (){
  1384. var self=this;
  1385. return self.packages.all();
  1386. return self;},
  1387. args: [],
  1388. source: unescape('packages%0A%09%22Return%20all%20Package%20instances%20in%20the%20system.%22%0A%0A%09%3Creturn%20self.packages.all%28%29%3E'),
  1389. messageSends: [],
  1390. referencedClasses: []
  1391. }),
  1392. smalltalk.Smalltalk);
  1393. smalltalk.addMethod(
  1394. unescape('_packageAt_'),
  1395. smalltalk.method({
  1396. selector: unescape('packageAt%3A'),
  1397. category: 'packages',
  1398. fn: function (packageName){
  1399. var self=this;
  1400. return self.packages[packageName];
  1401. return self;},
  1402. args: ["packageName"],
  1403. source: unescape('packageAt%3A%20packageName%0A%20%20%20%20%20%20%20%3Creturn%20self.packages%5BpackageName%5D%3E'),
  1404. messageSends: [],
  1405. referencedClasses: []
  1406. }),
  1407. smalltalk.Smalltalk);
  1408. smalltalk.addMethod(
  1409. unescape('_packageAt_ifAbsent_'),
  1410. smalltalk.method({
  1411. selector: unescape('packageAt%3AifAbsent%3A'),
  1412. category: 'packages',
  1413. fn: function (packageName, aBlock){
  1414. var self=this;
  1415. return smalltalk.send(smalltalk.send(self, "_packageAt_", [packageName]), "_ifNil_", [aBlock]);
  1416. return self;},
  1417. args: ["packageName", "aBlock"],
  1418. source: unescape('packageAt%3A%20packageName%20ifAbsent%3A%20aBlock%0A%20%20%20%20%20%20%20%5E%28self%20packageAt%3A%20packageName%29%20ifNil%3A%20aBlock'),
  1419. messageSends: ["ifNil:", "packageAt:"],
  1420. referencedClasses: []
  1421. }),
  1422. smalltalk.Smalltalk);
  1423. smalltalk.addMethod(
  1424. unescape('_createPackage_'),
  1425. smalltalk.method({
  1426. selector: unescape('createPackage%3A'),
  1427. category: 'private',
  1428. fn: function (packageName){
  1429. var self=this;
  1430. return smalltalk.addPackage(packageName, nil);
  1431. return self;},
  1432. args: ["packageName"],
  1433. source: unescape('createPackage%3A%20packageName%0A%09%22Create%20and%20bind%20a%20new%20package%20with%20given%20name%20and%20return%20it.%22%0A%0A%20%20%20%20%20%20%3Creturn%20smalltalk.addPackage%28packageName%2C%20nil%29%3E'),
  1434. messageSends: [],
  1435. referencedClasses: []
  1436. }),
  1437. smalltalk.Smalltalk);
  1438. smalltalk.addMethod(
  1439. unescape('_deletePackage_'),
  1440. smalltalk.method({
  1441. selector: unescape('deletePackage%3A'),
  1442. category: 'private',
  1443. fn: function (packageName){
  1444. var self=this;
  1445. delete smalltalk.packages[packageName];
  1446. return self;},
  1447. args: ["packageName"],
  1448. source: unescape('deletePackage%3A%20packageName%0A%09%22Deletes%20a%20package%20by%20deleting%20its%20binding%2C%20but%20does%20not%20check%20if%20it%20contains%20classes%20etc.%0A%09To%20remove%20a%20package%2C%20use%20%23removePackage%20instead.%22%0A%0A%20%20%20%20%20%20%20%3Cdelete%20smalltalk.packages%5BpackageName%5D%3E'),
  1449. messageSends: [],
  1450. referencedClasses: []
  1451. }),
  1452. smalltalk.Smalltalk);
  1453. smalltalk.addMethod(
  1454. unescape('_removePackage_'),
  1455. smalltalk.method({
  1456. selector: unescape('removePackage%3A'),
  1457. category: 'packages',
  1458. fn: function (packageName){
  1459. var self=this;
  1460. var pkg=nil;
  1461. pkg=smalltalk.send(self, "_packageAt_ifAbsent_", [packageName, (function(){return smalltalk.send(self, "_error_", [smalltalk.send("Missing package: ", "__comma", [packageName])]);})]);
  1462. smalltalk.send(smalltalk.send(pkg, "_classes", []), "_do_", [(function(each){return smalltalk.send(self, "_removeClass_", [each]);})]);
  1463. smalltalk.send(self, "_deletePackage_", [packageName]);
  1464. return self;},
  1465. args: ["packageName"],
  1466. source: unescape('removePackage%3A%20packageName%0A%09%22Removes%20a%20package%20and%20all%20its%20classes.%22%0A%0A%09%7C%20pkg%20%7C%0A%09pkg%20%3A%3D%20self%20packageAt%3A%20packageName%20ifAbsent%3A%20%5Bself%20error%3A%20%27Missing%20package%3A%20%27%2C%20packageName%5D.%0A%09pkg%20classes%20do%3A%20%5B%3Aeach%20%7C%0A%20%20%20%20%20%20%20%20%09self%20removeClass%3A%20each%5D.%0A%09self%20deletePackage%3A%20packageName'),
  1467. messageSends: ["packageAt:ifAbsent:", "error:", unescape("%2C"), "do:", "classes", "removeClass:", "deletePackage:"],
  1468. referencedClasses: []
  1469. }),
  1470. smalltalk.Smalltalk);
  1471. smalltalk.addMethod(
  1472. unescape('_renamePackage_to_'),
  1473. smalltalk.method({
  1474. selector: unescape('renamePackage%3Ato%3A'),
  1475. category: 'packages',
  1476. fn: function (packageName, newName){
  1477. var self=this;
  1478. var pkg=nil;
  1479. pkg=smalltalk.send(self, "_packageAt_ifAbsent_", [packageName, (function(){return smalltalk.send(self, "_error_", [smalltalk.send("Missing package: ", "__comma", [packageName])]);})]);
  1480. (($receiver = smalltalk.send(self, "_packageAt_", [newName])) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self, "_error_", [smalltalk.send("Already exists a package called: ", "__comma", [newName])]);})() : nil;
  1481. smalltalk.packages[newName] = smalltalk.packages[packageName];
  1482. smalltalk.send(pkg, "_name_", [newName]);
  1483. smalltalk.send(self, "_deletePackage_", [packageName]);
  1484. return self;},
  1485. args: ["packageName", "newName"],
  1486. source: unescape('renamePackage%3A%20packageName%20to%3A%20newName%0A%09%22Rename%20a%20package.%22%0A%0A%09%7C%20pkg%20%7C%0A%09pkg%20%3A%3D%20self%20packageAt%3A%20packageName%20ifAbsent%3A%20%5Bself%20error%3A%20%27Missing%20package%3A%20%27%2C%20packageName%5D.%0A%09%28self%20packageAt%3A%20newName%29%20ifNotNil%3A%20%5Bself%20error%3A%20%27Already%20exists%20a%20package%20called%3A%20%27%2C%20newName%5D.%0A%09%3Csmalltalk.packages%5BnewName%5D%20%3D%20smalltalk.packages%5BpackageName%5D%3E.%0A%09pkg%20name%3A%20newName.%0A%09self%20deletePackage%3A%20packageName.'),
  1487. messageSends: ["packageAt:ifAbsent:", "error:", unescape("%2C"), "ifNotNil:", "packageAt:", "name:", "deletePackage:"],
  1488. referencedClasses: []
  1489. }),
  1490. smalltalk.Smalltalk);
  1491. smalltalk.addMethod(
  1492. unescape('_reservedWords'),
  1493. smalltalk.method({
  1494. selector: unescape('reservedWords'),
  1495. category: 'accessing',
  1496. fn: function (){
  1497. var self=this;
  1498. return self.reservedWords;
  1499. return self;},
  1500. args: [],
  1501. source: unescape('reservedWords%0A%09%22JavaScript%20reserved%20words%22%0A%09%3Creturn%20self.reservedWords%3E'),
  1502. messageSends: [],
  1503. referencedClasses: []
  1504. }),
  1505. smalltalk.Smalltalk);
  1506. smalltalk.addMethod(
  1507. unescape('_createPackage_properties_'),
  1508. smalltalk.method({
  1509. selector: unescape('createPackage%3Aproperties%3A'),
  1510. category: 'private',
  1511. fn: function (packageName, aDict){
  1512. var self=this;
  1513. var object=nil;
  1514. object = {};;
  1515. smalltalk.send(aDict, "_keysAndValuesDo_", [(function(key, value){return object[key] = value;})]);
  1516. return smalltalk.addPackage(packageName, object);
  1517. return self;},
  1518. args: ["packageName", "aDict"],
  1519. source: unescape('createPackage%3A%20packageName%20properties%3A%20aDict%0A%09%22Create%20and%20bind%20a%20new%20package%20with%20given%20name%20and%20return%20it.%22%0A%0A%09%7C%20object%20%7C%0A%09%3Cobject%20%3D%20%7B%7D%3B%3E.%0A%09aDict%20keysAndValuesDo%3A%20%5B%3Akey%20%3Avalue%20%7C%0A%09%09%3Cobject%5Bkey%5D%20%3D%20value%3E.%0A%09%5D.%0A%20%20%20%20%20%20%20%3Creturn%20smalltalk.addPackage%28packageName%2C%20object%29%3E'),
  1520. messageSends: ["keysAndValuesDo:"],
  1521. referencedClasses: []
  1522. }),
  1523. smalltalk.Smalltalk);
  1524. smalltalk.addMethod(
  1525. unescape('_readJSObject_'),
  1526. smalltalk.method({
  1527. selector: unescape('readJSObject%3A'),
  1528. category: 'accessing',
  1529. fn: function (anObject){
  1530. var self=this;
  1531. return self.readJSObject(anObject);
  1532. return self;},
  1533. args: ["anObject"],
  1534. source: unescape('readJSObject%3A%20anObject%0A%09%3Creturn%20self.readJSObject%28anObject%29%3E'),
  1535. messageSends: [],
  1536. referencedClasses: []
  1537. }),
  1538. smalltalk.Smalltalk);
  1539. smalltalk.Smalltalk.klass.iVarNames = ['current'];
  1540. smalltalk.addMethod(
  1541. unescape('_current'),
  1542. smalltalk.method({
  1543. selector: unescape('current'),
  1544. category: 'accessing',
  1545. fn: function (){
  1546. var self=this;
  1547. return smalltalk;
  1548. return self;},
  1549. args: [],
  1550. source: unescape('current%0A%09%3Creturn%20smalltalk%3E'),
  1551. messageSends: [],
  1552. referencedClasses: []
  1553. }),
  1554. smalltalk.Smalltalk.klass);
  1555. smalltalk.addClass('Package', smalltalk.Object, [], 'Kernel');
  1556. smalltalk.Package.comment=unescape('A%20Package%20is%20similar%20to%20a%20%22class%20category%22%20typically%20found%20in%20other%20Smalltalks%20like%20Pharo%20or%20Squeak.%20Amber%20does%20not%20have%20class%20categories%20anymore%2C%20it%20had%20in%20the%20beginning%20but%20now%20each%20class%20in%20the%20system%20knows%20which%20package%20it%20belongs%20to.%0A%0AA%20Package%20has%20a%20name%2C%20an%20Array%20of%20%22requires%22%2C%20a%20comment%20and%20a%20Dictionary%20with%20other%20optional%20key%20value%20attributes.%20A%20Package%20can%20also%20be%20queried%20for%20its%20classes%2C%20but%20it%20will%20then%20resort%20to%20a%20reverse%20scan%20of%20all%20classes%20to%20find%20them.%0APackages%20are%20manipulated%20through%20%22Smalltalk%20current%22%2C%20like%20for%20example%20finding%20one%20based%20on%20a%20name%3A%0A%0A%09Smalltalk%20current%20packageAt%3A%20%27Kernel%27%0A%0A...but%20you%20can%20also%20use%3A%0A%0A%09Package%20named%3A%20%27Kernel%27%0A%0AA%20Package%20differs%20slightly%20from%20a%20Monticello%20package%20which%20can%20span%20multiple%20class%20categories%20using%20a%20naming%20convention%20based%20on%20hyphenation.%20But%20just%20as%20in%20Monticello%20a%20Package%20supports%20%22class%20extensions%22%20so%20a%20Package%0Acan%20define%20behaviors%20in%20foreign%20classes%20using%20a%20naming%20convention%20for%20method%20categories%20where%20the%20category%20starts%20with%20an%20asterisk%20and%20then%20the%20name%20of%20the%20owning%20package%20follows.%20This%20can%20easily%20be%20seen%20in%20for%20example%20class%0AString%20where%20the%20method%20category%20%22*IDE%22%20defines%20%23inspectOn%3A%20which%20thus%20is%20a%20method%20belonging%20to%20the%20IDE%20package.')
  1557. smalltalk.addMethod(
  1558. unescape('_name'),
  1559. smalltalk.method({
  1560. selector: unescape('name'),
  1561. category: 'accessing',
  1562. fn: function (){
  1563. var self=this;
  1564. return self.pkgName;
  1565. return self;},
  1566. args: [],
  1567. source: unescape('name%0A%09%3Creturn%20self.pkgName%3E'),
  1568. messageSends: [],
  1569. referencedClasses: []
  1570. }),
  1571. smalltalk.Package);
  1572. smalltalk.addMethod(
  1573. unescape('_name_'),
  1574. smalltalk.method({
  1575. selector: unescape('name%3A'),
  1576. category: 'accessing',
  1577. fn: function (aString){
  1578. var self=this;
  1579. return self.pkgName = aString;
  1580. return self;},
  1581. args: ["aString"],
  1582. source: unescape('name%3A%20aString%0A%09%3Creturn%20self.pkgName%20%3D%20aString%3E'),
  1583. messageSends: [],
  1584. referencedClasses: []
  1585. }),
  1586. smalltalk.Package);
  1587. smalltalk.addMethod(
  1588. unescape('_classes'),
  1589. smalltalk.method({
  1590. selector: unescape('classes'),
  1591. category: 'classes',
  1592. fn: function (){
  1593. var self=this;
  1594. return smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_classes", []), "_select_", [(function(c){return smalltalk.send(smalltalk.send(c, "_package", []), "__eq_eq", [self]);})]);
  1595. return self;},
  1596. args: [],
  1597. source: unescape('classes%0A%09%22We%20need%20to%20do%20a%20reverse%20scan.%22%0A%09%5ESmalltalk%20current%20classes%20select%3A%20%5B%3Ac%20%7C%20c%20package%20%3D%3D%20self%5D'),
  1598. messageSends: ["select:", "classes", "current", unescape("%3D%3D"), "package"],
  1599. referencedClasses: ["Smalltalk"]
  1600. }),
  1601. smalltalk.Package);
  1602. smalltalk.addMethod(
  1603. unescape('_printString'),
  1604. smalltalk.method({
  1605. selector: unescape('printString'),
  1606. category: 'printing',
  1607. fn: function (){
  1608. var self=this;
  1609. return smalltalk.send(self, "_name", []);
  1610. return self;},
  1611. args: [],
  1612. source: unescape('printString%0A%09%5Eself%20name'),
  1613. messageSends: ["name"],
  1614. referencedClasses: []
  1615. }),
  1616. smalltalk.Package);
  1617. smalltalk.addMethod(
  1618. unescape('_dependencies'),
  1619. smalltalk.method({
  1620. selector: unescape('dependencies'),
  1621. category: 'accessing',
  1622. fn: function (){
  1623. var self=this;
  1624. return smalltalk.send(self, "_propertyAt_ifAbsent_", ["dependencies", (function(){return [];})]);
  1625. return self;},
  1626. args: [],
  1627. source: unescape('dependencies%0A%09%5Eself%20propertyAt%3A%20%27dependencies%27%20ifAbsent%3A%20%5B%23%28%29%5D'),
  1628. messageSends: ["propertyAt:ifAbsent:"],
  1629. referencedClasses: []
  1630. }),
  1631. smalltalk.Package);
  1632. smalltalk.addMethod(
  1633. unescape('_dependencies_'),
  1634. smalltalk.method({
  1635. selector: unescape('dependencies%3A'),
  1636. category: 'accessing',
  1637. fn: function (anArray){
  1638. var self=this;
  1639. return smalltalk.send(self, "_propertyAt_put_", ["dependencies", anArray]);
  1640. return self;},
  1641. args: ["anArray"],
  1642. source: unescape('dependencies%3A%20anArray%0A%09%5Eself%20propertyAt%3A%20%27dependencies%27%20put%3A%20anArray'),
  1643. messageSends: ["propertyAt:put:"],
  1644. referencedClasses: []
  1645. }),
  1646. smalltalk.Package);
  1647. smalltalk.addMethod(
  1648. unescape('_properties'),
  1649. smalltalk.method({
  1650. selector: unescape('properties'),
  1651. category: 'accessing',
  1652. fn: function (){
  1653. var self=this;
  1654. return smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_readJSObject_", [smalltalk.send(self, "_basicAt_", ["properties"])]);
  1655. return self;},
  1656. args: [],
  1657. source: unescape('properties%0A%09%5ESmalltalk%20current%20readJSObject%3A%20%28self%20basicAt%3A%20%27properties%27%29'),
  1658. messageSends: ["readJSObject:", "current", "basicAt:"],
  1659. referencedClasses: ["Smalltalk"]
  1660. }),
  1661. smalltalk.Package);
  1662. smalltalk.addMethod(
  1663. unescape('_propertiesAsJSON'),
  1664. smalltalk.method({
  1665. selector: unescape('propertiesAsJSON'),
  1666. category: 'private',
  1667. fn: function (){
  1668. var self=this;
  1669. return JSON.stringify(self.properties);
  1670. return self;},
  1671. args: [],
  1672. source: unescape('propertiesAsJSON%0A%09%3Creturn%20JSON.stringify%28self.properties%29%3E'),
  1673. messageSends: [],
  1674. referencedClasses: []
  1675. }),
  1676. smalltalk.Package);
  1677. smalltalk.addMethod(
  1678. unescape('_properties_'),
  1679. smalltalk.method({
  1680. selector: unescape('properties%3A'),
  1681. category: 'accessing',
  1682. fn: function (aDict){
  1683. var self=this;
  1684. var object=nil;
  1685. object = {};;
  1686. smalltalk.send(aDict, "_keysAndValuesDo_", [(function(key, value){return object[key] = value;})]);
  1687. return self.properties = object;
  1688. return self;},
  1689. args: ["aDict"],
  1690. source: unescape('properties%3A%20aDict%0A%09%22We%20store%20it%20as%20a%20javascript%20object.%22%0A%09%0A%09%7C%20object%20%7C%0A%09%3Cobject%20%3D%20%7B%7D%3B%3E.%0A%09aDict%20keysAndValuesDo%3A%20%5B%3Akey%20%3Avalue%20%7C%0A%09%09%3Cobject%5Bkey%5D%20%3D%20value%3E.%0A%09%5D.%0A%09%3Creturn%20self.properties%20%3D%20object%3E'),
  1691. messageSends: ["keysAndValuesDo:"],
  1692. referencedClasses: []
  1693. }),
  1694. smalltalk.Package);
  1695. smalltalk.addMethod(
  1696. unescape('_jsProperties'),
  1697. smalltalk.method({
  1698. selector: unescape('jsProperties'),
  1699. category: 'private',
  1700. fn: function (){
  1701. var self=this;
  1702. return self.properties;
  1703. return self;},
  1704. args: [],
  1705. source: unescape('jsProperties%0A%09%3Creturn%20self.properties%3E'),
  1706. messageSends: [],
  1707. referencedClasses: []
  1708. }),
  1709. smalltalk.Package);
  1710. smalltalk.addMethod(
  1711. unescape('_jsProperties_'),
  1712. smalltalk.method({
  1713. selector: unescape('jsProperties%3A'),
  1714. category: 'private',
  1715. fn: function (aJSObject){
  1716. var self=this;
  1717. return self.properties = aJSObject;
  1718. return self;},
  1719. args: ["aJSObject"],
  1720. source: unescape('jsProperties%3A%20aJSObject%0A%09%3Creturn%20self.properties%20%3D%20aJSObject%3E'),
  1721. messageSends: [],
  1722. referencedClasses: []
  1723. }),
  1724. smalltalk.Package);
  1725. smalltalk.addMethod(
  1726. unescape('_propertyAt_'),
  1727. smalltalk.method({
  1728. selector: unescape('propertyAt%3A'),
  1729. category: 'properties',
  1730. fn: function (key){
  1731. var self=this;
  1732. return self.properties[key];
  1733. return self;},
  1734. args: ["key"],
  1735. source: unescape('propertyAt%3A%20key%0A%0A%09%3Creturn%20self.properties%5Bkey%5D%3E'),
  1736. messageSends: [],
  1737. referencedClasses: []
  1738. }),
  1739. smalltalk.Package);
  1740. smalltalk.addMethod(
  1741. unescape('_propertyAt_put_'),
  1742. smalltalk.method({
  1743. selector: unescape('propertyAt%3Aput%3A'),
  1744. category: 'properties',
  1745. fn: function (key, value){
  1746. var self=this;
  1747. return self.properties[key] = value;
  1748. return self;},
  1749. args: ["key", "value"],
  1750. source: unescape('propertyAt%3A%20key%20put%3A%20value%0A%0A%09%3Creturn%20self.properties%5Bkey%5D%20%3D%20value%3E'),
  1751. messageSends: [],
  1752. referencedClasses: []
  1753. }),
  1754. smalltalk.Package);
  1755. smalltalk.addMethod(
  1756. unescape('_propertyAt_ifAbsent_'),
  1757. smalltalk.method({
  1758. selector: unescape('propertyAt%3AifAbsent%3A'),
  1759. category: 'properties',
  1760. fn: function (key, block){
  1761. var self=this;
  1762. return (($receiver = smalltalk.send(self, "_propertyAt_", [key])) == nil || $receiver == undefined) ? (function(){return smalltalk.send(block, "_value", []);})() : $receiver;
  1763. return self;},
  1764. args: ["key", "block"],
  1765. source: unescape('propertyAt%3A%20key%20ifAbsent%3A%20block%0A%0A%09%5E%28self%20propertyAt%3A%20key%29%20ifNil%3A%20%5Bblock%20value%5D'),
  1766. messageSends: ["ifNil:", "propertyAt:", "value"],
  1767. referencedClasses: []
  1768. }),
  1769. smalltalk.Package);
  1770. smalltalk.addMethod(
  1771. unescape('_named_'),
  1772. smalltalk.method({
  1773. selector: unescape('named%3A'),
  1774. category: 'not yet classified',
  1775. fn: function (aPackageName){
  1776. var self=this;
  1777. return smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_packageAt_", [aPackageName]);
  1778. return self;},
  1779. args: ["aPackageName"],
  1780. source: unescape('named%3A%20aPackageName%0A%0A%09%5ESmalltalk%20current%20packageAt%3A%20aPackageName'),
  1781. messageSends: ["packageAt:", "current"],
  1782. referencedClasses: ["Smalltalk"]
  1783. }),
  1784. smalltalk.Package.klass);
  1785. smalltalk.addMethod(
  1786. unescape('_named_ifAbsent_'),
  1787. smalltalk.method({
  1788. selector: unescape('named%3AifAbsent%3A'),
  1789. category: 'not yet classified',
  1790. fn: function (aPackageName, aBlock){
  1791. var self=this;
  1792. return smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_packageAt_ifAbsent_", [aPackageName, aBlock]);
  1793. return self;},
  1794. args: ["aPackageName", "aBlock"],
  1795. source: unescape('named%3A%20aPackageName%20ifAbsent%3A%20aBlock%0A%0A%09%5ESmalltalk%20current%20packageAt%3A%20aPackageName%20ifAbsent%3A%20aBlock'),
  1796. messageSends: ["packageAt:ifAbsent:", "current"],
  1797. referencedClasses: ["Smalltalk"]
  1798. }),
  1799. smalltalk.Package.klass);
  1800. smalltalk.addClass('Behavior', smalltalk.Object, [], 'Kernel');
  1801. smalltalk.addMethod(
  1802. unescape('_new'),
  1803. smalltalk.method({
  1804. selector: unescape('new'),
  1805. category: 'instance creation',
  1806. fn: function (){
  1807. var self=this;
  1808. return smalltalk.send(smalltalk.send(self, "_basicNew", []), "_initialize", []);
  1809. return self;},
  1810. args: [],
  1811. source: unescape('new%0A%09%5Eself%20basicNew%20initialize'),
  1812. messageSends: ["initialize", "basicNew"],
  1813. referencedClasses: []
  1814. }),
  1815. smalltalk.Behavior);
  1816. smalltalk.addMethod(
  1817. unescape('_basicNew'),
  1818. smalltalk.method({
  1819. selector: unescape('basicNew'),
  1820. category: 'instance creation',
  1821. fn: function (){
  1822. var self=this;
  1823. return new self.fn();
  1824. return self;},
  1825. args: [],
  1826. source: unescape('basicNew%0A%09%3Creturn%20new%20self.fn%28%29%3E'),
  1827. messageSends: [],
  1828. referencedClasses: []
  1829. }),
  1830. smalltalk.Behavior);
  1831. smalltalk.addMethod(
  1832. unescape('_name'),
  1833. smalltalk.method({
  1834. selector: unescape('name'),
  1835. category: 'accessing',
  1836. fn: function (){
  1837. var self=this;
  1838. return self.className || nil;
  1839. return self;},
  1840. args: [],
  1841. source: unescape('name%0A%09%3Creturn%20self.className%20%7C%7C%20nil%3E'),
  1842. messageSends: [],
  1843. referencedClasses: []
  1844. }),
  1845. smalltalk.Behavior);
  1846. smalltalk.addMethod(
  1847. unescape('_superclass'),
  1848. smalltalk.method({
  1849. selector: unescape('superclass'),
  1850. category: 'accessing',
  1851. fn: function (){
  1852. var self=this;
  1853. return self.superclass || nil;
  1854. return self;},
  1855. args: [],
  1856. source: unescape('superclass%0A%09%3Creturn%20self.superclass%20%7C%7C%20nil%3E'),
  1857. messageSends: [],
  1858. referencedClasses: []
  1859. }),
  1860. smalltalk.Behavior);
  1861. smalltalk.addMethod(
  1862. unescape('_subclasses'),
  1863. smalltalk.method({
  1864. selector: unescape('subclasses'),
  1865. category: 'accessing',
  1866. fn: function (){
  1867. var self=this;
  1868. return smalltalk.subclasses(self);
  1869. return self;},
  1870. args: [],
  1871. source: unescape('subclasses%0A%09%3Creturn%20smalltalk.subclasses%28self%29%3E'),
  1872. messageSends: [],
  1873. referencedClasses: []
  1874. }),
  1875. smalltalk.Behavior);
  1876. smalltalk.addMethod(
  1877. unescape('_allSubclasses'),
  1878. smalltalk.method({
  1879. selector: unescape('allSubclasses'),
  1880. category: 'accessing',
  1881. fn: function (){
  1882. var self=this;
  1883. var result=nil;
  1884. result=smalltalk.send(self, "_subclasses", []);
  1885. smalltalk.send(smalltalk.send(self, "_subclasses", []), "_do_", [(function(each){return smalltalk.send(result, "_addAll_", [smalltalk.send(each, "_allSubclasses", [])]);})]);
  1886. return result;
  1887. return self;},
  1888. args: [],
  1889. source: unescape('allSubclasses%0A%09%7C%20result%20%7C%0A%09result%20%3A%3D%20self%20subclasses.%0A%09self%20subclasses%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20result%20addAll%3A%20each%20allSubclasses%5D.%0A%09%5Eresult'),
  1890. messageSends: ["subclasses", "do:", "addAll:", "allSubclasses"],
  1891. referencedClasses: []
  1892. }),
  1893. smalltalk.Behavior);
  1894. smalltalk.addMethod(
  1895. unescape('_withAllSubclasses'),
  1896. smalltalk.method({
  1897. selector: unescape('withAllSubclasses'),
  1898. category: 'accessing',
  1899. fn: function (){
  1900. var self=this;
  1901. return (function($rec){smalltalk.send($rec, "_addAll_", [smalltalk.send(self, "_allSubclasses", [])]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send((smalltalk.Array || Array), "_with_", [self]));
  1902. return self;},
  1903. args: [],
  1904. source: unescape('withAllSubclasses%0A%09%5E%28Array%20with%3A%20self%29%20addAll%3A%20self%20allSubclasses%3B%20yourself'),
  1905. messageSends: ["addAll:", "allSubclasses", "yourself", "with:"],
  1906. referencedClasses: ["Array"]
  1907. }),
  1908. smalltalk.Behavior);
  1909. smalltalk.addMethod(
  1910. unescape('_prototype'),
  1911. smalltalk.method({
  1912. selector: unescape('prototype'),
  1913. category: 'accessing',
  1914. fn: function (){
  1915. var self=this;
  1916. return self.fn.prototype;
  1917. return self;},
  1918. args: [],
  1919. source: unescape('prototype%0A%09%3Creturn%20self.fn.prototype%3E'),
  1920. messageSends: [],
  1921. referencedClasses: []
  1922. }),
  1923. smalltalk.Behavior);
  1924. smalltalk.addMethod(
  1925. unescape('_methodDictionary'),
  1926. smalltalk.method({
  1927. selector: unescape('methodDictionary'),
  1928. category: 'accessing',
  1929. fn: function (){
  1930. var self=this;
  1931. var dict = smalltalk.Dictionary._new();
  1932. var methods = self.fn.prototype.methods;
  1933. for(var i in methods) {
  1934. if(methods[i].selector) {
  1935. dict._at_put_(methods[i].selector, methods[i]);
  1936. }
  1937. };
  1938. return dict;
  1939. return self;},
  1940. args: [],
  1941. source: unescape('methodDictionary%0A%09%3Cvar%20dict%20%3D%20smalltalk.Dictionary._new%28%29%3B%0A%09var%20methods%20%3D%20self.fn.prototype.methods%3B%0A%09for%28var%20i%20in%20methods%29%20%7B%0A%09%09if%28methods%5Bi%5D.selector%29%20%7B%0A%09%09%09dict._at_put_%28methods%5Bi%5D.selector%2C%20methods%5Bi%5D%29%3B%0A%09%09%7D%0A%09%7D%3B%0A%09return%20dict%3E'),
  1942. messageSends: [],
  1943. referencedClasses: []
  1944. }),
  1945. smalltalk.Behavior);
  1946. smalltalk.addMethod(
  1947. unescape('_methodsFor_'),
  1948. smalltalk.method({
  1949. selector: unescape('methodsFor%3A'),
  1950. category: 'accessing',
  1951. fn: function (aString){
  1952. var self=this;
  1953. return (function($rec){smalltalk.send($rec, "_class_category_", [self, aString]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send((smalltalk.ClassCategoryReader || ClassCategoryReader), "_new", []));
  1954. return self;},
  1955. args: ["aString"],
  1956. source: unescape('methodsFor%3A%20aString%0A%09%5EClassCategoryReader%20new%0A%09%20%20%20%20class%3A%20self%20category%3A%20aString%3B%0A%09%20%20%20%20yourself'),
  1957. messageSends: ["class:category:", "yourself", "new"],
  1958. referencedClasses: ["ClassCategoryReader"]
  1959. }),
  1960. smalltalk.Behavior);
  1961. smalltalk.addMethod(
  1962. unescape('_addCompiledMethod_'),
  1963. smalltalk.method({
  1964. selector: unescape('addCompiledMethod%3A'),
  1965. category: 'accessing',
  1966. fn: function (aMethod){
  1967. var self=this;
  1968. smalltalk.addMethod(aMethod.selector._asSelector(), aMethod, self);
  1969. return self;},
  1970. args: ["aMethod"],
  1971. source: unescape('addCompiledMethod%3A%20aMethod%0A%09%3Csmalltalk.addMethod%28aMethod.selector._asSelector%28%29%2C%20aMethod%2C%20self%29%3E'),
  1972. messageSends: [],
  1973. referencedClasses: []
  1974. }),
  1975. smalltalk.Behavior);
  1976. smalltalk.addMethod(
  1977. unescape('_instanceVariableNames'),
  1978. smalltalk.method({
  1979. selector: unescape('instanceVariableNames'),
  1980. category: 'accessing',
  1981. fn: function (){
  1982. var self=this;
  1983. return self.iVarNames;
  1984. return self;},
  1985. args: [],
  1986. source: unescape('instanceVariableNames%0A%09%3Creturn%20self.iVarNames%3E'),
  1987. messageSends: [],
  1988. referencedClasses: []
  1989. }),
  1990. smalltalk.Behavior);
  1991. smalltalk.addMethod(
  1992. unescape('_comment'),
  1993. smalltalk.method({
  1994. selector: unescape('comment'),
  1995. category: 'accessing',
  1996. fn: function (){
  1997. var self=this;
  1998. return (($receiver = smalltalk.send(self, "_basicAt_", ["comment"])) == nil || $receiver == undefined) ? (function(){return "";})() : $receiver;
  1999. return self;},
  2000. args: [],
  2001. source: unescape('comment%0A%20%20%20%20%5E%28self%20basicAt%3A%20%27comment%27%29%20ifNil%3A%20%5B%27%27%5D'),
  2002. messageSends: ["ifNil:", "basicAt:"],
  2003. referencedClasses: []
  2004. }),
  2005. smalltalk.Behavior);
  2006. smalltalk.addMethod(
  2007. unescape('_comment_'),
  2008. smalltalk.method({
  2009. selector: unescape('comment%3A'),
  2010. category: 'accessing',
  2011. fn: function (aString){
  2012. var self=this;
  2013. smalltalk.send(self, "_basicAt_put_", ["comment", aString]);
  2014. return self;},
  2015. args: ["aString"],
  2016. source: unescape('comment%3A%20aString%0A%20%20%20%20self%20basicAt%3A%20%27comment%27%20put%3A%20aString'),
  2017. messageSends: ["basicAt:put:"],
  2018. referencedClasses: []
  2019. }),
  2020. smalltalk.Behavior);
  2021. smalltalk.addMethod(
  2022. unescape('_commentStamp'),
  2023. smalltalk.method({
  2024. selector: unescape('commentStamp'),
  2025. category: 'accessing',
  2026. fn: function (){
  2027. var self=this;
  2028. return (function($rec){smalltalk.send($rec, "_class_", [self]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send((smalltalk.ClassCommentReader || ClassCommentReader), "_new", []));
  2029. return self;},
  2030. args: [],
  2031. source: unescape('commentStamp%0A%20%20%20%20%5EClassCommentReader%20new%0A%09class%3A%20self%3B%0A%09yourself'),
  2032. messageSends: ["class:", "yourself", "new"],
  2033. referencedClasses: ["ClassCommentReader"]
  2034. }),
  2035. smalltalk.Behavior);
  2036. smalltalk.addMethod(
  2037. unescape('_removeCompiledMethod_'),
  2038. smalltalk.method({
  2039. selector: unescape('removeCompiledMethod%3A'),
  2040. category: 'accessing',
  2041. fn: function (aMethod){
  2042. var self=this;
  2043. delete self.fn.prototype[aMethod.selector._asSelector()];
  2044. delete self.fn.prototype.methods[aMethod.selector];
  2045. smalltalk.init(self);;
  2046. return self;},
  2047. args: ["aMethod"],
  2048. source: unescape('removeCompiledMethod%3A%20aMethod%0A%09%3Cdelete%20self.fn.prototype%5BaMethod.selector._asSelector%28%29%5D%3B%0A%09delete%20self.fn.prototype.methods%5BaMethod.selector%5D%3B%0A%09smalltalk.init%28self%29%3B%3E'),
  2049. messageSends: [],
  2050. referencedClasses: []
  2051. }),
  2052. smalltalk.Behavior);
  2053. smalltalk.addMethod(
  2054. unescape('_inheritsFrom_'),
  2055. smalltalk.method({
  2056. selector: unescape('inheritsFrom%3A'),
  2057. category: 'instance creation',
  2058. fn: function (aClass){
  2059. var self=this;
  2060. return smalltalk.send(smalltalk.send(aClass, "_allSubclasses", []), "_includes_", [self]);
  2061. return self;},
  2062. args: ["aClass"],
  2063. source: unescape('inheritsFrom%3A%20aClass%0A%09%5EaClass%20allSubclasses%20includes%3A%20self'),
  2064. messageSends: ["includes:", "allSubclasses"],
  2065. referencedClasses: []
  2066. }),
  2067. smalltalk.Behavior);
  2068. smalltalk.addMethod(
  2069. unescape('_protocols'),
  2070. smalltalk.method({
  2071. selector: unescape('protocols'),
  2072. category: 'accessing',
  2073. fn: function (){
  2074. var self=this;
  2075. var protocols=nil;
  2076. protocols=smalltalk.send((smalltalk.Array || Array), "_new", []);
  2077. smalltalk.send(smalltalk.send(self, "_methodDictionary", []), "_do_", [(function(each){return ((($receiver = smalltalk.send(protocols, "_includes_", [smalltalk.send(each, "_category", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(protocols, "_add_", [smalltalk.send(each, "_category", [])]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(protocols, "_add_", [smalltalk.send(each, "_category", [])]);})]));})]);
  2078. return smalltalk.send(protocols, "_sort", []);
  2079. return self;},
  2080. args: [],
  2081. source: unescape('protocols%0A%20%20%20%20%7C%20protocols%20%7C%0A%20%20%20%20protocols%20%3A%3D%20Array%20new.%0A%20%20%20%20self%20methodDictionary%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20%28protocols%20includes%3A%20each%20category%29%20ifFalse%3A%20%5B%0A%09%09protocols%20add%3A%20each%20category%5D%5D.%0A%20%20%20%20%5Eprotocols%20sort'),
  2082. messageSends: ["new", "do:", "methodDictionary", "ifFalse:", "includes:", "category", "add:", "sort"],
  2083. referencedClasses: ["Array"]
  2084. }),
  2085. smalltalk.Behavior);
  2086. smalltalk.addMethod(
  2087. unescape('_protocolsDo_'),
  2088. smalltalk.method({
  2089. selector: unescape('protocolsDo%3A'),
  2090. category: 'accessing',
  2091. fn: function (aBlock){
  2092. var self=this;
  2093. var methodsByCategory=nil;
  2094. methodsByCategory=smalltalk.send((smalltalk.Dictionary || Dictionary), "_new", []);
  2095. smalltalk.send(smalltalk.send(smalltalk.send(self, "_methodDictionary", []), "_values", []), "_do_", [(function(m){return smalltalk.send(smalltalk.send(methodsByCategory, "_at_ifAbsentPut_", [smalltalk.send(m, "_category", []), (function(){return smalltalk.send((smalltalk.Array || Array), "_new", []);})]), "_add_", [m]);})]);
  2096. smalltalk.send(smalltalk.send(self, "_protocols", []), "_do_", [(function(category){return smalltalk.send(aBlock, "_value_value_", [category, smalltalk.send(methodsByCategory, "_at_", [category])]);})]);
  2097. return self;},
  2098. args: ["aBlock"],
  2099. source: unescape('protocolsDo%3A%20aBlock%0A%09%22Execute%20aBlock%20for%20each%20method%20category%20with%0A%09its%20collection%20of%20methods%20in%20the%20sort%20order%20of%20category%20name.%22%0A%0A%09%7C%20methodsByCategory%20%7C%0A%09methodsByCategory%20%3A%3D%20Dictionary%20new.%0A%09self%20methodDictionary%20values%20do%3A%20%5B%3Am%20%7C%0A%09%09%28methodsByCategory%20at%3A%20m%20category%20ifAbsentPut%3A%20%5BArray%20new%5D%29%0A%20%09%09%09add%3A%20m%5D.%20%0A%09self%20protocols%20do%3A%20%5B%3Acategory%20%7C%0A%09%09aBlock%20value%3A%20category%20value%3A%20%28methodsByCategory%20at%3A%20category%29%5D'),
  2100. messageSends: ["new", "do:", "values", "methodDictionary", "add:", "at:ifAbsentPut:", "category", "protocols", "value:value:", "at:"],
  2101. referencedClasses: ["Dictionary", "Array"]
  2102. }),
  2103. smalltalk.Behavior);
  2104. smalltalk.addMethod(
  2105. unescape('_allInstanceVariableNames'),
  2106. smalltalk.method({
  2107. selector: unescape('allInstanceVariableNames'),
  2108. category: 'accessing',
  2109. fn: function (){
  2110. var self=this;
  2111. var result=nil;
  2112. result=smalltalk.send(smalltalk.send(self, "_instanceVariableNames", []), "_copy", []);
  2113. (($receiver = smalltalk.send(self, "_superclass", [])) != nil && $receiver != undefined) ? (function(){return smalltalk.send(result, "_addAll_", [smalltalk.send(smalltalk.send(self, "_superclass", []), "_allInstanceVariableNames", [])]);})() : nil;
  2114. return result;
  2115. return self;},
  2116. args: [],
  2117. source: unescape('allInstanceVariableNames%0A%09%7C%20result%20%7C%0A%09result%20%3A%3D%20self%20instanceVariableNames%20copy.%0A%09self%20superclass%20ifNotNil%3A%20%5B%0A%09%20%20%20%20result%20addAll%3A%20self%20superclass%20allInstanceVariableNames%5D.%0A%09%5Eresult'),
  2118. messageSends: ["copy", "instanceVariableNames", "ifNotNil:", "superclass", "addAll:", "allInstanceVariableNames"],
  2119. referencedClasses: []
  2120. }),
  2121. smalltalk.Behavior);
  2122. smalltalk.addMethod(
  2123. unescape('_methodAt_'),
  2124. smalltalk.method({
  2125. selector: unescape('methodAt%3A'),
  2126. category: 'accessing',
  2127. fn: function (aString){
  2128. var self=this;
  2129. return smalltalk.methods(self)[aString];
  2130. return self;},
  2131. args: ["aString"],
  2132. source: unescape('methodAt%3A%20aString%0A%09%3Creturn%20smalltalk.methods%28self%29%5BaString%5D%3E'),
  2133. messageSends: [],
  2134. referencedClasses: []
  2135. }),
  2136. smalltalk.Behavior);
  2137. smalltalk.addMethod(
  2138. unescape('_methodsFor_stamp_'),
  2139. smalltalk.method({
  2140. selector: unescape('methodsFor%3Astamp%3A'),
  2141. category: 'accessing',
  2142. fn: function (aString, aStamp){
  2143. var self=this;
  2144. return smalltalk.send(self, "_methodsFor_", [aString]);
  2145. return self;},
  2146. args: ["aString", "aStamp"],
  2147. source: unescape('methodsFor%3A%20aString%20stamp%3A%20aStamp%0A%09%22Added%20for%20compatibility%2C%20right%20now%20ignores%20stamp.%22%0A%09%5Eself%20methodsFor%3A%20aString'),
  2148. messageSends: ["methodsFor:"],
  2149. referencedClasses: []
  2150. }),
  2151. smalltalk.Behavior);
  2152. smalltalk.addMethod(
  2153. unescape('_commentStamp_prior_'),
  2154. smalltalk.method({
  2155. selector: unescape('commentStamp%3Aprior%3A'),
  2156. category: 'accessing',
  2157. fn: function (aStamp, prior){
  2158. var self=this;
  2159. return smalltalk.send(self, "_commentStamp", []);
  2160. return self;},
  2161. args: ["aStamp", "prior"],
  2162. source: unescape('commentStamp%3A%20aStamp%20prior%3A%20prior%0A%20%20%20%20%20%20%20%20%5Eself%20commentStamp'),
  2163. messageSends: ["commentStamp"],
  2164. referencedClasses: []
  2165. }),
  2166. smalltalk.Behavior);
  2167. smalltalk.addMethod(
  2168. unescape('_compile_'),
  2169. smalltalk.method({
  2170. selector: unescape('compile%3A'),
  2171. category: 'compiling',
  2172. fn: function (aString){
  2173. var self=this;
  2174. smalltalk.send(self, "_compile_category_", [aString, ""]);
  2175. return self;},
  2176. args: ["aString"],
  2177. source: unescape('compile%3A%20aString%0A%09self%20compile%3A%20aString%20category%3A%20%27%27'),
  2178. messageSends: ["compile:category:"],
  2179. referencedClasses: []
  2180. }),
  2181. smalltalk.Behavior);
  2182. smalltalk.addMethod(
  2183. unescape('_compile_category_'),
  2184. smalltalk.method({
  2185. selector: unescape('compile%3Acategory%3A'),
  2186. category: 'compiling',
  2187. fn: function (aString, anotherString){
  2188. var self=this;
  2189. var method=nil;
  2190. method=smalltalk.send(smalltalk.send((smalltalk.Compiler || Compiler), "_new", []), "_load_forClass_", [aString, self]);
  2191. smalltalk.send(method, "_category_", [anotherString]);
  2192. smalltalk.send(self, "_addCompiledMethod_", [method]);
  2193. return self;},
  2194. args: ["aString", "anotherString"],
  2195. source: unescape('compile%3A%20aString%20category%3A%20anotherString%0A%09%7C%20method%20%7C%0A%09method%20%3A%3D%20Compiler%20new%20load%3A%20aString%20forClass%3A%20self.%0A%09method%20category%3A%20anotherString.%0A%09self%20addCompiledMethod%3A%20method'),
  2196. messageSends: ["load:forClass:", "new", "category:", "addCompiledMethod:"],
  2197. referencedClasses: ["Compiler"]
  2198. }),
  2199. smalltalk.Behavior);
  2200. smalltalk.addClass('Class', smalltalk.Behavior, [], 'Kernel');
  2201. smalltalk.addMethod(
  2202. unescape('_category'),
  2203. smalltalk.method({
  2204. selector: unescape('category'),
  2205. category: 'accessing',
  2206. fn: function (){
  2207. var self=this;
  2208. return (($receiver = smalltalk.send(self, "_package", [])) == nil || $receiver == undefined) ? (function(){return "Unclassified";})() : (function(){return smalltalk.send(smalltalk.send(self, "_package", []), "_name", []);})();
  2209. return self;},
  2210. args: [],
  2211. source: unescape('category%0A%09%5Eself%20package%20ifNil%3A%20%5B%27Unclassified%27%5D%20ifNotNil%3A%20%5Bself%20package%20name%5D'),
  2212. messageSends: ["ifNil:ifNotNil:", "package", "name"],
  2213. referencedClasses: []
  2214. }),
  2215. smalltalk.Class);
  2216. smalltalk.addMethod(
  2217. unescape('_subclass_instanceVariableNames_'),
  2218. smalltalk.method({
  2219. selector: unescape('subclass%3AinstanceVariableNames%3A'),
  2220. category: 'class creation',
  2221. fn: function (aString, anotherString){
  2222. var self=this;
  2223. return smalltalk.send(self, "_subclass_instanceVariableNames_package_", [aString, anotherString, nil]);
  2224. return self;},
  2225. args: ["aString", "anotherString"],
  2226. source: unescape('subclass%3A%20aString%20instanceVariableNames%3A%20anotherString%0A%09%22Kept%20for%20compatibility.%22%0A%09%5Eself%20subclass%3A%20aString%20instanceVariableNames%3A%20anotherString%20package%3A%20nil'),
  2227. messageSends: ["subclass:instanceVariableNames:package:"],
  2228. referencedClasses: []
  2229. }),
  2230. smalltalk.Class);
  2231. smalltalk.addMethod(
  2232. unescape('_subclass_instanceVariableNames_category_'),
  2233. smalltalk.method({
  2234. selector: unescape('subclass%3AinstanceVariableNames%3Acategory%3A'),
  2235. category: 'class creation',
  2236. fn: function (aString, aString2, aString3){
  2237. var self=this;
  2238. return smalltalk.send(self, "_subclass_instanceVariableNames_package_", [aString, aString2, aString3]);
  2239. return self;},
  2240. args: ["aString", "aString2", "aString3"],
  2241. source: unescape('subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20category%3A%20aString3%0A%09%22Kept%20for%20compatibility.%22%0A%09%5Eself%20subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3'),
  2242. messageSends: ["subclass:instanceVariableNames:package:"],
  2243. referencedClasses: []
  2244. }),
  2245. smalltalk.Class);
  2246. smalltalk.addMethod(
  2247. unescape('_isClass'),
  2248. smalltalk.method({
  2249. selector: unescape('isClass'),
  2250. category: 'testing',
  2251. fn: function (){
  2252. var self=this;
  2253. return true;
  2254. return self;},
  2255. args: [],
  2256. source: unescape('isClass%0A%09%5Etrue'),
  2257. messageSends: [],
  2258. referencedClasses: []
  2259. }),
  2260. smalltalk.Class);
  2261. smalltalk.addMethod(
  2262. unescape('_printString'),
  2263. smalltalk.method({
  2264. selector: unescape('printString'),
  2265. category: 'printing',
  2266. fn: function (){
  2267. var self=this;
  2268. return smalltalk.send(self, "_name", []);
  2269. return self;},
  2270. args: [],
  2271. source: unescape('printString%0A%09%5Eself%20name'),
  2272. messageSends: ["name"],
  2273. referencedClasses: []
  2274. }),
  2275. smalltalk.Class);
  2276. smalltalk.addMethod(
  2277. unescape('_rename_'),
  2278. smalltalk.method({
  2279. selector: unescape('rename%3A'),
  2280. category: 'accessing',
  2281. fn: function (aString){
  2282. var self=this;
  2283. smalltalk[aString] = self;
  2284. delete smalltalk[self.className];
  2285. self.className = aString;
  2286. ;
  2287. return self;},
  2288. args: ["aString"],
  2289. source: unescape('rename%3A%20aString%0A%09%3C%0A%09%09smalltalk%5BaString%5D%20%3D%20self%3B%0A%09%09delete%20smalltalk%5Bself.className%5D%3B%0A%09%09self.className%20%3D%20aString%3B%0A%09%3E'),
  2290. messageSends: [],
  2291. referencedClasses: []
  2292. }),
  2293. smalltalk.Class);
  2294. smalltalk.addMethod(
  2295. unescape('_subclass_instanceVariableNames_classVariableNames_poolDictionaries_category_'),
  2296. smalltalk.method({
  2297. selector: unescape('subclass%3AinstanceVariableNames%3AclassVariableNames%3ApoolDictionaries%3Acategory%3A'),
  2298. category: 'class creation',
  2299. fn: function (aString, aString2, classVars, pools, aString3){
  2300. var self=this;
  2301. return smalltalk.send(self, "_subclass_instanceVariableNames_package_", [aString, aString2, aString3]);
  2302. return self;},
  2303. args: ["aString", "aString2", "classVars", "pools", "aString3"],
  2304. source: unescape('subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20classVariableNames%3A%20classVars%20poolDictionaries%3A%20pools%20category%3A%20aString3%0A%09%22Just%20ignore%20class%20variables%20and%20pools.%20Added%20for%20compatibility.%22%0A%09%5Eself%20subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3'),
  2305. messageSends: ["subclass:instanceVariableNames:package:"],
  2306. referencedClasses: []
  2307. }),
  2308. smalltalk.Class);
  2309. smalltalk.addMethod(
  2310. unescape('_package'),
  2311. smalltalk.method({
  2312. selector: unescape('package'),
  2313. category: 'accessing',
  2314. fn: function (){
  2315. var self=this;
  2316. return self.pkg;
  2317. return self;},
  2318. args: [],
  2319. source: unescape('package%0A%09%3Creturn%20self.pkg%3E'),
  2320. messageSends: [],
  2321. referencedClasses: []
  2322. }),
  2323. smalltalk.Class);
  2324. smalltalk.addMethod(
  2325. unescape('_package_'),
  2326. smalltalk.method({
  2327. selector: unescape('package%3A'),
  2328. category: 'accessing',
  2329. fn: function (aPackage){
  2330. var self=this;
  2331. self.pkg = aPackage;
  2332. return self;},
  2333. args: ["aPackage"],
  2334. source: unescape('package%3A%20aPackage%0A%09%3Cself.pkg%20%3D%20aPackage%3E'),
  2335. messageSends: [],
  2336. referencedClasses: []
  2337. }),
  2338. smalltalk.Class);
  2339. smalltalk.addMethod(
  2340. unescape('_subclass_instanceVariableNames_package_'),
  2341. smalltalk.method({
  2342. selector: unescape('subclass%3AinstanceVariableNames%3Apackage%3A'),
  2343. category: 'class creation',
  2344. fn: function (aString, aString2, aString3){
  2345. var self=this;
  2346. return smalltalk.send(smalltalk.send((smalltalk.ClassBuilder || ClassBuilder), "_new", []), "_superclass_subclass_instanceVariableNames_package_", [self, aString, aString2, aString3]);
  2347. return self;},
  2348. args: ["aString", "aString2", "aString3"],
  2349. source: unescape('subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3%0A%09%5EClassBuilder%20new%0A%09%20%20%20%20superclass%3A%20self%20subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3'),
  2350. messageSends: ["superclass:subclass:instanceVariableNames:package:", "new"],
  2351. referencedClasses: ["ClassBuilder"]
  2352. }),
  2353. smalltalk.Class);
  2354. smalltalk.addClass('Metaclass', smalltalk.Behavior, [], 'Kernel');
  2355. smalltalk.addMethod(
  2356. unescape('_instanceClass'),
  2357. smalltalk.method({
  2358. selector: unescape('instanceClass'),
  2359. category: 'accessing',
  2360. fn: function (){
  2361. var self=this;
  2362. return self.instanceClass;
  2363. return self;},
  2364. args: [],
  2365. source: unescape('instanceClass%0A%09%3Creturn%20self.instanceClass%3E'),
  2366. messageSends: [],
  2367. referencedClasses: []
  2368. }),
  2369. smalltalk.Metaclass);
  2370. smalltalk.addMethod(
  2371. unescape('_instanceVariableNames_'),
  2372. smalltalk.method({
  2373. selector: unescape('instanceVariableNames%3A'),
  2374. category: 'accessing',
  2375. fn: function (aCollection){
  2376. var self=this;
  2377. smalltalk.send(smalltalk.send((smalltalk.ClassBuilder || ClassBuilder), "_new", []), "_class_instanceVariableNames_", [self, aCollection]);
  2378. return self;},
  2379. args: ["aCollection"],
  2380. source: unescape('instanceVariableNames%3A%20aCollection%0A%09ClassBuilder%20new%0A%09%20%20%20%20class%3A%20self%20instanceVariableNames%3A%20aCollection'),
  2381. messageSends: ["class:instanceVariableNames:", "new"],
  2382. referencedClasses: ["ClassBuilder"]
  2383. }),
  2384. smalltalk.Metaclass);
  2385. smalltalk.addMethod(
  2386. unescape('_isMetaclass'),
  2387. smalltalk.method({
  2388. selector: unescape('isMetaclass'),
  2389. category: 'testing',
  2390. fn: function (){
  2391. var self=this;
  2392. return true;
  2393. return self;},
  2394. args: [],
  2395. source: unescape('isMetaclass%0A%09%5Etrue'),
  2396. messageSends: [],
  2397. referencedClasses: []
  2398. }),
  2399. smalltalk.Metaclass);
  2400. smalltalk.addMethod(
  2401. unescape('_printString'),
  2402. smalltalk.method({
  2403. selector: unescape('printString'),
  2404. category: 'printing',
  2405. fn: function (){
  2406. var self=this;
  2407. return smalltalk.send(smalltalk.send(smalltalk.send(self, "_instanceClass", []), "_name", []), "__comma", [" class"]);
  2408. return self;},
  2409. args: [],
  2410. source: unescape('printString%0A%09%5Eself%20instanceClass%20name%2C%20%27%20class%27'),
  2411. messageSends: [unescape("%2C"), "name", "instanceClass"],
  2412. referencedClasses: []
  2413. }),
  2414. smalltalk.Metaclass);
  2415. smalltalk.addClass('CompiledMethod', smalltalk.Object, [], 'Kernel');
  2416. smalltalk.addMethod(
  2417. unescape('_source'),
  2418. smalltalk.method({
  2419. selector: unescape('source'),
  2420. category: 'accessing',
  2421. fn: function (){
  2422. var self=this;
  2423. return (($receiver = smalltalk.send(self, "_basicAt_", ["source"])) == nil || $receiver == undefined) ? (function(){return "";})() : $receiver;
  2424. return self;},
  2425. args: [],
  2426. source: unescape('source%0A%09%5E%28self%20basicAt%3A%20%27source%27%29%20ifNil%3A%20%5B%27%27%5D'),
  2427. messageSends: ["ifNil:", "basicAt:"],
  2428. referencedClasses: []
  2429. }),
  2430. smalltalk.CompiledMethod);
  2431. smalltalk.addMethod(
  2432. unescape('_source_'),
  2433. smalltalk.method({
  2434. selector: unescape('source%3A'),
  2435. category: 'accessing',
  2436. fn: function (aString){
  2437. var self=this;
  2438. smalltalk.send(self, "_basicAt_put_", ["source", aString]);
  2439. return self;},
  2440. args: ["aString"],
  2441. source: unescape('source%3A%20aString%0A%09self%20basicAt%3A%20%27source%27%20put%3A%20aString'),
  2442. messageSends: ["basicAt:put:"],
  2443. referencedClasses: []
  2444. }),
  2445. smalltalk.CompiledMethod);
  2446. smalltalk.addMethod(
  2447. unescape('_category'),
  2448. smalltalk.method({
  2449. selector: unescape('category'),
  2450. category: 'accessing',
  2451. fn: function (){
  2452. var self=this;
  2453. return (($receiver = smalltalk.send(self, "_basicAt_", ["category"])) == nil || $receiver == undefined) ? (function(){return "";})() : $receiver;
  2454. return self;},
  2455. args: [],
  2456. source: unescape('category%0A%09%5E%28self%20basicAt%3A%20%27category%27%29%20ifNil%3A%20%5B%27%27%5D'),
  2457. messageSends: ["ifNil:", "basicAt:"],
  2458. referencedClasses: []
  2459. }),
  2460. smalltalk.CompiledMethod);
  2461. smalltalk.addMethod(
  2462. unescape('_category_'),
  2463. smalltalk.method({
  2464. selector: unescape('category%3A'),
  2465. category: 'accessing',
  2466. fn: function (aString){
  2467. var self=this;
  2468. smalltalk.send(self, "_basicAt_put_", ["category", aString]);
  2469. return self;},
  2470. args: ["aString"],
  2471. source: unescape('category%3A%20aString%0A%09self%20basicAt%3A%20%27category%27%20put%3A%20aString'),
  2472. messageSends: ["basicAt:put:"],
  2473. referencedClasses: []
  2474. }),
  2475. smalltalk.CompiledMethod);
  2476. smalltalk.addMethod(
  2477. unescape('_selector'),
  2478. smalltalk.method({
  2479. selector: unescape('selector'),
  2480. category: 'accessing',
  2481. fn: function (){
  2482. var self=this;
  2483. return smalltalk.send(self, "_basicAt_", ["selector"]);
  2484. return self;},
  2485. args: [],
  2486. source: unescape('selector%0A%09%5Eself%20basicAt%3A%20%27selector%27'),
  2487. messageSends: ["basicAt:"],
  2488. referencedClasses: []
  2489. }),
  2490. smalltalk.CompiledMethod);
  2491. smalltalk.addMethod(
  2492. unescape('_selector_'),
  2493. smalltalk.method({
  2494. selector: unescape('selector%3A'),
  2495. category: 'accessing',
  2496. fn: function (aString){
  2497. var self=this;
  2498. smalltalk.send(self, "_basicAt_put_", ["selector", aString]);
  2499. return self;},
  2500. args: ["aString"],
  2501. source: unescape('selector%3A%20aString%0A%09self%20basicAt%3A%20%27selector%27%20put%3A%20aString'),
  2502. messageSends: ["basicAt:put:"],
  2503. referencedClasses: []
  2504. }),
  2505. smalltalk.CompiledMethod);
  2506. smalltalk.addMethod(
  2507. unescape('_fn'),
  2508. smalltalk.method({
  2509. selector: unescape('fn'),
  2510. category: 'accessing',
  2511. fn: function (){
  2512. var self=this;
  2513. return smalltalk.send(self, "_basicAt_", ["fn"]);
  2514. return self;},
  2515. args: [],
  2516. source: unescape('fn%0A%09%5Eself%20basicAt%3A%20%27fn%27'),
  2517. messageSends: ["basicAt:"],
  2518. referencedClasses: []
  2519. }),
  2520. smalltalk.CompiledMethod);
  2521. smalltalk.addMethod(
  2522. unescape('_fn_'),
  2523. smalltalk.method({
  2524. selector: unescape('fn%3A'),
  2525. category: 'accessing',
  2526. fn: function (aBlock){
  2527. var self=this;
  2528. smalltalk.send(self, "_basicAt_put_", ["fn", aBlock]);
  2529. return self;},
  2530. args: ["aBlock"],
  2531. source: unescape('fn%3A%20aBlock%0A%09self%20basicAt%3A%20%27fn%27%20put%3A%20aBlock'),
  2532. messageSends: ["basicAt:put:"],
  2533. referencedClasses: []
  2534. }),
  2535. smalltalk.CompiledMethod);
  2536. smalltalk.addMethod(
  2537. unescape('_messageSends'),
  2538. smalltalk.method({
  2539. selector: unescape('messageSends'),
  2540. category: 'accessing',
  2541. fn: function (){
  2542. var self=this;
  2543. return smalltalk.send(self, "_basicAt_", ["messageSends"]);
  2544. return self;},
  2545. args: [],
  2546. source: unescape('messageSends%0A%09%5Eself%20basicAt%3A%20%27messageSends%27'),
  2547. messageSends: ["basicAt:"],
  2548. referencedClasses: []
  2549. }),
  2550. smalltalk.CompiledMethod);
  2551. smalltalk.addMethod(
  2552. unescape('_methodClass'),
  2553. smalltalk.method({
  2554. selector: unescape('methodClass'),
  2555. category: 'accessing',
  2556. fn: function (){
  2557. var self=this;
  2558. return smalltalk.send(self, "_basicAt_", ["methodClass"]);
  2559. return self;},
  2560. args: [],
  2561. source: unescape('methodClass%0A%09%5Eself%20basicAt%3A%20%27methodClass%27'),
  2562. messageSends: ["basicAt:"],
  2563. referencedClasses: []
  2564. }),
  2565. smalltalk.CompiledMethod);
  2566. smalltalk.addMethod(
  2567. unescape('_referencedClasses'),
  2568. smalltalk.method({
  2569. selector: unescape('referencedClasses'),
  2570. category: 'accessing',
  2571. fn: function (){
  2572. var self=this;
  2573. return smalltalk.send(self, "_basicAt_", ["referencedClasses"]);
  2574. return self;},
  2575. args: [],
  2576. source: unescape('referencedClasses%0A%09%5Eself%20basicAt%3A%20%27referencedClasses%27'),
  2577. messageSends: ["basicAt:"],
  2578. referencedClasses: []
  2579. }),
  2580. smalltalk.CompiledMethod);
  2581. smalltalk.addMethod(
  2582. unescape('_arguments'),
  2583. smalltalk.method({
  2584. selector: unescape('arguments'),
  2585. category: 'accessing',
  2586. fn: function (){
  2587. var self=this;
  2588. return self.args || [];
  2589. return self;},
  2590. args: [],
  2591. source: unescape('arguments%0A%09%3Creturn%20self.args%20%7C%7C%20%5B%5D%3E'),
  2592. messageSends: [],
  2593. referencedClasses: []
  2594. }),
  2595. smalltalk.CompiledMethod);
  2596. smalltalk.addClass('Number', smalltalk.Object, [], 'Kernel');
  2597. smalltalk.addMethod(
  2598. unescape('__eq'),
  2599. smalltalk.method({
  2600. selector: unescape('%3D'),
  2601. category: 'comparing',
  2602. fn: function (aNumber){
  2603. var self=this;
  2604. try{((($receiver = smalltalk.send(smalltalk.send(aNumber, "_class", []), "__eq", [smalltalk.send(self, "_class", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));
  2605. return Number(self) == aNumber;
  2606. return self;
  2607. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq'){return e.fn()} throw(e)}},
  2608. args: ["aNumber"],
  2609. source: unescape('%3D%20aNumber%0A%09aNumber%20class%20%3D%20self%20class%20ifFalse%3A%20%5B%5Efalse%5D.%20%0A%09%3Creturn%20Number%28self%29%20%3D%3D%20aNumber%3E'),
  2610. messageSends: ["ifFalse:", unescape("%3D"), "class"],
  2611. referencedClasses: []
  2612. }),
  2613. smalltalk.Number);
  2614. smalltalk.addMethod(
  2615. unescape('__gt'),
  2616. smalltalk.method({
  2617. selector: unescape('%3E'),
  2618. category: 'comparing',
  2619. fn: function (aNumber){
  2620. var self=this;
  2621. return self > aNumber;
  2622. return self;},
  2623. args: ["aNumber"],
  2624. source: unescape('%3E%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20%3E%3E%20aNumber%3E'),
  2625. messageSends: [],
  2626. referencedClasses: []
  2627. }),
  2628. smalltalk.Number);
  2629. smalltalk.addMethod(
  2630. unescape('__lt'),
  2631. smalltalk.method({
  2632. selector: unescape('%3C'),
  2633. category: 'comparing',
  2634. fn: function (aNumber){
  2635. var self=this;
  2636. return self < aNumber;
  2637. return self;},
  2638. args: ["aNumber"],
  2639. source: unescape('%3C%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20%3C%20aNumber%3E'),
  2640. messageSends: [],
  2641. referencedClasses: []
  2642. }),
  2643. smalltalk.Number);
  2644. smalltalk.addMethod(
  2645. unescape('__gt_eq'),
  2646. smalltalk.method({
  2647. selector: unescape('%3E%3D'),
  2648. category: 'comparing',
  2649. fn: function (aNumber){
  2650. var self=this;
  2651. return self >= aNumber;
  2652. return self;},
  2653. args: ["aNumber"],
  2654. source: unescape('%3E%3D%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20%3E%3E%3D%20aNumber%3E'),
  2655. messageSends: [],
  2656. referencedClasses: []
  2657. }),
  2658. smalltalk.Number);
  2659. smalltalk.addMethod(
  2660. unescape('__lt_eq'),
  2661. smalltalk.method({
  2662. selector: unescape('%3C%3D'),
  2663. category: 'comparing',
  2664. fn: function (aNumber){
  2665. var self=this;
  2666. return self <= aNumber;
  2667. return self;},
  2668. args: ["aNumber"],
  2669. source: unescape('%3C%3D%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20%3C%3D%20aNumber%3E'),
  2670. messageSends: [],
  2671. referencedClasses: []
  2672. }),
  2673. smalltalk.Number);
  2674. smalltalk.addMethod(
  2675. unescape('__plus'),
  2676. smalltalk.method({
  2677. selector: unescape('+'),
  2678. category: 'arithmetic',
  2679. fn: function (aNumber){
  2680. var self=this;
  2681. return self + aNumber;
  2682. return self;},
  2683. args: ["aNumber"],
  2684. source: unescape('+%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20+%20aNumber%3E'),
  2685. messageSends: [],
  2686. referencedClasses: []
  2687. }),
  2688. smalltalk.Number);
  2689. smalltalk.addMethod(
  2690. unescape('__minus'),
  2691. smalltalk.method({
  2692. selector: unescape('-'),
  2693. category: 'arithmetic',
  2694. fn: function (aNumber){
  2695. var self=this;
  2696. return self - aNumber;
  2697. return self;},
  2698. args: ["aNumber"],
  2699. source: unescape('-%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20-%20aNumber%3E'),
  2700. messageSends: [],
  2701. referencedClasses: []
  2702. }),
  2703. smalltalk.Number);
  2704. smalltalk.addMethod(
  2705. unescape('__star'),
  2706. smalltalk.method({
  2707. selector: unescape('*'),
  2708. category: 'arithmetic',
  2709. fn: function (aNumber){
  2710. var self=this;
  2711. return self * aNumber;
  2712. return self;},
  2713. args: ["aNumber"],
  2714. source: unescape('*%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20*%20aNumber%3E'),
  2715. messageSends: [],
  2716. referencedClasses: []
  2717. }),
  2718. smalltalk.Number);
  2719. smalltalk.addMethod(
  2720. unescape('__slash'),
  2721. smalltalk.method({
  2722. selector: unescape('/'),
  2723. category: 'arithmetic',
  2724. fn: function (aNumber){
  2725. var self=this;
  2726. return self / aNumber;
  2727. return self;},
  2728. args: ["aNumber"],
  2729. source: unescape('/%20aNumber%0A%09%22Inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%20/%20aNumber%3E'),
  2730. messageSends: [],
  2731. referencedClasses: []
  2732. }),
  2733. smalltalk.Number);
  2734. smalltalk.addMethod(
  2735. unescape('_max_'),
  2736. smalltalk.method({
  2737. selector: unescape('max%3A'),
  2738. category: 'arithmetic',
  2739. fn: function (aNumber){
  2740. var self=this;
  2741. return Math.max(self, aNumber);;
  2742. return self;},
  2743. args: ["aNumber"],
  2744. source: unescape('max%3A%20aNumber%0A%09%3Creturn%20Math.max%28self%2C%20aNumber%29%3B%3E'),
  2745. messageSends: [],
  2746. referencedClasses: []
  2747. }),
  2748. smalltalk.Number);
  2749. smalltalk.addMethod(
  2750. unescape('_min_'),
  2751. smalltalk.method({
  2752. selector: unescape('min%3A'),
  2753. category: 'arithmetic',
  2754. fn: function (aNumber){
  2755. var self=this;
  2756. return Math.min(self, aNumber);;
  2757. return self;},
  2758. args: ["aNumber"],
  2759. source: unescape('min%3A%20aNumber%0A%09%3Creturn%20Math.min%28self%2C%20aNumber%29%3B%3E'),
  2760. messageSends: [],
  2761. referencedClasses: []
  2762. }),
  2763. smalltalk.Number);
  2764. smalltalk.addMethod(
  2765. unescape('_rounded'),
  2766. smalltalk.method({
  2767. selector: unescape('rounded'),
  2768. category: 'converting',
  2769. fn: function (){
  2770. var self=this;
  2771. return Math.round(self);;
  2772. return self;},
  2773. args: [],
  2774. source: unescape('rounded%0A%09%3Creturn%20Math.round%28self%29%3B%3E'),
  2775. messageSends: [],
  2776. referencedClasses: []
  2777. }),
  2778. smalltalk.Number);
  2779. smalltalk.addMethod(
  2780. unescape('_truncated'),
  2781. smalltalk.method({
  2782. selector: unescape('truncated'),
  2783. category: 'converting',
  2784. fn: function (){
  2785. var self=this;
  2786. var result=nil;
  2787. ((($receiver = self >= (0)).klass === smalltalk.Boolean) ? ($receiver ? (function(){return result = Math.floor(self);;})() : (function(){return result = (Math.floor(self * (-1)) * (-1));;})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return result = Math.floor(self);;}), (function(){return result = (Math.floor(self * (-1)) * (-1));;})]));
  2788. return result;
  2789. return self;},
  2790. args: [],
  2791. source: unescape('truncated%0A%7Cresult%7C%0A%0A%20%20%20%20self%20%3E%3D%200%20%0A%20%20%20%20%20%20%20%20ifTrue%3A%20%5B%3Cresult%20%3D%20Math.floor%28self%29%3B%3E%5D%0A%20%20%20%20%20%20%20%20ifFalse%3A%20%5B%3Cresult%20%3D%20%28Math.floor%28self%20*%20%28-1%29%29%20*%20%28-1%29%29%3B%3E%5D.%0A%0A%20%20%20%20%5E%20result'),
  2792. messageSends: ["ifTrue:ifFalse:", unescape("%3E%3D")],
  2793. referencedClasses: []
  2794. }),
  2795. smalltalk.Number);
  2796. smalltalk.addMethod(
  2797. unescape('_to_'),
  2798. smalltalk.method({
  2799. selector: unescape('to%3A'),
  2800. category: 'converting',
  2801. fn: function (aNumber){
  2802. var self=this;
  2803. var array=nil;
  2804. var first=nil;
  2805. var last=nil;
  2806. var count=nil;
  2807. first=smalltalk.send(self, "_truncated", []);
  2808. last=((($receiver = smalltalk.send(aNumber, "_truncated", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));
  2809. count=(1);
  2810. array=smalltalk.send((smalltalk.Array || Array), "_new", []);
  2811. smalltalk.send(((($receiver = last).klass === smalltalk.Number) ? $receiver -first : smalltalk.send($receiver, "__minus", [first])), "_timesRepeat_", [(function(){smalltalk.send(array, "_at_put_", [count, first]);count=((($receiver = count).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));return first=((($receiver = first).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));})]);
  2812. return array;
  2813. return self;},
  2814. args: ["aNumber"],
  2815. source: unescape('to%3A%20aNumber%0A%09%7C%20array%20first%20last%20count%20%7C%0A%09first%20%3A%3D%20self%20truncated.%0A%09last%20%3A%3D%20aNumber%20truncated%20+%201.%0A%09count%20%3A%3D%201.%0A%09array%20%3A%3D%20Array%20new.%0A%09%28last%20-%20first%29%20timesRepeat%3A%20%5B%0A%09%20%20%20%20array%20at%3A%20count%20put%3A%20first.%0A%09%20%20%20%20count%20%3A%3D%20count%20+%201.%0A%09%20%20%20%20first%20%3A%3D%20first%20+%201%5D.%0A%09%5Earray'),
  2816. messageSends: ["truncated", unescape("+"), "new", "timesRepeat:", unescape("-"), "at:put:"],
  2817. referencedClasses: ["Array"]
  2818. }),
  2819. smalltalk.Number);
  2820. smalltalk.addMethod(
  2821. unescape('_timesRepeat_'),
  2822. smalltalk.method({
  2823. selector: unescape('timesRepeat%3A'),
  2824. category: 'enumerating',
  2825. fn: function (aBlock){
  2826. var self=this;
  2827. var integer=nil;
  2828. var count=nil;
  2829. integer=smalltalk.send(self, "_truncated", []);
  2830. count=(1);
  2831. (function(){while(!(function(){return ((($receiver = count).klass === smalltalk.Number) ? $receiver >self : smalltalk.send($receiver, "__gt", [self]));})()) {(function(){smalltalk.send(aBlock, "_value", []);return count=((($receiver = count).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));})()}})();
  2832. return self;},
  2833. args: ["aBlock"],
  2834. source: unescape('timesRepeat%3A%20aBlock%0A%09%7C%20integer%20count%20%7C%0A%09integer%20%3A%3D%20self%20truncated.%0A%09count%20%3A%3D%201.%0A%09%5Bcount%20%3E%20self%5D%20whileFalse%3A%20%5B%0A%09%20%20%20%20aBlock%20value.%0A%09%20%20%20%20count%20%3A%3D%20count%20+%201%5D'),
  2835. messageSends: ["truncated", "whileFalse:", unescape("%3E"), "value", unescape("+")],
  2836. referencedClasses: []
  2837. }),
  2838. smalltalk.Number);
  2839. smalltalk.addMethod(
  2840. unescape('_to_do_'),
  2841. smalltalk.method({
  2842. selector: unescape('to%3Ado%3A'),
  2843. category: 'enumerating',
  2844. fn: function (stop, aBlock){
  2845. var self=this;
  2846. var nextValue=nil;
  2847. nextValue=self;
  2848. (function(){while((function(){return ((($receiver = nextValue).klass === smalltalk.Number) ? $receiver <=stop : smalltalk.send($receiver, "__lt_eq", [stop]));})()) {(function(){smalltalk.send(aBlock, "_value_", [nextValue]);return nextValue=((($receiver = nextValue).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));})()}})();
  2849. return self;},
  2850. args: ["stop", "aBlock"],
  2851. source: unescape('to%3A%20stop%20do%3A%20aBlock%0A%09%22Evaluate%20aBlock%20for%20each%20number%20from%20self%20to%20aNumber.%22%0A%09%7C%20nextValue%20%7C%0A%09nextValue%20%3A%3D%20self.%0A%09%5BnextValue%20%3C%3D%20stop%5D%0A%09%09whileTrue%3A%20%0A%09%09%09%5BaBlock%20value%3A%20nextValue.%0A%09%09%09nextValue%20%3A%3D%20nextValue%20+%201%5D'),
  2852. messageSends: ["whileTrue:", unescape("%3C%3D"), "value:", unescape("+")],
  2853. referencedClasses: []
  2854. }),
  2855. smalltalk.Number);
  2856. smalltalk.addMethod(
  2857. unescape('_asString'),
  2858. smalltalk.method({
  2859. selector: unescape('asString'),
  2860. category: 'converting',
  2861. fn: function (){
  2862. var self=this;
  2863. return smalltalk.send(self, "_printString", []);
  2864. return self;},
  2865. args: [],
  2866. source: unescape('asString%0A%09%5Eself%20printString'),
  2867. messageSends: ["printString"],
  2868. referencedClasses: []
  2869. }),
  2870. smalltalk.Number);
  2871. smalltalk.addMethod(
  2872. unescape('_asJavascript'),
  2873. smalltalk.method({
  2874. selector: unescape('asJavascript'),
  2875. category: 'converting',
  2876. fn: function (){
  2877. var self=this;
  2878. return smalltalk.send(smalltalk.send(unescape("%28"), "__comma", [smalltalk.send(self, "_printString", [])]), "__comma", [unescape("%29")]);
  2879. return self;},
  2880. args: [],
  2881. source: unescape('asJavascript%0A%09%5E%27%28%27%2C%20self%20printString%2C%20%27%29%27'),
  2882. messageSends: [unescape("%2C"), "printString"],
  2883. referencedClasses: []
  2884. }),
  2885. smalltalk.Number);
  2886. smalltalk.addMethod(
  2887. unescape('_printString'),
  2888. smalltalk.method({
  2889. selector: unescape('printString'),
  2890. category: 'printing',
  2891. fn: function (){
  2892. var self=this;
  2893. return String(self);
  2894. return self;},
  2895. args: [],
  2896. source: unescape('printString%0A%09%3Creturn%20String%28self%29%3E'),
  2897. messageSends: [],
  2898. referencedClasses: []
  2899. }),
  2900. smalltalk.Number);
  2901. smalltalk.addMethod(
  2902. unescape('_isNumber'),
  2903. smalltalk.method({
  2904. selector: unescape('isNumber'),
  2905. category: 'testing',
  2906. fn: function (){
  2907. var self=this;
  2908. return true;
  2909. return self;},
  2910. args: [],
  2911. source: unescape('isNumber%0A%09%5Etrue'),
  2912. messageSends: [],
  2913. referencedClasses: []
  2914. }),
  2915. smalltalk.Number);
  2916. smalltalk.addMethod(
  2917. unescape('_atRandom'),
  2918. smalltalk.method({
  2919. selector: unescape('atRandom'),
  2920. category: 'converting',
  2921. fn: function (){
  2922. var self=this;
  2923. return ((($receiver = smalltalk.send(((($receiver = smalltalk.send(smalltalk.send((smalltalk.Random || Random), "_new", []), "_next", [])).klass === smalltalk.Number) ? $receiver *self : smalltalk.send($receiver, "__star", [self])), "_truncated", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));
  2924. return self;},
  2925. args: [],
  2926. source: unescape('atRandom%0A%20%20%20%20%5E%28Random%20new%20next%20*%20self%29%20truncated%20+%201'),
  2927. messageSends: [unescape("+"), "truncated", unescape("*"), "next", "new"],
  2928. referencedClasses: ["Random"]
  2929. }),
  2930. smalltalk.Number);
  2931. smalltalk.addMethod(
  2932. unescape('__at'),
  2933. smalltalk.method({
  2934. selector: unescape('@'),
  2935. category: 'converting',
  2936. fn: function (aNumber){
  2937. var self=this;
  2938. return smalltalk.send((smalltalk.Point || Point), "_x_y_", [self, aNumber]);
  2939. return self;},
  2940. args: ["aNumber"],
  2941. source: unescape('@%20aNumber%0A%09%5EPoint%20x%3A%20self%20y%3A%20aNumber'),
  2942. messageSends: ["x:y:"],
  2943. referencedClasses: ["Point"]
  2944. }),
  2945. smalltalk.Number);
  2946. smalltalk.addMethod(
  2947. unescape('_asPoint'),
  2948. smalltalk.method({
  2949. selector: unescape('asPoint'),
  2950. category: 'converting',
  2951. fn: function (){
  2952. var self=this;
  2953. return smalltalk.send((smalltalk.Point || Point), "_x_y_", [self, self]);
  2954. return self;},
  2955. args: [],
  2956. source: unescape('asPoint%0A%09%5EPoint%20x%3A%20self%20y%3A%20self'),
  2957. messageSends: ["x:y:"],
  2958. referencedClasses: ["Point"]
  2959. }),
  2960. smalltalk.Number);
  2961. smalltalk.addMethod(
  2962. unescape('_clearInterval'),
  2963. smalltalk.method({
  2964. selector: unescape('clearInterval'),
  2965. category: 'timeouts/intervals',
  2966. fn: function (){
  2967. var self=this;
  2968. clearInterval(Number(self));
  2969. return self;},
  2970. args: [],
  2971. source: unescape('clearInterval%0A%09%3CclearInterval%28Number%28self%29%29%3E'),
  2972. messageSends: [],
  2973. referencedClasses: []
  2974. }),
  2975. smalltalk.Number);
  2976. smalltalk.addMethod(
  2977. unescape('_asJSONObject'),
  2978. smalltalk.method({
  2979. selector: unescape('asJSONObject'),
  2980. category: 'converting',
  2981. fn: function (){
  2982. var self=this;
  2983. return self;
  2984. return self;},
  2985. args: [],
  2986. source: unescape('asJSONObject%0A%09%5Eself'),
  2987. messageSends: [],
  2988. referencedClasses: []
  2989. }),
  2990. smalltalk.Number);
  2991. smalltalk.addMethod(
  2992. unescape('_clearTimeout'),
  2993. smalltalk.method({
  2994. selector: unescape('clearTimeout'),
  2995. category: 'timeouts/intervals',
  2996. fn: function (){
  2997. var self=this;
  2998. clearTimeout(Number(self));
  2999. return self;},
  3000. args: [],
  3001. source: unescape('clearTimeout%0A%09%3CclearTimeout%28Number%28self%29%29%3E'),
  3002. messageSends: [],
  3003. referencedClasses: []
  3004. }),
  3005. smalltalk.Number);
  3006. smalltalk.addMethod(
  3007. unescape('_even'),
  3008. smalltalk.method({
  3009. selector: unescape('even'),
  3010. category: 'testing',
  3011. fn: function (){
  3012. var self=this;
  3013. return smalltalk.send((0), "__eq", [smalltalk.send(self, "_\\\\", [(2)])]);
  3014. return self;},
  3015. args: [],
  3016. source: unescape('even%0A%09%5E%200%20%3D%20%28self%20%5C%5C%202%29'),
  3017. messageSends: [unescape("%3D"), unescape("%5C%5C%5C%5C")],
  3018. referencedClasses: []
  3019. }),
  3020. smalltalk.Number);
  3021. smalltalk.addMethod(
  3022. unescape('_odd'),
  3023. smalltalk.method({
  3024. selector: unescape('odd'),
  3025. category: 'testing',
  3026. fn: function (){
  3027. var self=this;
  3028. return smalltalk.send(smalltalk.send(self, "_even", []), "_not", []);
  3029. return self;},
  3030. args: [],
  3031. source: unescape('odd%0A%09%5E%20self%20even%20not'),
  3032. messageSends: ["not", "even"],
  3033. referencedClasses: []
  3034. }),
  3035. smalltalk.Number);
  3036. smalltalk.addMethod(
  3037. unescape('_negated'),
  3038. smalltalk.method({
  3039. selector: unescape('negated'),
  3040. category: 'arithmetic',
  3041. fn: function (){
  3042. var self=this;
  3043. return (0) - self;
  3044. return self;},
  3045. args: [],
  3046. source: unescape('negated%0A%09%5E0%20-%20self'),
  3047. messageSends: [unescape("-")],
  3048. referencedClasses: []
  3049. }),
  3050. smalltalk.Number);
  3051. smalltalk.addMethod(
  3052. unescape('__eq_eq'),
  3053. smalltalk.method({
  3054. selector: unescape('%3D%3D'),
  3055. category: 'comparing',
  3056. fn: function (aNumber){
  3057. var self=this;
  3058. try{((($receiver = smalltalk.send(smalltalk.send(aNumber, "_class", []), "__eq", [smalltalk.send(self, "_class", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq_eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq_eq', fn: function(){return false}})})();})]));
  3059. return Number(self) === Number(aNumber);
  3060. return self;
  3061. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq_eq'){return e.fn()} throw(e)}},
  3062. args: ["aNumber"],
  3063. source: unescape('%3D%3D%20aNumber%0A%09aNumber%20class%20%3D%20self%20class%20ifFalse%3A%20%5B%5Efalse%5D.%20%0A%09%3Creturn%20Number%28self%29%20%3D%3D%3D%20Number%28aNumber%29%3E'),
  3064. messageSends: ["ifFalse:", unescape("%3D"), "class"],
  3065. referencedClasses: []
  3066. }),
  3067. smalltalk.Number);
  3068. smalltalk.addMethod(
  3069. unescape('_printShowingDecimalPlaces_'),
  3070. smalltalk.method({
  3071. selector: unescape('printShowingDecimalPlaces%3A'),
  3072. category: 'printing',
  3073. fn: function (placesDesired){
  3074. var self=this;
  3075. return self.toFixed(placesDesired);
  3076. return self;},
  3077. args: ["placesDesired"],
  3078. source: unescape('printShowingDecimalPlaces%3A%20placesDesired%0A%09%3Creturn%20self.toFixed%28placesDesired%29%3E'),
  3079. messageSends: [],
  3080. referencedClasses: []
  3081. }),
  3082. smalltalk.Number);
  3083. smalltalk.addMethod(
  3084. unescape('_%5C'),
  3085. smalltalk.method({
  3086. selector: unescape('%5C'),
  3087. category: '',
  3088. fn: function (aNumber){
  3089. var self=this;
  3090. return self % aNumber;
  3091. return self;},
  3092. args: ["aNumber"],
  3093. source: unescape(''),
  3094. messageSends: [],
  3095. referencedClasses: []
  3096. }),
  3097. smalltalk.Number);
  3098. smalltalk.addMethod(
  3099. unescape('_to_by_'),
  3100. smalltalk.method({
  3101. selector: unescape('to%3Aby%3A'),
  3102. category: 'converting',
  3103. fn: function (stop, step){
  3104. var self=this;
  3105. var array=nil;
  3106. var value=nil;
  3107. var pos=nil;
  3108. value=self;
  3109. array=smalltalk.send((smalltalk.Array || Array), "_new", []);
  3110. pos=(1);
  3111. ((($receiver = smalltalk.send(step, "__eq", [(0)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self, "_error_", [unescape("step%20must%20be%20non-zero")]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(self, "_error_", [unescape("step%20must%20be%20non-zero")]);})]));
  3112. ((($receiver = ((($receiver = step).klass === smalltalk.Number) ? $receiver <(0) : smalltalk.send($receiver, "__lt", [(0)]))).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver >=stop : smalltalk.send($receiver, "__gt_eq", [stop]));})()) {(function(){smalltalk.send(array, "_at_put_", [pos, value]);pos=((($receiver = pos).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();})() : (function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver <=stop : smalltalk.send($receiver, "__lt_eq", [stop]));})()) {(function(){smalltalk.send(array, "_at_put_", [pos, value]);pos=((($receiver = pos).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver >=stop : smalltalk.send($receiver, "__gt_eq", [stop]));})()) {(function(){smalltalk.send(array, "_at_put_", [pos, value]);pos=((($receiver = pos).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();}), (function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver <=stop : smalltalk.send($receiver, "__lt_eq", [stop]));})()) {(function(){smalltalk.send(array, "_at_put_", [pos, value]);pos=((($receiver = pos).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();})]));
  3113. return array;
  3114. return self;},
  3115. args: ["stop", "step"],
  3116. source: unescape('to%3A%20stop%20by%3A%20step%0A%09%7C%20array%20value%20pos%20%7C%0A%09value%20%3A%3D%20self.%0A%09array%20%3A%3D%20Array%20new.%0A%09pos%20%3A%3D%201.%0A%09step%20%3D%200%20ifTrue%3A%20%5Bself%20error%3A%20%27step%20must%20be%20non-zero%27%5D.%0A%09step%20%3C%200%0A%09%09ifTrue%3A%20%5B%5B%20value%20%3E%3D%20stop%20%5D%20whileTrue%3A%20%5B%0A%09%20%20%20%20%09%09%09array%20at%3A%20pos%20put%3A%20value.%0A%09%20%20%20%20%09%09%09pos%20%3A%3D%20pos%20+%201.%0A%09%20%20%20%20%09%09%09value%20%3A%3D%20value%20+%20step%5D%5D%0A%09%09ifFalse%3A%20%5B%5B%20value%20%3C%3D%20stop%20%5D%20whileTrue%3A%20%5B%0A%09%20%20%20%20%09%09%09array%20at%3A%20pos%20put%3A%20value.%0A%09%20%20%09%09%09pos%20%3A%3D%20pos%20+%201.%0A%09%20%20%20%20%09%09%09value%20%3A%3D%20value%20+%20step%5D%5D.%0A%09%5Earray'),
  3117. messageSends: ["new", "ifTrue:", unescape("%3D"), "error:", "ifTrue:ifFalse:", unescape("%3C"), "whileTrue:", unescape("%3E%3D"), "at:put:", unescape("+"), unescape("%3C%3D")],
  3118. referencedClasses: ["Array"]
  3119. }),
  3120. smalltalk.Number);
  3121. smalltalk.addMethod(
  3122. unescape('_to_by_do_'),
  3123. smalltalk.method({
  3124. selector: unescape('to%3Aby%3Ado%3A'),
  3125. category: 'enumerating',
  3126. fn: function (stop, step, aBlock){
  3127. var self=this;
  3128. var value=nil;
  3129. value=self;
  3130. ((($receiver = smalltalk.send(step, "__eq", [(0)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self, "_error_", [unescape("step%20must%20be%20non-zero")]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(self, "_error_", [unescape("step%20must%20be%20non-zero")]);})]));
  3131. ((($receiver = ((($receiver = step).klass === smalltalk.Number) ? $receiver <(0) : smalltalk.send($receiver, "__lt", [(0)]))).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver >=stop : smalltalk.send($receiver, "__gt_eq", [stop]));})()) {(function(){smalltalk.send(aBlock, "_value_", [value]);return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();})() : (function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver <=stop : smalltalk.send($receiver, "__lt_eq", [stop]));})()) {(function(){smalltalk.send(aBlock, "_value_", [value]);return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver >=stop : smalltalk.send($receiver, "__gt_eq", [stop]));})()) {(function(){smalltalk.send(aBlock, "_value_", [value]);return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();}), (function(){return (function(){while((function(){return ((($receiver = value).klass === smalltalk.Number) ? $receiver <=stop : smalltalk.send($receiver, "__lt_eq", [stop]));})()) {(function(){smalltalk.send(aBlock, "_value_", [value]);return value=((($receiver = value).klass === smalltalk.Number) ? $receiver +step : smalltalk.send($receiver, "__plus", [step]));})()}})();})]));
  3132. return self;},
  3133. args: ["stop", "step", "aBlock"],
  3134. source: unescape('to%3A%20stop%20by%3A%20step%20do%3A%20aBlock%0A%09%7C%20value%20%7C%0A%09value%20%3A%3D%20self.%0A%09step%20%3D%200%20ifTrue%3A%20%5Bself%20error%3A%20%27step%20must%20be%20non-zero%27%5D.%0A%09step%20%3C%200%0A%09%09ifTrue%3A%20%5B%5B%20value%20%3E%3D%20stop%20%5D%20whileTrue%3A%20%5B%0A%09%20%20%20%20%09%09%09aBlock%20value%3A%20value.%0A%09%20%20%20%20%09%09%09value%20%3A%3D%20value%20+%20step%5D%5D%0A%09%09ifFalse%3A%20%5B%5B%20value%20%3C%3D%20stop%20%5D%20whileTrue%3A%20%5B%0A%09%20%20%20%20%09%09%09aBlock%20value%3A%20value.%0A%09%20%20%20%20%09%09%09value%20%3A%3D%20value%20+%20step%5D%5D'),
  3135. messageSends: ["ifTrue:", unescape("%3D"), "error:", "ifTrue:ifFalse:", unescape("%3C"), "whileTrue:", unescape("%3E%3D"), "value:", unescape("+"), unescape("%3C%3D")],
  3136. referencedClasses: []
  3137. }),
  3138. smalltalk.Number);
  3139. smalltalk.addMethod(
  3140. unescape('_deepCopy'),
  3141. smalltalk.method({
  3142. selector: unescape('deepCopy'),
  3143. category: 'copying',
  3144. fn: function (){
  3145. var self=this;
  3146. return smalltalk.send(self, "_copy", []);
  3147. return self;},
  3148. args: [],
  3149. source: unescape('deepCopy%0A%09%5Eself%20copy'),
  3150. messageSends: ["copy"],
  3151. referencedClasses: []
  3152. }),
  3153. smalltalk.Number);
  3154. smalltalk.addMethod(
  3155. unescape('_copy'),
  3156. smalltalk.method({
  3157. selector: unescape('copy'),
  3158. category: 'copying',
  3159. fn: function (){
  3160. var self=this;
  3161. return self;
  3162. return self;},
  3163. args: [],
  3164. source: unescape('copy%0A%09%5Eself'),
  3165. messageSends: [],
  3166. referencedClasses: []
  3167. }),
  3168. smalltalk.Number);
  3169. smalltalk.addMethod(
  3170. unescape('_%5C%5C'),
  3171. smalltalk.method({
  3172. selector: unescape('%5C%5C'),
  3173. category: 'arithmetic',
  3174. fn: function (aNumber){
  3175. var self=this;
  3176. return self % aNumber;
  3177. return self;},
  3178. args: ["aNumber"],
  3179. source: unescape('%5C%5C%20aNumber%0A%09%3Creturn%20self%20%25%20aNumber%3E'),
  3180. messageSends: [],
  3181. referencedClasses: []
  3182. }),
  3183. smalltalk.Number);
  3184. smalltalk.addMethod(
  3185. unescape('_sqrt'),
  3186. smalltalk.method({
  3187. selector: unescape('sqrt'),
  3188. category: 'arithmetic',
  3189. fn: function (){
  3190. var self=this;
  3191. return Math.sqrt(self);
  3192. return self;},
  3193. args: [],
  3194. source: unescape('sqrt%0A%09%3Creturn%20Math.sqrt%28self%29%3E'),
  3195. messageSends: [],
  3196. referencedClasses: []
  3197. }),
  3198. smalltalk.Number);
  3199. smalltalk.addMethod(
  3200. unescape('_squared'),
  3201. smalltalk.method({
  3202. selector: unescape('squared'),
  3203. category: 'arithmetic',
  3204. fn: function (){
  3205. var self=this;
  3206. return self * self;
  3207. return self;},
  3208. args: [],
  3209. source: unescape('squared%0A%09%5Eself%20*%20self'),
  3210. messageSends: [unescape("*")],
  3211. referencedClasses: []
  3212. }),
  3213. smalltalk.Number);
  3214. smalltalk.addMethod(
  3215. unescape('_pi'),
  3216. smalltalk.method({
  3217. selector: unescape('pi'),
  3218. category: 'instance creation',
  3219. fn: function (){
  3220. var self=this;
  3221. return Math.PI;
  3222. return self;},
  3223. args: [],
  3224. source: unescape('pi%0A%09%3Creturn%20Math.PI%3E'),
  3225. messageSends: [],
  3226. referencedClasses: []
  3227. }),
  3228. smalltalk.Number.klass);
  3229. smalltalk.addClass('BlockClosure', smalltalk.Object, [], 'Kernel');
  3230. smalltalk.addMethod(
  3231. unescape('_compiledSource'),
  3232. smalltalk.method({
  3233. selector: unescape('compiledSource'),
  3234. category: 'accessing',
  3235. fn: function (){
  3236. var self=this;
  3237. return self.toString();
  3238. return self;},
  3239. args: [],
  3240. source: unescape('compiledSource%0A%09%3Creturn%20self.toString%28%29%3E'),
  3241. messageSends: [],
  3242. referencedClasses: []
  3243. }),
  3244. smalltalk.BlockClosure);
  3245. smalltalk.addMethod(
  3246. unescape('_whileTrue_'),
  3247. smalltalk.method({
  3248. selector: unescape('whileTrue%3A'),
  3249. category: 'controlling',
  3250. fn: function (aBlock){
  3251. var self=this;
  3252. while(self()) {aBlock()};
  3253. return self;},
  3254. args: ["aBlock"],
  3255. source: unescape('whileTrue%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%3Cwhile%28self%28%29%29%20%7BaBlock%28%29%7D%3E'),
  3256. messageSends: [],
  3257. referencedClasses: []
  3258. }),
  3259. smalltalk.BlockClosure);
  3260. smalltalk.addMethod(
  3261. unescape('_whileFalse_'),
  3262. smalltalk.method({
  3263. selector: unescape('whileFalse%3A'),
  3264. category: 'controlling',
  3265. fn: function (aBlock){
  3266. var self=this;
  3267. while(!self()) {aBlock()};
  3268. return self;},
  3269. args: ["aBlock"],
  3270. source: unescape('whileFalse%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%3Cwhile%28%21self%28%29%29%20%7BaBlock%28%29%7D%3E'),
  3271. messageSends: [],
  3272. referencedClasses: []
  3273. }),
  3274. smalltalk.BlockClosure);
  3275. smalltalk.addMethod(
  3276. unescape('_value'),
  3277. smalltalk.method({
  3278. selector: unescape('value'),
  3279. category: 'evaluating',
  3280. fn: function (){
  3281. var self=this;
  3282. return self();;
  3283. return self;},
  3284. args: [],
  3285. source: unescape('value%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%28%29%3B%3E'),
  3286. messageSends: [],
  3287. referencedClasses: []
  3288. }),
  3289. smalltalk.BlockClosure);
  3290. smalltalk.addMethod(
  3291. unescape('_value_'),
  3292. smalltalk.method({
  3293. selector: unescape('value%3A'),
  3294. category: 'evaluating',
  3295. fn: function (anArg){
  3296. var self=this;
  3297. return self(anArg);;
  3298. return self;},
  3299. args: ["anArg"],
  3300. source: unescape('value%3A%20anArg%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%28anArg%29%3B%3E'),
  3301. messageSends: [],
  3302. referencedClasses: []
  3303. }),
  3304. smalltalk.BlockClosure);
  3305. smalltalk.addMethod(
  3306. unescape('_value_value_'),
  3307. smalltalk.method({
  3308. selector: unescape('value%3Avalue%3A'),
  3309. category: 'evaluating',
  3310. fn: function (firstArg, secondArg){
  3311. var self=this;
  3312. return self(firstArg, secondArg);;
  3313. return self;},
  3314. args: ["firstArg", "secondArg"],
  3315. source: unescape('value%3A%20firstArg%20value%3A%20secondArg%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%28firstArg%2C%20secondArg%29%3B%3E'),
  3316. messageSends: [],
  3317. referencedClasses: []
  3318. }),
  3319. smalltalk.BlockClosure);
  3320. smalltalk.addMethod(
  3321. unescape('_value_value_value_'),
  3322. smalltalk.method({
  3323. selector: unescape('value%3Avalue%3Avalue%3A'),
  3324. category: 'evaluating',
  3325. fn: function (firstArg, secondArg, thirdArg){
  3326. var self=this;
  3327. return self(firstArg, secondArg, thirdArg);;
  3328. return self;},
  3329. args: ["firstArg", "secondArg", "thirdArg"],
  3330. source: unescape('value%3A%20firstArg%20value%3A%20secondArg%20value%3A%20thirdArg%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%3Creturn%20self%28firstArg%2C%20secondArg%2C%20thirdArg%29%3B%3E'),
  3331. messageSends: [],
  3332. referencedClasses: []
  3333. }),
  3334. smalltalk.BlockClosure);
  3335. smalltalk.addMethod(
  3336. unescape('_valueWithPossibleArguments_'),
  3337. smalltalk.method({
  3338. selector: unescape('valueWithPossibleArguments%3A'),
  3339. category: 'evaluating',
  3340. fn: function (aCollection){
  3341. var self=this;
  3342. return self.apply(null, aCollection);;
  3343. return self;},
  3344. args: ["aCollection"],
  3345. source: unescape('valueWithPossibleArguments%3A%20aCollection%0A%09%3Creturn%20self.apply%28null%2C%20aCollection%29%3B%3E'),
  3346. messageSends: [],
  3347. referencedClasses: []
  3348. }),
  3349. smalltalk.BlockClosure);
  3350. smalltalk.addMethod(
  3351. unescape('_on_do_'),
  3352. smalltalk.method({
  3353. selector: unescape('on%3Ado%3A'),
  3354. category: 'error handling',
  3355. fn: function (anErrorClass, aBlock){
  3356. var self=this;
  3357. smalltalk.send(self, "_try_catch_", [self, (function(error){return ((($receiver = smalltalk.send(error, "_isKindOf_", [anErrorClass])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(aBlock, "_value_", [error]);})() : (function(){return smalltalk.send(error, "_signal", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(aBlock, "_value_", [error]);}), (function(){return smalltalk.send(error, "_signal", []);})]));})]);
  3358. return self;},
  3359. args: ["anErrorClass", "aBlock"],
  3360. source: unescape('on%3A%20anErrorClass%20do%3A%20aBlock%0A%09self%20try%3A%20self%20catch%3A%20%5B%3Aerror%20%7C%0A%09%20%20%20%20%28error%20isKindOf%3A%20anErrorClass%29%20%0A%09%20%20%20%20%20ifTrue%3A%20%5BaBlock%20value%3A%20error%5D%0A%09%20%20%20%20%20ifFalse%3A%20%5Berror%20signal%5D%5D'),
  3361. messageSends: ["try:catch:", "ifTrue:ifFalse:", "isKindOf:", "value:", "signal"],
  3362. referencedClasses: []
  3363. }),
  3364. smalltalk.BlockClosure);
  3365. smalltalk.addMethod(
  3366. unescape('_valueWithTimeout_'),
  3367. smalltalk.method({
  3368. selector: unescape('valueWithTimeout%3A'),
  3369. category: 'timeout/interval',
  3370. fn: function (aNumber){
  3371. var self=this;
  3372. return setTimeout(self, aNumber);
  3373. return self;},
  3374. args: ["aNumber"],
  3375. source: unescape('valueWithTimeout%3A%20aNumber%0A%09%3Creturn%20setTimeout%28self%2C%20aNumber%29%3E'),
  3376. messageSends: [],
  3377. referencedClasses: []
  3378. }),
  3379. smalltalk.BlockClosure);
  3380. smalltalk.addMethod(
  3381. unescape('_valueWithInterval_'),
  3382. smalltalk.method({
  3383. selector: unescape('valueWithInterval%3A'),
  3384. category: 'timeout/interval',
  3385. fn: function (aNumber){
  3386. var self=this;
  3387. return setInterval(self, aNumber);
  3388. return self;},
  3389. args: ["aNumber"],
  3390. source: unescape('valueWithInterval%3A%20aNumber%0A%09%3Creturn%20setInterval%28self%2C%20aNumber%29%3E'),
  3391. messageSends: [],
  3392. referencedClasses: []
  3393. }),
  3394. smalltalk.BlockClosure);
  3395. smalltalk.addMethod(
  3396. unescape('_whileFalse'),
  3397. smalltalk.method({
  3398. selector: unescape('whileFalse'),
  3399. category: 'controlling',
  3400. fn: function (){
  3401. var self=this;
  3402. smalltalk.send(self, "_whileFalse_", [(function(){return nil;})]);
  3403. return self;},
  3404. args: [],
  3405. source: unescape('whileFalse%0A%09%22inlined%20in%20the%20Compiler%22%0A%09self%20whileFalse%3A%20%5B%5D'),
  3406. messageSends: ["whileFalse:"],
  3407. referencedClasses: []
  3408. }),
  3409. smalltalk.BlockClosure);
  3410. smalltalk.addMethod(
  3411. unescape('_whileTrue'),
  3412. smalltalk.method({
  3413. selector: unescape('whileTrue'),
  3414. category: 'controlling',
  3415. fn: function (){
  3416. var self=this;
  3417. smalltalk.send(self, "_whileTrue_", [(function(){return nil;})]);
  3418. return self;},
  3419. args: [],
  3420. source: unescape('whileTrue%0A%09%22inlined%20in%20the%20Compiler%22%0A%09self%20whileTrue%3A%20%5B%5D'),
  3421. messageSends: ["whileTrue:"],
  3422. referencedClasses: []
  3423. }),
  3424. smalltalk.BlockClosure);
  3425. smalltalk.addMethod(
  3426. unescape('_new'),
  3427. smalltalk.method({
  3428. selector: unescape('new'),
  3429. category: 'evaluating',
  3430. fn: function (){
  3431. var self=this;
  3432. return new self();
  3433. return self;},
  3434. args: [],
  3435. source: unescape('new%0A%09%22Use%20the%20receiver%20as%20a%20JS%20constructor.%20%0A%09*Do%20not*%20use%20this%20method%20to%20instanciate%20Smalltalk%20objects%21%22%0A%09%3Creturn%20new%20self%28%29%3E'),
  3436. messageSends: [],
  3437. referencedClasses: []
  3438. }),
  3439. smalltalk.BlockClosure);
  3440. smalltalk.addMethod(
  3441. unescape('_applyTo_arguments_'),
  3442. smalltalk.method({
  3443. selector: unescape('applyTo%3Aarguments%3A'),
  3444. category: 'evaluating',
  3445. fn: function (anObject, aCollection){
  3446. var self=this;
  3447. return self.apply(anObject, aCollection);
  3448. return self;},
  3449. args: ["anObject", "aCollection"],
  3450. source: unescape('applyTo%3A%20anObject%20arguments%3A%20aCollection%0A%09%3Creturn%20self.apply%28anObject%2C%20aCollection%29%3E'),
  3451. messageSends: [],
  3452. referencedClasses: []
  3453. }),
  3454. smalltalk.BlockClosure);
  3455. smalltalk.addMethod(
  3456. unescape('_timeToRun'),
  3457. smalltalk.method({
  3458. selector: unescape('timeToRun'),
  3459. category: 'evaluating',
  3460. fn: function (){
  3461. var self=this;
  3462. return smalltalk.send((smalltalk.Date || Date), "_millisecondsToRun_", [self]);
  3463. return self;},
  3464. args: [],
  3465. source: unescape('timeToRun%0A%09%22Answer%20the%20number%20of%20milliseconds%20taken%20to%20execute%20this%20block.%22%0A%0A%09%5E%20Date%20millisecondsToRun%3A%20self'),
  3466. messageSends: ["millisecondsToRun:"],
  3467. referencedClasses: ["Date"]
  3468. }),
  3469. smalltalk.BlockClosure);
  3470. smalltalk.addMethod(
  3471. unescape('_numArgs'),
  3472. smalltalk.method({
  3473. selector: unescape('numArgs'),
  3474. category: 'accessing',
  3475. fn: function (){
  3476. var self=this;
  3477. return self.length;
  3478. return self;},
  3479. args: [],
  3480. source: unescape('numArgs%0A%09%3Creturn%20self.length%3E'),
  3481. messageSends: [],
  3482. referencedClasses: []
  3483. }),
  3484. smalltalk.BlockClosure);
  3485. smalltalk.addMethod(
  3486. unescape('_ensure_'),
  3487. smalltalk.method({
  3488. selector: unescape('ensure%3A'),
  3489. category: 'evaluating',
  3490. fn: function (aBlock){
  3491. var self=this;
  3492. var success=nil;
  3493. success=false;
  3494. smalltalk.send((function(){smalltalk.send(self, "_value", []);success=true;return smalltalk.send(aBlock, "_value", []);}), "_on_do_", [(smalltalk.Error || Error), (function(ex){((($receiver = success).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(aBlock, "_value", []);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(aBlock, "_value", []);})]));return smalltalk.send(ex, "_signal", []);})]);
  3495. return self;},
  3496. args: ["aBlock"],
  3497. source: unescape('ensure%3A%20aBlock%0A%09%7C%20success%20%7C%0A%09success%20%3A%3D%20false.%0A%09%5Bself%20value.%20success%20%3A%3D%20true.%20aBlock%20value%5D%0A%09%09on%3A%20Error%0A%09%09do%3A%20%5B%3Aex%20%7C%0A%09%09%09success%20ifFalse%3A%20%5BaBlock%20value%5D.%0A%09%09%09ex%20signal%5D'),
  3498. messageSends: ["on:do:", "value", "ifFalse:", "signal"],
  3499. referencedClasses: ["Error"]
  3500. }),
  3501. smalltalk.BlockClosure);
  3502. smalltalk.addClass('Boolean', smalltalk.Object, [], 'Kernel');
  3503. smalltalk.addMethod(
  3504. unescape('__eq'),
  3505. smalltalk.method({
  3506. selector: unescape('%3D'),
  3507. category: 'comparing',
  3508. fn: function (aBoolean){
  3509. var self=this;
  3510. try{((($receiver = smalltalk.send(smalltalk.send(aBoolean, "_class", []), "__eq", [smalltalk.send(self, "_class", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));
  3511. return Boolean(self == true) == aBoolean;
  3512. return self;
  3513. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq'){return e.fn()} throw(e)}},
  3514. args: ["aBoolean"],
  3515. source: unescape('%3D%20aBoolean%0A%09aBoolean%20class%20%3D%20self%20class%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09%3Creturn%20Boolean%28self%20%3D%3D%20true%29%20%3D%3D%20aBoolean%3E'),
  3516. messageSends: ["ifFalse:", unescape("%3D"), "class"],
  3517. referencedClasses: []
  3518. }),
  3519. smalltalk.Boolean);
  3520. smalltalk.addMethod(
  3521. unescape('_shallowCopy'),
  3522. smalltalk.method({
  3523. selector: unescape('shallowCopy'),
  3524. category: 'copying',
  3525. fn: function (){
  3526. var self=this;
  3527. return self;
  3528. return self;},
  3529. args: [],
  3530. source: unescape('shallowCopy%0A%09%5Eself'),
  3531. messageSends: [],
  3532. referencedClasses: []
  3533. }),
  3534. smalltalk.Boolean);
  3535. smalltalk.addMethod(
  3536. unescape('_deepCopy'),
  3537. smalltalk.method({
  3538. selector: unescape('deepCopy'),
  3539. category: 'copying',
  3540. fn: function (){
  3541. var self=this;
  3542. return self;
  3543. return self;},
  3544. args: [],
  3545. source: unescape('deepCopy%0A%09%5Eself'),
  3546. messageSends: [],
  3547. referencedClasses: []
  3548. }),
  3549. smalltalk.Boolean);
  3550. smalltalk.addMethod(
  3551. unescape('_ifTrue_'),
  3552. smalltalk.method({
  3553. selector: unescape('ifTrue%3A'),
  3554. category: 'controlling',
  3555. fn: function (aBlock){
  3556. var self=this;
  3557. return smalltalk.send(self, "_ifTrue_ifFalse_", [aBlock, (function(){return nil;})]);
  3558. return self;},
  3559. args: ["aBlock"],
  3560. source: unescape('ifTrue%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5Eself%20ifTrue%3A%20aBlock%20ifFalse%3A%20%5B%5D'),
  3561. messageSends: ["ifTrue:ifFalse:"],
  3562. referencedClasses: []
  3563. }),
  3564. smalltalk.Boolean);
  3565. smalltalk.addMethod(
  3566. unescape('_ifFalse_'),
  3567. smalltalk.method({
  3568. selector: unescape('ifFalse%3A'),
  3569. category: 'controlling',
  3570. fn: function (aBlock){
  3571. var self=this;
  3572. return smalltalk.send(self, "_ifTrue_ifFalse_", [(function(){return nil;}), aBlock]);
  3573. return self;},
  3574. args: ["aBlock"],
  3575. source: unescape('ifFalse%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5Eself%20ifTrue%3A%20%5B%5D%20ifFalse%3A%20aBlock'),
  3576. messageSends: ["ifTrue:ifFalse:"],
  3577. referencedClasses: []
  3578. }),
  3579. smalltalk.Boolean);
  3580. smalltalk.addMethod(
  3581. unescape('_ifFalse_ifTrue_'),
  3582. smalltalk.method({
  3583. selector: unescape('ifFalse%3AifTrue%3A'),
  3584. category: 'controlling',
  3585. fn: function (aBlock, anotherBlock){
  3586. var self=this;
  3587. return smalltalk.send(self, "_ifTrue_ifFalse_", [anotherBlock, aBlock]);
  3588. return self;},
  3589. args: ["aBlock", "anotherBlock"],
  3590. source: unescape('ifFalse%3A%20aBlock%20ifTrue%3A%20anotherBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5Eself%20ifTrue%3A%20anotherBlock%20ifFalse%3A%20aBlock'),
  3591. messageSends: ["ifTrue:ifFalse:"],
  3592. referencedClasses: []
  3593. }),
  3594. smalltalk.Boolean);
  3595. smalltalk.addMethod(
  3596. unescape('_ifTrue_ifFalse_'),
  3597. smalltalk.method({
  3598. selector: unescape('ifTrue%3AifFalse%3A'),
  3599. category: 'controlling',
  3600. fn: function (aBlock, anotherBlock){
  3601. var self=this;
  3602. if(self == true) {
  3603. return aBlock();
  3604. } else {
  3605. return anotherBlock();
  3606. }
  3607. ;
  3608. return self;},
  3609. args: ["aBlock", "anotherBlock"],
  3610. source: unescape('ifTrue%3A%20aBlock%20ifFalse%3A%20anotherBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%3C%0A%09%20%20%20%20if%28self%20%3D%3D%20true%29%20%7B%0A%09%09return%20aBlock%28%29%3B%0A%09%20%20%20%20%7D%20else%20%7B%0A%09%09return%20anotherBlock%28%29%3B%0A%09%20%20%20%20%7D%0A%09%3E'),
  3611. messageSends: [],
  3612. referencedClasses: []
  3613. }),
  3614. smalltalk.Boolean);
  3615. smalltalk.addMethod(
  3616. unescape('_and_'),
  3617. smalltalk.method({
  3618. selector: unescape('and%3A'),
  3619. category: 'controlling',
  3620. fn: function (aBlock){
  3621. var self=this;
  3622. return smalltalk.send(smalltalk.send(self, "__eq", [true]), "_ifTrue_ifFalse_", [aBlock, (function(){return false;})]);
  3623. return self;},
  3624. args: ["aBlock"],
  3625. source: unescape('and%3A%20aBlock%0A%09%5Eself%20%3D%20true%0A%09%20%20%20%20ifTrue%3A%20aBlock%0A%09%20%20%20%20ifFalse%3A%20%5Bfalse%5D'),
  3626. messageSends: ["ifTrue:ifFalse:", unescape("%3D")],
  3627. referencedClasses: []
  3628. }),
  3629. smalltalk.Boolean);
  3630. smalltalk.addMethod(
  3631. unescape('_or_'),
  3632. smalltalk.method({
  3633. selector: unescape('or%3A'),
  3634. category: 'controlling',
  3635. fn: function (aBlock){
  3636. var self=this;
  3637. return smalltalk.send(smalltalk.send(self, "__eq", [true]), "_ifTrue_ifFalse_", [(function(){return true;}), aBlock]);
  3638. return self;},
  3639. args: ["aBlock"],
  3640. source: unescape('or%3A%20aBlock%0A%09%5Eself%20%3D%20true%0A%09%20%20%20%20ifTrue%3A%20%5Btrue%5D%0A%09%20%20%20%20ifFalse%3A%20aBlock'),
  3641. messageSends: ["ifTrue:ifFalse:", unescape("%3D")],
  3642. referencedClasses: []
  3643. }),
  3644. smalltalk.Boolean);
  3645. smalltalk.addMethod(
  3646. unescape('_not'),
  3647. smalltalk.method({
  3648. selector: unescape('not'),
  3649. category: 'controlling',
  3650. fn: function (){
  3651. var self=this;
  3652. return smalltalk.send(self, "__eq", [false]);
  3653. return self;},
  3654. args: [],
  3655. source: unescape('not%0A%09%5Eself%20%3D%20false'),
  3656. messageSends: [unescape("%3D")],
  3657. referencedClasses: []
  3658. }),
  3659. smalltalk.Boolean);
  3660. smalltalk.addMethod(
  3661. unescape('_printString'),
  3662. smalltalk.method({
  3663. selector: unescape('printString'),
  3664. category: 'printing',
  3665. fn: function (){
  3666. var self=this;
  3667. return self.toString();
  3668. return self;},
  3669. args: [],
  3670. source: unescape('printString%0A%09%3Creturn%20self.toString%28%29%3E'),
  3671. messageSends: [],
  3672. referencedClasses: []
  3673. }),
  3674. smalltalk.Boolean);
  3675. smalltalk.addMethod(
  3676. unescape('_asJSONObject'),
  3677. smalltalk.method({
  3678. selector: unescape('asJSONObject'),
  3679. category: 'converting',
  3680. fn: function (){
  3681. var self=this;
  3682. return self;
  3683. return self;},
  3684. args: [],
  3685. source: unescape('asJSONObject%0A%09%5Eself'),
  3686. messageSends: [],
  3687. referencedClasses: []
  3688. }),
  3689. smalltalk.Boolean);
  3690. smalltalk.addMethod(
  3691. unescape('_%26'),
  3692. smalltalk.method({
  3693. selector: unescape('%26'),
  3694. category: 'controlling',
  3695. fn: function (aBoolean){
  3696. var self=this;
  3697. if(self == true) {
  3698. return aBoolean;
  3699. } else {
  3700. return false;
  3701. }
  3702. ;
  3703. return self;},
  3704. args: ["aBoolean"],
  3705. source: unescape('%26%20aBoolean%0A%09%3C%0A%09%20%20%20%20if%28self%20%3D%3D%20true%29%20%7B%0A%09%09return%20aBoolean%3B%0A%09%20%20%20%20%7D%20else%20%7B%0A%09%09return%20false%3B%0A%09%20%20%20%20%7D%0A%09%3E'),
  3706. messageSends: [],
  3707. referencedClasses: []
  3708. }),
  3709. smalltalk.Boolean);
  3710. smalltalk.addMethod(
  3711. unescape('_%7C'),
  3712. smalltalk.method({
  3713. selector: unescape('%7C'),
  3714. category: 'controlling',
  3715. fn: function (aBoolean){
  3716. var self=this;
  3717. if(self == true) {
  3718. return true;
  3719. } else {
  3720. return aBoolean;
  3721. }
  3722. ;
  3723. return self;},
  3724. args: ["aBoolean"],
  3725. source: unescape('%7C%20aBoolean%0A%09%3C%0A%09%20%20%20%20if%28self%20%3D%3D%20true%29%20%7B%0A%09%09return%20true%3B%0A%09%20%20%20%20%7D%20else%20%7B%0A%09%09return%20aBoolean%3B%0A%09%20%20%20%20%7D%0A%09%3E'),
  3726. messageSends: [],
  3727. referencedClasses: []
  3728. }),
  3729. smalltalk.Boolean);
  3730. smalltalk.addMethod(
  3731. unescape('__eq_eq'),
  3732. smalltalk.method({
  3733. selector: unescape('%3D%3D'),
  3734. category: 'comparing',
  3735. fn: function (aBoolean){
  3736. var self=this;
  3737. try{((($receiver = smalltalk.send(smalltalk.send(aBoolean, "_class", []), "__eq", [smalltalk.send(self, "_class", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq_eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq_eq', fn: function(){return false}})})();})]));
  3738. return Boolean(self == true) === Boolean(aBoolean == true);
  3739. return self;
  3740. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq_eq'){return e.fn()} throw(e)}},
  3741. args: ["aBoolean"],
  3742. source: unescape('%3D%3D%20aBoolean%0A%09aBoolean%20class%20%3D%20self%20class%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09%3Creturn%20Boolean%28self%20%3D%3D%20true%29%20%3D%3D%3D%20Boolean%28aBoolean%20%3D%3D%20true%29%3E'),
  3743. messageSends: ["ifFalse:", unescape("%3D"), "class"],
  3744. referencedClasses: []
  3745. }),
  3746. smalltalk.Boolean);
  3747. smalltalk.addClass('Date', smalltalk.Object, [], 'Kernel');
  3748. smalltalk.Date.comment=unescape('The%20Date%20class%20is%20used%20to%20work%20with%20dates%20and%20times.')
  3749. smalltalk.addMethod(
  3750. unescape('_year'),
  3751. smalltalk.method({
  3752. selector: unescape('year'),
  3753. category: 'accessing',
  3754. fn: function (){
  3755. var self=this;
  3756. return self.getFullYear();
  3757. return self;},
  3758. args: [],
  3759. source: unescape('year%0A%09%3Creturn%20self.getFullYear%28%29%3E'),
  3760. messageSends: [],
  3761. referencedClasses: []
  3762. }),
  3763. smalltalk.Date);
  3764. smalltalk.addMethod(
  3765. unescape('_month'),
  3766. smalltalk.method({
  3767. selector: unescape('month'),
  3768. category: 'accessing',
  3769. fn: function (){
  3770. var self=this;
  3771. return self.getMonth() + 1;
  3772. return self;},
  3773. args: [],
  3774. source: unescape('month%0A%09%3Creturn%20self.getMonth%28%29%20+%201%3E'),
  3775. messageSends: [],
  3776. referencedClasses: []
  3777. }),
  3778. smalltalk.Date);
  3779. smalltalk.addMethod(
  3780. unescape('_month_'),
  3781. smalltalk.method({
  3782. selector: unescape('month%3A'),
  3783. category: 'accessing',
  3784. fn: function (aNumber){
  3785. var self=this;
  3786. self.setMonth(aNumber - 1);
  3787. return self;},
  3788. args: ["aNumber"],
  3789. source: unescape('month%3A%20aNumber%0A%09%3Cself.setMonth%28aNumber%20-%201%29%3E'),
  3790. messageSends: [],
  3791. referencedClasses: []
  3792. }),
  3793. smalltalk.Date);
  3794. smalltalk.addMethod(
  3795. unescape('_day'),
  3796. smalltalk.method({
  3797. selector: unescape('day'),
  3798. category: 'accessing',
  3799. fn: function (){
  3800. var self=this;
  3801. return smalltalk.send(self, "_dayOfWeek", []);
  3802. return self;},
  3803. args: [],
  3804. source: unescape('day%0A%09%5Eself%20dayOfWeek'),
  3805. messageSends: ["dayOfWeek"],
  3806. referencedClasses: []
  3807. }),
  3808. smalltalk.Date);
  3809. smalltalk.addMethod(
  3810. unescape('_dayOfWeek'),
  3811. smalltalk.method({
  3812. selector: unescape('dayOfWeek'),
  3813. category: 'accessing',
  3814. fn: function (){
  3815. var self=this;
  3816. return self.getDay() + 1;
  3817. return self;},
  3818. args: [],
  3819. source: unescape('dayOfWeek%0A%09%3Creturn%20self.getDay%28%29%20+%201%3E'),
  3820. messageSends: [],
  3821. referencedClasses: []
  3822. }),
  3823. smalltalk.Date);
  3824. smalltalk.addMethod(
  3825. unescape('_dayOfWeek_'),
  3826. smalltalk.method({
  3827. selector: unescape('dayOfWeek%3A'),
  3828. category: 'accessing',
  3829. fn: function (aNumber){
  3830. var self=this;
  3831. return self.setDay(aNumber - 1);
  3832. return self;},
  3833. args: ["aNumber"],
  3834. source: unescape('dayOfWeek%3A%20aNumber%0A%09%3Creturn%20self.setDay%28aNumber%20-%201%29%3E'),
  3835. messageSends: [],
  3836. referencedClasses: []
  3837. }),
  3838. smalltalk.Date);
  3839. smalltalk.addMethod(
  3840. unescape('_day_'),
  3841. smalltalk.method({
  3842. selector: unescape('day%3A'),
  3843. category: 'accessing',
  3844. fn: function (aNumber){
  3845. var self=this;
  3846. smalltalk.send(self, "_day_", [aNumber]);
  3847. return self;},
  3848. args: ["aNumber"],
  3849. source: unescape('day%3A%20aNumber%0A%09self%20day%3A%20aNumber'),
  3850. messageSends: ["day:"],
  3851. referencedClasses: []
  3852. }),
  3853. smalltalk.Date);
  3854. smalltalk.addMethod(
  3855. unescape('_year_'),
  3856. smalltalk.method({
  3857. selector: unescape('year%3A'),
  3858. category: 'accessing',
  3859. fn: function (aNumber){
  3860. var self=this;
  3861. self.setFullYear(aNumber);
  3862. return self;},
  3863. args: ["aNumber"],
  3864. source: unescape('year%3A%20aNumber%0A%09%3Cself.setFullYear%28aNumber%29%3E'),
  3865. messageSends: [],
  3866. referencedClasses: []
  3867. }),
  3868. smalltalk.Date);
  3869. smalltalk.addMethod(
  3870. unescape('_dayOfMonth'),
  3871. smalltalk.method({
  3872. selector: unescape('dayOfMonth'),
  3873. category: 'accessing',
  3874. fn: function (){
  3875. var self=this;
  3876. return self.getDate();
  3877. return self;},
  3878. args: [],
  3879. source: unescape('dayOfMonth%0A%09%3Creturn%20self.getDate%28%29%3E'),
  3880. messageSends: [],
  3881. referencedClasses: []
  3882. }),
  3883. smalltalk.Date);
  3884. smalltalk.addMethod(
  3885. unescape('_dayOfMonth_'),
  3886. smalltalk.method({
  3887. selector: unescape('dayOfMonth%3A'),
  3888. category: 'accessing',
  3889. fn: function (aNumber){
  3890. var self=this;
  3891. self.setDate(aNumber);
  3892. return self;},
  3893. args: ["aNumber"],
  3894. source: unescape('dayOfMonth%3A%20aNumber%0A%09%3Cself.setDate%28aNumber%29%3E'),
  3895. messageSends: [],
  3896. referencedClasses: []
  3897. }),
  3898. smalltalk.Date);
  3899. smalltalk.addMethod(
  3900. unescape('_asString'),
  3901. smalltalk.method({
  3902. selector: unescape('asString'),
  3903. category: 'converting',
  3904. fn: function (){
  3905. var self=this;
  3906. return self.toString();
  3907. return self;},
  3908. args: [],
  3909. source: unescape('asString%0A%09%3Creturn%20self.toString%28%29%3E'),
  3910. messageSends: [],
  3911. referencedClasses: []
  3912. }),
  3913. smalltalk.Date);
  3914. smalltalk.addMethod(
  3915. unescape('_printString'),
  3916. smalltalk.method({
  3917. selector: unescape('printString'),
  3918. category: 'printing',
  3919. fn: function (){
  3920. var self=this;
  3921. return smalltalk.send(self, "_asString", []);
  3922. return self;},
  3923. args: [],
  3924. source: unescape('printString%0A%09%5Eself%20asString'),
  3925. messageSends: ["asString"],
  3926. referencedClasses: []
  3927. }),
  3928. smalltalk.Date);
  3929. smalltalk.addMethod(
  3930. unescape('_asMilliseconds'),
  3931. smalltalk.method({
  3932. selector: unescape('asMilliseconds'),
  3933. category: 'converting',
  3934. fn: function (){
  3935. var self=this;
  3936. return smalltalk.send(self, "_time", []);
  3937. return self;},
  3938. args: [],
  3939. source: unescape('asMilliseconds%0A%09%5Eself%20time'),
  3940. messageSends: ["time"],
  3941. referencedClasses: []
  3942. }),
  3943. smalltalk.Date);
  3944. smalltalk.addMethod(
  3945. unescape('_time'),
  3946. smalltalk.method({
  3947. selector: unescape('time'),
  3948. category: 'accessing',
  3949. fn: function (){
  3950. var self=this;
  3951. return self.getTime();
  3952. return self;},
  3953. args: [],
  3954. source: unescape('time%0A%09%3Creturn%20self.getTime%28%29%3E'),
  3955. messageSends: [],
  3956. referencedClasses: []
  3957. }),
  3958. smalltalk.Date);
  3959. smalltalk.addMethod(
  3960. unescape('_time_'),
  3961. smalltalk.method({
  3962. selector: unescape('time%3A'),
  3963. category: 'accessing',
  3964. fn: function (aNumber){
  3965. var self=this;
  3966. self.setTime(aNumber);
  3967. return self;},
  3968. args: ["aNumber"],
  3969. source: unescape('time%3A%20aNumber%0A%09%3Cself.setTime%28aNumber%29%3E'),
  3970. messageSends: [],
  3971. referencedClasses: []
  3972. }),
  3973. smalltalk.Date);
  3974. smalltalk.addMethod(
  3975. unescape('_asDateString'),
  3976. smalltalk.method({
  3977. selector: unescape('asDateString'),
  3978. category: 'converting',
  3979. fn: function (){
  3980. var self=this;
  3981. return self.toDateString();
  3982. return self;},
  3983. args: [],
  3984. source: unescape('asDateString%0A%09%3Creturn%20self.toDateString%28%29%3E'),
  3985. messageSends: [],
  3986. referencedClasses: []
  3987. }),
  3988. smalltalk.Date);
  3989. smalltalk.addMethod(
  3990. unescape('_asTimeString'),
  3991. smalltalk.method({
  3992. selector: unescape('asTimeString'),
  3993. category: 'converting',
  3994. fn: function (){
  3995. var self=this;
  3996. return self.toTimeString();
  3997. return self;},
  3998. args: [],
  3999. source: unescape('asTimeString%0A%09%3Creturn%20self.toTimeString%28%29%3E'),
  4000. messageSends: [],
  4001. referencedClasses: []
  4002. }),
  4003. smalltalk.Date);
  4004. smalltalk.addMethod(
  4005. unescape('_asLocaleString'),
  4006. smalltalk.method({
  4007. selector: unescape('asLocaleString'),
  4008. category: 'converting',
  4009. fn: function (){
  4010. var self=this;
  4011. return self.toLocaleString();
  4012. return self;},
  4013. args: [],
  4014. source: unescape('asLocaleString%0A%09%3Creturn%20self.toLocaleString%28%29%3E'),
  4015. messageSends: [],
  4016. referencedClasses: []
  4017. }),
  4018. smalltalk.Date);
  4019. smalltalk.addMethod(
  4020. unescape('_asNumber'),
  4021. smalltalk.method({
  4022. selector: unescape('asNumber'),
  4023. category: 'converting',
  4024. fn: function (){
  4025. var self=this;
  4026. return smalltalk.send(self, "_asMilliseconds", []);
  4027. return self;},
  4028. args: [],
  4029. source: unescape('asNumber%0A%09%5Eself%20asMilliseconds'),
  4030. messageSends: ["asMilliseconds"],
  4031. referencedClasses: []
  4032. }),
  4033. smalltalk.Date);
  4034. smalltalk.addMethod(
  4035. unescape('_hours_'),
  4036. smalltalk.method({
  4037. selector: unescape('hours%3A'),
  4038. category: 'accessing',
  4039. fn: function (aNumber){
  4040. var self=this;
  4041. self.setHours(aNumber);
  4042. return self;},
  4043. args: ["aNumber"],
  4044. source: unescape('hours%3A%20aNumber%0A%09%3Cself.setHours%28aNumber%29%3E'),
  4045. messageSends: [],
  4046. referencedClasses: []
  4047. }),
  4048. smalltalk.Date);
  4049. smalltalk.addMethod(
  4050. unescape('_minutes_'),
  4051. smalltalk.method({
  4052. selector: unescape('minutes%3A'),
  4053. category: 'accessing',
  4054. fn: function (aNumber){
  4055. var self=this;
  4056. self.setMinutes(aNumber);
  4057. return self;},
  4058. args: ["aNumber"],
  4059. source: unescape('minutes%3A%20aNumber%0A%09%3Cself.setMinutes%28aNumber%29%3E'),
  4060. messageSends: [],
  4061. referencedClasses: []
  4062. }),
  4063. smalltalk.Date);
  4064. smalltalk.addMethod(
  4065. unescape('_seconds_'),
  4066. smalltalk.method({
  4067. selector: unescape('seconds%3A'),
  4068. category: 'accessing',
  4069. fn: function (aNumber){
  4070. var self=this;
  4071. self.setSeconds(aNumber);
  4072. return self;},
  4073. args: ["aNumber"],
  4074. source: unescape('seconds%3A%20aNumber%0A%09%3Cself.setSeconds%28aNumber%29%3E'),
  4075. messageSends: [],
  4076. referencedClasses: []
  4077. }),
  4078. smalltalk.Date);
  4079. smalltalk.addMethod(
  4080. unescape('_milliseconds_'),
  4081. smalltalk.method({
  4082. selector: unescape('milliseconds%3A'),
  4083. category: 'accessing',
  4084. fn: function (aNumber){
  4085. var self=this;
  4086. self.setMilliseconds(aNumber);
  4087. return self;},
  4088. args: ["aNumber"],
  4089. source: unescape('milliseconds%3A%20aNumber%0A%09%3Cself.setMilliseconds%28aNumber%29%3E'),
  4090. messageSends: [],
  4091. referencedClasses: []
  4092. }),
  4093. smalltalk.Date);
  4094. smalltalk.addMethod(
  4095. unescape('_hours'),
  4096. smalltalk.method({
  4097. selector: unescape('hours'),
  4098. category: 'accessing',
  4099. fn: function (){
  4100. var self=this;
  4101. return self.getHours();
  4102. return self;},
  4103. args: [],
  4104. source: unescape('hours%0A%09%3Creturn%20self.getHours%28%29%3E'),
  4105. messageSends: [],
  4106. referencedClasses: []
  4107. }),
  4108. smalltalk.Date);
  4109. smalltalk.addMethod(
  4110. unescape('_minutes'),
  4111. smalltalk.method({
  4112. selector: unescape('minutes'),
  4113. category: 'accessing',
  4114. fn: function (){
  4115. var self=this;
  4116. return self.getMinutes();
  4117. return self;},
  4118. args: [],
  4119. source: unescape('minutes%0A%09%3Creturn%20self.getMinutes%28%29%3E'),
  4120. messageSends: [],
  4121. referencedClasses: []
  4122. }),
  4123. smalltalk.Date);
  4124. smalltalk.addMethod(
  4125. unescape('_seconds'),
  4126. smalltalk.method({
  4127. selector: unescape('seconds'),
  4128. category: 'accessing',
  4129. fn: function (){
  4130. var self=this;
  4131. return self.getSeconds();
  4132. return self;},
  4133. args: [],
  4134. source: unescape('seconds%0A%09%3Creturn%20self.getSeconds%28%29%3E'),
  4135. messageSends: [],
  4136. referencedClasses: []
  4137. }),
  4138. smalltalk.Date);
  4139. smalltalk.addMethod(
  4140. unescape('_milliseconds'),
  4141. smalltalk.method({
  4142. selector: unescape('milliseconds'),
  4143. category: 'accessing',
  4144. fn: function (){
  4145. var self=this;
  4146. return self.getMilliseconds();
  4147. return self;},
  4148. args: [],
  4149. source: unescape('milliseconds%0A%09%3Creturn%20self.getMilliseconds%28%29%3E'),
  4150. messageSends: [],
  4151. referencedClasses: []
  4152. }),
  4153. smalltalk.Date);
  4154. smalltalk.addMethod(
  4155. unescape('__lt'),
  4156. smalltalk.method({
  4157. selector: unescape('%3C'),
  4158. category: 'comparing',
  4159. fn: function (aDate){
  4160. var self=this;
  4161. return self < aDate;
  4162. return self;},
  4163. args: ["aDate"],
  4164. source: unescape('%3C%20aDate%0A%09%3Creturn%20self%20%3C%20aDate%3E'),
  4165. messageSends: [],
  4166. referencedClasses: []
  4167. }),
  4168. smalltalk.Date);
  4169. smalltalk.addMethod(
  4170. unescape('__gt'),
  4171. smalltalk.method({
  4172. selector: unescape('%3E'),
  4173. category: 'comparing',
  4174. fn: function (aDate){
  4175. var self=this;
  4176. return self > aDate;
  4177. return self;},
  4178. args: ["aDate"],
  4179. source: unescape('%3E%20aDate%0A%09%3Creturn%20self%20%3E%3E%20aDate%3E'),
  4180. messageSends: [],
  4181. referencedClasses: []
  4182. }),
  4183. smalltalk.Date);
  4184. smalltalk.addMethod(
  4185. unescape('__lt_eq'),
  4186. smalltalk.method({
  4187. selector: unescape('%3C%3D'),
  4188. category: 'comparing',
  4189. fn: function (aDate){
  4190. var self=this;
  4191. return self <= aDate;
  4192. return self;},
  4193. args: ["aDate"],
  4194. source: unescape('%3C%3D%20aDate%0A%09%3Creturn%20self%20%3C%3D%20aDate%3E'),
  4195. messageSends: [],
  4196. referencedClasses: []
  4197. }),
  4198. smalltalk.Date);
  4199. smalltalk.addMethod(
  4200. unescape('__gt_eq'),
  4201. smalltalk.method({
  4202. selector: unescape('%3E%3D'),
  4203. category: 'comparing',
  4204. fn: function (aDate){
  4205. var self=this;
  4206. return self >= aDate;
  4207. return self;},
  4208. args: ["aDate"],
  4209. source: unescape('%3E%3D%20aDate%0A%09%3Creturn%20self%20%3E%3E%3D%20aDate%3E'),
  4210. messageSends: [],
  4211. referencedClasses: []
  4212. }),
  4213. smalltalk.Date);
  4214. smalltalk.addMethod(
  4215. unescape('__minus'),
  4216. smalltalk.method({
  4217. selector: unescape('-'),
  4218. category: 'arithmetic',
  4219. fn: function (aDate){
  4220. var self=this;
  4221. return self - aDate;
  4222. return self;},
  4223. args: ["aDate"],
  4224. source: unescape('-%20aDate%0A%09%3Creturn%20self%20-%20aDate%3E'),
  4225. messageSends: [],
  4226. referencedClasses: []
  4227. }),
  4228. smalltalk.Date);
  4229. smalltalk.addMethod(
  4230. unescape('__plus'),
  4231. smalltalk.method({
  4232. selector: unescape('+'),
  4233. category: 'arithmetic',
  4234. fn: function (aDate){
  4235. var self=this;
  4236. return self + aDate;
  4237. return self;},
  4238. args: ["aDate"],
  4239. source: unescape('+%20aDate%0A%09%3Creturn%20self%20+%20aDate%3E'),
  4240. messageSends: [],
  4241. referencedClasses: []
  4242. }),
  4243. smalltalk.Date);
  4244. smalltalk.addMethod(
  4245. unescape('_asJSONObject'),
  4246. smalltalk.method({
  4247. selector: unescape('asJSONObject'),
  4248. category: 'converting',
  4249. fn: function (){
  4250. var self=this;
  4251. return self;
  4252. return self;},
  4253. args: [],
  4254. source: unescape('asJSONObject%0A%09%5Eself'),
  4255. messageSends: [],
  4256. referencedClasses: []
  4257. }),
  4258. smalltalk.Date);
  4259. smalltalk.addMethod(
  4260. unescape('_new_'),
  4261. smalltalk.method({
  4262. selector: unescape('new%3A'),
  4263. category: 'instance creation',
  4264. fn: function (anObject){
  4265. var self=this;
  4266. return new Date(anObject);
  4267. return self;},
  4268. args: ["anObject"],
  4269. source: unescape('new%3A%20anObject%0A%09%3Creturn%20new%20Date%28anObject%29%3E'),
  4270. messageSends: [],
  4271. referencedClasses: []
  4272. }),
  4273. smalltalk.Date.klass);
  4274. smalltalk.addMethod(
  4275. unescape('_fromString_'),
  4276. smalltalk.method({
  4277. selector: unescape('fromString%3A'),
  4278. category: 'instance creation',
  4279. fn: function (aString){
  4280. var self=this;
  4281. return smalltalk.send(self, "_new_", [aString]);
  4282. return self;},
  4283. args: ["aString"],
  4284. source: unescape('fromString%3A%20aString%0A%09%22Example%3A%20Date%20fromString%28%272011/04/15%2000%3A00%3A00%27%29%22%0A%09%5Eself%20new%3A%20aString'),
  4285. messageSends: ["new:"],
  4286. referencedClasses: []
  4287. }),
  4288. smalltalk.Date.klass);
  4289. smalltalk.addMethod(
  4290. unescape('_fromSeconds_'),
  4291. smalltalk.method({
  4292. selector: unescape('fromSeconds%3A'),
  4293. category: 'instance creation',
  4294. fn: function (aNumber){
  4295. var self=this;
  4296. return smalltalk.send(self, "_fromMilliseconds_", [((($receiver = aNumber).klass === smalltalk.Number) ? $receiver *(1000) : smalltalk.send($receiver, "__star", [(1000)]))]);
  4297. return self;},
  4298. args: ["aNumber"],
  4299. source: unescape('fromSeconds%3A%20aNumber%0A%09%5Eself%20fromMilliseconds%3A%20aNumber%20*%201000'),
  4300. messageSends: ["fromMilliseconds:", unescape("*")],
  4301. referencedClasses: []
  4302. }),
  4303. smalltalk.Date.klass);
  4304. smalltalk.addMethod(
  4305. unescape('_fromMilliseconds_'),
  4306. smalltalk.method({
  4307. selector: unescape('fromMilliseconds%3A'),
  4308. category: 'instance creation',
  4309. fn: function (aNumber){
  4310. var self=this;
  4311. return smalltalk.send(self, "_new_", [aNumber]);
  4312. return self;},
  4313. args: ["aNumber"],
  4314. source: unescape('fromMilliseconds%3A%20aNumber%0A%09%5Eself%20new%3A%20aNumber'),
  4315. messageSends: ["new:"],
  4316. referencedClasses: []
  4317. }),
  4318. smalltalk.Date.klass);
  4319. smalltalk.addMethod(
  4320. unescape('_today'),
  4321. smalltalk.method({
  4322. selector: unescape('today'),
  4323. category: 'instance creation',
  4324. fn: function (){
  4325. var self=this;
  4326. return smalltalk.send(self, "_new", []);
  4327. return self;},
  4328. args: [],
  4329. source: unescape('today%0A%09%5Eself%20new'),
  4330. messageSends: ["new"],
  4331. referencedClasses: []
  4332. }),
  4333. smalltalk.Date.klass);
  4334. smalltalk.addMethod(
  4335. unescape('_now'),
  4336. smalltalk.method({
  4337. selector: unescape('now'),
  4338. category: 'instance creation',
  4339. fn: function (){
  4340. var self=this;
  4341. return smalltalk.send(self, "_today", []);
  4342. return self;},
  4343. args: [],
  4344. source: unescape('now%0A%09%5Eself%20today'),
  4345. messageSends: ["today"],
  4346. referencedClasses: []
  4347. }),
  4348. smalltalk.Date.klass);
  4349. smalltalk.addMethod(
  4350. unescape('_millisecondsToRun_'),
  4351. smalltalk.method({
  4352. selector: unescape('millisecondsToRun%3A'),
  4353. category: 'instance creation',
  4354. fn: function (aBlock){
  4355. var self=this;
  4356. var t=nil;
  4357. t=smalltalk.send((smalltalk.Date || Date), "_now", []);
  4358. smalltalk.send(aBlock, "_value", []);
  4359. return ((($receiver = smalltalk.send((smalltalk.Date || Date), "_now", [])).klass === smalltalk.Number) ? $receiver -t : smalltalk.send($receiver, "__minus", [t]));
  4360. return self;},
  4361. args: ["aBlock"],
  4362. source: unescape('millisecondsToRun%3A%20aBlock%0A%09%7C%20t%20%7C%0A%09t%20%3A%3D%20Date%20now.%0A%09aBlock%20value.%0A%09%5EDate%20now%20-%20t'),
  4363. messageSends: ["now", "value", unescape("-")],
  4364. referencedClasses: ["Date"]
  4365. }),
  4366. smalltalk.Date.klass);
  4367. smalltalk.addClass('UndefinedObject', smalltalk.Object, [], 'Kernel');
  4368. smalltalk.addMethod(
  4369. unescape('_subclass_instanceVariableNames_'),
  4370. smalltalk.method({
  4371. selector: unescape('subclass%3AinstanceVariableNames%3A'),
  4372. category: 'class creation',
  4373. fn: function (aString, anotherString){
  4374. var self=this;
  4375. return smalltalk.send(self, "_subclass_instanceVariableNames_package_", [aString, anotherString, nil]);
  4376. return self;},
  4377. args: ["aString", "anotherString"],
  4378. source: unescape('subclass%3A%20aString%20instanceVariableNames%3A%20anotherString%0A%09%5Eself%20subclass%3A%20aString%20instanceVariableNames%3A%20anotherString%20package%3A%20nil'),
  4379. messageSends: ["subclass:instanceVariableNames:package:"],
  4380. referencedClasses: []
  4381. }),
  4382. smalltalk.UndefinedObject);
  4383. smalltalk.addMethod(
  4384. unescape('_subclass_instanceVariableNames_category_'),
  4385. smalltalk.method({
  4386. selector: unescape('subclass%3AinstanceVariableNames%3Acategory%3A'),
  4387. category: 'class creation',
  4388. fn: function (aString, aString2, aString3){
  4389. var self=this;
  4390. return smalltalk.send(self, "_subclass_instanceVariableNames_package_", [aString, aString2, aString3]);
  4391. return self;},
  4392. args: ["aString", "aString2", "aString3"],
  4393. source: unescape('subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20category%3A%20aString3%0A%09%22Kept%20for%20compatibility.%22%0A%09%5Eself%20subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3'),
  4394. messageSends: ["subclass:instanceVariableNames:package:"],
  4395. referencedClasses: []
  4396. }),
  4397. smalltalk.UndefinedObject);
  4398. smalltalk.addMethod(
  4399. unescape('_shallowCopy'),
  4400. smalltalk.method({
  4401. selector: unescape('shallowCopy'),
  4402. category: 'copying',
  4403. fn: function (){
  4404. var self=this;
  4405. return self;
  4406. return self;},
  4407. args: [],
  4408. source: unescape('shallowCopy%0A%09%5Eself'),
  4409. messageSends: [],
  4410. referencedClasses: []
  4411. }),
  4412. smalltalk.UndefinedObject);
  4413. smalltalk.addMethod(
  4414. unescape('_deepCopy'),
  4415. smalltalk.method({
  4416. selector: unescape('deepCopy'),
  4417. category: 'copying',
  4418. fn: function (){
  4419. var self=this;
  4420. return self;
  4421. return self;},
  4422. args: [],
  4423. source: unescape('deepCopy%0A%09%5Eself'),
  4424. messageSends: [],
  4425. referencedClasses: []
  4426. }),
  4427. smalltalk.UndefinedObject);
  4428. smalltalk.addMethod(
  4429. unescape('_ifNil_'),
  4430. smalltalk.method({
  4431. selector: unescape('ifNil%3A'),
  4432. category: 'testing',
  4433. fn: function (aBlock){
  4434. var self=this;
  4435. return smalltalk.send(self, "_ifNil_ifNotNil_", [aBlock, (function(){return nil;})]);
  4436. return self;},
  4437. args: ["aBlock"],
  4438. source: unescape('ifNil%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5Eself%20ifNil%3A%20aBlock%20ifNotNil%3A%20%5B%5D'),
  4439. messageSends: ["ifNil:ifNotNil:"],
  4440. referencedClasses: []
  4441. }),
  4442. smalltalk.UndefinedObject);
  4443. smalltalk.addMethod(
  4444. unescape('_ifNotNil_'),
  4445. smalltalk.method({
  4446. selector: unescape('ifNotNil%3A'),
  4447. category: 'testing',
  4448. fn: function (aBlock){
  4449. var self=this;
  4450. return self;
  4451. return self;},
  4452. args: ["aBlock"],
  4453. source: unescape('ifNotNil%3A%20aBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5Eself'),
  4454. messageSends: [],
  4455. referencedClasses: []
  4456. }),
  4457. smalltalk.UndefinedObject);
  4458. smalltalk.addMethod(
  4459. unescape('_ifNil_ifNotNil_'),
  4460. smalltalk.method({
  4461. selector: unescape('ifNil%3AifNotNil%3A'),
  4462. category: 'testing',
  4463. fn: function (aBlock, anotherBlock){
  4464. var self=this;
  4465. return smalltalk.send(aBlock, "_value", []);
  4466. return self;},
  4467. args: ["aBlock", "anotherBlock"],
  4468. source: unescape('ifNil%3A%20aBlock%20ifNotNil%3A%20anotherBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5EaBlock%20value'),
  4469. messageSends: ["value"],
  4470. referencedClasses: []
  4471. }),
  4472. smalltalk.UndefinedObject);
  4473. smalltalk.addMethod(
  4474. unescape('_ifNotNil_ifNil_'),
  4475. smalltalk.method({
  4476. selector: unescape('ifNotNil%3AifNil%3A'),
  4477. category: 'testing',
  4478. fn: function (aBlock, anotherBlock){
  4479. var self=this;
  4480. return smalltalk.send(anotherBlock, "_value", []);
  4481. return self;},
  4482. args: ["aBlock", "anotherBlock"],
  4483. source: unescape('ifNotNil%3A%20aBlock%20ifNil%3A%20anotherBlock%0A%09%22inlined%20in%20the%20Compiler%22%0A%09%5EanotherBlock%20value'),
  4484. messageSends: ["value"],
  4485. referencedClasses: []
  4486. }),
  4487. smalltalk.UndefinedObject);
  4488. smalltalk.addMethod(
  4489. unescape('_isNil'),
  4490. smalltalk.method({
  4491. selector: unescape('isNil'),
  4492. category: 'testing',
  4493. fn: function (){
  4494. var self=this;
  4495. return true;
  4496. return self;},
  4497. args: [],
  4498. source: unescape('isNil%0A%09%5Etrue'),
  4499. messageSends: [],
  4500. referencedClasses: []
  4501. }),
  4502. smalltalk.UndefinedObject);
  4503. smalltalk.addMethod(
  4504. unescape('_notNil'),
  4505. smalltalk.method({
  4506. selector: unescape('notNil'),
  4507. category: 'testing',
  4508. fn: function (){
  4509. var self=this;
  4510. return false;
  4511. return self;},
  4512. args: [],
  4513. source: unescape('notNil%0A%09%5Efalse'),
  4514. messageSends: [],
  4515. referencedClasses: []
  4516. }),
  4517. smalltalk.UndefinedObject);
  4518. smalltalk.addMethod(
  4519. unescape('_printString'),
  4520. smalltalk.method({
  4521. selector: unescape('printString'),
  4522. category: 'printing',
  4523. fn: function (){
  4524. var self=this;
  4525. return "nil";
  4526. return self;},
  4527. args: [],
  4528. source: unescape('printString%0A%20%20%20%20%5E%27nil%27'),
  4529. messageSends: [],
  4530. referencedClasses: []
  4531. }),
  4532. smalltalk.UndefinedObject);
  4533. smalltalk.addMethod(
  4534. unescape('_subclass_instanceVariableNames_package_'),
  4535. smalltalk.method({
  4536. selector: unescape('subclass%3AinstanceVariableNames%3Apackage%3A'),
  4537. category: 'class creation',
  4538. fn: function (aString, aString2, aString3){
  4539. var self=this;
  4540. return smalltalk.send(smalltalk.send((smalltalk.ClassBuilder || ClassBuilder), "_new", []), "_superclass_subclass_instanceVariableNames_package_", [self, aString, aString2, aString3]);
  4541. return self;},
  4542. args: ["aString", "aString2", "aString3"],
  4543. source: unescape('subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3%0A%09%5EClassBuilder%20new%0A%09%20%20%20%20superclass%3A%20self%20subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3'),
  4544. messageSends: ["superclass:subclass:instanceVariableNames:package:", "new"],
  4545. referencedClasses: ["ClassBuilder"]
  4546. }),
  4547. smalltalk.UndefinedObject);
  4548. smalltalk.addMethod(
  4549. unescape('_new'),
  4550. smalltalk.method({
  4551. selector: unescape('new'),
  4552. category: 'instance creation',
  4553. fn: function (){
  4554. var self=this;
  4555. smalltalk.send(self, "_error_", ["You cannot create new instances of UndefinedObject. Use nil"]);
  4556. return self;},
  4557. args: [],
  4558. source: unescape('new%0A%09%20%20%20%20self%20error%3A%20%27You%20cannot%20create%20new%20instances%20of%20UndefinedObject.%20Use%20nil%27'),
  4559. messageSends: ["error:"],
  4560. referencedClasses: []
  4561. }),
  4562. smalltalk.UndefinedObject.klass);
  4563. smalltalk.addClass('Collection', smalltalk.Object, [], 'Kernel');
  4564. smalltalk.addMethod(
  4565. unescape('_size'),
  4566. smalltalk.method({
  4567. selector: unescape('size'),
  4568. category: 'accessing',
  4569. fn: function (){
  4570. var self=this;
  4571. smalltalk.send(self, "_subclassResponsibility", []);
  4572. return self;},
  4573. args: [],
  4574. source: unescape('size%0A%09self%20subclassResponsibility'),
  4575. messageSends: ["subclassResponsibility"],
  4576. referencedClasses: []
  4577. }),
  4578. smalltalk.Collection);
  4579. smalltalk.addMethod(
  4580. unescape('_readStream'),
  4581. smalltalk.method({
  4582. selector: unescape('readStream'),
  4583. category: 'accessing',
  4584. fn: function (){
  4585. var self=this;
  4586. return smalltalk.send(self, "_stream", []);
  4587. return self;},
  4588. args: [],
  4589. source: unescape('readStream%0A%09%5Eself%20stream'),
  4590. messageSends: ["stream"],
  4591. referencedClasses: []
  4592. }),
  4593. smalltalk.Collection);
  4594. smalltalk.addMethod(
  4595. unescape('_writeStream'),
  4596. smalltalk.method({
  4597. selector: unescape('writeStream'),
  4598. category: 'accessing',
  4599. fn: function (){
  4600. var self=this;
  4601. return smalltalk.send(self, "_stream", []);
  4602. return self;},
  4603. args: [],
  4604. source: unescape('writeStream%0A%09%5Eself%20stream'),
  4605. messageSends: ["stream"],
  4606. referencedClasses: []
  4607. }),
  4608. smalltalk.Collection);
  4609. smalltalk.addMethod(
  4610. unescape('_stream'),
  4611. smalltalk.method({
  4612. selector: unescape('stream'),
  4613. category: 'accessing',
  4614. fn: function (){
  4615. var self=this;
  4616. return smalltalk.send(smalltalk.send(self, "_streamClass", []), "_on_", [self]);
  4617. return self;},
  4618. args: [],
  4619. source: unescape('stream%0A%09%5Eself%20streamClass%20on%3A%20self'),
  4620. messageSends: ["on:", "streamClass"],
  4621. referencedClasses: []
  4622. }),
  4623. smalltalk.Collection);
  4624. smalltalk.addMethod(
  4625. unescape('_streamClass'),
  4626. smalltalk.method({
  4627. selector: unescape('streamClass'),
  4628. category: 'accessing',
  4629. fn: function (){
  4630. var self=this;
  4631. return smalltalk.send(smalltalk.send(self, "_class", []), "_streamClass", []);
  4632. return self;},
  4633. args: [],
  4634. source: unescape('streamClass%0A%09%5Eself%20class%20streamClass'),
  4635. messageSends: ["streamClass", "class"],
  4636. referencedClasses: []
  4637. }),
  4638. smalltalk.Collection);
  4639. smalltalk.addMethod(
  4640. unescape('_add_'),
  4641. smalltalk.method({
  4642. selector: unescape('add%3A'),
  4643. category: 'adding/removing',
  4644. fn: function (anObject){
  4645. var self=this;
  4646. smalltalk.send(self, "_subclassResponsibility", []);
  4647. return self;},
  4648. args: ["anObject"],
  4649. source: unescape('add%3A%20anObject%0A%09self%20subclassResponsibility'),
  4650. messageSends: ["subclassResponsibility"],
  4651. referencedClasses: []
  4652. }),
  4653. smalltalk.Collection);
  4654. smalltalk.addMethod(
  4655. unescape('_addAll_'),
  4656. smalltalk.method({
  4657. selector: unescape('addAll%3A'),
  4658. category: 'adding/removing',
  4659. fn: function (aCollection){
  4660. var self=this;
  4661. smalltalk.send(aCollection, "_do_", [(function(each){return smalltalk.send(self, "_add_", [each]);})]);
  4662. return aCollection;
  4663. return self;},
  4664. args: ["aCollection"],
  4665. source: unescape('addAll%3A%20aCollection%0A%09aCollection%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20self%20add%3A%20each%5D.%0A%09%5EaCollection'),
  4666. messageSends: ["do:", "add:"],
  4667. referencedClasses: []
  4668. }),
  4669. smalltalk.Collection);
  4670. smalltalk.addMethod(
  4671. unescape('__comma'),
  4672. smalltalk.method({
  4673. selector: unescape('%2C'),
  4674. category: 'copying',
  4675. fn: function (aCollection){
  4676. var self=this;
  4677. return (function($rec){smalltalk.send($rec, "_addAll_", [aCollection]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_copy", []));
  4678. return self;},
  4679. args: ["aCollection"],
  4680. source: unescape('%2C%20aCollection%0A%09%5Eself%20copy%20%0A%09%20%20%20%20addAll%3A%20aCollection%3B%20%0A%09%20%20%20%20yourself'),
  4681. messageSends: ["addAll:", "yourself", "copy"],
  4682. referencedClasses: []
  4683. }),
  4684. smalltalk.Collection);
  4685. smalltalk.addMethod(
  4686. unescape('_copyWith_'),
  4687. smalltalk.method({
  4688. selector: unescape('copyWith%3A'),
  4689. category: 'copying',
  4690. fn: function (anObject){
  4691. var self=this;
  4692. return (function($rec){smalltalk.send($rec, "_add_", [anObject]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_copy", []));
  4693. return self;},
  4694. args: ["anObject"],
  4695. source: unescape('copyWith%3A%20anObject%0A%09%5Eself%20copy%20add%3A%20anObject%3B%20yourself'),
  4696. messageSends: ["add:", "yourself", "copy"],
  4697. referencedClasses: []
  4698. }),
  4699. smalltalk.Collection);
  4700. smalltalk.addMethod(
  4701. unescape('_copyWithAll_'),
  4702. smalltalk.method({
  4703. selector: unescape('copyWithAll%3A'),
  4704. category: 'copying',
  4705. fn: function (aCollection){
  4706. var self=this;
  4707. return (function($rec){smalltalk.send($rec, "_addAll_", [aCollection]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_copy", []));
  4708. return self;},
  4709. args: ["aCollection"],
  4710. source: unescape('copyWithAll%3A%20aCollection%0A%09%5Eself%20copy%20addAll%3A%20aCollection%3B%20yourself'),
  4711. messageSends: ["addAll:", "yourself", "copy"],
  4712. referencedClasses: []
  4713. }),
  4714. smalltalk.Collection);
  4715. smalltalk.addMethod(
  4716. unescape('_asArray'),
  4717. smalltalk.method({
  4718. selector: unescape('asArray'),
  4719. category: 'converting',
  4720. fn: function (){
  4721. var self=this;
  4722. var array=nil;
  4723. var index=nil;
  4724. array=smalltalk.send((smalltalk.Array || Array), "_new", []);
  4725. index=(0);
  4726. smalltalk.send(self, "_do_", [(function(each){index=((($receiver = index).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));return smalltalk.send(array, "_at_put_", [index, each]);})]);
  4727. return array;
  4728. return self;},
  4729. args: [],
  4730. source: unescape('asArray%0A%09%7C%20array%20index%20%7C%0A%09array%20%3A%3D%20Array%20new.%0A%09index%20%3A%3D%200.%0A%09self%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20index%20%3A%3D%20index%20+%201.%0A%09%20%20%20%20array%20at%3A%20index%20put%3A%20each%5D.%0A%09%5Earray'),
  4731. messageSends: ["new", "do:", unescape("+"), "at:put:"],
  4732. referencedClasses: ["Array"]
  4733. }),
  4734. smalltalk.Collection);
  4735. smalltalk.addMethod(
  4736. unescape('_do_'),
  4737. smalltalk.method({
  4738. selector: unescape('do%3A'),
  4739. category: 'enumerating',
  4740. fn: function (aBlock){
  4741. var self=this;
  4742. for(var i=0;i<self.length;i++){aBlock(self[i]);};
  4743. return self;},
  4744. args: ["aBlock"],
  4745. source: unescape('do%3A%20aBlock%0A%09%3Cfor%28var%20i%3D0%3Bi%3Cself.length%3Bi++%29%7BaBlock%28self%5Bi%5D%29%3B%7D%3E'),
  4746. messageSends: [],
  4747. referencedClasses: []
  4748. }),
  4749. smalltalk.Collection);
  4750. smalltalk.addMethod(
  4751. unescape('_collect_'),
  4752. smalltalk.method({
  4753. selector: unescape('collect%3A'),
  4754. category: 'enumerating',
  4755. fn: function (aBlock){
  4756. var self=this;
  4757. var newCollection=nil;
  4758. newCollection=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  4759. smalltalk.send(self, "_do_", [(function(each){return smalltalk.send(newCollection, "_add_", [smalltalk.send(aBlock, "_value_", [each])]);})]);
  4760. return newCollection;
  4761. return self;},
  4762. args: ["aBlock"],
  4763. source: unescape('collect%3A%20aBlock%0A%09%7C%20newCollection%20%7C%0A%09newCollection%20%3A%3D%20self%20class%20new.%0A%09self%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20newCollection%20add%3A%20%28aBlock%20value%3A%20each%29%5D.%0A%09%5EnewCollection'),
  4764. messageSends: ["new", "class", "do:", "add:", "value:"],
  4765. referencedClasses: []
  4766. }),
  4767. smalltalk.Collection);
  4768. smalltalk.addMethod(
  4769. unescape('_detect_'),
  4770. smalltalk.method({
  4771. selector: unescape('detect%3A'),
  4772. category: 'enumerating',
  4773. fn: function (aBlock){
  4774. var self=this;
  4775. return smalltalk.send(self, "_detect_ifNone_", [aBlock, (function(){return smalltalk.send(self, "_errorNotFound", []);})]);
  4776. return self;},
  4777. args: ["aBlock"],
  4778. source: unescape('detect%3A%20aBlock%0A%09%5Eself%20detect%3A%20aBlock%20ifNone%3A%20%5Bself%20errorNotFound%5D'),
  4779. messageSends: ["detect:ifNone:", "errorNotFound"],
  4780. referencedClasses: []
  4781. }),
  4782. smalltalk.Collection);
  4783. smalltalk.addMethod(
  4784. unescape('_detect_ifNone_'),
  4785. smalltalk.method({
  4786. selector: unescape('detect%3AifNone%3A'),
  4787. category: 'enumerating',
  4788. fn: function (aBlock, anotherBlock){
  4789. var self=this;
  4790. for(var i = 0; i < self.length; i++)
  4791. if(aBlock(self[i]))
  4792. return self[i];
  4793. return anotherBlock();
  4794. ;
  4795. return self;},
  4796. args: ["aBlock", "anotherBlock"],
  4797. source: unescape('detect%3A%20aBlock%20ifNone%3A%20anotherBlock%0A%09%3C%0A%09%09for%28var%20i%20%3D%200%3B%20i%20%3C%20self.length%3B%20i++%29%0A%09%09%09if%28aBlock%28self%5Bi%5D%29%29%0A%09%09%09%09return%20self%5Bi%5D%3B%0A%09%09return%20anotherBlock%28%29%3B%0A%09%3E'),
  4798. messageSends: [],
  4799. referencedClasses: []
  4800. }),
  4801. smalltalk.Collection);
  4802. smalltalk.addMethod(
  4803. unescape('_do_separatedBy_'),
  4804. smalltalk.method({
  4805. selector: unescape('do%3AseparatedBy%3A'),
  4806. category: 'enumerating',
  4807. fn: function (aBlock, anotherBlock){
  4808. var self=this;
  4809. var first=nil;
  4810. first=true;
  4811. smalltalk.send(self, "_do_", [(function(each){((($receiver = first).klass === smalltalk.Boolean) ? ($receiver ? (function(){return first=false;})() : (function(){return smalltalk.send(anotherBlock, "_value", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return first=false;}), (function(){return smalltalk.send(anotherBlock, "_value", []);})]));return smalltalk.send(aBlock, "_value_", [each]);})]);
  4812. return self;},
  4813. args: ["aBlock", "anotherBlock"],
  4814. source: unescape('do%3A%20aBlock%20separatedBy%3A%20anotherBlock%0A%20%20%20%20%09%7C%20first%20%7C%0A%20%20%20%20%09first%20%3A%3D%20true.%0A%20%20%20%20%09self%20do%3A%20%5B%3Aeach%20%7C%0A%20%20%20%20%09%20%20%20%20first%0A%20%20%20%20%09%09ifTrue%3A%20%5Bfirst%20%3A%3D%20false%5D%0A%20%20%20%20%09%09ifFalse%3A%20%5BanotherBlock%20value%5D.%0A%20%20%20%20%09%20%20%20%20aBlock%20value%3A%20each%5D'),
  4815. messageSends: ["do:", "ifTrue:ifFalse:", "value", "value:"],
  4816. referencedClasses: []
  4817. }),
  4818. smalltalk.Collection);
  4819. smalltalk.addMethod(
  4820. unescape('_inject_into_'),
  4821. smalltalk.method({
  4822. selector: unescape('inject%3Ainto%3A'),
  4823. category: 'enumerating',
  4824. fn: function (anObject, aBlock){
  4825. var self=this;
  4826. var result=nil;
  4827. result=anObject;
  4828. smalltalk.send(self, "_do_", [(function(each){return result=smalltalk.send(aBlock, "_value_value_", [result, each]);})]);
  4829. return result;
  4830. return self;},
  4831. args: ["anObject", "aBlock"],
  4832. source: unescape('inject%3A%20anObject%20into%3A%20aBlock%0A%09%7C%20result%20%7C%0A%09result%20%3A%3D%20anObject.%0A%09self%20do%3A%20%5B%3Aeach%20%7C%20%0A%09%20%20%20%20result%20%3A%3D%20aBlock%20value%3A%20result%20value%3A%20each%5D.%0A%09%5Eresult'),
  4833. messageSends: ["do:", "value:value:"],
  4834. referencedClasses: []
  4835. }),
  4836. smalltalk.Collection);
  4837. smalltalk.addMethod(
  4838. unescape('_reject_'),
  4839. smalltalk.method({
  4840. selector: unescape('reject%3A'),
  4841. category: 'enumerating',
  4842. fn: function (aBlock){
  4843. var self=this;
  4844. return smalltalk.send(self, "_select_", [(function(each){return smalltalk.send(smalltalk.send(aBlock, "_value_", [each]), "__eq", [false]);})]);
  4845. return self;},
  4846. args: ["aBlock"],
  4847. source: unescape('reject%3A%20aBlock%0A%09%5Eself%20select%3A%20%5B%3Aeach%20%7C%20%28aBlock%20value%3A%20each%29%20%3D%20false%5D'),
  4848. messageSends: ["select:", unescape("%3D"), "value:"],
  4849. referencedClasses: []
  4850. }),
  4851. smalltalk.Collection);
  4852. smalltalk.addMethod(
  4853. unescape('_select_'),
  4854. smalltalk.method({
  4855. selector: unescape('select%3A'),
  4856. category: 'enumerating',
  4857. fn: function (aBlock){
  4858. var self=this;
  4859. var stream=nil;
  4860. stream=smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "_new", []), "_writeStream", []);
  4861. smalltalk.send(self, "_do_", [(function(each){return ((($receiver = smalltalk.send(aBlock, "_value_", [each])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(stream, "_nextPut_", [each]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(stream, "_nextPut_", [each]);})]));})]);
  4862. return smalltalk.send(stream, "_contents", []);
  4863. return self;},
  4864. args: ["aBlock"],
  4865. source: unescape('select%3A%20aBlock%0A%09%7C%20stream%20%7C%0A%09stream%20%3A%3D%20self%20class%20new%20writeStream.%0A%09self%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20%28aBlock%20value%3A%20each%29%20ifTrue%3A%20%5B%0A%09%09stream%20nextPut%3A%20each%5D%5D.%0A%09%5Estream%20contents'),
  4866. messageSends: ["writeStream", "new", "class", "do:", "ifTrue:", "value:", "nextPut:", "contents"],
  4867. referencedClasses: []
  4868. }),
  4869. smalltalk.Collection);
  4870. smalltalk.addMethod(
  4871. unescape('_errorNotFound'),
  4872. smalltalk.method({
  4873. selector: unescape('errorNotFound'),
  4874. category: 'error handling',
  4875. fn: function (){
  4876. var self=this;
  4877. smalltalk.send(self, "_error_", ["Object is not in the collection"]);
  4878. return self;},
  4879. args: [],
  4880. source: unescape('errorNotFound%0A%09self%20error%3A%20%27Object%20is%20not%20in%20the%20collection%27'),
  4881. messageSends: ["error:"],
  4882. referencedClasses: []
  4883. }),
  4884. smalltalk.Collection);
  4885. smalltalk.addMethod(
  4886. unescape('_includes_'),
  4887. smalltalk.method({
  4888. selector: unescape('includes%3A'),
  4889. category: 'testing',
  4890. fn: function (anObject){
  4891. var self=this;
  4892. var i = self.length;
  4893. while (i--) {
  4894. if (smalltalk.send(self[i], "__eq", [anObject])) {return true;}
  4895. }
  4896. return false
  4897. ;
  4898. return self;},
  4899. args: ["anObject"],
  4900. source: unescape('includes%3A%20anObject%0A%09%3C%0A%09%09var%20i%20%3D%20self.length%3B%0A%09%09while%20%28i--%29%20%7B%0A%09%09%09if%20%28smalltalk.send%28self%5Bi%5D%2C%20%22__eq%22%2C%20%5BanObject%5D%29%29%20%7Breturn%20true%3B%7D%09%0A%09%09%7D%0A%09%09return%20false%0A%09%3E'),
  4901. messageSends: [],
  4902. referencedClasses: []
  4903. }),
  4904. smalltalk.Collection);
  4905. smalltalk.addMethod(
  4906. unescape('_notEmpty'),
  4907. smalltalk.method({
  4908. selector: unescape('notEmpty'),
  4909. category: 'testing',
  4910. fn: function (){
  4911. var self=this;
  4912. return smalltalk.send(smalltalk.send(self, "_isEmpty", []), "_not", []);
  4913. return self;},
  4914. args: [],
  4915. source: unescape('notEmpty%0A%09%5Eself%20isEmpty%20not'),
  4916. messageSends: ["not", "isEmpty"],
  4917. referencedClasses: []
  4918. }),
  4919. smalltalk.Collection);
  4920. smalltalk.addMethod(
  4921. unescape('_isEmpty'),
  4922. smalltalk.method({
  4923. selector: unescape('isEmpty'),
  4924. category: 'testing',
  4925. fn: function (){
  4926. var self=this;
  4927. return smalltalk.send(smalltalk.send(self, "_size", []), "__eq", [(0)]);
  4928. return self;},
  4929. args: [],
  4930. source: unescape('isEmpty%0A%09%5Eself%20size%20%3D%200'),
  4931. messageSends: [unescape("%3D"), "size"],
  4932. referencedClasses: []
  4933. }),
  4934. smalltalk.Collection);
  4935. smalltalk.addMethod(
  4936. unescape('_remove_'),
  4937. smalltalk.method({
  4938. selector: unescape('remove%3A'),
  4939. category: 'adding/removing',
  4940. fn: function (anObject){
  4941. var self=this;
  4942. smalltalk.send(self, "_subclassResponsibility", []);
  4943. return self;},
  4944. args: ["anObject"],
  4945. source: unescape('remove%3A%20anObject%0A%20%20%20%20self%20subclassResponsibility'),
  4946. messageSends: ["subclassResponsibility"],
  4947. referencedClasses: []
  4948. }),
  4949. smalltalk.Collection);
  4950. smalltalk.addMethod(
  4951. unescape('_asSet'),
  4952. smalltalk.method({
  4953. selector: unescape('asSet'),
  4954. category: 'converting',
  4955. fn: function (){
  4956. var self=this;
  4957. return smalltalk.send((smalltalk.Set || Set), "_withAll_", [self]);
  4958. return self;},
  4959. args: [],
  4960. source: unescape('asSet%0A%09%5ESet%20withAll%3A%20self'),
  4961. messageSends: ["withAll:"],
  4962. referencedClasses: ["Set"]
  4963. }),
  4964. smalltalk.Collection);
  4965. smalltalk.addMethod(
  4966. unescape('_ifNotEmpty_'),
  4967. smalltalk.method({
  4968. selector: unescape('ifNotEmpty%3A'),
  4969. category: 'testing',
  4970. fn: function (aBlock){
  4971. var self=this;
  4972. smalltalk.send(smalltalk.send(self, "_notEmpty", []), "_ifTrue_", [aBlock]);
  4973. return self;},
  4974. args: ["aBlock"],
  4975. source: unescape('ifNotEmpty%3A%20aBlock%0A%09self%20notEmpty%20ifTrue%3A%20aBlock.'),
  4976. messageSends: ["ifTrue:", "notEmpty"],
  4977. referencedClasses: []
  4978. }),
  4979. smalltalk.Collection);
  4980. smalltalk.addMethod(
  4981. unescape('_ifEmpty_'),
  4982. smalltalk.method({
  4983. selector: unescape('ifEmpty%3A'),
  4984. category: 'testing',
  4985. fn: function (aBlock){
  4986. var self=this;
  4987. smalltalk.send(smalltalk.send(self, "_isEmpty", []), "_ifTrue_", [aBlock]);
  4988. return self;},
  4989. args: ["aBlock"],
  4990. source: unescape('ifEmpty%3A%20aBlock%0A%09self%20isEmpty%20ifTrue%3A%20aBlock.'),
  4991. messageSends: ["ifTrue:", "isEmpty"],
  4992. referencedClasses: []
  4993. }),
  4994. smalltalk.Collection);
  4995. smalltalk.addMethod(
  4996. unescape('_copyWithoutAll_'),
  4997. smalltalk.method({
  4998. selector: unescape('copyWithoutAll%3A'),
  4999. category: 'copying',
  5000. fn: function (aCollection){
  5001. var self=this;
  5002. return smalltalk.send(self, "_reject_", [(function(each){return smalltalk.send(aCollection, "_includes_", [each]);})]);
  5003. return self;},
  5004. args: ["aCollection"],
  5005. source: unescape('copyWithoutAll%3A%20aCollection%0A%09%22Answer%20a%20copy%20of%20the%20receiver%20that%20does%20not%20contain%20any%20elements%20%0A%09equal%20to%20those%20in%20aCollection.%22%0A%0A%09%5E%20self%20reject%3A%20%5B%3Aeach%20%7C%20aCollection%20includes%3A%20each%5D'),
  5006. messageSends: ["reject:", "includes:"],
  5007. referencedClasses: []
  5008. }),
  5009. smalltalk.Collection);
  5010. smalltalk.addMethod(
  5011. unescape('_streamClass'),
  5012. smalltalk.method({
  5013. selector: unescape('streamClass'),
  5014. category: 'accessing',
  5015. fn: function (){
  5016. var self=this;
  5017. return (smalltalk.Stream || Stream);
  5018. return self;},
  5019. args: [],
  5020. source: unescape('streamClass%0A%09%20%20%20%20%5EStream'),
  5021. messageSends: [],
  5022. referencedClasses: ["Stream"]
  5023. }),
  5024. smalltalk.Collection.klass);
  5025. smalltalk.addMethod(
  5026. unescape('_with_'),
  5027. smalltalk.method({
  5028. selector: unescape('with%3A'),
  5029. category: 'instance creation',
  5030. fn: function (anObject){
  5031. var self=this;
  5032. return (function($rec){smalltalk.send($rec, "_add_", [anObject]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  5033. return self;},
  5034. args: ["anObject"],
  5035. source: unescape('with%3A%20anObject%0A%09%20%20%20%20%5Eself%20new%0A%09%09add%3A%20anObject%3B%0A%09%09yourself'),
  5036. messageSends: ["add:", "yourself", "new"],
  5037. referencedClasses: []
  5038. }),
  5039. smalltalk.Collection.klass);
  5040. smalltalk.addMethod(
  5041. unescape('_with_with_'),
  5042. smalltalk.method({
  5043. selector: unescape('with%3Awith%3A'),
  5044. category: 'instance creation',
  5045. fn: function (anObject, anotherObject){
  5046. var self=this;
  5047. return (function($rec){smalltalk.send($rec, "_add_", [anObject]);smalltalk.send($rec, "_add_", [anotherObject]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  5048. return self;},
  5049. args: ["anObject", "anotherObject"],
  5050. source: unescape('with%3A%20anObject%20with%3A%20anotherObject%0A%09%20%20%20%20%5Eself%20new%0A%09%09add%3A%20anObject%3B%0A%09%09add%3A%20anotherObject%3B%0A%09%09yourself'),
  5051. messageSends: ["add:", "yourself", "new"],
  5052. referencedClasses: []
  5053. }),
  5054. smalltalk.Collection.klass);
  5055. smalltalk.addMethod(
  5056. unescape('_with_with_with_'),
  5057. smalltalk.method({
  5058. selector: unescape('with%3Awith%3Awith%3A'),
  5059. category: 'instance creation',
  5060. fn: function (firstObject, secondObject, thirdObject){
  5061. var self=this;
  5062. return (function($rec){smalltalk.send($rec, "_add_", [firstObject]);smalltalk.send($rec, "_add_", [secondObject]);smalltalk.send($rec, "_add_", [thirdObject]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  5063. return self;},
  5064. args: ["firstObject", "secondObject", "thirdObject"],
  5065. source: unescape('with%3A%20firstObject%20with%3A%20secondObject%20with%3A%20thirdObject%0A%09%20%20%20%20%5Eself%20new%0A%09%09add%3A%20firstObject%3B%0A%09%09add%3A%20secondObject%3B%0A%09%09add%3A%20thirdObject%3B%0A%09%09yourself'),
  5066. messageSends: ["add:", "yourself", "new"],
  5067. referencedClasses: []
  5068. }),
  5069. smalltalk.Collection.klass);
  5070. smalltalk.addMethod(
  5071. unescape('_withAll_'),
  5072. smalltalk.method({
  5073. selector: unescape('withAll%3A'),
  5074. category: 'instance creation',
  5075. fn: function (aCollection){
  5076. var self=this;
  5077. return (function($rec){smalltalk.send($rec, "_addAll_", [aCollection]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  5078. return self;},
  5079. args: ["aCollection"],
  5080. source: unescape('withAll%3A%20aCollection%0A%09%20%20%20%20%5Eself%20new%0A%09%09addAll%3A%20aCollection%3B%0A%09%09yourself'),
  5081. messageSends: ["addAll:", "yourself", "new"],
  5082. referencedClasses: []
  5083. }),
  5084. smalltalk.Collection.klass);
  5085. smalltalk.addClass('SequenceableCollection', smalltalk.Collection, [], 'Kernel');
  5086. smalltalk.addMethod(
  5087. unescape('_at_'),
  5088. smalltalk.method({
  5089. selector: unescape('at%3A'),
  5090. category: 'accessing',
  5091. fn: function (anIndex){
  5092. var self=this;
  5093. return smalltalk.send(self, "_at_ifAbsent_", [anIndex, (function(){return smalltalk.send(self, "_errorNotFound", []);})]);
  5094. return self;},
  5095. args: ["anIndex"],
  5096. source: unescape('at%3A%20anIndex%0A%09%5Eself%20at%3A%20anIndex%20ifAbsent%3A%20%5B%0A%09%20%20%20%20self%20errorNotFound%5D'),
  5097. messageSends: ["at:ifAbsent:", "errorNotFound"],
  5098. referencedClasses: []
  5099. }),
  5100. smalltalk.SequenceableCollection);
  5101. smalltalk.addMethod(
  5102. unescape('_at_ifAbsent_'),
  5103. smalltalk.method({
  5104. selector: unescape('at%3AifAbsent%3A'),
  5105. category: 'accessing',
  5106. fn: function (anIndex, aBlock){
  5107. var self=this;
  5108. smalltalk.send(self, "_subclassResponsibility", []);
  5109. return self;},
  5110. args: ["anIndex", "aBlock"],
  5111. source: unescape('at%3A%20anIndex%20ifAbsent%3A%20aBlock%0A%09self%20subclassResponsibility'),
  5112. messageSends: ["subclassResponsibility"],
  5113. referencedClasses: []
  5114. }),
  5115. smalltalk.SequenceableCollection);
  5116. smalltalk.addMethod(
  5117. unescape('_at_put_'),
  5118. smalltalk.method({
  5119. selector: unescape('at%3Aput%3A'),
  5120. category: 'accessing',
  5121. fn: function (anIndex, anObject){
  5122. var self=this;
  5123. smalltalk.send(self, "_subclassResponsibility", []);
  5124. return self;},
  5125. args: ["anIndex", "anObject"],
  5126. source: unescape('at%3A%20anIndex%20put%3A%20anObject%0A%09self%20subclassResponsibility'),
  5127. messageSends: ["subclassResponsibility"],
  5128. referencedClasses: []
  5129. }),
  5130. smalltalk.SequenceableCollection);
  5131. smalltalk.addMethod(
  5132. unescape('_copyFrom_to_'),
  5133. smalltalk.method({
  5134. selector: unescape('copyFrom%3Ato%3A'),
  5135. category: 'copying',
  5136. fn: function (anIndex, anotherIndex){
  5137. var self=this;
  5138. smalltalk.send(self, "_subclassResponsibility", []);
  5139. return self;},
  5140. args: ["anIndex", "anotherIndex"],
  5141. source: unescape('copyFrom%3A%20anIndex%20to%3A%20anotherIndex%0A%09self%20subclassResponsibility'),
  5142. messageSends: ["subclassResponsibility"],
  5143. referencedClasses: []
  5144. }),
  5145. smalltalk.SequenceableCollection);
  5146. smalltalk.addMethod(
  5147. unescape('_first'),
  5148. smalltalk.method({
  5149. selector: unescape('first'),
  5150. category: 'accessing',
  5151. fn: function (){
  5152. var self=this;
  5153. return smalltalk.send(self, "_at_", [(1)]);
  5154. return self;},
  5155. args: [],
  5156. source: unescape('first%0A%09%5Eself%20at%3A%201'),
  5157. messageSends: ["at:"],
  5158. referencedClasses: []
  5159. }),
  5160. smalltalk.SequenceableCollection);
  5161. smalltalk.addMethod(
  5162. unescape('_fourth'),
  5163. smalltalk.method({
  5164. selector: unescape('fourth'),
  5165. category: 'accessing',
  5166. fn: function (){
  5167. var self=this;
  5168. return smalltalk.send(self, "_at_", [(4)]);
  5169. return self;},
  5170. args: [],
  5171. source: unescape('fourth%0A%09%5Eself%20at%3A%204'),
  5172. messageSends: ["at:"],
  5173. referencedClasses: []
  5174. }),
  5175. smalltalk.SequenceableCollection);
  5176. smalltalk.addMethod(
  5177. unescape('_last'),
  5178. smalltalk.method({
  5179. selector: unescape('last'),
  5180. category: 'accessing',
  5181. fn: function (){
  5182. var self=this;
  5183. return smalltalk.send(self, "_at_", [smalltalk.send(self, "_size", [])]);
  5184. return self;},
  5185. args: [],
  5186. source: unescape('last%0A%09%5Eself%20at%3A%20self%20size'),
  5187. messageSends: ["at:", "size"],
  5188. referencedClasses: []
  5189. }),
  5190. smalltalk.SequenceableCollection);
  5191. smalltalk.addMethod(
  5192. unescape('_second'),
  5193. smalltalk.method({
  5194. selector: unescape('second'),
  5195. category: 'accessing',
  5196. fn: function (){
  5197. var self=this;
  5198. return smalltalk.send(self, "_at_", [(2)]);
  5199. return self;},
  5200. args: [],
  5201. source: unescape('second%0A%09%5Eself%20at%3A%202'),
  5202. messageSends: ["at:"],
  5203. referencedClasses: []
  5204. }),
  5205. smalltalk.SequenceableCollection);
  5206. smalltalk.addMethod(
  5207. unescape('_third'),
  5208. smalltalk.method({
  5209. selector: unescape('third'),
  5210. category: 'accessing',
  5211. fn: function (){
  5212. var self=this;
  5213. return smalltalk.send(self, "_at_", [(3)]);
  5214. return self;},
  5215. args: [],
  5216. source: unescape('third%0A%09%5Eself%20at%3A%203'),
  5217. messageSends: ["at:"],
  5218. referencedClasses: []
  5219. }),
  5220. smalltalk.SequenceableCollection);
  5221. smalltalk.addMethod(
  5222. unescape('_removeLast'),
  5223. smalltalk.method({
  5224. selector: unescape('removeLast'),
  5225. category: 'adding',
  5226. fn: function (){
  5227. var self=this;
  5228. smalltalk.send(self, "_remove_", [smalltalk.send(self, "_last", [])]);
  5229. return self;},
  5230. args: [],
  5231. source: unescape('removeLast%0A%09self%20remove%3A%20self%20last'),
  5232. messageSends: ["remove:", "last"],
  5233. referencedClasses: []
  5234. }),
  5235. smalltalk.SequenceableCollection);
  5236. smalltalk.addMethod(
  5237. unescape('_addLast_'),
  5238. smalltalk.method({
  5239. selector: unescape('addLast%3A'),
  5240. category: 'adding',
  5241. fn: function (anObject){
  5242. var self=this;
  5243. smalltalk.send(self, "_add_", [anObject]);
  5244. return self;},
  5245. args: ["anObject"],
  5246. source: unescape('addLast%3A%20anObject%0A%09self%20add%3A%20anObject'),
  5247. messageSends: ["add:"],
  5248. referencedClasses: []
  5249. }),
  5250. smalltalk.SequenceableCollection);
  5251. smalltalk.addMethod(
  5252. unescape('_withIndexDo_'),
  5253. smalltalk.method({
  5254. selector: unescape('withIndexDo%3A'),
  5255. category: 'enumerating',
  5256. fn: function (aBlock){
  5257. var self=this;
  5258. for(var i=0;i<self.length;i++){aBlock(self[i], i+1);};
  5259. return self;},
  5260. args: ["aBlock"],
  5261. source: unescape('withIndexDo%3A%20aBlock%0A%09%3Cfor%28var%20i%3D0%3Bi%3Cself.length%3Bi++%29%7BaBlock%28self%5Bi%5D%2C%20i+1%29%3B%7D%3E'),
  5262. messageSends: [],
  5263. referencedClasses: []
  5264. }),
  5265. smalltalk.SequenceableCollection);
  5266. smalltalk.addMethod(
  5267. unescape('_allButFirst'),
  5268. smalltalk.method({
  5269. selector: unescape('allButFirst'),
  5270. category: 'accessing',
  5271. fn: function (){
  5272. var self=this;
  5273. return smalltalk.send(self, "_copyFrom_to_", [(2), smalltalk.send(self, "_size", [])]);
  5274. return self;},
  5275. args: [],
  5276. source: unescape('allButFirst%0A%09%5Eself%20copyFrom%3A%202%20to%3A%20self%20size'),
  5277. messageSends: ["copyFrom:to:", "size"],
  5278. referencedClasses: []
  5279. }),
  5280. smalltalk.SequenceableCollection);
  5281. smalltalk.addMethod(
  5282. unescape('_allButLast'),
  5283. smalltalk.method({
  5284. selector: unescape('allButLast'),
  5285. category: 'accessing',
  5286. fn: function (){
  5287. var self=this;
  5288. return smalltalk.send(self, "_copyFrom_to_", [(1), ((($receiver = smalltalk.send(self, "_size", [])).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)]))]);
  5289. return self;},
  5290. args: [],
  5291. source: unescape('allButLast%0A%09%5Eself%20copyFrom%3A%201%20to%3A%20self%20size%20-%201'),
  5292. messageSends: ["copyFrom:to:", unescape("-"), "size"],
  5293. referencedClasses: []
  5294. }),
  5295. smalltalk.SequenceableCollection);
  5296. smalltalk.addMethod(
  5297. unescape('_indexOf_'),
  5298. smalltalk.method({
  5299. selector: unescape('indexOf%3A'),
  5300. category: 'accessing',
  5301. fn: function (anObject){
  5302. var self=this;
  5303. return smalltalk.send(self, "_indexOf_ifAbsent_", [anObject, (function(){return smalltalk.send(self, "_errorNotFound", []);})]);
  5304. return self;},
  5305. args: ["anObject"],
  5306. source: unescape('indexOf%3A%20anObject%0A%09%5Eself%20indexOf%3A%20anObject%20ifAbsent%3A%20%5Bself%20errorNotFound%5D'),
  5307. messageSends: ["indexOf:ifAbsent:", "errorNotFound"],
  5308. referencedClasses: []
  5309. }),
  5310. smalltalk.SequenceableCollection);
  5311. smalltalk.addMethod(
  5312. unescape('_indexOf_ifAbsent_'),
  5313. smalltalk.method({
  5314. selector: unescape('indexOf%3AifAbsent%3A'),
  5315. category: 'accessing',
  5316. fn: function (anObject, aBlock){
  5317. var self=this;
  5318. for(var i=0;i<self.length;i++){
  5319. if(self[i].__eq(anObject)) {return i+1}
  5320. }
  5321. return aBlock();
  5322. ;
  5323. return self;},
  5324. args: ["anObject", "aBlock"],
  5325. source: unescape('indexOf%3A%20anObject%20ifAbsent%3A%20aBlock%0A%09%3C%0A%09%09for%28var%20i%3D0%3Bi%3Cself.length%3Bi++%29%7B%0A%09%09%09if%28self%5Bi%5D.__eq%28anObject%29%29%20%7Breturn%20i+1%7D%0A%09%09%7D%0A%09%09return%20aBlock%28%29%3B%0A%09%3E'),
  5326. messageSends: [],
  5327. referencedClasses: []
  5328. }),
  5329. smalltalk.SequenceableCollection);
  5330. smalltalk.addMethod(
  5331. unescape('_indexOf_startingAt_ifAbsent_'),
  5332. smalltalk.method({
  5333. selector: unescape('indexOf%3AstartingAt%3AifAbsent%3A'),
  5334. category: 'accessing',
  5335. fn: function (anObject, start, aBlock){
  5336. var self=this;
  5337. for(var i=start-1;i<self.length;i++){
  5338. if(self[i].__eq(anObject)) {return i+1}
  5339. }
  5340. return aBlock();
  5341. ;
  5342. return self;},
  5343. args: ["anObject", "start", "aBlock"],
  5344. source: unescape('indexOf%3A%20anObject%20startingAt%3A%20start%20ifAbsent%3A%20aBlock%0A%09%3C%0A%09%09for%28var%20i%3Dstart-1%3Bi%3Cself.length%3Bi++%29%7B%0A%09%09%09if%28self%5Bi%5D.__eq%28anObject%29%29%20%7Breturn%20i+1%7D%0A%09%09%7D%0A%09%09return%20aBlock%28%29%3B%0A%09%3E'),
  5345. messageSends: [],
  5346. referencedClasses: []
  5347. }),
  5348. smalltalk.SequenceableCollection);
  5349. smalltalk.addMethod(
  5350. unescape('_indexOf_startingAt_'),
  5351. smalltalk.method({
  5352. selector: unescape('indexOf%3AstartingAt%3A'),
  5353. category: 'accessing',
  5354. fn: function (anObject, start){
  5355. var self=this;
  5356. return smalltalk.send(self, "_indexOf_startingAt_ifAbsent_", [anObject, start, (function(){return (0);})]);
  5357. return self;},
  5358. args: ["anObject", "start"],
  5359. source: unescape('indexOf%3A%20anObject%20startingAt%3A%20start%0A%09%22Answer%20the%20index%20of%20the%20first%20occurence%20of%20anElement%20after%20start%0A%09within%20the%20receiver.%20If%20the%20receiver%20does%20not%20contain%20anElement%2C%20%0A%09answer%200.%22%0A%09%5Eself%20indexOf%3A%20anObject%20startingAt%3A%20start%20ifAbsent%3A%20%5B0%5D'),
  5360. messageSends: ["indexOf:startingAt:ifAbsent:"],
  5361. referencedClasses: []
  5362. }),
  5363. smalltalk.SequenceableCollection);
  5364. smalltalk.addMethod(
  5365. unescape('_reversed'),
  5366. smalltalk.method({
  5367. selector: unescape('reversed'),
  5368. category: 'converting',
  5369. fn: function (){
  5370. var self=this;
  5371. smalltalk.send(self, "_subclassResponsibility", []);
  5372. return self;},
  5373. args: [],
  5374. source: unescape('reversed%0A%09self%20subclassResponsibility'),
  5375. messageSends: ["subclassResponsibility"],
  5376. referencedClasses: []
  5377. }),
  5378. smalltalk.SequenceableCollection);
  5379. smalltalk.addMethod(
  5380. unescape('_atRandom'),
  5381. smalltalk.method({
  5382. selector: unescape('atRandom'),
  5383. category: 'accessing',
  5384. fn: function (){
  5385. var self=this;
  5386. return smalltalk.send(self, "_at_", [smalltalk.send(smalltalk.send(self, "_size", []), "_atRandom", [])]);
  5387. return self;},
  5388. args: [],
  5389. source: unescape('atRandom%0A%09%5E%20self%20at%3A%20self%20size%20atRandom'),
  5390. messageSends: ["at:", "atRandom", "size"],
  5391. referencedClasses: []
  5392. }),
  5393. smalltalk.SequenceableCollection);
  5394. smalltalk.addClass('String', smalltalk.SequenceableCollection, [], 'Kernel');
  5395. smalltalk.addMethod(
  5396. unescape('__eq'),
  5397. smalltalk.method({
  5398. selector: unescape('%3D'),
  5399. category: 'comparing',
  5400. fn: function (aString){
  5401. var self=this;
  5402. try{((($receiver = smalltalk.send(smalltalk.send(aString, "_class", []), "__eq", [smalltalk.send(self, "_class", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));
  5403. return String(self) == aString;
  5404. return self;
  5405. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq'){return e.fn()} throw(e)}},
  5406. args: ["aString"],
  5407. source: unescape('%3D%20aString%0A%09aString%20class%20%3D%20self%20class%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09%3Creturn%20String%28self%29%20%3D%3D%20aString%3E'),
  5408. messageSends: ["ifFalse:", unescape("%3D"), "class"],
  5409. referencedClasses: []
  5410. }),
  5411. smalltalk.String);
  5412. smalltalk.addMethod(
  5413. unescape('_size'),
  5414. smalltalk.method({
  5415. selector: unescape('size'),
  5416. category: 'accessing',
  5417. fn: function (){
  5418. var self=this;
  5419. return self.length;
  5420. return self;},
  5421. args: [],
  5422. source: unescape('size%0A%09%3Creturn%20self.length%3E'),
  5423. messageSends: [],
  5424. referencedClasses: []
  5425. }),
  5426. smalltalk.String);
  5427. smalltalk.addMethod(
  5428. unescape('_at_'),
  5429. smalltalk.method({
  5430. selector: unescape('at%3A'),
  5431. category: 'accessing',
  5432. fn: function (anIndex){
  5433. var self=this;
  5434. return self[anIndex - 1];
  5435. return self;},
  5436. args: ["anIndex"],
  5437. source: unescape('at%3A%20anIndex%0A%09%3Creturn%20self%5BanIndex%20-%201%5D%3E'),
  5438. messageSends: [],
  5439. referencedClasses: []
  5440. }),
  5441. smalltalk.String);
  5442. smalltalk.addMethod(
  5443. unescape('_at_put_'),
  5444. smalltalk.method({
  5445. selector: unescape('at%3Aput%3A'),
  5446. category: 'accessing',
  5447. fn: function (anIndex, anObject){
  5448. var self=this;
  5449. smalltalk.send(self, "_errorReadOnly", []);
  5450. return self;},
  5451. args: ["anIndex", "anObject"],
  5452. source: unescape('at%3A%20anIndex%20put%3A%20anObject%0A%20%20%20%20%09self%20errorReadOnly'),
  5453. messageSends: ["errorReadOnly"],
  5454. referencedClasses: []
  5455. }),
  5456. smalltalk.String);
  5457. smalltalk.addMethod(
  5458. unescape('_at_ifAbsent_'),
  5459. smalltalk.method({
  5460. selector: unescape('at%3AifAbsent%3A'),
  5461. category: 'accessing',
  5462. fn: function (anIndex, aBlock){
  5463. var self=this;
  5464. (($receiver = smalltalk.send(self, "_at_", [anIndex])) == nil || $receiver == undefined) ? (function(){return aBlock;})() : $receiver;
  5465. return self;},
  5466. args: ["anIndex", "aBlock"],
  5467. source: unescape('at%3A%20anIndex%20ifAbsent%3A%20aBlock%0A%20%20%20%20%09%28self%20at%3A%20anIndex%29%20ifNil%3A%20%5BaBlock%5D'),
  5468. messageSends: ["ifNil:", "at:"],
  5469. referencedClasses: []
  5470. }),
  5471. smalltalk.String);
  5472. smalltalk.addMethod(
  5473. unescape('_escaped'),
  5474. smalltalk.method({
  5475. selector: unescape('escaped'),
  5476. category: 'accessing',
  5477. fn: function (){
  5478. var self=this;
  5479. return escape(self);
  5480. return self;},
  5481. args: [],
  5482. source: unescape('escaped%0A%09%3Creturn%20escape%28self%29%3E'),
  5483. messageSends: [],
  5484. referencedClasses: []
  5485. }),
  5486. smalltalk.String);
  5487. smalltalk.addMethod(
  5488. unescape('_unescaped'),
  5489. smalltalk.method({
  5490. selector: unescape('unescaped'),
  5491. category: 'accessing',
  5492. fn: function (){
  5493. var self=this;
  5494. return unescape(self);
  5495. return self;},
  5496. args: [],
  5497. source: unescape('unescaped%0A%09%3Creturn%20unescape%28self%29%3E'),
  5498. messageSends: [],
  5499. referencedClasses: []
  5500. }),
  5501. smalltalk.String);
  5502. smalltalk.addMethod(
  5503. unescape('_add_'),
  5504. smalltalk.method({
  5505. selector: unescape('add%3A'),
  5506. category: 'adding',
  5507. fn: function (anObject){
  5508. var self=this;
  5509. smalltalk.send(self, "_errorReadOnly", []);
  5510. return self;},
  5511. args: ["anObject"],
  5512. source: unescape('add%3A%20anObject%0A%20%20%20%20%09self%20errorReadOnly'),
  5513. messageSends: ["errorReadOnly"],
  5514. referencedClasses: []
  5515. }),
  5516. smalltalk.String);
  5517. smalltalk.addMethod(
  5518. unescape('__comma'),
  5519. smalltalk.method({
  5520. selector: unescape('%2C'),
  5521. category: 'copying',
  5522. fn: function (aString){
  5523. var self=this;
  5524. return self + aString;
  5525. return self;},
  5526. args: ["aString"],
  5527. source: unescape('%2C%20aString%0A%09%3Creturn%20self%20+%20aString%3E'),
  5528. messageSends: [],
  5529. referencedClasses: []
  5530. }),
  5531. smalltalk.String);
  5532. smalltalk.addMethod(
  5533. unescape('_copyFrom_to_'),
  5534. smalltalk.method({
  5535. selector: unescape('copyFrom%3Ato%3A'),
  5536. category: 'copying',
  5537. fn: function (anIndex, anotherIndex){
  5538. var self=this;
  5539. return self.substring(anIndex - 1, anotherIndex);
  5540. return self;},
  5541. args: ["anIndex", "anotherIndex"],
  5542. source: unescape('copyFrom%3A%20anIndex%20to%3A%20anotherIndex%0A%09%3Creturn%20self.substring%28anIndex%20-%201%2C%20anotherIndex%29%3E'),
  5543. messageSends: [],
  5544. referencedClasses: []
  5545. }),
  5546. smalltalk.String);
  5547. smalltalk.addMethod(
  5548. unescape('_shallowCopy'),
  5549. smalltalk.method({
  5550. selector: unescape('shallowCopy'),
  5551. category: 'copying',
  5552. fn: function (){
  5553. var self=this;
  5554. return smalltalk.send(smalltalk.send(self, "_class", []), "_fromString_", [self]);
  5555. return self;},
  5556. args: [],
  5557. source: unescape('shallowCopy%0A%20%20%20%20%09%5Eself%20class%20fromString%3A%20self'),
  5558. messageSends: ["fromString:", "class"],
  5559. referencedClasses: []
  5560. }),
  5561. smalltalk.String);
  5562. smalltalk.addMethod(
  5563. unescape('_deepCopy'),
  5564. smalltalk.method({
  5565. selector: unescape('deepCopy'),
  5566. category: 'copying',
  5567. fn: function (){
  5568. var self=this;
  5569. return smalltalk.send(self, "_shallowCopy", []);
  5570. return self;},
  5571. args: [],
  5572. source: unescape('deepCopy%0A%20%20%20%20%09%5Eself%20shallowCopy'),
  5573. messageSends: ["shallowCopy"],
  5574. referencedClasses: []
  5575. }),
  5576. smalltalk.String);
  5577. smalltalk.addMethod(
  5578. unescape('_asSelector'),
  5579. smalltalk.method({
  5580. selector: unescape('asSelector'),
  5581. category: 'converting',
  5582. fn: function (){
  5583. var self=this;
  5584. var selector=nil;
  5585. selector=smalltalk.send("_", "__comma", [self]);
  5586. selector=smalltalk.send(selector, "_replace_with_", [":", "_"]);
  5587. selector=smalltalk.send(selector, "_replace_with_", [unescape("%5B+%5D"), "_plus"]);
  5588. selector=smalltalk.send(selector, "_replace_with_", [unescape("-"), "_minus"]);
  5589. selector=smalltalk.send(selector, "_replace_with_", [unescape("%5B*%5D"), "_star"]);
  5590. selector=smalltalk.send(selector, "_replace_with_", [unescape("%5B/%5D"), "_slash"]);
  5591. selector=smalltalk.send(selector, "_replace_with_", [unescape("%3E"), "_gt"]);
  5592. selector=smalltalk.send(selector, "_replace_with_", [unescape("%3C"), "_lt"]);
  5593. selector=smalltalk.send(selector, "_replace_with_", [unescape("%3D"), "_eq"]);
  5594. selector=smalltalk.send(selector, "_replace_with_", [unescape("%2C"), "_comma"]);
  5595. selector=smalltalk.send(selector, "_replace_with_", [unescape("%5B@%5D"), "_at"]);
  5596. return selector;
  5597. return self;},
  5598. args: [],
  5599. source: unescape('asSelector%0A%09%22If%20you%20change%20this%20method%2C%20change%20smalltalk.convertSelector%20too%20%28see%20js/boot.js%20file%29%22%0A%0A%09%7C%20selector%20%7C%0A%09selector%20%3A%3D%20%27_%27%2C%20self.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%3A%27%20with%3A%20%27_%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%5B+%5D%27%20with%3A%20%27_plus%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27-%27%20with%3A%20%27_minus%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%5B*%5D%27%20with%3A%20%27_star%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%5B/%5D%27%20with%3A%20%27_slash%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%3E%27%20with%3A%20%27_gt%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%3C%27%20with%3A%20%27_lt%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%3D%27%20with%3A%20%27_eq%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%2C%27%20with%3A%20%27_comma%27.%0A%20%20%20%20%09selector%20%3A%3D%20selector%20replace%3A%20%27%5B@%5D%27%20with%3A%20%27_at%27.%0A%09%5Eselector'),
  5600. messageSends: [unescape("%2C"), "replace:with:"],
  5601. referencedClasses: []
  5602. }),
  5603. smalltalk.String);
  5604. smalltalk.addMethod(
  5605. unescape('_asJavascript'),
  5606. smalltalk.method({
  5607. selector: unescape('asJavascript'),
  5608. category: 'converting',
  5609. fn: function (){
  5610. var self=this;
  5611. if(self.search(/^[a-zA-Z0-9_:.$ ]*$/) == -1)
  5612. return "unescape(\"" + escape(self) + "\")";
  5613. else
  5614. return "\"" + self + "\"";
  5615. ;
  5616. return self;},
  5617. args: [],
  5618. source: unescape('asJavascript%0A%09%3C%0A%09%09if%28self.search%28/%5E%5Ba-zA-Z0-9_%3A.%24%20%5D*%24/%29%20%3D%3D%20-1%29%0A%09%09%09return%20%22unescape%28%5C%22%22%20+%20escape%28self%29%20+%20%22%5C%22%29%22%3B%0A%09%09else%0A%09%09%09return%20%22%5C%22%22%20+%20self%20+%20%22%5C%22%22%3B%0A%09%3E'),
  5619. messageSends: [],
  5620. referencedClasses: []
  5621. }),
  5622. smalltalk.String);
  5623. smalltalk.addMethod(
  5624. unescape('_replace_with_'),
  5625. smalltalk.method({
  5626. selector: unescape('replace%3Awith%3A'),
  5627. category: 'regular expressions',
  5628. fn: function (aString, anotherString){
  5629. var self=this;
  5630. return smalltalk.send(self, "_replaceRegexp_with_", [smalltalk.send((smalltalk.RegularExpression || RegularExpression), "_fromString_flag_", [aString, "g"]), anotherString]);
  5631. return self;},
  5632. args: ["aString", "anotherString"],
  5633. source: unescape('replace%3A%20aString%20with%3A%20anotherString%0A%20%20%20%20%09%5Eself%20replaceRegexp%3A%20%28RegularExpression%20fromString%3A%20aString%20flag%3A%20%27g%27%29%20with%3A%20anotherString'),
  5634. messageSends: ["replaceRegexp:with:", "fromString:flag:"],
  5635. referencedClasses: ["RegularExpression"]
  5636. }),
  5637. smalltalk.String);
  5638. smalltalk.addMethod(
  5639. unescape('_replaceRegexp_with_'),
  5640. smalltalk.method({
  5641. selector: unescape('replaceRegexp%3Awith%3A'),
  5642. category: 'regular expressions',
  5643. fn: function (aRegexp, aString){
  5644. var self=this;
  5645. return self.replace(aRegexp, aString);
  5646. return self;},
  5647. args: ["aRegexp", "aString"],
  5648. source: unescape('replaceRegexp%3A%20aRegexp%20with%3A%20aString%0A%09%3Creturn%20self.replace%28aRegexp%2C%20aString%29%3E'),
  5649. messageSends: [],
  5650. referencedClasses: []
  5651. }),
  5652. smalltalk.String);
  5653. smalltalk.addMethod(
  5654. unescape('_tokenize_'),
  5655. smalltalk.method({
  5656. selector: unescape('tokenize%3A'),
  5657. category: 'converting',
  5658. fn: function (aString){
  5659. var self=this;
  5660. return self.split(aString);
  5661. return self;},
  5662. args: ["aString"],
  5663. source: unescape('tokenize%3A%20aString%0A%09%3Creturn%20self.split%28aString%29%3E'),
  5664. messageSends: [],
  5665. referencedClasses: []
  5666. }),
  5667. smalltalk.String);
  5668. smalltalk.addMethod(
  5669. unescape('_match_'),
  5670. smalltalk.method({
  5671. selector: unescape('match%3A'),
  5672. category: 'regular expressions',
  5673. fn: function (aRegexp){
  5674. var self=this;
  5675. return self.search(aRegexp) != -1;
  5676. return self;},
  5677. args: ["aRegexp"],
  5678. source: unescape('match%3A%20aRegexp%0A%09%3Creturn%20self.search%28aRegexp%29%20%21%3D%20-1%3E'),
  5679. messageSends: [],
  5680. referencedClasses: []
  5681. }),
  5682. smalltalk.String);
  5683. smalltalk.addMethod(
  5684. unescape('_asString'),
  5685. smalltalk.method({
  5686. selector: unescape('asString'),
  5687. category: 'converting',
  5688. fn: function (){
  5689. var self=this;
  5690. return self;
  5691. return self;},
  5692. args: [],
  5693. source: unescape('asString%0A%20%20%20%20%09%5Eself'),
  5694. messageSends: [],
  5695. referencedClasses: []
  5696. }),
  5697. smalltalk.String);
  5698. smalltalk.addMethod(
  5699. unescape('_asNumber'),
  5700. smalltalk.method({
  5701. selector: unescape('asNumber'),
  5702. category: 'converting',
  5703. fn: function (){
  5704. var self=this;
  5705. return Number(self);
  5706. return self;},
  5707. args: [],
  5708. source: unescape('asNumber%0A%09%3Creturn%20Number%28self%29%3E'),
  5709. messageSends: [],
  5710. referencedClasses: []
  5711. }),
  5712. smalltalk.String);
  5713. smalltalk.addMethod(
  5714. unescape('_errorReadOnly'),
  5715. smalltalk.method({
  5716. selector: unescape('errorReadOnly'),
  5717. category: 'error handling',
  5718. fn: function (){
  5719. var self=this;
  5720. smalltalk.send(self, "_error_", [unescape("Object%20is%20read-only")]);
  5721. return self;},
  5722. args: [],
  5723. source: unescape('errorReadOnly%0A%20%20%20%20%09self%20error%3A%20%27Object%20is%20read-only%27'),
  5724. messageSends: ["error:"],
  5725. referencedClasses: []
  5726. }),
  5727. smalltalk.String);
  5728. smalltalk.addMethod(
  5729. unescape('_printString'),
  5730. smalltalk.method({
  5731. selector: unescape('printString'),
  5732. category: 'printing',
  5733. fn: function (){
  5734. var self=this;
  5735. return smalltalk.send(smalltalk.send(unescape("%27"), "__comma", [self]), "__comma", [unescape("%27")]);
  5736. return self;},
  5737. args: [],
  5738. source: unescape('printString%0A%20%20%20%20%09%5E%27%27%27%27%2C%20self%2C%20%27%27%27%27'),
  5739. messageSends: [unescape("%2C")],
  5740. referencedClasses: []
  5741. }),
  5742. smalltalk.String);
  5743. smalltalk.addMethod(
  5744. unescape('_printNl'),
  5745. smalltalk.method({
  5746. selector: unescape('printNl'),
  5747. category: 'printing',
  5748. fn: function (){
  5749. var self=this;
  5750. console.log(self);
  5751. return self;},
  5752. args: [],
  5753. source: unescape('printNl%0A%09%3Cconsole.log%28self%29%3E'),
  5754. messageSends: [],
  5755. referencedClasses: []
  5756. }),
  5757. smalltalk.String);
  5758. smalltalk.addMethod(
  5759. unescape('_isString'),
  5760. smalltalk.method({
  5761. selector: unescape('isString'),
  5762. category: 'testing',
  5763. fn: function (){
  5764. var self=this;
  5765. return true;
  5766. return self;},
  5767. args: [],
  5768. source: unescape('isString%0A%20%20%20%20%09%5Etrue'),
  5769. messageSends: [],
  5770. referencedClasses: []
  5771. }),
  5772. smalltalk.String);
  5773. smalltalk.addMethod(
  5774. unescape('__gt'),
  5775. smalltalk.method({
  5776. selector: unescape('%3E'),
  5777. category: 'comparing',
  5778. fn: function (aString){
  5779. var self=this;
  5780. return String(self) > aString;
  5781. return self;},
  5782. args: ["aString"],
  5783. source: unescape('%3E%20aString%0A%09%3Creturn%20String%28self%29%20%3E%3E%20aString%3E'),
  5784. messageSends: [],
  5785. referencedClasses: []
  5786. }),
  5787. smalltalk.String);
  5788. smalltalk.addMethod(
  5789. unescape('__lt'),
  5790. smalltalk.method({
  5791. selector: unescape('%3C'),
  5792. category: 'comparing',
  5793. fn: function (aString){
  5794. var self=this;
  5795. return String(self) < aString;
  5796. return self;},
  5797. args: ["aString"],
  5798. source: unescape('%3C%20aString%0A%09%3Creturn%20String%28self%29%20%3C%20aString%3E'),
  5799. messageSends: [],
  5800. referencedClasses: []
  5801. }),
  5802. smalltalk.String);
  5803. smalltalk.addMethod(
  5804. unescape('__gt_eq'),
  5805. smalltalk.method({
  5806. selector: unescape('%3E%3D'),
  5807. category: 'comparing',
  5808. fn: function (aString){
  5809. var self=this;
  5810. return String(self) >= aString;
  5811. return self;},
  5812. args: ["aString"],
  5813. source: unescape('%3E%3D%20aString%0A%09%3Creturn%20String%28self%29%20%3E%3E%3D%20aString%3E'),
  5814. messageSends: [],
  5815. referencedClasses: []
  5816. }),
  5817. smalltalk.String);
  5818. smalltalk.addMethod(
  5819. unescape('__lt_eq'),
  5820. smalltalk.method({
  5821. selector: unescape('%3C%3D'),
  5822. category: 'comparing',
  5823. fn: function (aString){
  5824. var self=this;
  5825. return String(self) <= aString;
  5826. return self;},
  5827. args: ["aString"],
  5828. source: unescape('%3C%3D%20aString%0A%09%3Creturn%20String%28self%29%20%3C%3D%20aString%3E'),
  5829. messageSends: [],
  5830. referencedClasses: []
  5831. }),
  5832. smalltalk.String);
  5833. smalltalk.addMethod(
  5834. unescape('_remove_'),
  5835. smalltalk.method({
  5836. selector: unescape('remove%3A'),
  5837. category: 'adding',
  5838. fn: function (anObject){
  5839. var self=this;
  5840. smalltalk.send(self, "_errorReadOnly", []);
  5841. return self;},
  5842. args: ["anObject"],
  5843. source: unescape('remove%3A%20anObject%0A%09self%20errorReadOnly'),
  5844. messageSends: ["errorReadOnly"],
  5845. referencedClasses: []
  5846. }),
  5847. smalltalk.String);
  5848. smalltalk.addMethod(
  5849. unescape('_asJSONObject'),
  5850. smalltalk.method({
  5851. selector: unescape('asJSONObject'),
  5852. category: 'converting',
  5853. fn: function (){
  5854. var self=this;
  5855. return self;
  5856. return self;},
  5857. args: [],
  5858. source: unescape('asJSONObject%0A%09%5Eself'),
  5859. messageSends: [],
  5860. referencedClasses: []
  5861. }),
  5862. smalltalk.String);
  5863. smalltalk.addMethod(
  5864. unescape('_trimLeft_'),
  5865. smalltalk.method({
  5866. selector: unescape('trimLeft%3A'),
  5867. category: 'regular expressions',
  5868. fn: function (separators){
  5869. var self=this;
  5870. return smalltalk.send(self, "_replaceRegexp_with_", [smalltalk.send((smalltalk.RegularExpression || RegularExpression), "_fromString_flag_", [smalltalk.send(smalltalk.send(unescape("%5E%5B"), "__comma", [separators]), "__comma", [unescape("%5D+")]), "g"]), ""]);
  5871. return self;},
  5872. args: ["separators"],
  5873. source: unescape('trimLeft%3A%20separators%0A%0A%20%20%20%20%09%5Eself%20replaceRegexp%3A%20%28RegularExpression%20fromString%3A%20%27%5E%5B%27%2C%20separators%2C%20%27%5D+%27%20flag%3A%20%27g%27%29%20with%3A%20%27%27'),
  5874. messageSends: ["replaceRegexp:with:", "fromString:flag:", unescape("%2C")],
  5875. referencedClasses: ["RegularExpression"]
  5876. }),
  5877. smalltalk.String);
  5878. smalltalk.addMethod(
  5879. unescape('_trimRight_'),
  5880. smalltalk.method({
  5881. selector: unescape('trimRight%3A'),
  5882. category: 'regular expressions',
  5883. fn: function (separators){
  5884. var self=this;
  5885. return smalltalk.send(self, "_replaceRegexp_with_", [smalltalk.send((smalltalk.RegularExpression || RegularExpression), "_fromString_flag_", [smalltalk.send(smalltalk.send(unescape("%5B"), "__comma", [separators]), "__comma", [unescape("%5D+%24")]), "g"]), ""]);
  5886. return self;},
  5887. args: ["separators"],
  5888. source: unescape('trimRight%3A%20separators%0A%0A%20%20%20%20%09%5Eself%20replaceRegexp%3A%20%28RegularExpression%20fromString%3A%20%27%5B%27%2C%20separators%2C%20%27%5D+%24%27%20flag%3A%20%27g%27%29%20with%3A%20%27%27'),
  5889. messageSends: ["replaceRegexp:with:", "fromString:flag:", unescape("%2C")],
  5890. referencedClasses: ["RegularExpression"]
  5891. }),
  5892. smalltalk.String);
  5893. smalltalk.addMethod(
  5894. unescape('_trimLeft'),
  5895. smalltalk.method({
  5896. selector: unescape('trimLeft'),
  5897. category: 'regular expressions',
  5898. fn: function (){
  5899. var self=this;
  5900. return smalltalk.send(self, "_trimLeft_", [unescape("%5Cs")]);
  5901. return self;},
  5902. args: [],
  5903. source: unescape('trimLeft%0A%09%5Eself%20trimLeft%3A%20%27%5Cs%27'),
  5904. messageSends: ["trimLeft:"],
  5905. referencedClasses: []
  5906. }),
  5907. smalltalk.String);
  5908. smalltalk.addMethod(
  5909. unescape('_trimRight'),
  5910. smalltalk.method({
  5911. selector: unescape('trimRight'),
  5912. category: 'regular expressions',
  5913. fn: function (){
  5914. var self=this;
  5915. return smalltalk.send(self, "_trimRight_", [unescape("%5Cs")]);
  5916. return self;},
  5917. args: [],
  5918. source: unescape('trimRight%0A%09%5Eself%20trimRight%3A%20%27%5Cs%27'),
  5919. messageSends: ["trimRight:"],
  5920. referencedClasses: []
  5921. }),
  5922. smalltalk.String);
  5923. smalltalk.addMethod(
  5924. unescape('_trimBoth'),
  5925. smalltalk.method({
  5926. selector: unescape('trimBoth'),
  5927. category: 'regular expressions',
  5928. fn: function (){
  5929. var self=this;
  5930. return smalltalk.send(self, "_trimBoth_", [unescape("%5Cs")]);
  5931. return self;},
  5932. args: [],
  5933. source: unescape('trimBoth%0A%09%5Eself%20trimBoth%3A%20%27%5Cs%27'),
  5934. messageSends: ["trimBoth:"],
  5935. referencedClasses: []
  5936. }),
  5937. smalltalk.String);
  5938. smalltalk.addMethod(
  5939. unescape('_trimBoth_'),
  5940. smalltalk.method({
  5941. selector: unescape('trimBoth%3A'),
  5942. category: 'regular expressions',
  5943. fn: function (separators){
  5944. var self=this;
  5945. return smalltalk.send(smalltalk.send(self, "_trimLeft_", [separators]), "_trimRight_", [separators]);
  5946. return self;},
  5947. args: ["separators"],
  5948. source: unescape('trimBoth%3A%20separators%0A%0A%20%20%20%20%09%5E%28self%20trimLeft%3A%20separators%29%20trimRight%3A%20separators'),
  5949. messageSends: ["trimRight:", "trimLeft:"],
  5950. referencedClasses: []
  5951. }),
  5952. smalltalk.String);
  5953. smalltalk.addMethod(
  5954. unescape('_asLowercase'),
  5955. smalltalk.method({
  5956. selector: unescape('asLowercase'),
  5957. category: 'converting',
  5958. fn: function (){
  5959. var self=this;
  5960. return self.toLowerCase();
  5961. return self;},
  5962. args: [],
  5963. source: unescape('asLowercase%0A%09%3Creturn%20self.toLowerCase%28%29%3E'),
  5964. messageSends: [],
  5965. referencedClasses: []
  5966. }),
  5967. smalltalk.String);
  5968. smalltalk.addMethod(
  5969. unescape('_asUppercase'),
  5970. smalltalk.method({
  5971. selector: unescape('asUppercase'),
  5972. category: 'converting',
  5973. fn: function (){
  5974. var self=this;
  5975. return self.toUpperCase();
  5976. return self;},
  5977. args: [],
  5978. source: unescape('asUppercase%0A%09%3Creturn%20self.toUpperCase%28%29%3E'),
  5979. messageSends: [],
  5980. referencedClasses: []
  5981. }),
  5982. smalltalk.String);
  5983. smalltalk.addMethod(
  5984. unescape('_join_'),
  5985. smalltalk.method({
  5986. selector: unescape('join%3A'),
  5987. category: 'split join',
  5988. fn: function (aCollection){
  5989. var self=this;
  5990. return smalltalk.send((smalltalk.String || String), "_streamContents_", [(function(stream){return smalltalk.send(aCollection, "_do_separatedBy_", [(function(each){return smalltalk.send(stream, "_nextPutAll_", [smalltalk.send(each, "_asString", [])]);}), (function(){return smalltalk.send(stream, "_nextPutAll_", [self]);})]);})]);
  5991. return self;},
  5992. args: ["aCollection"],
  5993. source: unescape('join%3A%20aCollection%20%0A%09%5E%20String%0A%09%09streamContents%3A%20%5B%3Astream%20%7C%20aCollection%0A%09%09%09%09do%3A%20%5B%3Aeach%20%7C%20stream%20nextPutAll%3A%20each%20asString%5D%20%0A%09%09%09%09separatedBy%3A%20%5Bstream%20nextPutAll%3A%20self%5D%5D'),
  5994. messageSends: ["streamContents:", "do:separatedBy:", "nextPutAll:", "asString"],
  5995. referencedClasses: ["String"]
  5996. }),
  5997. smalltalk.String);
  5998. smalltalk.addMethod(
  5999. unescape('_includesSubString_'),
  6000. smalltalk.method({
  6001. selector: unescape('includesSubString%3A'),
  6002. category: 'testing',
  6003. fn: function (subString){
  6004. var self=this;
  6005. return self.indexOf(subString) != -1 ;
  6006. return self;},
  6007. args: ["subString"],
  6008. source: unescape('includesSubString%3A%20subString%0A%09%3C%20return%20self.indexOf%28subString%29%20%21%3D%20-1%20%3E'),
  6009. messageSends: [],
  6010. referencedClasses: []
  6011. }),
  6012. smalltalk.String);
  6013. smalltalk.addMethod(
  6014. unescape('_asciiValue'),
  6015. smalltalk.method({
  6016. selector: unescape('asciiValue'),
  6017. category: 'accessing',
  6018. fn: function (){
  6019. var self=this;
  6020. return self.charCodeAt(0);;
  6021. return self;},
  6022. args: [],
  6023. source: unescape('asciiValue%0A%09%3Creturn%20self.charCodeAt%280%29%3B%3E'),
  6024. messageSends: [],
  6025. referencedClasses: []
  6026. }),
  6027. smalltalk.String);
  6028. smalltalk.addMethod(
  6029. unescape('_lineIndicesDo_'),
  6030. smalltalk.method({
  6031. selector: unescape('lineIndicesDo%3A'),
  6032. category: 'split join',
  6033. fn: function (aBlock){
  6034. var self=this;
  6035. try{var cr=nil;
  6036. var lf=nil;
  6037. var start=nil;
  6038. var sz=nil;
  6039. var nextLF=nil;
  6040. var nextCR=nil;
  6041. start=(1);
  6042. sz=smalltalk.send(self, "_size", []);
  6043. cr=smalltalk.send((smalltalk.String || String), "_cr", []);
  6044. nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, (1)]);
  6045. lf=smalltalk.send((smalltalk.String || String), "_lf", []);
  6046. nextLF=smalltalk.send(self, "_indexOf_startingAt_", [lf, (1)]);
  6047. (function(){while((function(){return ((($receiver = start).klass === smalltalk.Number) ? $receiver <=sz : smalltalk.send($receiver, "__lt_eq", [sz]));})()) {(function(){((($receiver = smalltalk.send(smalltalk.send(nextLF, "__eq", [(0)]), "_and_", [(function(){return smalltalk.send(nextCR, "__eq", [(0)]);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(aBlock, "_value_value_value_", [start, sz, sz]);return (function(){throw({name: 'stReturn', selector: '_lineIndicesDo_', fn: function(){return self}})})();})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(aBlock, "_value_value_value_", [start, sz, sz]);return (function(){throw({name: 'stReturn', selector: '_lineIndicesDo_', fn: function(){return self}})})();})]));return ((($receiver = smalltalk.send(smalltalk.send(nextCR, "__eq", [(0)]), "_or_", [(function(){return smalltalk.send((0) < nextLF, "_and_", [(function(){return ((($receiver = nextLF).klass === smalltalk.Number) ? $receiver <nextCR : smalltalk.send($receiver, "__lt", [nextCR]));})]);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextLF).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextLF]);start=(1) + nextLF;return nextLF=smalltalk.send(self, "_indexOf_startingAt_", [lf, start]);})() : (function(){return ((($receiver = smalltalk.send((1) + nextCR, "__eq", [nextLF])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextLF]);start=(1) + nextLF;nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);return nextLF=smalltalk.send(self, "_indexOf_startingAt_", [lf, start]);})() : (function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextCR]);start=(1) + nextCR;return nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextLF]);start=(1) + nextLF;nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);return nextLF=smalltalk.send(self, "_indexOf_startingAt_", [lf, start]);}), (function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextCR]);start=(1) + nextCR;return nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);})]));})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextLF).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextLF]);start=(1) + nextLF;return nextLF=smalltalk.send(self, "_indexOf_startingAt_", [lf, start]);}), (function(){return ((($receiver = smalltalk.send((1) + nextCR, "__eq", [nextLF])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextLF]);start=(1) + nextLF;nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);return nextLF=smalltalk.send(self, "_indexOf_startingAt_", [lf, start]);})() : (function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextCR]);start=(1) + nextCR;return nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextLF]);start=(1) + nextLF;nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);return nextLF=smalltalk.send(self, "_indexOf_startingAt_", [lf, start]);}), (function(){smalltalk.send(aBlock, "_value_value_value_", [start, ((($receiver = nextCR).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)])), nextCR]);start=(1) + nextCR;return nextCR=smalltalk.send(self, "_indexOf_startingAt_", [cr, start]);})]));})]));})()}})();
  6048. return self;
  6049. } catch(e) {if(e.name === 'stReturn' && e.selector === '_lineIndicesDo_'){return e.fn()} throw(e)}},
  6050. args: ["aBlock"],
  6051. source: unescape('lineIndicesDo%3A%20aBlock%0A%09%22execute%20aBlock%20with%203%20arguments%20for%20each%20line%3A%0A%09-%20start%20index%20of%20line%0A%09-%20end%20index%20of%20line%20without%20line%20delimiter%0A%09-%20end%20index%20of%20line%20including%20line%20delimiter%28s%29%20CR%2C%20LF%20or%20CRLF%22%0A%09%0A%09%7C%20cr%20lf%20start%20sz%20nextLF%20nextCR%20%7C%0A%09start%20%3A%3D%201.%0A%09sz%20%3A%3D%20self%20size.%0A%09cr%20%3A%3D%20String%20cr.%0A%09nextCR%20%3A%3D%20self%20indexOf%3A%20cr%20startingAt%3A%201.%0A%09lf%20%3A%3D%20String%20lf.%0A%09nextLF%20%3A%3D%20self%20indexOf%3A%20lf%20startingAt%3A%201.%0A%09%5B%20start%20%3C%3D%20sz%20%5D%20whileTrue%3A%20%5B%0A%09%09%28nextLF%20%3D%200%20and%3A%20%5B%20nextCR%20%3D%200%20%5D%29%0A%09%09%09ifTrue%3A%20%5B%20%22No%20more%20CR%2C%20nor%20LF%2C%20the%20string%20is%20over%22%0A%09%09%09%09%09aBlock%20value%3A%20start%20value%3A%20sz%20value%3A%20sz.%0A%09%09%09%09%09%5Eself%20%5D.%0A%09%09%28nextCR%20%3D%200%20or%3A%20%5B%200%20%3C%20nextLF%20and%3A%20%5B%20nextLF%20%3C%20nextCR%20%5D%20%5D%29%0A%09%09%09ifTrue%3A%20%5B%20%22Found%20a%20LF%22%0A%09%09%09%09%09aBlock%20value%3A%20start%20value%3A%20nextLF%20-%201%20value%3A%20nextLF.%0A%09%09%09%09%09start%20%3A%3D%201%20+%20nextLF.%0A%09%09%09%09%09nextLF%20%3A%3D%20self%20indexOf%3A%20lf%20startingAt%3A%20start%20%5D%0A%09%09%09ifFalse%3A%20%5B%201%20+%20nextCR%20%3D%20nextLF%0A%09%09%09%09ifTrue%3A%20%5B%20%22Found%20a%20CR-LF%20pair%22%0A%09%09%09%09%09aBlock%20value%3A%20start%20value%3A%20nextCR%20-%201%20value%3A%20nextLF.%0A%09%09%09%09%09start%20%3A%3D%201%20+%20nextLF.%0A%09%09%09%09%09nextCR%20%3A%3D%20self%20indexOf%3A%20cr%20startingAt%3A%20start.%0A%09%09%09%09%09nextLF%20%3A%3D%20self%20indexOf%3A%20lf%20startingAt%3A%20start%20%5D%0A%09%09%09%09ifFalse%3A%20%5B%20%22Found%20a%20CR%22%0A%09%09%09%09%09aBlock%20value%3A%20start%20value%3A%20nextCR%20-%201%20value%3A%20nextCR.%0A%09%09%09%09%09start%20%3A%3D%201%20+%20nextCR.%0A%09%09%09%09%09nextCR%20%3A%3D%20self%20indexOf%3A%20cr%20startingAt%3A%20start%20%5D%5D%5D'),
  6052. messageSends: ["size", "cr", "indexOf:startingAt:", "lf", "whileTrue:", unescape("%3C%3D"), "ifTrue:", "and:", unescape("%3D"), "value:value:value:", "ifTrue:ifFalse:", "or:", unescape("%3C"), unescape("-"), unescape("+")],
  6053. referencedClasses: ["String"]
  6054. }),
  6055. smalltalk.String);
  6056. smalltalk.addMethod(
  6057. unescape('_linesDo_'),
  6058. smalltalk.method({
  6059. selector: unescape('linesDo%3A'),
  6060. category: 'split join',
  6061. fn: function (aBlock){
  6062. var self=this;
  6063. smalltalk.send(self, "_lineIndicesDo_", [(function(start, endWithoutDelimiters, end){return smalltalk.send(aBlock, "_value_", [smalltalk.send(self, "_copyFrom_to_", [start, endWithoutDelimiters])]);})]);
  6064. return self;},
  6065. args: ["aBlock"],
  6066. source: unescape('linesDo%3A%20aBlock%0A%09%22Execute%20aBlock%20with%20each%20line%20in%20this%20string.%20The%20terminating%20line%0A%09delimiters%20CR%2C%20LF%20or%20CRLF%20pairs%20are%20not%20included%20in%20what%20is%20passed%20to%20aBlock%22%0A%0A%09self%20lineIndicesDo%3A%20%5B%3Astart%20%3AendWithoutDelimiters%20%3Aend%20%7C%0A%09%09aBlock%20value%3A%20%28self%20copyFrom%3A%20start%20to%3A%20endWithoutDelimiters%29%5D'),
  6067. messageSends: ["lineIndicesDo:", "value:", "copyFrom:to:"],
  6068. referencedClasses: []
  6069. }),
  6070. smalltalk.String);
  6071. smalltalk.addMethod(
  6072. unescape('_lines'),
  6073. smalltalk.method({
  6074. selector: unescape('lines'),
  6075. category: 'split join',
  6076. fn: function (){
  6077. var self=this;
  6078. var lines=nil;
  6079. lines=smalltalk.send((smalltalk.Array || Array), "_new", []);
  6080. smalltalk.send(self, "_linesDo_", [(function(aLine){return smalltalk.send(lines, "_add_", [aLine]);})]);
  6081. return lines;
  6082. return self;},
  6083. args: [],
  6084. source: unescape('lines%0A%09%22Answer%20an%20array%20of%20lines%20composing%20this%20receiver%20without%20the%20line%20ending%20delimiters.%22%0A%0A%09%7C%20lines%20%7C%0A%09lines%20%3A%3D%20Array%20new.%0A%09self%20linesDo%3A%20%5B%3AaLine%20%7C%20lines%20add%3A%20aLine%5D.%0A%09%5Elines'),
  6085. messageSends: ["new", "linesDo:", "add:"],
  6086. referencedClasses: ["Array"]
  6087. }),
  6088. smalltalk.String);
  6089. smalltalk.addMethod(
  6090. unescape('_lineNumber_'),
  6091. smalltalk.method({
  6092. selector: unescape('lineNumber%3A'),
  6093. category: 'split join',
  6094. fn: function (anIndex){
  6095. var self=this;
  6096. try{var lineCount=nil;
  6097. lineCount=(0);
  6098. smalltalk.send(self, "_lineIndicesDo_", [(function(start, endWithoutDelimiters, end){return ((($receiver = smalltalk.send(lineCount=((($receiver = lineCount).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)])), "__eq", [anIndex])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '_lineNumber_', fn: function(){return smalltalk.send(self, "_copyFrom_to_", [start, endWithoutDelimiters])}})})();})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return (function(){throw({name: 'stReturn', selector: '_lineNumber_', fn: function(){return smalltalk.send(self, "_copyFrom_to_", [start, endWithoutDelimiters])}})})();})]));})]);
  6099. (function(){throw({name: 'stReturn', selector: '_lineNumber_', fn: function(){return nil}})})();
  6100. return self;
  6101. } catch(e) {if(e.name === 'stReturn' && e.selector === '_lineNumber_'){return e.fn()} throw(e)}},
  6102. args: ["anIndex"],
  6103. source: unescape('lineNumber%3A%20anIndex%0A%09%22Answer%20a%20string%20containing%20the%20characters%20in%20the%20given%20line%20number.%22%0A%0A%09%7C%20lineCount%20%7C%0A%09lineCount%20%3A%3D%200.%0A%09self%20lineIndicesDo%3A%20%5B%3Astart%20%3AendWithoutDelimiters%20%3Aend%20%7C%0A%09%09%28lineCount%20%3A%3D%20lineCount%20+%201%29%20%3D%20anIndex%20ifTrue%3A%20%5B%5Eself%20copyFrom%3A%20start%20to%3A%20endWithoutDelimiters%5D%5D.%0A%09%5Enil'),
  6104. messageSends: ["lineIndicesDo:", "ifTrue:", unescape("%3D"), unescape("+"), "copyFrom:to:"],
  6105. referencedClasses: []
  6106. }),
  6107. smalltalk.String);
  6108. smalltalk.addMethod(
  6109. unescape('_reversed'),
  6110. smalltalk.method({
  6111. selector: unescape('reversed'),
  6112. category: 'converting',
  6113. fn: function (){
  6114. var self=this;
  6115. return self.split("").reverse().join("");
  6116. return self;},
  6117. args: [],
  6118. source: unescape('reversed%0A%09%3Creturn%20self.split%28%22%22%29.reverse%28%29.join%28%22%22%29%3E'),
  6119. messageSends: [],
  6120. referencedClasses: []
  6121. }),
  6122. smalltalk.String);
  6123. smalltalk.addMethod(
  6124. unescape('__eq_eq'),
  6125. smalltalk.method({
  6126. selector: unescape('%3D%3D'),
  6127. category: 'comparing',
  6128. fn: function (aString){
  6129. var self=this;
  6130. try{((($receiver = smalltalk.send(smalltalk.send(aString, "_class", []), "__eq", [smalltalk.send(self, "_class", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq_eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq_eq', fn: function(){return false}})})();})]));
  6131. return String(self) === String(aString);
  6132. return self;
  6133. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq_eq'){return e.fn()} throw(e)}},
  6134. args: ["aString"],
  6135. source: unescape('%3D%3D%20aString%0A%09aString%20class%20%3D%20self%20class%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09%3Creturn%20String%28self%29%20%3D%3D%3D%20String%28aString%29%3E'),
  6136. messageSends: ["ifFalse:", unescape("%3D"), "class"],
  6137. referencedClasses: []
  6138. }),
  6139. smalltalk.String);
  6140. smalltalk.addMethod(
  6141. unescape('_asJavaScriptSelector'),
  6142. smalltalk.method({
  6143. selector: unescape('asJavaScriptSelector'),
  6144. category: 'converting',
  6145. fn: function (){
  6146. var self=this;
  6147. return smalltalk.send(smalltalk.send(smalltalk.send(self, "_asSelector", []), "_replace_with_", [unescape("%5E_"), ""]), "_replace_with_", [unescape("_.*"), ""]);
  6148. return self;},
  6149. args: [],
  6150. source: unescape('asJavaScriptSelector%0A%09%5E%28self%20asSelector%20replace%3A%20%27%5E_%27%20with%3A%20%27%27%29%20replace%3A%20%27_.*%27%20with%3A%20%27%27.'),
  6151. messageSends: ["replace:with:", "asSelector"],
  6152. referencedClasses: []
  6153. }),
  6154. smalltalk.String);
  6155. smalltalk.addMethod(
  6156. unescape('_streamClass'),
  6157. smalltalk.method({
  6158. selector: unescape('streamClass'),
  6159. category: 'accessing',
  6160. fn: function (){
  6161. var self=this;
  6162. return (smalltalk.StringStream || StringStream);
  6163. return self;},
  6164. args: [],
  6165. source: unescape('streamClass%0A%09%20%20%20%20%5EStringStream'),
  6166. messageSends: [],
  6167. referencedClasses: ["StringStream"]
  6168. }),
  6169. smalltalk.String.klass);
  6170. smalltalk.addMethod(
  6171. unescape('_fromString_'),
  6172. smalltalk.method({
  6173. selector: unescape('fromString%3A'),
  6174. category: 'instance creation',
  6175. fn: function (aString){
  6176. var self=this;
  6177. return new self.fn(aString);
  6178. return self;},
  6179. args: ["aString"],
  6180. source: unescape('fromString%3A%20aString%0A%09%20%20%20%20%3Creturn%20new%20self.fn%28aString%29%3E'),
  6181. messageSends: [],
  6182. referencedClasses: []
  6183. }),
  6184. smalltalk.String.klass);
  6185. smalltalk.addMethod(
  6186. unescape('_cr'),
  6187. smalltalk.method({
  6188. selector: unescape('cr'),
  6189. category: 'accessing',
  6190. fn: function (){
  6191. var self=this;
  6192. return '\r';
  6193. return self;},
  6194. args: [],
  6195. source: unescape('cr%0A%09%3Creturn%20%27%5Cr%27%3E'),
  6196. messageSends: [],
  6197. referencedClasses: []
  6198. }),
  6199. smalltalk.String.klass);
  6200. smalltalk.addMethod(
  6201. unescape('_lf'),
  6202. smalltalk.method({
  6203. selector: unescape('lf'),
  6204. category: 'accessing',
  6205. fn: function (){
  6206. var self=this;
  6207. return '\n';
  6208. return self;},
  6209. args: [],
  6210. source: unescape('lf%0A%09%3Creturn%20%27%5Cn%27%3E'),
  6211. messageSends: [],
  6212. referencedClasses: []
  6213. }),
  6214. smalltalk.String.klass);
  6215. smalltalk.addMethod(
  6216. unescape('_space'),
  6217. smalltalk.method({
  6218. selector: unescape('space'),
  6219. category: 'accessing',
  6220. fn: function (){
  6221. var self=this;
  6222. return ' ';
  6223. return self;},
  6224. args: [],
  6225. source: unescape('space%0A%09%3Creturn%20%27%20%27%3E'),
  6226. messageSends: [],
  6227. referencedClasses: []
  6228. }),
  6229. smalltalk.String.klass);
  6230. smalltalk.addMethod(
  6231. unescape('_tab'),
  6232. smalltalk.method({
  6233. selector: unescape('tab'),
  6234. category: 'accessing',
  6235. fn: function (){
  6236. var self=this;
  6237. return '\t';
  6238. return self;},
  6239. args: [],
  6240. source: unescape('tab%0A%09%3Creturn%20%27%5Ct%27%3E'),
  6241. messageSends: [],
  6242. referencedClasses: []
  6243. }),
  6244. smalltalk.String.klass);
  6245. smalltalk.addMethod(
  6246. unescape('_crlf'),
  6247. smalltalk.method({
  6248. selector: unescape('crlf'),
  6249. category: 'accessing',
  6250. fn: function (){
  6251. var self=this;
  6252. return '\r\n';
  6253. return self;},
  6254. args: [],
  6255. source: unescape('crlf%0A%09%3Creturn%20%27%5Cr%5Cn%27%3E'),
  6256. messageSends: [],
  6257. referencedClasses: []
  6258. }),
  6259. smalltalk.String.klass);
  6260. smalltalk.addMethod(
  6261. unescape('_streamContents_'),
  6262. smalltalk.method({
  6263. selector: unescape('streamContents%3A'),
  6264. category: 'instance creation',
  6265. fn: function (blockWithArg){
  6266. var self=this;
  6267. var stream=nil;
  6268. stream=smalltalk.send(smalltalk.send(self, "_streamClass", []), "_on_", [smalltalk.send((smalltalk.String || String), "_new", [])]);
  6269. smalltalk.send(blockWithArg, "_value_", [stream]);
  6270. return smalltalk.send(stream, "_contents", []);
  6271. return self;},
  6272. args: ["blockWithArg"],
  6273. source: unescape('streamContents%3A%20blockWithArg%0A%09%7Cstream%7C%0A%09stream%20%3A%3D%20%28self%20streamClass%20on%3A%20String%20new%29.%0A%09blockWithArg%20value%3A%20stream.%0A%09%5E%20stream%20contents'),
  6274. messageSends: ["on:", "streamClass", "new", "value:", "contents"],
  6275. referencedClasses: ["String"]
  6276. }),
  6277. smalltalk.String.klass);
  6278. smalltalk.addMethod(
  6279. unescape('_value_'),
  6280. smalltalk.method({
  6281. selector: unescape('value%3A'),
  6282. category: 'instance creation',
  6283. fn: function (aUTFCharCode){
  6284. var self=this;
  6285. return String.fromCharCode(aUTFCharCode);;
  6286. return self;},
  6287. args: ["aUTFCharCode"],
  6288. source: unescape('value%3A%20aUTFCharCode%0A%0A%09%3Creturn%20String.fromCharCode%28aUTFCharCode%29%3B%3E'),
  6289. messageSends: [],
  6290. referencedClasses: []
  6291. }),
  6292. smalltalk.String.klass);
  6293. smalltalk.addClass('Array', smalltalk.SequenceableCollection, [], 'Kernel');
  6294. smalltalk.addMethod(
  6295. unescape('_size'),
  6296. smalltalk.method({
  6297. selector: unescape('size'),
  6298. category: 'accessing',
  6299. fn: function (){
  6300. var self=this;
  6301. return self.length;
  6302. return self;},
  6303. args: [],
  6304. source: unescape('size%0A%09%3Creturn%20self.length%3E'),
  6305. messageSends: [],
  6306. referencedClasses: []
  6307. }),
  6308. smalltalk.Array);
  6309. smalltalk.addMethod(
  6310. unescape('_at_put_'),
  6311. smalltalk.method({
  6312. selector: unescape('at%3Aput%3A'),
  6313. category: 'accessing',
  6314. fn: function (anIndex, anObject){
  6315. var self=this;
  6316. return self[anIndex - 1] = anObject;
  6317. return self;},
  6318. args: ["anIndex", "anObject"],
  6319. source: unescape('at%3A%20anIndex%20put%3A%20anObject%0A%09%3Creturn%20self%5BanIndex%20-%201%5D%20%3D%20anObject%3E'),
  6320. messageSends: [],
  6321. referencedClasses: []
  6322. }),
  6323. smalltalk.Array);
  6324. smalltalk.addMethod(
  6325. unescape('_at_ifAbsent_'),
  6326. smalltalk.method({
  6327. selector: unescape('at%3AifAbsent%3A'),
  6328. category: 'accessing',
  6329. fn: function (anIndex, aBlock){
  6330. var self=this;
  6331. var value = self[anIndex - 1];
  6332. if(value === undefined) {
  6333. return aBlock();
  6334. } else {
  6335. return value;
  6336. }
  6337. ;
  6338. return self;},
  6339. args: ["anIndex", "aBlock"],
  6340. source: unescape('at%3A%20anIndex%20ifAbsent%3A%20aBlock%0A%09%3C%0A%09%20%20%20%20var%20value%20%3D%20self%5BanIndex%20-%201%5D%3B%0A%09%20%20%20%20if%28value%20%3D%3D%3D%20undefined%29%20%7B%0A%09%09return%20aBlock%28%29%3B%0A%09%20%20%20%20%7D%20else%20%7B%0A%09%09return%20value%3B%0A%09%20%20%20%20%7D%0A%09%3E'),
  6341. messageSends: [],
  6342. referencedClasses: []
  6343. }),
  6344. smalltalk.Array);
  6345. smalltalk.addMethod(
  6346. unescape('_add_'),
  6347. smalltalk.method({
  6348. selector: unescape('add%3A'),
  6349. category: 'adding/removing',
  6350. fn: function (anObject){
  6351. var self=this;
  6352. self.push(anObject); return anObject;;
  6353. return self;},
  6354. args: ["anObject"],
  6355. source: unescape('add%3A%20anObject%0A%09%3Cself.push%28anObject%29%3B%20return%20anObject%3B%3E'),
  6356. messageSends: [],
  6357. referencedClasses: []
  6358. }),
  6359. smalltalk.Array);
  6360. smalltalk.addMethod(
  6361. unescape('_shallowCopy'),
  6362. smalltalk.method({
  6363. selector: unescape('shallowCopy'),
  6364. category: 'copying',
  6365. fn: function (){
  6366. var self=this;
  6367. var newCollection=nil;
  6368. newCollection=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  6369. smalltalk.send(self, "_do_", [(function(each){return smalltalk.send(newCollection, "_add_", [each]);})]);
  6370. return newCollection;
  6371. return self;},
  6372. args: [],
  6373. source: unescape('shallowCopy%0A%09%7C%20newCollection%20%7C%0A%09newCollection%20%3A%3D%20self%20class%20new.%0A%09self%20do%3A%20%5B%3Aeach%20%7C%20newCollection%20add%3A%20each%5D.%0A%09%5EnewCollection'),
  6374. messageSends: ["new", "class", "do:", "add:"],
  6375. referencedClasses: []
  6376. }),
  6377. smalltalk.Array);
  6378. smalltalk.addMethod(
  6379. unescape('_deepCopy'),
  6380. smalltalk.method({
  6381. selector: unescape('deepCopy'),
  6382. category: 'copying',
  6383. fn: function (){
  6384. var self=this;
  6385. var newCollection=nil;
  6386. newCollection=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  6387. smalltalk.send(self, "_do_", [(function(each){return smalltalk.send(newCollection, "_add_", [smalltalk.send(each, "_deepCopy", [])]);})]);
  6388. return newCollection;
  6389. return self;},
  6390. args: [],
  6391. source: unescape('deepCopy%0A%09%7C%20newCollection%20%7C%0A%09newCollection%20%3A%3D%20self%20class%20new.%0A%09self%20do%3A%20%5B%3Aeach%20%7C%20newCollection%20add%3A%20each%20deepCopy%5D.%0A%09%5EnewCollection'),
  6392. messageSends: ["new", "class", "do:", "add:", "deepCopy"],
  6393. referencedClasses: []
  6394. }),
  6395. smalltalk.Array);
  6396. smalltalk.addMethod(
  6397. unescape('_copyFrom_to_'),
  6398. smalltalk.method({
  6399. selector: unescape('copyFrom%3Ato%3A'),
  6400. category: 'copying',
  6401. fn: function (anIndex, anotherIndex){
  6402. var self=this;
  6403. var array=nil;
  6404. array=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  6405. smalltalk.send(anIndex, "_to_do_", [anotherIndex, (function(each){return smalltalk.send(array, "_add_", [smalltalk.send(self, "_at_", [each])]);})]);
  6406. return array;
  6407. return self;},
  6408. args: ["anIndex", "anotherIndex"],
  6409. source: unescape('copyFrom%3A%20anIndex%20to%3A%20anotherIndex%0A%09%7C%20array%20%7C%0A%09array%20%3A%3D%20self%20class%20new.%0A%09anIndex%20to%3A%20anotherIndex%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20array%20add%3A%20%28self%20at%3A%20each%29%5D.%0A%09%5Earray'),
  6410. messageSends: ["new", "class", "to:do:", "add:", "at:"],
  6411. referencedClasses: []
  6412. }),
  6413. smalltalk.Array);
  6414. smalltalk.addMethod(
  6415. unescape('_join_'),
  6416. smalltalk.method({
  6417. selector: unescape('join%3A'),
  6418. category: 'enumerating',
  6419. fn: function (aString){
  6420. var self=this;
  6421. return self.join(aString);
  6422. return self;},
  6423. args: ["aString"],
  6424. source: unescape('join%3A%20aString%0A%09%3Creturn%20self.join%28aString%29%3E'),
  6425. messageSends: [],
  6426. referencedClasses: []
  6427. }),
  6428. smalltalk.Array);
  6429. smalltalk.addMethod(
  6430. unescape('_asJavascript'),
  6431. smalltalk.method({
  6432. selector: unescape('asJavascript'),
  6433. category: 'converting',
  6434. fn: function (){
  6435. var self=this;
  6436. return smalltalk.send(smalltalk.send(unescape("%5B"), "__comma", [smalltalk.send(smalltalk.send(self, "_collect_", [(function(each){return smalltalk.send(each, "_asJavascript", []);})]), "_join_", [unescape("%2C%20")])]), "__comma", [unescape("%5D")]);
  6437. return self;},
  6438. args: [],
  6439. source: unescape('asJavascript%0A%09%5E%27%5B%27%2C%20%28%28self%20collect%3A%20%5B%3Aeach%20%7C%20each%20asJavascript%5D%29%20join%3A%20%27%2C%20%27%29%2C%20%20%27%5D%27'),
  6440. messageSends: [unescape("%2C"), "join:", "collect:", "asJavascript"],
  6441. referencedClasses: []
  6442. }),
  6443. smalltalk.Array);
  6444. smalltalk.addMethod(
  6445. unescape('_sort'),
  6446. smalltalk.method({
  6447. selector: unescape('sort'),
  6448. category: 'enumerating',
  6449. fn: function (){
  6450. var self=this;
  6451. return smalltalk.send(self, "_basicPerform_", ["sort"]);
  6452. return self;},
  6453. args: [],
  6454. source: unescape('sort%0A%20%20%20%20%5Eself%20basicPerform%3A%20%27sort%27'),
  6455. messageSends: ["basicPerform:"],
  6456. referencedClasses: []
  6457. }),
  6458. smalltalk.Array);
  6459. smalltalk.addMethod(
  6460. unescape('_sort_'),
  6461. smalltalk.method({
  6462. selector: unescape('sort%3A'),
  6463. category: 'enumerating',
  6464. fn: function (aBlock){
  6465. var self=this;
  6466. return self.sort(function(a, b) {
  6467. if(aBlock(a,b)) {return -1} else {return 1}
  6468. })
  6469. ;
  6470. return self;},
  6471. args: ["aBlock"],
  6472. source: unescape('sort%3A%20aBlock%0A%09%3C%0A%09%09return%20self.sort%28function%28a%2C%20b%29%20%7B%0A%09%09%09if%28aBlock%28a%2Cb%29%29%20%7Breturn%20-1%7D%20else%20%7Breturn%201%7D%0A%09%09%7D%29%0A%09%3E'),
  6473. messageSends: [],
  6474. referencedClasses: []
  6475. }),
  6476. smalltalk.Array);
  6477. smalltalk.addMethod(
  6478. unescape('_remove_'),
  6479. smalltalk.method({
  6480. selector: unescape('remove%3A'),
  6481. category: 'adding/removing',
  6482. fn: function (anObject){
  6483. var self=this;
  6484. for(var i=0;i<self.length;i++) {
  6485. if(self[i] == anObject) {
  6486. self.splice(i,1);
  6487. break;
  6488. }
  6489. }
  6490. ;
  6491. return self;},
  6492. args: ["anObject"],
  6493. source: unescape('remove%3A%20anObject%0A%09%3C%0A%09%09for%28var%20i%3D0%3Bi%3Cself.length%3Bi++%29%20%7B%0A%09%09%09if%28self%5Bi%5D%20%3D%3D%20anObject%29%20%7B%0A%09%09%09%09self.splice%28i%2C1%29%3B%0A%09%09%09%09break%3B%0A%09%09%09%7D%0A%09%09%7D%0A%09%3E'),
  6494. messageSends: [],
  6495. referencedClasses: []
  6496. }),
  6497. smalltalk.Array);
  6498. smalltalk.addMethod(
  6499. unescape('_sorted'),
  6500. smalltalk.method({
  6501. selector: unescape('sorted'),
  6502. category: 'enumerating',
  6503. fn: function (){
  6504. var self=this;
  6505. return smalltalk.send(smalltalk.send(self, "_copy", []), "_sort", []);
  6506. return self;},
  6507. args: [],
  6508. source: unescape('sorted%0A%09%5Eself%20copy%20sort'),
  6509. messageSends: ["sort", "copy"],
  6510. referencedClasses: []
  6511. }),
  6512. smalltalk.Array);
  6513. smalltalk.addMethod(
  6514. unescape('_sorted_'),
  6515. smalltalk.method({
  6516. selector: unescape('sorted%3A'),
  6517. category: 'enumerating',
  6518. fn: function (aBlock){
  6519. var self=this;
  6520. return smalltalk.send(smalltalk.send(self, "_copy", []), "_sort_", [aBlock]);
  6521. return self;},
  6522. args: ["aBlock"],
  6523. source: unescape('sorted%3A%20aBlock%0A%09%5Eself%20copy%20sort%3A%20aBlock'),
  6524. messageSends: ["sort:", "copy"],
  6525. referencedClasses: []
  6526. }),
  6527. smalltalk.Array);
  6528. smalltalk.addMethod(
  6529. unescape('_asJSONObject'),
  6530. smalltalk.method({
  6531. selector: unescape('asJSONObject'),
  6532. category: 'converting',
  6533. fn: function (){
  6534. var self=this;
  6535. return smalltalk.send(self, "_collect_", [(function(each){return smalltalk.send(each, "_asJSONObject", []);})]);
  6536. return self;},
  6537. args: [],
  6538. source: unescape('asJSONObject%0A%09%5Eself%20collect%3A%20%5B%3Aeach%20%7C%20each%20asJSONObject%5D'),
  6539. messageSends: ["collect:", "asJSONObject"],
  6540. referencedClasses: []
  6541. }),
  6542. smalltalk.Array);
  6543. smalltalk.addMethod(
  6544. unescape('_removeFrom_to_'),
  6545. smalltalk.method({
  6546. selector: unescape('removeFrom%3Ato%3A'),
  6547. category: 'adding/removing',
  6548. fn: function (aNumber, anotherNumber){
  6549. var self=this;
  6550. self.splice(aNumber - 1,anotherNumber - 1);
  6551. return self;},
  6552. args: ["aNumber", "anotherNumber"],
  6553. source: unescape('removeFrom%3A%20aNumber%20to%3A%20anotherNumber%0A%09%3Cself.splice%28aNumber%20-%201%2CanotherNumber%20-%201%29%3E'),
  6554. messageSends: [],
  6555. referencedClasses: []
  6556. }),
  6557. smalltalk.Array);
  6558. smalltalk.addMethod(
  6559. unescape('_printString'),
  6560. smalltalk.method({
  6561. selector: unescape('printString'),
  6562. category: 'enumerating',
  6563. fn: function (){
  6564. var self=this;
  6565. var str=nil;
  6566. str=smalltalk.send("", "_writeStream", []);
  6567. smalltalk.send(str, "_nextPutAll_", [smalltalk.send(smalltalk.send(self, "_printString", [], smalltalk.SequenceableCollection), "__comma", [unescape("%20%28")])]);
  6568. smalltalk.send(self, "_do_separatedBy_", [(function(each){return smalltalk.send(str, "_nextPutAll_", [smalltalk.send(each, "_printString", [])]);}), (function(){return smalltalk.send(str, "_nextPutAll_", [" "]);})]);
  6569. smalltalk.send(str, "_nextPutAll_", [unescape("%29")]);
  6570. return smalltalk.send(str, "_contents", []);
  6571. return self;},
  6572. args: [],
  6573. source: unescape('printString%0A%09%7C%20str%20%7C%0A%09str%20%3A%3D%20%27%27%20writeStream.%0A%09str%20nextPutAll%3A%20super%20printString%2C%20%27%20%28%27.%0A%09self%20%0A%09%09do%3A%20%5B%3Aeach%20%7C%20str%20nextPutAll%3A%20each%20printString%5D%0A%09%09separatedBy%3A%20%5Bstr%20nextPutAll%3A%20%27%20%27%5D.%0A%09str%20nextPutAll%3A%20%27%29%27.%0A%09%5Estr%20contents'),
  6574. messageSends: ["writeStream", "nextPutAll:", unescape("%2C"), "printString", "do:separatedBy:", "contents"],
  6575. referencedClasses: []
  6576. }),
  6577. smalltalk.Array);
  6578. smalltalk.addMethod(
  6579. unescape('_reversed'),
  6580. smalltalk.method({
  6581. selector: unescape('reversed'),
  6582. category: 'converting',
  6583. fn: function (){
  6584. var self=this;
  6585. return self._copy().reverse();
  6586. return self;},
  6587. args: [],
  6588. source: unescape('reversed%0A%09%3Creturn%20self._copy%28%29.reverse%28%29%3E'),
  6589. messageSends: [],
  6590. referencedClasses: []
  6591. }),
  6592. smalltalk.Array);
  6593. smalltalk.addMethod(
  6594. unescape('__eq'),
  6595. smalltalk.method({
  6596. selector: unescape('%3D'),
  6597. category: 'comparing',
  6598. fn: function (aCollection){
  6599. var self=this;
  6600. try{((($receiver = smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "__eq", [smalltalk.send(aCollection, "_class", [])]), "_and_", [(function(){return smalltalk.send(smalltalk.send(self, "_size", []), "__eq", [smalltalk.send(aCollection, "_size", [])]);})])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));
  6601. smalltalk.send(self, "_withIndexDo_", [(function(each, i){return ((($receiver = smalltalk.send(smalltalk.send(aCollection, "_at_", [i]), "__eq", [each])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));})]);
  6602. (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return true}})})();
  6603. return self;
  6604. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq'){return e.fn()} throw(e)}},
  6605. args: ["aCollection"],
  6606. source: unescape('%3D%20aCollection%0A%09%28self%20class%20%3D%20aCollection%20class%20and%3A%20%5B%0A%20%20%20%20%20%20%20%20%09self%20size%20%3D%20aCollection%20size%5D%29%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09self%20withIndexDo%3A%20%5B%3Aeach%20%3Ai%20%7C%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%28aCollection%20at%3A%20i%29%20%3D%20each%20ifFalse%3A%20%5B%5Efalse%5D%5D.%0A%09%5Etrue'),
  6607. messageSends: ["ifFalse:", "and:", unescape("%3D"), "class", "size", "withIndexDo:", "at:"],
  6608. referencedClasses: []
  6609. }),
  6610. smalltalk.Array);
  6611. smalltalk.addClass('RegularExpression', smalltalk.Object, [], 'Kernel');
  6612. smalltalk.addMethod(
  6613. unescape('_compile_'),
  6614. smalltalk.method({
  6615. selector: unescape('compile%3A'),
  6616. category: 'evaluating',
  6617. fn: function (aString){
  6618. var self=this;
  6619. return self.compile(aString);
  6620. return self;},
  6621. args: ["aString"],
  6622. source: unescape('compile%3A%20aString%0A%09%3Creturn%20self.compile%28aString%29%3E'),
  6623. messageSends: [],
  6624. referencedClasses: []
  6625. }),
  6626. smalltalk.RegularExpression);
  6627. smalltalk.addMethod(
  6628. unescape('_exec_'),
  6629. smalltalk.method({
  6630. selector: unescape('exec%3A'),
  6631. category: 'evaluating',
  6632. fn: function (aString){
  6633. var self=this;
  6634. return self.exec(aString) || nil;
  6635. return self;},
  6636. args: ["aString"],
  6637. source: unescape('exec%3A%20aString%0A%09%3Creturn%20self.exec%28aString%29%20%7C%7C%20nil%3E'),
  6638. messageSends: [],
  6639. referencedClasses: []
  6640. }),
  6641. smalltalk.RegularExpression);
  6642. smalltalk.addMethod(
  6643. unescape('_test_'),
  6644. smalltalk.method({
  6645. selector: unescape('test%3A'),
  6646. category: 'evaluating',
  6647. fn: function (aString){
  6648. var self=this;
  6649. return self.test(aString);
  6650. return self;},
  6651. args: ["aString"],
  6652. source: unescape('test%3A%20aString%0A%09%3Creturn%20self.test%28aString%29%3E'),
  6653. messageSends: [],
  6654. referencedClasses: []
  6655. }),
  6656. smalltalk.RegularExpression);
  6657. smalltalk.addMethod(
  6658. unescape('_fromString_flag_'),
  6659. smalltalk.method({
  6660. selector: unescape('fromString%3Aflag%3A'),
  6661. category: 'instance creation',
  6662. fn: function (aString, anotherString){
  6663. var self=this;
  6664. return new RegExp(aString, anotherString);
  6665. return self;},
  6666. args: ["aString", "anotherString"],
  6667. source: unescape('fromString%3A%20aString%20flag%3A%20anotherString%0A%09%3Creturn%20new%20RegExp%28aString%2C%20anotherString%29%3E'),
  6668. messageSends: [],
  6669. referencedClasses: []
  6670. }),
  6671. smalltalk.RegularExpression.klass);
  6672. smalltalk.addMethod(
  6673. unescape('_fromString_'),
  6674. smalltalk.method({
  6675. selector: unescape('fromString%3A'),
  6676. category: 'instance creation',
  6677. fn: function (aString){
  6678. var self=this;
  6679. return smalltalk.send(self, "_fromString_flag_", [aString, ""]);
  6680. return self;},
  6681. args: ["aString"],
  6682. source: unescape('fromString%3A%20aString%0A%09%20%20%20%20%5Eself%20fromString%3A%20aString%20flag%3A%20%27%27'),
  6683. messageSends: ["fromString:flag:"],
  6684. referencedClasses: []
  6685. }),
  6686. smalltalk.RegularExpression.klass);
  6687. smalltalk.addClass('Error', smalltalk.Object, ['messageText'], 'Kernel');
  6688. smalltalk.addMethod(
  6689. unescape('_messageText'),
  6690. smalltalk.method({
  6691. selector: unescape('messageText'),
  6692. category: 'accessing',
  6693. fn: function (){
  6694. var self=this;
  6695. return self['@messageText'];
  6696. return self;},
  6697. args: [],
  6698. source: unescape('messageText%0A%09%5EmessageText'),
  6699. messageSends: [],
  6700. referencedClasses: []
  6701. }),
  6702. smalltalk.Error);
  6703. smalltalk.addMethod(
  6704. unescape('_messageText_'),
  6705. smalltalk.method({
  6706. selector: unescape('messageText%3A'),
  6707. category: 'accessing',
  6708. fn: function (aString){
  6709. var self=this;
  6710. self['@messageText']=aString;
  6711. return self;},
  6712. args: ["aString"],
  6713. source: unescape('messageText%3A%20aString%0A%09messageText%20%3A%3D%20aString'),
  6714. messageSends: [],
  6715. referencedClasses: []
  6716. }),
  6717. smalltalk.Error);
  6718. smalltalk.addMethod(
  6719. unescape('_signal'),
  6720. smalltalk.method({
  6721. selector: unescape('signal'),
  6722. category: 'signaling',
  6723. fn: function (){
  6724. var self=this;
  6725. self.context = smalltalk.getThisContext(); self.smalltalkError = true; throw(self);
  6726. return self;},
  6727. args: [],
  6728. source: unescape('signal%0A%09%3Cself.context%20%3D%20smalltalk.getThisContext%28%29%3B%20self.smalltalkError%20%3D%20true%3B%20throw%28self%29%3E'),
  6729. messageSends: [],
  6730. referencedClasses: []
  6731. }),
  6732. smalltalk.Error);
  6733. smalltalk.addMethod(
  6734. unescape('_context'),
  6735. smalltalk.method({
  6736. selector: unescape('context'),
  6737. category: 'accessing',
  6738. fn: function (){
  6739. var self=this;
  6740. return self.context;
  6741. return self;},
  6742. args: [],
  6743. source: unescape('context%0A%09%3Creturn%20self.context%3E'),
  6744. messageSends: [],
  6745. referencedClasses: []
  6746. }),
  6747. smalltalk.Error);
  6748. smalltalk.addMethod(
  6749. unescape('_jsStack'),
  6750. smalltalk.method({
  6751. selector: unescape('jsStack'),
  6752. category: 'accessing',
  6753. fn: function (){
  6754. var self=this;
  6755. return self.stack;
  6756. return self;},
  6757. args: [],
  6758. source: unescape('jsStack%0A%09%3Creturn%20self.stack%3E'),
  6759. messageSends: [],
  6760. referencedClasses: []
  6761. }),
  6762. smalltalk.Error);
  6763. smalltalk.addMethod(
  6764. unescape('_isSmalltalkError'),
  6765. smalltalk.method({
  6766. selector: unescape('isSmalltalkError'),
  6767. category: 'testing',
  6768. fn: function (){
  6769. var self=this;
  6770. return self.smalltalkError === true;
  6771. return self;},
  6772. args: [],
  6773. source: unescape('isSmalltalkError%0A%09%3Creturn%20self.smalltalkError%20%3D%3D%3D%20true%3E'),
  6774. messageSends: [],
  6775. referencedClasses: []
  6776. }),
  6777. smalltalk.Error);
  6778. smalltalk.addMethod(
  6779. unescape('_signal_'),
  6780. smalltalk.method({
  6781. selector: unescape('signal%3A'),
  6782. category: 'instance creation',
  6783. fn: function (aString){
  6784. var self=this;
  6785. return (function($rec){smalltalk.send($rec, "_messageText_", [aString]);return smalltalk.send($rec, "_signal", []);})(smalltalk.send(self, "_new", []));
  6786. return self;},
  6787. args: ["aString"],
  6788. source: unescape('signal%3A%20aString%0A%09%20%20%20%20%5Eself%20new%0A%09%09messageText%3A%20aString%3B%0A%09%09signal'),
  6789. messageSends: ["messageText:", "signal", "new"],
  6790. referencedClasses: []
  6791. }),
  6792. smalltalk.Error.klass);
  6793. smalltalk.addClass('MethodContext', smalltalk.Object, [], 'Kernel');
  6794. smalltalk.addMethod(
  6795. unescape('_receiver'),
  6796. smalltalk.method({
  6797. selector: unescape('receiver'),
  6798. category: 'accessing',
  6799. fn: function (){
  6800. var self=this;
  6801. return self.receiver;
  6802. return self;},
  6803. args: [],
  6804. source: unescape('receiver%0A%09%3Creturn%20self.receiver%3E'),
  6805. messageSends: [],
  6806. referencedClasses: []
  6807. }),
  6808. smalltalk.MethodContext);
  6809. smalltalk.addMethod(
  6810. unescape('_selector'),
  6811. smalltalk.method({
  6812. selector: unescape('selector'),
  6813. category: 'accessing',
  6814. fn: function (){
  6815. var self=this;
  6816. return smalltalk.convertSelector(self.selector);
  6817. return self;},
  6818. args: [],
  6819. source: unescape('selector%0A%09%3Creturn%20smalltalk.convertSelector%28self.selector%29%3E'),
  6820. messageSends: [],
  6821. referencedClasses: []
  6822. }),
  6823. smalltalk.MethodContext);
  6824. smalltalk.addMethod(
  6825. unescape('_home'),
  6826. smalltalk.method({
  6827. selector: unescape('home'),
  6828. category: 'accessing',
  6829. fn: function (){
  6830. var self=this;
  6831. return self.homeContext;
  6832. return self;},
  6833. args: [],
  6834. source: unescape('home%0A%09%3Creturn%20self.homeContext%3E'),
  6835. messageSends: [],
  6836. referencedClasses: []
  6837. }),
  6838. smalltalk.MethodContext);
  6839. smalltalk.addMethod(
  6840. unescape('_temps'),
  6841. smalltalk.method({
  6842. selector: unescape('temps'),
  6843. category: 'accessing',
  6844. fn: function (){
  6845. var self=this;
  6846. return self.temps;
  6847. return self;},
  6848. args: [],
  6849. source: unescape('temps%0A%09%3Creturn%20self.temps%3E'),
  6850. messageSends: [],
  6851. referencedClasses: []
  6852. }),
  6853. smalltalk.MethodContext);
  6854. smalltalk.addMethod(
  6855. unescape('_printString'),
  6856. smalltalk.method({
  6857. selector: unescape('printString'),
  6858. category: 'accessing',
  6859. fn: function (){
  6860. var self=this;
  6861. return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_printString", [], smalltalk.Object), "__comma", [unescape("%28")]), "__comma", [smalltalk.send(self, "_asString", [])]), "__comma", [unescape("%29")]);
  6862. return self;},
  6863. args: [],
  6864. source: unescape('printString%0A%09%5Esuper%20printString%2C%20%27%28%27%2C%20self%20asString%2C%20%27%29%27'),
  6865. messageSends: [unescape("%2C"), "printString", "asString"],
  6866. referencedClasses: []
  6867. }),
  6868. smalltalk.MethodContext);
  6869. smalltalk.addMethod(
  6870. unescape('_asString'),
  6871. smalltalk.method({
  6872. selector: unescape('asString'),
  6873. category: 'accessing',
  6874. fn: function (){
  6875. var self=this;
  6876. return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_receiver", []), "_class", []), "_printString", []), "__comma", [unescape("%20%3E%3E%20")]), "__comma", [smalltalk.send(self, "_selector", [])]);
  6877. return self;},
  6878. args: [],
  6879. source: unescape('asString%0A%09%5Eself%20receiver%20class%20printString%2C%20%27%20%3E%3E%20%27%2C%20self%20selector'),
  6880. messageSends: [unescape("%2C"), "printString", "class", "receiver", "selector"],
  6881. referencedClasses: []
  6882. }),
  6883. smalltalk.MethodContext);
  6884. smalltalk.addClass('Association', smalltalk.Object, ['key', 'value'], 'Kernel');
  6885. smalltalk.addMethod(
  6886. unescape('__eq'),
  6887. smalltalk.method({
  6888. selector: unescape('%3D'),
  6889. category: 'comparing',
  6890. fn: function (anAssociation){
  6891. var self=this;
  6892. return smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "__eq", [smalltalk.send(anAssociation, "_class", [])]), "_and_", [(function(){return smalltalk.send(smalltalk.send(smalltalk.send(self, "_key", []), "__eq", [smalltalk.send(anAssociation, "_key", [])]), "_and_", [(function(){return smalltalk.send(smalltalk.send(self, "_value", []), "__eq", [smalltalk.send(anAssociation, "_value", [])]);})]);})]);
  6893. return self;},
  6894. args: ["anAssociation"],
  6895. source: unescape('%3D%20anAssociation%0A%09%5Eself%20class%20%3D%20anAssociation%20class%20and%3A%20%5B%0A%09%20%20%20%20self%20key%20%3D%20anAssociation%20key%20and%3A%20%5B%0A%09%09self%20value%20%3D%20anAssociation%20value%5D%5D'),
  6896. messageSends: ["and:", unescape("%3D"), "class", "key", "value"],
  6897. referencedClasses: []
  6898. }),
  6899. smalltalk.Association);
  6900. smalltalk.addMethod(
  6901. unescape('_key_'),
  6902. smalltalk.method({
  6903. selector: unescape('key%3A'),
  6904. category: 'accessing',
  6905. fn: function (aKey){
  6906. var self=this;
  6907. self['@key']=aKey;
  6908. return self;},
  6909. args: ["aKey"],
  6910. source: unescape('key%3A%20aKey%0A%09key%20%3A%3D%20aKey'),
  6911. messageSends: [],
  6912. referencedClasses: []
  6913. }),
  6914. smalltalk.Association);
  6915. smalltalk.addMethod(
  6916. unescape('_key'),
  6917. smalltalk.method({
  6918. selector: unescape('key'),
  6919. category: 'accessing',
  6920. fn: function (){
  6921. var self=this;
  6922. return self['@key'];
  6923. return self;},
  6924. args: [],
  6925. source: unescape('key%0A%09%5Ekey'),
  6926. messageSends: [],
  6927. referencedClasses: []
  6928. }),
  6929. smalltalk.Association);
  6930. smalltalk.addMethod(
  6931. unescape('_value_'),
  6932. smalltalk.method({
  6933. selector: unescape('value%3A'),
  6934. category: 'accessing',
  6935. fn: function (aValue){
  6936. var self=this;
  6937. self['@value']=aValue;
  6938. return self;},
  6939. args: ["aValue"],
  6940. source: unescape('value%3A%20aValue%0A%09value%20%3A%3D%20aValue'),
  6941. messageSends: [],
  6942. referencedClasses: []
  6943. }),
  6944. smalltalk.Association);
  6945. smalltalk.addMethod(
  6946. unescape('_value'),
  6947. smalltalk.method({
  6948. selector: unescape('value'),
  6949. category: 'accessing',
  6950. fn: function (){
  6951. var self=this;
  6952. return self['@value'];
  6953. return self;},
  6954. args: [],
  6955. source: unescape('value%0A%09%5Evalue'),
  6956. messageSends: [],
  6957. referencedClasses: []
  6958. }),
  6959. smalltalk.Association);
  6960. smalltalk.addMethod(
  6961. unescape('_storeOn_'),
  6962. smalltalk.method({
  6963. selector: unescape('storeOn%3A'),
  6964. category: 'comparing',
  6965. fn: function (aStream){
  6966. var self=this;
  6967. smalltalk.send(self['@key'], "_storeOn_", [aStream]);
  6968. smalltalk.send(aStream, "_nextPutAll_", [unescape("-%3E")]);
  6969. smalltalk.send(self['@value'], "_storeOn_", [aStream]);
  6970. return self;},
  6971. args: ["aStream"],
  6972. source: unescape('storeOn%3A%20aStream%0A%09%22Store%20in%20the%20format%20%28key-%3Evalue%29%22%0A%0A%09%22aStream%20nextPutAll%3A%20%27%28%27.%22%0A%09key%20storeOn%3A%20aStream.%0A%09aStream%20nextPutAll%3A%20%27-%3E%27.%0A%09value%20storeOn%3A%20aStream.%0A%09%22aStream%20nextPutAll%3A%20%27%29%27%22'),
  6973. messageSends: ["storeOn:", "nextPutAll:"],
  6974. referencedClasses: []
  6975. }),
  6976. smalltalk.Association);
  6977. smalltalk.addMethod(
  6978. unescape('_key_value_'),
  6979. smalltalk.method({
  6980. selector: unescape('key%3Avalue%3A'),
  6981. category: 'instance creation',
  6982. fn: function (aKey, aValue){
  6983. var self=this;
  6984. return (function($rec){smalltalk.send($rec, "_key_", [aKey]);smalltalk.send($rec, "_value_", [aValue]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  6985. return self;},
  6986. args: ["aKey", "aValue"],
  6987. source: unescape('key%3A%20aKey%20value%3A%20aValue%0A%09%20%20%20%20%5Eself%20new%0A%09%09key%3A%20aKey%3B%0A%09%09value%3A%20aValue%3B%0A%09%09yourself'),
  6988. messageSends: ["key:", "value:", "yourself", "new"],
  6989. referencedClasses: []
  6990. }),
  6991. smalltalk.Association.klass);
  6992. smalltalk.addClass('Dictionary', smalltalk.Collection, ['keys'], 'Kernel');
  6993. smalltalk.addMethod(
  6994. unescape('__eq'),
  6995. smalltalk.method({
  6996. selector: unescape('%3D'),
  6997. category: 'comparing',
  6998. fn: function (aDictionary){
  6999. var self=this;
  7000. try{((($receiver = smalltalk.send(smalltalk.send(self, "_class", []), "__eq", [smalltalk.send(aDictionary, "_class", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));
  7001. ((($receiver = smalltalk.send(smalltalk.send(self, "_size", []), "__eq", [smalltalk.send(aDictionary, "_size", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));
  7002. (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return smalltalk.send(smalltalk.send(self, "_associations", []), "__eq", [smalltalk.send(aDictionary, "_associations", [])])}})})();
  7003. return self;
  7004. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq'){return e.fn()} throw(e)}},
  7005. args: ["aDictionary"],
  7006. source: unescape('%3D%20aDictionary%0A%09self%20class%20%3D%20aDictionary%20class%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09self%20size%20%3D%20aDictionary%20size%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09%5Eself%20associations%20%3D%20aDictionary%20associations'),
  7007. messageSends: ["ifFalse:", unescape("%3D"), "class", "size", "associations"],
  7008. referencedClasses: []
  7009. }),
  7010. smalltalk.Dictionary);
  7011. smalltalk.addMethod(
  7012. unescape('_shallowCopy'),
  7013. smalltalk.method({
  7014. selector: unescape('shallowCopy'),
  7015. category: 'copying',
  7016. fn: function (){
  7017. var self=this;
  7018. var copy=nil;
  7019. copy=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  7020. smalltalk.send(self, "_associationsDo_", [(function(each){return smalltalk.send(copy, "_at_put_", [smalltalk.send(each, "_key", []), smalltalk.send(each, "_value", [])]);})]);
  7021. return copy;
  7022. return self;},
  7023. args: [],
  7024. source: unescape('shallowCopy%0A%09%7C%20copy%20%7C%0A%09copy%20%3A%3D%20self%20class%20new.%0A%09self%20associationsDo%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20copy%20at%3A%20each%20key%20%20put%3A%20each%20value%5D.%0A%09%5Ecopy'),
  7025. messageSends: ["new", "class", "associationsDo:", "at:put:", "key", "value"],
  7026. referencedClasses: []
  7027. }),
  7028. smalltalk.Dictionary);
  7029. smalltalk.addMethod(
  7030. unescape('_initialize'),
  7031. smalltalk.method({
  7032. selector: unescape('initialize'),
  7033. category: 'initialization',
  7034. fn: function (){
  7035. var self=this;
  7036. smalltalk.send(self, "_initialize", [], smalltalk.Collection);
  7037. self['@keys']=[];
  7038. return self;},
  7039. args: [],
  7040. source: unescape('initialize%0A%20%20%20%20%09super%20initialize.%0A%20%20%20%20%09keys%20%3A%3D%20%23%28%29'),
  7041. messageSends: ["initialize"],
  7042. referencedClasses: []
  7043. }),
  7044. smalltalk.Dictionary);
  7045. smalltalk.addMethod(
  7046. unescape('_size'),
  7047. smalltalk.method({
  7048. selector: unescape('size'),
  7049. category: 'accessing',
  7050. fn: function (){
  7051. var self=this;
  7052. return smalltalk.send(self['@keys'], "_size", []);
  7053. return self;},
  7054. args: [],
  7055. source: unescape('size%0A%09%5Ekeys%20size'),
  7056. messageSends: ["size"],
  7057. referencedClasses: []
  7058. }),
  7059. smalltalk.Dictionary);
  7060. smalltalk.addMethod(
  7061. unescape('_associations'),
  7062. smalltalk.method({
  7063. selector: unescape('associations'),
  7064. category: 'accessing',
  7065. fn: function (){
  7066. var self=this;
  7067. var associations=nil;
  7068. associations=[];
  7069. smalltalk.send(self['@keys'], "_do_", [(function(each){return smalltalk.send(associations, "_add_", [smalltalk.send((smalltalk.Association || Association), "_key_value_", [each, smalltalk.send(self, "_at_", [each])])]);})]);
  7070. return associations;
  7071. return self;},
  7072. args: [],
  7073. source: unescape('associations%0A%09%7C%20associations%20%7C%0A%09associations%20%3A%3D%20%23%28%29.%0A%09keys%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20associations%20add%3A%20%28Association%20key%3A%20each%20value%3A%20%28self%20at%3A%20each%29%29%5D.%0A%09%5Eassociations'),
  7074. messageSends: ["do:", "add:", "key:value:", "at:"],
  7075. referencedClasses: ["Association"]
  7076. }),
  7077. smalltalk.Dictionary);
  7078. smalltalk.addMethod(
  7079. unescape('_keys'),
  7080. smalltalk.method({
  7081. selector: unescape('keys'),
  7082. category: 'accessing',
  7083. fn: function (){
  7084. var self=this;
  7085. return smalltalk.send(self['@keys'], "_copy", []);
  7086. return self;},
  7087. args: [],
  7088. source: unescape('keys%0A%09%5Ekeys%20copy'),
  7089. messageSends: ["copy"],
  7090. referencedClasses: []
  7091. }),
  7092. smalltalk.Dictionary);
  7093. smalltalk.addMethod(
  7094. unescape('_values'),
  7095. smalltalk.method({
  7096. selector: unescape('values'),
  7097. category: 'accessing',
  7098. fn: function (){
  7099. var self=this;
  7100. return smalltalk.send(self['@keys'], "_collect_", [(function(each){return smalltalk.send(self, "_at_", [each]);})]);
  7101. return self;},
  7102. args: [],
  7103. source: unescape('values%0A%20%20%20%20%09%5Ekeys%20collect%3A%20%5B%3Aeach%20%7C%20self%20at%3A%20each%5D'),
  7104. messageSends: ["collect:", "at:"],
  7105. referencedClasses: []
  7106. }),
  7107. smalltalk.Dictionary);
  7108. smalltalk.addMethod(
  7109. unescape('_at_put_'),
  7110. smalltalk.method({
  7111. selector: unescape('at%3Aput%3A'),
  7112. category: 'accessing',
  7113. fn: function (aKey, aValue){
  7114. var self=this;
  7115. ((($receiver = smalltalk.send(self['@keys'], "_includes_", [aKey])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self['@keys'], "_add_", [aKey]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(self['@keys'], "_add_", [aKey]);})]));
  7116. return smalltalk.send(self, "_basicAt_put_", [aKey, aValue]);
  7117. return self;},
  7118. args: ["aKey", "aValue"],
  7119. source: unescape('at%3A%20aKey%20put%3A%20aValue%0A%09%28keys%20includes%3A%20aKey%29%20ifFalse%3A%20%5Bkeys%20add%3A%20aKey%5D.%0A%09%5Eself%20basicAt%3A%20aKey%20put%3A%20aValue'),
  7120. messageSends: ["ifFalse:", "includes:", "add:", "basicAt:put:"],
  7121. referencedClasses: []
  7122. }),
  7123. smalltalk.Dictionary);
  7124. smalltalk.addMethod(
  7125. unescape('_at_ifAbsent_'),
  7126. smalltalk.method({
  7127. selector: unescape('at%3AifAbsent%3A'),
  7128. category: 'accessing',
  7129. fn: function (aKey, aBlock){
  7130. var self=this;
  7131. return smalltalk.send(smalltalk.send(smalltalk.send(self, "_keys", []), "_includes_", [aKey]), "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self, "_basicAt_", [aKey]);}), aBlock]);
  7132. return self;},
  7133. args: ["aKey", "aBlock"],
  7134. source: unescape('at%3A%20aKey%20ifAbsent%3A%20aBlock%0A%09%5E%28self%20keys%20includes%3A%20aKey%29%0A%09%09ifTrue%3A%20%5Bself%20basicAt%3A%20aKey%5D%0A%09%09ifFalse%3A%20aBlock'),
  7135. messageSends: ["ifTrue:ifFalse:", "includes:", "keys", "basicAt:"],
  7136. referencedClasses: []
  7137. }),
  7138. smalltalk.Dictionary);
  7139. smalltalk.addMethod(
  7140. unescape('_at_ifAbsentPut_'),
  7141. smalltalk.method({
  7142. selector: unescape('at%3AifAbsentPut%3A'),
  7143. category: 'accessing',
  7144. fn: function (aKey, aBlock){
  7145. var self=this;
  7146. return smalltalk.send(self, "_at_ifAbsent_", [aKey, (function(){return smalltalk.send(self, "_at_put_", [aKey, smalltalk.send(aBlock, "_value", [])]);})]);
  7147. return self;},
  7148. args: ["aKey", "aBlock"],
  7149. source: unescape('at%3A%20aKey%20ifAbsentPut%3A%20aBlock%0A%20%20%20%20%09%5Eself%20at%3A%20aKey%20ifAbsent%3A%20%5B%0A%20%20%20%20%09%20%20%20%20self%20at%3A%20aKey%20put%3A%20aBlock%20value%5D'),
  7150. messageSends: ["at:ifAbsent:", "at:put:", "value"],
  7151. referencedClasses: []
  7152. }),
  7153. smalltalk.Dictionary);
  7154. smalltalk.addMethod(
  7155. unescape('_at_ifPresent_'),
  7156. smalltalk.method({
  7157. selector: unescape('at%3AifPresent%3A'),
  7158. category: 'accessing',
  7159. fn: function (aKey, aBlock){
  7160. var self=this;
  7161. return (($receiver = smalltalk.send(self, "_basicAt_", [aKey])) != nil && $receiver != undefined) ? (function(){return smalltalk.send(aBlock, "_value_", [smalltalk.send(self, "_at_", [aKey])]);})() : nil;
  7162. return self;},
  7163. args: ["aKey", "aBlock"],
  7164. source: unescape('at%3A%20aKey%20ifPresent%3A%20aBlock%0A%09%5E%28self%20basicAt%3A%20aKey%29%20ifNotNil%3A%20%5BaBlock%20value%3A%20%28self%20at%3A%20aKey%29%5D'),
  7165. messageSends: ["ifNotNil:", "basicAt:", "value:", "at:"],
  7166. referencedClasses: []
  7167. }),
  7168. smalltalk.Dictionary);
  7169. smalltalk.addMethod(
  7170. unescape('_at_ifPresent_ifAbsent_'),
  7171. smalltalk.method({
  7172. selector: unescape('at%3AifPresent%3AifAbsent%3A'),
  7173. category: 'accessing',
  7174. fn: function (aKey, aBlock, anotherBlock){
  7175. var self=this;
  7176. return smalltalk.send(smalltalk.send(self, "_basicAt_", [aKey]), "_ifNil_ifNotNil_", [anotherBlock, (function(){return smalltalk.send(aBlock, "_value_", [smalltalk.send(self, "_at_", [aKey])]);})]);
  7177. return self;},
  7178. args: ["aKey", "aBlock", "anotherBlock"],
  7179. source: unescape('at%3A%20aKey%20ifPresent%3A%20aBlock%20ifAbsent%3A%20anotherBlock%0A%09%5E%28self%20basicAt%3A%20aKey%29%0A%09%20%20%20%20ifNil%3A%20anotherBlock%0A%09%20%20%20%20ifNotNil%3A%20%5BaBlock%20value%3A%20%28self%20at%3A%20aKey%29%5D'),
  7180. messageSends: ["ifNil:ifNotNil:", "basicAt:", "value:", "at:"],
  7181. referencedClasses: []
  7182. }),
  7183. smalltalk.Dictionary);
  7184. smalltalk.addMethod(
  7185. unescape('_add_'),
  7186. smalltalk.method({
  7187. selector: unescape('add%3A'),
  7188. category: 'adding/removing',
  7189. fn: function (anAssociation){
  7190. var self=this;
  7191. smalltalk.send(self, "_at_put_", [smalltalk.send(anAssociation, "_key", []), smalltalk.send(anAssociation, "_value", [])]);
  7192. return self;},
  7193. args: ["anAssociation"],
  7194. source: unescape('add%3A%20anAssociation%0A%20%20%20%20%09self%20at%3A%20anAssociation%20key%20put%3A%20anAssociation%20value'),
  7195. messageSends: ["at:put:", "key", "value"],
  7196. referencedClasses: []
  7197. }),
  7198. smalltalk.Dictionary);
  7199. smalltalk.addMethod(
  7200. unescape('_addAll_'),
  7201. smalltalk.method({
  7202. selector: unescape('addAll%3A'),
  7203. category: 'adding/removing',
  7204. fn: function (aDictionary){
  7205. var self=this;
  7206. smalltalk.send(self, "_addAll_", [smalltalk.send(aDictionary, "_associations", [])], smalltalk.Collection);
  7207. return aDictionary;
  7208. return self;},
  7209. args: ["aDictionary"],
  7210. source: unescape('addAll%3A%20aDictionary%0A%20%20%20%20%09super%20addAll%3A%20aDictionary%20associations.%0A%20%20%20%20%09%5EaDictionary'),
  7211. messageSends: ["addAll:", "associations"],
  7212. referencedClasses: []
  7213. }),
  7214. smalltalk.Dictionary);
  7215. smalltalk.addMethod(
  7216. unescape('__comma'),
  7217. smalltalk.method({
  7218. selector: unescape('%2C'),
  7219. category: 'copying',
  7220. fn: function (aCollection){
  7221. var self=this;
  7222. smalltalk.send(self, "_shouldNotImplement", []);
  7223. return self;},
  7224. args: ["aCollection"],
  7225. source: unescape('%2C%20aCollection%0A%09self%20shouldNotImplement'),
  7226. messageSends: ["shouldNotImplement"],
  7227. referencedClasses: []
  7228. }),
  7229. smalltalk.Dictionary);
  7230. smalltalk.addMethod(
  7231. unescape('_copyFrom_to_'),
  7232. smalltalk.method({
  7233. selector: unescape('copyFrom%3Ato%3A'),
  7234. category: 'copying',
  7235. fn: function (anIndex, anotherIndex){
  7236. var self=this;
  7237. smalltalk.send(self, "_shouldNotImplement", []);
  7238. return self;},
  7239. args: ["anIndex", "anotherIndex"],
  7240. source: unescape('copyFrom%3A%20anIndex%20to%3A%20anotherIndex%0A%09self%20shouldNotImplement'),
  7241. messageSends: ["shouldNotImplement"],
  7242. referencedClasses: []
  7243. }),
  7244. smalltalk.Dictionary);
  7245. smalltalk.addMethod(
  7246. unescape('_associationsDo_'),
  7247. smalltalk.method({
  7248. selector: unescape('associationsDo%3A'),
  7249. category: 'enumerating',
  7250. fn: function (aBlock){
  7251. var self=this;
  7252. smalltalk.send(smalltalk.send(self, "_associations", []), "_do_", [aBlock]);
  7253. return self;},
  7254. args: ["aBlock"],
  7255. source: unescape('associationsDo%3A%20aBlock%0A%20%20%20%20%09self%20associations%20do%3A%20aBlock'),
  7256. messageSends: ["do:", "associations"],
  7257. referencedClasses: []
  7258. }),
  7259. smalltalk.Dictionary);
  7260. smalltalk.addMethod(
  7261. unescape('_keysAndValuesDo_'),
  7262. smalltalk.method({
  7263. selector: unescape('keysAndValuesDo%3A'),
  7264. category: 'enumerating',
  7265. fn: function (aBlock){
  7266. var self=this;
  7267. smalltalk.send(self, "_associationsDo_", [(function(each){return smalltalk.send(aBlock, "_value_value_", [smalltalk.send(each, "_key", []), smalltalk.send(each, "_value", [])]);})]);
  7268. return self;},
  7269. args: ["aBlock"],
  7270. source: unescape('keysAndValuesDo%3A%20aBlock%0A%20%20%20%20%09self%20associationsDo%3A%20%5B%3Aeach%20%7C%0A%20%20%20%20%09%20%20%20%20aBlock%20value%3A%20each%20key%20value%3A%20each%20value%5D'),
  7271. messageSends: ["associationsDo:", "value:value:", "key", "value"],
  7272. referencedClasses: []
  7273. }),
  7274. smalltalk.Dictionary);
  7275. smalltalk.addMethod(
  7276. unescape('_do_'),
  7277. smalltalk.method({
  7278. selector: unescape('do%3A'),
  7279. category: 'enumerating',
  7280. fn: function (aBlock){
  7281. var self=this;
  7282. smalltalk.send(smalltalk.send(self, "_values", []), "_do_", [aBlock]);
  7283. return self;},
  7284. args: ["aBlock"],
  7285. source: unescape('do%3A%20aBlock%0A%20%20%20%20%09self%20values%20do%3A%20aBlock'),
  7286. messageSends: ["do:", "values"],
  7287. referencedClasses: []
  7288. }),
  7289. smalltalk.Dictionary);
  7290. smalltalk.addMethod(
  7291. unescape('_select_'),
  7292. smalltalk.method({
  7293. selector: unescape('select%3A'),
  7294. category: 'enumerating',
  7295. fn: function (aBlock){
  7296. var self=this;
  7297. var newDict=nil;
  7298. newDict=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  7299. smalltalk.send(self, "_keysAndValuesDo_", [(function(key, value){return ((($receiver = smalltalk.send(aBlock, "_value_", [value])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(newDict, "_at_put_", [key, value]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(newDict, "_at_put_", [key, value]);})]));})]);
  7300. return newDict;
  7301. return self;},
  7302. args: ["aBlock"],
  7303. source: unescape('select%3A%20aBlock%0A%20%20%20%20%09%7C%20newDict%20%7C%0A%20%20%20%20%09newDict%20%3A%3D%20self%20class%20new.%0A%20%20%20%20%09self%20keysAndValuesDo%3A%20%5B%3Akey%20%3Avalue%20%7C%0A%20%20%20%20%09%20%20%20%20%28aBlock%20value%3A%20value%29%20ifTrue%3A%20%5BnewDict%20at%3A%20key%20put%3A%20value%5D%5D.%0A%20%20%20%20%09%5EnewDict'),
  7304. messageSends: ["new", "class", "keysAndValuesDo:", "ifTrue:", "value:", "at:put:"],
  7305. referencedClasses: []
  7306. }),
  7307. smalltalk.Dictionary);
  7308. smalltalk.addMethod(
  7309. unescape('_collect_'),
  7310. smalltalk.method({
  7311. selector: unescape('collect%3A'),
  7312. category: 'enumerating',
  7313. fn: function (aBlock){
  7314. var self=this;
  7315. var newDict=nil;
  7316. newDict=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  7317. smalltalk.send(self, "_keysAndValuesDo_", [(function(key, value){return smalltalk.send(newDict, "_at_put_", [key, smalltalk.send(aBlock, "_value_", [value])]);})]);
  7318. return newDict;
  7319. return self;},
  7320. args: ["aBlock"],
  7321. source: unescape('collect%3A%20aBlock%0A%20%20%20%20%09%7C%20newDict%20%7C%0A%20%20%20%20%09newDict%20%3A%3D%20self%20class%20new.%0A%20%20%20%20%09self%20keysAndValuesDo%3A%20%5B%3Akey%20%3Avalue%20%7C%0A%20%20%20%20%09%20%20%20%20newDict%20at%3A%20key%20put%3A%20%28aBlock%20value%3A%20value%29%5D.%0A%20%20%20%20%09%5EnewDict'),
  7322. messageSends: ["new", "class", "keysAndValuesDo:", "at:put:", "value:"],
  7323. referencedClasses: []
  7324. }),
  7325. smalltalk.Dictionary);
  7326. smalltalk.addMethod(
  7327. unescape('_detect_ifNone_'),
  7328. smalltalk.method({
  7329. selector: unescape('detect%3AifNone%3A'),
  7330. category: 'enumerating',
  7331. fn: function (aBlock, anotherBlock){
  7332. var self=this;
  7333. return smalltalk.send(smalltalk.send(self, "_values", []), "_detect_ifNone_", [aBlock, anotherBlock]);
  7334. return self;},
  7335. args: ["aBlock", "anotherBlock"],
  7336. source: unescape('detect%3A%20aBlock%20ifNone%3A%20anotherBlock%0A%09%5Eself%20values%20detect%3A%20aBlock%20ifNone%3A%20anotherBlock'),
  7337. messageSends: ["detect:ifNone:", "values"],
  7338. referencedClasses: []
  7339. }),
  7340. smalltalk.Dictionary);
  7341. smalltalk.addMethod(
  7342. unescape('_includes_'),
  7343. smalltalk.method({
  7344. selector: unescape('includes%3A'),
  7345. category: 'enumerating',
  7346. fn: function (anObject){
  7347. var self=this;
  7348. return smalltalk.send(smalltalk.send(self, "_values", []), "_includes_", [anObject]);
  7349. return self;},
  7350. args: ["anObject"],
  7351. source: unescape('includes%3A%20anObject%0A%09%5Eself%20values%20includes%3A%20anObject'),
  7352. messageSends: ["includes:", "values"],
  7353. referencedClasses: []
  7354. }),
  7355. smalltalk.Dictionary);
  7356. smalltalk.addMethod(
  7357. unescape('_remove_'),
  7358. smalltalk.method({
  7359. selector: unescape('remove%3A'),
  7360. category: 'adding/removing',
  7361. fn: function (aKey){
  7362. var self=this;
  7363. smalltalk.send(self, "_removeKey_", [aKey]);
  7364. return self;},
  7365. args: ["aKey"],
  7366. source: unescape('remove%3A%20aKey%0A%20%20%20%20self%20removeKey%3A%20aKey'),
  7367. messageSends: ["removeKey:"],
  7368. referencedClasses: []
  7369. }),
  7370. smalltalk.Dictionary);
  7371. smalltalk.addMethod(
  7372. unescape('_removeKey_'),
  7373. smalltalk.method({
  7374. selector: unescape('removeKey%3A'),
  7375. category: 'adding/removing',
  7376. fn: function (aKey){
  7377. var self=this;
  7378. smalltalk.send(self['@keys'], "_remove_", [aKey]);
  7379. return self;},
  7380. args: ["aKey"],
  7381. source: unescape('removeKey%3A%20aKey%0A%20%20%20%20keys%20remove%3A%20aKey'),
  7382. messageSends: ["remove:"],
  7383. referencedClasses: []
  7384. }),
  7385. smalltalk.Dictionary);
  7386. smalltalk.addMethod(
  7387. unescape('_at_'),
  7388. smalltalk.method({
  7389. selector: unescape('at%3A'),
  7390. category: 'accessing',
  7391. fn: function (aKey){
  7392. var self=this;
  7393. return smalltalk.send(self, "_at_ifAbsent_", [aKey, (function(){return smalltalk.send(self, "_errorNotFound", []);})]);
  7394. return self;},
  7395. args: ["aKey"],
  7396. source: unescape('at%3A%20aKey%0A%09%5Eself%20at%3A%20aKey%20ifAbsent%3A%20%5Bself%20errorNotFound%5D'),
  7397. messageSends: ["at:ifAbsent:", "errorNotFound"],
  7398. referencedClasses: []
  7399. }),
  7400. smalltalk.Dictionary);
  7401. smalltalk.addMethod(
  7402. unescape('_asJSONObject'),
  7403. smalltalk.method({
  7404. selector: unescape('asJSONObject'),
  7405. category: 'converting',
  7406. fn: function (){
  7407. var self=this;
  7408. var object=nil;
  7409. object=smalltalk.send((smalltalk.Object || Object), "_new", []);
  7410. smalltalk.send(self, "_keysAndValuesDo_", [(function(key, value){return smalltalk.send(object, "_basicAt_put_", [key, smalltalk.send(value, "_asJSONObject", [])]);})]);
  7411. return object;
  7412. return self;},
  7413. args: [],
  7414. source: unescape('asJSONObject%0A%09%7C%20object%20%7C%0A%09object%20%3A%3D%20Object%20new.%0A%09self%20keysAndValuesDo%3A%20%5B%3Akey%20%3Avalue%20%7C%0A%09%09object%20basicAt%3A%20key%20put%3A%20value%20asJSONObject%5D.%0A%09%5Eobject'),
  7415. messageSends: ["new", "keysAndValuesDo:", "basicAt:put:", "asJSONObject"],
  7416. referencedClasses: ["Object"]
  7417. }),
  7418. smalltalk.Dictionary);
  7419. smalltalk.addMethod(
  7420. unescape('_printString'),
  7421. smalltalk.method({
  7422. selector: unescape('printString'),
  7423. category: 'printing',
  7424. fn: function (){
  7425. var self=this;
  7426. return smalltalk.send((smalltalk.String || String), "_streamContents_", [(function(aStream){(function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self, "_printString", [], smalltalk.Collection)]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%28")]);})(aStream);smalltalk.send(smalltalk.send(self, "_associations", []), "_do_separatedBy_", [(function(anAssociation){return (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(anAssociation, "_key", []), "_printString", [])]);smalltalk.send($rec, "_nextPutAll_", [unescape("%20-%3E%20")]);return smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(anAssociation, "_value", []), "_printString", [])]);})(aStream);}), (function(){return smalltalk.send(aStream, "_nextPutAll_", [unescape("%20%2C%20")]);})]);return smalltalk.send(aStream, "_nextPutAll_", [unescape("%29")]);})]);
  7427. return self;},
  7428. args: [],
  7429. source: unescape('printString%0A%09%5E%20String%20streamContents%3A%20%5B%3AaStream%7C%20%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09aStream%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09nextPutAll%3A%20super%20printString%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09nextPutAll%3A%20%27%28%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09self%20associations%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09do%3A%20%5B%3AanAssociation%7C%20%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09aStream%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09nextPutAll%3A%20anAssociation%20key%20printString%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09nextPutAll%3A%20%27%20-%3E%20%27%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09nextPutAll%3A%20anAssociation%20value%20printString%5D%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09separatedBy%3A%20%5BaStream%20nextPutAll%3A%20%27%20%2C%20%27%5D.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09aStream%20nextPutAll%3A%20%27%29%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%5D'),
  7430. messageSends: ["streamContents:", "nextPutAll:", "printString", "do:separatedBy:", "associations", "key", "value"],
  7431. referencedClasses: ["String"]
  7432. }),
  7433. smalltalk.Dictionary);
  7434. smalltalk.addMethod(
  7435. unescape('_storeOn_'),
  7436. smalltalk.method({
  7437. selector: unescape('storeOn%3A'),
  7438. category: 'printing',
  7439. fn: function (aStream){
  7440. var self=this;
  7441. smalltalk.send(aStream, "_nextPutAll_", [unescape("%23%7B")]);
  7442. smalltalk.send(smalltalk.send(self, "_associations", []), "_do_separatedBy_", [(function(each){return smalltalk.send(each, "_storeOn_", [aStream]);}), (function(){return smalltalk.send(aStream, "_nextPutAll_", [". "]);})]);
  7443. smalltalk.send(aStream, "_nextPutAll_", [unescape("%7D")]);
  7444. return self;},
  7445. args: ["aStream"],
  7446. source: unescape('storeOn%3A%20aStream%0A%09aStream%20nextPutAll%3A%20%27%23%7B%27.%0A%09self%20associations%0A%09%09do%3A%20%5B%3Aeach%20%7C%20each%20storeOn%3A%20aStream%5D%0A%09%09separatedBy%3A%20%5B%20aStream%20nextPutAll%3A%20%27.%20%27%5D.%0A%09aStream%20nextPutAll%3A%20%27%7D%27'),
  7447. messageSends: ["nextPutAll:", "do:separatedBy:", "associations", "storeOn:"],
  7448. referencedClasses: []
  7449. }),
  7450. smalltalk.Dictionary);
  7451. smalltalk.addMethod(
  7452. unescape('_fromPairs_'),
  7453. smalltalk.method({
  7454. selector: unescape('fromPairs%3A'),
  7455. category: 'instance creation',
  7456. fn: function (aCollection){
  7457. var self=this;
  7458. var dict=nil;
  7459. dict=smalltalk.send(self, "_new", []);
  7460. smalltalk.send(aCollection, "_do_", [(function(each){return smalltalk.send(dict, "_add_", [each]);})]);
  7461. return dict;
  7462. return self;},
  7463. args: ["aCollection"],
  7464. source: unescape('fromPairs%3A%20aCollection%0A%09%7C%20dict%20%7C%0A%09dict%20%3A%3D%20self%20new.%0A%09aCollection%20do%3A%20%5B%3Aeach%20%7C%20dict%20add%3A%20each%5D.%0A%09%5Edict'),
  7465. messageSends: ["new", "do:", "add:"],
  7466. referencedClasses: []
  7467. }),
  7468. smalltalk.Dictionary.klass);
  7469. smalltalk.addClass('ClassBuilder', smalltalk.Object, [], 'Kernel');
  7470. smalltalk.addMethod(
  7471. unescape('_superclass_subclass_'),
  7472. smalltalk.method({
  7473. selector: unescape('superclass%3Asubclass%3A'),
  7474. category: 'class creation',
  7475. fn: function (aClass, aString){
  7476. var self=this;
  7477. return smalltalk.send(self, "_superclass_subclass_instanceVariableNames_package_", [aClass, aString, "", nil]);
  7478. return self;},
  7479. args: ["aClass", "aString"],
  7480. source: unescape('superclass%3A%20aClass%20subclass%3A%20aString%0A%09%5Eself%20superclass%3A%20aClass%20subclass%3A%20aString%20instanceVariableNames%3A%20%27%27%20package%3A%20nil'),
  7481. messageSends: ["superclass:subclass:instanceVariableNames:package:"],
  7482. referencedClasses: []
  7483. }),
  7484. smalltalk.ClassBuilder);
  7485. smalltalk.addMethod(
  7486. unescape('_class_instanceVariableNames_'),
  7487. smalltalk.method({
  7488. selector: unescape('class%3AinstanceVariableNames%3A'),
  7489. category: 'class creation',
  7490. fn: function (aClass, aString){
  7491. var self=this;
  7492. ((($receiver = smalltalk.send(aClass, "_isMetaclass", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_error_", [smalltalk.send(smalltalk.send(aClass, "_name", []), "__comma", [" is not a metaclass"])]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(self, "_error_", [smalltalk.send(smalltalk.send(aClass, "_name", []), "__comma", [" is not a metaclass"])]);})]));
  7493. smalltalk.send(aClass, "_basicAt_put_", ["iVarNames", smalltalk.send(self, "_instanceVariableNamesFor_", [aString])]);
  7494. smalltalk.send(self, "_setupClass_", [aClass]);
  7495. return self;},
  7496. args: ["aClass", "aString"],
  7497. source: unescape('class%3A%20aClass%20instanceVariableNames%3A%20aString%0A%09aClass%20isMetaclass%20ifFalse%3A%20%5Bself%20error%3A%20aClass%20name%2C%20%27%20is%20not%20a%20metaclass%27%5D.%0A%09aClass%20basicAt%3A%20%27iVarNames%27%20put%3A%20%28self%20instanceVariableNamesFor%3A%20aString%29.%0A%09self%20setupClass%3A%20aClass'),
  7498. messageSends: ["ifFalse:", "isMetaclass", "error:", unescape("%2C"), "name", "basicAt:put:", "instanceVariableNamesFor:", "setupClass:"],
  7499. referencedClasses: []
  7500. }),
  7501. smalltalk.ClassBuilder);
  7502. smalltalk.addMethod(
  7503. unescape('_instanceVariableNamesFor_'),
  7504. smalltalk.method({
  7505. selector: unescape('instanceVariableNamesFor%3A'),
  7506. category: 'private',
  7507. fn: function (aString){
  7508. var self=this;
  7509. return smalltalk.send(smalltalk.send(aString, "_tokenize_", [" "]), "_reject_", [(function(each){return smalltalk.send(each, "_isEmpty", []);})]);
  7510. return self;},
  7511. args: ["aString"],
  7512. source: unescape('instanceVariableNamesFor%3A%20aString%0A%09%5E%28aString%20tokenize%3A%20%27%20%27%29%20reject%3A%20%5B%3Aeach%20%7C%20each%20isEmpty%5D'),
  7513. messageSends: ["reject:", "tokenize:", "isEmpty"],
  7514. referencedClasses: []
  7515. }),
  7516. smalltalk.ClassBuilder);
  7517. smalltalk.addMethod(
  7518. unescape('_addSubclassOf_named_instanceVariableNames_'),
  7519. smalltalk.method({
  7520. selector: unescape('addSubclassOf%3Anamed%3AinstanceVariableNames%3A'),
  7521. category: 'private',
  7522. fn: function (aClass, aString, aCollection){
  7523. var self=this;
  7524. smalltalk.addClass(aString, aClass, aCollection);
  7525. return smalltalk[aString];
  7526. return self;},
  7527. args: ["aClass", "aString", "aCollection"],
  7528. source: unescape('addSubclassOf%3A%20aClass%20named%3A%20aString%20instanceVariableNames%3A%20aCollection%0A%09%3Csmalltalk.addClass%28aString%2C%20aClass%2C%20aCollection%29%3B%0A%09%20%20%20%20return%20smalltalk%5BaString%5D%3E'),
  7529. messageSends: [],
  7530. referencedClasses: []
  7531. }),
  7532. smalltalk.ClassBuilder);
  7533. smalltalk.addMethod(
  7534. unescape('_setupClass_'),
  7535. smalltalk.method({
  7536. selector: unescape('setupClass%3A'),
  7537. category: 'private',
  7538. fn: function (aClass){
  7539. var self=this;
  7540. smalltalk.init(aClass);;
  7541. return self;},
  7542. args: ["aClass"],
  7543. source: unescape('setupClass%3A%20aClass%0A%09%3Csmalltalk.init%28aClass%29%3B%3E'),
  7544. messageSends: [],
  7545. referencedClasses: []
  7546. }),
  7547. smalltalk.ClassBuilder);
  7548. smalltalk.addMethod(
  7549. unescape('_superclass_subclass_instanceVariableNames_package_'),
  7550. smalltalk.method({
  7551. selector: unescape('superclass%3Asubclass%3AinstanceVariableNames%3Apackage%3A'),
  7552. category: 'class creation',
  7553. fn: function (aClass, aString, aString2, aString3){
  7554. var self=this;
  7555. var newClass=nil;
  7556. newClass=smalltalk.send(self, "_addSubclassOf_named_instanceVariableNames_package_", [aClass, aString, smalltalk.send(self, "_instanceVariableNamesFor_", [aString2]), (($receiver = aString3) == nil || $receiver == undefined) ? (function(){return "unclassified";})() : $receiver]);
  7557. smalltalk.send(self, "_setupClass_", [newClass]);
  7558. return newClass;
  7559. return self;},
  7560. args: ["aClass", "aString", "aString2", "aString3"],
  7561. source: unescape('superclass%3A%20aClass%20subclass%3A%20aString%20instanceVariableNames%3A%20aString2%20package%3A%20aString3%0A%09%7C%20newClass%20%7C%0A%09newClass%20%3A%3D%20self%20addSubclassOf%3A%20aClass%0A%09%09%09%09named%3A%20aString%20instanceVariableNames%3A%20%28self%20instanceVariableNamesFor%3A%20aString2%29%0A%09%09%09%09package%3A%20%28aString3%20ifNil%3A%20%5B%27unclassified%27%5D%29.%0A%09self%20setupClass%3A%20newClass.%0A%09%5EnewClass'),
  7562. messageSends: ["addSubclassOf:named:instanceVariableNames:package:", "instanceVariableNamesFor:", "ifNil:", "setupClass:"],
  7563. referencedClasses: []
  7564. }),
  7565. smalltalk.ClassBuilder);
  7566. smalltalk.addMethod(
  7567. unescape('_addSubclassOf_named_instanceVariableNames_package_'),
  7568. smalltalk.method({
  7569. selector: unescape('addSubclassOf%3Anamed%3AinstanceVariableNames%3Apackage%3A'),
  7570. category: 'private',
  7571. fn: function (aClass, aString, aCollection, packageName){
  7572. var self=this;
  7573. smalltalk.addClass(aString, aClass, aCollection, packageName);
  7574. return smalltalk[aString];
  7575. return self;},
  7576. args: ["aClass", "aString", "aCollection", "packageName"],
  7577. source: unescape('addSubclassOf%3A%20aClass%20named%3A%20aString%20instanceVariableNames%3A%20aCollection%20package%3A%20packageName%0A%09%3Csmalltalk.addClass%28aString%2C%20aClass%2C%20aCollection%2C%20packageName%29%3B%0A%09%20%20%20%20return%20smalltalk%5BaString%5D%3E'),
  7578. messageSends: [],
  7579. referencedClasses: []
  7580. }),
  7581. smalltalk.ClassBuilder);
  7582. smalltalk.addMethod(
  7583. unescape('_copyClass_named_'),
  7584. smalltalk.method({
  7585. selector: unescape('copyClass%3Anamed%3A'),
  7586. category: 'private',
  7587. fn: function (aClass, aString){
  7588. var self=this;
  7589. var newClass=nil;
  7590. newClass=smalltalk.send(self, "_addSubclassOf_named_instanceVariableNames_package_", [smalltalk.send(aClass, "_superclass", []), aString, smalltalk.send(aClass, "_instanceVariableNames", []), smalltalk.send(smalltalk.send(aClass, "_package", []), "_name", [])]);
  7591. smalltalk.send(self, "_setupClass_", [newClass]);
  7592. smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_methodDictionary", []), "_values", []), "_do_", [(function(each){smalltalk.send(newClass, "_addCompiledMethod_", [smalltalk.send(smalltalk.send((smalltalk.Compiler || Compiler), "_new", []), "_load_forClass_", [smalltalk.send(each, "_source", []), newClass])]);return smalltalk.send(smalltalk.send(smalltalk.send(newClass, "_methodDictionary", []), "_at_", [smalltalk.send(each, "_selector", [])]), "_category_", [smalltalk.send(each, "_category", [])]);})]);
  7593. smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_class", []), "_methodDictionary", []), "_values", []), "_do_", [(function(each){smalltalk.send(smalltalk.send(newClass, "_class", []), "_addCompiledMethod_", [smalltalk.send(smalltalk.send((smalltalk.Compiler || Compiler), "_new", []), "_load_forClass_", [smalltalk.send(each, "_source", []), smalltalk.send(newClass, "_class", [])])]);return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(newClass, "_class", []), "_methodDictionary", []), "_at_", [smalltalk.send(each, "_selector", [])]), "_category_", [smalltalk.send(each, "_category", [])]);})]);
  7594. smalltalk.send(self, "_setupClass_", [newClass]);
  7595. return newClass;
  7596. return self;},
  7597. args: ["aClass", "aString"],
  7598. source: unescape('copyClass%3A%20aClass%20named%3A%20aString%0A%09%7C%20newClass%20%7C%0A%0A%09newClass%20%3A%3D%20self%20%0A%09%09addSubclassOf%3A%20aClass%20superclass%0A%09%09named%3A%20aString%20%0A%09%09instanceVariableNames%3A%20aClass%20instanceVariableNames%20%0A%09%09package%3A%20aClass%20package%20name.%0A%0A%09self%20setupClass%3A%20newClass.%0A%0A%09aClass%20methodDictionary%20values%20do%3A%20%5B%3Aeach%20%7C%0A%09%09newClass%20addCompiledMethod%3A%20%28Compiler%20new%20load%3A%20each%20source%20forClass%3A%20newClass%29.%0A%09%09%28newClass%20methodDictionary%20at%3A%20each%20selector%29%20category%3A%20each%20category%5D.%0A%0A%09aClass%20class%20methodDictionary%20values%20do%3A%20%5B%3Aeach%20%7C%0A%09%09newClass%20class%20addCompiledMethod%3A%20%28Compiler%20new%20load%3A%20each%20source%20forClass%3A%20newClass%20class%29.%0A%09%09%28newClass%20class%20methodDictionary%20at%3A%20each%20selector%29%20category%3A%20each%20category%5D.%0A%0A%09self%20setupClass%3A%20newClass.%0A%09%5EnewClass'),
  7599. messageSends: ["addSubclassOf:named:instanceVariableNames:package:", "superclass", "instanceVariableNames", "name", "package", "setupClass:", "do:", "values", "methodDictionary", "addCompiledMethod:", "load:forClass:", "new", "source", "category:", "at:", "selector", "category", "class"],
  7600. referencedClasses: ["Compiler"]
  7601. }),
  7602. smalltalk.ClassBuilder);
  7603. smalltalk.addClass('ClassCategoryReader', smalltalk.Object, ['class', 'category', 'chunkParser'], 'Kernel');
  7604. smalltalk.addMethod(
  7605. unescape('_initialize'),
  7606. smalltalk.method({
  7607. selector: unescape('initialize'),
  7608. category: 'initialization',
  7609. fn: function (){
  7610. var self=this;
  7611. smalltalk.send(self, "_initialize", [], smalltalk.Object);
  7612. self['@chunkParser']=smalltalk.send((smalltalk.ChunkParser || ChunkParser), "_new", []);
  7613. return self;},
  7614. args: [],
  7615. source: unescape('initialize%0A%09super%20initialize.%0A%09chunkParser%20%3A%3D%20ChunkParser%20new.'),
  7616. messageSends: ["initialize", "new"],
  7617. referencedClasses: ["ChunkParser"]
  7618. }),
  7619. smalltalk.ClassCategoryReader);
  7620. smalltalk.addMethod(
  7621. unescape('_class_category_'),
  7622. smalltalk.method({
  7623. selector: unescape('class%3Acategory%3A'),
  7624. category: 'accessing',
  7625. fn: function (aClass, aString){
  7626. var self=this;
  7627. self['@class']=aClass;
  7628. self['@category']=aString;
  7629. return self;},
  7630. args: ["aClass", "aString"],
  7631. source: unescape('class%3A%20aClass%20category%3A%20aString%0A%09class%20%3A%3D%20aClass.%0A%09category%20%3A%3D%20aString'),
  7632. messageSends: [],
  7633. referencedClasses: []
  7634. }),
  7635. smalltalk.ClassCategoryReader);
  7636. smalltalk.addMethod(
  7637. unescape('_scanFrom_'),
  7638. smalltalk.method({
  7639. selector: unescape('scanFrom%3A'),
  7640. category: 'fileIn',
  7641. fn: function (aChunkParser){
  7642. var self=this;
  7643. var chunk=nil;
  7644. (function(){while(!(function(){chunk=smalltalk.send(aChunkParser, "_nextChunk", []);return smalltalk.send(chunk, "_isEmpty", []);})()) {(function(){return smalltalk.send(self, "_compileMethod_", [chunk]);})()}})();
  7645. return self;},
  7646. args: ["aChunkParser"],
  7647. source: unescape('scanFrom%3A%20aChunkParser%0A%09%7C%20chunk%20%7C%0A%09%5Bchunk%20%3A%3D%20aChunkParser%20nextChunk.%0A%09chunk%20isEmpty%5D%20whileFalse%3A%20%5B%0A%09%20%20%20%20self%20compileMethod%3A%20chunk%5D'),
  7648. messageSends: ["whileFalse:", "nextChunk", "isEmpty", "compileMethod:"],
  7649. referencedClasses: []
  7650. }),
  7651. smalltalk.ClassCategoryReader);
  7652. smalltalk.addMethod(
  7653. unescape('_compileMethod_'),
  7654. smalltalk.method({
  7655. selector: unescape('compileMethod%3A'),
  7656. category: 'private',
  7657. fn: function (aString){
  7658. var self=this;
  7659. var method=nil;
  7660. method=smalltalk.send(smalltalk.send((smalltalk.Compiler || Compiler), "_new", []), "_load_forClass_", [aString, self['@class']]);
  7661. smalltalk.send(method, "_category_", [self['@category']]);
  7662. smalltalk.send(self['@class'], "_addCompiledMethod_", [method]);
  7663. return self;},
  7664. args: ["aString"],
  7665. source: unescape('compileMethod%3A%20aString%0A%09%7C%20method%20%7C%0A%09method%20%3A%3D%20Compiler%20new%20load%3A%20aString%20forClass%3A%20class.%0A%09method%20category%3A%20category.%0A%09class%20addCompiledMethod%3A%20method'),
  7666. messageSends: ["load:forClass:", "new", "category:", "addCompiledMethod:"],
  7667. referencedClasses: ["Compiler"]
  7668. }),
  7669. smalltalk.ClassCategoryReader);
  7670. smalltalk.addClass('Stream', smalltalk.Object, ['collection', 'position', 'streamSize'], 'Kernel');
  7671. smalltalk.addMethod(
  7672. unescape('_collection'),
  7673. smalltalk.method({
  7674. selector: unescape('collection'),
  7675. category: 'accessing',
  7676. fn: function (){
  7677. var self=this;
  7678. return self['@collection'];
  7679. return self;},
  7680. args: [],
  7681. source: unescape('collection%0A%09%5Ecollection'),
  7682. messageSends: [],
  7683. referencedClasses: []
  7684. }),
  7685. smalltalk.Stream);
  7686. smalltalk.addMethod(
  7687. unescape('_setCollection_'),
  7688. smalltalk.method({
  7689. selector: unescape('setCollection%3A'),
  7690. category: 'accessing',
  7691. fn: function (aCollection){
  7692. var self=this;
  7693. self['@collection']=aCollection;
  7694. return self;},
  7695. args: ["aCollection"],
  7696. source: unescape('setCollection%3A%20aCollection%0A%09collection%20%3A%3D%20aCollection'),
  7697. messageSends: [],
  7698. referencedClasses: []
  7699. }),
  7700. smalltalk.Stream);
  7701. smalltalk.addMethod(
  7702. unescape('_position'),
  7703. smalltalk.method({
  7704. selector: unescape('position'),
  7705. category: 'accessing',
  7706. fn: function (){
  7707. var self=this;
  7708. return (($receiver = self['@position']) == nil || $receiver == undefined) ? (function(){return self['@position']=(0);})() : $receiver;
  7709. return self;},
  7710. args: [],
  7711. source: unescape('position%0A%09%5Eposition%20ifNil%3A%20%5Bposition%20%3A%3D%200%5D'),
  7712. messageSends: ["ifNil:"],
  7713. referencedClasses: []
  7714. }),
  7715. smalltalk.Stream);
  7716. smalltalk.addMethod(
  7717. unescape('_position_'),
  7718. smalltalk.method({
  7719. selector: unescape('position%3A'),
  7720. category: 'accessing',
  7721. fn: function (anInteger){
  7722. var self=this;
  7723. self['@position']=anInteger;
  7724. return self;},
  7725. args: ["anInteger"],
  7726. source: unescape('position%3A%20anInteger%0A%09position%20%3A%3D%20anInteger'),
  7727. messageSends: [],
  7728. referencedClasses: []
  7729. }),
  7730. smalltalk.Stream);
  7731. smalltalk.addMethod(
  7732. unescape('_streamSize'),
  7733. smalltalk.method({
  7734. selector: unescape('streamSize'),
  7735. category: 'accessing',
  7736. fn: function (){
  7737. var self=this;
  7738. return self['@streamSize'];
  7739. return self;},
  7740. args: [],
  7741. source: unescape('streamSize%0A%09%5EstreamSize'),
  7742. messageSends: [],
  7743. referencedClasses: []
  7744. }),
  7745. smalltalk.Stream);
  7746. smalltalk.addMethod(
  7747. unescape('_setStreamSize_'),
  7748. smalltalk.method({
  7749. selector: unescape('setStreamSize%3A'),
  7750. category: 'accessing',
  7751. fn: function (anInteger){
  7752. var self=this;
  7753. self['@streamSize']=anInteger;
  7754. return self;},
  7755. args: ["anInteger"],
  7756. source: unescape('setStreamSize%3A%20anInteger%0A%09streamSize%20%3A%3D%20anInteger'),
  7757. messageSends: [],
  7758. referencedClasses: []
  7759. }),
  7760. smalltalk.Stream);
  7761. smalltalk.addMethod(
  7762. unescape('_contents'),
  7763. smalltalk.method({
  7764. selector: unescape('contents'),
  7765. category: 'accessing',
  7766. fn: function (){
  7767. var self=this;
  7768. return smalltalk.send(smalltalk.send(self, "_collection", []), "_copyFrom_to_", [(1), smalltalk.send(self, "_streamSize", [])]);
  7769. return self;},
  7770. args: [],
  7771. source: unescape('contents%0A%09%5Eself%20collection%0A%09%20%20%20%20copyFrom%3A%201%20%0A%09%20%20%20%20to%3A%20self%20streamSize'),
  7772. messageSends: ["copyFrom:to:", "collection", "streamSize"],
  7773. referencedClasses: []
  7774. }),
  7775. smalltalk.Stream);
  7776. smalltalk.addMethod(
  7777. unescape('_size'),
  7778. smalltalk.method({
  7779. selector: unescape('size'),
  7780. category: 'accessing',
  7781. fn: function (){
  7782. var self=this;
  7783. return smalltalk.send(self, "_streamSize", []);
  7784. return self;},
  7785. args: [],
  7786. source: unescape('size%0A%09%5Eself%20streamSize'),
  7787. messageSends: ["streamSize"],
  7788. referencedClasses: []
  7789. }),
  7790. smalltalk.Stream);
  7791. smalltalk.addMethod(
  7792. unescape('_reset'),
  7793. smalltalk.method({
  7794. selector: unescape('reset'),
  7795. category: 'actions',
  7796. fn: function (){
  7797. var self=this;
  7798. smalltalk.send(self, "_position_", [(0)]);
  7799. return self;},
  7800. args: [],
  7801. source: unescape('reset%0A%09self%20position%3A%200'),
  7802. messageSends: ["position:"],
  7803. referencedClasses: []
  7804. }),
  7805. smalltalk.Stream);
  7806. smalltalk.addMethod(
  7807. unescape('_close'),
  7808. smalltalk.method({
  7809. selector: unescape('close'),
  7810. category: 'actions',
  7811. fn: function (){
  7812. var self=this;
  7813. return self;},
  7814. args: [],
  7815. source: unescape('close'),
  7816. messageSends: [],
  7817. referencedClasses: []
  7818. }),
  7819. smalltalk.Stream);
  7820. smalltalk.addMethod(
  7821. unescape('_flush'),
  7822. smalltalk.method({
  7823. selector: unescape('flush'),
  7824. category: 'actions',
  7825. fn: function (){
  7826. var self=this;
  7827. return self;},
  7828. args: [],
  7829. source: unescape('flush'),
  7830. messageSends: [],
  7831. referencedClasses: []
  7832. }),
  7833. smalltalk.Stream);
  7834. smalltalk.addMethod(
  7835. unescape('_resetContents'),
  7836. smalltalk.method({
  7837. selector: unescape('resetContents'),
  7838. category: 'actions',
  7839. fn: function (){
  7840. var self=this;
  7841. smalltalk.send(self, "_reset", []);
  7842. smalltalk.send(self, "_setStreamSize_", [(0)]);
  7843. return self;},
  7844. args: [],
  7845. source: unescape('resetContents%0A%09self%20reset.%0A%09self%20setStreamSize%3A%200'),
  7846. messageSends: ["reset", "setStreamSize:"],
  7847. referencedClasses: []
  7848. }),
  7849. smalltalk.Stream);
  7850. smalltalk.addMethod(
  7851. unescape('_do_'),
  7852. smalltalk.method({
  7853. selector: unescape('do%3A'),
  7854. category: 'enumerating',
  7855. fn: function (aBlock){
  7856. var self=this;
  7857. (function(){while(!(function(){return smalltalk.send(self, "_atEnd", []);})()) {(function(){return smalltalk.send(aBlock, "_value_", [smalltalk.send(self, "_next", [])]);})()}})();
  7858. return self;},
  7859. args: ["aBlock"],
  7860. source: unescape('do%3A%20aBlock%0A%09%5Bself%20atEnd%5D%20whileFalse%3A%20%5BaBlock%20value%3A%20self%20next%5D'),
  7861. messageSends: ["whileFalse:", "atEnd", "value:", "next"],
  7862. referencedClasses: []
  7863. }),
  7864. smalltalk.Stream);
  7865. smalltalk.addMethod(
  7866. unescape('_setToEnd'),
  7867. smalltalk.method({
  7868. selector: unescape('setToEnd'),
  7869. category: 'positioning',
  7870. fn: function (){
  7871. var self=this;
  7872. smalltalk.send(self, "_position_", [smalltalk.send(self, "_size", [])]);
  7873. return self;},
  7874. args: [],
  7875. source: unescape('setToEnd%0A%09self%20position%3A%20self%20size'),
  7876. messageSends: ["position:", "size"],
  7877. referencedClasses: []
  7878. }),
  7879. smalltalk.Stream);
  7880. smalltalk.addMethod(
  7881. unescape('_skip_'),
  7882. smalltalk.method({
  7883. selector: unescape('skip%3A'),
  7884. category: 'positioning',
  7885. fn: function (anInteger){
  7886. var self=this;
  7887. smalltalk.send(self, "_position_", [smalltalk.send(((($receiver = smalltalk.send(self, "_position", [])).klass === smalltalk.Number) ? $receiver +anInteger : smalltalk.send($receiver, "__plus", [anInteger])), "_min_max_", [smalltalk.send(self, "_size", []), (0)])]);
  7888. return self;},
  7889. args: ["anInteger"],
  7890. source: unescape('skip%3A%20anInteger%0A%09self%20position%3A%20%28%28self%20position%20+%20anInteger%29%20min%3A%20self%20size%20max%3A%200%29'),
  7891. messageSends: ["position:", "min:max:", unescape("+"), "position", "size"],
  7892. referencedClasses: []
  7893. }),
  7894. smalltalk.Stream);
  7895. smalltalk.addMethod(
  7896. unescape('_next'),
  7897. smalltalk.method({
  7898. selector: unescape('next'),
  7899. category: 'reading',
  7900. fn: function (){
  7901. var self=this;
  7902. smalltalk.send(self, "_position_", [((($receiver = smalltalk.send(self, "_position", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]))]);
  7903. return smalltalk.send(self['@collection'], "_at_", [smalltalk.send(self, "_position", [])]);
  7904. return self;},
  7905. args: [],
  7906. source: unescape('next%0A%09self%20position%3A%20self%20position%20+%201.%20%0A%09%5Ecollection%20at%3A%20self%20position'),
  7907. messageSends: ["position:", unescape("+"), "position", "at:"],
  7908. referencedClasses: []
  7909. }),
  7910. smalltalk.Stream);
  7911. smalltalk.addMethod(
  7912. unescape('_next_'),
  7913. smalltalk.method({
  7914. selector: unescape('next%3A'),
  7915. category: 'reading',
  7916. fn: function (anInteger){
  7917. var self=this;
  7918. var tempCollection=nil;
  7919. tempCollection=smalltalk.send(smalltalk.send(smalltalk.send(self, "_collection", []), "_class", []), "_new", []);
  7920. smalltalk.send(anInteger, "_timesRepeat_", [(function(){return ((($receiver = smalltalk.send(self, "_atEnd", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(tempCollection, "_add_", [smalltalk.send(self, "_next", [])]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(tempCollection, "_add_", [smalltalk.send(self, "_next", [])]);})]));})]);
  7921. return tempCollection;
  7922. return self;},
  7923. args: ["anInteger"],
  7924. source: unescape('next%3A%20anInteger%0A%09%7C%20tempCollection%20%7C%0A%09tempCollection%20%3A%3D%20self%20collection%20class%20new.%0A%09anInteger%20timesRepeat%3A%20%5B%0A%09%20%20%20%20self%20atEnd%20ifFalse%3A%20%5B%0A%09%09tempCollection%20add%3A%20self%20next%5D%5D.%0A%09%5EtempCollection'),
  7925. messageSends: ["new", "class", "collection", "timesRepeat:", "ifFalse:", "atEnd", "add:", "next"],
  7926. referencedClasses: []
  7927. }),
  7928. smalltalk.Stream);
  7929. smalltalk.addMethod(
  7930. unescape('_nextPut_'),
  7931. smalltalk.method({
  7932. selector: unescape('nextPut%3A'),
  7933. category: 'writing',
  7934. fn: function (anObject){
  7935. var self=this;
  7936. smalltalk.send(self, "_position_", [((($receiver = smalltalk.send(self, "_position", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]))]);
  7937. smalltalk.send(smalltalk.send(self, "_collection", []), "_at_put_", [smalltalk.send(self, "_position", []), anObject]);
  7938. smalltalk.send(self, "_setStreamSize_", [smalltalk.send(smalltalk.send(self, "_streamSize", []), "_max_", [smalltalk.send(self, "_position", [])])]);
  7939. return self;},
  7940. args: ["anObject"],
  7941. source: unescape('nextPut%3A%20anObject%0A%09self%20position%3A%20self%20position%20+%201.%0A%09self%20collection%20at%3A%20self%20position%20put%3A%20anObject.%0A%09self%20setStreamSize%3A%20%28self%20streamSize%20max%3A%20self%20position%29'),
  7942. messageSends: ["position:", unescape("+"), "position", "at:put:", "collection", "setStreamSize:", "max:", "streamSize"],
  7943. referencedClasses: []
  7944. }),
  7945. smalltalk.Stream);
  7946. smalltalk.addMethod(
  7947. unescape('_nextPutAll_'),
  7948. smalltalk.method({
  7949. selector: unescape('nextPutAll%3A'),
  7950. category: 'writing',
  7951. fn: function (aCollection){
  7952. var self=this;
  7953. smalltalk.send(aCollection, "_do_", [(function(each){return smalltalk.send(self, "_nextPut_", [each]);})]);
  7954. return self;},
  7955. args: ["aCollection"],
  7956. source: unescape('nextPutAll%3A%20aCollection%0A%09aCollection%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20self%20nextPut%3A%20each%5D'),
  7957. messageSends: ["do:", "nextPut:"],
  7958. referencedClasses: []
  7959. }),
  7960. smalltalk.Stream);
  7961. smalltalk.addMethod(
  7962. unescape('_peek'),
  7963. smalltalk.method({
  7964. selector: unescape('peek'),
  7965. category: 'reading',
  7966. fn: function (){
  7967. var self=this;
  7968. return ((($receiver = smalltalk.send(self, "_atEnd", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(smalltalk.send(self, "_collection", []), "_at_", [((($receiver = smalltalk.send(self, "_position", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]))]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(smalltalk.send(self, "_collection", []), "_at_", [((($receiver = smalltalk.send(self, "_position", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]))]);})]));
  7969. return self;},
  7970. args: [],
  7971. source: unescape('peek%0A%09%5Eself%20atEnd%20ifFalse%3A%20%5B%0A%09%20%20%20%20self%20collection%20at%3A%20self%20position%20+%201%5D'),
  7972. messageSends: ["ifFalse:", "atEnd", "at:", "collection", unescape("+"), "position"],
  7973. referencedClasses: []
  7974. }),
  7975. smalltalk.Stream);
  7976. smalltalk.addMethod(
  7977. unescape('_atEnd'),
  7978. smalltalk.method({
  7979. selector: unescape('atEnd'),
  7980. category: 'testing',
  7981. fn: function (){
  7982. var self=this;
  7983. return smalltalk.send(smalltalk.send(self, "_position", []), "__eq", [smalltalk.send(self, "_size", [])]);
  7984. return self;},
  7985. args: [],
  7986. source: unescape('atEnd%0A%09%5Eself%20position%20%3D%20self%20size'),
  7987. messageSends: [unescape("%3D"), "position", "size"],
  7988. referencedClasses: []
  7989. }),
  7990. smalltalk.Stream);
  7991. smalltalk.addMethod(
  7992. unescape('_atStart'),
  7993. smalltalk.method({
  7994. selector: unescape('atStart'),
  7995. category: 'testing',
  7996. fn: function (){
  7997. var self=this;
  7998. return smalltalk.send(smalltalk.send(self, "_position", []), "__eq", [(0)]);
  7999. return self;},
  8000. args: [],
  8001. source: unescape('atStart%0A%09%5Eself%20position%20%3D%200'),
  8002. messageSends: [unescape("%3D"), "position"],
  8003. referencedClasses: []
  8004. }),
  8005. smalltalk.Stream);
  8006. smalltalk.addMethod(
  8007. unescape('_isEmpty'),
  8008. smalltalk.method({
  8009. selector: unescape('isEmpty'),
  8010. category: 'testing',
  8011. fn: function (){
  8012. var self=this;
  8013. return smalltalk.send(smalltalk.send(self, "_size", []), "__eq", [(0)]);
  8014. return self;},
  8015. args: [],
  8016. source: unescape('isEmpty%0A%09%5Eself%20size%20%3D%200'),
  8017. messageSends: [unescape("%3D"), "size"],
  8018. referencedClasses: []
  8019. }),
  8020. smalltalk.Stream);
  8021. smalltalk.addMethod(
  8022. unescape('_on_'),
  8023. smalltalk.method({
  8024. selector: unescape('on%3A'),
  8025. category: 'instance creation',
  8026. fn: function (aCollection){
  8027. var self=this;
  8028. return (function($rec){smalltalk.send($rec, "_setCollection_", [aCollection]);smalltalk.send($rec, "_setStreamSize_", [smalltalk.send(aCollection, "_size", [])]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  8029. return self;},
  8030. args: ["aCollection"],
  8031. source: unescape('on%3A%20aCollection%0A%09%20%20%20%20%5Eself%20new%20%0A%09%09setCollection%3A%20aCollection%3B%0A%09%09setStreamSize%3A%20aCollection%20size%3B%0A%09%09yourself'),
  8032. messageSends: ["setCollection:", "setStreamSize:", "size", "yourself", "new"],
  8033. referencedClasses: []
  8034. }),
  8035. smalltalk.Stream.klass);
  8036. smalltalk.addClass('StringStream', smalltalk.Stream, [], 'Kernel');
  8037. smalltalk.addMethod(
  8038. unescape('_next_'),
  8039. smalltalk.method({
  8040. selector: unescape('next%3A'),
  8041. category: 'reading',
  8042. fn: function (anInteger){
  8043. var self=this;
  8044. var tempCollection=nil;
  8045. tempCollection=smalltalk.send(smalltalk.send(smalltalk.send(self, "_collection", []), "_class", []), "_new", []);
  8046. smalltalk.send(anInteger, "_timesRepeat_", [(function(){return ((($receiver = smalltalk.send(self, "_atEnd", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return tempCollection=smalltalk.send(tempCollection, "__comma", [smalltalk.send(self, "_next", [])]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return tempCollection=smalltalk.send(tempCollection, "__comma", [smalltalk.send(self, "_next", [])]);})]));})]);
  8047. return tempCollection;
  8048. return self;},
  8049. args: ["anInteger"],
  8050. source: unescape('next%3A%20anInteger%0A%09%7C%20tempCollection%20%7C%0A%09tempCollection%20%3A%3D%20self%20collection%20class%20new.%0A%09anInteger%20timesRepeat%3A%20%5B%0A%09%20%20%20%20self%20atEnd%20ifFalse%3A%20%5B%0A%09%09tempCollection%20%3A%3D%20tempCollection%2C%20self%20next%5D%5D.%0A%09%5EtempCollection'),
  8051. messageSends: ["new", "class", "collection", "timesRepeat:", "ifFalse:", "atEnd", unescape("%2C"), "next"],
  8052. referencedClasses: []
  8053. }),
  8054. smalltalk.StringStream);
  8055. smalltalk.addMethod(
  8056. unescape('_nextPut_'),
  8057. smalltalk.method({
  8058. selector: unescape('nextPut%3A'),
  8059. category: 'writing',
  8060. fn: function (aString){
  8061. var self=this;
  8062. smalltalk.send(self, "_nextPutAll_", [aString]);
  8063. return self;},
  8064. args: ["aString"],
  8065. source: unescape('nextPut%3A%20aString%0A%09self%20nextPutAll%3A%20aString'),
  8066. messageSends: ["nextPutAll:"],
  8067. referencedClasses: []
  8068. }),
  8069. smalltalk.StringStream);
  8070. smalltalk.addMethod(
  8071. unescape('_nextPutAll_'),
  8072. smalltalk.method({
  8073. selector: unescape('nextPutAll%3A'),
  8074. category: 'writing',
  8075. fn: function (aString){
  8076. var self=this;
  8077. smalltalk.send(self, "_setCollection_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_collection", []), "_copyFrom_to_", [(1), smalltalk.send(self, "_position", [])]), "__comma", [aString]), "__comma", [smalltalk.send(smalltalk.send(self, "_collection", []), "_copyFrom_to_", [((($receiver = ((($receiver = smalltalk.send(self, "_position", [])).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]))).klass === smalltalk.Number) ? $receiver +smalltalk.send(aString, "_size", []) : smalltalk.send($receiver, "__plus", [smalltalk.send(aString, "_size", [])])), smalltalk.send(smalltalk.send(self, "_collection", []), "_size", [])])])]);
  8078. smalltalk.send(self, "_position_", [((($receiver = smalltalk.send(self, "_position", [])).klass === smalltalk.Number) ? $receiver +smalltalk.send(aString, "_size", []) : smalltalk.send($receiver, "__plus", [smalltalk.send(aString, "_size", [])]))]);
  8079. smalltalk.send(self, "_setStreamSize_", [smalltalk.send(smalltalk.send(self, "_streamSize", []), "_max_", [smalltalk.send(self, "_position", [])])]);
  8080. return self;},
  8081. args: ["aString"],
  8082. source: unescape('nextPutAll%3A%20aString%0A%09self%20setCollection%3A%20%0A%09%20%20%20%20%28self%20collection%20copyFrom%3A%201%20to%3A%20self%20position%29%2C%0A%09%20%20%20%20aString%2C%0A%09%20%20%20%20%28self%20collection%20copyFrom%3A%20%28self%20position%20+%201%20+%20aString%20size%29%20to%3A%20self%20collection%20size%29.%0A%09self%20position%3A%20self%20position%20+%20aString%20size.%0A%09self%20setStreamSize%3A%20%28self%20streamSize%20max%3A%20self%20position%29'),
  8083. messageSends: ["setCollection:", unescape("%2C"), "copyFrom:to:", "collection", "position", unescape("+"), "size", "position:", "setStreamSize:", "max:", "streamSize"],
  8084. referencedClasses: []
  8085. }),
  8086. smalltalk.StringStream);
  8087. smalltalk.addMethod(
  8088. unescape('_cr'),
  8089. smalltalk.method({
  8090. selector: unescape('cr'),
  8091. category: 'writing',
  8092. fn: function (){
  8093. var self=this;
  8094. return smalltalk.send(self, "_nextPutAll_", [smalltalk.send((smalltalk.String || String), "_cr", [])]);
  8095. return self;},
  8096. args: [],
  8097. source: unescape('cr%0A%09%5Eself%20nextPutAll%3A%20String%20cr'),
  8098. messageSends: ["nextPutAll:", "cr"],
  8099. referencedClasses: ["String"]
  8100. }),
  8101. smalltalk.StringStream);
  8102. smalltalk.addMethod(
  8103. unescape('_crlf'),
  8104. smalltalk.method({
  8105. selector: unescape('crlf'),
  8106. category: 'writing',
  8107. fn: function (){
  8108. var self=this;
  8109. return smalltalk.send(self, "_nextPutAll_", [smalltalk.send((smalltalk.String || String), "_crlf", [])]);
  8110. return self;},
  8111. args: [],
  8112. source: unescape('crlf%0A%09%5Eself%20nextPutAll%3A%20String%20crlf'),
  8113. messageSends: ["nextPutAll:", "crlf"],
  8114. referencedClasses: ["String"]
  8115. }),
  8116. smalltalk.StringStream);
  8117. smalltalk.addMethod(
  8118. unescape('_lf'),
  8119. smalltalk.method({
  8120. selector: unescape('lf'),
  8121. category: 'writing',
  8122. fn: function (){
  8123. var self=this;
  8124. return smalltalk.send(self, "_nextPutAll_", [smalltalk.send((smalltalk.String || String), "_lf", [])]);
  8125. return self;},
  8126. args: [],
  8127. source: unescape('lf%0A%09%5Eself%20nextPutAll%3A%20String%20lf'),
  8128. messageSends: ["nextPutAll:", "lf"],
  8129. referencedClasses: ["String"]
  8130. }),
  8131. smalltalk.StringStream);
  8132. smalltalk.addMethod(
  8133. unescape('_space'),
  8134. smalltalk.method({
  8135. selector: unescape('space'),
  8136. category: 'writing',
  8137. fn: function (){
  8138. var self=this;
  8139. smalltalk.send(self, "_nextPut_", [" "]);
  8140. return self;},
  8141. args: [],
  8142. source: unescape('space%0A%09self%20nextPut%3A%20%27%20%27'),
  8143. messageSends: ["nextPut:"],
  8144. referencedClasses: []
  8145. }),
  8146. smalltalk.StringStream);
  8147. smalltalk.addClass('ClassCommentReader', smalltalk.Object, ['class', 'chunkParser'], 'Kernel');
  8148. smalltalk.addMethod(
  8149. unescape('_class_'),
  8150. smalltalk.method({
  8151. selector: unescape('class%3A'),
  8152. category: 'accessing',
  8153. fn: function (aClass){
  8154. var self=this;
  8155. self['@class']=aClass;
  8156. return self;},
  8157. args: ["aClass"],
  8158. source: unescape('class%3A%20aClass%0A%09class%20%3A%3D%20aClass'),
  8159. messageSends: [],
  8160. referencedClasses: []
  8161. }),
  8162. smalltalk.ClassCommentReader);
  8163. smalltalk.addMethod(
  8164. unescape('_scanFrom_'),
  8165. smalltalk.method({
  8166. selector: unescape('scanFrom%3A'),
  8167. category: 'fileIn',
  8168. fn: function (aChunkParser){
  8169. var self=this;
  8170. var chunk=nil;
  8171. chunk=smalltalk.send(aChunkParser, "_nextChunk", []);
  8172. ((($receiver = smalltalk.send(chunk, "_isEmpty", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_setComment_", [chunk]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(self, "_setComment_", [chunk]);})]));
  8173. return self;},
  8174. args: ["aChunkParser"],
  8175. source: unescape('scanFrom%3A%20aChunkParser%0A%09%7C%20chunk%20%7C%0A%09chunk%20%3A%3D%20aChunkParser%20nextChunk.%0A%09chunk%20isEmpty%20ifFalse%3A%20%5B%0A%09%20%20%20%20self%20setComment%3A%20chunk%5D.'),
  8176. messageSends: ["nextChunk", "ifFalse:", "isEmpty", "setComment:"],
  8177. referencedClasses: []
  8178. }),
  8179. smalltalk.ClassCommentReader);
  8180. smalltalk.addMethod(
  8181. unescape('_initialize'),
  8182. smalltalk.method({
  8183. selector: unescape('initialize'),
  8184. category: 'initialization',
  8185. fn: function (){
  8186. var self=this;
  8187. smalltalk.send(self, "_initialize", [], smalltalk.Object);
  8188. self['@chunkParser']=smalltalk.send((smalltalk.ChunkParser || ChunkParser), "_new", []);
  8189. return self;},
  8190. args: [],
  8191. source: unescape('initialize%0A%09super%20initialize.%0A%09chunkParser%20%3A%3D%20ChunkParser%20new.'),
  8192. messageSends: ["initialize", "new"],
  8193. referencedClasses: ["ChunkParser"]
  8194. }),
  8195. smalltalk.ClassCommentReader);
  8196. smalltalk.addMethod(
  8197. unescape('_setComment_'),
  8198. smalltalk.method({
  8199. selector: unescape('setComment%3A'),
  8200. category: 'private',
  8201. fn: function (aString){
  8202. var self=this;
  8203. smalltalk.send(self['@class'], "_comment_", [aString]);
  8204. return self;},
  8205. args: ["aString"],
  8206. source: unescape('setComment%3A%20aString%0A%20%20%20%20class%20comment%3A%20aString'),
  8207. messageSends: ["comment:"],
  8208. referencedClasses: []
  8209. }),
  8210. smalltalk.ClassCommentReader);
  8211. smalltalk.addClass('Random', smalltalk.Object, [], 'Kernel');
  8212. smalltalk.addMethod(
  8213. unescape('_next'),
  8214. smalltalk.method({
  8215. selector: unescape('next'),
  8216. category: 'accessing',
  8217. fn: function (){
  8218. var self=this;
  8219. return Math.random();
  8220. return self;},
  8221. args: [],
  8222. source: unescape('next%0A%09%3Creturn%20Math.random%28%29%3E'),
  8223. messageSends: [],
  8224. referencedClasses: []
  8225. }),
  8226. smalltalk.Random);
  8227. smalltalk.addMethod(
  8228. unescape('_next_'),
  8229. smalltalk.method({
  8230. selector: unescape('next%3A'),
  8231. category: 'accessing',
  8232. fn: function (anInteger){
  8233. var self=this;
  8234. return smalltalk.send(smalltalk.send((1), "_to_", [anInteger]), "_collect_", [(function(each){return smalltalk.send(self, "_next", []);})]);
  8235. return self;},
  8236. args: ["anInteger"],
  8237. source: unescape('next%3A%20anInteger%0A%20%20%20%20%5E%281%20to%3A%20anInteger%29%20collect%3A%20%5B%3Aeach%20%7C%20self%20next%5D'),
  8238. messageSends: ["collect:", "to:", "next"],
  8239. referencedClasses: []
  8240. }),
  8241. smalltalk.Random);
  8242. smalltalk.addClass('Point', smalltalk.Object, ['x', 'y'], 'Kernel');
  8243. smalltalk.addMethod(
  8244. unescape('_x'),
  8245. smalltalk.method({
  8246. selector: unescape('x'),
  8247. category: 'accessing',
  8248. fn: function (){
  8249. var self=this;
  8250. return self['@x'];
  8251. return self;},
  8252. args: [],
  8253. source: unescape('x%0A%09%5Ex'),
  8254. messageSends: [],
  8255. referencedClasses: []
  8256. }),
  8257. smalltalk.Point);
  8258. smalltalk.addMethod(
  8259. unescape('_y'),
  8260. smalltalk.method({
  8261. selector: unescape('y'),
  8262. category: 'accessing',
  8263. fn: function (){
  8264. var self=this;
  8265. return self['@y'];
  8266. return self;},
  8267. args: [],
  8268. source: unescape('y%0A%09%5Ey'),
  8269. messageSends: [],
  8270. referencedClasses: []
  8271. }),
  8272. smalltalk.Point);
  8273. smalltalk.addMethod(
  8274. unescape('_y_'),
  8275. smalltalk.method({
  8276. selector: unescape('y%3A'),
  8277. category: 'accessing',
  8278. fn: function (aNumber){
  8279. var self=this;
  8280. self['@y']=aNumber;
  8281. return self;},
  8282. args: ["aNumber"],
  8283. source: unescape('y%3A%20aNumber%0A%09y%20%3A%3D%20aNumber'),
  8284. messageSends: [],
  8285. referencedClasses: []
  8286. }),
  8287. smalltalk.Point);
  8288. smalltalk.addMethod(
  8289. unescape('_x_'),
  8290. smalltalk.method({
  8291. selector: unescape('x%3A'),
  8292. category: 'accessing',
  8293. fn: function (aNumber){
  8294. var self=this;
  8295. self['@x']=aNumber;
  8296. return self;},
  8297. args: ["aNumber"],
  8298. source: unescape('x%3A%20aNumber%0A%09x%20%3A%3D%20aNumber'),
  8299. messageSends: [],
  8300. referencedClasses: []
  8301. }),
  8302. smalltalk.Point);
  8303. smalltalk.addMethod(
  8304. unescape('__star'),
  8305. smalltalk.method({
  8306. selector: unescape('*'),
  8307. category: 'arithmetic',
  8308. fn: function (aPoint){
  8309. var self=this;
  8310. return smalltalk.send((smalltalk.Point || Point), "_x_y_", [((($receiver = smalltalk.send(self, "_x", [])).klass === smalltalk.Number) ? $receiver *smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", []) : smalltalk.send($receiver, "__star", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", [])])), ((($receiver = smalltalk.send(self, "_y", [])).klass === smalltalk.Number) ? $receiver *smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", []) : smalltalk.send($receiver, "__star", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", [])]))]);
  8311. return self;},
  8312. args: ["aPoint"],
  8313. source: unescape('*%20aPoint%0A%09%5EPoint%20x%3A%20self%20x%20*%20aPoint%20asPoint%20x%20y%3A%20self%20y%20*%20aPoint%20asPoint%20y'),
  8314. messageSends: ["x:y:", unescape("*"), "x", "asPoint", "y"],
  8315. referencedClasses: ["Point"]
  8316. }),
  8317. smalltalk.Point);
  8318. smalltalk.addMethod(
  8319. unescape('__plus'),
  8320. smalltalk.method({
  8321. selector: unescape('+'),
  8322. category: 'arithmetic',
  8323. fn: function (aPoint){
  8324. var self=this;
  8325. return smalltalk.send((smalltalk.Point || Point), "_x_y_", [((($receiver = smalltalk.send(self, "_x", [])).klass === smalltalk.Number) ? $receiver +smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", []) : smalltalk.send($receiver, "__plus", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", [])])), ((($receiver = smalltalk.send(self, "_y", [])).klass === smalltalk.Number) ? $receiver +smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", []) : smalltalk.send($receiver, "__plus", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", [])]))]);
  8326. return self;},
  8327. args: ["aPoint"],
  8328. source: unescape('+%20aPoint%0A%09%5EPoint%20x%3A%20self%20x%20+%20aPoint%20asPoint%20x%20y%3A%20self%20y%20+%20aPoint%20asPoint%20y'),
  8329. messageSends: ["x:y:", unescape("+"), "x", "asPoint", "y"],
  8330. referencedClasses: ["Point"]
  8331. }),
  8332. smalltalk.Point);
  8333. smalltalk.addMethod(
  8334. unescape('__minus'),
  8335. smalltalk.method({
  8336. selector: unescape('-'),
  8337. category: 'arithmetic',
  8338. fn: function (aPoint){
  8339. var self=this;
  8340. return smalltalk.send((smalltalk.Point || Point), "_x_y_", [((($receiver = smalltalk.send(self, "_x", [])).klass === smalltalk.Number) ? $receiver -smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", []) : smalltalk.send($receiver, "__minus", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", [])])), ((($receiver = smalltalk.send(self, "_y", [])).klass === smalltalk.Number) ? $receiver -smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", []) : smalltalk.send($receiver, "__minus", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", [])]))]);
  8341. return self;},
  8342. args: ["aPoint"],
  8343. source: unescape('-%20aPoint%0A%09%5EPoint%20x%3A%20self%20x%20-%20aPoint%20asPoint%20x%20y%3A%20self%20y%20-%20aPoint%20asPoint%20y'),
  8344. messageSends: ["x:y:", unescape("-"), "x", "asPoint", "y"],
  8345. referencedClasses: ["Point"]
  8346. }),
  8347. smalltalk.Point);
  8348. smalltalk.addMethod(
  8349. unescape('__slash'),
  8350. smalltalk.method({
  8351. selector: unescape('/'),
  8352. category: 'arithmetic',
  8353. fn: function (aPoint){
  8354. var self=this;
  8355. return smalltalk.send((smalltalk.Point || Point), "_x_y_", [((($receiver = smalltalk.send(self, "_x", [])).klass === smalltalk.Number) ? $receiver /smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", []) : smalltalk.send($receiver, "__slash", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_x", [])])), ((($receiver = smalltalk.send(self, "_y", [])).klass === smalltalk.Number) ? $receiver /smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", []) : smalltalk.send($receiver, "__slash", [smalltalk.send(smalltalk.send(aPoint, "_asPoint", []), "_y", [])]))]);
  8356. return self;},
  8357. args: ["aPoint"],
  8358. source: unescape('/%20aPoint%0A%09%5EPoint%20x%3A%20self%20x%20/%20aPoint%20asPoint%20x%20y%3A%20self%20y%20/%20aPoint%20asPoint%20y'),
  8359. messageSends: ["x:y:", unescape("/"), "x", "asPoint", "y"],
  8360. referencedClasses: ["Point"]
  8361. }),
  8362. smalltalk.Point);
  8363. smalltalk.addMethod(
  8364. unescape('_asPoint'),
  8365. smalltalk.method({
  8366. selector: unescape('asPoint'),
  8367. category: 'converting',
  8368. fn: function (){
  8369. var self=this;
  8370. return self;
  8371. return self;},
  8372. args: [],
  8373. source: unescape('asPoint%0A%09%5Eself'),
  8374. messageSends: [],
  8375. referencedClasses: []
  8376. }),
  8377. smalltalk.Point);
  8378. smalltalk.addMethod(
  8379. unescape('__eq'),
  8380. smalltalk.method({
  8381. selector: unescape('%3D'),
  8382. category: 'arithmetic',
  8383. fn: function (aPoint){
  8384. var self=this;
  8385. return smalltalk.send(smalltalk.send(smalltalk.send(aPoint, "_class", []), "__eq", [smalltalk.send(self, "_class", [])]), "_and_", [(function(){return smalltalk.send(smalltalk.send(smalltalk.send(aPoint, "_x", []), "__eq", [smalltalk.send(self, "_x", [])]), "_&", [smalltalk.send(smalltalk.send(aPoint, "_y", []), "__eq", [smalltalk.send(self, "_y", [])])]);})]);
  8386. return self;},
  8387. args: ["aPoint"],
  8388. source: unescape('%3D%20aPoint%0A%09%5EaPoint%20class%20%3D%20self%20class%20and%3A%20%5B%0A%09%09%28aPoint%20x%20%3D%20self%20x%29%20%26%20%28aPoint%20y%20%3D%20self%20y%29%5D'),
  8389. messageSends: ["and:", unescape("%3D"), "class", unescape("%26"), "x", "y"],
  8390. referencedClasses: []
  8391. }),
  8392. smalltalk.Point);
  8393. smalltalk.addMethod(
  8394. unescape('_x_y_'),
  8395. smalltalk.method({
  8396. selector: unescape('x%3Ay%3A'),
  8397. category: 'instance creation',
  8398. fn: function (aNumber, anotherNumber){
  8399. var self=this;
  8400. return (function($rec){smalltalk.send($rec, "_x_", [aNumber]);smalltalk.send($rec, "_y_", [anotherNumber]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  8401. return self;},
  8402. args: ["aNumber", "anotherNumber"],
  8403. source: unescape('x%3A%20aNumber%20y%3A%20anotherNumber%0A%09%5Eself%20new%0A%09%09x%3A%20aNumber%3B%0A%09%09y%3A%20anotherNumber%3B%0A%09%09yourself'),
  8404. messageSends: ["x:", "y:", "yourself", "new"],
  8405. referencedClasses: []
  8406. }),
  8407. smalltalk.Point.klass);
  8408. smalltalk.addClass('Message', smalltalk.Object, ['selector', 'arguments'], 'Kernel');
  8409. smalltalk.addMethod(
  8410. unescape('_selector'),
  8411. smalltalk.method({
  8412. selector: unescape('selector'),
  8413. category: 'accessing',
  8414. fn: function (){
  8415. var self=this;
  8416. return self['@selector'];
  8417. return self;},
  8418. args: [],
  8419. source: unescape('selector%0A%09%5Eselector'),
  8420. messageSends: [],
  8421. referencedClasses: []
  8422. }),
  8423. smalltalk.Message);
  8424. smalltalk.addMethod(
  8425. unescape('_selector_'),
  8426. smalltalk.method({
  8427. selector: unescape('selector%3A'),
  8428. category: 'accessing',
  8429. fn: function (aString){
  8430. var self=this;
  8431. self['@selector']=aString;
  8432. return self;},
  8433. args: ["aString"],
  8434. source: unescape('selector%3A%20aString%0A%09selector%20%3A%3D%20aString'),
  8435. messageSends: [],
  8436. referencedClasses: []
  8437. }),
  8438. smalltalk.Message);
  8439. smalltalk.addMethod(
  8440. unescape('_arguments_'),
  8441. smalltalk.method({
  8442. selector: unescape('arguments%3A'),
  8443. category: 'accessing',
  8444. fn: function (anArray){
  8445. var self=this;
  8446. self['@arguments']=anArray;
  8447. return self;},
  8448. args: ["anArray"],
  8449. source: unescape('arguments%3A%20anArray%0A%09arguments%20%3A%3D%20anArray'),
  8450. messageSends: [],
  8451. referencedClasses: []
  8452. }),
  8453. smalltalk.Message);
  8454. smalltalk.addMethod(
  8455. unescape('_arguments'),
  8456. smalltalk.method({
  8457. selector: unescape('arguments'),
  8458. category: 'accessing',
  8459. fn: function (){
  8460. var self=this;
  8461. return self['@arguments'];
  8462. return self;},
  8463. args: [],
  8464. source: unescape('arguments%0A%09%5Earguments'),
  8465. messageSends: [],
  8466. referencedClasses: []
  8467. }),
  8468. smalltalk.Message);
  8469. smalltalk.addMethod(
  8470. unescape('_printString'),
  8471. smalltalk.method({
  8472. selector: unescape('printString'),
  8473. category: 'printing',
  8474. fn: function (){
  8475. var self=this;
  8476. return smalltalk.send((smalltalk.String || String), "_streamContents_", [(function(aStream){return (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self, "_printString", [], smalltalk.Object)]);smalltalk.send($rec, "_nextPutAll_", [unescape("%28")]);smalltalk.send($rec, "_nextPutAll_", [self['@selector']]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%29")]);})(aStream);})]);
  8477. return self;},
  8478. args: [],
  8479. source: unescape('printString%0A%09%5E%20String%20streamContents%3A%20%5B%3AaStream%7C%20%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09%09aStream%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09%09%09nextPutAll%3A%20super%20printString%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09%09%09nextPutAll%3A%20%27%28%27%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09%09%09nextPutAll%3A%20selector%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09%09%09nextPutAll%3A%20%27%29%27%20%09%09%09%09%5D'),
  8480. messageSends: ["streamContents:", "nextPutAll:", "printString"],
  8481. referencedClasses: ["String"]
  8482. }),
  8483. smalltalk.Message);
  8484. smalltalk.addMethod(
  8485. unescape('_selector_arguments_'),
  8486. smalltalk.method({
  8487. selector: unescape('selector%3Aarguments%3A'),
  8488. category: 'instance creation',
  8489. fn: function (aString, anArray){
  8490. var self=this;
  8491. return (function($rec){smalltalk.send($rec, "_selector_", [aString]);smalltalk.send($rec, "_arguments_", [anArray]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  8492. return self;},
  8493. args: ["aString", "anArray"],
  8494. source: unescape('selector%3A%20aString%20arguments%3A%20anArray%0A%09%5Eself%20new%0A%09%09selector%3A%20aString%3B%0A%09%09arguments%3A%20anArray%3B%0A%09%09yourself'),
  8495. messageSends: ["selector:", "arguments:", "yourself", "new"],
  8496. referencedClasses: []
  8497. }),
  8498. smalltalk.Message.klass);
  8499. smalltalk.addClass('MessageNotUnderstood', smalltalk.Error, ['message', 'receiver'], 'Kernel');
  8500. smalltalk.addMethod(
  8501. unescape('_message'),
  8502. smalltalk.method({
  8503. selector: unescape('message'),
  8504. category: 'accessing',
  8505. fn: function (){
  8506. var self=this;
  8507. return self['@message'];
  8508. return self;},
  8509. args: [],
  8510. source: unescape('message%0A%09%5Emessage'),
  8511. messageSends: [],
  8512. referencedClasses: []
  8513. }),
  8514. smalltalk.MessageNotUnderstood);
  8515. smalltalk.addMethod(
  8516. unescape('_message_'),
  8517. smalltalk.method({
  8518. selector: unescape('message%3A'),
  8519. category: 'accessing',
  8520. fn: function (aMessage){
  8521. var self=this;
  8522. self['@message']=aMessage;
  8523. return self;},
  8524. args: ["aMessage"],
  8525. source: unescape('message%3A%20aMessage%0A%09message%20%3A%3D%20aMessage'),
  8526. messageSends: [],
  8527. referencedClasses: []
  8528. }),
  8529. smalltalk.MessageNotUnderstood);
  8530. smalltalk.addMethod(
  8531. unescape('_receiver'),
  8532. smalltalk.method({
  8533. selector: unescape('receiver'),
  8534. category: 'accessing',
  8535. fn: function (){
  8536. var self=this;
  8537. return self['@receiver'];
  8538. return self;},
  8539. args: [],
  8540. source: unescape('receiver%0A%09%5Ereceiver'),
  8541. messageSends: [],
  8542. referencedClasses: []
  8543. }),
  8544. smalltalk.MessageNotUnderstood);
  8545. smalltalk.addMethod(
  8546. unescape('_receiver_'),
  8547. smalltalk.method({
  8548. selector: unescape('receiver%3A'),
  8549. category: 'accessing',
  8550. fn: function (anObject){
  8551. var self=this;
  8552. self['@receiver']=anObject;
  8553. return self;},
  8554. args: ["anObject"],
  8555. source: unescape('receiver%3A%20anObject%0A%09receiver%20%3A%3D%20anObject'),
  8556. messageSends: [],
  8557. referencedClasses: []
  8558. }),
  8559. smalltalk.MessageNotUnderstood);
  8560. smalltalk.addMethod(
  8561. unescape('_messageText'),
  8562. smalltalk.method({
  8563. selector: unescape('messageText'),
  8564. category: 'accessing',
  8565. fn: function (){
  8566. var self=this;
  8567. return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(self, "_receiver", []), "_asString", []), "__comma", [unescape("%20does%20not%20understand%20%23")]), "__comma", [smalltalk.send(smalltalk.send(self, "_message", []), "_selector", [])]);
  8568. return self;},
  8569. args: [],
  8570. source: unescape('messageText%0A%09%5Eself%20receiver%20asString%2C%20%27%20does%20not%20understand%20%23%27%2C%20self%20message%20selector'),
  8571. messageSends: [unescape("%2C"), "asString", "receiver", "selector", "message"],
  8572. referencedClasses: []
  8573. }),
  8574. smalltalk.MessageNotUnderstood);
  8575. smalltalk.addClass('ErrorHandler', smalltalk.Object, [], 'Kernel');
  8576. smalltalk.addMethod(
  8577. unescape('_handleError_'),
  8578. smalltalk.method({
  8579. selector: unescape('handleError%3A'),
  8580. category: 'error handling',
  8581. fn: function (anError){
  8582. var self=this;
  8583. (($receiver = smalltalk.send(anError, "_context", [])) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self, "_logErrorContext_", [smalltalk.send(anError, "_context", [])]);})() : nil;
  8584. smalltalk.send(self, "_logError_", [anError]);
  8585. return self;},
  8586. args: ["anError"],
  8587. source: unescape('handleError%3A%20anError%0A%09anError%20context%20ifNotNil%3A%20%5Bself%20logErrorContext%3A%20anError%20context%5D.%0A%09self%20logError%3A%20anError'),
  8588. messageSends: ["ifNotNil:", "context", "logErrorContext:", "logError:"],
  8589. referencedClasses: []
  8590. }),
  8591. smalltalk.ErrorHandler);
  8592. smalltalk.addMethod(
  8593. unescape('_logContext_'),
  8594. smalltalk.method({
  8595. selector: unescape('logContext%3A'),
  8596. category: 'private',
  8597. fn: function (aContext){
  8598. var self=this;
  8599. (($receiver = smalltalk.send(aContext, "_home", [])) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self, "_logContext_", [smalltalk.send(aContext, "_home", [])]);})() : nil;
  8600. smalltalk.send(self, "_log_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(aContext, "_receiver", []), "_asString", []), "__comma", [unescape("%3E%3E")]), "__comma", [smalltalk.send(aContext, "_selector", [])])]);
  8601. return self;},
  8602. args: ["aContext"],
  8603. source: unescape('logContext%3A%20aContext%0A%09aContext%20home%20ifNotNil%3A%20%5B%0A%09%09self%20logContext%3A%20aContext%20home%5D.%0A%09self%20log%3A%20aContext%20receiver%20asString%2C%20%27%3E%3E%27%2C%20aContext%20selector'),
  8604. messageSends: ["ifNotNil:", "home", "logContext:", "log:", unescape("%2C"), "asString", "receiver", "selector"],
  8605. referencedClasses: []
  8606. }),
  8607. smalltalk.ErrorHandler);
  8608. smalltalk.addMethod(
  8609. unescape('_logErrorContext_'),
  8610. smalltalk.method({
  8611. selector: unescape('logErrorContext%3A'),
  8612. category: 'private',
  8613. fn: function (aContext){
  8614. var self=this;
  8615. (($receiver = aContext) != nil && $receiver != undefined) ? (function(){return (($receiver = smalltalk.send(aContext, "_home", [])) != nil && $receiver != undefined) ? (function(){return smalltalk.send(self, "_logContext_", [smalltalk.send(aContext, "_home", [])]);})() : nil;})() : nil;
  8616. return self;},
  8617. args: ["aContext"],
  8618. source: unescape('logErrorContext%3A%20aContext%0A%09aContext%20ifNotNil%3A%20%5B%0A%09%09aContext%20home%20ifNotNil%3A%20%5B%0A%09%09%09self%20logContext%3A%20aContext%20home%5D%5D'),
  8619. messageSends: ["ifNotNil:", "home", "logContext:"],
  8620. referencedClasses: []
  8621. }),
  8622. smalltalk.ErrorHandler);
  8623. smalltalk.addMethod(
  8624. unescape('_logError_'),
  8625. smalltalk.method({
  8626. selector: unescape('logError%3A'),
  8627. category: 'private',
  8628. fn: function (anError){
  8629. var self=this;
  8630. smalltalk.send(self, "_log_", [smalltalk.send(anError, "_messageText", [])]);
  8631. return self;},
  8632. args: ["anError"],
  8633. source: unescape('logError%3A%20anError%0A%09self%20log%3A%20anError%20messageText'),
  8634. messageSends: ["log:", "messageText"],
  8635. referencedClasses: []
  8636. }),
  8637. smalltalk.ErrorHandler);
  8638. smalltalk.addMethod(
  8639. unescape('_log_'),
  8640. smalltalk.method({
  8641. selector: unescape('log%3A'),
  8642. category: 'private',
  8643. fn: function (aString){
  8644. var self=this;
  8645. smalltalk.send((typeof console == 'undefined' ? nil : console), "_log_", [aString]);
  8646. return self;},
  8647. args: ["aString"],
  8648. source: unescape('log%3A%20aString%0A%09console%20log%3A%20aString'),
  8649. messageSends: ["log:"],
  8650. referencedClasses: []
  8651. }),
  8652. smalltalk.ErrorHandler);
  8653. smalltalk.ErrorHandler.klass.iVarNames = ['current'];
  8654. smalltalk.addMethod(
  8655. unescape('_current'),
  8656. smalltalk.method({
  8657. selector: unescape('current'),
  8658. category: 'accessing',
  8659. fn: function (){
  8660. var self=this;
  8661. return (($receiver = self['@current']) == nil || $receiver == undefined) ? (function(){return self['@current']=smalltalk.send(self, "_new", []);})() : $receiver;
  8662. return self;},
  8663. args: [],
  8664. source: unescape('current%0A%09%5Ecurrent%20ifNil%3A%20%5Bcurrent%20%3A%3D%20self%20new%5D'),
  8665. messageSends: ["ifNil:", "new"],
  8666. referencedClasses: []
  8667. }),
  8668. smalltalk.ErrorHandler.klass);
  8669. smalltalk.addMethod(
  8670. unescape('_initialize'),
  8671. smalltalk.method({
  8672. selector: unescape('initialize'),
  8673. category: 'initialization',
  8674. fn: function (){
  8675. var self=this;
  8676. smalltalk.send(self, "_register", []);
  8677. return self;},
  8678. args: [],
  8679. source: unescape('initialize%0A%09self%20register'),
  8680. messageSends: ["register"],
  8681. referencedClasses: []
  8682. }),
  8683. smalltalk.ErrorHandler.klass);
  8684. smalltalk.addMethod(
  8685. unescape('_register'),
  8686. smalltalk.method({
  8687. selector: unescape('register'),
  8688. category: 'initialization',
  8689. fn: function (){
  8690. var self=this;
  8691. smalltalk.send((smalltalk.ErrorHandler || ErrorHandler), "_setCurrent_", [smalltalk.send(self, "_new", [])]);
  8692. return self;},
  8693. args: [],
  8694. source: unescape('register%0A%09ErrorHandler%20setCurrent%3A%20self%20new'),
  8695. messageSends: ["setCurrent:", "new"],
  8696. referencedClasses: ["ErrorHandler"]
  8697. }),
  8698. smalltalk.ErrorHandler.klass);
  8699. smalltalk.addMethod(
  8700. unescape('_setCurrent_'),
  8701. smalltalk.method({
  8702. selector: unescape('setCurrent%3A'),
  8703. category: 'accessing',
  8704. fn: function (anHandler){
  8705. var self=this;
  8706. self['@current']=anHandler;
  8707. return self;},
  8708. args: ["anHandler"],
  8709. source: unescape('setCurrent%3A%20anHandler%0A%09current%20%3A%3D%20anHandler'),
  8710. messageSends: [],
  8711. referencedClasses: []
  8712. }),
  8713. smalltalk.ErrorHandler.klass);
  8714. smalltalk.addClass('JSObjectProxy', smalltalk.Object, ['jsObject'], 'Kernel');
  8715. smalltalk.addMethod(
  8716. unescape('_jsObject_'),
  8717. smalltalk.method({
  8718. selector: unescape('jsObject%3A'),
  8719. category: 'accessing',
  8720. fn: function (aJSObject){
  8721. var self=this;
  8722. self['@jsObject']=aJSObject;
  8723. return self;},
  8724. args: ["aJSObject"],
  8725. source: unescape('jsObject%3A%20aJSObject%0A%09jsObject%20%3A%3D%20aJSObject'),
  8726. messageSends: [],
  8727. referencedClasses: []
  8728. }),
  8729. smalltalk.JSObjectProxy);
  8730. smalltalk.addMethod(
  8731. unescape('_jsObject'),
  8732. smalltalk.method({
  8733. selector: unescape('jsObject'),
  8734. category: 'accessing',
  8735. fn: function (){
  8736. var self=this;
  8737. return self['@jsObject'];
  8738. return self;},
  8739. args: [],
  8740. source: unescape('jsObject%0A%09%5EjsObject'),
  8741. messageSends: [],
  8742. referencedClasses: []
  8743. }),
  8744. smalltalk.JSObjectProxy);
  8745. smalltalk.addMethod(
  8746. unescape('_printString'),
  8747. smalltalk.method({
  8748. selector: unescape('printString'),
  8749. category: 'proxy',
  8750. fn: function (){
  8751. var self=this;
  8752. return smalltalk.send(smalltalk.send(self, "_jsObject", []), "_toString", []);
  8753. return self;},
  8754. args: [],
  8755. source: unescape('printString%0A%09%5Eself%20jsObject%20toString'),
  8756. messageSends: ["toString", "jsObject"],
  8757. referencedClasses: []
  8758. }),
  8759. smalltalk.JSObjectProxy);
  8760. smalltalk.addMethod(
  8761. unescape('_inspectOn_'),
  8762. smalltalk.method({
  8763. selector: unescape('inspectOn%3A'),
  8764. category: 'proxy',
  8765. fn: function (anInspector){
  8766. var self=this;
  8767. var variables=nil;
  8768. variables=smalltalk.send((smalltalk.Dictionary || Dictionary), "_new", []);
  8769. smalltalk.send(variables, "_at_put_", [unescape("%23self"), smalltalk.send(self, "_jsObject", [])]);
  8770. smalltalk.send(anInspector, "_setLabel_", [smalltalk.send(self, "_printString", [])]);
  8771. for(var i in self['@jsObject']) {
  8772. variables._at_put_(i, self['@jsObject'][i]);
  8773. };
  8774. smalltalk.send(anInspector, "_setVariables_", [variables]);
  8775. return self;},
  8776. args: ["anInspector"],
  8777. source: unescape('inspectOn%3A%20anInspector%0A%09%7C%20variables%20%7C%0A%09variables%20%3A%3D%20Dictionary%20new.%0A%09variables%20at%3A%20%27%23self%27%20put%3A%20self%20jsObject.%0A%09anInspector%20setLabel%3A%20self%20printString.%0A%09%3Cfor%28var%20i%20in%20self%5B%27@jsObject%27%5D%29%20%7B%0A%09%09variables._at_put_%28i%2C%20self%5B%27@jsObject%27%5D%5Bi%5D%29%3B%0A%09%7D%3E.%0A%09anInspector%20setVariables%3A%20variables'),
  8778. messageSends: ["new", "at:put:", "jsObject", "setLabel:", "printString", "setVariables:"],
  8779. referencedClasses: ["Dictionary"]
  8780. }),
  8781. smalltalk.JSObjectProxy);
  8782. smalltalk.addMethod(
  8783. unescape('_doesNotUnderstand_'),
  8784. smalltalk.method({
  8785. selector: unescape('doesNotUnderstand%3A'),
  8786. category: 'proxy',
  8787. fn: function (aMessage){
  8788. var self=this;
  8789. var obj=nil;
  8790. var selector=nil;
  8791. var jsSelector=nil;
  8792. var arguments=nil;
  8793. obj=smalltalk.send(self, "_jsObject", []);
  8794. selector=smalltalk.send(aMessage, "_selector", []);
  8795. jsSelector=smalltalk.send(selector, "_asJavaScriptSelector", []);
  8796. arguments=smalltalk.send(aMessage, "_arguments", []);
  8797. if(obj[jsSelector] != undefined) {return smalltalk.send(obj, jsSelector, arguments)};
  8798. smalltalk.send(self, "_doesNotUnderstand_", [aMessage], smalltalk.Object);
  8799. return self;},
  8800. args: ["aMessage"],
  8801. source: unescape('doesNotUnderstand%3A%20aMessage%0A%09%7C%20obj%20selector%20jsSelector%20arguments%20%7C%0A%09obj%20%3A%3D%20self%20jsObject.%0A%09selector%20%3A%3D%20aMessage%20selector.%0A%09jsSelector%20%3A%3D%20selector%20asJavaScriptSelector.%0A%09arguments%20%3A%3D%20aMessage%20arguments.%0A%09%3Cif%28obj%5BjsSelector%5D%20%21%3D%20undefined%29%20%7Breturn%20smalltalk.send%28obj%2C%20jsSelector%2C%20arguments%29%7D%3E.%0A%09super%20doesNotUnderstand%3A%20aMessage'),
  8802. messageSends: ["jsObject", "selector", "asJavaScriptSelector", "arguments", "doesNotUnderstand:"],
  8803. referencedClasses: []
  8804. }),
  8805. smalltalk.JSObjectProxy);
  8806. smalltalk.addMethod(
  8807. unescape('_at_'),
  8808. smalltalk.method({
  8809. selector: unescape('at%3A'),
  8810. category: 'accessing',
  8811. fn: function (aString){
  8812. var self=this;
  8813. return self['@jsObject'][aString];
  8814. return self;},
  8815. args: ["aString"],
  8816. source: unescape('at%3A%20aString%0A%09%3Creturn%20self%5B%27@jsObject%27%5D%5BaString%5D%3E'),
  8817. messageSends: [],
  8818. referencedClasses: []
  8819. }),
  8820. smalltalk.JSObjectProxy);
  8821. smalltalk.addMethod(
  8822. unescape('_at_put_'),
  8823. smalltalk.method({
  8824. selector: unescape('at%3Aput%3A'),
  8825. category: 'accessing',
  8826. fn: function (aString, anObject){
  8827. var self=this;
  8828. self['@jsObject'][aString] = anObject;
  8829. return self;},
  8830. args: ["aString", "anObject"],
  8831. source: unescape('at%3A%20aString%20put%3A%20anObject%0A%09%3Cself%5B%27@jsObject%27%5D%5BaString%5D%20%3D%20anObject%3E'),
  8832. messageSends: [],
  8833. referencedClasses: []
  8834. }),
  8835. smalltalk.JSObjectProxy);
  8836. smalltalk.addMethod(
  8837. unescape('_on_'),
  8838. smalltalk.method({
  8839. selector: unescape('on%3A'),
  8840. category: 'instance creation',
  8841. fn: function (aJSObject){
  8842. var self=this;
  8843. return (function($rec){smalltalk.send($rec, "_jsObject_", [aJSObject]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_new", []));
  8844. return self;},
  8845. args: ["aJSObject"],
  8846. source: unescape('on%3A%20aJSObject%0A%09%5Eself%20new%0A%09%09jsObject%3A%20aJSObject%3B%0A%09%09yourself'),
  8847. messageSends: ["jsObject:", "yourself", "new"],
  8848. referencedClasses: []
  8849. }),
  8850. smalltalk.JSObjectProxy.klass);
  8851. smalltalk.addClass('Set', smalltalk.Collection, ['elements'], 'Kernel');
  8852. smalltalk.addMethod(
  8853. unescape('_add_'),
  8854. smalltalk.method({
  8855. selector: unescape('add%3A'),
  8856. category: 'adding/removing',
  8857. fn: function (anObject){
  8858. var self=this;
  8859. var found;
  8860. for(var i in self['@elements']) {
  8861. if(anObject == self['@elements'][i]) {
  8862. found = true;
  8863. break;
  8864. }
  8865. }
  8866. if(!found) {self['@elements'].push(anObject)}
  8867. ;
  8868. return self;},
  8869. args: ["anObject"],
  8870. source: unescape('add%3A%20anObject%0A%09%3C%0A%09%09var%20found%3B%0A%09%09for%28var%20i%20in%20self%5B%27@elements%27%5D%29%20%7B%0A%09%09%09if%28anObject%20%3D%3D%20self%5B%27@elements%27%5D%5Bi%5D%29%20%7B%0A%09%09%09%09found%20%3D%20true%3B%0A%09%09%09%09break%3B%0A%09%09%09%7D%0A%09%09%7D%0A%09%09if%28%21found%29%20%7Bself%5B%27@elements%27%5D.push%28anObject%29%7D%0A%09%3E'),
  8871. messageSends: [],
  8872. referencedClasses: []
  8873. }),
  8874. smalltalk.Set);
  8875. smalltalk.addMethod(
  8876. unescape('_remove_'),
  8877. smalltalk.method({
  8878. selector: unescape('remove%3A'),
  8879. category: 'adding/removing',
  8880. fn: function (anObject){
  8881. var self=this;
  8882. smalltalk.send(self['@elements'], "_remove_", [anObject]);
  8883. return self;},
  8884. args: ["anObject"],
  8885. source: unescape('remove%3A%20anObject%0A%09elements%20remove%3A%20anObject'),
  8886. messageSends: ["remove:"],
  8887. referencedClasses: []
  8888. }),
  8889. smalltalk.Set);
  8890. smalltalk.addMethod(
  8891. unescape('_initialize'),
  8892. smalltalk.method({
  8893. selector: unescape('initialize'),
  8894. category: 'initialization',
  8895. fn: function (){
  8896. var self=this;
  8897. smalltalk.send(self, "_initialize", [], smalltalk.Collection);
  8898. self['@elements']=[];
  8899. return self;},
  8900. args: [],
  8901. source: unescape('initialize%0A%09super%20initialize.%0A%09elements%20%3A%3D%20%23%28%29'),
  8902. messageSends: ["initialize"],
  8903. referencedClasses: []
  8904. }),
  8905. smalltalk.Set);
  8906. smalltalk.addMethod(
  8907. unescape('_size'),
  8908. smalltalk.method({
  8909. selector: unescape('size'),
  8910. category: 'accessing',
  8911. fn: function (){
  8912. var self=this;
  8913. return smalltalk.send(self['@elements'], "_size", []);
  8914. return self;},
  8915. args: [],
  8916. source: unescape('size%0A%09%5Eelements%20size'),
  8917. messageSends: ["size"],
  8918. referencedClasses: []
  8919. }),
  8920. smalltalk.Set);
  8921. smalltalk.addMethod(
  8922. unescape('_asArray'),
  8923. smalltalk.method({
  8924. selector: unescape('asArray'),
  8925. category: 'converting',
  8926. fn: function (){
  8927. var self=this;
  8928. return smalltalk.send(self['@elements'], "_copy", []);
  8929. return self;},
  8930. args: [],
  8931. source: unescape('asArray%0A%09%5Eelements%20copy'),
  8932. messageSends: ["copy"],
  8933. referencedClasses: []
  8934. }),
  8935. smalltalk.Set);
  8936. smalltalk.addMethod(
  8937. unescape('_detect_ifNone_'),
  8938. smalltalk.method({
  8939. selector: unescape('detect%3AifNone%3A'),
  8940. category: 'enumerating',
  8941. fn: function (aBlock, anotherBlock){
  8942. var self=this;
  8943. return smalltalk.send(self['@elements'], "_detect_ifNone_", [aBlock, anotherBlock]);
  8944. return self;},
  8945. args: ["aBlock", "anotherBlock"],
  8946. source: unescape('detect%3A%20aBlock%20ifNone%3A%20anotherBlock%0A%09%5Eelements%20detect%3A%20aBlock%20ifNone%3A%20anotherBlock'),
  8947. messageSends: ["detect:ifNone:"],
  8948. referencedClasses: []
  8949. }),
  8950. smalltalk.Set);
  8951. smalltalk.addMethod(
  8952. unescape('_do_'),
  8953. smalltalk.method({
  8954. selector: unescape('do%3A'),
  8955. category: 'enumerating',
  8956. fn: function (aBlock){
  8957. var self=this;
  8958. smalltalk.send(self['@elements'], "_do_", [aBlock]);
  8959. return self;},
  8960. args: ["aBlock"],
  8961. source: unescape('do%3A%20aBlock%0A%09elements%20do%3A%20aBlock'),
  8962. messageSends: ["do:"],
  8963. referencedClasses: []
  8964. }),
  8965. smalltalk.Set);
  8966. smalltalk.addMethod(
  8967. unescape('_includes_'),
  8968. smalltalk.method({
  8969. selector: unescape('includes%3A'),
  8970. category: 'testing',
  8971. fn: function (anObject){
  8972. var self=this;
  8973. return smalltalk.send(self['@elements'], "_includes_", [anObject]);
  8974. return self;},
  8975. args: ["anObject"],
  8976. source: unescape('includes%3A%20anObject%0A%09%5Eelements%20includes%3A%20anObject'),
  8977. messageSends: ["includes:"],
  8978. referencedClasses: []
  8979. }),
  8980. smalltalk.Set);
  8981. smalltalk.addMethod(
  8982. unescape('__eq'),
  8983. smalltalk.method({
  8984. selector: unescape('%3D'),
  8985. category: 'comparing',
  8986. fn: function (aCollection){
  8987. var self=this;
  8988. return smalltalk.send(smalltalk.send(smalltalk.send(self, "_class", []), "__eq", [smalltalk.send(aCollection, "_class", [])]), "_and_", [(function(){return smalltalk.send(self['@elements'], "__eq", [smalltalk.send(aCollection, "_asArray", [])]);})]);
  8989. return self;},
  8990. args: ["aCollection"],
  8991. source: unescape('%3D%20aCollection%0A%09%5Eself%20class%20%3D%20aCollection%20class%20and%3A%20%5B%0A%20%20%20%20%20%20%20%20%09elements%20%3D%20aCollection%20asArray%5D'),
  8992. messageSends: ["and:", unescape("%3D"), "class", "asArray"],
  8993. referencedClasses: []
  8994. }),
  8995. smalltalk.Set);
  8996. smalltalk.addClass('Transcript', smalltalk.Object, ['textarea'], 'Kernel');
  8997. smalltalk.Transcript.klass.iVarNames = ['current'];
  8998. smalltalk.addMethod(
  8999. unescape('_open'),
  9000. smalltalk.method({
  9001. selector: unescape('open'),
  9002. category: 'instance creation',
  9003. fn: function (){
  9004. var self=this;
  9005. smalltalk.send(smalltalk.send(self, "_current", []), "_open", []);
  9006. return self;},
  9007. args: [],
  9008. source: unescape('open%0A%20%20%20%20self%20current%20open'),
  9009. messageSends: ["open", "current"],
  9010. referencedClasses: []
  9011. }),
  9012. smalltalk.Transcript.klass);
  9013. smalltalk.addMethod(
  9014. unescape('_new'),
  9015. smalltalk.method({
  9016. selector: unescape('new'),
  9017. category: 'instance creation',
  9018. fn: function (){
  9019. var self=this;
  9020. smalltalk.send(self, "_shouldNotImplement", []);
  9021. return self;},
  9022. args: [],
  9023. source: unescape('new%0A%20%20%20%20self%20shouldNotImplement'),
  9024. messageSends: ["shouldNotImplement"],
  9025. referencedClasses: []
  9026. }),
  9027. smalltalk.Transcript.klass);
  9028. smalltalk.addMethod(
  9029. unescape('_current'),
  9030. smalltalk.method({
  9031. selector: unescape('current'),
  9032. category: 'instance creation',
  9033. fn: function (){
  9034. var self=this;
  9035. return self['@current'];
  9036. return self;},
  9037. args: [],
  9038. source: unescape('current%0A%20%20%20%20%5Ecurrent'),
  9039. messageSends: [],
  9040. referencedClasses: []
  9041. }),
  9042. smalltalk.Transcript.klass);
  9043. smalltalk.addMethod(
  9044. unescape('_show_'),
  9045. smalltalk.method({
  9046. selector: unescape('show%3A'),
  9047. category: 'printing',
  9048. fn: function (anObject){
  9049. var self=this;
  9050. smalltalk.send(smalltalk.send(self, "_current", []), "_show_", [anObject]);
  9051. return self;},
  9052. args: ["anObject"],
  9053. source: unescape('show%3A%20anObject%0A%20%20%20%20self%20current%20show%3A%20anObject'),
  9054. messageSends: ["show:", "current"],
  9055. referencedClasses: []
  9056. }),
  9057. smalltalk.Transcript.klass);
  9058. smalltalk.addMethod(
  9059. unescape('_cr'),
  9060. smalltalk.method({
  9061. selector: unescape('cr'),
  9062. category: 'printing',
  9063. fn: function (){
  9064. var self=this;
  9065. smalltalk.send(smalltalk.send(self, "_current", []), "_show_", [smalltalk.send((smalltalk.String || String), "_cr", [])]);
  9066. return self;},
  9067. args: [],
  9068. source: unescape('cr%0A%20%20%20%20self%20current%20show%3A%20String%20cr'),
  9069. messageSends: ["show:", "current", "cr"],
  9070. referencedClasses: ["String"]
  9071. }),
  9072. smalltalk.Transcript.klass);
  9073. smalltalk.addMethod(
  9074. unescape('_clear'),
  9075. smalltalk.method({
  9076. selector: unescape('clear'),
  9077. category: 'printing',
  9078. fn: function (){
  9079. var self=this;
  9080. smalltalk.send(smalltalk.send(self, "_current", []), "_clear", []);
  9081. return self;},
  9082. args: [],
  9083. source: unescape('clear%0A%20%20%20%20self%20current%20clear'),
  9084. messageSends: ["clear", "current"],
  9085. referencedClasses: []
  9086. }),
  9087. smalltalk.Transcript.klass);
  9088. smalltalk.addMethod(
  9089. unescape('_register_'),
  9090. smalltalk.method({
  9091. selector: unescape('register%3A'),
  9092. category: 'instance creation',
  9093. fn: function (aTranscript){
  9094. var self=this;
  9095. self['@current']=aTranscript;
  9096. return self;},
  9097. args: ["aTranscript"],
  9098. source: unescape('register%3A%20aTranscript%0A%09current%20%3A%3D%20aTranscript'),
  9099. messageSends: [],
  9100. referencedClasses: []
  9101. }),
  9102. smalltalk.Transcript.klass);
  9103. smalltalk.addClass('ConsoleTranscript', smalltalk.Object, ['textarea'], 'Kernel');
  9104. smalltalk.addMethod(
  9105. unescape('_clear'),
  9106. smalltalk.method({
  9107. selector: unescape('clear'),
  9108. category: 'printing',
  9109. fn: function (){
  9110. var self=this;
  9111. return self;},
  9112. args: [],
  9113. source: unescape('clear%0A%09%22no%20op%22'),
  9114. messageSends: [],
  9115. referencedClasses: []
  9116. }),
  9117. smalltalk.ConsoleTranscript);
  9118. smalltalk.addMethod(
  9119. unescape('_cr'),
  9120. smalltalk.method({
  9121. selector: unescape('cr'),
  9122. category: 'printing',
  9123. fn: function (){
  9124. var self=this;
  9125. return self;},
  9126. args: [],
  9127. source: unescape('cr%0A%09%22no%20op%22'),
  9128. messageSends: [],
  9129. referencedClasses: []
  9130. }),
  9131. smalltalk.ConsoleTranscript);
  9132. smalltalk.addMethod(
  9133. unescape('_show_'),
  9134. smalltalk.method({
  9135. selector: unescape('show%3A'),
  9136. category: 'printing',
  9137. fn: function (anObject){
  9138. var self=this;
  9139. var string=nil;
  9140. string=smalltalk.send(anObject, "_asString", []);
  9141. console.log(String(string));
  9142. return self;},
  9143. args: ["anObject"],
  9144. source: unescape('show%3A%20anObject%0A%09%7C%20string%20%7C%0A%09string%20%3A%3D%20anObject%20asString.%0A%09%3Cconsole.log%28String%28string%29%29%3E'),
  9145. messageSends: ["asString"],
  9146. referencedClasses: []
  9147. }),
  9148. smalltalk.ConsoleTranscript);
  9149. smalltalk.addMethod(
  9150. unescape('_open'),
  9151. smalltalk.method({
  9152. selector: unescape('open'),
  9153. category: 'actions',
  9154. fn: function (){
  9155. var self=this;
  9156. return self;},
  9157. args: [],
  9158. source: unescape('open'),
  9159. messageSends: [],
  9160. referencedClasses: []
  9161. }),
  9162. smalltalk.ConsoleTranscript);
  9163. smalltalk.addMethod(
  9164. unescape('_initialize'),
  9165. smalltalk.method({
  9166. selector: unescape('initialize'),
  9167. category: 'initialization',
  9168. fn: function (){
  9169. var self=this;
  9170. smalltalk.send((smalltalk.Transcript || Transcript), "_register_", [smalltalk.send(self, "_new", [])]);
  9171. return self;},
  9172. args: [],
  9173. source: unescape('initialize%0A%09Transcript%20register%3A%20self%20new'),
  9174. messageSends: ["register:", "new"],
  9175. referencedClasses: ["Transcript"]
  9176. }),
  9177. smalltalk.ConsoleTranscript.klass);
  9178. smalltalk.addClass('Dictionary2', smalltalk.Dictionary, ['keys'], 'Kernel');
  9179. smalltalk.addMethod(
  9180. unescape('__eq'),
  9181. smalltalk.method({
  9182. selector: unescape('%3D'),
  9183. category: 'comparing',
  9184. fn: function (aDictionary){
  9185. var self=this;
  9186. try{((($receiver = smalltalk.send(smalltalk.send(self, "_class", []), "__eq", [smalltalk.send(aDictionary, "_class", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));
  9187. ((($receiver = smalltalk.send(smalltalk.send(self, "_size", []), "__eq", [smalltalk.send(aDictionary, "_size", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return false}})})();})]));
  9188. (function(){throw({name: 'stReturn', selector: '__eq', fn: function(){return smalltalk.send(smalltalk.send(self, "_associations", []), "__eq", [smalltalk.send(aDictionary, "_associations", [])])}})})();
  9189. return self;
  9190. } catch(e) {if(e.name === 'stReturn' && e.selector === '__eq'){return e.fn()} throw(e)}},
  9191. args: ["aDictionary"],
  9192. source: unescape('%3D%20aDictionary%0A%09self%20class%20%3D%20aDictionary%20class%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09self%20size%20%3D%20aDictionary%20size%20ifFalse%3A%20%5B%5Efalse%5D.%0A%09%5Eself%20associations%20%3D%20aDictionary%20associations'),
  9193. messageSends: ["ifFalse:", unescape("%3D"), "class", "size", "associations"],
  9194. referencedClasses: []
  9195. }),
  9196. smalltalk.Dictionary2);
  9197. smalltalk.addMethod(
  9198. unescape('_shallowCopy'),
  9199. smalltalk.method({
  9200. selector: unescape('shallowCopy'),
  9201. category: 'copying',
  9202. fn: function (){
  9203. var self=this;
  9204. var copy=nil;
  9205. copy=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  9206. smalltalk.send(self, "_associationsDo_", [(function(each){return smalltalk.send(copy, "_at_put_", [smalltalk.send(each, "_key", []), smalltalk.send(each, "_value", [])]);})]);
  9207. return copy;
  9208. return self;},
  9209. args: [],
  9210. source: unescape('shallowCopy%0A%09%7C%20copy%20%7C%0A%09copy%20%3A%3D%20self%20class%20new.%0A%09self%20associationsDo%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20copy%20at%3A%20each%20key%20%20put%3A%20each%20value%5D.%0A%09%5Ecopy'),
  9211. messageSends: ["new", "class", "associationsDo:", "at:put:", "key", "value"],
  9212. referencedClasses: []
  9213. }),
  9214. smalltalk.Dictionary2);
  9215. smalltalk.addMethod(
  9216. unescape('_initialize'),
  9217. smalltalk.method({
  9218. selector: unescape('initialize'),
  9219. category: 'initialization',
  9220. fn: function (){
  9221. var self=this;
  9222. smalltalk.send(self, "_initialize", [], smalltalk.Dictionary);
  9223. self['@keys']=[];
  9224. return self;},
  9225. args: [],
  9226. source: unescape('initialize%0A%20%20%20%20%09super%20initialize.%0A%20%20%20%20%09keys%20%3A%3D%20%23%28%29'),
  9227. messageSends: ["initialize"],
  9228. referencedClasses: []
  9229. }),
  9230. smalltalk.Dictionary2);
  9231. smalltalk.addMethod(
  9232. unescape('_size'),
  9233. smalltalk.method({
  9234. selector: unescape('size'),
  9235. category: 'accessing',
  9236. fn: function (){
  9237. var self=this;
  9238. return smalltalk.send(self['@keys'], "_size", []);
  9239. return self;},
  9240. args: [],
  9241. source: unescape('size%0A%09%5Ekeys%20size'),
  9242. messageSends: ["size"],
  9243. referencedClasses: []
  9244. }),
  9245. smalltalk.Dictionary2);
  9246. smalltalk.addMethod(
  9247. unescape('_associations'),
  9248. smalltalk.method({
  9249. selector: unescape('associations'),
  9250. category: 'accessing',
  9251. fn: function (){
  9252. var self=this;
  9253. var associations=nil;
  9254. associations=[];
  9255. smalltalk.send(self['@keys'], "_do_", [(function(each){return smalltalk.send(associations, "_add_", [smalltalk.send((smalltalk.Association || Association), "_key_value_", [each, smalltalk.send(self, "_at_", [each])])]);})]);
  9256. return associations;
  9257. return self;},
  9258. args: [],
  9259. source: unescape('associations%0A%09%7C%20associations%20%7C%0A%09associations%20%3A%3D%20%23%28%29.%0A%09keys%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20associations%20add%3A%20%28Association%20key%3A%20each%20value%3A%20%28self%20at%3A%20each%29%29%5D.%0A%09%5Eassociations'),
  9260. messageSends: ["do:", "add:", "key:value:", "at:"],
  9261. referencedClasses: ["Association"]
  9262. }),
  9263. smalltalk.Dictionary2);
  9264. smalltalk.addMethod(
  9265. unescape('_keys'),
  9266. smalltalk.method({
  9267. selector: unescape('keys'),
  9268. category: 'accessing',
  9269. fn: function (){
  9270. var self=this;
  9271. return smalltalk.send(self['@keys'], "_copy", []);
  9272. return self;},
  9273. args: [],
  9274. source: unescape('keys%0A%09%5Ekeys%20copy'),
  9275. messageSends: ["copy"],
  9276. referencedClasses: []
  9277. }),
  9278. smalltalk.Dictionary2);
  9279. smalltalk.addMethod(
  9280. unescape('_values'),
  9281. smalltalk.method({
  9282. selector: unescape('values'),
  9283. category: 'accessing',
  9284. fn: function (){
  9285. var self=this;
  9286. return smalltalk.send(self['@keys'], "_collect_", [(function(each){return smalltalk.send(self, "_at_", [each]);})]);
  9287. return self;},
  9288. args: [],
  9289. source: unescape('values%0A%20%20%20%20%09%5Ekeys%20collect%3A%20%5B%3Aeach%20%7C%20self%20at%3A%20each%5D'),
  9290. messageSends: ["collect:", "at:"],
  9291. referencedClasses: []
  9292. }),
  9293. smalltalk.Dictionary2);
  9294. smalltalk.addMethod(
  9295. unescape('_at_put_'),
  9296. smalltalk.method({
  9297. selector: unescape('at%3Aput%3A'),
  9298. category: 'accessing',
  9299. fn: function (aKey, aValue){
  9300. var self=this;
  9301. ((($receiver = smalltalk.send(self['@keys'], "_includes_", [aKey])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self['@keys'], "_add_", [aKey]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(self['@keys'], "_add_", [aKey]);})]));
  9302. return smalltalk.send(self, "_basicAt_put_", [aKey, aValue]);
  9303. return self;},
  9304. args: ["aKey", "aValue"],
  9305. source: unescape('at%3A%20aKey%20put%3A%20aValue%0A%09%28keys%20includes%3A%20aKey%29%20ifFalse%3A%20%5Bkeys%20add%3A%20aKey%5D.%0A%09%5Eself%20basicAt%3A%20aKey%20put%3A%20aValue'),
  9306. messageSends: ["ifFalse:", "includes:", "add:", "basicAt:put:"],
  9307. referencedClasses: []
  9308. }),
  9309. smalltalk.Dictionary2);
  9310. smalltalk.addMethod(
  9311. unescape('_at_ifAbsent_'),
  9312. smalltalk.method({
  9313. selector: unescape('at%3AifAbsent%3A'),
  9314. category: 'accessing',
  9315. fn: function (aKey, aBlock){
  9316. var self=this;
  9317. return smalltalk.send(smalltalk.send(smalltalk.send(self, "_keys", []), "_includes_", [aKey]), "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self, "_basicAt_", [aKey]);}), aBlock]);
  9318. return self;},
  9319. args: ["aKey", "aBlock"],
  9320. source: unescape('at%3A%20aKey%20ifAbsent%3A%20aBlock%0A%09%5E%28self%20keys%20includes%3A%20aKey%29%0A%09%09ifTrue%3A%20%5Bself%20basicAt%3A%20aKey%5D%0A%09%09ifFalse%3A%20aBlock'),
  9321. messageSends: ["ifTrue:ifFalse:", "includes:", "keys", "basicAt:"],
  9322. referencedClasses: []
  9323. }),
  9324. smalltalk.Dictionary2);
  9325. smalltalk.addMethod(
  9326. unescape('_at_ifAbsentPut_'),
  9327. smalltalk.method({
  9328. selector: unescape('at%3AifAbsentPut%3A'),
  9329. category: 'accessing',
  9330. fn: function (aKey, aBlock){
  9331. var self=this;
  9332. return smalltalk.send(self, "_at_ifAbsent_", [aKey, (function(){return smalltalk.send(self, "_at_put_", [aKey, smalltalk.send(aBlock, "_value", [])]);})]);
  9333. return self;},
  9334. args: ["aKey", "aBlock"],
  9335. source: unescape('at%3A%20aKey%20ifAbsentPut%3A%20aBlock%0A%20%20%20%20%09%5Eself%20at%3A%20aKey%20ifAbsent%3A%20%5B%0A%20%20%20%20%09%20%20%20%20self%20at%3A%20aKey%20put%3A%20aBlock%20value%5D'),
  9336. messageSends: ["at:ifAbsent:", "at:put:", "value"],
  9337. referencedClasses: []
  9338. }),
  9339. smalltalk.Dictionary2);
  9340. smalltalk.addMethod(
  9341. unescape('_at_ifPresent_'),
  9342. smalltalk.method({
  9343. selector: unescape('at%3AifPresent%3A'),
  9344. category: 'accessing',
  9345. fn: function (aKey, aBlock){
  9346. var self=this;
  9347. return (($receiver = smalltalk.send(self, "_basicAt_", [aKey])) != nil && $receiver != undefined) ? (function(){return smalltalk.send(aBlock, "_value_", [smalltalk.send(self, "_at_", [aKey])]);})() : nil;
  9348. return self;},
  9349. args: ["aKey", "aBlock"],
  9350. source: unescape('at%3A%20aKey%20ifPresent%3A%20aBlock%0A%09%5E%28self%20basicAt%3A%20aKey%29%20ifNotNil%3A%20%5BaBlock%20value%3A%20%28self%20at%3A%20aKey%29%5D'),
  9351. messageSends: ["ifNotNil:", "basicAt:", "value:", "at:"],
  9352. referencedClasses: []
  9353. }),
  9354. smalltalk.Dictionary2);
  9355. smalltalk.addMethod(
  9356. unescape('_at_ifPresent_ifAbsent_'),
  9357. smalltalk.method({
  9358. selector: unescape('at%3AifPresent%3AifAbsent%3A'),
  9359. category: 'accessing',
  9360. fn: function (aKey, aBlock, anotherBlock){
  9361. var self=this;
  9362. return smalltalk.send(smalltalk.send(self, "_basicAt_", [aKey]), "_ifNil_ifNotNil_", [anotherBlock, (function(){return smalltalk.send(aBlock, "_value_", [smalltalk.send(self, "_at_", [aKey])]);})]);
  9363. return self;},
  9364. args: ["aKey", "aBlock", "anotherBlock"],
  9365. source: unescape('at%3A%20aKey%20ifPresent%3A%20aBlock%20ifAbsent%3A%20anotherBlock%0A%09%5E%28self%20basicAt%3A%20aKey%29%0A%09%20%20%20%20ifNil%3A%20anotherBlock%0A%09%20%20%20%20ifNotNil%3A%20%5BaBlock%20value%3A%20%28self%20at%3A%20aKey%29%5D'),
  9366. messageSends: ["ifNil:ifNotNil:", "basicAt:", "value:", "at:"],
  9367. referencedClasses: []
  9368. }),
  9369. smalltalk.Dictionary2);
  9370. smalltalk.addMethod(
  9371. unescape('_add_'),
  9372. smalltalk.method({
  9373. selector: unescape('add%3A'),
  9374. category: 'adding/removing',
  9375. fn: function (anAssociation){
  9376. var self=this;
  9377. smalltalk.send(self, "_at_put_", [smalltalk.send(anAssociation, "_key", []), smalltalk.send(anAssociation, "_value", [])]);
  9378. return self;},
  9379. args: ["anAssociation"],
  9380. source: unescape('add%3A%20anAssociation%0A%20%20%20%20%09self%20at%3A%20anAssociation%20key%20put%3A%20anAssociation%20value'),
  9381. messageSends: ["at:put:", "key", "value"],
  9382. referencedClasses: []
  9383. }),
  9384. smalltalk.Dictionary2);
  9385. smalltalk.addMethod(
  9386. unescape('_addAll_'),
  9387. smalltalk.method({
  9388. selector: unescape('addAll%3A'),
  9389. category: 'adding/removing',
  9390. fn: function (aDictionary){
  9391. var self=this;
  9392. smalltalk.send(self, "_addAll_", [smalltalk.send(aDictionary, "_associations", [])], smalltalk.Dictionary);
  9393. return aDictionary;
  9394. return self;},
  9395. args: ["aDictionary"],
  9396. source: unescape('addAll%3A%20aDictionary%0A%20%20%20%20%09super%20addAll%3A%20aDictionary%20associations.%0A%20%20%20%20%09%5EaDictionary'),
  9397. messageSends: ["addAll:", "associations"],
  9398. referencedClasses: []
  9399. }),
  9400. smalltalk.Dictionary2);
  9401. smalltalk.addMethod(
  9402. unescape('__comma'),
  9403. smalltalk.method({
  9404. selector: unescape('%2C'),
  9405. category: 'copying',
  9406. fn: function (aCollection){
  9407. var self=this;
  9408. smalltalk.send(self, "_shouldNotImplement", []);
  9409. return self;},
  9410. args: ["aCollection"],
  9411. source: unescape('%2C%20aCollection%0A%09self%20shouldNotImplement'),
  9412. messageSends: ["shouldNotImplement"],
  9413. referencedClasses: []
  9414. }),
  9415. smalltalk.Dictionary2);
  9416. smalltalk.addMethod(
  9417. unescape('_copyFrom_to_'),
  9418. smalltalk.method({
  9419. selector: unescape('copyFrom%3Ato%3A'),
  9420. category: 'copying',
  9421. fn: function (anIndex, anotherIndex){
  9422. var self=this;
  9423. smalltalk.send(self, "_shouldNotImplement", []);
  9424. return self;},
  9425. args: ["anIndex", "anotherIndex"],
  9426. source: unescape('copyFrom%3A%20anIndex%20to%3A%20anotherIndex%0A%09self%20shouldNotImplement'),
  9427. messageSends: ["shouldNotImplement"],
  9428. referencedClasses: []
  9429. }),
  9430. smalltalk.Dictionary2);
  9431. smalltalk.addMethod(
  9432. unescape('_associationsDo_'),
  9433. smalltalk.method({
  9434. selector: unescape('associationsDo%3A'),
  9435. category: 'enumerating',
  9436. fn: function (aBlock){
  9437. var self=this;
  9438. smalltalk.send(smalltalk.send(self, "_associations", []), "_do_", [aBlock]);
  9439. return self;},
  9440. args: ["aBlock"],
  9441. source: unescape('associationsDo%3A%20aBlock%0A%20%20%20%20%09self%20associations%20do%3A%20aBlock'),
  9442. messageSends: ["do:", "associations"],
  9443. referencedClasses: []
  9444. }),
  9445. smalltalk.Dictionary2);
  9446. smalltalk.addMethod(
  9447. unescape('_keysAndValuesDo_'),
  9448. smalltalk.method({
  9449. selector: unescape('keysAndValuesDo%3A'),
  9450. category: 'enumerating',
  9451. fn: function (aBlock){
  9452. var self=this;
  9453. smalltalk.send(self, "_associationsDo_", [(function(each){return smalltalk.send(aBlock, "_value_value_", [smalltalk.send(each, "_key", []), smalltalk.send(each, "_value", [])]);})]);
  9454. return self;},
  9455. args: ["aBlock"],
  9456. source: unescape('keysAndValuesDo%3A%20aBlock%0A%20%20%20%20%09self%20associationsDo%3A%20%5B%3Aeach%20%7C%0A%20%20%20%20%09%20%20%20%20aBlock%20value%3A%20each%20key%20value%3A%20each%20value%5D'),
  9457. messageSends: ["associationsDo:", "value:value:", "key", "value"],
  9458. referencedClasses: []
  9459. }),
  9460. smalltalk.Dictionary2);
  9461. smalltalk.addMethod(
  9462. unescape('_do_'),
  9463. smalltalk.method({
  9464. selector: unescape('do%3A'),
  9465. category: 'enumerating',
  9466. fn: function (aBlock){
  9467. var self=this;
  9468. smalltalk.send(smalltalk.send(self, "_values", []), "_do_", [aBlock]);
  9469. return self;},
  9470. args: ["aBlock"],
  9471. source: unescape('do%3A%20aBlock%0A%20%20%20%20%09self%20values%20do%3A%20aBlock'),
  9472. messageSends: ["do:", "values"],
  9473. referencedClasses: []
  9474. }),
  9475. smalltalk.Dictionary2);
  9476. smalltalk.addMethod(
  9477. unescape('_select_'),
  9478. smalltalk.method({
  9479. selector: unescape('select%3A'),
  9480. category: 'enumerating',
  9481. fn: function (aBlock){
  9482. var self=this;
  9483. var newDict=nil;
  9484. newDict=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  9485. smalltalk.send(self, "_keysAndValuesDo_", [(function(key, value){return ((($receiver = smalltalk.send(aBlock, "_value_", [value])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(newDict, "_at_put_", [key, value]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(newDict, "_at_put_", [key, value]);})]));})]);
  9486. return newDict;
  9487. return self;},
  9488. args: ["aBlock"],
  9489. source: unescape('select%3A%20aBlock%0A%20%20%20%20%09%7C%20newDict%20%7C%0A%20%20%20%20%09newDict%20%3A%3D%20self%20class%20new.%0A%20%20%20%20%09self%20keysAndValuesDo%3A%20%5B%3Akey%20%3Avalue%20%7C%0A%20%20%20%20%09%20%20%20%20%28aBlock%20value%3A%20value%29%20ifTrue%3A%20%5BnewDict%20at%3A%20key%20put%3A%20value%5D%5D.%0A%20%20%20%20%09%5EnewDict'),
  9490. messageSends: ["new", "class", "keysAndValuesDo:", "ifTrue:", "value:", "at:put:"],
  9491. referencedClasses: []
  9492. }),
  9493. smalltalk.Dictionary2);
  9494. smalltalk.addMethod(
  9495. unescape('_collect_'),
  9496. smalltalk.method({
  9497. selector: unescape('collect%3A'),
  9498. category: 'enumerating',
  9499. fn: function (aBlock){
  9500. var self=this;
  9501. var newDict=nil;
  9502. newDict=smalltalk.send(smalltalk.send(self, "_class", []), "_new", []);
  9503. smalltalk.send(self, "_keysAndValuesDo_", [(function(key, value){return smalltalk.send(newDict, "_at_put_", [key, smalltalk.send(aBlock, "_value_", [value])]);})]);
  9504. return newDict;
  9505. return self;},
  9506. args: ["aBlock"],
  9507. source: unescape('collect%3A%20aBlock%0A%20%20%20%20%09%7C%20newDict%20%7C%0A%20%20%20%20%09newDict%20%3A%3D%20self%20class%20new.%0A%20%20%20%20%09self%20keysAndValuesDo%3A%20%5B%3Akey%20%3Avalue%20%7C%0A%20%20%20%20%09%20%20%20%20newDict%20at%3A%20key%20put%3A%20%28aBlock%20value%3A%20value%29%5D.%0A%20%20%20%20%09%5EnewDict'),
  9508. messageSends: ["new", "class", "keysAndValuesDo:", "at:put:", "value:"],
  9509. referencedClasses: []
  9510. }),
  9511. smalltalk.Dictionary2);
  9512. smalltalk.addMethod(
  9513. unescape('_detect_ifNone_'),
  9514. smalltalk.method({
  9515. selector: unescape('detect%3AifNone%3A'),
  9516. category: 'enumerating',
  9517. fn: function (aBlock, anotherBlock){
  9518. var self=this;
  9519. return smalltalk.send(smalltalk.send(self, "_values", []), "_detect_ifNone_", [aBlock, anotherBlock]);
  9520. return self;},
  9521. args: ["aBlock", "anotherBlock"],
  9522. source: unescape('detect%3A%20aBlock%20ifNone%3A%20anotherBlock%0A%09%5Eself%20values%20detect%3A%20aBlock%20ifNone%3A%20anotherBlock'),
  9523. messageSends: ["detect:ifNone:", "values"],
  9524. referencedClasses: []
  9525. }),
  9526. smalltalk.Dictionary2);
  9527. smalltalk.addMethod(
  9528. unescape('_includes_'),
  9529. smalltalk.method({
  9530. selector: unescape('includes%3A'),
  9531. category: 'enumerating',
  9532. fn: function (anObject){
  9533. var self=this;
  9534. return smalltalk.send(smalltalk.send(self, "_values", []), "_includes_", [anObject]);
  9535. return self;},
  9536. args: ["anObject"],
  9537. source: unescape('includes%3A%20anObject%0A%09%5Eself%20values%20includes%3A%20anObject'),
  9538. messageSends: ["includes:", "values"],
  9539. referencedClasses: []
  9540. }),
  9541. smalltalk.Dictionary2);
  9542. smalltalk.addMethod(
  9543. unescape('_remove_'),
  9544. smalltalk.method({
  9545. selector: unescape('remove%3A'),
  9546. category: 'adding/removing',
  9547. fn: function (aKey){
  9548. var self=this;
  9549. smalltalk.send(self, "_removeKey_", [aKey]);
  9550. return self;},
  9551. args: ["aKey"],
  9552. source: unescape('remove%3A%20aKey%0A%20%20%20%20self%20removeKey%3A%20aKey'),
  9553. messageSends: ["removeKey:"],
  9554. referencedClasses: []
  9555. }),
  9556. smalltalk.Dictionary2);
  9557. smalltalk.addMethod(
  9558. unescape('_removeKey_'),
  9559. smalltalk.method({
  9560. selector: unescape('removeKey%3A'),
  9561. category: 'adding/removing',
  9562. fn: function (aKey){
  9563. var self=this;
  9564. smalltalk.send(self['@keys'], "_remove_", [aKey]);
  9565. return self;},
  9566. args: ["aKey"],
  9567. source: unescape('removeKey%3A%20aKey%0A%20%20%20%20keys%20remove%3A%20aKey'),
  9568. messageSends: ["remove:"],
  9569. referencedClasses: []
  9570. }),
  9571. smalltalk.Dictionary2);
  9572. smalltalk.addMethod(
  9573. unescape('_at_'),
  9574. smalltalk.method({
  9575. selector: unescape('at%3A'),
  9576. category: 'accessing',
  9577. fn: function (aKey){
  9578. var self=this;
  9579. return smalltalk.send(self, "_at_ifAbsent_", [aKey, (function(){return smalltalk.send(self, "_errorNotFound", []);})]);
  9580. return self;},
  9581. args: ["aKey"],
  9582. source: unescape('at%3A%20aKey%0A%09%5Eself%20at%3A%20aKey%20ifAbsent%3A%20%5Bself%20errorNotFound%5D'),
  9583. messageSends: ["at:ifAbsent:", "errorNotFound"],
  9584. referencedClasses: []
  9585. }),
  9586. smalltalk.Dictionary2);
  9587. smalltalk.addMethod(
  9588. unescape('_asJSONObject'),
  9589. smalltalk.method({
  9590. selector: unescape('asJSONObject'),
  9591. category: 'converting',
  9592. fn: function (){
  9593. var self=this;
  9594. var object=nil;
  9595. object=smalltalk.send((smalltalk.Object || Object), "_new", []);
  9596. smalltalk.send(self, "_keysAndValuesDo_", [(function(key, value){return smalltalk.send(object, "_basicAt_put_", [key, smalltalk.send(value, "_asJSONObject", [])]);})]);
  9597. return object;
  9598. return self;},
  9599. args: [],
  9600. source: unescape('asJSONObject%0A%09%7C%20object%20%7C%0A%09object%20%3A%3D%20Object%20new.%0A%09self%20keysAndValuesDo%3A%20%5B%3Akey%20%3Avalue%20%7C%0A%09%09object%20basicAt%3A%20key%20put%3A%20value%20asJSONObject%5D.%0A%09%5Eobject'),
  9601. messageSends: ["new", "keysAndValuesDo:", "basicAt:put:", "asJSONObject"],
  9602. referencedClasses: ["Object"]
  9603. }),
  9604. smalltalk.Dictionary2);
  9605. smalltalk.addMethod(
  9606. unescape('_printString'),
  9607. smalltalk.method({
  9608. selector: unescape('printString'),
  9609. category: 'printing',
  9610. fn: function (){
  9611. var self=this;
  9612. return smalltalk.send((smalltalk.String || String), "_streamContents_", [(function(aStream){(function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self, "_printString", [], smalltalk.Dictionary)]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%28")]);})(aStream);smalltalk.send(smalltalk.send(self, "_associations", []), "_do_separatedBy_", [(function(anAssociation){return (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(anAssociation, "_key", []), "_printString", [])]);smalltalk.send($rec, "_nextPutAll_", [unescape("%20-%3E%20")]);return smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(anAssociation, "_value", []), "_printString", [])]);})(aStream);}), (function(){return smalltalk.send(aStream, "_nextPutAll_", [unescape("%20%2C%20")]);})]);return smalltalk.send(aStream, "_nextPutAll_", [unescape("%29")]);})]);
  9613. return self;},
  9614. args: [],
  9615. source: unescape('printString%0A%09%5E%20String%20streamContents%3A%20%5B%3AaStream%7C%20%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09aStream%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09nextPutAll%3A%20super%20printString%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09nextPutAll%3A%20%27%28%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09self%20associations%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09do%3A%20%5B%3AanAssociation%7C%20%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09aStream%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09nextPutAll%3A%20anAssociation%20key%20printString%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09nextPutAll%3A%20%27%20-%3E%20%27%3B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09nextPutAll%3A%20anAssociation%20value%20printString%5D%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09separatedBy%3A%20%5BaStream%20nextPutAll%3A%20%27%20%2C%20%27%5D.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09aStream%20nextPutAll%3A%20%27%29%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%5D'),
  9616. messageSends: ["streamContents:", "nextPutAll:", "printString", "do:separatedBy:", "associations", "key", "value"],
  9617. referencedClasses: ["String"]
  9618. }),
  9619. smalltalk.Dictionary2);
  9620. smalltalk.addMethod(
  9621. unescape('_storeOn_'),
  9622. smalltalk.method({
  9623. selector: unescape('storeOn%3A'),
  9624. category: 'printing',
  9625. fn: function (aStream){
  9626. var self=this;
  9627. smalltalk.send(aStream, "_nextPutAll_", [unescape("%23%7B")]);
  9628. smalltalk.send(smalltalk.send(self, "_associations", []), "_do_separatedBy_", [(function(each){return smalltalk.send(each, "_storeOn_", [aStream]);}), (function(){return smalltalk.send(aStream, "_nextPutAll_", [". "]);})]);
  9629. smalltalk.send(aStream, "_nextPutAll_", [unescape("%7D")]);
  9630. return self;},
  9631. args: ["aStream"],
  9632. source: unescape('storeOn%3A%20aStream%0A%09aStream%20nextPutAll%3A%20%27%23%7B%27.%0A%09self%20associations%0A%09%09do%3A%20%5B%3Aeach%20%7C%20each%20storeOn%3A%20aStream%5D%0A%09%09separatedBy%3A%20%5B%20aStream%20nextPutAll%3A%20%27.%20%27%5D.%0A%09aStream%20nextPutAll%3A%20%27%7D%27'),
  9633. messageSends: ["nextPutAll:", "do:separatedBy:", "associations", "storeOn:"],
  9634. referencedClasses: []
  9635. }),
  9636. smalltalk.Dictionary2);
  9637. smalltalk.addPackage('Compiler', {});
  9638. smalltalk.addClass('ChunkParser', smalltalk.Object, ['stream'], 'Compiler');
  9639. smalltalk.addMethod(
  9640. unescape('_stream_'),
  9641. smalltalk.method({
  9642. selector: unescape('stream%3A'),
  9643. category: 'accessing',
  9644. fn: function (aStream){
  9645. var self=this;
  9646. self['@stream']=aStream;
  9647. return self;},
  9648. args: ["aStream"],
  9649. source: unescape('stream%3A%20aStream%0A%09stream%20%3A%3D%20aStream'),
  9650. messageSends: [],
  9651. referencedClasses: []
  9652. }),
  9653. smalltalk.ChunkParser);
  9654. smalltalk.addMethod(
  9655. unescape('_nextChunk'),
  9656. smalltalk.method({
  9657. selector: unescape('nextChunk'),
  9658. category: 'reading',
  9659. fn: function (){
  9660. var self=this;
  9661. try{var char_=nil;
  9662. var result=nil;
  9663. var chunk=nil;
  9664. result=smalltalk.send("", "_writeStream", []);
  9665. (function(){while((function(){char_=smalltalk.send(self['@stream'], "_next", []);return smalltalk.send(char_, "_notNil", []);})()) {(function(){((($receiver = smalltalk.send(char_, "__eq", [unescape("%21")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(smalltalk.send(self['@stream'], "_peek", []), "__eq", [unescape("%21")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_next", []);})() : (function(){return (function(){throw({name: 'stReturn', selector: '_nextChunk', fn: function(){return smalltalk.send(smalltalk.send(result, "_contents", []), "_trimBoth", [])}})})();})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_next", []);}), (function(){return (function(){throw({name: 'stReturn', selector: '_nextChunk', fn: function(){return smalltalk.send(smalltalk.send(result, "_contents", []), "_trimBoth", [])}})})();})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(smalltalk.send(self['@stream'], "_peek", []), "__eq", [unescape("%21")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_next", []);})() : (function(){return (function(){throw({name: 'stReturn', selector: '_nextChunk', fn: function(){return smalltalk.send(smalltalk.send(result, "_contents", []), "_trimBoth", [])}})})();})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_next", []);}), (function(){return (function(){throw({name: 'stReturn', selector: '_nextChunk', fn: function(){return smalltalk.send(smalltalk.send(result, "_contents", []), "_trimBoth", [])}})})();})]));})]));return smalltalk.send(result, "_nextPut_", [char_]);})()}})();
  9666. (function(){throw({name: 'stReturn', selector: '_nextChunk', fn: function(){return nil}})})();
  9667. return self;
  9668. } catch(e) {if(e.name === 'stReturn' && e.selector === '_nextChunk'){return e.fn()} throw(e)}},
  9669. args: [],
  9670. source: unescape('nextChunk%0A%09%22The%20chunk%20format%20%28Smalltalk%20Interchange%20Format%20or%20Fileout%20format%29%0A%09is%20a%20trivial%20format%20but%20can%20be%20a%20bit%20tricky%20to%20understand%3A%0A%09%09-%20Uses%20the%20exclamation%20mark%20as%20delimiter%20of%20chunks.%0A%09%09-%20Inside%20a%20chunk%20a%20normal%20exclamation%20mark%20must%20be%20doubled.%0A%09%09-%20A%20non%20empty%20chunk%20must%20be%20a%20valid%20Smalltalk%20expression.%0A%09%09-%20A%20chunk%20on%20top%20level%20with%20a%20preceding%20empty%20chunk%20is%20an%20instruction%20chunk%3A%0A%09%09%09-%20The%20object%20created%20by%20the%20expression%20then%20takes%20over%20reading%20chunks.%0A%0A%09This%20metod%20returns%20next%20chunk%20as%20a%20String%20%28trimmed%29%2C%20empty%20String%20%28all%20whitespace%29%20or%20nil.%22%0A%0A%09%7C%20char%20result%20chunk%20%7C%0A%09result%20%3A%3D%20%27%27%20writeStream.%0A%20%20%20%20%20%20%20%20%5Bchar%20%3A%3D%20stream%20next.%0A%20%20%20%20%20%20%20%20char%20notNil%5D%20whileTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20char%20%3D%20%27%21%27%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20stream%20peek%20%3D%20%27%21%27%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20ifTrue%3A%20%5Bstream%20next%20%22skipping%20the%20escape%20double%22%5D%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20ifFalse%3A%20%5B%5Eresult%20contents%20trimBoth%20%20%22chunk%20end%20marker%20found%22%5D%5D.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20result%20nextPut%3A%20char%5D.%0A%09%5Enil%20%22a%20chunk%20needs%20to%20end%20with%20%21%22'),
  9671. messageSends: ["writeStream", "whileTrue:", "next", "notNil", "ifTrue:", unescape("%3D"), "ifTrue:ifFalse:", "peek", "trimBoth", "contents", "nextPut:"],
  9672. referencedClasses: []
  9673. }),
  9674. smalltalk.ChunkParser);
  9675. smalltalk.addMethod(
  9676. unescape('_on_'),
  9677. smalltalk.method({
  9678. selector: unescape('on%3A'),
  9679. category: 'not yet classified',
  9680. fn: function (aStream){
  9681. var self=this;
  9682. return smalltalk.send(smalltalk.send(self, "_new", []), "_stream_", [aStream]);
  9683. return self;},
  9684. args: ["aStream"],
  9685. source: unescape('on%3A%20aStream%0A%09%5Eself%20new%20stream%3A%20aStream'),
  9686. messageSends: ["stream:", "new"],
  9687. referencedClasses: []
  9688. }),
  9689. smalltalk.ChunkParser.klass);
  9690. smalltalk.addClass('Importer', smalltalk.Object, [], 'Compiler');
  9691. smalltalk.addMethod(
  9692. unescape('_import_'),
  9693. smalltalk.method({
  9694. selector: unescape('import%3A'),
  9695. category: 'fileIn',
  9696. fn: function (aStream){
  9697. var self=this;
  9698. var chunk=nil;
  9699. var result=nil;
  9700. var parser=nil;
  9701. var lastEmpty=nil;
  9702. parser=smalltalk.send((smalltalk.ChunkParser || ChunkParser), "_on_", [aStream]);
  9703. lastEmpty=false;
  9704. (function(){while(!(function(){chunk=smalltalk.send(parser, "_nextChunk", []);return smalltalk.send(chunk, "_isNil", []);})()) {(function(){return ((($receiver = smalltalk.send(chunk, "_isEmpty", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return lastEmpty=true;})() : (function(){result=smalltalk.send(smalltalk.send((smalltalk.Compiler || Compiler), "_new", []), "_loadExpression_", [chunk]);return ((($receiver = lastEmpty).klass === smalltalk.Boolean) ? ($receiver ? (function(){lastEmpty=false;return smalltalk.send(result, "_scanFrom_", [parser]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){lastEmpty=false;return smalltalk.send(result, "_scanFrom_", [parser]);})]));})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return lastEmpty=true;}), (function(){result=smalltalk.send(smalltalk.send((smalltalk.Compiler || Compiler), "_new", []), "_loadExpression_", [chunk]);return ((($receiver = lastEmpty).klass === smalltalk.Boolean) ? ($receiver ? (function(){lastEmpty=false;return smalltalk.send(result, "_scanFrom_", [parser]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){lastEmpty=false;return smalltalk.send(result, "_scanFrom_", [parser]);})]));})]));})()}})();
  9705. return self;},
  9706. args: ["aStream"],
  9707. source: unescape('import%3A%20aStream%0A%20%20%20%20%7C%20chunk%20result%20parser%20lastEmpty%20%7C%0A%20%20%20%20parser%20%3A%3D%20ChunkParser%20on%3A%20aStream.%0A%20%20%20%20lastEmpty%20%3A%3D%20false.%0A%20%20%20%20%5Bchunk%20%3A%3D%20parser%20nextChunk.%0A%20%20%20%20%20chunk%20isNil%5D%20whileFalse%3A%20%5B%0A%20%20%20%20%20%20%20%20chunk%20isEmpty%0A%20%20%20%20%20%20%20%09%09ifTrue%3A%20%5BlastEmpty%20%3A%3D%20true%5D%0A%20%20%20%20%20%20%20%09%09ifFalse%3A%20%5B%0A%20%20%20%20%20%20%20%20%09%09result%20%3A%3D%20Compiler%20new%20loadExpression%3A%20chunk.%0A%20%20%20%20%20%20%20%20%09%09lastEmpty%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09lastEmpty%20%3A%3D%20false.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09result%20scanFrom%3A%20parser%5D%5D%5D'),
  9708. messageSends: ["on:", "whileFalse:", "nextChunk", "isNil", "ifTrue:ifFalse:", "isEmpty", "loadExpression:", "new", "ifTrue:", "scanFrom:"],
  9709. referencedClasses: ["ChunkParser", "Compiler"]
  9710. }),
  9711. smalltalk.Importer);
  9712. smalltalk.addClass('Exporter', smalltalk.Object, [], 'Compiler');
  9713. smalltalk.addMethod(
  9714. unescape('_exportDefinitionOf_on_'),
  9715. smalltalk.method({
  9716. selector: unescape('exportDefinitionOf%3Aon%3A'),
  9717. category: 'private',
  9718. fn: function (aClass, aStream){
  9719. var self=this;
  9720. (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("smalltalk.addClass%28")]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%27"), "__comma", [smalltalk.send(self, "_classNameFor_", [aClass])]), "__comma", [unescape("%27%2C%20")])]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send("smalltalk.", "__comma", [smalltalk.send(self, "_classNameFor_", [smalltalk.send(aClass, "_superclass", [])])])]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%2C%20%5B")]);})(aStream);
  9721. smalltalk.send(smalltalk.send(aClass, "_instanceVariableNames", []), "_do_separatedBy_", [(function(each){return smalltalk.send(aStream, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%27"), "__comma", [each]), "__comma", [unescape("%27")])]);}), (function(){return smalltalk.send(aStream, "_nextPutAll_", [unescape("%2C%20")]);})]);
  9722. (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("%5D%2C%20%27")]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(aClass, "_category", []), "__comma", [unescape("%27")])]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%29%3B")]);})(aStream);
  9723. ((($receiver = smalltalk.send(smalltalk.send(aClass, "_comment", []), "_notEmpty", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function($rec){smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", ["smalltalk."]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self, "_classNameFor_", [aClass])]);smalltalk.send($rec, "_nextPutAll_", [unescape(".comment%3D")]);return smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("unescape%28%27"), "__comma", [smalltalk.send(smalltalk.send(aClass, "_comment", []), "_escaped", [])]), "__comma", [unescape("%27%29")])]);})(aStream);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return (function($rec){smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", ["smalltalk."]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self, "_classNameFor_", [aClass])]);smalltalk.send($rec, "_nextPutAll_", [unescape(".comment%3D")]);return smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("unescape%28%27"), "__comma", [smalltalk.send(smalltalk.send(aClass, "_comment", []), "_escaped", [])]), "__comma", [unescape("%27%29")])]);})(aStream);})]));
  9724. smalltalk.send(aStream, "_lf", []);
  9725. return self;},
  9726. args: ["aClass", "aStream"],
  9727. source: unescape('exportDefinitionOf%3A%20aClass%20on%3A%20aStream%0A%09aStream%20%0A%09%20%20%20%20nextPutAll%3A%20%27smalltalk.addClass%28%27%3B%0A%09%20%20%20%20nextPutAll%3A%20%27%27%27%27%2C%20%28self%20classNameFor%3A%20aClass%29%2C%20%27%27%27%2C%20%27%3B%0A%09%20%20%20%20nextPutAll%3A%20%27smalltalk.%27%2C%20%28self%20classNameFor%3A%20aClass%20superclass%29%3B%0A%09%20%20%20%20nextPutAll%3A%20%27%2C%20%5B%27.%0A%09aClass%20instanceVariableNames%20%0A%09%20%20%20%20do%3A%20%5B%3Aeach%20%7C%20aStream%20nextPutAll%3A%20%27%27%27%27%2C%20each%2C%20%27%27%27%27%5D%0A%09%20%20%20%20separatedBy%3A%20%5BaStream%20nextPutAll%3A%20%27%2C%20%27%5D.%0A%09aStream%09%0A%09%20%20%20%20nextPutAll%3A%20%27%5D%2C%20%27%27%27%3B%0A%09%20%20%20%20nextPutAll%3A%20aClass%20category%2C%20%27%27%27%27%3B%0A%09%20%20%20%20nextPutAll%3A%20%27%29%3B%27.%0A%09aClass%20comment%20notEmpty%20ifTrue%3A%20%5B%0A%09%20%20%20%20aStream%20%0A%09%20%20%20%20%09lf%3B%0A%09%09nextPutAll%3A%20%27smalltalk.%27%3B%0A%09%09nextPutAll%3A%20%28self%20classNameFor%3A%20aClass%29%3B%0A%09%09nextPutAll%3A%20%27.comment%3D%27%3B%0A%09%09nextPutAll%3A%20%27unescape%28%27%27%27%2C%20aClass%20comment%20escaped%2C%20%27%27%27%29%27%5D.%0A%09aStream%20lf'),
  9728. messageSends: ["nextPutAll:", unescape("%2C"), "classNameFor:", "superclass", "do:separatedBy:", "instanceVariableNames", "category", "ifTrue:", "notEmpty", "comment", "lf", "escaped"],
  9729. referencedClasses: []
  9730. }),
  9731. smalltalk.Exporter);
  9732. smalltalk.addMethod(
  9733. unescape('_exportMetaDefinitionOf_on_'),
  9734. smalltalk.method({
  9735. selector: unescape('exportMetaDefinitionOf%3Aon%3A'),
  9736. category: 'private',
  9737. fn: function (aClass, aStream){
  9738. var self=this;
  9739. ((($receiver = smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_class", []), "_instanceVariableNames", []), "_isEmpty", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){(function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send("smalltalk.", "__comma", [smalltalk.send(self, "_classNameFor_", [smalltalk.send(aClass, "_class", [])])])]);return smalltalk.send($rec, "_nextPutAll_", [unescape(".iVarNames%20%3D%20%5B")]);})(aStream);smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_class", []), "_instanceVariableNames", []), "_do_separatedBy_", [(function(each){return smalltalk.send(aStream, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%27"), "__comma", [each]), "__comma", [unescape("%27")])]);}), (function(){return smalltalk.send(aStream, "_nextPutAll_", [unescape("%2C")]);})]);return smalltalk.send(aStream, "_nextPutAll_", [smalltalk.send(unescape("%5D%3B"), "__comma", [smalltalk.send((smalltalk.String || String), "_lf", [])])]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){(function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send("smalltalk.", "__comma", [smalltalk.send(self, "_classNameFor_", [smalltalk.send(aClass, "_class", [])])])]);return smalltalk.send($rec, "_nextPutAll_", [unescape(".iVarNames%20%3D%20%5B")]);})(aStream);smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_class", []), "_instanceVariableNames", []), "_do_separatedBy_", [(function(each){return smalltalk.send(aStream, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%27"), "__comma", [each]), "__comma", [unescape("%27")])]);}), (function(){return smalltalk.send(aStream, "_nextPutAll_", [unescape("%2C")]);})]);return smalltalk.send(aStream, "_nextPutAll_", [smalltalk.send(unescape("%5D%3B"), "__comma", [smalltalk.send((smalltalk.String || String), "_lf", [])])]);})]));
  9740. return self;},
  9741. args: ["aClass", "aStream"],
  9742. source: unescape('exportMetaDefinitionOf%3A%20aClass%20on%3A%20aStream%0A%09aClass%20class%20instanceVariableNames%20isEmpty%20ifFalse%3A%20%5B%0A%09%20%20%20%20aStream%20%0A%09%09nextPutAll%3A%20%27smalltalk.%27%2C%20%28self%20classNameFor%3A%20aClass%20class%29%3B%0A%09%09nextPutAll%3A%20%27.iVarNames%20%3D%20%5B%27.%0A%09%20%20%20%20aClass%20class%20instanceVariableNames%0A%09%09do%3A%20%5B%3Aeach%20%7C%20aStream%20nextPutAll%3A%20%27%27%27%27%2C%20each%2C%20%27%27%27%27%5D%0A%09%09separatedBy%3A%20%5BaStream%20nextPutAll%3A%20%27%2C%27%5D.%0A%09%20%20%20%20aStream%20nextPutAll%3A%20%27%5D%3B%27%2C%20String%20lf%5D'),
  9743. messageSends: ["ifFalse:", "isEmpty", "instanceVariableNames", "class", "nextPutAll:", unescape("%2C"), "classNameFor:", "do:separatedBy:", "lf"],
  9744. referencedClasses: ["String"]
  9745. }),
  9746. smalltalk.Exporter);
  9747. smalltalk.addMethod(
  9748. unescape('_exportMethodsOf_on_'),
  9749. smalltalk.method({
  9750. selector: unescape('exportMethodsOf%3Aon%3A'),
  9751. category: 'private',
  9752. fn: function (aClass, aStream){
  9753. var self=this;
  9754. smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_methodDictionary", []), "_values", []), "_do_", [(function(each){return ((($receiver = smalltalk.send(smalltalk.send(each, "_category", []), "_match_", [unescape("%5E%5C*")])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_exportMethod_of_on_", [each, aClass, aStream]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(self, "_exportMethod_of_on_", [each, aClass, aStream]);})]));})]);
  9755. smalltalk.send(aStream, "_lf", []);
  9756. return self;},
  9757. args: ["aClass", "aStream"],
  9758. source: unescape('exportMethodsOf%3A%20aClass%20on%3A%20aStream%0A%09aClass%20methodDictionary%20values%20do%3A%20%5B%3Aeach%20%7C%0A%09%09%28each%20category%20match%3A%20%27%5E%5C*%27%29%20ifFalse%3A%20%5B%0A%09%09%09self%20exportMethod%3A%20each%20of%3A%20aClass%20on%3A%20aStream%5D%5D.%0A%09aStream%20lf'),
  9759. messageSends: ["do:", "values", "methodDictionary", "ifFalse:", "match:", "category", "exportMethod:of:on:", "lf"],
  9760. referencedClasses: []
  9761. }),
  9762. smalltalk.Exporter);
  9763. smalltalk.addMethod(
  9764. unescape('_classNameFor_'),
  9765. smalltalk.method({
  9766. selector: unescape('classNameFor%3A'),
  9767. category: 'private',
  9768. fn: function (aClass){
  9769. var self=this;
  9770. return ((($receiver = smalltalk.send(aClass, "_isMetaclass", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_instanceClass", []), "_name", []), "__comma", [".klass"]);})() : (function(){return ((($receiver = smalltalk.send(aClass, "_isNil", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return "nil";})() : (function(){return smalltalk.send(aClass, "_name", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return "nil";}), (function(){return smalltalk.send(aClass, "_name", []);})]));})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_instanceClass", []), "_name", []), "__comma", [".klass"]);}), (function(){return ((($receiver = smalltalk.send(aClass, "_isNil", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return "nil";})() : (function(){return smalltalk.send(aClass, "_name", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return "nil";}), (function(){return smalltalk.send(aClass, "_name", []);})]));})]));
  9771. return self;},
  9772. args: ["aClass"],
  9773. source: unescape('classNameFor%3A%20aClass%0A%09%5EaClass%20isMetaclass%0A%09%20%20%20%20ifTrue%3A%20%5BaClass%20instanceClass%20name%2C%20%27.klass%27%5D%0A%09%20%20%20%20ifFalse%3A%20%5B%0A%09%09aClass%20isNil%0A%09%09%20%20%20%20ifTrue%3A%20%5B%27nil%27%5D%0A%09%09%20%20%20%20ifFalse%3A%20%5BaClass%20name%5D%5D'),
  9774. messageSends: ["ifTrue:ifFalse:", "isMetaclass", unescape("%2C"), "name", "instanceClass", "isNil"],
  9775. referencedClasses: []
  9776. }),
  9777. smalltalk.Exporter);
  9778. smalltalk.addMethod(
  9779. unescape('_exportMethod_of_on_'),
  9780. smalltalk.method({
  9781. selector: unescape('exportMethod%3Aof%3Aon%3A'),
  9782. category: 'private',
  9783. fn: function (aMethod, aClass, aStream){
  9784. var self=this;
  9785. (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("smalltalk.addMethod%28")]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("unescape%28%27"), "__comma", [smalltalk.send(smalltalk.send(smalltalk.send(aMethod, "_selector", []), "_asSelector", []), "_escaped", [])]), "__comma", [unescape("%27%29%2C")])]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [unescape("smalltalk.method%28%7B")]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("selector%3A%20unescape%28%27"), "__comma", [smalltalk.send(smalltalk.send(aMethod, "_selector", []), "_escaped", [])]), "__comma", [unescape("%27%29%2C")])]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("category%3A%20%27"), "__comma", [smalltalk.send(aMethod, "_category", [])]), "__comma", [unescape("%27%2C")])]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send("fn: ", "__comma", [smalltalk.send(smalltalk.send(aMethod, "_fn", []), "_compiledSource", [])]), "__comma", [unescape("%2C")])]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send("args: ", "__comma", [smalltalk.send(smalltalk.send(aMethod, "_arguments", []), "_asJavascript", [])]), "__comma", [unescape("%2C")])]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("source%3A%20unescape%28%27"), "__comma", [smalltalk.send(smalltalk.send(aMethod, "_source", []), "_escaped", [])]), "__comma", [unescape("%27%29%2C")])]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send("messageSends: ", "__comma", [smalltalk.send(smalltalk.send(aMethod, "_messageSends", []), "_asJavascript", [])]), "__comma", [unescape("%2C")])]);smalltalk.send($rec, "_lf", []);return smalltalk.send($rec, "_nextPutAll_", [smalltalk.send("referencedClasses: ", "__comma", [smalltalk.send(smalltalk.send(aMethod, "_referencedClasses", []), "_asJavascript", [])])]);})(aStream);
  9786. (function($rec){smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [unescape("%7D%29%2C")]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send("smalltalk.", "__comma", [smalltalk.send(self, "_classNameFor_", [aClass])])]);smalltalk.send($rec, "_nextPutAll_", [unescape("%29%3B")]);smalltalk.send($rec, "_lf", []);return smalltalk.send($rec, "_lf", []);})(aStream);
  9787. return self;},
  9788. args: ["aMethod", "aClass", "aStream"],
  9789. source: unescape('exportMethod%3A%20aMethod%20of%3A%20aClass%20on%3A%20aStream%0A%09aStream%20%0A%09%09nextPutAll%3A%20%27smalltalk.addMethod%28%27%3Blf%3B%0A%09%09nextPutAll%3A%20%27unescape%28%27%27%27%2C%20aMethod%20selector%20asSelector%20escaped%2C%20%27%27%27%29%2C%27%3Blf%3B%0A%09%09nextPutAll%3A%20%27smalltalk.method%28%7B%27%3Blf%3B%0A%09%09nextPutAll%3A%20%27selector%3A%20unescape%28%27%27%27%2C%20aMethod%20selector%20escaped%2C%20%27%27%27%29%2C%27%3Blf%3B%0A%09%09nextPutAll%3A%20%27category%3A%20%27%27%27%2C%20aMethod%20category%2C%20%27%27%27%2C%27%3Blf%3B%0A%09%09nextPutAll%3A%20%27fn%3A%20%27%2C%20aMethod%20fn%20compiledSource%2C%20%27%2C%27%3Blf%3B%0A%09%09nextPutAll%3A%20%27args%3A%20%27%2C%20aMethod%20arguments%20asJavascript%2C%20%27%2C%27%3B%20lf%3B%0A%09%09nextPutAll%3A%20%27source%3A%20unescape%28%27%27%27%2C%20aMethod%20source%20escaped%2C%20%27%27%27%29%2C%27%3Blf%3B%0A%09%09nextPutAll%3A%20%27messageSends%3A%20%27%2C%20aMethod%20messageSends%20asJavascript%2C%20%27%2C%27%3Blf%3B%0A%09%09nextPutAll%3A%20%27referencedClasses%3A%20%27%2C%20aMethod%20referencedClasses%20asJavascript.%0A%09aStream%0A%09%09lf%3B%0A%09%09nextPutAll%3A%20%27%7D%29%2C%27%3Blf%3B%0A%09%09nextPutAll%3A%20%27smalltalk.%27%2C%20%28self%20classNameFor%3A%20aClass%29%3B%0A%09%09nextPutAll%3A%20%27%29%3B%27%3Blf%3Blf'),
  9790. messageSends: ["nextPutAll:", "lf", unescape("%2C"), "escaped", "asSelector", "selector", "category", "compiledSource", "fn", "asJavascript", "arguments", "source", "messageSends", "referencedClasses", "classNameFor:"],
  9791. referencedClasses: []
  9792. }),
  9793. smalltalk.Exporter);
  9794. smalltalk.addMethod(
  9795. unescape('_exportPackage_'),
  9796. smalltalk.method({
  9797. selector: unescape('exportPackage%3A'),
  9798. category: 'fileOut',
  9799. fn: function (packageName){
  9800. var self=this;
  9801. var package=nil;
  9802. return smalltalk.send((smalltalk.String || String), "_streamContents_", [(function(stream){package=smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_packageAt_", [packageName]);smalltalk.send(self, "_exportPackageDefinitionOf_on_", [package, stream]);smalltalk.send(smalltalk.send(package, "_classes", []), "_do_", [(function(each){return smalltalk.send(stream, "_nextPutAll_", [smalltalk.send(self, "_exportClass_", [each])]);})]);return smalltalk.send(self, "_exportPackageExtensionsOf_on_", [package, stream]);})]);
  9803. return self;},
  9804. args: ["packageName"],
  9805. source: unescape('exportPackage%3A%20packageName%0A%09%22Export%20a%20given%20package%20by%20name.%22%0A%0A%09%7C%20package%20%7C%0A%09%5EString%20streamContents%3A%20%5B%3Astream%20%7C%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20package%20%3A%3D%20Smalltalk%20current%20packageAt%3A%20packageName.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20exportPackageDefinitionOf%3A%20package%20on%3A%20stream.%0A%09%20%20%20%20%09package%20classes%20do%3A%20%5B%3Aeach%20%7C%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20stream%20nextPutAll%3A%20%28self%20exportClass%3A%20each%29%5D.%0A%09%09self%20exportPackageExtensionsOf%3A%20package%20on%3A%20stream%5D'),
  9806. messageSends: ["streamContents:", "packageAt:", "current", "exportPackageDefinitionOf:on:", "do:", "classes", "nextPutAll:", "exportClass:", "exportPackageExtensionsOf:on:"],
  9807. referencedClasses: ["String", "Smalltalk"]
  9808. }),
  9809. smalltalk.Exporter);
  9810. smalltalk.addMethod(
  9811. unescape('_exportAll'),
  9812. smalltalk.method({
  9813. selector: unescape('exportAll'),
  9814. category: 'fileOut',
  9815. fn: function (){
  9816. var self=this;
  9817. return smalltalk.send((smalltalk.String || String), "_streamContents_", [(function(stream){return smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_packages", []), "_do_", [(function(pkg){return smalltalk.send(stream, "_nextPutAll_", [smalltalk.send(self, "_exportPackage_", [smalltalk.send(pkg, "_name", [])])]);})]);})]);
  9818. return self;},
  9819. args: [],
  9820. source: unescape('exportAll%0A%20%20%20%20%22Export%20all%20packages%20in%20the%20system.%22%0A%0A%20%20%20%20%5EString%20streamContents%3A%20%5B%3Astream%20%7C%0A%20%20%20%20%09Smalltalk%20current%20packages%20do%3A%20%5B%3Apkg%20%7C%0A%09%09stream%20nextPutAll%3A%20%28self%20exportPackage%3A%20pkg%20name%29%5D%5D'),
  9821. messageSends: ["streamContents:", "do:", "packages", "current", "nextPutAll:", "exportPackage:", "name"],
  9822. referencedClasses: ["String", "Smalltalk"]
  9823. }),
  9824. smalltalk.Exporter);
  9825. smalltalk.addMethod(
  9826. unescape('_exportClass_'),
  9827. smalltalk.method({
  9828. selector: unescape('exportClass%3A'),
  9829. category: 'fileOut',
  9830. fn: function (aClass){
  9831. var self=this;
  9832. return smalltalk.send((smalltalk.String || String), "_streamContents_", [(function(stream){smalltalk.send(self, "_exportDefinitionOf_on_", [aClass, stream]);smalltalk.send(self, "_exportMethodsOf_on_", [aClass, stream]);smalltalk.send(self, "_exportMetaDefinitionOf_on_", [aClass, stream]);return smalltalk.send(self, "_exportMethodsOf_on_", [smalltalk.send(aClass, "_class", []), stream]);})]);
  9833. return self;},
  9834. args: ["aClass"],
  9835. source: unescape('exportClass%3A%20aClass%0A%09%22Export%20a%20single%20class.%20Subclasses%20override%20these%20methods.%22%0A%0A%09%5EString%20streamContents%3A%20%5B%3Astream%20%7C%0A%09%09self%20exportDefinitionOf%3A%20aClass%20on%3A%20stream.%0A%09%09self%20exportMethodsOf%3A%20aClass%20on%3A%20stream.%0A%09%09self%20exportMetaDefinitionOf%3A%20aClass%20on%3A%20stream.%0A%09%09self%20exportMethodsOf%3A%20aClass%20class%20on%3A%20stream%5D'),
  9836. messageSends: ["streamContents:", "exportDefinitionOf:on:", "exportMethodsOf:on:", "exportMetaDefinitionOf:on:", "class"],
  9837. referencedClasses: ["String"]
  9838. }),
  9839. smalltalk.Exporter);
  9840. smalltalk.addMethod(
  9841. unescape('_exportPackageExtensionsOf_on_'),
  9842. smalltalk.method({
  9843. selector: unescape('exportPackageExtensionsOf%3Aon%3A'),
  9844. category: 'private',
  9845. fn: function (package, aStream){
  9846. var self=this;
  9847. var name=nil;
  9848. name=smalltalk.send(package, "_name", []);
  9849. smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_classes", []), "__comma", [smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_classes", []), "_collect_", [(function(each){return smalltalk.send(each, "_class", []);})])]), "_do_", [(function(each){return smalltalk.send(smalltalk.send(smalltalk.send(each, "_methodDictionary", []), "_values", []), "_do_", [(function(method){return ((($receiver = smalltalk.send(smalltalk.send(method, "_category", []), "__eq", [smalltalk.send(unescape("*"), "__comma", [name])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self, "_exportMethod_of_on_", [method, each, aStream]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(self, "_exportMethod_of_on_", [method, each, aStream]);})]));})]);})]);
  9850. return self;},
  9851. args: ["package", "aStream"],
  9852. source: unescape('exportPackageExtensionsOf%3A%20package%20on%3A%20aStream%0A%09%7C%20name%20%7C%0A%09name%20%3A%3D%20package%20name.%0A%09Smalltalk%20current%20classes%2C%20%28Smalltalk%20current%20classes%20collect%3A%20%5B%3Aeach%20%7C%20each%20class%5D%29%20do%3A%20%5B%3Aeach%20%7C%0A%09%09each%20methodDictionary%20values%20do%3A%20%5B%3Amethod%20%7C%0A%09%09%09method%20category%20%3D%20%28%27*%27%2C%20name%29%20ifTrue%3A%20%5B%0A%09%09%09%09self%20exportMethod%3A%20method%20of%3A%20each%20on%3A%20aStream%5D%5D%5D'),
  9853. messageSends: ["name", "do:", unescape("%2C"), "classes", "current", "collect:", "class", "values", "methodDictionary", "ifTrue:", unescape("%3D"), "category", "exportMethod:of:on:"],
  9854. referencedClasses: ["Smalltalk"]
  9855. }),
  9856. smalltalk.Exporter);
  9857. smalltalk.addMethod(
  9858. unescape('_exportPackageDefinitionOf_on_'),
  9859. smalltalk.method({
  9860. selector: unescape('exportPackageDefinitionOf%3Aon%3A'),
  9861. category: 'private',
  9862. fn: function (package, aStream){
  9863. var self=this;
  9864. (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("smalltalk.addPackage%28")]);return smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(unescape("%27"), "__comma", [smalltalk.send(package, "_name", [])]), "__comma", [unescape("%27%2C%20")]), "__comma", [smalltalk.send(package, "_propertiesAsJSON", [])]), "__comma", [unescape("%29%3B")])]);})(aStream);
  9865. smalltalk.send(aStream, "_lf", []);
  9866. return self;},
  9867. args: ["package", "aStream"],
  9868. source: unescape('exportPackageDefinitionOf%3A%20package%20on%3A%20aStream%0A%09aStream%20%0A%09%20%20%20%20nextPutAll%3A%20%27smalltalk.addPackage%28%27%3B%0A%09%20%20%20%20nextPutAll%3A%20%27%27%27%27%2C%20package%20name%2C%20%27%27%27%2C%20%27%2C%20package%20propertiesAsJSON%20%2C%20%27%29%3B%27.%0A%09aStream%20lf'),
  9869. messageSends: ["nextPutAll:", unescape("%2C"), "name", "propertiesAsJSON", "lf"],
  9870. referencedClasses: []
  9871. }),
  9872. smalltalk.Exporter);
  9873. smalltalk.addClass('ChunkExporter', smalltalk.Exporter, [], 'Compiler');
  9874. smalltalk.addMethod(
  9875. unescape('_exportDefinitionOf_on_'),
  9876. smalltalk.method({
  9877. selector: unescape('exportDefinitionOf%3Aon%3A'),
  9878. category: 'not yet classified',
  9879. fn: function (aClass, aStream){
  9880. var self=this;
  9881. (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self, "_classNameFor_", [smalltalk.send(aClass, "_superclass", [])])]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(unescape("%20subclass%3A%20%23"), "__comma", [smalltalk.send(self, "_classNameFor_", [aClass])])]);smalltalk.send($rec, "_lf", []);return smalltalk.send($rec, "_nextPutAll_", [unescape("%09instanceVariableNames%3A%20%27")]);})(aStream);
  9882. smalltalk.send(smalltalk.send(aClass, "_instanceVariableNames", []), "_do_separatedBy_", [(function(each){return smalltalk.send(aStream, "_nextPutAll_", [each]);}), (function(){return smalltalk.send(aStream, "_nextPutAll_", [" "]);})]);
  9883. (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("%27")]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%09category%3A%20%27"), "__comma", [smalltalk.send(aClass, "_category", [])]), "__comma", [unescape("%27%21")])]);return smalltalk.send($rec, "_lf", []);})(aStream);
  9884. ((($receiver = smalltalk.send(smalltalk.send(aClass, "_comment", []), "_notEmpty", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%21"), "__comma", [smalltalk.send(self, "_classNameFor_", [aClass])]), "__comma", [unescape("%20commentStamp%21")])]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(self, "_chunkEscape_", [smalltalk.send(aClass, "_comment", [])]), "__comma", [unescape("%21")])]);return smalltalk.send($rec, "_lf", []);})(aStream);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%21"), "__comma", [smalltalk.send(self, "_classNameFor_", [aClass])]), "__comma", [unescape("%20commentStamp%21")])]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(self, "_chunkEscape_", [smalltalk.send(aClass, "_comment", [])]), "__comma", [unescape("%21")])]);return smalltalk.send($rec, "_lf", []);})(aStream);})]));
  9885. smalltalk.send(aStream, "_lf", []);
  9886. return self;},
  9887. args: ["aClass", "aStream"],
  9888. source: unescape('exportDefinitionOf%3A%20aClass%20on%3A%20aStream%0A%09%22Chunk%20format.%22%0A%0A%09aStream%20%0A%09%20%20%20%20nextPutAll%3A%20%28self%20classNameFor%3A%20aClass%20superclass%29%3B%0A%09%20%20%20%20nextPutAll%3A%20%27%20subclass%3A%20%23%27%2C%20%28self%20classNameFor%3A%20aClass%29%3B%20lf%3B%0A%09%20%20%20%20nextPutAll%3A%20%27%09instanceVariableNames%3A%20%27%27%27.%0A%09aClass%20instanceVariableNames%20%0A%09%20%20%20%20do%3A%20%5B%3Aeach%20%7C%20aStream%20nextPutAll%3A%20each%5D%0A%09%20%20%20%20separatedBy%3A%20%5BaStream%20nextPutAll%3A%20%27%20%27%5D.%0A%09aStream%09%0A%09%20%20%20%20nextPutAll%3A%20%27%27%27%27%3B%20lf%3B%0A%09%20%20%20%20nextPutAll%3A%20%27%09category%3A%20%27%27%27%2C%20aClass%20category%2C%20%27%27%27%21%27%3B%20lf.%0A%20%09aClass%20comment%20notEmpty%20ifTrue%3A%20%5B%0A%09%20%20%20%20aStream%20%0A%09%09nextPutAll%3A%20%27%21%27%2C%20%28self%20classNameFor%3A%20aClass%29%2C%20%27%20commentStamp%21%27%3Blf%3B%0A%09%09nextPutAll%3A%20%28self%20chunkEscape%3A%20aClass%20comment%29%2C%20%27%21%27%3Blf%5D.%0A%09aStream%20lf'),
  9889. messageSends: ["nextPutAll:", "classNameFor:", "superclass", unescape("%2C"), "lf", "do:separatedBy:", "instanceVariableNames", "category", "ifTrue:", "notEmpty", "comment", "chunkEscape:"],
  9890. referencedClasses: []
  9891. }),
  9892. smalltalk.ChunkExporter);
  9893. smalltalk.addMethod(
  9894. unescape('_exportMethod_of_on_'),
  9895. smalltalk.method({
  9896. selector: unescape('exportMethod%3Aof%3Aon%3A'),
  9897. category: 'not yet classified',
  9898. fn: function (aMethod, aClass, aStream){
  9899. var self=this;
  9900. (function($rec){smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self, "_chunkEscape_", [smalltalk.send(aMethod, "_source", [])])]);smalltalk.send($rec, "_lf", []);return smalltalk.send($rec, "_nextPutAll_", [unescape("%21")]);})(aStream);
  9901. return self;},
  9902. args: ["aMethod", "aClass", "aStream"],
  9903. source: unescape('exportMethod%3A%20aMethod%20of%3A%20aClass%20on%3A%20aStream%0A%09aStream%20%0A%09%09lf%3B%20lf%3B%20nextPutAll%3A%20%28self%20chunkEscape%3A%20aMethod%20source%29%3B%20lf%3B%0A%09%09nextPutAll%3A%20%27%21%27'),
  9904. messageSends: ["lf", "nextPutAll:", "chunkEscape:", "source"],
  9905. referencedClasses: []
  9906. }),
  9907. smalltalk.ChunkExporter);
  9908. smalltalk.addMethod(
  9909. unescape('_exportMethodsOf_on_'),
  9910. smalltalk.method({
  9911. selector: unescape('exportMethodsOf%3Aon%3A'),
  9912. category: 'not yet classified',
  9913. fn: function (aClass, aStream){
  9914. var self=this;
  9915. smalltalk.send(aClass, "_protocolsDo_", [(function(category, methods){return ((($receiver = smalltalk.send(category, "_match_", [unescape("%5E%5C*")])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_exportMethods_category_of_on_", [methods, category, aClass, aStream]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(self, "_exportMethods_category_of_on_", [methods, category, aClass, aStream]);})]));})]);
  9916. return self;},
  9917. args: ["aClass", "aStream"],
  9918. source: unescape('exportMethodsOf%3A%20aClass%20on%3A%20aStream%0A%0A%20%20%20aClass%20protocolsDo%3A%20%5B%3Acategory%20%3Amethods%20%7C%0A%09%28category%20match%3A%20%27%5E%5C*%27%29%20ifFalse%3A%20%5B%20%0A%09%09self%0A%09%09%09exportMethods%3A%20methods%0A%09%09%09category%3A%20category%0A%09%09%09of%3A%20aClass%0A%09%09%09on%3A%20aStream%5D%5D'),
  9919. messageSends: ["protocolsDo:", "ifFalse:", "match:", "exportMethods:category:of:on:"],
  9920. referencedClasses: []
  9921. }),
  9922. smalltalk.ChunkExporter);
  9923. smalltalk.addMethod(
  9924. unescape('_exportMetaDefinitionOf_on_'),
  9925. smalltalk.method({
  9926. selector: unescape('exportMetaDefinitionOf%3Aon%3A'),
  9927. category: 'not yet classified',
  9928. fn: function (aClass, aStream){
  9929. var self=this;
  9930. ((($receiver = smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_class", []), "_instanceVariableNames", []), "_isEmpty", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){(function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self, "_classNameFor_", [smalltalk.send(aClass, "_class", [])])]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%20instanceVariableNames%3A%20%27")]);})(aStream);smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_class", []), "_instanceVariableNames", []), "_do_separatedBy_", [(function(each){return smalltalk.send(aStream, "_nextPutAll_", [each]);}), (function(){return smalltalk.send(aStream, "_nextPutAll_", [" "]);})]);return (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("%27%21")]);smalltalk.send($rec, "_lf", []);return smalltalk.send($rec, "_lf", []);})(aStream);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){(function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self, "_classNameFor_", [smalltalk.send(aClass, "_class", [])])]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%20instanceVariableNames%3A%20%27")]);})(aStream);smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_class", []), "_instanceVariableNames", []), "_do_separatedBy_", [(function(each){return smalltalk.send(aStream, "_nextPutAll_", [each]);}), (function(){return smalltalk.send(aStream, "_nextPutAll_", [" "]);})]);return (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("%27%21")]);smalltalk.send($rec, "_lf", []);return smalltalk.send($rec, "_lf", []);})(aStream);})]));
  9931. return self;},
  9932. args: ["aClass", "aStream"],
  9933. source: unescape('exportMetaDefinitionOf%3A%20aClass%20on%3A%20aStream%0A%0A%09aClass%20class%20instanceVariableNames%20isEmpty%20ifFalse%3A%20%5B%0A%09%09aStream%20%0A%09%09%20%20%20%20nextPutAll%3A%20%28self%20classNameFor%3A%20aClass%20class%29%3B%0A%09%09%20%20%20%20nextPutAll%3A%20%27%20instanceVariableNames%3A%20%27%27%27.%0A%09%09aClass%20class%20instanceVariableNames%20%0A%09%09%20%20%20%20do%3A%20%5B%3Aeach%20%7C%20aStream%20nextPutAll%3A%20each%5D%0A%09%09%20%20%20%20separatedBy%3A%20%5BaStream%20nextPutAll%3A%20%27%20%27%5D.%0A%09%09aStream%09%0A%09%09%20%20%20%20nextPutAll%3A%20%27%27%27%21%27%3B%20lf%3B%20lf%5D'),
  9934. messageSends: ["ifFalse:", "isEmpty", "instanceVariableNames", "class", "nextPutAll:", "classNameFor:", "do:separatedBy:", "lf"],
  9935. referencedClasses: []
  9936. }),
  9937. smalltalk.ChunkExporter);
  9938. smalltalk.addMethod(
  9939. unescape('_classNameFor_'),
  9940. smalltalk.method({
  9941. selector: unescape('classNameFor%3A'),
  9942. category: 'not yet classified',
  9943. fn: function (aClass){
  9944. var self=this;
  9945. return ((($receiver = smalltalk.send(aClass, "_isMetaclass", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_instanceClass", []), "_name", []), "__comma", [" class"]);})() : (function(){return ((($receiver = smalltalk.send(aClass, "_isNil", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return "nil";})() : (function(){return smalltalk.send(aClass, "_name", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return "nil";}), (function(){return smalltalk.send(aClass, "_name", []);})]));})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_instanceClass", []), "_name", []), "__comma", [" class"]);}), (function(){return ((($receiver = smalltalk.send(aClass, "_isNil", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return "nil";})() : (function(){return smalltalk.send(aClass, "_name", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return "nil";}), (function(){return smalltalk.send(aClass, "_name", []);})]));})]));
  9946. return self;},
  9947. args: ["aClass"],
  9948. source: unescape('classNameFor%3A%20aClass%0A%09%5EaClass%20isMetaclass%0A%09%20%20%20%20ifTrue%3A%20%5BaClass%20instanceClass%20name%2C%20%27%20class%27%5D%0A%09%20%20%20%20ifFalse%3A%20%5B%0A%09%09aClass%20isNil%0A%09%09%20%20%20%20ifTrue%3A%20%5B%27nil%27%5D%0A%09%09%20%20%20%20ifFalse%3A%20%5BaClass%20name%5D%5D'),
  9949. messageSends: ["ifTrue:ifFalse:", "isMetaclass", unescape("%2C"), "name", "instanceClass", "isNil"],
  9950. referencedClasses: []
  9951. }),
  9952. smalltalk.ChunkExporter);
  9953. smalltalk.addMethod(
  9954. unescape('_chunkEscape_'),
  9955. smalltalk.method({
  9956. selector: unescape('chunkEscape%3A'),
  9957. category: 'not yet classified',
  9958. fn: function (aString){
  9959. var self=this;
  9960. return smalltalk.send(smalltalk.send(aString, "_replace_with_", [unescape("%21"), unescape("%21%21")]), "_trimBoth", []);
  9961. return self;},
  9962. args: ["aString"],
  9963. source: unescape('chunkEscape%3A%20aString%0A%09%22Replace%20all%20occurrences%20of%20%21%20with%20%21%21%20and%20trim%20at%20both%20ends.%22%0A%0A%09%5E%28aString%20replace%3A%20%27%21%27%20with%3A%20%27%21%21%27%29%20trimBoth'),
  9964. messageSends: ["trimBoth", "replace:with:"],
  9965. referencedClasses: []
  9966. }),
  9967. smalltalk.ChunkExporter);
  9968. smalltalk.addMethod(
  9969. unescape('_exportMethods_category_of_on_'),
  9970. smalltalk.method({
  9971. selector: unescape('exportMethods%3Acategory%3Aof%3Aon%3A'),
  9972. category: 'not yet classified',
  9973. fn: function (methods, category, aClass, aStream){
  9974. var self=this;
  9975. (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(unescape("%21"), "__comma", [smalltalk.send(self, "_classNameFor_", [aClass])])]);return smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%20methodsFor%3A%20%27"), "__comma", [category]), "__comma", [unescape("%27%21")])]);})(aStream);
  9976. smalltalk.send(methods, "_do_", [(function(each){return smalltalk.send(self, "_exportMethod_of_on_", [each, aClass, aStream]);})]);
  9977. (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("%20%21")]);smalltalk.send($rec, "_lf", []);return smalltalk.send($rec, "_lf", []);})(aStream);
  9978. return self;},
  9979. args: ["methods", "category", "aClass", "aStream"],
  9980. source: unescape('exportMethods%3A%20methods%20category%3A%20category%20of%3A%20aClass%20on%3A%20aStream%0A%0A%09aStream%0A%09%09nextPutAll%3A%20%27%21%27%2C%20%28self%20classNameFor%3A%20aClass%29%3B%0A%09%09nextPutAll%3A%20%27%20methodsFor%3A%20%27%27%27%2C%20category%2C%20%27%27%27%21%27.%0A%20%20%20%20%09methods%20do%3A%20%5B%3Aeach%20%7C%0A%09%09self%20exportMethod%3A%20each%20of%3A%20aClass%20on%3A%20aStream%5D.%0A%09aStream%20nextPutAll%3A%20%27%20%21%27%3B%20lf%3B%20lf'),
  9981. messageSends: ["nextPutAll:", unescape("%2C"), "classNameFor:", "do:", "exportMethod:of:on:", "lf"],
  9982. referencedClasses: []
  9983. }),
  9984. smalltalk.ChunkExporter);
  9985. smalltalk.addMethod(
  9986. unescape('_exportPackageExtensionsOf_on_'),
  9987. smalltalk.method({
  9988. selector: unescape('exportPackageExtensionsOf%3Aon%3A'),
  9989. category: 'not yet classified',
  9990. fn: function (package, aStream){
  9991. var self=this;
  9992. var name=nil;
  9993. name=smalltalk.send(package, "_name", []);
  9994. smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_classes", []), "__comma", [smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_classes", []), "_collect_", [(function(each){return smalltalk.send(each, "_class", []);})])]), "_do_", [(function(each){return smalltalk.send(each, "_protocolsDo_", [(function(category, methods){return ((($receiver = smalltalk.send(category, "__eq", [smalltalk.send(unescape("*"), "__comma", [name])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self, "_exportMethods_category_of_on_", [methods, category, each, aStream]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(self, "_exportMethods_category_of_on_", [methods, category, each, aStream]);})]));})]);})]);
  9995. return self;},
  9996. args: ["package", "aStream"],
  9997. source: unescape('exportPackageExtensionsOf%3A%20package%20on%3A%20aStream%0A%09%22We%20need%20to%20override%20this%20one%20too%20since%20we%20need%20to%20group%0A%09all%20methods%20in%20a%20given%20protocol%20under%20a%20leading%20methodsFor%3A%20chunk%0A%09for%20that%20class.%22%0A%0A%09%7C%20name%20%7C%0A%09name%20%3A%3D%20package%20name.%0A%09Smalltalk%20current%20classes%2C%20%28Smalltalk%20current%20classes%20collect%3A%20%5B%3Aeach%20%7C%20each%20class%5D%29%20do%3A%20%5B%3Aeach%20%7C%0A%09%09each%20protocolsDo%3A%20%5B%3Acategory%20%3Amethods%20%7C%0A%09%09%09category%20%3D%20%28%27*%27%2C%20name%29%20ifTrue%3A%20%5B%0A%09%09%09%09self%20exportMethods%3A%20methods%20category%3A%20category%20of%3A%20each%20on%3A%20aStream%5D%5D%5D'),
  9998. messageSends: ["name", "do:", unescape("%2C"), "classes", "current", "collect:", "class", "protocolsDo:", "ifTrue:", unescape("%3D"), "exportMethods:category:of:on:"],
  9999. referencedClasses: ["Smalltalk"]
  10000. }),
  10001. smalltalk.ChunkExporter);
  10002. smalltalk.addMethod(
  10003. unescape('_exportPackageDefinitionOf_on_'),
  10004. smalltalk.method({
  10005. selector: unescape('exportPackageDefinitionOf%3Aon%3A'),
  10006. category: 'not yet classified',
  10007. fn: function (package, aStream){
  10008. var self=this;
  10009. (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(unescape("Smalltalk%20current%20createPackage%3A%20%27"), "__comma", [smalltalk.send(package, "_name", [])]), "__comma", [unescape("%27%20properties%3A%20")]), "__comma", [smalltalk.send(smalltalk.send(package, "_properties", []), "_storeString", [])]), "__comma", [unescape("%21")])]);return smalltalk.send($rec, "_lf", []);})(aStream);
  10010. return self;},
  10011. args: ["package", "aStream"],
  10012. source: unescape('exportPackageDefinitionOf%3A%20package%20on%3A%20aStream%0A%09%22Chunk%20format.%22%0A%0A%09aStream%20%0A%09%20%20%20%20nextPutAll%3A%20%27Smalltalk%20current%20createPackage%3A%20%27%27%27%2C%20package%20name%2C%0A%09%09%27%27%27%20properties%3A%20%27%2C%20package%20properties%20storeString%2C%20%27%21%27%3B%20lf.'),
  10013. messageSends: ["nextPutAll:", unescape("%2C"), "name", "storeString", "properties", "lf"],
  10014. referencedClasses: []
  10015. }),
  10016. smalltalk.ChunkExporter);
  10017. smalltalk.addClass('StrippedExporter', smalltalk.Exporter, [], 'Compiler');
  10018. smalltalk.addMethod(
  10019. unescape('_exportDefinitionOf_on_'),
  10020. smalltalk.method({
  10021. selector: unescape('exportDefinitionOf%3Aon%3A'),
  10022. category: 'private',
  10023. fn: function (aClass, aStream){
  10024. var self=this;
  10025. (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("smalltalk.addClass%28")]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%27"), "__comma", [smalltalk.send(self, "_classNameFor_", [aClass])]), "__comma", [unescape("%27%2C%20")])]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send("smalltalk.", "__comma", [smalltalk.send(self, "_classNameFor_", [smalltalk.send(aClass, "_superclass", [])])])]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%2C%20%5B")]);})(aStream);
  10026. smalltalk.send(smalltalk.send(aClass, "_instanceVariableNames", []), "_do_separatedBy_", [(function(each){return smalltalk.send(aStream, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%27"), "__comma", [each]), "__comma", [unescape("%27")])]);}), (function(){return smalltalk.send(aStream, "_nextPutAll_", [unescape("%2C%20")]);})]);
  10027. (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("%5D%2C%20%27")]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(aClass, "_category", []), "__comma", [unescape("%27")])]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%29%3B")]);})(aStream);
  10028. smalltalk.send(aStream, "_lf", []);
  10029. return self;},
  10030. args: ["aClass", "aStream"],
  10031. source: unescape('exportDefinitionOf%3A%20aClass%20on%3A%20aStream%0A%09aStream%20%0A%09%20%20%20%20nextPutAll%3A%20%27smalltalk.addClass%28%27%3B%0A%09%20%20%20%20nextPutAll%3A%20%27%27%27%27%2C%20%28self%20classNameFor%3A%20aClass%29%2C%20%27%27%27%2C%20%27%3B%0A%09%20%20%20%20nextPutAll%3A%20%27smalltalk.%27%2C%20%28self%20classNameFor%3A%20aClass%20superclass%29%3B%0A%09%20%20%20%20nextPutAll%3A%20%27%2C%20%5B%27.%0A%09aClass%20instanceVariableNames%20%0A%09%20%20%20%20do%3A%20%5B%3Aeach%20%7C%20aStream%20nextPutAll%3A%20%27%27%27%27%2C%20each%2C%20%27%27%27%27%5D%0A%09%20%20%20%20separatedBy%3A%20%5BaStream%20nextPutAll%3A%20%27%2C%20%27%5D.%0A%09aStream%09%0A%09%20%20%20%20nextPutAll%3A%20%27%5D%2C%20%27%27%27%3B%0A%09%20%20%20%20nextPutAll%3A%20aClass%20category%2C%20%27%27%27%27%3B%0A%09%20%20%20%20nextPutAll%3A%20%27%29%3B%27.%0A%09aStream%20lf'),
  10032. messageSends: ["nextPutAll:", unescape("%2C"), "classNameFor:", "superclass", "do:separatedBy:", "instanceVariableNames", "category", "lf"],
  10033. referencedClasses: []
  10034. }),
  10035. smalltalk.StrippedExporter);
  10036. smalltalk.addMethod(
  10037. unescape('_exportMethod_of_on_'),
  10038. smalltalk.method({
  10039. selector: unescape('exportMethod%3Aof%3Aon%3A'),
  10040. category: 'private',
  10041. fn: function (aMethod, aClass, aStream){
  10042. var self=this;
  10043. (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("smalltalk.addMethod%28")]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%27"), "__comma", [smalltalk.send(smalltalk.send(aMethod, "_selector", []), "_asSelector", [])]), "__comma", [unescape("%27%2C")])]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [unescape("smalltalk.method%28%7B")]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("selector%3A%20%27"), "__comma", [smalltalk.send(aMethod, "_selector", [])]), "__comma", [unescape("%27%2C")])]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send("fn: ", "__comma", [smalltalk.send(smalltalk.send(aMethod, "_fn", []), "_compiledSource", [])])]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [unescape("%7D%29%2C")]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send("smalltalk.", "__comma", [smalltalk.send(self, "_classNameFor_", [aClass])])]);smalltalk.send($rec, "_nextPutAll_", [unescape("%29%3B")]);smalltalk.send($rec, "_lf", []);return smalltalk.send($rec, "_lf", []);})(aStream);
  10044. return self;},
  10045. args: ["aMethod", "aClass", "aStream"],
  10046. source: unescape('exportMethod%3A%20aMethod%20of%3A%20aClass%20on%3A%20aStream%0A%09aStream%20%0A%09%09nextPutAll%3A%20%27smalltalk.addMethod%28%27%3Blf%3B%0A%09%09nextPutAll%3A%20%27%27%27%27%2C%20aMethod%20selector%20asSelector%2C%20%27%27%27%2C%27%3Blf%3B%0A%09%09nextPutAll%3A%20%27smalltalk.method%28%7B%27%3Blf%3B%0A%09%09nextPutAll%3A%20%27selector%3A%20%27%27%27%2C%20aMethod%20selector%2C%20%27%27%27%2C%27%3Blf%3B%0A%09%09nextPutAll%3A%20%27fn%3A%20%27%2C%20aMethod%20fn%20compiledSource%3Blf%3B%0A%09%09nextPutAll%3A%20%27%7D%29%2C%27%3Blf%3B%0A%09%09nextPutAll%3A%20%27smalltalk.%27%2C%20%28self%20classNameFor%3A%20aClass%29%3B%0A%09%09nextPutAll%3A%20%27%29%3B%27%3Blf%3Blf'),
  10047. messageSends: ["nextPutAll:", "lf", unescape("%2C"), "asSelector", "selector", "compiledSource", "fn", "classNameFor:"],
  10048. referencedClasses: []
  10049. }),
  10050. smalltalk.StrippedExporter);
  10051. smalltalk.addClass('Node', smalltalk.Object, ['nodes'], 'Compiler');
  10052. smalltalk.addMethod(
  10053. unescape('_nodes'),
  10054. smalltalk.method({
  10055. selector: unescape('nodes'),
  10056. category: 'accessing',
  10057. fn: function (){
  10058. var self=this;
  10059. return (($receiver = self['@nodes']) == nil || $receiver == undefined) ? (function(){return self['@nodes']=smalltalk.send((smalltalk.Array || Array), "_new", []);})() : $receiver;
  10060. return self;},
  10061. args: [],
  10062. source: unescape('nodes%0A%09%5Enodes%20ifNil%3A%20%5Bnodes%20%3A%3D%20Array%20new%5D'),
  10063. messageSends: ["ifNil:", "new"],
  10064. referencedClasses: ["Array"]
  10065. }),
  10066. smalltalk.Node);
  10067. smalltalk.addMethod(
  10068. unescape('_nodes_'),
  10069. smalltalk.method({
  10070. selector: unescape('nodes%3A'),
  10071. category: 'building',
  10072. fn: function (aCollection){
  10073. var self=this;
  10074. self['@nodes']=aCollection;
  10075. return self;},
  10076. args: ["aCollection"],
  10077. source: unescape('nodes%3A%20aCollection%0A%09nodes%20%3A%3D%20aCollection'),
  10078. messageSends: [],
  10079. referencedClasses: []
  10080. }),
  10081. smalltalk.Node);
  10082. smalltalk.addMethod(
  10083. unescape('_addNode_'),
  10084. smalltalk.method({
  10085. selector: unescape('addNode%3A'),
  10086. category: 'accessing',
  10087. fn: function (aNode){
  10088. var self=this;
  10089. smalltalk.send(smalltalk.send(self, "_nodes", []), "_add_", [aNode]);
  10090. return self;},
  10091. args: ["aNode"],
  10092. source: unescape('addNode%3A%20aNode%0A%09self%20nodes%20add%3A%20aNode'),
  10093. messageSends: ["add:", "nodes"],
  10094. referencedClasses: []
  10095. }),
  10096. smalltalk.Node);
  10097. smalltalk.addMethod(
  10098. unescape('_accept_'),
  10099. smalltalk.method({
  10100. selector: unescape('accept%3A'),
  10101. category: 'visiting',
  10102. fn: function (aVisitor){
  10103. var self=this;
  10104. smalltalk.send(aVisitor, "_visitNode_", [self]);
  10105. return self;},
  10106. args: ["aVisitor"],
  10107. source: unescape('accept%3A%20aVisitor%0A%09aVisitor%20visitNode%3A%20self'),
  10108. messageSends: ["visitNode:"],
  10109. referencedClasses: []
  10110. }),
  10111. smalltalk.Node);
  10112. smalltalk.addMethod(
  10113. unescape('_isValueNode'),
  10114. smalltalk.method({
  10115. selector: unescape('isValueNode'),
  10116. category: 'testing',
  10117. fn: function (){
  10118. var self=this;
  10119. return false;
  10120. return self;},
  10121. args: [],
  10122. source: unescape('isValueNode%0A%09%5Efalse'),
  10123. messageSends: [],
  10124. referencedClasses: []
  10125. }),
  10126. smalltalk.Node);
  10127. smalltalk.addMethod(
  10128. unescape('_isBlockNode'),
  10129. smalltalk.method({
  10130. selector: unescape('isBlockNode'),
  10131. category: 'testing',
  10132. fn: function (){
  10133. var self=this;
  10134. return false;
  10135. return self;},
  10136. args: [],
  10137. source: unescape('isBlockNode%0A%09%5Efalse'),
  10138. messageSends: [],
  10139. referencedClasses: []
  10140. }),
  10141. smalltalk.Node);
  10142. smalltalk.addMethod(
  10143. unescape('_isBlockSequenceNode'),
  10144. smalltalk.method({
  10145. selector: unescape('isBlockSequenceNode'),
  10146. category: 'testing',
  10147. fn: function (){
  10148. var self=this;
  10149. return false;
  10150. return self;},
  10151. args: [],
  10152. source: unescape('isBlockSequenceNode%0A%09%5Efalse'),
  10153. messageSends: [],
  10154. referencedClasses: []
  10155. }),
  10156. smalltalk.Node);
  10157. smalltalk.addClass('MethodNode', smalltalk.Node, ['selector', 'arguments', 'source'], 'Compiler');
  10158. smalltalk.addMethod(
  10159. unescape('_selector'),
  10160. smalltalk.method({
  10161. selector: unescape('selector'),
  10162. category: 'accessing',
  10163. fn: function (){
  10164. var self=this;
  10165. return self['@selector'];
  10166. return self;},
  10167. args: [],
  10168. source: unescape('selector%0A%09%5Eselector'),
  10169. messageSends: [],
  10170. referencedClasses: []
  10171. }),
  10172. smalltalk.MethodNode);
  10173. smalltalk.addMethod(
  10174. unescape('_selector_'),
  10175. smalltalk.method({
  10176. selector: unescape('selector%3A'),
  10177. category: 'accessing',
  10178. fn: function (aString){
  10179. var self=this;
  10180. self['@selector']=aString;
  10181. return self;},
  10182. args: ["aString"],
  10183. source: unescape('selector%3A%20aString%0A%09selector%20%3A%3D%20aString'),
  10184. messageSends: [],
  10185. referencedClasses: []
  10186. }),
  10187. smalltalk.MethodNode);
  10188. smalltalk.addMethod(
  10189. unescape('_arguments'),
  10190. smalltalk.method({
  10191. selector: unescape('arguments'),
  10192. category: 'accessing',
  10193. fn: function (){
  10194. var self=this;
  10195. return (($receiver = self['@arguments']) == nil || $receiver == undefined) ? (function(){return [];})() : $receiver;
  10196. return self;},
  10197. args: [],
  10198. source: unescape('arguments%0A%09%5Earguments%20ifNil%3A%20%5B%23%28%29%5D'),
  10199. messageSends: ["ifNil:"],
  10200. referencedClasses: []
  10201. }),
  10202. smalltalk.MethodNode);
  10203. smalltalk.addMethod(
  10204. unescape('_arguments_'),
  10205. smalltalk.method({
  10206. selector: unescape('arguments%3A'),
  10207. category: 'accessing',
  10208. fn: function (aCollection){
  10209. var self=this;
  10210. self['@arguments']=aCollection;
  10211. return self;},
  10212. args: ["aCollection"],
  10213. source: unescape('arguments%3A%20aCollection%0A%09arguments%20%3A%3D%20aCollection'),
  10214. messageSends: [],
  10215. referencedClasses: []
  10216. }),
  10217. smalltalk.MethodNode);
  10218. smalltalk.addMethod(
  10219. unescape('_source'),
  10220. smalltalk.method({
  10221. selector: unescape('source'),
  10222. category: 'accessing',
  10223. fn: function (){
  10224. var self=this;
  10225. return self['@source'];
  10226. return self;},
  10227. args: [],
  10228. source: unescape('source%0A%09%5Esource'),
  10229. messageSends: [],
  10230. referencedClasses: []
  10231. }),
  10232. smalltalk.MethodNode);
  10233. smalltalk.addMethod(
  10234. unescape('_source_'),
  10235. smalltalk.method({
  10236. selector: unescape('source%3A'),
  10237. category: 'accessing',
  10238. fn: function (aString){
  10239. var self=this;
  10240. self['@source']=aString;
  10241. return self;},
  10242. args: ["aString"],
  10243. source: unescape('source%3A%20aString%0A%09source%20%3A%3D%20aString'),
  10244. messageSends: [],
  10245. referencedClasses: []
  10246. }),
  10247. smalltalk.MethodNode);
  10248. smalltalk.addMethod(
  10249. unescape('_accept_'),
  10250. smalltalk.method({
  10251. selector: unescape('accept%3A'),
  10252. category: 'visiting',
  10253. fn: function (aVisitor){
  10254. var self=this;
  10255. smalltalk.send(aVisitor, "_visitMethodNode_", [self]);
  10256. return self;},
  10257. args: ["aVisitor"],
  10258. source: unescape('accept%3A%20aVisitor%0A%09aVisitor%20visitMethodNode%3A%20self'),
  10259. messageSends: ["visitMethodNode:"],
  10260. referencedClasses: []
  10261. }),
  10262. smalltalk.MethodNode);
  10263. smalltalk.addClass('SendNode', smalltalk.Node, ['selector', 'arguments', 'receiver'], 'Compiler');
  10264. smalltalk.addMethod(
  10265. unescape('_selector'),
  10266. smalltalk.method({
  10267. selector: unescape('selector'),
  10268. category: 'accessing',
  10269. fn: function (){
  10270. var self=this;
  10271. return self['@selector'];
  10272. return self;},
  10273. args: [],
  10274. source: unescape('selector%0A%09%5Eselector'),
  10275. messageSends: [],
  10276. referencedClasses: []
  10277. }),
  10278. smalltalk.SendNode);
  10279. smalltalk.addMethod(
  10280. unescape('_selector_'),
  10281. smalltalk.method({
  10282. selector: unescape('selector%3A'),
  10283. category: 'accessing',
  10284. fn: function (aString){
  10285. var self=this;
  10286. self['@selector']=aString;
  10287. return self;},
  10288. args: ["aString"],
  10289. source: unescape('selector%3A%20aString%0A%09selector%20%3A%3D%20aString'),
  10290. messageSends: [],
  10291. referencedClasses: []
  10292. }),
  10293. smalltalk.SendNode);
  10294. smalltalk.addMethod(
  10295. unescape('_arguments'),
  10296. smalltalk.method({
  10297. selector: unescape('arguments'),
  10298. category: 'accessing',
  10299. fn: function (){
  10300. var self=this;
  10301. return (($receiver = self['@arguments']) == nil || $receiver == undefined) ? (function(){return self['@arguments']=[];})() : $receiver;
  10302. return self;},
  10303. args: [],
  10304. source: unescape('arguments%0A%09%5Earguments%20ifNil%3A%20%5Barguments%20%3A%3D%20%23%28%29%5D'),
  10305. messageSends: ["ifNil:"],
  10306. referencedClasses: []
  10307. }),
  10308. smalltalk.SendNode);
  10309. smalltalk.addMethod(
  10310. unescape('_arguments_'),
  10311. smalltalk.method({
  10312. selector: unescape('arguments%3A'),
  10313. category: 'accessing',
  10314. fn: function (aCollection){
  10315. var self=this;
  10316. self['@arguments']=aCollection;
  10317. return self;},
  10318. args: ["aCollection"],
  10319. source: unescape('arguments%3A%20aCollection%0A%09arguments%20%3A%3D%20aCollection'),
  10320. messageSends: [],
  10321. referencedClasses: []
  10322. }),
  10323. smalltalk.SendNode);
  10324. smalltalk.addMethod(
  10325. unescape('_receiver'),
  10326. smalltalk.method({
  10327. selector: unescape('receiver'),
  10328. category: 'accessing',
  10329. fn: function (){
  10330. var self=this;
  10331. return self['@receiver'];
  10332. return self;},
  10333. args: [],
  10334. source: unescape('receiver%0A%09%5Ereceiver'),
  10335. messageSends: [],
  10336. referencedClasses: []
  10337. }),
  10338. smalltalk.SendNode);
  10339. smalltalk.addMethod(
  10340. unescape('_receiver_'),
  10341. smalltalk.method({
  10342. selector: unescape('receiver%3A'),
  10343. category: 'accessing',
  10344. fn: function (aNode){
  10345. var self=this;
  10346. self['@receiver']=aNode;
  10347. return self;},
  10348. args: ["aNode"],
  10349. source: unescape('receiver%3A%20aNode%0A%09receiver%20%3A%3D%20aNode'),
  10350. messageSends: [],
  10351. referencedClasses: []
  10352. }),
  10353. smalltalk.SendNode);
  10354. smalltalk.addMethod(
  10355. unescape('_valueForReceiver_'),
  10356. smalltalk.method({
  10357. selector: unescape('valueForReceiver%3A'),
  10358. category: 'accessing',
  10359. fn: function (anObject){
  10360. var self=this;
  10361. return (function($rec){smalltalk.send($rec, "_receiver_", [(($receiver = smalltalk.send(self, "_receiver", [])) == nil || $receiver == undefined) ? (function(){return anObject;})() : (function(){return smalltalk.send(smalltalk.send(self, "_receiver", []), "_valueForReceiver_", [anObject]);})()]);smalltalk.send($rec, "_selector_", [smalltalk.send(self, "_selector", [])]);smalltalk.send($rec, "_arguments_", [smalltalk.send(self, "_arguments", [])]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send((smalltalk.SendNode || SendNode), "_new", []));
  10362. return self;},
  10363. args: ["anObject"],
  10364. source: unescape('valueForReceiver%3A%20anObject%0A%09%5ESendNode%20new%0A%09%20%20%20%20receiver%3A%20%28self%20receiver%20%0A%09%09ifNil%3A%20%5BanObject%5D%0A%09%09ifNotNil%3A%20%5Bself%20receiver%20valueForReceiver%3A%20anObject%5D%29%3B%0A%09%20%20%20%20selector%3A%20self%20selector%3B%0A%09%20%20%20%20arguments%3A%20self%20arguments%3B%0A%09%20%20%20%20yourself'),
  10365. messageSends: ["receiver:", "ifNil:ifNotNil:", "receiver", "valueForReceiver:", "selector:", "selector", "arguments:", "arguments", "yourself", "new"],
  10366. referencedClasses: ["SendNode"]
  10367. }),
  10368. smalltalk.SendNode);
  10369. smalltalk.addMethod(
  10370. unescape('_cascadeNodeWithMessages_'),
  10371. smalltalk.method({
  10372. selector: unescape('cascadeNodeWithMessages%3A'),
  10373. category: 'accessing',
  10374. fn: function (aCollection){
  10375. var self=this;
  10376. var first=nil;
  10377. first=(function($rec){smalltalk.send($rec, "_selector_", [smalltalk.send(self, "_selector", [])]);smalltalk.send($rec, "_arguments_", [smalltalk.send(self, "_arguments", [])]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send((smalltalk.SendNode || SendNode), "_new", []));
  10378. return (function($rec){smalltalk.send($rec, "_receiver_", [smalltalk.send(self, "_receiver", [])]);smalltalk.send($rec, "_nodes_", [smalltalk.send(smalltalk.send((smalltalk.Array || Array), "_with_", [first]), "__comma", [aCollection])]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send((smalltalk.CascadeNode || CascadeNode), "_new", []));
  10379. return self;},
  10380. args: ["aCollection"],
  10381. source: unescape('cascadeNodeWithMessages%3A%20aCollection%0A%09%7C%20first%20%7C%0A%09first%20%3A%3D%20SendNode%20new%0A%09%20%20%20%20selector%3A%20self%20selector%3B%0A%09%20%20%20%20arguments%3A%20self%20arguments%3B%0A%09%20%20%20%20yourself.%0A%09%5ECascadeNode%20new%0A%09%20%20%20%20receiver%3A%20self%20receiver%3B%0A%09%20%20%20%20nodes%3A%20%28Array%20with%3A%20first%29%2C%20aCollection%3B%0A%09%20%20%20%20yourself'),
  10382. messageSends: ["selector:", "selector", "arguments:", "arguments", "yourself", "new", "receiver:", "receiver", "nodes:", unescape("%2C"), "with:"],
  10383. referencedClasses: ["SendNode", "Array", "CascadeNode"]
  10384. }),
  10385. smalltalk.SendNode);
  10386. smalltalk.addMethod(
  10387. unescape('_accept_'),
  10388. smalltalk.method({
  10389. selector: unescape('accept%3A'),
  10390. category: 'visiting',
  10391. fn: function (aVisitor){
  10392. var self=this;
  10393. smalltalk.send(aVisitor, "_visitSendNode_", [self]);
  10394. return self;},
  10395. args: ["aVisitor"],
  10396. source: unescape('accept%3A%20aVisitor%0A%09aVisitor%20visitSendNode%3A%20self'),
  10397. messageSends: ["visitSendNode:"],
  10398. referencedClasses: []
  10399. }),
  10400. smalltalk.SendNode);
  10401. smalltalk.addClass('CascadeNode', smalltalk.Node, ['receiver'], 'Compiler');
  10402. smalltalk.addMethod(
  10403. unescape('_receiver'),
  10404. smalltalk.method({
  10405. selector: unescape('receiver'),
  10406. category: 'accessing',
  10407. fn: function (){
  10408. var self=this;
  10409. return self['@receiver'];
  10410. return self;},
  10411. args: [],
  10412. source: unescape('receiver%0A%09%5Ereceiver'),
  10413. messageSends: [],
  10414. referencedClasses: []
  10415. }),
  10416. smalltalk.CascadeNode);
  10417. smalltalk.addMethod(
  10418. unescape('_receiver_'),
  10419. smalltalk.method({
  10420. selector: unescape('receiver%3A'),
  10421. category: 'accessing',
  10422. fn: function (aNode){
  10423. var self=this;
  10424. self['@receiver']=aNode;
  10425. return self;},
  10426. args: ["aNode"],
  10427. source: unescape('receiver%3A%20aNode%0A%09receiver%20%3A%3D%20aNode'),
  10428. messageSends: [],
  10429. referencedClasses: []
  10430. }),
  10431. smalltalk.CascadeNode);
  10432. smalltalk.addMethod(
  10433. unescape('_accept_'),
  10434. smalltalk.method({
  10435. selector: unescape('accept%3A'),
  10436. category: 'visiting',
  10437. fn: function (aVisitor){
  10438. var self=this;
  10439. smalltalk.send(aVisitor, "_visitCascadeNode_", [self]);
  10440. return self;},
  10441. args: ["aVisitor"],
  10442. source: unescape('accept%3A%20aVisitor%0A%09aVisitor%20visitCascadeNode%3A%20self'),
  10443. messageSends: ["visitCascadeNode:"],
  10444. referencedClasses: []
  10445. }),
  10446. smalltalk.CascadeNode);
  10447. smalltalk.addClass('AssignmentNode', smalltalk.Node, ['left', 'right'], 'Compiler');
  10448. smalltalk.addMethod(
  10449. unescape('_left'),
  10450. smalltalk.method({
  10451. selector: unescape('left'),
  10452. category: 'accessing',
  10453. fn: function (){
  10454. var self=this;
  10455. return self['@left'];
  10456. return self;},
  10457. args: [],
  10458. source: unescape('left%0A%09%5Eleft'),
  10459. messageSends: [],
  10460. referencedClasses: []
  10461. }),
  10462. smalltalk.AssignmentNode);
  10463. smalltalk.addMethod(
  10464. unescape('_left_'),
  10465. smalltalk.method({
  10466. selector: unescape('left%3A'),
  10467. category: 'accessing',
  10468. fn: function (aNode){
  10469. var self=this;
  10470. self['@left']=aNode;
  10471. smalltalk.send(self['@left'], "_assigned_", [true]);
  10472. return self;},
  10473. args: ["aNode"],
  10474. source: unescape('left%3A%20aNode%0A%09left%20%3A%3D%20aNode.%0A%09left%20assigned%3A%20true'),
  10475. messageSends: ["assigned:"],
  10476. referencedClasses: []
  10477. }),
  10478. smalltalk.AssignmentNode);
  10479. smalltalk.addMethod(
  10480. unescape('_right'),
  10481. smalltalk.method({
  10482. selector: unescape('right'),
  10483. category: 'accessing',
  10484. fn: function (){
  10485. var self=this;
  10486. return self['@right'];
  10487. return self;},
  10488. args: [],
  10489. source: unescape('right%0A%09%5Eright'),
  10490. messageSends: [],
  10491. referencedClasses: []
  10492. }),
  10493. smalltalk.AssignmentNode);
  10494. smalltalk.addMethod(
  10495. unescape('_right_'),
  10496. smalltalk.method({
  10497. selector: unescape('right%3A'),
  10498. category: 'accessing',
  10499. fn: function (aNode){
  10500. var self=this;
  10501. self['@right']=aNode;
  10502. return self;},
  10503. args: ["aNode"],
  10504. source: unescape('right%3A%20aNode%0A%09right%20%3A%3D%20aNode'),
  10505. messageSends: [],
  10506. referencedClasses: []
  10507. }),
  10508. smalltalk.AssignmentNode);
  10509. smalltalk.addMethod(
  10510. unescape('_accept_'),
  10511. smalltalk.method({
  10512. selector: unescape('accept%3A'),
  10513. category: 'visiting',
  10514. fn: function (aVisitor){
  10515. var self=this;
  10516. smalltalk.send(aVisitor, "_visitAssignmentNode_", [self]);
  10517. return self;},
  10518. args: ["aVisitor"],
  10519. source: unescape('accept%3A%20aVisitor%0A%09aVisitor%20visitAssignmentNode%3A%20self'),
  10520. messageSends: ["visitAssignmentNode:"],
  10521. referencedClasses: []
  10522. }),
  10523. smalltalk.AssignmentNode);
  10524. smalltalk.addClass('BlockNode', smalltalk.Node, ['parameters', 'inlined'], 'Compiler');
  10525. smalltalk.addMethod(
  10526. unescape('_parameters'),
  10527. smalltalk.method({
  10528. selector: unescape('parameters'),
  10529. category: 'accessing',
  10530. fn: function (){
  10531. var self=this;
  10532. return (($receiver = self['@parameters']) == nil || $receiver == undefined) ? (function(){return self['@parameters']=smalltalk.send((smalltalk.Array || Array), "_new", []);})() : $receiver;
  10533. return self;},
  10534. args: [],
  10535. source: unescape('parameters%0A%09%5Eparameters%20ifNil%3A%20%5Bparameters%20%3A%3D%20Array%20new%5D'),
  10536. messageSends: ["ifNil:", "new"],
  10537. referencedClasses: ["Array"]
  10538. }),
  10539. smalltalk.BlockNode);
  10540. smalltalk.addMethod(
  10541. unescape('_parameters_'),
  10542. smalltalk.method({
  10543. selector: unescape('parameters%3A'),
  10544. category: 'accessing',
  10545. fn: function (aCollection){
  10546. var self=this;
  10547. self['@parameters']=aCollection;
  10548. return self;},
  10549. args: ["aCollection"],
  10550. source: unescape('parameters%3A%20aCollection%0A%09parameters%20%3A%3D%20aCollection'),
  10551. messageSends: [],
  10552. referencedClasses: []
  10553. }),
  10554. smalltalk.BlockNode);
  10555. smalltalk.addMethod(
  10556. unescape('_accept_'),
  10557. smalltalk.method({
  10558. selector: unescape('accept%3A'),
  10559. category: 'visiting',
  10560. fn: function (aVisitor){
  10561. var self=this;
  10562. smalltalk.send(aVisitor, "_visitBlockNode_", [self]);
  10563. return self;},
  10564. args: ["aVisitor"],
  10565. source: unescape('accept%3A%20aVisitor%0A%09aVisitor%20visitBlockNode%3A%20self'),
  10566. messageSends: ["visitBlockNode:"],
  10567. referencedClasses: []
  10568. }),
  10569. smalltalk.BlockNode);
  10570. smalltalk.addMethod(
  10571. unescape('_isBlockNode'),
  10572. smalltalk.method({
  10573. selector: unescape('isBlockNode'),
  10574. category: 'testing',
  10575. fn: function (){
  10576. var self=this;
  10577. return true;
  10578. return self;},
  10579. args: [],
  10580. source: unescape('isBlockNode%0A%09%5Etrue'),
  10581. messageSends: [],
  10582. referencedClasses: []
  10583. }),
  10584. smalltalk.BlockNode);
  10585. smalltalk.addMethod(
  10586. unescape('_inlined'),
  10587. smalltalk.method({
  10588. selector: unescape('inlined'),
  10589. category: 'accessing',
  10590. fn: function (){
  10591. var self=this;
  10592. return (($receiver = self['@inlined']) == nil || $receiver == undefined) ? (function(){return false;})() : $receiver;
  10593. return self;},
  10594. args: [],
  10595. source: unescape('inlined%0A%09%5Einlined%20ifNil%3A%20%5Bfalse%5D'),
  10596. messageSends: ["ifNil:"],
  10597. referencedClasses: []
  10598. }),
  10599. smalltalk.BlockNode);
  10600. smalltalk.addMethod(
  10601. unescape('_inlined_'),
  10602. smalltalk.method({
  10603. selector: unescape('inlined%3A'),
  10604. category: 'accessing',
  10605. fn: function (aBoolean){
  10606. var self=this;
  10607. self['@inlined']=aBoolean;
  10608. return self;},
  10609. args: ["aBoolean"],
  10610. source: unescape('inlined%3A%20aBoolean%0A%09inlined%20%3A%3D%20aBoolean'),
  10611. messageSends: [],
  10612. referencedClasses: []
  10613. }),
  10614. smalltalk.BlockNode);
  10615. smalltalk.addClass('SequenceNode', smalltalk.Node, ['temps'], 'Compiler');
  10616. smalltalk.addMethod(
  10617. unescape('_temps'),
  10618. smalltalk.method({
  10619. selector: unescape('temps'),
  10620. category: 'accessing',
  10621. fn: function (){
  10622. var self=this;
  10623. return (($receiver = self['@temps']) == nil || $receiver == undefined) ? (function(){return [];})() : $receiver;
  10624. return self;},
  10625. args: [],
  10626. source: unescape('temps%0A%09%5Etemps%20ifNil%3A%20%5B%23%28%29%5D'),
  10627. messageSends: ["ifNil:"],
  10628. referencedClasses: []
  10629. }),
  10630. smalltalk.SequenceNode);
  10631. smalltalk.addMethod(
  10632. unescape('_temps_'),
  10633. smalltalk.method({
  10634. selector: unescape('temps%3A'),
  10635. category: 'accessing',
  10636. fn: function (aCollection){
  10637. var self=this;
  10638. self['@temps']=aCollection;
  10639. return self;},
  10640. args: ["aCollection"],
  10641. source: unescape('temps%3A%20aCollection%0A%09temps%20%3A%3D%20aCollection'),
  10642. messageSends: [],
  10643. referencedClasses: []
  10644. }),
  10645. smalltalk.SequenceNode);
  10646. smalltalk.addMethod(
  10647. unescape('_asBlockSequenceNode'),
  10648. smalltalk.method({
  10649. selector: unescape('asBlockSequenceNode'),
  10650. category: 'testing',
  10651. fn: function (){
  10652. var self=this;
  10653. return (function($rec){smalltalk.send($rec, "_nodes_", [smalltalk.send(self, "_nodes", [])]);smalltalk.send($rec, "_temps_", [smalltalk.send(self, "_temps", [])]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send((smalltalk.BlockSequenceNode || BlockSequenceNode), "_new", []));
  10654. return self;},
  10655. args: [],
  10656. source: unescape('asBlockSequenceNode%0A%09%5EBlockSequenceNode%20new%0A%09%20%20%20%20nodes%3A%20self%20nodes%3B%0A%09%20%20%20%20temps%3A%20self%20temps%3B%0A%09%20%20%20%20yourself'),
  10657. messageSends: ["nodes:", "nodes", "temps:", "temps", "yourself", "new"],
  10658. referencedClasses: ["BlockSequenceNode"]
  10659. }),
  10660. smalltalk.SequenceNode);
  10661. smalltalk.addMethod(
  10662. unescape('_accept_'),
  10663. smalltalk.method({
  10664. selector: unescape('accept%3A'),
  10665. category: 'visiting',
  10666. fn: function (aVisitor){
  10667. var self=this;
  10668. smalltalk.send(aVisitor, "_visitSequenceNode_", [self]);
  10669. return self;},
  10670. args: ["aVisitor"],
  10671. source: unescape('accept%3A%20aVisitor%0A%09aVisitor%20visitSequenceNode%3A%20self'),
  10672. messageSends: ["visitSequenceNode:"],
  10673. referencedClasses: []
  10674. }),
  10675. smalltalk.SequenceNode);
  10676. smalltalk.addClass('BlockSequenceNode', smalltalk.SequenceNode, [], 'Compiler');
  10677. smalltalk.addMethod(
  10678. unescape('_accept_'),
  10679. smalltalk.method({
  10680. selector: unescape('accept%3A'),
  10681. category: 'visiting',
  10682. fn: function (aVisitor){
  10683. var self=this;
  10684. smalltalk.send(aVisitor, "_visitBlockSequenceNode_", [self]);
  10685. return self;},
  10686. args: ["aVisitor"],
  10687. source: unescape('accept%3A%20aVisitor%0A%09aVisitor%20visitBlockSequenceNode%3A%20self'),
  10688. messageSends: ["visitBlockSequenceNode:"],
  10689. referencedClasses: []
  10690. }),
  10691. smalltalk.BlockSequenceNode);
  10692. smalltalk.addMethod(
  10693. unescape('_isBlockSequenceNode'),
  10694. smalltalk.method({
  10695. selector: unescape('isBlockSequenceNode'),
  10696. category: 'testing',
  10697. fn: function (){
  10698. var self=this;
  10699. return true;
  10700. return self;},
  10701. args: [],
  10702. source: unescape('isBlockSequenceNode%0A%09%5Etrue'),
  10703. messageSends: [],
  10704. referencedClasses: []
  10705. }),
  10706. smalltalk.BlockSequenceNode);
  10707. smalltalk.addClass('ReturnNode', smalltalk.Node, [], 'Compiler');
  10708. smalltalk.addMethod(
  10709. unescape('_accept_'),
  10710. smalltalk.method({
  10711. selector: unescape('accept%3A'),
  10712. category: 'visiting',
  10713. fn: function (aVisitor){
  10714. var self=this;
  10715. smalltalk.send(aVisitor, "_visitReturnNode_", [self]);
  10716. return self;},
  10717. args: ["aVisitor"],
  10718. source: unescape('accept%3A%20aVisitor%0A%09aVisitor%20visitReturnNode%3A%20self'),
  10719. messageSends: ["visitReturnNode:"],
  10720. referencedClasses: []
  10721. }),
  10722. smalltalk.ReturnNode);
  10723. smalltalk.addClass('ValueNode', smalltalk.Node, ['value'], 'Compiler');
  10724. smalltalk.addMethod(
  10725. unescape('_value'),
  10726. smalltalk.method({
  10727. selector: unescape('value'),
  10728. category: 'accessing',
  10729. fn: function (){
  10730. var self=this;
  10731. return self['@value'];
  10732. return self;},
  10733. args: [],
  10734. source: unescape('value%0A%09%5Evalue'),
  10735. messageSends: [],
  10736. referencedClasses: []
  10737. }),
  10738. smalltalk.ValueNode);
  10739. smalltalk.addMethod(
  10740. unescape('_value_'),
  10741. smalltalk.method({
  10742. selector: unescape('value%3A'),
  10743. category: 'accessing',
  10744. fn: function (anObject){
  10745. var self=this;
  10746. self['@value']=anObject;
  10747. return self;},
  10748. args: ["anObject"],
  10749. source: unescape('value%3A%20anObject%0A%09value%20%3A%3D%20anObject'),
  10750. messageSends: [],
  10751. referencedClasses: []
  10752. }),
  10753. smalltalk.ValueNode);
  10754. smalltalk.addMethod(
  10755. unescape('_accept_'),
  10756. smalltalk.method({
  10757. selector: unescape('accept%3A'),
  10758. category: 'visiting',
  10759. fn: function (aVisitor){
  10760. var self=this;
  10761. smalltalk.send(aVisitor, "_visitValueNode_", [self]);
  10762. return self;},
  10763. args: ["aVisitor"],
  10764. source: unescape('accept%3A%20aVisitor%0A%09aVisitor%20visitValueNode%3A%20self'),
  10765. messageSends: ["visitValueNode:"],
  10766. referencedClasses: []
  10767. }),
  10768. smalltalk.ValueNode);
  10769. smalltalk.addMethod(
  10770. unescape('_isValueNode'),
  10771. smalltalk.method({
  10772. selector: unescape('isValueNode'),
  10773. category: 'testing',
  10774. fn: function (){
  10775. var self=this;
  10776. return true;
  10777. return self;},
  10778. args: [],
  10779. source: unescape('isValueNode%0A%09%5Etrue'),
  10780. messageSends: [],
  10781. referencedClasses: []
  10782. }),
  10783. smalltalk.ValueNode);
  10784. smalltalk.addClass('VariableNode', smalltalk.ValueNode, ['assigned'], 'Compiler');
  10785. smalltalk.addMethod(
  10786. unescape('_accept_'),
  10787. smalltalk.method({
  10788. selector: unescape('accept%3A'),
  10789. category: 'visiting',
  10790. fn: function (aVisitor){
  10791. var self=this;
  10792. smalltalk.send(aVisitor, "_visitVariableNode_", [self]);
  10793. return self;},
  10794. args: ["aVisitor"],
  10795. source: unescape('accept%3A%20aVisitor%0A%09aVisitor%20visitVariableNode%3A%20self'),
  10796. messageSends: ["visitVariableNode:"],
  10797. referencedClasses: []
  10798. }),
  10799. smalltalk.VariableNode);
  10800. smalltalk.addMethod(
  10801. unescape('_assigned'),
  10802. smalltalk.method({
  10803. selector: unescape('assigned'),
  10804. category: 'accessing',
  10805. fn: function (){
  10806. var self=this;
  10807. return (($receiver = self['@assigned']) == nil || $receiver == undefined) ? (function(){return false;})() : $receiver;
  10808. return self;},
  10809. args: [],
  10810. source: unescape('assigned%0A%09%5Eassigned%20ifNil%3A%20%5Bfalse%5D'),
  10811. messageSends: ["ifNil:"],
  10812. referencedClasses: []
  10813. }),
  10814. smalltalk.VariableNode);
  10815. smalltalk.addMethod(
  10816. unescape('_assigned_'),
  10817. smalltalk.method({
  10818. selector: unescape('assigned%3A'),
  10819. category: 'accessing',
  10820. fn: function (aBoolean){
  10821. var self=this;
  10822. self['@assigned']=aBoolean;
  10823. return self;},
  10824. args: ["aBoolean"],
  10825. source: unescape('assigned%3A%20aBoolean%0A%09assigned%20%3A%3D%20aBoolean'),
  10826. messageSends: [],
  10827. referencedClasses: []
  10828. }),
  10829. smalltalk.VariableNode);
  10830. smalltalk.addClass('ClassReferenceNode', smalltalk.VariableNode, [], 'Compiler');
  10831. smalltalk.addMethod(
  10832. unescape('_accept_'),
  10833. smalltalk.method({
  10834. selector: unescape('accept%3A'),
  10835. category: 'visiting',
  10836. fn: function (aVisitor){
  10837. var self=this;
  10838. smalltalk.send(aVisitor, "_visitClassReferenceNode_", [self]);
  10839. return self;},
  10840. args: ["aVisitor"],
  10841. source: unescape('accept%3A%20aVisitor%0A%09aVisitor%20visitClassReferenceNode%3A%20self'),
  10842. messageSends: ["visitClassReferenceNode:"],
  10843. referencedClasses: []
  10844. }),
  10845. smalltalk.ClassReferenceNode);
  10846. smalltalk.addClass('JSStatementNode', smalltalk.Node, ['source'], 'Compiler');
  10847. smalltalk.addMethod(
  10848. unescape('_source'),
  10849. smalltalk.method({
  10850. selector: unescape('source'),
  10851. category: 'accessing',
  10852. fn: function (){
  10853. var self=this;
  10854. return (($receiver = self['@source']) == nil || $receiver == undefined) ? (function(){return "";})() : $receiver;
  10855. return self;},
  10856. args: [],
  10857. source: unescape('source%0A%09%5Esource%20ifNil%3A%20%5B%27%27%5D'),
  10858. messageSends: ["ifNil:"],
  10859. referencedClasses: []
  10860. }),
  10861. smalltalk.JSStatementNode);
  10862. smalltalk.addMethod(
  10863. unescape('_source_'),
  10864. smalltalk.method({
  10865. selector: unescape('source%3A'),
  10866. category: 'accessing',
  10867. fn: function (aString){
  10868. var self=this;
  10869. self['@source']=aString;
  10870. return self;},
  10871. args: ["aString"],
  10872. source: unescape('source%3A%20aString%0A%09source%20%3A%3D%20aString'),
  10873. messageSends: [],
  10874. referencedClasses: []
  10875. }),
  10876. smalltalk.JSStatementNode);
  10877. smalltalk.addMethod(
  10878. unescape('_accept_'),
  10879. smalltalk.method({
  10880. selector: unescape('accept%3A'),
  10881. category: 'visiting',
  10882. fn: function (aVisitor){
  10883. var self=this;
  10884. smalltalk.send(aVisitor, "_visitJSStatementNode_", [self]);
  10885. return self;},
  10886. args: ["aVisitor"],
  10887. source: unescape('accept%3A%20aVisitor%0A%09aVisitor%20visitJSStatementNode%3A%20self'),
  10888. messageSends: ["visitJSStatementNode:"],
  10889. referencedClasses: []
  10890. }),
  10891. smalltalk.JSStatementNode);
  10892. smalltalk.addClass('NodeVisitor', smalltalk.Object, [], 'Compiler');
  10893. smalltalk.addMethod(
  10894. unescape('_visit_'),
  10895. smalltalk.method({
  10896. selector: unescape('visit%3A'),
  10897. category: 'visiting',
  10898. fn: function (aNode){
  10899. var self=this;
  10900. smalltalk.send(aNode, "_accept_", [self]);
  10901. return self;},
  10902. args: ["aNode"],
  10903. source: unescape('visit%3A%20aNode%0A%09aNode%20accept%3A%20self'),
  10904. messageSends: ["accept:"],
  10905. referencedClasses: []
  10906. }),
  10907. smalltalk.NodeVisitor);
  10908. smalltalk.addMethod(
  10909. unescape('_visitNode_'),
  10910. smalltalk.method({
  10911. selector: unescape('visitNode%3A'),
  10912. category: 'visiting',
  10913. fn: function (aNode){
  10914. var self=this;
  10915. return self;},
  10916. args: ["aNode"],
  10917. source: unescape('visitNode%3A%20aNode'),
  10918. messageSends: [],
  10919. referencedClasses: []
  10920. }),
  10921. smalltalk.NodeVisitor);
  10922. smalltalk.addMethod(
  10923. unescape('_visitMethodNode_'),
  10924. smalltalk.method({
  10925. selector: unescape('visitMethodNode%3A'),
  10926. category: 'visiting',
  10927. fn: function (aNode){
  10928. var self=this;
  10929. smalltalk.send(self, "_visitNode_", [aNode]);
  10930. return self;},
  10931. args: ["aNode"],
  10932. source: unescape('visitMethodNode%3A%20aNode%0A%09self%20visitNode%3A%20aNode'),
  10933. messageSends: ["visitNode:"],
  10934. referencedClasses: []
  10935. }),
  10936. smalltalk.NodeVisitor);
  10937. smalltalk.addMethod(
  10938. unescape('_visitSequenceNode_'),
  10939. smalltalk.method({
  10940. selector: unescape('visitSequenceNode%3A'),
  10941. category: 'visiting',
  10942. fn: function (aNode){
  10943. var self=this;
  10944. smalltalk.send(self, "_visitNode_", [aNode]);
  10945. return self;},
  10946. args: ["aNode"],
  10947. source: unescape('visitSequenceNode%3A%20aNode%0A%09self%20visitNode%3A%20aNode'),
  10948. messageSends: ["visitNode:"],
  10949. referencedClasses: []
  10950. }),
  10951. smalltalk.NodeVisitor);
  10952. smalltalk.addMethod(
  10953. unescape('_visitBlockSequenceNode_'),
  10954. smalltalk.method({
  10955. selector: unescape('visitBlockSequenceNode%3A'),
  10956. category: 'visiting',
  10957. fn: function (aNode){
  10958. var self=this;
  10959. smalltalk.send(self, "_visitSequenceNode_", [aNode]);
  10960. return self;},
  10961. args: ["aNode"],
  10962. source: unescape('visitBlockSequenceNode%3A%20aNode%0A%09self%20visitSequenceNode%3A%20aNode'),
  10963. messageSends: ["visitSequenceNode:"],
  10964. referencedClasses: []
  10965. }),
  10966. smalltalk.NodeVisitor);
  10967. smalltalk.addMethod(
  10968. unescape('_visitBlockNode_'),
  10969. smalltalk.method({
  10970. selector: unescape('visitBlockNode%3A'),
  10971. category: 'visiting',
  10972. fn: function (aNode){
  10973. var self=this;
  10974. smalltalk.send(self, "_visitNode_", [aNode]);
  10975. return self;},
  10976. args: ["aNode"],
  10977. source: unescape('visitBlockNode%3A%20aNode%0A%09self%20visitNode%3A%20aNode'),
  10978. messageSends: ["visitNode:"],
  10979. referencedClasses: []
  10980. }),
  10981. smalltalk.NodeVisitor);
  10982. smalltalk.addMethod(
  10983. unescape('_visitReturnNode_'),
  10984. smalltalk.method({
  10985. selector: unescape('visitReturnNode%3A'),
  10986. category: 'visiting',
  10987. fn: function (aNode){
  10988. var self=this;
  10989. smalltalk.send(self, "_visitNode_", [aNode]);
  10990. return self;},
  10991. args: ["aNode"],
  10992. source: unescape('visitReturnNode%3A%20aNode%0A%09self%20visitNode%3A%20aNode'),
  10993. messageSends: ["visitNode:"],
  10994. referencedClasses: []
  10995. }),
  10996. smalltalk.NodeVisitor);
  10997. smalltalk.addMethod(
  10998. unescape('_visitSendNode_'),
  10999. smalltalk.method({
  11000. selector: unescape('visitSendNode%3A'),
  11001. category: 'visiting',
  11002. fn: function (aNode){
  11003. var self=this;
  11004. smalltalk.send(self, "_visitNode_", [aNode]);
  11005. return self;},
  11006. args: ["aNode"],
  11007. source: unescape('visitSendNode%3A%20aNode%0A%09self%20visitNode%3A%20aNode'),
  11008. messageSends: ["visitNode:"],
  11009. referencedClasses: []
  11010. }),
  11011. smalltalk.NodeVisitor);
  11012. smalltalk.addMethod(
  11013. unescape('_visitCascadeNode_'),
  11014. smalltalk.method({
  11015. selector: unescape('visitCascadeNode%3A'),
  11016. category: 'visiting',
  11017. fn: function (aNode){
  11018. var self=this;
  11019. smalltalk.send(self, "_visitNode_", [aNode]);
  11020. return self;},
  11021. args: ["aNode"],
  11022. source: unescape('visitCascadeNode%3A%20aNode%0A%09self%20visitNode%3A%20aNode'),
  11023. messageSends: ["visitNode:"],
  11024. referencedClasses: []
  11025. }),
  11026. smalltalk.NodeVisitor);
  11027. smalltalk.addMethod(
  11028. unescape('_visitValueNode_'),
  11029. smalltalk.method({
  11030. selector: unescape('visitValueNode%3A'),
  11031. category: 'visiting',
  11032. fn: function (aNode){
  11033. var self=this;
  11034. smalltalk.send(self, "_visitNode_", [aNode]);
  11035. return self;},
  11036. args: ["aNode"],
  11037. source: unescape('visitValueNode%3A%20aNode%0A%09self%20visitNode%3A%20aNode'),
  11038. messageSends: ["visitNode:"],
  11039. referencedClasses: []
  11040. }),
  11041. smalltalk.NodeVisitor);
  11042. smalltalk.addMethod(
  11043. unescape('_visitVariableNode_'),
  11044. smalltalk.method({
  11045. selector: unescape('visitVariableNode%3A'),
  11046. category: 'visiting',
  11047. fn: function (aNode){
  11048. var self=this;
  11049. return self;},
  11050. args: ["aNode"],
  11051. source: unescape('visitVariableNode%3A%20aNode'),
  11052. messageSends: [],
  11053. referencedClasses: []
  11054. }),
  11055. smalltalk.NodeVisitor);
  11056. smalltalk.addMethod(
  11057. unescape('_visitAssignmentNode_'),
  11058. smalltalk.method({
  11059. selector: unescape('visitAssignmentNode%3A'),
  11060. category: 'visiting',
  11061. fn: function (aNode){
  11062. var self=this;
  11063. smalltalk.send(self, "_visitNode_", [aNode]);
  11064. return self;},
  11065. args: ["aNode"],
  11066. source: unescape('visitAssignmentNode%3A%20aNode%0A%09self%20visitNode%3A%20aNode'),
  11067. messageSends: ["visitNode:"],
  11068. referencedClasses: []
  11069. }),
  11070. smalltalk.NodeVisitor);
  11071. smalltalk.addMethod(
  11072. unescape('_visitClassReferenceNode_'),
  11073. smalltalk.method({
  11074. selector: unescape('visitClassReferenceNode%3A'),
  11075. category: 'visiting',
  11076. fn: function (aNode){
  11077. var self=this;
  11078. (function($rec){smalltalk.send($rec, "_nextPutAll_", ["smalltalk."]);return smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(aNode, "_value", [])]);})(self);
  11079. return self;},
  11080. args: ["aNode"],
  11081. source: unescape('visitClassReferenceNode%3A%20aNode%0A%09self%20%0A%09%20%20%20%20nextPutAll%3A%20%27smalltalk.%27%3B%0A%09%20%20%20%20nextPutAll%3A%20aNode%20value'),
  11082. messageSends: ["nextPutAll:", "value"],
  11083. referencedClasses: []
  11084. }),
  11085. smalltalk.NodeVisitor);
  11086. smalltalk.addMethod(
  11087. unescape('_visitJSStatementNode_'),
  11088. smalltalk.method({
  11089. selector: unescape('visitJSStatementNode%3A'),
  11090. category: 'visiting',
  11091. fn: function (aNode){
  11092. var self=this;
  11093. (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("function%28%29%7B")]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(aNode, "_source", [])]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%7D%29%28%29")]);})(self);
  11094. return self;},
  11095. args: ["aNode"],
  11096. source: unescape('visitJSStatementNode%3A%20aNode%0A%09self%20%0A%09%20%20%20%20nextPutAll%3A%20%27function%28%29%7B%27%3B%0A%09%20%20%20%20nextPutAll%3A%20aNode%20source%3B%0A%09%20%20%20%20nextPutAll%3A%20%27%7D%29%28%29%27'),
  11097. messageSends: ["nextPutAll:", "source"],
  11098. referencedClasses: []
  11099. }),
  11100. smalltalk.NodeVisitor);
  11101. smalltalk.addMethod(
  11102. unescape('_visitDynamicArrayNode_'),
  11103. smalltalk.method({
  11104. selector: unescape('visitDynamicArrayNode%3A'),
  11105. category: 'visiting',
  11106. fn: function (aNode){
  11107. var self=this;
  11108. smalltalk.send(self, "_visitNode_", [aNode]);
  11109. return self;},
  11110. args: ["aNode"],
  11111. source: unescape('visitDynamicArrayNode%3A%20aNode%0A%09self%20visitNode%3A%20aNode'),
  11112. messageSends: ["visitNode:"],
  11113. referencedClasses: []
  11114. }),
  11115. smalltalk.NodeVisitor);
  11116. smalltalk.addMethod(
  11117. unescape('_visitDynamicDictionaryNode_'),
  11118. smalltalk.method({
  11119. selector: unescape('visitDynamicDictionaryNode%3A'),
  11120. category: 'visiting',
  11121. fn: function (aNode){
  11122. var self=this;
  11123. smalltalk.send(self, "_visitNode_", [aNode]);
  11124. return self;},
  11125. args: ["aNode"],
  11126. source: unescape('visitDynamicDictionaryNode%3A%20aNode%0A%09self%20visitNode%3A%20aNode'),
  11127. messageSends: ["visitNode:"],
  11128. referencedClasses: []
  11129. }),
  11130. smalltalk.NodeVisitor);
  11131. smalltalk.addClass('Compiler', smalltalk.NodeVisitor, ['stream', 'nestedBlocks', 'earlyReturn', 'currentClass', 'currentSelector', 'unknownVariables', 'tempVariables', 'messageSends', 'referencedClasses', 'classReferenced', 'source', 'argVariables'], 'Compiler');
  11132. smalltalk.addMethod(
  11133. unescape('_initialize'),
  11134. smalltalk.method({
  11135. selector: unescape('initialize'),
  11136. category: 'initialization',
  11137. fn: function (){
  11138. var self=this;
  11139. smalltalk.send(self, "_initialize", [], smalltalk.NodeVisitor);
  11140. self['@stream']=smalltalk.send("", "_writeStream", []);
  11141. self['@unknownVariables']=[];
  11142. self['@tempVariables']=[];
  11143. self['@argVariables']=[];
  11144. self['@messageSends']=[];
  11145. self['@classReferenced']=[];
  11146. return self;},
  11147. args: [],
  11148. source: unescape('initialize%0A%09super%20initialize.%0A%09stream%20%3A%3D%20%27%27%20writeStream.%20%0A%09unknownVariables%20%3A%3D%20%23%28%29.%0A%09tempVariables%20%3A%3D%20%23%28%29.%0A%09argVariables%20%3A%3D%20%23%28%29.%0A%09messageSends%20%3A%3D%20%23%28%29.%0A%09classReferenced%20%3A%3D%20%23%28%29'),
  11149. messageSends: ["initialize", "writeStream"],
  11150. referencedClasses: []
  11151. }),
  11152. smalltalk.Compiler);
  11153. smalltalk.addMethod(
  11154. unescape('_parser'),
  11155. smalltalk.method({
  11156. selector: unescape('parser'),
  11157. category: 'accessing',
  11158. fn: function (){
  11159. var self=this;
  11160. return smalltalk.send((smalltalk.SmalltalkParser || SmalltalkParser), "_new", []);
  11161. return self;},
  11162. args: [],
  11163. source: unescape('parser%0A%09%5ESmalltalkParser%20new'),
  11164. messageSends: ["new"],
  11165. referencedClasses: ["SmalltalkParser"]
  11166. }),
  11167. smalltalk.Compiler);
  11168. smalltalk.addMethod(
  11169. unescape('_currentClass'),
  11170. smalltalk.method({
  11171. selector: unescape('currentClass'),
  11172. category: 'accessing',
  11173. fn: function (){
  11174. var self=this;
  11175. return self['@currentClass'];
  11176. return self;},
  11177. args: [],
  11178. source: unescape('currentClass%0A%09%5EcurrentClass'),
  11179. messageSends: [],
  11180. referencedClasses: []
  11181. }),
  11182. smalltalk.Compiler);
  11183. smalltalk.addMethod(
  11184. unescape('_currentClass_'),
  11185. smalltalk.method({
  11186. selector: unescape('currentClass%3A'),
  11187. category: 'accessing',
  11188. fn: function (aClass){
  11189. var self=this;
  11190. self['@currentClass']=aClass;
  11191. return self;},
  11192. args: ["aClass"],
  11193. source: unescape('currentClass%3A%20aClass%0A%09currentClass%20%3A%3D%20aClass'),
  11194. messageSends: [],
  11195. referencedClasses: []
  11196. }),
  11197. smalltalk.Compiler);
  11198. smalltalk.addMethod(
  11199. unescape('_loadExpression_'),
  11200. smalltalk.method({
  11201. selector: unescape('loadExpression%3A'),
  11202. category: 'compiling',
  11203. fn: function (aString){
  11204. var self=this;
  11205. var result=nil;
  11206. smalltalk.send((smalltalk.DoIt || DoIt), "_addCompiledMethod_", [smalltalk.send(self, "_eval_", [smalltalk.send(self, "_compileExpression_", [aString])])]);
  11207. result=smalltalk.send(smalltalk.send((smalltalk.DoIt || DoIt), "_new", []), "_doIt", []);
  11208. smalltalk.send((smalltalk.DoIt || DoIt), "_removeCompiledMethod_", [smalltalk.send(smalltalk.send((smalltalk.DoIt || DoIt), "_methodDictionary", []), "_at_", ["doIt"])]);
  11209. return result;
  11210. return self;},
  11211. args: ["aString"],
  11212. source: unescape('loadExpression%3A%20aString%0A%09%7C%20result%20%7C%0A%09DoIt%20addCompiledMethod%3A%20%28self%20eval%3A%20%28self%20compileExpression%3A%20aString%29%29.%0A%09result%20%3A%3D%20DoIt%20new%20doIt.%0A%09DoIt%20removeCompiledMethod%3A%20%28DoIt%20methodDictionary%20at%3A%20%23doIt%29.%0A%09%5Eresult'),
  11213. messageSends: ["addCompiledMethod:", "eval:", "compileExpression:", "doIt", "new", "removeCompiledMethod:", "at:", "methodDictionary"],
  11214. referencedClasses: ["DoIt"]
  11215. }),
  11216. smalltalk.Compiler);
  11217. smalltalk.addMethod(
  11218. unescape('_load_forClass_'),
  11219. smalltalk.method({
  11220. selector: unescape('load%3AforClass%3A'),
  11221. category: 'compiling',
  11222. fn: function (aString, aClass){
  11223. var self=this;
  11224. var compiled=nil;
  11225. compiled=smalltalk.send(self, "_eval_", [smalltalk.send(self, "_compile_forClass_", [aString, aClass])]);
  11226. smalltalk.send(self, "_setupClass_", [aClass]);
  11227. return compiled;
  11228. return self;},
  11229. args: ["aString", "aClass"],
  11230. source: unescape('load%3A%20aString%20forClass%3A%20aClass%0A%09%7C%20compiled%20%7C%0A%09compiled%20%3A%3D%20self%20eval%3A%20%28self%20compile%3A%20aString%20forClass%3A%20aClass%29.%0A%09self%20setupClass%3A%20aClass.%0A%09%5Ecompiled'),
  11231. messageSends: ["eval:", "compile:forClass:", "setupClass:"],
  11232. referencedClasses: []
  11233. }),
  11234. smalltalk.Compiler);
  11235. smalltalk.addMethod(
  11236. unescape('_compile_forClass_'),
  11237. smalltalk.method({
  11238. selector: unescape('compile%3AforClass%3A'),
  11239. category: 'compiling',
  11240. fn: function (aString, aClass){
  11241. var self=this;
  11242. smalltalk.send(self, "_currentClass_", [aClass]);
  11243. smalltalk.send(self, "_source_", [aString]);
  11244. return smalltalk.send(self, "_compile_", [aString]);
  11245. return self;},
  11246. args: ["aString", "aClass"],
  11247. source: unescape('compile%3A%20aString%20forClass%3A%20aClass%0A%09self%20currentClass%3A%20aClass.%0A%09self%20source%3A%20aString.%0A%09%5Eself%20compile%3A%20aString'),
  11248. messageSends: ["currentClass:", "source:", "compile:"],
  11249. referencedClasses: []
  11250. }),
  11251. smalltalk.Compiler);
  11252. smalltalk.addMethod(
  11253. unescape('_compileExpression_'),
  11254. smalltalk.method({
  11255. selector: unescape('compileExpression%3A'),
  11256. category: 'compiling',
  11257. fn: function (aString){
  11258. var self=this;
  11259. smalltalk.send(self, "_currentClass_", [(smalltalk.DoIt || DoIt)]);
  11260. smalltalk.send(self, "_source_", [smalltalk.send(smalltalk.send(unescape("doIt%20%5E%5B"), "__comma", [aString]), "__comma", [unescape("%5D%20value")])]);
  11261. return smalltalk.send(self, "_compileNode_", [smalltalk.send(self, "_parse_", [smalltalk.send(self, "_source", [])])]);
  11262. return self;},
  11263. args: ["aString"],
  11264. source: unescape('compileExpression%3A%20aString%0A%09self%20currentClass%3A%20DoIt.%0A%09self%20source%3A%20%27doIt%20%5E%5B%27%2C%20aString%2C%20%27%5D%20value%27.%0A%09%5Eself%20compileNode%3A%20%28self%20parse%3A%20self%20source%29'),
  11265. messageSends: ["currentClass:", "source:", unescape("%2C"), "compileNode:", "parse:", "source"],
  11266. referencedClasses: ["DoIt"]
  11267. }),
  11268. smalltalk.Compiler);
  11269. smalltalk.addMethod(
  11270. unescape('_eval_'),
  11271. smalltalk.method({
  11272. selector: unescape('eval%3A'),
  11273. category: 'compiling',
  11274. fn: function (aString){
  11275. var self=this;
  11276. return eval(aString);
  11277. return self;},
  11278. args: ["aString"],
  11279. source: unescape('eval%3A%20aString%0A%09%3Creturn%20eval%28aString%29%3E'),
  11280. messageSends: [],
  11281. referencedClasses: []
  11282. }),
  11283. smalltalk.Compiler);
  11284. smalltalk.addMethod(
  11285. unescape('_compile_'),
  11286. smalltalk.method({
  11287. selector: unescape('compile%3A'),
  11288. category: 'compiling',
  11289. fn: function (aString){
  11290. var self=this;
  11291. return smalltalk.send(self, "_compileNode_", [smalltalk.send(self, "_parse_", [aString])]);
  11292. return self;},
  11293. args: ["aString"],
  11294. source: unescape('compile%3A%20aString%0A%09%5Eself%20compileNode%3A%20%28self%20parse%3A%20aString%29'),
  11295. messageSends: ["compileNode:", "parse:"],
  11296. referencedClasses: []
  11297. }),
  11298. smalltalk.Compiler);
  11299. smalltalk.addMethod(
  11300. unescape('_compileNode_'),
  11301. smalltalk.method({
  11302. selector: unescape('compileNode%3A'),
  11303. category: 'compiling',
  11304. fn: function (aNode){
  11305. var self=this;
  11306. self['@stream']=smalltalk.send("", "_writeStream", []);
  11307. smalltalk.send(self, "_visit_", [aNode]);
  11308. return smalltalk.send(self['@stream'], "_contents", []);
  11309. return self;},
  11310. args: ["aNode"],
  11311. source: unescape('compileNode%3A%20aNode%0A%09stream%20%3A%3D%20%27%27%20writeStream.%0A%09self%20visit%3A%20aNode.%0A%09%5Estream%20contents'),
  11312. messageSends: ["writeStream", "visit:", "contents"],
  11313. referencedClasses: []
  11314. }),
  11315. smalltalk.Compiler);
  11316. smalltalk.addMethod(
  11317. unescape('_visit_'),
  11318. smalltalk.method({
  11319. selector: unescape('visit%3A'),
  11320. category: 'visiting',
  11321. fn: function (aNode){
  11322. var self=this;
  11323. smalltalk.send(aNode, "_accept_", [self]);
  11324. return self;},
  11325. args: ["aNode"],
  11326. source: unescape('visit%3A%20aNode%0A%09aNode%20accept%3A%20self'),
  11327. messageSends: ["accept:"],
  11328. referencedClasses: []
  11329. }),
  11330. smalltalk.Compiler);
  11331. smalltalk.addMethod(
  11332. unescape('_visitMethodNode_'),
  11333. smalltalk.method({
  11334. selector: unescape('visitMethodNode%3A'),
  11335. category: 'visiting',
  11336. fn: function (aNode){
  11337. var self=this;
  11338. var str=nil;
  11339. var currentSelector=nil;
  11340. self['@currentSelector']=smalltalk.send(smalltalk.send(aNode, "_selector", []), "_asSelector", []);
  11341. self['@nestedBlocks']=(0);
  11342. self['@earlyReturn']=false;
  11343. self['@messageSends']=[];
  11344. self['@referencedClasses']=[];
  11345. self['@unknownVariables']=[];
  11346. self['@tempVariables']=[];
  11347. self['@argVariables']=[];
  11348. (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("smalltalk.method%28%7B")]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("selector%3A%20%22"), "__comma", [smalltalk.send(aNode, "_selector", [])]), "__comma", [unescape("%22%2C")])]);return smalltalk.send($rec, "_lf", []);})(self['@stream']);
  11349. (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("source%3A%20unescape%28%22"), "__comma", [smalltalk.send(smalltalk.send(self, "_source", []), "_escaped", [])]), "__comma", [unescape("%22%29%2C")])]);return smalltalk.send($rec, "_lf", []);})(self['@stream']);
  11350. smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("fn%3A%20function%28")]);
  11351. smalltalk.send(smalltalk.send(aNode, "_arguments", []), "_do_separatedBy_", [(function(each){smalltalk.send(self['@argVariables'], "_add_", [each]);return smalltalk.send(self['@stream'], "_nextPutAll_", [each]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%2C%20")]);})]);
  11352. (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("%29%7B")]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [unescape("var%20self%3Dthis%3B")]);return smalltalk.send($rec, "_lf", []);})(self['@stream']);
  11353. str=self['@stream'];
  11354. self['@stream']=smalltalk.send("", "_writeStream", []);
  11355. smalltalk.send(smalltalk.send(aNode, "_nodes", []), "_do_", [(function(each){return smalltalk.send(self, "_visit_", [each]);})]);
  11356. ((($receiver = self['@earlyReturn']).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(str, "_nextPutAll_", [unescape("try%7B")]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(str, "_nextPutAll_", [unescape("try%7B")]);})]));
  11357. smalltalk.send(str, "_nextPutAll_", [smalltalk.send(self['@stream'], "_contents", [])]);
  11358. self['@stream']=str;
  11359. (function($rec){smalltalk.send($rec, "_lf", []);return smalltalk.send($rec, "_nextPutAll_", [unescape("return%20self%3B")]);})(self['@stream']);
  11360. ((($receiver = self['@earlyReturn']).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function($rec){smalltalk.send($rec, "_lf", []);return smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%7D%20catch%28e%29%20%7Bif%28e.name%20%3D%3D%3D%20%27stReturn%27%20%26%26%20e.selector%20%3D%3D%3D%20"), "__comma", [smalltalk.send(self['@currentSelector'], "_printString", [])]), "__comma", [unescape("%29%7Breturn%20e.fn%28%29%7D%20throw%28e%29%7D")])]);})(self['@stream']);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return (function($rec){smalltalk.send($rec, "_lf", []);return smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%7D%20catch%28e%29%20%7Bif%28e.name%20%3D%3D%3D%20%27stReturn%27%20%26%26%20e.selector%20%3D%3D%3D%20"), "__comma", [smalltalk.send(self['@currentSelector'], "_printString", [])]), "__comma", [unescape("%29%7Breturn%20e.fn%28%29%7D%20throw%28e%29%7D")])]);})(self['@stream']);})]));
  11361. smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%7D")]);
  11362. (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%2C"), "__comma", [smalltalk.send((smalltalk.String || String), "_lf", [])]), "__comma", ["messageSends: "])]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send(self['@messageSends'], "_asJavascript", []), "__comma", [unescape("%2C")])]);smalltalk.send($rec, "_lf", []);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send("args: ", "__comma", [smalltalk.send(self['@argVariables'], "_asJavascript", [])]), "__comma", [unescape("%2C")])]);smalltalk.send($rec, "_lf", []);return smalltalk.send($rec, "_nextPutAll_", [unescape("referencedClasses%3A%20%5B")]);})(self['@stream']);
  11363. smalltalk.send(self['@referencedClasses'], "_do_separatedBy_", [(function(each){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(each, "_printString", [])]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%2C")]);})]);
  11364. smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%5D")]);
  11365. smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%7D%29")]);
  11366. return self;},
  11367. args: ["aNode"],
  11368. source: unescape('visitMethodNode%3A%20aNode%0A%09%7C%20str%20currentSelector%20%7C%20%0A%09currentSelector%20%3A%3D%20aNode%20selector%20asSelector.%0A%09nestedBlocks%20%3A%3D%200.%0A%09earlyReturn%20%3A%3D%20false.%0A%09messageSends%20%3A%3D%20%23%28%29.%0A%09referencedClasses%20%3A%3D%20%23%28%29.%0A%09unknownVariables%20%3A%3D%20%23%28%29.%0A%09tempVariables%20%3A%3D%20%23%28%29.%0A%09argVariables%20%3A%3D%20%23%28%29.%0A%09stream%20%0A%09%20%20%20%20nextPutAll%3A%20%27smalltalk.method%28%7B%27%3B%20lf%3B%0A%09%20%20%20%20nextPutAll%3A%20%27selector%3A%20%22%27%2C%20aNode%20selector%2C%20%27%22%2C%27%3B%20lf.%0A%09stream%20nextPutAll%3A%20%27source%3A%20unescape%28%22%27%2C%20self%20source%20escaped%2C%20%27%22%29%2C%27%3Blf.%0A%09stream%20nextPutAll%3A%20%27fn%3A%20function%28%27.%0A%09aNode%20arguments%20%0A%09%20%20%20%20do%3A%20%5B%3Aeach%20%7C%20%0A%09%09argVariables%20add%3A%20each.%0A%09%09stream%20nextPutAll%3A%20each%5D%0A%09%20%20%20%20separatedBy%3A%20%5Bstream%20nextPutAll%3A%20%27%2C%20%27%5D.%0A%09stream%20%0A%09%20%20%20%20nextPutAll%3A%20%27%29%7B%27%3B%20lf%3B%0A%09%20%20%20%20nextPutAll%3A%20%27var%20self%3Dthis%3B%27%3B%20lf.%0A%09str%20%3A%3D%20stream.%0A%09stream%20%3A%3D%20%27%27%20writeStream.%0A%09aNode%20nodes%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20self%20visit%3A%20each%5D.%0A%09earlyReturn%20ifTrue%3A%20%5B%0A%09%20%20%20%20str%20nextPutAll%3A%20%27try%7B%27%5D.%0A%09str%20nextPutAll%3A%20stream%20contents.%0A%09stream%20%3A%3D%20str.%0A%09stream%20%0A%09%20%20%20%20lf%3B%20%0A%09%20%20%20%20nextPutAll%3A%20%27return%20self%3B%27.%0A%09earlyReturn%20ifTrue%3A%20%5B%0A%09%20%20%20%20stream%20lf%3B%20nextPutAll%3A%20%27%7D%20catch%28e%29%20%7Bif%28e.name%20%3D%3D%3D%20%27%27stReturn%27%27%20%26%26%20e.selector%20%3D%3D%3D%20%27%2C%20currentSelector%20printString%2C%20%27%29%7Breturn%20e.fn%28%29%7D%20throw%28e%29%7D%27%5D.%0A%09stream%20nextPutAll%3A%20%27%7D%27.%0A%09stream%20%0A%09%09nextPutAll%3A%20%27%2C%27%2C%20String%20lf%2C%20%27messageSends%3A%20%27%3B%0A%09%09nextPutAll%3A%20messageSends%20asJavascript%2C%20%27%2C%27%3B%20lf%3B%0A%20%20%20%20%20%20%20%20%20%20%09nextPutAll%3A%20%27args%3A%20%27%2C%20argVariables%20asJavascript%2C%20%27%2C%27%3B%20lf%3B%0A%09%09nextPutAll%3A%20%27referencedClasses%3A%20%5B%27.%0A%09referencedClasses%20%0A%09%09do%3A%20%5B%3Aeach%20%7C%20stream%20nextPutAll%3A%20each%20printString%5D%0A%09%09separatedBy%3A%20%5Bstream%20nextPutAll%3A%20%27%2C%27%5D.%0A%09stream%20nextPutAll%3A%20%27%5D%27.%0A%09stream%20nextPutAll%3A%20%27%7D%29%27'),
  11369. messageSends: ["asSelector", "selector", "nextPutAll:", "lf", unescape("%2C"), "escaped", "source", "do:separatedBy:", "arguments", "add:", "writeStream", "do:", "nodes", "visit:", "ifTrue:", "contents", "printString", "asJavascript"],
  11370. referencedClasses: ["String"]
  11371. }),
  11372. smalltalk.Compiler);
  11373. smalltalk.addMethod(
  11374. unescape('_visitBlockNode_'),
  11375. smalltalk.method({
  11376. selector: unescape('visitBlockNode%3A'),
  11377. category: 'visiting',
  11378. fn: function (aNode){
  11379. var self=this;
  11380. smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28")]);
  11381. smalltalk.send(smalltalk.send(aNode, "_parameters", []), "_do_separatedBy_", [(function(each){smalltalk.send(self['@tempVariables'], "_add_", [each]);return smalltalk.send(self['@stream'], "_nextPutAll_", [each]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%2C%20")]);})]);
  11382. smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%7B")]);
  11383. smalltalk.send(smalltalk.send(aNode, "_nodes", []), "_do_", [(function(each){return smalltalk.send(self, "_visit_", [each]);})]);
  11384. smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%7D%29")]);
  11385. return self;},
  11386. args: ["aNode"],
  11387. source: unescape('visitBlockNode%3A%20aNode%0A%09stream%20nextPutAll%3A%20%27%28function%28%27.%0A%09aNode%20parameters%20%0A%09%20%20%20%20do%3A%20%5B%3Aeach%20%7C%0A%09%09tempVariables%20add%3A%20each.%0A%09%09stream%20nextPutAll%3A%20each%5D%0A%09%20%20%20%20separatedBy%3A%20%5Bstream%20nextPutAll%3A%20%27%2C%20%27%5D.%0A%09stream%20nextPutAll%3A%20%27%29%7B%27.%0A%09aNode%20nodes%20do%3A%20%5B%3Aeach%20%7C%20self%20visit%3A%20each%5D.%0A%09stream%20nextPutAll%3A%20%27%7D%29%27'),
  11388. messageSends: ["nextPutAll:", "do:separatedBy:", "parameters", "add:", "do:", "nodes", "visit:"],
  11389. referencedClasses: []
  11390. }),
  11391. smalltalk.Compiler);
  11392. smalltalk.addMethod(
  11393. unescape('_visitSequenceNode_'),
  11394. smalltalk.method({
  11395. selector: unescape('visitSequenceNode%3A'),
  11396. category: 'visiting',
  11397. fn: function (aNode){
  11398. var self=this;
  11399. smalltalk.send(smalltalk.send(aNode, "_temps", []), "_do_", [(function(each){var temp=nil;
  11400. temp=smalltalk.send(self, "_safeVariableNameFor_", [each]);smalltalk.send(self['@tempVariables'], "_add_", [temp]);return (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send("var ", "__comma", [temp]), "__comma", [unescape("%3Dnil%3B")])]);return smalltalk.send($rec, "_lf", []);})(self['@stream']);})]);
  11401. smalltalk.send(smalltalk.send(aNode, "_nodes", []), "_do_separatedBy_", [(function(each){smalltalk.send(self, "_visit_", [each]);return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%3B")]);}), (function(){return smalltalk.send(self['@stream'], "_lf", []);})]);
  11402. return self;},
  11403. args: ["aNode"],
  11404. source: unescape('visitSequenceNode%3A%20aNode%0A%09aNode%20temps%20do%3A%20%5B%3Aeach%20%7C%7C%20temp%20%7C%0A%20%20%20%20%20%20%20%20%20%20%20%20temp%20%3A%3D%20self%20safeVariableNameFor%3A%20each.%0A%09%20%20%20%20tempVariables%20add%3A%20temp.%0A%09%20%20%20%20stream%20nextPutAll%3A%20%27var%20%27%2C%20temp%2C%20%27%3Dnil%3B%27%3B%20lf%5D.%0A%09aNode%20nodes%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20self%20visit%3A%20each.%0A%09%20%20%20%20stream%20nextPutAll%3A%20%27%3B%27%5D%0A%09%20%20%20%20separatedBy%3A%20%5Bstream%20lf%5D'),
  11405. messageSends: ["do:", "temps", "safeVariableNameFor:", "add:", "nextPutAll:", unescape("%2C"), "lf", "do:separatedBy:", "nodes", "visit:"],
  11406. referencedClasses: []
  11407. }),
  11408. smalltalk.Compiler);
  11409. smalltalk.addMethod(
  11410. unescape('_visitBlockSequenceNode_'),
  11411. smalltalk.method({
  11412. selector: unescape('visitBlockSequenceNode%3A'),
  11413. category: 'visiting',
  11414. fn: function (aNode){
  11415. var self=this;
  11416. var index=nil;
  11417. self['@nestedBlocks']=((($receiver = self['@nestedBlocks']).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));
  11418. ((($receiver = smalltalk.send(smalltalk.send(aNode, "_nodes", []), "_isEmpty", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("return%20nil%3B")]);})() : (function(){smalltalk.send(smalltalk.send(aNode, "_temps", []), "_do_", [(function(each){var temp=nil;
  11419. temp=smalltalk.send(self, "_safeVariableNameFor_", [each]);smalltalk.send(self['@tempVariables'], "_add_", [temp]);return (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send("var ", "__comma", [temp]), "__comma", [unescape("%3Dnil%3B")])]);return smalltalk.send($rec, "_lf", []);})(self['@stream']);})]);index=(0);return smalltalk.send(smalltalk.send(aNode, "_nodes", []), "_do_", [(function(each){index=((($receiver = index).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));((($receiver = smalltalk.send(index, "__eq", [smalltalk.send(smalltalk.send(aNode, "_nodes", []), "_size", [])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", ["return "]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", ["return "]);})]));smalltalk.send(self, "_visit_", [each]);return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%3B")]);})]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("return%20nil%3B")]);}), (function(){smalltalk.send(smalltalk.send(aNode, "_temps", []), "_do_", [(function(each){var temp=nil;
  11420. temp=smalltalk.send(self, "_safeVariableNameFor_", [each]);smalltalk.send(self['@tempVariables'], "_add_", [temp]);return (function($rec){smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(smalltalk.send("var ", "__comma", [temp]), "__comma", [unescape("%3Dnil%3B")])]);return smalltalk.send($rec, "_lf", []);})(self['@stream']);})]);index=(0);return smalltalk.send(smalltalk.send(aNode, "_nodes", []), "_do_", [(function(each){index=((($receiver = index).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));((($receiver = smalltalk.send(index, "__eq", [smalltalk.send(smalltalk.send(aNode, "_nodes", []), "_size", [])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", ["return "]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", ["return "]);})]));smalltalk.send(self, "_visit_", [each]);return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%3B")]);})]);})]));
  11421. self['@nestedBlocks']=((($receiver = self['@nestedBlocks']).klass === smalltalk.Number) ? $receiver -(1) : smalltalk.send($receiver, "__minus", [(1)]));
  11422. return self;},
  11423. args: ["aNode"],
  11424. source: unescape('visitBlockSequenceNode%3A%20aNode%0A%09%7C%20index%20%7C%0A%09nestedBlocks%20%3A%3D%20nestedBlocks%20+%201.%0A%09aNode%20nodes%20isEmpty%0A%09%20%20%20%20ifTrue%3A%20%5B%0A%09%09stream%20nextPutAll%3A%20%27return%20nil%3B%27%5D%0A%09%20%20%20%20ifFalse%3A%20%5B%0A%09%09aNode%20temps%20do%3A%20%5B%3Aeach%20%7C%20%7C%20temp%20%7C%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20temp%20%3A%3D%20self%20safeVariableNameFor%3A%20each.%0A%09%09%20%20%20%20tempVariables%20add%3A%20temp.%0A%09%09%20%20%20%20stream%20nextPutAll%3A%20%27var%20%27%2C%20temp%2C%20%27%3Dnil%3B%27%3B%20lf%5D.%0A%09%09index%20%3A%3D%200.%0A%09%09aNode%20nodes%20do%3A%20%5B%3Aeach%20%7C%0A%09%09%20%20%20%20index%20%3A%3D%20index%20+%201.%0A%09%09%20%20%20%20index%20%3D%20aNode%20nodes%20size%20ifTrue%3A%20%5B%0A%09%09%09stream%20nextPutAll%3A%20%27return%20%27%5D.%0A%09%09%20%20%20%20self%20visit%3A%20each.%0A%09%09%20%20%20%20stream%20nextPutAll%3A%20%27%3B%27%5D%5D.%0A%09nestedBlocks%20%3A%3D%20nestedBlocks%20-%201'),
  11425. messageSends: [unescape("+"), "ifTrue:ifFalse:", "isEmpty", "nodes", "nextPutAll:", "do:", "temps", "safeVariableNameFor:", "add:", unescape("%2C"), "lf", "ifTrue:", unescape("%3D"), "size", "visit:", unescape("-")],
  11426. referencedClasses: []
  11427. }),
  11428. smalltalk.Compiler);
  11429. smalltalk.addMethod(
  11430. unescape('_visitReturnNode_'),
  11431. smalltalk.method({
  11432. selector: unescape('visitReturnNode%3A'),
  11433. category: 'visiting',
  11434. fn: function (aNode){
  11435. var self=this;
  11436. ((($receiver = ((($receiver = self['@nestedBlocks']).klass === smalltalk.Number) ? $receiver >(0) : smalltalk.send($receiver, "__gt", [(0)]))).klass === smalltalk.Boolean) ? ($receiver ? (function(){return self['@earlyReturn']=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return self['@earlyReturn']=true;})]));
  11437. ((($receiver = self['@earlyReturn']).klass === smalltalk.Boolean) ? ($receiver ? (function(){return (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("%28function%28%29%7Bthrow%28")]);smalltalk.send($rec, "_nextPutAll_", [unescape("%7Bname%3A%20%27stReturn%27%2C%20selector%3A%20")]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self['@currentSelector'], "_printString", [])]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%2C%20fn%3A%20function%28%29%7Breturn%20")]);})(self['@stream']);})() : (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", ["return "]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return (function($rec){smalltalk.send($rec, "_nextPutAll_", [unescape("%28function%28%29%7Bthrow%28")]);smalltalk.send($rec, "_nextPutAll_", [unescape("%7Bname%3A%20%27stReturn%27%2C%20selector%3A%20")]);smalltalk.send($rec, "_nextPutAll_", [smalltalk.send(self['@currentSelector'], "_printString", [])]);return smalltalk.send($rec, "_nextPutAll_", [unescape("%2C%20fn%3A%20function%28%29%7Breturn%20")]);})(self['@stream']);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", ["return "]);})]));
  11438. smalltalk.send(smalltalk.send(aNode, "_nodes", []), "_do_", [(function(each){return smalltalk.send(self, "_visit_", [each]);})]);
  11439. ((($receiver = self['@earlyReturn']).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%7D%7D%29%7D%29%28%29")]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%7D%7D%29%7D%29%28%29")]);})]));
  11440. return self;},
  11441. args: ["aNode"],
  11442. source: unescape('visitReturnNode%3A%20aNode%0A%09nestedBlocks%20%3E%200%20ifTrue%3A%20%5B%0A%09%20%20%20%20earlyReturn%20%3A%3D%20true%5D.%0A%09earlyReturn%0A%09%20%20%20%20ifTrue%3A%20%5B%0A%09%09stream%0A%09%09%20%20%20%20nextPutAll%3A%20%27%28function%28%29%7Bthrow%28%27%3B%0A%09%09%20%20%20%20nextPutAll%3A%20%27%7Bname%3A%20%27%27stReturn%27%27%2C%20selector%3A%20%27%3B%0A%09%09%20%20%20%20nextPutAll%3A%20currentSelector%20printString%3B%0A%09%09%20%20%20%20nextPutAll%3A%20%27%2C%20fn%3A%20function%28%29%7Breturn%20%27%5D%0A%09%20%20%20%20ifFalse%3A%20%5Bstream%20nextPutAll%3A%20%27return%20%27%5D.%0A%09aNode%20nodes%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20self%20visit%3A%20each%5D.%0A%09earlyReturn%20ifTrue%3A%20%5B%0A%09%20%20%20%20stream%20nextPutAll%3A%20%27%7D%7D%29%7D%29%28%29%27%5D'),
  11443. messageSends: ["ifTrue:", unescape("%3E"), "ifTrue:ifFalse:", "nextPutAll:", "printString", "do:", "nodes", "visit:"],
  11444. referencedClasses: []
  11445. }),
  11446. smalltalk.Compiler);
  11447. smalltalk.addMethod(
  11448. unescape('_visitSendNode_'),
  11449. smalltalk.method({
  11450. selector: unescape('visitSendNode%3A'),
  11451. category: 'visiting',
  11452. fn: function (aNode){
  11453. var self=this;
  11454. var str=nil;
  11455. var receiver=nil;
  11456. var superSend=nil;
  11457. var inlined=nil;
  11458. str=self['@stream'];
  11459. ((($receiver = smalltalk.send(self['@messageSends'], "_includes_", [smalltalk.send(aNode, "_selector", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self['@messageSends'], "_add_", [smalltalk.send(aNode, "_selector", [])]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(self['@messageSends'], "_add_", [smalltalk.send(aNode, "_selector", [])]);})]));
  11460. self['@stream']=smalltalk.send("", "_writeStream", []);
  11461. smalltalk.send(self, "_visit_", [smalltalk.send(aNode, "_receiver", [])]);
  11462. superSend=smalltalk.send(smalltalk.send(self['@stream'], "_contents", []), "__eq", ["super"]);
  11463. receiver=((($receiver = superSend).klass === smalltalk.Boolean) ? ($receiver ? (function(){return "self";})() : (function(){return smalltalk.send(self['@stream'], "_contents", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return "self";}), (function(){return smalltalk.send(self['@stream'], "_contents", []);})]));
  11464. self['@stream']=str;
  11465. ((($receiver = smalltalk.send(self, "_performOptimizations", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(self, "_inlineLiteral_receiverNode_argumentNodes_", [smalltalk.send(aNode, "_selector", []), smalltalk.send(aNode, "_receiver", []), smalltalk.send(aNode, "_arguments", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return ((($receiver = smalltalk.send(self, "_inline_receiver_argumentNodes_", [smalltalk.send(aNode, "_selector", []), receiver, smalltalk.send(aNode, "_arguments", [])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(" : ", "__comma", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), "$receiver", smalltalk.send(aNode, "_arguments", []), superSend])]), "__comma", [unescape("%29")])]);})() : (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), receiver, smalltalk.send(aNode, "_arguments", []), superSend])]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(" : ", "__comma", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), "$receiver", smalltalk.send(aNode, "_arguments", []), superSend])]), "__comma", [unescape("%29")])]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), receiver, smalltalk.send(aNode, "_arguments", []), superSend])]);})]));})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return ((($receiver = smalltalk.send(self, "_inline_receiver_argumentNodes_", [smalltalk.send(aNode, "_selector", []), receiver, smalltalk.send(aNode, "_arguments", [])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(" : ", "__comma", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), "$receiver", smalltalk.send(aNode, "_arguments", []), superSend])]), "__comma", [unescape("%29")])]);})() : (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), receiver, smalltalk.send(aNode, "_arguments", []), superSend])]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(" : ", "__comma", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), "$receiver", smalltalk.send(aNode, "_arguments", []), superSend])]), "__comma", [unescape("%29")])]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), receiver, smalltalk.send(aNode, "_arguments", []), superSend])]);})]));})]));})() : (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), receiver, smalltalk.send(aNode, "_arguments", []), superSend])]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return ((($receiver = smalltalk.send(self, "_inlineLiteral_receiverNode_argumentNodes_", [smalltalk.send(aNode, "_selector", []), smalltalk.send(aNode, "_receiver", []), smalltalk.send(aNode, "_arguments", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return ((($receiver = smalltalk.send(self, "_inline_receiver_argumentNodes_", [smalltalk.send(aNode, "_selector", []), receiver, smalltalk.send(aNode, "_arguments", [])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(" : ", "__comma", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), "$receiver", smalltalk.send(aNode, "_arguments", []), superSend])]), "__comma", [unescape("%29")])]);})() : (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), receiver, smalltalk.send(aNode, "_arguments", []), superSend])]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(" : ", "__comma", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), "$receiver", smalltalk.send(aNode, "_arguments", []), superSend])]), "__comma", [unescape("%29")])]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), receiver, smalltalk.send(aNode, "_arguments", []), superSend])]);})]));})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return ((($receiver = smalltalk.send(self, "_inline_receiver_argumentNodes_", [smalltalk.send(aNode, "_selector", []), receiver, smalltalk.send(aNode, "_arguments", [])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(" : ", "__comma", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), "$receiver", smalltalk.send(aNode, "_arguments", []), superSend])]), "__comma", [unescape("%29")])]);})() : (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), receiver, smalltalk.send(aNode, "_arguments", []), superSend])]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(" : ", "__comma", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), "$receiver", smalltalk.send(aNode, "_arguments", []), superSend])]), "__comma", [unescape("%29")])]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), receiver, smalltalk.send(aNode, "_arguments", []), superSend])]);})]));})]));}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(self, "_send_to_arguments_superSend_", [smalltalk.send(aNode, "_selector", []), receiver, smalltalk.send(aNode, "_arguments", []), superSend])]);})]));
  11466. return self;},
  11467. args: ["aNode"],
  11468. source: unescape('visitSendNode%3A%20aNode%0A%20%20%20%20%20%20%20%20%7C%20str%20receiver%20superSend%20inlined%20%7C%0A%20%20%20%20%20%20%20%20str%20%3A%3D%20stream.%0A%20%20%20%20%20%20%20%20%28messageSends%20includes%3A%20aNode%20selector%29%20ifFalse%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20messageSends%20add%3A%20aNode%20selector%5D.%0A%20%20%20%20%20%20%20%20stream%20%3A%3D%20%27%27%20writeStream.%0A%20%20%20%20%20%20%20%20self%20visit%3A%20aNode%20receiver.%0A%20%20%20%20%20%20%20%20superSend%20%3A%3D%20stream%20contents%20%3D%20%27super%27.%0A%20%20%20%20%20%20%20%20receiver%20%3A%3D%20superSend%20ifTrue%3A%20%5B%27self%27%5D%20ifFalse%3A%20%5Bstream%20contents%5D.%0A%20%20%20%20%20%20%20%20stream%20%3A%3D%20str.%0A%09%0A%09self%20performOptimizations%20%0A%09%09ifTrue%3A%20%5B%0A%09%09%09%28self%20inlineLiteral%3A%20aNode%20selector%20receiverNode%3A%20aNode%20receiver%20argumentNodes%3A%20aNode%20arguments%29%20ifFalse%3A%20%5B%0A%09%09%09%09%28self%20inline%3A%20aNode%20selector%20receiver%3A%20receiver%20argumentNodes%3A%20aNode%20arguments%29%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09ifTrue%3A%20%5Bstream%20nextPutAll%3A%20%27%20%3A%20%27%2C%20%28self%20send%3A%20aNode%20selector%20to%3A%20%27%24receiver%27%20arguments%3A%20aNode%20arguments%20superSend%3A%20superSend%29%2C%20%27%29%27%5D%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09ifFalse%3A%20%5Bstream%20nextPutAll%3A%20%28self%20send%3A%20aNode%20selector%20to%3A%20receiver%20arguments%3A%20aNode%20arguments%20superSend%3A%20superSend%29%5D%5D%5D%0A%09%09ifFalse%3A%20%5Bstream%20nextPutAll%3A%20%28self%20send%3A%20aNode%20selector%20to%3A%20receiver%20arguments%3A%20aNode%20arguments%20superSend%3A%20superSend%29%5D'),
  11469. messageSends: ["ifFalse:", "includes:", "selector", "add:", "writeStream", "visit:", "receiver", unescape("%3D"), "contents", "ifTrue:ifFalse:", "performOptimizations", "inlineLiteral:receiverNode:argumentNodes:", "arguments", "inline:receiver:argumentNodes:", "nextPutAll:", unescape("%2C"), "send:to:arguments:superSend:"],
  11470. referencedClasses: []
  11471. }),
  11472. smalltalk.Compiler);
  11473. smalltalk.addMethod(
  11474. unescape('_visitCascadeNode_'),
  11475. smalltalk.method({
  11476. selector: unescape('visitCascadeNode%3A'),
  11477. category: 'visiting',
  11478. fn: function (aNode){
  11479. var self=this;
  11480. var index=nil;
  11481. index=(0);
  11482. ((($receiver = smalltalk.send(self['@tempVariables'], "_includes_", ["$rec"])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self['@tempVariables'], "_add_", ["$rec"]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(self['@tempVariables'], "_add_", ["$rec"]);})]));
  11483. smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%24rec%29%7B")]);
  11484. smalltalk.send(smalltalk.send(aNode, "_nodes", []), "_do_", [(function(each){index=((($receiver = index).klass === smalltalk.Number) ? $receiver +(1) : smalltalk.send($receiver, "__plus", [(1)]));((($receiver = smalltalk.send(index, "__eq", [smalltalk.send(smalltalk.send(aNode, "_nodes", []), "_size", [])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", ["return "]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", ["return "]);})]));smalltalk.send(each, "_receiver_", [smalltalk.send(smalltalk.send((smalltalk.VariableNode || VariableNode), "_new", []), "_value_", ["$rec"])]);smalltalk.send(self, "_visit_", [each]);return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%3B")]);})]);
  11485. smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%7D%29%28")]);
  11486. smalltalk.send(self, "_visit_", [smalltalk.send(aNode, "_receiver", [])]);
  11487. smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29")]);
  11488. return self;},
  11489. args: ["aNode"],
  11490. source: unescape('visitCascadeNode%3A%20aNode%0A%09%7C%20index%20%7C%0A%09index%20%3A%3D%200.%0A%09%28tempVariables%20includes%3A%20%27%24rec%27%29%20ifFalse%3A%20%5B%0A%09%09tempVariables%20add%3A%20%27%24rec%27%5D.%0A%09stream%20nextPutAll%3A%20%27%28function%28%24rec%29%7B%27.%0A%09aNode%20nodes%20do%3A%20%5B%3Aeach%20%7C%0A%09%20%20%20%20index%20%3A%3D%20index%20+%201.%0A%09%20%20%20%20index%20%3D%20aNode%20nodes%20size%20ifTrue%3A%20%5B%0A%09%09stream%20nextPutAll%3A%20%27return%20%27%5D.%0A%09%20%20%20%20each%20receiver%3A%20%28VariableNode%20new%20value%3A%20%27%24rec%27%29.%0A%09%20%20%20%20self%20visit%3A%20each.%0A%09%20%20%20%20stream%20nextPutAll%3A%20%27%3B%27%5D.%0A%09stream%20nextPutAll%3A%20%27%7D%29%28%27.%0A%09self%20visit%3A%20aNode%20receiver.%0A%09stream%20nextPutAll%3A%20%27%29%27'),
  11491. messageSends: ["ifFalse:", "includes:", "add:", "nextPutAll:", "do:", "nodes", unescape("+"), "ifTrue:", unescape("%3D"), "size", "receiver:", "value:", "new", "visit:", "receiver"],
  11492. referencedClasses: ["VariableNode"]
  11493. }),
  11494. smalltalk.Compiler);
  11495. smalltalk.addMethod(
  11496. unescape('_visitValueNode_'),
  11497. smalltalk.method({
  11498. selector: unescape('visitValueNode%3A'),
  11499. category: 'visiting',
  11500. fn: function (aNode){
  11501. var self=this;
  11502. smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(aNode, "_value", []), "_asJavascript", [])]);
  11503. return self;},
  11504. args: ["aNode"],
  11505. source: unescape('visitValueNode%3A%20aNode%0A%09stream%20nextPutAll%3A%20aNode%20value%20asJavascript'),
  11506. messageSends: ["nextPutAll:", "asJavascript", "value"],
  11507. referencedClasses: []
  11508. }),
  11509. smalltalk.Compiler);
  11510. smalltalk.addMethod(
  11511. unescape('_visitAssignmentNode_'),
  11512. smalltalk.method({
  11513. selector: unescape('visitAssignmentNode%3A'),
  11514. category: 'visiting',
  11515. fn: function (aNode){
  11516. var self=this;
  11517. smalltalk.send(self, "_visit_", [smalltalk.send(aNode, "_left", [])]);
  11518. smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%3D")]);
  11519. smalltalk.send(self, "_visit_", [smalltalk.send(aNode, "_right", [])]);
  11520. return self;},
  11521. args: ["aNode"],
  11522. source: unescape('visitAssignmentNode%3A%20aNode%0A%09self%20visit%3A%20aNode%20left.%0A%09stream%20nextPutAll%3A%20%27%3D%27.%0A%09self%20visit%3A%20aNode%20right'),
  11523. messageSends: ["visit:", "left", "nextPutAll:", "right"],
  11524. referencedClasses: []
  11525. }),
  11526. smalltalk.Compiler);
  11527. smalltalk.addMethod(
  11528. unescape('_visitClassReferenceNode_'),
  11529. smalltalk.method({
  11530. selector: unescape('visitClassReferenceNode%3A'),
  11531. category: 'visiting',
  11532. fn: function (aNode){
  11533. var self=this;
  11534. ((($receiver = smalltalk.send(self['@referencedClasses'], "_includes_", [smalltalk.send(aNode, "_value", [])])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self['@referencedClasses'], "_add_", [smalltalk.send(aNode, "_value", [])]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(self['@referencedClasses'], "_add_", [smalltalk.send(aNode, "_value", [])]);})]));
  11535. smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(unescape("%28smalltalk."), "__comma", [smalltalk.send(aNode, "_value", [])]), "__comma", [unescape("%20%7C%7C%20")]), "__comma", [smalltalk.send(aNode, "_value", [])]), "__comma", [unescape("%29")])]);
  11536. return self;},
  11537. args: ["aNode"],
  11538. source: unescape('visitClassReferenceNode%3A%20aNode%0A%09%28referencedClasses%20includes%3A%20aNode%20value%29%20ifFalse%3A%20%5B%0A%09%09referencedClasses%20add%3A%20aNode%20value%5D.%0A%09stream%20nextPutAll%3A%20%27%28smalltalk.%27%2C%20aNode%20value%2C%20%27%20%7C%7C%20%27%2C%20aNode%20value%2C%20%27%29%27'),
  11539. messageSends: ["ifFalse:", "includes:", "value", "add:", "nextPutAll:", unescape("%2C")],
  11540. referencedClasses: []
  11541. }),
  11542. smalltalk.Compiler);
  11543. smalltalk.addMethod(
  11544. unescape('_visitVariableNode_'),
  11545. smalltalk.method({
  11546. selector: unescape('visitVariableNode%3A'),
  11547. category: 'visiting',
  11548. fn: function (aNode){
  11549. var self=this;
  11550. var varName=nil;
  11551. ((($receiver = smalltalk.send(smalltalk.send(smalltalk.send(self, "_currentClass", []), "_allInstanceVariableNames", []), "_includes_", [smalltalk.send(aNode, "_value", [])])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("self%5B%27@"), "__comma", [smalltalk.send(aNode, "_value", [])]), "__comma", [unescape("%27%5D")])]);})() : (function(){varName=smalltalk.send(self, "_safeVariableNameFor_", [smalltalk.send(aNode, "_value", [])]);return ((($receiver = smalltalk.send(smalltalk.send(self, "_knownVariables", []), "_includes_", [varName])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){smalltalk.send(self['@unknownVariables'], "_add_", [smalltalk.send(aNode, "_value", [])]);return ((($receiver = smalltalk.send(aNode, "_assigned", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);})() : (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(unescape("%28typeof%20"), "__comma", [varName]), "__comma", [unescape("%20%3D%3D%20%27undefined%27%20%3F%20nil%20%3A%20")]), "__comma", [varName]), "__comma", [unescape("%29")])]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(unescape("%28typeof%20"), "__comma", [varName]), "__comma", [unescape("%20%3D%3D%20%27undefined%27%20%3F%20nil%20%3A%20")]), "__comma", [varName]), "__comma", [unescape("%29")])]);})]));})() : (function(){return ((($receiver = smalltalk.send(smalltalk.send(aNode, "_value", []), "__eq", ["thisContext"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28smalltalk.getThisContext%28%29%29")]);})() : (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28smalltalk.getThisContext%28%29%29")]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);})]));})()) : smalltalk.send($receiver, "_ifFalse_ifTrue_", [(function(){smalltalk.send(self['@unknownVariables'], "_add_", [smalltalk.send(aNode, "_value", [])]);return ((($receiver = smalltalk.send(aNode, "_assigned", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);})() : (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(unescape("%28typeof%20"), "__comma", [varName]), "__comma", [unescape("%20%3D%3D%20%27undefined%27%20%3F%20nil%20%3A%20")]), "__comma", [varName]), "__comma", [unescape("%29")])]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(unescape("%28typeof%20"), "__comma", [varName]), "__comma", [unescape("%20%3D%3D%20%27undefined%27%20%3F%20nil%20%3A%20")]), "__comma", [varName]), "__comma", [unescape("%29")])]);})]));}), (function(){return ((($receiver = smalltalk.send(smalltalk.send(aNode, "_value", []), "__eq", ["thisContext"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28smalltalk.getThisContext%28%29%29")]);})() : (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28smalltalk.getThisContext%28%29%29")]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);})]));})]));})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("self%5B%27@"), "__comma", [smalltalk.send(aNode, "_value", [])]), "__comma", [unescape("%27%5D")])]);}), (function(){varName=smalltalk.send(self, "_safeVariableNameFor_", [smalltalk.send(aNode, "_value", [])]);return ((($receiver = smalltalk.send(smalltalk.send(self, "_knownVariables", []), "_includes_", [varName])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){smalltalk.send(self['@unknownVariables'], "_add_", [smalltalk.send(aNode, "_value", [])]);return ((($receiver = smalltalk.send(aNode, "_assigned", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);})() : (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(unescape("%28typeof%20"), "__comma", [varName]), "__comma", [unescape("%20%3D%3D%20%27undefined%27%20%3F%20nil%20%3A%20")]), "__comma", [varName]), "__comma", [unescape("%29")])]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(unescape("%28typeof%20"), "__comma", [varName]), "__comma", [unescape("%20%3D%3D%20%27undefined%27%20%3F%20nil%20%3A%20")]), "__comma", [varName]), "__comma", [unescape("%29")])]);})]));})() : (function(){return ((($receiver = smalltalk.send(smalltalk.send(aNode, "_value", []), "__eq", ["thisContext"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28smalltalk.getThisContext%28%29%29")]);})() : (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28smalltalk.getThisContext%28%29%29")]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);})]));})()) : smalltalk.send($receiver, "_ifFalse_ifTrue_", [(function(){smalltalk.send(self['@unknownVariables'], "_add_", [smalltalk.send(aNode, "_value", [])]);return ((($receiver = smalltalk.send(aNode, "_assigned", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);})() : (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(unescape("%28typeof%20"), "__comma", [varName]), "__comma", [unescape("%20%3D%3D%20%27undefined%27%20%3F%20nil%20%3A%20")]), "__comma", [varName]), "__comma", [unescape("%29")])]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(unescape("%28typeof%20"), "__comma", [varName]), "__comma", [unescape("%20%3D%3D%20%27undefined%27%20%3F%20nil%20%3A%20")]), "__comma", [varName]), "__comma", [unescape("%29")])]);})]));}), (function(){return ((($receiver = smalltalk.send(smalltalk.send(aNode, "_value", []), "__eq", ["thisContext"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28smalltalk.getThisContext%28%29%29")]);})() : (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28smalltalk.getThisContext%28%29%29")]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [varName]);})]));})]));})]));
  11552. return self;},
  11553. args: ["aNode"],
  11554. source: unescape('visitVariableNode%3A%20aNode%0A%09%7C%20varName%20%7C%0A%09%28self%20currentClass%20allInstanceVariableNames%20includes%3A%20aNode%20value%29%20%0A%09%09ifTrue%3A%20%5Bstream%20nextPutAll%3A%20%27self%5B%27%27@%27%2C%20aNode%20value%2C%20%27%27%27%5D%27%5D%0A%09%09ifFalse%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09varName%20%3A%3D%20self%20safeVariableNameFor%3A%20aNode%20value.%0A%09%09%09%28self%20knownVariables%20includes%3A%20varName%29%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09ifFalse%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09unknownVariables%20add%3A%20aNode%20value.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09aNode%20assigned%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09ifTrue%3A%20%5Bstream%20nextPutAll%3A%20varName%5D%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09ifFalse%3A%20%5Bstream%20nextPutAll%3A%20%27%28typeof%20%27%2C%20varName%2C%20%27%20%3D%3D%20%27%27undefined%27%27%20%3F%20nil%20%3A%20%27%2C%20varName%2C%20%27%29%27%5D%5D%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09aNode%20value%20%3D%20%27thisContext%27%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09ifTrue%3A%20%5Bstream%20nextPutAll%3A%20%27%28smalltalk.getThisContext%28%29%29%27%5D%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%09%09%09ifFalse%3A%20%5Bstream%20nextPutAll%3A%20varName%5D%5D%5D'),
  11555. messageSends: ["ifTrue:ifFalse:", "includes:", "allInstanceVariableNames", "currentClass", "value", "nextPutAll:", unescape("%2C"), "safeVariableNameFor:", "ifFalse:ifTrue:", "knownVariables", "add:", "assigned", unescape("%3D")],
  11556. referencedClasses: []
  11557. }),
  11558. smalltalk.Compiler);
  11559. smalltalk.addMethod(
  11560. unescape('_visitJSStatementNode_'),
  11561. smalltalk.method({
  11562. selector: unescape('visitJSStatementNode%3A'),
  11563. category: 'visiting',
  11564. fn: function (aNode){
  11565. var self=this;
  11566. smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(aNode, "_source", []), "_replace_with_", [unescape("%3E%3E"), unescape("%3E")])]);
  11567. return self;},
  11568. args: ["aNode"],
  11569. source: unescape('visitJSStatementNode%3A%20aNode%0A%09stream%20nextPutAll%3A%20%28aNode%20source%20replace%3A%20%27%3E%3E%27%20with%3A%20%27%3E%27%29'),
  11570. messageSends: ["nextPutAll:", "replace:with:", "source"],
  11571. referencedClasses: []
  11572. }),
  11573. smalltalk.Compiler);
  11574. smalltalk.addMethod(
  11575. unescape('_parse_'),
  11576. smalltalk.method({
  11577. selector: unescape('parse%3A'),
  11578. category: 'compiling',
  11579. fn: function (aString){
  11580. var self=this;
  11581. return smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_parse_", [aString]);
  11582. return self;},
  11583. args: ["aString"],
  11584. source: unescape('parse%3A%20aString%0A%20%20%20%20%5ESmalltalk%20current%20parse%3A%20aString'),
  11585. messageSends: ["parse:", "current"],
  11586. referencedClasses: ["Smalltalk"]
  11587. }),
  11588. smalltalk.Compiler);
  11589. smalltalk.addMethod(
  11590. unescape('_parseExpression_'),
  11591. smalltalk.method({
  11592. selector: unescape('parseExpression%3A'),
  11593. category: 'compiling',
  11594. fn: function (aString){
  11595. var self=this;
  11596. return smalltalk.send(self, "_parse_", [smalltalk.send(smalltalk.send(unescape("doIt%20%5E%5B"), "__comma", [aString]), "__comma", [unescape("%5D%20value")])]);
  11597. return self;},
  11598. args: ["aString"],
  11599. source: unescape('parseExpression%3A%20aString%0A%20%20%20%20%5Eself%20parse%3A%20%27doIt%20%5E%5B%27%2C%20aString%2C%20%27%5D%20value%27'),
  11600. messageSends: ["parse:", unescape("%2C")],
  11601. referencedClasses: []
  11602. }),
  11603. smalltalk.Compiler);
  11604. smalltalk.addMethod(
  11605. unescape('_unknownVariables'),
  11606. smalltalk.method({
  11607. selector: unescape('unknownVariables'),
  11608. category: 'accessing',
  11609. fn: function (){
  11610. var self=this;
  11611. return smalltalk.send(self['@unknownVariables'], "_copy", []);
  11612. return self;},
  11613. args: [],
  11614. source: unescape('unknownVariables%0A%09%5EunknownVariables%20copy'),
  11615. messageSends: ["copy"],
  11616. referencedClasses: []
  11617. }),
  11618. smalltalk.Compiler);
  11619. smalltalk.addMethod(
  11620. unescape('_pseudoVariables'),
  11621. smalltalk.method({
  11622. selector: unescape('pseudoVariables'),
  11623. category: 'accessing',
  11624. fn: function (){
  11625. var self=this;
  11626. return ["self", "super", "true", "false", "nil", "thisContext"];
  11627. return self;},
  11628. args: [],
  11629. source: unescape('pseudoVariables%0A%09%5E%23%28%27self%27%20%27super%27%20%27true%27%20%27false%27%20%27nil%27%20%27thisContext%27%29'),
  11630. messageSends: [],
  11631. referencedClasses: []
  11632. }),
  11633. smalltalk.Compiler);
  11634. smalltalk.addMethod(
  11635. unescape('_tempVariables'),
  11636. smalltalk.method({
  11637. selector: unescape('tempVariables'),
  11638. category: 'accessing',
  11639. fn: function (){
  11640. var self=this;
  11641. return smalltalk.send(self['@tempVariables'], "_copy", []);
  11642. return self;},
  11643. args: [],
  11644. source: unescape('tempVariables%0A%09%5EtempVariables%20copy'),
  11645. messageSends: ["copy"],
  11646. referencedClasses: []
  11647. }),
  11648. smalltalk.Compiler);
  11649. smalltalk.addMethod(
  11650. unescape('_knownVariables'),
  11651. smalltalk.method({
  11652. selector: unescape('knownVariables'),
  11653. category: 'accessing',
  11654. fn: function (){
  11655. var self=this;
  11656. return (function($rec){smalltalk.send($rec, "_addAll_", [smalltalk.send(self, "_tempVariables", [])]);smalltalk.send($rec, "_addAll_", [smalltalk.send(self, "_argVariables", [])]);return smalltalk.send($rec, "_yourself", []);})(smalltalk.send(self, "_pseudoVariables", []));
  11657. return self;},
  11658. args: [],
  11659. source: unescape('knownVariables%0A%09%5Eself%20pseudoVariables%20%0A%09%09addAll%3A%20self%20tempVariables%3B%0A%09%09addAll%3A%20self%20argVariables%3B%0A%09%09yourself'),
  11660. messageSends: ["addAll:", "tempVariables", "argVariables", "yourself", "pseudoVariables"],
  11661. referencedClasses: []
  11662. }),
  11663. smalltalk.Compiler);
  11664. smalltalk.addMethod(
  11665. unescape('_recompile_'),
  11666. smalltalk.method({
  11667. selector: unescape('recompile%3A'),
  11668. category: 'compiling',
  11669. fn: function (aClass){
  11670. var self=this;
  11671. smalltalk.send(smalltalk.send(aClass, "_methodDictionary", []), "_do_", [(function(each){var method=nil;
  11672. method=smalltalk.send(self, "_load_forClass_", [smalltalk.send(each, "_source", []), aClass]);smalltalk.send(method, "_category_", [smalltalk.send(each, "_category", [])]);return smalltalk.send(aClass, "_addCompiledMethod_", [method]);})]);
  11673. ((($receiver = smalltalk.send(aClass, "_isMetaclass", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_recompile_", [smalltalk.send(aClass, "_class", [])]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(self, "_recompile_", [smalltalk.send(aClass, "_class", [])]);})]));
  11674. return self;},
  11675. args: ["aClass"],
  11676. source: unescape('recompile%3A%20aClass%0A%09aClass%20methodDictionary%20do%3A%20%5B%3Aeach%20%7C%7C%20method%20%7C%0A%09%09method%20%3A%3D%20self%20load%3A%20each%20source%20forClass%3A%20aClass.%0A%09%09method%20category%3A%20each%20category.%0A%09%09aClass%20addCompiledMethod%3A%20method%5D.%0A%09aClass%20isMetaclass%20ifFalse%3A%20%5Bself%20recompile%3A%20aClass%20class%5D'),
  11677. messageSends: ["do:", "methodDictionary", "load:forClass:", "source", "category:", "category", "addCompiledMethod:", "ifFalse:", "isMetaclass", "recompile:", "class"],
  11678. referencedClasses: []
  11679. }),
  11680. smalltalk.Compiler);
  11681. smalltalk.addMethod(
  11682. unescape('_recompileAll'),
  11683. smalltalk.method({
  11684. selector: unescape('recompileAll'),
  11685. category: 'compiling',
  11686. fn: function (){
  11687. var self=this;
  11688. smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_classes", []), "_do_", [(function(each){(function($rec){smalltalk.send($rec, "_show_", [each]);return smalltalk.send($rec, "_cr", []);})((smalltalk.Transcript || Transcript));return smalltalk.send((function(){return smalltalk.send(self, "_recompile_", [each]);}), "_valueWithTimeout_", [(100)]);})]);
  11689. return self;},
  11690. args: [],
  11691. source: unescape('recompileAll%0A%09Smalltalk%20current%20classes%20do%3A%20%5B%3Aeach%20%7C%0A%09%09Transcript%20show%3A%20each%3B%20cr.%0A%09%09%5Bself%20recompile%3A%20each%5D%20valueWithTimeout%3A%20100%5D'),
  11692. messageSends: ["do:", "classes", "current", "show:", "cr", "valueWithTimeout:", "recompile:"],
  11693. referencedClasses: ["Smalltalk", "Transcript"]
  11694. }),
  11695. smalltalk.Compiler);
  11696. smalltalk.addMethod(
  11697. unescape('_classNameFor_'),
  11698. smalltalk.method({
  11699. selector: unescape('classNameFor%3A'),
  11700. category: 'accessing',
  11701. fn: function (aClass){
  11702. var self=this;
  11703. return ((($receiver = smalltalk.send(aClass, "_isMetaclass", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_instanceClass", []), "_name", []), "__comma", [".klass"]);})() : (function(){return ((($receiver = smalltalk.send(aClass, "_isNil", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return "nil";})() : (function(){return smalltalk.send(aClass, "_name", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return "nil";}), (function(){return smalltalk.send(aClass, "_name", []);})]));})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(smalltalk.send(smalltalk.send(aClass, "_instanceClass", []), "_name", []), "__comma", [".klass"]);}), (function(){return ((($receiver = smalltalk.send(aClass, "_isNil", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return "nil";})() : (function(){return smalltalk.send(aClass, "_name", []);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return "nil";}), (function(){return smalltalk.send(aClass, "_name", []);})]));})]));
  11704. return self;},
  11705. args: ["aClass"],
  11706. source: unescape('classNameFor%3A%20aClass%0A%09%5EaClass%20isMetaclass%0A%09%20%20%20%20ifTrue%3A%20%5BaClass%20instanceClass%20name%2C%20%27.klass%27%5D%0A%09%20%20%20%20ifFalse%3A%20%5B%0A%09%09aClass%20isNil%0A%09%09%20%20%20%20ifTrue%3A%20%5B%27nil%27%5D%0A%09%09%20%20%20%20ifFalse%3A%20%5BaClass%20name%5D%5D'),
  11707. messageSends: ["ifTrue:ifFalse:", "isMetaclass", unescape("%2C"), "name", "instanceClass", "isNil"],
  11708. referencedClasses: []
  11709. }),
  11710. smalltalk.Compiler);
  11711. smalltalk.addMethod(
  11712. unescape('_visitFailure_'),
  11713. smalltalk.method({
  11714. selector: unescape('visitFailure%3A'),
  11715. category: 'visiting',
  11716. fn: function (aFailure){
  11717. var self=this;
  11718. smalltalk.send(self, "_error_", [smalltalk.send(aFailure, "_asString", [])]);
  11719. return self;},
  11720. args: ["aFailure"],
  11721. source: unescape('visitFailure%3A%20aFailure%0A%09self%20error%3A%20aFailure%20asString'),
  11722. messageSends: ["error:", "asString"],
  11723. referencedClasses: []
  11724. }),
  11725. smalltalk.Compiler);
  11726. smalltalk.addMethod(
  11727. unescape('_setupClass_'),
  11728. smalltalk.method({
  11729. selector: unescape('setupClass%3A'),
  11730. category: 'compiling',
  11731. fn: function (aClass){
  11732. var self=this;
  11733. smalltalk.init(aClass);
  11734. return self;},
  11735. args: ["aClass"],
  11736. source: unescape('setupClass%3A%20aClass%0A%09%3Csmalltalk.init%28aClass%29%3E'),
  11737. messageSends: [],
  11738. referencedClasses: []
  11739. }),
  11740. smalltalk.Compiler);
  11741. smalltalk.addMethod(
  11742. unescape('_send_to_arguments_superSend_'),
  11743. smalltalk.method({
  11744. selector: unescape('send%3Ato%3Aarguments%3AsuperSend%3A'),
  11745. category: 'visiting',
  11746. fn: function (aSelector, aReceiver, aCollection, aBoolean){
  11747. var self=this;
  11748. return smalltalk.send((smalltalk.String || String), "_streamContents_", [(function(str){var tmp=nil;
  11749. tmp=self['@stream'];smalltalk.send(str, "_nextPutAll_", [unescape("smalltalk.send%28")]);smalltalk.send(str, "_nextPutAll_", [aReceiver]);smalltalk.send(str, "_nextPutAll_", [smalltalk.send(smalltalk.send(unescape("%2C%20%22"), "__comma", [smalltalk.send(aSelector, "_asSelector", [])]), "__comma", [unescape("%22%2C%20%5B")])]);self['@stream']=str;smalltalk.send(aCollection, "_do_separatedBy_", [(function(each){return smalltalk.send(self, "_visit_", [each]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%2C%20")]);})]);self['@stream']=tmp;smalltalk.send(str, "_nextPutAll_", [unescape("%5D")]);((($receiver = aBoolean).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(str, "_nextPutAll_", [smalltalk.send(unescape("%2C%20smalltalk."), "__comma", [smalltalk.send(self, "_classNameFor_", [smalltalk.send(smalltalk.send(self, "_currentClass", []), "_superclass", [])])])]);})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return smalltalk.send(str, "_nextPutAll_", [smalltalk.send(unescape("%2C%20smalltalk."), "__comma", [smalltalk.send(self, "_classNameFor_", [smalltalk.send(smalltalk.send(self, "_currentClass", []), "_superclass", [])])])]);})]));return smalltalk.send(str, "_nextPutAll_", [unescape("%29")]);})]);
  11750. return self;},
  11751. args: ["aSelector", "aReceiver", "aCollection", "aBoolean"],
  11752. source: unescape('send%3A%20aSelector%20to%3A%20aReceiver%20arguments%3A%20aCollection%20superSend%3A%20aBoolean%0A%09%5EString%20streamContents%3A%20%5B%3Astr%20%7C%7C%20tmp%20%7C%0A%20%20%20%20%20%20%20%20%09tmp%20%3A%3D%20stream.%0A%09%09str%20nextPutAll%3A%20%27smalltalk.send%28%27.%0A%09%09str%20nextPutAll%3A%20aReceiver.%0A%09%09str%20nextPutAll%3A%20%27%2C%20%22%27%2C%20aSelector%20asSelector%2C%20%27%22%2C%20%5B%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20stream%20%3A%3D%20str.%0A%09%09aCollection%0A%09%20%20%20%20%09%09do%3A%20%5B%3Aeach%20%7C%20self%20visit%3A%20each%5D%0A%09%20%20%20%20%09%09separatedBy%3A%20%5Bstream%20nextPutAll%3A%20%27%2C%20%27%5D.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20stream%20%3A%3D%20tmp.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20str%20nextPutAll%3A%20%27%5D%27.%0A%09%09aBoolean%20ifTrue%3A%20%5B%0A%09%09%09str%20nextPutAll%3A%20%27%2C%20smalltalk.%27%2C%20%28self%20classNameFor%3A%20self%20currentClass%20superclass%29%5D.%0A%09%09str%20nextPutAll%3A%20%27%29%27%5D'),
  11753. messageSends: ["streamContents:", "nextPutAll:", unescape("%2C"), "asSelector", "do:separatedBy:", "visit:", "ifTrue:", "classNameFor:", "superclass", "currentClass"],
  11754. referencedClasses: ["String"]
  11755. }),
  11756. smalltalk.Compiler);
  11757. smalltalk.addMethod(
  11758. unescape('_checkClass_for_'),
  11759. smalltalk.method({
  11760. selector: unescape('checkClass%3Afor%3A'),
  11761. category: 'optimizations',
  11762. fn: function (aClassName, receiver){
  11763. var self=this;
  11764. smalltalk.send(self['@stream'], "_nextPutAll_", [smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(unescape("%28%28%28%24receiver%20%3D%20"), "__comma", [receiver]), "__comma", [unescape("%29.klass%20%3D%3D%3D%20smalltalk.")]), "__comma", [aClassName]), "__comma", [unescape("%29%20%3F%20")])]);
  11765. return self;},
  11766. args: ["aClassName", "receiver"],
  11767. source: unescape('checkClass%3A%20aClassName%20for%3A%20receiver%0A%20%20%20%20%20%20%20%20stream%20nextPutAll%3A%20%27%28%28%28%24receiver%20%3D%20%27%2C%20receiver%2C%20%27%29.klass%20%3D%3D%3D%20smalltalk.%27%2C%20aClassName%2C%20%27%29%20%3F%20%27'),
  11768. messageSends: ["nextPutAll:", unescape("%2C")],
  11769. referencedClasses: []
  11770. }),
  11771. smalltalk.Compiler);
  11772. smalltalk.addMethod(
  11773. unescape('_inlineLiteral_receiverNode_argumentNodes_'),
  11774. smalltalk.method({
  11775. selector: unescape('inlineLiteral%3AreceiverNode%3AargumentNodes%3A'),
  11776. category: 'optimizations',
  11777. fn: function (aSelector, anObject, aCollection){
  11778. var self=this;
  11779. var inlined=nil;
  11780. inlined=false;
  11781. ((($receiver = smalltalk.send(aSelector, "__eq", ["whileTrue:"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(smalltalk.send(anObject, "_isBlockNode", []), "_and_", [(function(){return smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", []);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%7D%7D%29%28%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%7D%7D%29%28%29")]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(smalltalk.send(anObject, "_isBlockNode", []), "_and_", [(function(){return smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", []);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%7D%7D%29%28%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%7D%7D%29%28%29")]);return inlined=true;})]));})]));
  11782. ((($receiver = smalltalk.send(aSelector, "__eq", ["whileFalse:"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(smalltalk.send(anObject, "_isBlockNode", []), "_and_", [(function(){return smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", []);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28%21")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%7D%7D%29%28%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28%21")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%7D%7D%29%28%29")]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(smalltalk.send(anObject, "_isBlockNode", []), "_and_", [(function(){return smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", []);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28%21")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%7D%7D%29%28%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28%21")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%7D%7D%29%28%29")]);return inlined=true;})]));})]));
  11783. ((($receiver = smalltalk.send(aSelector, "__eq", ["whileTrue"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(anObject, "_isBlockNode", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B%7D%7D%29%28%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B%7D%7D%29%28%29")]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(anObject, "_isBlockNode", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B%7D%7D%29%28%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B%7D%7D%29%28%29")]);return inlined=true;})]));})]));
  11784. ((($receiver = smalltalk.send(aSelector, "__eq", ["whileFalse"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(anObject, "_isBlockNode", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28%21")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B%7D%7D%29%28%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28%21")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B%7D%7D%29%28%29")]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(anObject, "_isBlockNode", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28%21")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B%7D%7D%29%28%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28function%28%29%7Bwhile%28%21")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29%20%7B%7D%7D%29%28%29")]);return inlined=true;})]));})]));
  11785. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("+")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20+%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20+%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20+%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20+%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})]));
  11786. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("-")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20-%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20-%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20-%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20-%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})]));
  11787. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("*")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20*%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20*%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20*%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20*%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})]));
  11788. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("/")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20/%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20/%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20/%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20/%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})]));
  11789. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("%3C")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3C%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3C%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3C%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3C%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})]));
  11790. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("%3C%3D")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3C%3D%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3C%3D%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3C%3D%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3C%3D%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})]));
  11791. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("%3E")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3E%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3E%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3E%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3E%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})]));
  11792. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("%3E%3D")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3E%3D%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3E%3D%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(self, "_isNode_ofClass_", [anObject, (smalltalk.Number || Number)])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3E%3D%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%20%3E%3D%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));})]));
  11793. ((($receiver = smalltalk.send(aSelector, "__eq", ["ifNil:"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%3D%3D%20nil%20%7C%7C%20%24receiver%20%3D%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20%24receiver")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%3D%3D%20nil%20%7C%7C%20%24receiver%20%3D%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20%24receiver")]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%3D%3D%20nil%20%7C%7C%20%24receiver%20%3D%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20%24receiver")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%3D%3D%20nil%20%7C%7C%20%24receiver%20%3D%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20%24receiver")]);return inlined=true;})]));})]));
  11794. ((($receiver = smalltalk.send(aSelector, "__eq", ["ifNotNil:"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%21%3D%20nil%20%26%26%20%24receiver%20%21%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20nil")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%21%3D%20nil%20%26%26%20%24receiver%20%21%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20nil")]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%21%3D%20nil%20%26%26%20%24receiver%20%21%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20nil")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%21%3D%20nil%20%26%26%20%24receiver%20%21%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20nil")]);return inlined=true;})]));})]));
  11795. ((($receiver = smalltalk.send(aSelector, "__eq", ["ifNil:ifNotNil:"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", []), "_and_", [(function(){return smalltalk.send(smalltalk.send(aCollection, "_second", []), "_isBlockNode", []);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%3D%3D%20nil%20%7C%7C%20%24receiver%20%3D%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%3D%3D%20nil%20%7C%7C%20%24receiver%20%3D%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29")]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", []), "_and_", [(function(){return smalltalk.send(smalltalk.send(aCollection, "_second", []), "_isBlockNode", []);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%3D%3D%20nil%20%7C%7C%20%24receiver%20%3D%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%3D%3D%20nil%20%7C%7C%20%24receiver%20%3D%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29")]);return inlined=true;})]));})]));
  11796. ((($receiver = smalltalk.send(aSelector, "__eq", ["ifNotNil:ifNil:"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", []), "_and_", [(function(){return smalltalk.send(smalltalk.send(aCollection, "_second", []), "_isBlockNode", []);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%3D%3D%20nil%20%7C%7C%20%24receiver%20%3D%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%3D%3D%20nil%20%7C%7C%20%24receiver%20%3D%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29")]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", []), "_and_", [(function(){return smalltalk.send(smalltalk.send(aCollection, "_second", []), "_isBlockNode", []);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%3D%3D%20nil%20%7C%7C%20%24receiver%20%3D%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%28%24receiver%20%3D%20")]);smalltalk.send(self, "_visit_", [anObject]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%29%20%3D%3D%20nil%20%7C%7C%20%24receiver%20%3D%3D%20undefined%29%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29")]);return inlined=true;})]));})]));
  11797. return inlined;
  11798. return self;},
  11799. args: ["aSelector", "anObject", "aCollection"],
  11800. source: unescape('inlineLiteral%3A%20aSelector%20receiverNode%3A%20anObject%20argumentNodes%3A%20aCollection%0A%20%20%20%20%20%20%20%20%7C%20inlined%20%7C%0A%20%20%20%20%20%20%20%20inlined%20%3A%3D%20false.%0A%20%0A%09%22--%20BlockClosures%20--%22%0A%0A%09%28aSelector%20%3D%20%27whileTrue%3A%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09%28anObject%20isBlockNode%20and%3A%20%5BaCollection%20first%20isBlockNode%5D%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28function%28%29%7Bwhile%28%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28%29%29%20%7B%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%28%29%7D%7D%29%28%29%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27whileFalse%3A%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09%28anObject%20isBlockNode%20and%3A%20%5BaCollection%20first%20isBlockNode%5D%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28function%28%29%7Bwhile%28%21%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28%29%29%20%7B%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%28%29%7D%7D%29%28%29%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27whileTrue%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09anObject%20isBlockNode%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28function%28%29%7Bwhile%28%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28%29%29%20%7B%7D%7D%29%28%29%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27whileFalse%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09anObject%20isBlockNode%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28function%28%29%7Bwhile%28%21%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28%29%29%20%7B%7D%7D%29%28%29%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%22--%20Numbers%20--%22%0A%0A%09%28aSelector%20%3D%20%27+%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09%28self%20isNode%3A%20anObject%20ofClass%3A%20Number%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%20+%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27-%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09%28self%20isNode%3A%20anObject%20ofClass%3A%20Number%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%20-%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27*%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09%28self%20isNode%3A%20anObject%20ofClass%3A%20Number%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%20*%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27/%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09%28self%20isNode%3A%20anObject%20ofClass%3A%20Number%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%20/%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27%3C%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09%28self%20isNode%3A%20anObject%20ofClass%3A%20Number%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%20%3C%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27%3C%3D%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09%28self%20isNode%3A%20anObject%20ofClass%3A%20Number%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%20%3C%3D%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27%3E%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09%28self%20isNode%3A%20anObject%20ofClass%3A%20Number%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%20%3E%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27%3E%3D%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09%28self%20isNode%3A%20anObject%20ofClass%3A%20Number%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%20%3E%3D%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09%20%20%20%0A%09%22--%20UndefinedObject%20--%22%0A%0A%09%28aSelector%20%3D%20%27ifNil%3A%27%29%20ifTrue%3A%20%5B%0A%09%09aCollection%20first%20isBlockNode%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%28%28%24receiver%20%3D%20%27.%0A%20%20%20%20%20%20%20%20%20%20%09%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%29%20%3D%3D%20nil%20%7C%7C%20%24receiver%20%3D%3D%20undefined%29%20%3F%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28%29%20%3A%20%24receiver%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27ifNotNil%3A%27%29%20ifTrue%3A%20%5B%0A%09%09aCollection%20first%20isBlockNode%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%28%28%24receiver%20%3D%20%27.%0A%20%20%20%20%20%20%20%20%20%20%09%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%29%20%21%3D%20nil%20%26%26%20%24receiver%20%21%3D%20undefined%29%20%3F%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28%29%20%3A%20nil%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27ifNil%3AifNotNil%3A%27%29%20ifTrue%3A%20%5B%0A%09%09%28aCollection%20first%20isBlockNode%20and%3A%20%5BaCollection%20second%20isBlockNode%5D%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%28%28%24receiver%20%3D%20%27.%0A%20%20%20%20%20%20%20%20%20%20%09%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%29%20%3D%3D%20nil%20%7C%7C%20%24receiver%20%3D%3D%20undefined%29%20%3F%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28%29%20%3A%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20second.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28%29%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27ifNotNil%3AifNil%3A%27%29%20ifTrue%3A%20%5B%0A%09%09%28aCollection%20first%20isBlockNode%20and%3A%20%5BaCollection%20second%20isBlockNode%5D%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%28%28%24receiver%20%3D%20%27.%0A%20%20%20%20%20%20%20%20%20%20%09%09self%20visit%3A%20anObject.%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%29%20%3D%3D%20nil%20%7C%7C%20%24receiver%20%3D%3D%20undefined%29%20%3F%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20second.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28%29%20%3A%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28%29%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%0A%20%20%20%20%20%20%20%20%5Einlined'),
  11801. messageSends: ["ifTrue:", unescape("%3D"), "and:", "isBlockNode", "first", "nextPutAll:", "visit:", "isNode:ofClass:", "second"],
  11802. referencedClasses: ["Number"]
  11803. }),
  11804. smalltalk.Compiler);
  11805. smalltalk.addMethod(
  11806. unescape('_isNode_ofClass_'),
  11807. smalltalk.method({
  11808. selector: unescape('isNode%3AofClass%3A'),
  11809. category: 'optimizations',
  11810. fn: function (aNode, aClass){
  11811. var self=this;
  11812. return smalltalk.send(smalltalk.send(aNode, "_isValueNode", []), "_and_", [(function(){return smalltalk.send(smalltalk.send(smalltalk.send(smalltalk.send(aNode, "_value", []), "_class", []), "__eq", [aClass]), "_or_", [(function(){return smalltalk.send(smalltalk.send(smalltalk.send(aNode, "_value", []), "__eq", ["self"]), "_and_", [(function(){return smalltalk.send(smalltalk.send(self, "_currentClass", []), "__eq", [aClass]);})]);})]);})]);
  11813. return self;},
  11814. args: ["aNode", "aClass"],
  11815. source: unescape('isNode%3A%20aNode%20ofClass%3A%20aClass%0A%09%5EaNode%20isValueNode%20and%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09aNode%20value%20class%20%3D%20aClass%20or%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%09%09aNode%20value%20%3D%20%27self%27%20and%3A%20%5Bself%20currentClass%20%3D%20aClass%5D%5D%5D'),
  11816. messageSends: ["and:", "isValueNode", "or:", unescape("%3D"), "class", "value", "currentClass"],
  11817. referencedClasses: []
  11818. }),
  11819. smalltalk.Compiler);
  11820. smalltalk.addMethod(
  11821. unescape('_inline_receiver_argumentNodes_'),
  11822. smalltalk.method({
  11823. selector: unescape('inline%3Areceiver%3AargumentNodes%3A'),
  11824. category: 'optimizations',
  11825. fn: function (aSelector, receiver, aCollection){
  11826. var self=this;
  11827. var inlined=nil;
  11828. inlined=false;
  11829. ((($receiver = smalltalk.send(aSelector, "__eq", ["ifFalse:"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%21%20%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20nil%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%21%20%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20nil%29")]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%21%20%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20nil%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%21%20%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20nil%29")]);return inlined=true;})]));})]));
  11830. ((($receiver = smalltalk.send(aSelector, "__eq", ["ifTrue:"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20nil%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20nil%29")]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20nil%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20nil%29")]);return inlined=true;})]));})]));
  11831. ((($receiver = smalltalk.send(aSelector, "__eq", ["ifTrue:ifFalse:"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", []), "_and_", [(function(){return smalltalk.send(smalltalk.send(aCollection, "_second", []), "_isBlockNode", []);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29")]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", []), "_and_", [(function(){return smalltalk.send(smalltalk.send(aCollection, "_second", []), "_isBlockNode", []);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29")]);return inlined=true;})]));})]));
  11832. ((($receiver = smalltalk.send(aSelector, "__eq", ["ifFalse:ifTrue:"])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return ((($receiver = smalltalk.send(smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", []), "_and_", [(function(){return smalltalk.send(smalltalk.send(aCollection, "_second", []), "_isBlockNode", []);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%21%20%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%21%20%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29")]);return inlined=true;})]));})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){return ((($receiver = smalltalk.send(smalltalk.send(smalltalk.send(aCollection, "_first", []), "_isBlockNode", []), "_and_", [(function(){return smalltalk.send(smalltalk.send(aCollection, "_second", []), "_isBlockNode", []);})])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%21%20%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29")]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Boolean", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%21%20%24receiver%20%3F%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%20%3A%20")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_second", [])]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%28%29%29")]);return inlined=true;})]));})]));
  11833. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("%3C")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20%3C")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20%3C")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));
  11834. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("%3C%3D")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20%3C%3D")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20%3C%3D")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));
  11835. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("%3E")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20%3E")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20%3E")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));
  11836. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("%3E%3D")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20%3E%3D")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20%3E%3D")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));
  11837. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("+")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20+")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20+")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));
  11838. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("-")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20-")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20-")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));
  11839. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("*")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20*")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20*")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));
  11840. ((($receiver = smalltalk.send(aSelector, "__eq", [unescape("/")])).klass === smalltalk.Boolean) ? ($receiver ? (function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20/")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})() : nil) : smalltalk.send($receiver, "_ifTrue_", [(function(){smalltalk.send(self, "_checkClass_for_", ["Number", receiver]);smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%24receiver%20/")]);smalltalk.send(self, "_visit_", [smalltalk.send(aCollection, "_first", [])]);return inlined=true;})]));
  11841. return inlined;
  11842. return self;},
  11843. args: ["aSelector", "receiver", "aCollection"],
  11844. source: unescape('inline%3A%20aSelector%20receiver%3A%20receiver%20argumentNodes%3A%20aCollection%0A%20%20%20%20%20%20%20%20%7C%20inlined%20%7C%0A%20%20%20%20%20%20%20%20inlined%20%3A%3D%20false.%0A%0A%09%22--%20Booleans%20--%22%0A%0A%09%28aSelector%20%3D%20%27ifFalse%3A%27%29%20ifTrue%3A%20%5B%0A%09%09aCollection%20first%20isBlockNode%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20checkClass%3A%20%27Boolean%27%20for%3A%20receiver.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28%21%20%24receiver%20%3F%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%28%29%20%3A%20nil%29%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27ifTrue%3A%27%29%20ifTrue%3A%20%5B%0A%09%09aCollection%20first%20isBlockNode%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20checkClass%3A%20%27Boolean%27%20for%3A%20receiver.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28%24receiver%20%3F%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%28%29%20%3A%20nil%29%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27ifTrue%3AifFalse%3A%27%29%20ifTrue%3A%20%5B%0A%09%09%28aCollection%20first%20isBlockNode%20and%3A%20%5BaCollection%20second%20isBlockNode%5D%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20checkClass%3A%20%27Boolean%27%20for%3A%20receiver.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28%24receiver%20%3F%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%28%29%20%3A%20%27.%0A%20%20%20%20%20%20%20%20%20%20%09%09self%20visit%3A%20aCollection%20second.%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%28%29%29%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%28aSelector%20%3D%20%27ifFalse%3AifTrue%3A%27%29%20ifTrue%3A%20%5B%0A%09%09%28aCollection%20first%20isBlockNode%20and%3A%20%5BaCollection%20second%20isBlockNode%5D%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20checkClass%3A%20%27Boolean%27%20for%3A%20receiver.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09stream%20nextPutAll%3A%20%27%28%21%20%24receiver%20%3F%20%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%28%29%20%3A%20%27.%0A%20%20%20%20%20%20%20%20%20%20%09%09self%20visit%3A%20aCollection%20second.%0A%20%20%20%20%20%20%20%20%20%20%09%09stream%20nextPutAll%3A%20%27%28%29%29%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%09inlined%20%3A%3D%20true%5D%5D.%0A%0A%09%22--%20Numbers%20--%22%0A%0A%09%28aSelector%20%3D%20%27%3C%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20checkClass%3A%20%27Number%27%20for%3A%20receiver.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20stream%20nextPutAll%3A%20%27%24receiver%20%3C%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20inlined%20%3A%3D%20true%5D.%0A%0A%09%28aSelector%20%3D%20%27%3C%3D%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20checkClass%3A%20%27Number%27%20for%3A%20receiver.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20stream%20nextPutAll%3A%20%27%24receiver%20%3C%3D%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20inlined%20%3A%3D%20true%5D.%0A%0A%09%28aSelector%20%3D%20%27%3E%27%29%20ifTrue%3A%20%5B%20%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20checkClass%3A%20%27Number%27%20for%3A%20receiver.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20stream%20nextPutAll%3A%20%27%24receiver%20%3E%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20inlined%20%3A%3D%20true%5D.%0A%0A%09%28aSelector%20%3D%20%27%3E%3D%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20checkClass%3A%20%27Number%27%20for%3A%20receiver.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20stream%20nextPutAll%3A%20%27%24receiver%20%3E%3D%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20inlined%20%3A%3D%20true%5D.%0A%0A%20%20%20%20%20%20%20%20%28aSelector%20%3D%20%27+%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20checkClass%3A%20%27Number%27%20for%3A%20receiver.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20stream%20nextPutAll%3A%20%27%24receiver%20+%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20inlined%20%3A%3D%20true%5D.%0A%0A%20%20%20%20%20%20%20%20%28aSelector%20%3D%20%27-%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20checkClass%3A%20%27Number%27%20for%3A%20receiver.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20stream%20nextPutAll%3A%20%27%24receiver%20-%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20inlined%20%3A%3D%20true%5D.%0A%0A%20%20%20%20%20%20%20%20%28aSelector%20%3D%20%27*%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20checkClass%3A%20%27Number%27%20for%3A%20receiver.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20stream%20nextPutAll%3A%20%27%24receiver%20*%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20inlined%20%3A%3D%20true%5D.%0A%0A%20%20%20%20%20%20%20%20%28aSelector%20%3D%20%27/%27%29%20ifTrue%3A%20%5B%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20checkClass%3A%20%27Number%27%20for%3A%20receiver.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20stream%20nextPutAll%3A%20%27%24receiver%20/%27.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20self%20visit%3A%20aCollection%20first.%0A%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20%20inlined%20%3A%3D%20true%5D.%0A%0A%20%20%20%20%20%20%20%20%5Einlined'),
  11845. messageSends: ["ifTrue:", unescape("%3D"), "isBlockNode", "first", "checkClass:for:", "nextPutAll:", "visit:", "and:", "second"],
  11846. referencedClasses: []
  11847. }),
  11848. smalltalk.Compiler);
  11849. smalltalk.addMethod(
  11850. unescape('_performOptimizations'),
  11851. smalltalk.method({
  11852. selector: unescape('performOptimizations'),
  11853. category: 'testing',
  11854. fn: function (){
  11855. var self=this;
  11856. return smalltalk.send(smalltalk.send(self, "_class", []), "_performOptimizations", []);
  11857. return self;},
  11858. args: [],
  11859. source: unescape('performOptimizations%0A%09%5Eself%20class%20performOptimizations'),
  11860. messageSends: ["performOptimizations", "class"],
  11861. referencedClasses: []
  11862. }),
  11863. smalltalk.Compiler);
  11864. smalltalk.addMethod(
  11865. unescape('_source'),
  11866. smalltalk.method({
  11867. selector: unescape('source'),
  11868. category: 'accessing',
  11869. fn: function (){
  11870. var self=this;
  11871. return (($receiver = self['@source']) == nil || $receiver == undefined) ? (function(){return "";})() : $receiver;
  11872. return self;},
  11873. args: [],
  11874. source: unescape('source%0A%09%5Esource%20ifNil%3A%20%5B%27%27%5D'),
  11875. messageSends: ["ifNil:"],
  11876. referencedClasses: []
  11877. }),
  11878. smalltalk.Compiler);
  11879. smalltalk.addMethod(
  11880. unescape('_source_'),
  11881. smalltalk.method({
  11882. selector: unescape('source%3A'),
  11883. category: 'accessing',
  11884. fn: function (aString){
  11885. var self=this;
  11886. self['@source']=aString;
  11887. return self;},
  11888. args: ["aString"],
  11889. source: unescape('source%3A%20aString%0A%09source%20%3A%3D%20aString'),
  11890. messageSends: [],
  11891. referencedClasses: []
  11892. }),
  11893. smalltalk.Compiler);
  11894. smalltalk.addMethod(
  11895. unescape('_visitDynamicArrayNode_'),
  11896. smalltalk.method({
  11897. selector: unescape('visitDynamicArrayNode%3A'),
  11898. category: 'visiting',
  11899. fn: function (aNode){
  11900. var self=this;
  11901. smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%5B")]);
  11902. smalltalk.send(smalltalk.send(aNode, "_nodes", []), "_do_separatedBy_", [(function(each){return smalltalk.send(self, "_visit_", [each]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%2C")]);})]);
  11903. smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%5D")]);
  11904. return self;},
  11905. args: ["aNode"],
  11906. source: unescape('visitDynamicArrayNode%3A%20aNode%0A%09stream%20nextPutAll%3A%20%27%5B%27.%0A%09aNode%20nodes%20%0A%09%09do%3A%20%5B%3Aeach%20%7C%20self%20visit%3A%20each%5D%0A%09%09separatedBy%3A%20%5Bstream%20nextPutAll%3A%20%27%2C%27%5D.%0A%09stream%20nextPutAll%3A%20%27%5D%27'),
  11907. messageSends: ["nextPutAll:", "do:separatedBy:", "nodes", "visit:"],
  11908. referencedClasses: []
  11909. }),
  11910. smalltalk.Compiler);
  11911. smalltalk.addMethod(
  11912. unescape('_visitDynamicDictionaryNode_'),
  11913. smalltalk.method({
  11914. selector: unescape('visitDynamicDictionaryNode%3A'),
  11915. category: 'visiting',
  11916. fn: function (aNode){
  11917. var self=this;
  11918. smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("smalltalk.Dictionary._fromPairs_%28%5B")]);
  11919. smalltalk.send(smalltalk.send(aNode, "_nodes", []), "_do_separatedBy_", [(function(each){return smalltalk.send(self, "_visit_", [each]);}), (function(){return smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%2C")]);})]);
  11920. smalltalk.send(self['@stream'], "_nextPutAll_", [unescape("%5D%29")]);
  11921. return self;},
  11922. args: ["aNode"],
  11923. source: unescape('visitDynamicDictionaryNode%3A%20aNode%0A%09stream%20nextPutAll%3A%20%27smalltalk.Dictionary._fromPairs_%28%5B%27.%0A%09%09aNode%20nodes%20%0A%09%09%09do%3A%20%5B%3Aeach%20%7C%20self%20visit%3A%20each%5D%0A%09%09%09separatedBy%3A%20%5Bstream%20nextPutAll%3A%20%27%2C%27%5D.%0A%09%09stream%20nextPutAll%3A%20%27%5D%29%27'),
  11924. messageSends: ["nextPutAll:", "do:separatedBy:", "nodes", "visit:"],
  11925. referencedClasses: []
  11926. }),
  11927. smalltalk.Compiler);
  11928. smalltalk.addMethod(
  11929. unescape('_argVariables'),
  11930. smalltalk.method({
  11931. selector: unescape('argVariables'),
  11932. category: 'accessing',
  11933. fn: function (){
  11934. var self=this;
  11935. return smalltalk.send(self['@argVariables'], "_copy", []);
  11936. return self;},
  11937. args: [],
  11938. source: unescape('argVariables%0A%09%5EargVariables%20copy'),
  11939. messageSends: ["copy"],
  11940. referencedClasses: []
  11941. }),
  11942. smalltalk.Compiler);
  11943. smalltalk.addMethod(
  11944. unescape('_safeVariableNameFor_'),
  11945. smalltalk.method({
  11946. selector: unescape('safeVariableNameFor%3A'),
  11947. category: 'accessing',
  11948. fn: function (aString){
  11949. var self=this;
  11950. return ((($receiver = smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_reservedWords", []), "_includes_", [aString])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(aString, "__comma", ["_"]);})() : (function(){return aString;})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(aString, "__comma", ["_"]);}), (function(){return aString;})]));
  11951. return self;},
  11952. args: ["aString"],
  11953. source: unescape('safeVariableNameFor%3A%20aString%0A%09%5E%28Smalltalk%20current%20reservedWords%20includes%3A%20aString%29%0A%09%09ifTrue%3A%20%5BaString%2C%20%27_%27%5D%0A%09%09ifFalse%3A%20%5BaString%5D'),
  11954. messageSends: ["ifTrue:ifFalse:", "includes:", "reservedWords", "current", unescape("%2C")],
  11955. referencedClasses: ["Smalltalk"]
  11956. }),
  11957. smalltalk.Compiler);
  11958. smalltalk.Compiler.klass.iVarNames = ['performOptimizations'];
  11959. smalltalk.addMethod(
  11960. unescape('_recompile_'),
  11961. smalltalk.method({
  11962. selector: unescape('recompile%3A'),
  11963. category: 'compiling',
  11964. fn: function (aClass){
  11965. var self=this;
  11966. smalltalk.send(smalltalk.send(aClass, "_methodDictionary", []), "_do_", [(function(each){var method=nil;
  11967. method=smalltalk.send(smalltalk.send(self, "_new", []), "_load_forClass_", [smalltalk.send(each, "_source", []), aClass]);smalltalk.send(method, "_category_", [smalltalk.send(each, "_category", [])]);return smalltalk.send(aClass, "_addCompiledMethod_", [method]);})]);
  11968. ((($receiver = smalltalk.send(aClass, "_isMetaclass", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_recompile_", [smalltalk.send(aClass, "_class", [])]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(self, "_recompile_", [smalltalk.send(aClass, "_class", [])]);})]));
  11969. return self;},
  11970. args: ["aClass"],
  11971. source: unescape('recompile%3A%20aClass%0A%09aClass%20methodDictionary%20do%3A%20%5B%3Aeach%20%7C%7C%20method%20%7C%0A%09%09method%20%3A%3D%20self%20new%20load%3A%20each%20source%20forClass%3A%20aClass.%0A%09%09method%20category%3A%20each%20category.%0A%09%09aClass%20addCompiledMethod%3A%20method%5D.%0A%09aClass%20isMetaclass%20ifFalse%3A%20%5Bself%20recompile%3A%20aClass%20class%5D'),
  11972. messageSends: ["do:", "methodDictionary", "load:forClass:", "new", "source", "category:", "category", "addCompiledMethod:", "ifFalse:", "isMetaclass", "recompile:", "class"],
  11973. referencedClasses: []
  11974. }),
  11975. smalltalk.Compiler.klass);
  11976. smalltalk.addMethod(
  11977. unescape('_recompileAll'),
  11978. smalltalk.method({
  11979. selector: unescape('recompileAll'),
  11980. category: 'compiling',
  11981. fn: function (){
  11982. var self=this;
  11983. smalltalk.send(smalltalk.send(smalltalk.send((smalltalk.Smalltalk || Smalltalk), "_current", []), "_classes", []), "_do_", [(function(each){return smalltalk.send(self, "_recompile_", [each]);})]);
  11984. return self;},
  11985. args: [],
  11986. source: unescape('recompileAll%0A%09Smalltalk%20current%20classes%20do%3A%20%5B%3Aeach%20%7C%0A%09%09self%20recompile%3A%20each%5D'),
  11987. messageSends: ["do:", "classes", "current", "recompile:"],
  11988. referencedClasses: ["Smalltalk"]
  11989. }),
  11990. smalltalk.Compiler.klass);
  11991. smalltalk.addMethod(
  11992. unescape('_performOptimizations'),
  11993. smalltalk.method({
  11994. selector: unescape('performOptimizations'),
  11995. category: 'accessing',
  11996. fn: function (){
  11997. var self=this;
  11998. return (($receiver = self['@performOptimizations']) == nil || $receiver == undefined) ? (function(){return true;})() : $receiver;
  11999. return self;},
  12000. args: [],
  12001. source: unescape('performOptimizations%0A%09%5EperformOptimizations%20ifNil%3A%20%5Btrue%5D'),
  12002. messageSends: ["ifNil:"],
  12003. referencedClasses: []
  12004. }),
  12005. smalltalk.Compiler.klass);
  12006. smalltalk.addMethod(
  12007. unescape('_performOptimizations_'),
  12008. smalltalk.method({
  12009. selector: unescape('performOptimizations%3A'),
  12010. category: 'accessing',
  12011. fn: function (aBoolean){
  12012. var self=this;
  12013. self['@performOptimizations']=aBoolean;
  12014. return self;},
  12015. args: ["aBoolean"],
  12016. source: unescape('performOptimizations%3A%20aBoolean%0A%09performOptimizations%20%3A%3D%20aBoolean'),
  12017. messageSends: [],
  12018. referencedClasses: []
  12019. }),
  12020. smalltalk.Compiler.klass);
  12021. smalltalk.addClass('DoIt', smalltalk.Object, [], 'Compiler');
  12022. smalltalk.addClass('DynamicArrayNode', smalltalk.Node, [], 'Compiler');
  12023. smalltalk.addMethod(
  12024. unescape('_accept_'),
  12025. smalltalk.method({
  12026. selector: unescape('accept%3A'),
  12027. category: 'visiting',
  12028. fn: function (aVisitor){
  12029. var self=this;
  12030. smalltalk.send(aVisitor, "_visitDynamicArrayNode_", [self]);
  12031. return self;},
  12032. args: ["aVisitor"],
  12033. source: unescape('accept%3A%20aVisitor%0A%09aVisitor%20visitDynamicArrayNode%3A%20self'),
  12034. messageSends: ["visitDynamicArrayNode:"],
  12035. referencedClasses: []
  12036. }),
  12037. smalltalk.DynamicArrayNode);
  12038. smalltalk.addClass('DynamicDictionaryNode', smalltalk.Node, [], 'Compiler');
  12039. smalltalk.addMethod(
  12040. unescape('_accept_'),
  12041. smalltalk.method({
  12042. selector: unescape('accept%3A'),
  12043. category: 'visiting',
  12044. fn: function (aVisitor){
  12045. var self=this;
  12046. smalltalk.send(aVisitor, "_visitDynamicDictionaryNode_", [self]);
  12047. return self;},
  12048. args: ["aVisitor"],
  12049. source: unescape('accept%3A%20aVisitor%0A%09aVisitor%20visitDynamicDictionaryNode%3A%20self'),
  12050. messageSends: ["visitDynamicDictionaryNode:"],
  12051. referencedClasses: []
  12052. }),
  12053. smalltalk.DynamicDictionaryNode);
  12054. smalltalk.parser = (function(){
  12055. /* Generated by PEG.js 0.6.2 (http://pegjs.majda.cz/). */
  12056. var result = {
  12057. /*
  12058. * Parses the input with a generated parser. If the parsing is successfull,
  12059. * returns a value explicitly or implicitly specified by the grammar from
  12060. * which the parser was generated (see |PEG.buildParser|). If the parsing is
  12061. * unsuccessful, throws |PEG.parser.SyntaxError| describing the error.
  12062. */
  12063. parse: function(input, startRule) {
  12064. var parseFunctions = {
  12065. "assignment": parse_assignment,
  12066. "binaryMessage": parse_binaryMessage,
  12067. "binaryPattern": parse_binaryPattern,
  12068. "binarySelector": parse_binarySelector,
  12069. "binarySend": parse_binarySend,
  12070. "binaryTail": parse_binaryTail,
  12071. "block": parse_block,
  12072. "blockParamList": parse_blockParamList,
  12073. "cascade": parse_cascade,
  12074. "className": parse_className,
  12075. "classReference": parse_classReference,
  12076. "comments": parse_comments,
  12077. "dynamicArray": parse_dynamicArray,
  12078. "dynamicDictionary": parse_dynamicDictionary,
  12079. "expression": parse_expression,
  12080. "expressionList": parse_expressionList,
  12081. "expressions": parse_expressions,
  12082. "float": parse_float,
  12083. "identifier": parse_identifier,
  12084. "integer": parse_integer,
  12085. "jsStatement": parse_jsStatement,
  12086. "keyword": parse_keyword,
  12087. "keywordMessage": parse_keywordMessage,
  12088. "keywordPair": parse_keywordPair,
  12089. "keywordPattern": parse_keywordPattern,
  12090. "keywordSend": parse_keywordSend,
  12091. "literal": parse_literal,
  12092. "literalArray": parse_literalArray,
  12093. "message": parse_message,
  12094. "method": parse_method,
  12095. "number": parse_number,
  12096. "operand": parse_operand,
  12097. "pseudoVariable": parse_pseudoVariable,
  12098. "reference": parse_reference,
  12099. "ret": parse_ret,
  12100. "separator": parse_separator,
  12101. "sequence": parse_sequence,
  12102. "statements": parse_statements,
  12103. "string": parse_string,
  12104. "subexpression": parse_subexpression,
  12105. "symbol": parse_symbol,
  12106. "temps": parse_temps,
  12107. "unaryMessage": parse_unaryMessage,
  12108. "unaryPattern": parse_unaryPattern,
  12109. "unarySend": parse_unarySend,
  12110. "unaryTail": parse_unaryTail,
  12111. "variable": parse_variable,
  12112. "ws": parse_ws
  12113. };
  12114. if (startRule !== undefined) {
  12115. if (parseFunctions[startRule] === undefined) {
  12116. throw new Error("Invalid rule name: " + quote(startRule) + ".");
  12117. }
  12118. } else {
  12119. startRule = "method";
  12120. }
  12121. var pos = 0;
  12122. var reportMatchFailures = true;
  12123. var rightmostMatchFailuresPos = 0;
  12124. var rightmostMatchFailuresExpected = [];
  12125. var cache = {};
  12126. function padLeft(input, padding, length) {
  12127. var result = input;
  12128. var padLength = length - input.length;
  12129. for (var i = 0; i < padLength; i++) {
  12130. result = padding + result;
  12131. }
  12132. return result;
  12133. }
  12134. function escape(ch) {
  12135. var charCode = ch.charCodeAt(0);
  12136. if (charCode <= 0xFF) {
  12137. var escapeChar = 'x';
  12138. var length = 2;
  12139. } else {
  12140. var escapeChar = 'u';
  12141. var length = 4;
  12142. }
  12143. return '\\' + escapeChar + padLeft(charCode.toString(16).toUpperCase(), '0', length);
  12144. }
  12145. function quote(s) {
  12146. /*
  12147. * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a
  12148. * string literal except for the closing quote character, backslash,
  12149. * carriage return, line separator, paragraph separator, and line feed.
  12150. * Any character may appear in the form of an escape sequence.
  12151. */
  12152. return '"' + s
  12153. .replace(/\\/g, '\\\\') // backslash
  12154. .replace(/"/g, '\\"') // closing quote character
  12155. .replace(/\r/g, '\\r') // carriage return
  12156. .replace(/\n/g, '\\n') // line feed
  12157. .replace(/[\x80-\uFFFF]/g, escape) // non-ASCII characters
  12158. + '"';
  12159. }
  12160. function matchFailed(failure) {
  12161. if (pos < rightmostMatchFailuresPos) {
  12162. return;
  12163. }
  12164. if (pos > rightmostMatchFailuresPos) {
  12165. rightmostMatchFailuresPos = pos;
  12166. rightmostMatchFailuresExpected = [];
  12167. }
  12168. rightmostMatchFailuresExpected.push(failure);
  12169. }
  12170. function parse_separator() {
  12171. var cacheKey = 'separator@' + pos;
  12172. var cachedResult = cache[cacheKey];
  12173. if (cachedResult) {
  12174. pos = cachedResult.nextPos;
  12175. return cachedResult.result;
  12176. }
  12177. if (input.substr(pos).match(/^[ \xA0\uFEFF\n\r\u2028\u2029]/) !== null) {
  12178. var result1 = input.charAt(pos);
  12179. pos++;
  12180. } else {
  12181. var result1 = null;
  12182. if (reportMatchFailures) {
  12183. matchFailed("[ \\xA0\\uFEFF\\n\\r\\u2028\\u2029]");
  12184. }
  12185. }
  12186. if (result1 !== null) {
  12187. var result0 = [];
  12188. while (result1 !== null) {
  12189. result0.push(result1);
  12190. if (input.substr(pos).match(/^[ \xA0\uFEFF\n\r\u2028\u2029]/) !== null) {
  12191. var result1 = input.charAt(pos);
  12192. pos++;
  12193. } else {
  12194. var result1 = null;
  12195. if (reportMatchFailures) {
  12196. matchFailed("[ \\xA0\\uFEFF\\n\\r\\u2028\\u2029]");
  12197. }
  12198. }
  12199. }
  12200. } else {
  12201. var result0 = null;
  12202. }
  12203. cache[cacheKey] = {
  12204. nextPos: pos,
  12205. result: result0
  12206. };
  12207. return result0;
  12208. }
  12209. function parse_comments() {
  12210. var cacheKey = 'comments@' + pos;
  12211. var cachedResult = cache[cacheKey];
  12212. if (cachedResult) {
  12213. pos = cachedResult.nextPos;
  12214. return cachedResult.result;
  12215. }
  12216. var savedPos0 = pos;
  12217. if (input.substr(pos).match(/^["]/) !== null) {
  12218. var result2 = input.charAt(pos);
  12219. pos++;
  12220. } else {
  12221. var result2 = null;
  12222. if (reportMatchFailures) {
  12223. matchFailed("[\"]");
  12224. }
  12225. }
  12226. if (result2 !== null) {
  12227. var result3 = [];
  12228. if (input.substr(pos).match(/^[^"]/) !== null) {
  12229. var result5 = input.charAt(pos);
  12230. pos++;
  12231. } else {
  12232. var result5 = null;
  12233. if (reportMatchFailures) {
  12234. matchFailed("[^\"]");
  12235. }
  12236. }
  12237. while (result5 !== null) {
  12238. result3.push(result5);
  12239. if (input.substr(pos).match(/^[^"]/) !== null) {
  12240. var result5 = input.charAt(pos);
  12241. pos++;
  12242. } else {
  12243. var result5 = null;
  12244. if (reportMatchFailures) {
  12245. matchFailed("[^\"]");
  12246. }
  12247. }
  12248. }
  12249. if (result3 !== null) {
  12250. if (input.substr(pos).match(/^["]/) !== null) {
  12251. var result4 = input.charAt(pos);
  12252. pos++;
  12253. } else {
  12254. var result4 = null;
  12255. if (reportMatchFailures) {
  12256. matchFailed("[\"]");
  12257. }
  12258. }
  12259. if (result4 !== null) {
  12260. var result1 = [result2, result3, result4];
  12261. } else {
  12262. var result1 = null;
  12263. pos = savedPos0;
  12264. }
  12265. } else {
  12266. var result1 = null;
  12267. pos = savedPos0;
  12268. }
  12269. } else {
  12270. var result1 = null;
  12271. pos = savedPos0;
  12272. }
  12273. if (result1 !== null) {
  12274. var result0 = [];
  12275. while (result1 !== null) {
  12276. result0.push(result1);
  12277. var savedPos0 = pos;
  12278. if (input.substr(pos).match(/^["]/) !== null) {
  12279. var result2 = input.charAt(pos);
  12280. pos++;
  12281. } else {
  12282. var result2 = null;
  12283. if (reportMatchFailures) {
  12284. matchFailed("[\"]");
  12285. }
  12286. }
  12287. if (result2 !== null) {
  12288. var result3 = [];
  12289. if (input.substr(pos).match(/^[^"]/) !== null) {
  12290. var result5 = input.charAt(pos);
  12291. pos++;
  12292. } else {
  12293. var result5 = null;
  12294. if (reportMatchFailures) {
  12295. matchFailed("[^\"]");
  12296. }
  12297. }
  12298. while (result5 !== null) {
  12299. result3.push(result5);
  12300. if (input.substr(pos).match(/^[^"]/) !== null) {
  12301. var result5 = input.charAt(pos);
  12302. pos++;
  12303. } else {
  12304. var result5 = null;
  12305. if (reportMatchFailures) {
  12306. matchFailed("[^\"]");
  12307. }
  12308. }
  12309. }
  12310. if (result3 !== null) {
  12311. if (input.substr(pos).match(/^["]/) !== null) {
  12312. var result4 = input.charAt(pos);
  12313. pos++;
  12314. } else {
  12315. var result4 = null;
  12316. if (reportMatchFailures) {
  12317. matchFailed("[\"]");
  12318. }
  12319. }
  12320. if (result4 !== null) {
  12321. var result1 = [result2, result3, result4];
  12322. } else {
  12323. var result1 = null;
  12324. pos = savedPos0;
  12325. }
  12326. } else {
  12327. var result1 = null;
  12328. pos = savedPos0;
  12329. }
  12330. } else {
  12331. var result1 = null;
  12332. pos = savedPos0;
  12333. }
  12334. }
  12335. } else {
  12336. var result0 = null;
  12337. }
  12338. cache[cacheKey] = {
  12339. nextPos: pos,
  12340. result: result0
  12341. };
  12342. return result0;
  12343. }
  12344. function parse_ws() {
  12345. var cacheKey = 'ws@' + pos;
  12346. var cachedResult = cache[cacheKey];
  12347. if (cachedResult) {
  12348. pos = cachedResult.nextPos;
  12349. return cachedResult.result;
  12350. }
  12351. var result0 = [];
  12352. var result3 = parse_separator();
  12353. if (result3 !== null) {
  12354. var result1 = result3;
  12355. } else {
  12356. var result2 = parse_comments();
  12357. if (result2 !== null) {
  12358. var result1 = result2;
  12359. } else {
  12360. var result1 = null;;
  12361. };
  12362. }
  12363. while (result1 !== null) {
  12364. result0.push(result1);
  12365. var result3 = parse_separator();
  12366. if (result3 !== null) {
  12367. var result1 = result3;
  12368. } else {
  12369. var result2 = parse_comments();
  12370. if (result2 !== null) {
  12371. var result1 = result2;
  12372. } else {
  12373. var result1 = null;;
  12374. };
  12375. }
  12376. }
  12377. cache[cacheKey] = {
  12378. nextPos: pos,
  12379. result: result0
  12380. };
  12381. return result0;
  12382. }
  12383. function parse_identifier() {
  12384. var cacheKey = 'identifier@' + pos;
  12385. var cachedResult = cache[cacheKey];
  12386. if (cachedResult) {
  12387. pos = cachedResult.nextPos;
  12388. return cachedResult.result;
  12389. }
  12390. var savedPos0 = pos;
  12391. var savedPos1 = pos;
  12392. if (input.substr(pos).match(/^[a-z]/) !== null) {
  12393. var result3 = input.charAt(pos);
  12394. pos++;
  12395. } else {
  12396. var result3 = null;
  12397. if (reportMatchFailures) {
  12398. matchFailed("[a-z]");
  12399. }
  12400. }
  12401. if (result3 !== null) {
  12402. var result4 = [];
  12403. if (input.substr(pos).match(/^[a-zA-Z0-9]/) !== null) {
  12404. var result5 = input.charAt(pos);
  12405. pos++;
  12406. } else {
  12407. var result5 = null;
  12408. if (reportMatchFailures) {
  12409. matchFailed("[a-zA-Z0-9]");
  12410. }
  12411. }
  12412. while (result5 !== null) {
  12413. result4.push(result5);
  12414. if (input.substr(pos).match(/^[a-zA-Z0-9]/) !== null) {
  12415. var result5 = input.charAt(pos);
  12416. pos++;
  12417. } else {
  12418. var result5 = null;
  12419. if (reportMatchFailures) {
  12420. matchFailed("[a-zA-Z0-9]");
  12421. }
  12422. }
  12423. }
  12424. if (result4 !== null) {
  12425. var result1 = [result3, result4];
  12426. } else {
  12427. var result1 = null;
  12428. pos = savedPos1;
  12429. }
  12430. } else {
  12431. var result1 = null;
  12432. pos = savedPos1;
  12433. }
  12434. var result2 = result1 !== null
  12435. ? (function(first, others) {return first + others.join("")})(result1[0], result1[1])
  12436. : null;
  12437. if (result2 !== null) {
  12438. var result0 = result2;
  12439. } else {
  12440. var result0 = null;
  12441. pos = savedPos0;
  12442. }
  12443. cache[cacheKey] = {
  12444. nextPos: pos,
  12445. result: result0
  12446. };
  12447. return result0;
  12448. }
  12449. function parse_keyword() {
  12450. var cacheKey = 'keyword@' + pos;
  12451. var cachedResult = cache[cacheKey];
  12452. if (cachedResult) {
  12453. pos = cachedResult.nextPos;
  12454. return cachedResult.result;
  12455. }
  12456. var savedPos0 = pos;
  12457. var savedPos1 = pos;
  12458. var result3 = parse_identifier();
  12459. if (result3 !== null) {
  12460. if (input.substr(pos).match(/^[:]/) !== null) {
  12461. var result4 = input.charAt(pos);
  12462. pos++;
  12463. } else {
  12464. var result4 = null;
  12465. if (reportMatchFailures) {
  12466. matchFailed("[:]");
  12467. }
  12468. }
  12469. if (result4 !== null) {
  12470. var result1 = [result3, result4];
  12471. } else {
  12472. var result1 = null;
  12473. pos = savedPos1;
  12474. }
  12475. } else {
  12476. var result1 = null;
  12477. pos = savedPos1;
  12478. }
  12479. var result2 = result1 !== null
  12480. ? (function(first, last) {return first + last})(result1[0], result1[1])
  12481. : null;
  12482. if (result2 !== null) {
  12483. var result0 = result2;
  12484. } else {
  12485. var result0 = null;
  12486. pos = savedPos0;
  12487. }
  12488. cache[cacheKey] = {
  12489. nextPos: pos,
  12490. result: result0
  12491. };
  12492. return result0;
  12493. }
  12494. function parse_className() {
  12495. var cacheKey = 'className@' + pos;
  12496. var cachedResult = cache[cacheKey];
  12497. if (cachedResult) {
  12498. pos = cachedResult.nextPos;
  12499. return cachedResult.result;
  12500. }
  12501. var savedPos0 = pos;
  12502. var savedPos1 = pos;
  12503. if (input.substr(pos).match(/^[A-Z]/) !== null) {
  12504. var result3 = input.charAt(pos);
  12505. pos++;
  12506. } else {
  12507. var result3 = null;
  12508. if (reportMatchFailures) {
  12509. matchFailed("[A-Z]");
  12510. }
  12511. }
  12512. if (result3 !== null) {
  12513. var result4 = [];
  12514. if (input.substr(pos).match(/^[a-zA-Z0-9]/) !== null) {
  12515. var result5 = input.charAt(pos);
  12516. pos++;
  12517. } else {
  12518. var result5 = null;
  12519. if (reportMatchFailures) {
  12520. matchFailed("[a-zA-Z0-9]");
  12521. }
  12522. }
  12523. while (result5 !== null) {
  12524. result4.push(result5);
  12525. if (input.substr(pos).match(/^[a-zA-Z0-9]/) !== null) {
  12526. var result5 = input.charAt(pos);
  12527. pos++;
  12528. } else {
  12529. var result5 = null;
  12530. if (reportMatchFailures) {
  12531. matchFailed("[a-zA-Z0-9]");
  12532. }
  12533. }
  12534. }
  12535. if (result4 !== null) {
  12536. var result1 = [result3, result4];
  12537. } else {
  12538. var result1 = null;
  12539. pos = savedPos1;
  12540. }
  12541. } else {
  12542. var result1 = null;
  12543. pos = savedPos1;
  12544. }
  12545. var result2 = result1 !== null
  12546. ? (function(first, others) {return first + others.join("")})(result1[0], result1[1])
  12547. : null;
  12548. if (result2 !== null) {
  12549. var result0 = result2;
  12550. } else {
  12551. var result0 = null;
  12552. pos = savedPos0;
  12553. }
  12554. cache[cacheKey] = {
  12555. nextPos: pos,
  12556. result: result0
  12557. };
  12558. return result0;
  12559. }
  12560. function parse_string() {
  12561. var cacheKey = 'string@' + pos;
  12562. var cachedResult = cache[cacheKey];
  12563. if (cachedResult) {
  12564. pos = cachedResult.nextPos;
  12565. return cachedResult.result;
  12566. }
  12567. var savedPos0 = pos;
  12568. var savedPos1 = pos;
  12569. if (input.substr(pos).match(/^[']/) !== null) {
  12570. var result3 = input.charAt(pos);
  12571. pos++;
  12572. } else {
  12573. var result3 = null;
  12574. if (reportMatchFailures) {
  12575. matchFailed("[']");
  12576. }
  12577. }
  12578. if (result3 !== null) {
  12579. var result4 = [];
  12580. var savedPos2 = pos;
  12581. if (input.substr(pos, 2) === "''") {
  12582. var result9 = "''";
  12583. pos += 2;
  12584. } else {
  12585. var result9 = null;
  12586. if (reportMatchFailures) {
  12587. matchFailed("\"''\"");
  12588. }
  12589. }
  12590. var result10 = result9 !== null
  12591. ? (function() {return "'"})()
  12592. : null;
  12593. if (result10 !== null) {
  12594. var result8 = result10;
  12595. } else {
  12596. var result8 = null;
  12597. pos = savedPos2;
  12598. }
  12599. if (result8 !== null) {
  12600. var result6 = result8;
  12601. } else {
  12602. if (input.substr(pos).match(/^[^']/) !== null) {
  12603. var result7 = input.charAt(pos);
  12604. pos++;
  12605. } else {
  12606. var result7 = null;
  12607. if (reportMatchFailures) {
  12608. matchFailed("[^']");
  12609. }
  12610. }
  12611. if (result7 !== null) {
  12612. var result6 = result7;
  12613. } else {
  12614. var result6 = null;;
  12615. };
  12616. }
  12617. while (result6 !== null) {
  12618. result4.push(result6);
  12619. var savedPos2 = pos;
  12620. if (input.substr(pos, 2) === "''") {
  12621. var result9 = "''";
  12622. pos += 2;
  12623. } else {
  12624. var result9 = null;
  12625. if (reportMatchFailures) {
  12626. matchFailed("\"''\"");
  12627. }
  12628. }
  12629. var result10 = result9 !== null
  12630. ? (function() {return "'"})()
  12631. : null;
  12632. if (result10 !== null) {
  12633. var result8 = result10;
  12634. } else {
  12635. var result8 = null;
  12636. pos = savedPos2;
  12637. }
  12638. if (result8 !== null) {
  12639. var result6 = result8;
  12640. } else {
  12641. if (input.substr(pos).match(/^[^']/) !== null) {
  12642. var result7 = input.charAt(pos);
  12643. pos++;
  12644. } else {
  12645. var result7 = null;
  12646. if (reportMatchFailures) {
  12647. matchFailed("[^']");
  12648. }
  12649. }
  12650. if (result7 !== null) {
  12651. var result6 = result7;
  12652. } else {
  12653. var result6 = null;;
  12654. };
  12655. }
  12656. }
  12657. if (result4 !== null) {
  12658. if (input.substr(pos).match(/^[']/) !== null) {
  12659. var result5 = input.charAt(pos);
  12660. pos++;
  12661. } else {
  12662. var result5 = null;
  12663. if (reportMatchFailures) {
  12664. matchFailed("[']");
  12665. }
  12666. }
  12667. if (result5 !== null) {
  12668. var result1 = [result3, result4, result5];
  12669. } else {
  12670. var result1 = null;
  12671. pos = savedPos1;
  12672. }
  12673. } else {
  12674. var result1 = null;
  12675. pos = savedPos1;
  12676. }
  12677. } else {
  12678. var result1 = null;
  12679. pos = savedPos1;
  12680. }
  12681. var result2 = result1 !== null
  12682. ? (function(val) {
  12683. return smalltalk.ValueNode._new()
  12684. ._value_(val.join("").replace(/\"/ig, '"'))
  12685. })(result1[1])
  12686. : null;
  12687. if (result2 !== null) {
  12688. var result0 = result2;
  12689. } else {
  12690. var result0 = null;
  12691. pos = savedPos0;
  12692. }
  12693. cache[cacheKey] = {
  12694. nextPos: pos,
  12695. result: result0
  12696. };
  12697. return result0;
  12698. }
  12699. function parse_symbol() {
  12700. var cacheKey = 'symbol@' + pos;
  12701. var cachedResult = cache[cacheKey];
  12702. if (cachedResult) {
  12703. pos = cachedResult.nextPos;
  12704. return cachedResult.result;
  12705. }
  12706. var savedPos0 = pos;
  12707. var savedPos1 = pos;
  12708. if (input.substr(pos, 1) === "#") {
  12709. var result3 = "#";
  12710. pos += 1;
  12711. } else {
  12712. var result3 = null;
  12713. if (reportMatchFailures) {
  12714. matchFailed("\"#\"");
  12715. }
  12716. }
  12717. if (result3 !== null) {
  12718. var result4 = [];
  12719. if (input.substr(pos).match(/^[a-zA-Z0-9]/) !== null) {
  12720. var result5 = input.charAt(pos);
  12721. pos++;
  12722. } else {
  12723. var result5 = null;
  12724. if (reportMatchFailures) {
  12725. matchFailed("[a-zA-Z0-9]");
  12726. }
  12727. }
  12728. while (result5 !== null) {
  12729. result4.push(result5);
  12730. if (input.substr(pos).match(/^[a-zA-Z0-9]/) !== null) {
  12731. var result5 = input.charAt(pos);
  12732. pos++;
  12733. } else {
  12734. var result5 = null;
  12735. if (reportMatchFailures) {
  12736. matchFailed("[a-zA-Z0-9]");
  12737. }
  12738. }
  12739. }
  12740. if (result4 !== null) {
  12741. var result1 = [result3, result4];
  12742. } else {
  12743. var result1 = null;
  12744. pos = savedPos1;
  12745. }
  12746. } else {
  12747. var result1 = null;
  12748. pos = savedPos1;
  12749. }
  12750. var result2 = result1 !== null
  12751. ? (function(val) {
  12752. return smalltalk.ValueNode._new()
  12753. ._value_(val.join("").replace(/\"/ig, '"'))
  12754. })(result1[1])
  12755. : null;
  12756. if (result2 !== null) {
  12757. var result0 = result2;
  12758. } else {
  12759. var result0 = null;
  12760. pos = savedPos0;
  12761. }
  12762. cache[cacheKey] = {
  12763. nextPos: pos,
  12764. result: result0
  12765. };
  12766. return result0;
  12767. }
  12768. function parse_number() {
  12769. var cacheKey = 'number@' + pos;
  12770. var cachedResult = cache[cacheKey];
  12771. if (cachedResult) {
  12772. pos = cachedResult.nextPos;
  12773. return cachedResult.result;
  12774. }
  12775. var savedPos0 = pos;
  12776. var result4 = parse_float();
  12777. if (result4 !== null) {
  12778. var result1 = result4;
  12779. } else {
  12780. var result3 = parse_integer();
  12781. if (result3 !== null) {
  12782. var result1 = result3;
  12783. } else {
  12784. var result1 = null;;
  12785. };
  12786. }
  12787. var result2 = result1 !== null
  12788. ? (function(n) {
  12789. return smalltalk.ValueNode._new()
  12790. ._value_(n)
  12791. })(result1)
  12792. : null;
  12793. if (result2 !== null) {
  12794. var result0 = result2;
  12795. } else {
  12796. var result0 = null;
  12797. pos = savedPos0;
  12798. }
  12799. cache[cacheKey] = {
  12800. nextPos: pos,
  12801. result: result0
  12802. };
  12803. return result0;
  12804. }
  12805. function parse_float() {
  12806. var cacheKey = 'float@' + pos;
  12807. var cachedResult = cache[cacheKey];
  12808. if (cachedResult) {
  12809. pos = cachedResult.nextPos;
  12810. return cachedResult.result;
  12811. }
  12812. var savedPos0 = pos;
  12813. var savedPos1 = pos;
  12814. if (input.substr(pos).match(/^[\-]/) !== null) {
  12815. var result7 = input.charAt(pos);
  12816. pos++;
  12817. } else {
  12818. var result7 = null;
  12819. if (reportMatchFailures) {
  12820. matchFailed("[\\-]");
  12821. }
  12822. }
  12823. var result3 = result7 !== null ? result7 : '';
  12824. if (result3 !== null) {
  12825. var result4 = parse_integer();
  12826. if (result4 !== null) {
  12827. if (input.substr(pos, 1) === ".") {
  12828. var result5 = ".";
  12829. pos += 1;
  12830. } else {
  12831. var result5 = null;
  12832. if (reportMatchFailures) {
  12833. matchFailed("\".\"");
  12834. }
  12835. }
  12836. if (result5 !== null) {
  12837. var result6 = parse_integer();
  12838. if (result6 !== null) {
  12839. var result1 = [result3, result4, result5, result6];
  12840. } else {
  12841. var result1 = null;
  12842. pos = savedPos1;
  12843. }
  12844. } else {
  12845. var result1 = null;
  12846. pos = savedPos1;
  12847. }
  12848. } else {
  12849. var result1 = null;
  12850. pos = savedPos1;
  12851. }
  12852. } else {
  12853. var result1 = null;
  12854. pos = savedPos1;
  12855. }
  12856. var result2 = result1 !== null
  12857. ? (function(neg, int, dec) {return parseFloat((neg+int+"."+dec), 10)})(result1[0], result1[1], result1[3])
  12858. : null;
  12859. if (result2 !== null) {
  12860. var result0 = result2;
  12861. } else {
  12862. var result0 = null;
  12863. pos = savedPos0;
  12864. }
  12865. cache[cacheKey] = {
  12866. nextPos: pos,
  12867. result: result0
  12868. };
  12869. return result0;
  12870. }
  12871. function parse_integer() {
  12872. var cacheKey = 'integer@' + pos;
  12873. var cachedResult = cache[cacheKey];
  12874. if (cachedResult) {
  12875. pos = cachedResult.nextPos;
  12876. return cachedResult.result;
  12877. }
  12878. var savedPos0 = pos;
  12879. var savedPos1 = pos;
  12880. if (input.substr(pos).match(/^[\-]/) !== null) {
  12881. var result6 = input.charAt(pos);
  12882. pos++;
  12883. } else {
  12884. var result6 = null;
  12885. if (reportMatchFailures) {
  12886. matchFailed("[\\-]");
  12887. }
  12888. }
  12889. var result3 = result6 !== null ? result6 : '';
  12890. if (result3 !== null) {
  12891. if (input.substr(pos).match(/^[0-9]/) !== null) {
  12892. var result5 = input.charAt(pos);
  12893. pos++;
  12894. } else {
  12895. var result5 = null;
  12896. if (reportMatchFailures) {
  12897. matchFailed("[0-9]");
  12898. }
  12899. }
  12900. if (result5 !== null) {
  12901. var result4 = [];
  12902. while (result5 !== null) {
  12903. result4.push(result5);
  12904. if (input.substr(pos).match(/^[0-9]/) !== null) {
  12905. var result5 = input.charAt(pos);
  12906. pos++;
  12907. } else {
  12908. var result5 = null;
  12909. if (reportMatchFailures) {
  12910. matchFailed("[0-9]");
  12911. }
  12912. }
  12913. }
  12914. } else {
  12915. var result4 = null;
  12916. }
  12917. if (result4 !== null) {
  12918. var result1 = [result3, result4];
  12919. } else {
  12920. var result1 = null;
  12921. pos = savedPos1;
  12922. }
  12923. } else {
  12924. var result1 = null;
  12925. pos = savedPos1;
  12926. }
  12927. var result2 = result1 !== null
  12928. ? (function(neg, digits) {return (parseInt(neg+digits.join(""), 10))})(result1[0], result1[1])
  12929. : null;
  12930. if (result2 !== null) {
  12931. var result0 = result2;
  12932. } else {
  12933. var result0 = null;
  12934. pos = savedPos0;
  12935. }
  12936. cache[cacheKey] = {
  12937. nextPos: pos,
  12938. result: result0
  12939. };
  12940. return result0;
  12941. }
  12942. function parse_literalArray() {
  12943. var cacheKey = 'literalArray@' + pos;
  12944. var cachedResult = cache[cacheKey];
  12945. if (cachedResult) {
  12946. pos = cachedResult.nextPos;
  12947. return cachedResult.result;
  12948. }
  12949. var savedPos0 = pos;
  12950. var savedPos1 = pos;
  12951. if (input.substr(pos, 2) === "#(") {
  12952. var result3 = "#(";
  12953. pos += 2;
  12954. } else {
  12955. var result3 = null;
  12956. if (reportMatchFailures) {
  12957. matchFailed("\"#(\"");
  12958. }
  12959. }
  12960. if (result3 !== null) {
  12961. var result4 = parse_ws();
  12962. if (result4 !== null) {
  12963. var result5 = [];
  12964. var savedPos2 = pos;
  12965. var savedPos3 = pos;
  12966. var result11 = parse_literal();
  12967. if (result11 !== null) {
  12968. var result12 = parse_ws();
  12969. if (result12 !== null) {
  12970. var result9 = [result11, result12];
  12971. } else {
  12972. var result9 = null;
  12973. pos = savedPos3;
  12974. }
  12975. } else {
  12976. var result9 = null;
  12977. pos = savedPos3;
  12978. }
  12979. var result10 = result9 !== null
  12980. ? (function(lit) {return lit._value()})(result9[0])
  12981. : null;
  12982. if (result10 !== null) {
  12983. var result8 = result10;
  12984. } else {
  12985. var result8 = null;
  12986. pos = savedPos2;
  12987. }
  12988. while (result8 !== null) {
  12989. result5.push(result8);
  12990. var savedPos2 = pos;
  12991. var savedPos3 = pos;
  12992. var result11 = parse_literal();
  12993. if (result11 !== null) {
  12994. var result12 = parse_ws();
  12995. if (result12 !== null) {
  12996. var result9 = [result11, result12];
  12997. } else {
  12998. var result9 = null;
  12999. pos = savedPos3;
  13000. }
  13001. } else {
  13002. var result9 = null;
  13003. pos = savedPos3;
  13004. }
  13005. var result10 = result9 !== null
  13006. ? (function(lit) {return lit._value()})(result9[0])
  13007. : null;
  13008. if (result10 !== null) {
  13009. var result8 = result10;
  13010. } else {
  13011. var result8 = null;
  13012. pos = savedPos2;
  13013. }
  13014. }
  13015. if (result5 !== null) {
  13016. var result6 = parse_ws();
  13017. if (result6 !== null) {
  13018. if (input.substr(pos, 1) === ")") {
  13019. var result7 = ")";
  13020. pos += 1;
  13021. } else {
  13022. var result7 = null;
  13023. if (reportMatchFailures) {
  13024. matchFailed("\")\"");
  13025. }
  13026. }
  13027. if (result7 !== null) {
  13028. var result1 = [result3, result4, result5, result6, result7];
  13029. } else {
  13030. var result1 = null;
  13031. pos = savedPos1;
  13032. }
  13033. } else {
  13034. var result1 = null;
  13035. pos = savedPos1;
  13036. }
  13037. } else {
  13038. var result1 = null;
  13039. pos = savedPos1;
  13040. }
  13041. } else {
  13042. var result1 = null;
  13043. pos = savedPos1;
  13044. }
  13045. } else {
  13046. var result1 = null;
  13047. pos = savedPos1;
  13048. }
  13049. var result2 = result1 !== null
  13050. ? (function(lits) {
  13051. return smalltalk.ValueNode._new()
  13052. ._value_(lits)
  13053. })(result1[2])
  13054. : null;
  13055. if (result2 !== null) {
  13056. var result0 = result2;
  13057. } else {
  13058. var result0 = null;
  13059. pos = savedPos0;
  13060. }
  13061. cache[cacheKey] = {
  13062. nextPos: pos,
  13063. result: result0
  13064. };
  13065. return result0;
  13066. }
  13067. function parse_dynamicArray() {
  13068. var cacheKey = 'dynamicArray@' + pos;
  13069. var cachedResult = cache[cacheKey];
  13070. if (cachedResult) {
  13071. pos = cachedResult.nextPos;
  13072. return cachedResult.result;
  13073. }
  13074. var savedPos0 = pos;
  13075. var savedPos1 = pos;
  13076. if (input.substr(pos, 1) === "{") {
  13077. var result3 = "{";
  13078. pos += 1;
  13079. } else {
  13080. var result3 = null;
  13081. if (reportMatchFailures) {
  13082. matchFailed("\"{\"");
  13083. }
  13084. }
  13085. if (result3 !== null) {
  13086. var result4 = parse_ws();
  13087. if (result4 !== null) {
  13088. var result8 = parse_expressions();
  13089. var result5 = result8 !== null ? result8 : '';
  13090. if (result5 !== null) {
  13091. var result6 = parse_ws();
  13092. if (result6 !== null) {
  13093. if (input.substr(pos, 1) === "}") {
  13094. var result7 = "}";
  13095. pos += 1;
  13096. } else {
  13097. var result7 = null;
  13098. if (reportMatchFailures) {
  13099. matchFailed("\"}\"");
  13100. }
  13101. }
  13102. if (result7 !== null) {
  13103. var result1 = [result3, result4, result5, result6, result7];
  13104. } else {
  13105. var result1 = null;
  13106. pos = savedPos1;
  13107. }
  13108. } else {
  13109. var result1 = null;
  13110. pos = savedPos1;
  13111. }
  13112. } else {
  13113. var result1 = null;
  13114. pos = savedPos1;
  13115. }
  13116. } else {
  13117. var result1 = null;
  13118. pos = savedPos1;
  13119. }
  13120. } else {
  13121. var result1 = null;
  13122. pos = savedPos1;
  13123. }
  13124. var result2 = result1 !== null
  13125. ? (function(expressions) {
  13126. return smalltalk.DynamicArrayNode._new()
  13127. ._nodes_(expressions)
  13128. })(result1[2])
  13129. : null;
  13130. if (result2 !== null) {
  13131. var result0 = result2;
  13132. } else {
  13133. var result0 = null;
  13134. pos = savedPos0;
  13135. }
  13136. cache[cacheKey] = {
  13137. nextPos: pos,
  13138. result: result0
  13139. };
  13140. return result0;
  13141. }
  13142. function parse_dynamicDictionary() {
  13143. var cacheKey = 'dynamicDictionary@' + pos;
  13144. var cachedResult = cache[cacheKey];
  13145. if (cachedResult) {
  13146. pos = cachedResult.nextPos;
  13147. return cachedResult.result;
  13148. }
  13149. var savedPos0 = pos;
  13150. var savedPos1 = pos;
  13151. if (input.substr(pos, 2) === "#{") {
  13152. var result3 = "#{";
  13153. pos += 2;
  13154. } else {
  13155. var result3 = null;
  13156. if (reportMatchFailures) {
  13157. matchFailed("\"#{\"");
  13158. }
  13159. }
  13160. if (result3 !== null) {
  13161. var result4 = parse_ws();
  13162. if (result4 !== null) {
  13163. var result8 = parse_expressions();
  13164. var result5 = result8 !== null ? result8 : '';
  13165. if (result5 !== null) {
  13166. var result6 = parse_ws();
  13167. if (result6 !== null) {
  13168. if (input.substr(pos, 1) === "}") {
  13169. var result7 = "}";
  13170. pos += 1;
  13171. } else {
  13172. var result7 = null;
  13173. if (reportMatchFailures) {
  13174. matchFailed("\"}\"");
  13175. }
  13176. }
  13177. if (result7 !== null) {
  13178. var result1 = [result3, result4, result5, result6, result7];
  13179. } else {
  13180. var result1 = null;
  13181. pos = savedPos1;
  13182. }
  13183. } else {
  13184. var result1 = null;
  13185. pos = savedPos1;
  13186. }
  13187. } else {
  13188. var result1 = null;
  13189. pos = savedPos1;
  13190. }
  13191. } else {
  13192. var result1 = null;
  13193. pos = savedPos1;
  13194. }
  13195. } else {
  13196. var result1 = null;
  13197. pos = savedPos1;
  13198. }
  13199. var result2 = result1 !== null
  13200. ? (function(expressions) {
  13201. return smalltalk.DynamicDictionaryNode._new()
  13202. ._nodes_(expressions)
  13203. })(result1[2])
  13204. : null;
  13205. if (result2 !== null) {
  13206. var result0 = result2;
  13207. } else {
  13208. var result0 = null;
  13209. pos = savedPos0;
  13210. }
  13211. cache[cacheKey] = {
  13212. nextPos: pos,
  13213. result: result0
  13214. };
  13215. return result0;
  13216. }
  13217. function parse_pseudoVariable() {
  13218. var cacheKey = 'pseudoVariable@' + pos;
  13219. var cachedResult = cache[cacheKey];
  13220. if (cachedResult) {
  13221. pos = cachedResult.nextPos;
  13222. return cachedResult.result;
  13223. }
  13224. var savedPos0 = pos;
  13225. var savedPos3 = pos;
  13226. if (input.substr(pos, 4) === "true") {
  13227. var result10 = "true";
  13228. pos += 4;
  13229. } else {
  13230. var result10 = null;
  13231. if (reportMatchFailures) {
  13232. matchFailed("\"true\"");
  13233. }
  13234. }
  13235. var result11 = result10 !== null
  13236. ? (function() {return true})()
  13237. : null;
  13238. if (result11 !== null) {
  13239. var result9 = result11;
  13240. } else {
  13241. var result9 = null;
  13242. pos = savedPos3;
  13243. }
  13244. if (result9 !== null) {
  13245. var result1 = result9;
  13246. } else {
  13247. var savedPos2 = pos;
  13248. if (input.substr(pos, 5) === "false") {
  13249. var result7 = "false";
  13250. pos += 5;
  13251. } else {
  13252. var result7 = null;
  13253. if (reportMatchFailures) {
  13254. matchFailed("\"false\"");
  13255. }
  13256. }
  13257. var result8 = result7 !== null
  13258. ? (function() {return false})()
  13259. : null;
  13260. if (result8 !== null) {
  13261. var result6 = result8;
  13262. } else {
  13263. var result6 = null;
  13264. pos = savedPos2;
  13265. }
  13266. if (result6 !== null) {
  13267. var result1 = result6;
  13268. } else {
  13269. var savedPos1 = pos;
  13270. if (input.substr(pos, 3) === "nil") {
  13271. var result4 = "nil";
  13272. pos += 3;
  13273. } else {
  13274. var result4 = null;
  13275. if (reportMatchFailures) {
  13276. matchFailed("\"nil\"");
  13277. }
  13278. }
  13279. var result5 = result4 !== null
  13280. ? (function() {return nil})()
  13281. : null;
  13282. if (result5 !== null) {
  13283. var result3 = result5;
  13284. } else {
  13285. var result3 = null;
  13286. pos = savedPos1;
  13287. }
  13288. if (result3 !== null) {
  13289. var result1 = result3;
  13290. } else {
  13291. var result1 = null;;
  13292. };
  13293. };
  13294. }
  13295. var result2 = result1 !== null
  13296. ? (function(val) {
  13297. return smalltalk.ValueNode._new()
  13298. ._value_(val)
  13299. })(result1)
  13300. : null;
  13301. if (result2 !== null) {
  13302. var result0 = result2;
  13303. } else {
  13304. var result0 = null;
  13305. pos = savedPos0;
  13306. }
  13307. cache[cacheKey] = {
  13308. nextPos: pos,
  13309. result: result0
  13310. };
  13311. return result0;
  13312. }
  13313. function parse_literal() {
  13314. var cacheKey = 'literal@' + pos;
  13315. var cachedResult = cache[cacheKey];
  13316. if (cachedResult) {
  13317. pos = cachedResult.nextPos;
  13318. return cachedResult.result;
  13319. }
  13320. var result8 = parse_pseudoVariable();
  13321. if (result8 !== null) {
  13322. var result0 = result8;
  13323. } else {
  13324. var result7 = parse_number();
  13325. if (result7 !== null) {
  13326. var result0 = result7;
  13327. } else {
  13328. var result6 = parse_literalArray();
  13329. if (result6 !== null) {
  13330. var result0 = result6;
  13331. } else {
  13332. var result5 = parse_dynamicDictionary();
  13333. if (result5 !== null) {
  13334. var result0 = result5;
  13335. } else {
  13336. var result4 = parse_dynamicArray();
  13337. if (result4 !== null) {
  13338. var result0 = result4;
  13339. } else {
  13340. var result3 = parse_string();
  13341. if (result3 !== null) {
  13342. var result0 = result3;
  13343. } else {
  13344. var result2 = parse_symbol();
  13345. if (result2 !== null) {
  13346. var result0 = result2;
  13347. } else {
  13348. var result1 = parse_block();
  13349. if (result1 !== null) {
  13350. var result0 = result1;
  13351. } else {
  13352. var result0 = null;;
  13353. };
  13354. };
  13355. };
  13356. };
  13357. };
  13358. };
  13359. };
  13360. }
  13361. cache[cacheKey] = {
  13362. nextPos: pos,
  13363. result: result0
  13364. };
  13365. return result0;
  13366. }
  13367. function parse_variable() {
  13368. var cacheKey = 'variable@' + pos;
  13369. var cachedResult = cache[cacheKey];
  13370. if (cachedResult) {
  13371. pos = cachedResult.nextPos;
  13372. return cachedResult.result;
  13373. }
  13374. var savedPos0 = pos;
  13375. var result1 = parse_identifier();
  13376. var result2 = result1 !== null
  13377. ? (function(identifier) {
  13378. return smalltalk.VariableNode._new()
  13379. ._value_(identifier)
  13380. })(result1)
  13381. : null;
  13382. if (result2 !== null) {
  13383. var result0 = result2;
  13384. } else {
  13385. var result0 = null;
  13386. pos = savedPos0;
  13387. }
  13388. cache[cacheKey] = {
  13389. nextPos: pos,
  13390. result: result0
  13391. };
  13392. return result0;
  13393. }
  13394. function parse_classReference() {
  13395. var cacheKey = 'classReference@' + pos;
  13396. var cachedResult = cache[cacheKey];
  13397. if (cachedResult) {
  13398. pos = cachedResult.nextPos;
  13399. return cachedResult.result;
  13400. }
  13401. var savedPos0 = pos;
  13402. var result1 = parse_className();
  13403. var result2 = result1 !== null
  13404. ? (function(className) {
  13405. return smalltalk.ClassReferenceNode._new()
  13406. ._value_(className)
  13407. })(result1)
  13408. : null;
  13409. if (result2 !== null) {
  13410. var result0 = result2;
  13411. } else {
  13412. var result0 = null;
  13413. pos = savedPos0;
  13414. }
  13415. cache[cacheKey] = {
  13416. nextPos: pos,
  13417. result: result0
  13418. };
  13419. return result0;
  13420. }
  13421. function parse_reference() {
  13422. var cacheKey = 'reference@' + pos;
  13423. var cachedResult = cache[cacheKey];
  13424. if (cachedResult) {
  13425. pos = cachedResult.nextPos;
  13426. return cachedResult.result;
  13427. }
  13428. var result2 = parse_variable();
  13429. if (result2 !== null) {
  13430. var result0 = result2;
  13431. } else {
  13432. var result1 = parse_classReference();
  13433. if (result1 !== null) {
  13434. var result0 = result1;
  13435. } else {
  13436. var result0 = null;;
  13437. };
  13438. }
  13439. cache[cacheKey] = {
  13440. nextPos: pos,
  13441. result: result0
  13442. };
  13443. return result0;
  13444. }
  13445. function parse_keywordPair() {
  13446. var cacheKey = 'keywordPair@' + pos;
  13447. var cachedResult = cache[cacheKey];
  13448. if (cachedResult) {
  13449. pos = cachedResult.nextPos;
  13450. return cachedResult.result;
  13451. }
  13452. var savedPos0 = pos;
  13453. var savedPos1 = pos;
  13454. var result3 = parse_keyword();
  13455. if (result3 !== null) {
  13456. var result4 = parse_ws();
  13457. if (result4 !== null) {
  13458. var result5 = parse_binarySend();
  13459. if (result5 !== null) {
  13460. var result6 = parse_ws();
  13461. if (result6 !== null) {
  13462. var result1 = [result3, result4, result5, result6];
  13463. } else {
  13464. var result1 = null;
  13465. pos = savedPos1;
  13466. }
  13467. } else {
  13468. var result1 = null;
  13469. pos = savedPos1;
  13470. }
  13471. } else {
  13472. var result1 = null;
  13473. pos = savedPos1;
  13474. }
  13475. } else {
  13476. var result1 = null;
  13477. pos = savedPos1;
  13478. }
  13479. var result2 = result1 !== null
  13480. ? (function(key, arg) {return {key:key, arg: arg}})(result1[0], result1[2])
  13481. : null;
  13482. if (result2 !== null) {
  13483. var result0 = result2;
  13484. } else {
  13485. var result0 = null;
  13486. pos = savedPos0;
  13487. }
  13488. cache[cacheKey] = {
  13489. nextPos: pos,
  13490. result: result0
  13491. };
  13492. return result0;
  13493. }
  13494. function parse_binarySelector() {
  13495. var cacheKey = 'binarySelector@' + pos;
  13496. var cachedResult = cache[cacheKey];
  13497. if (cachedResult) {
  13498. pos = cachedResult.nextPos;
  13499. return cachedResult.result;
  13500. }
  13501. var savedPos0 = pos;
  13502. if (input.substr(pos).match(/^[\\+*\/=><,@%~|&\-]/) !== null) {
  13503. var result3 = input.charAt(pos);
  13504. pos++;
  13505. } else {
  13506. var result3 = null;
  13507. if (reportMatchFailures) {
  13508. matchFailed("[\\\\+*\\/=><,@%~|&\\-]");
  13509. }
  13510. }
  13511. if (result3 !== null) {
  13512. var result1 = [];
  13513. while (result3 !== null) {
  13514. result1.push(result3);
  13515. if (input.substr(pos).match(/^[\\+*\/=><,@%~|&\-]/) !== null) {
  13516. var result3 = input.charAt(pos);
  13517. pos++;
  13518. } else {
  13519. var result3 = null;
  13520. if (reportMatchFailures) {
  13521. matchFailed("[\\\\+*\\/=><,@%~|&\\-]");
  13522. }
  13523. }
  13524. }
  13525. } else {
  13526. var result1 = null;
  13527. }
  13528. var result2 = result1 !== null
  13529. ? (function(bin) {return bin.join("").replace(/\\/g, '\\\\')})(result1)
  13530. : null;
  13531. if (result2 !== null) {
  13532. var result0 = result2;
  13533. } else {
  13534. var result0 = null;
  13535. pos = savedPos0;
  13536. }
  13537. cache[cacheKey] = {
  13538. nextPos: pos,
  13539. result: result0
  13540. };
  13541. return result0;
  13542. }
  13543. function parse_keywordPattern() {
  13544. var cacheKey = 'keywordPattern@' + pos;
  13545. var cachedResult = cache[cacheKey];
  13546. if (cachedResult) {
  13547. pos = cachedResult.nextPos;
  13548. return cachedResult.result;
  13549. }
  13550. var savedPos0 = pos;
  13551. var savedPos1 = pos;
  13552. var savedPos2 = pos;
  13553. var result6 = parse_ws();
  13554. if (result6 !== null) {
  13555. var result7 = parse_keyword();
  13556. if (result7 !== null) {
  13557. var result8 = parse_ws();
  13558. if (result8 !== null) {
  13559. var result9 = parse_identifier();
  13560. if (result9 !== null) {
  13561. var result4 = [result6, result7, result8, result9];
  13562. } else {
  13563. var result4 = null;
  13564. pos = savedPos2;
  13565. }
  13566. } else {
  13567. var result4 = null;
  13568. pos = savedPos2;
  13569. }
  13570. } else {
  13571. var result4 = null;
  13572. pos = savedPos2;
  13573. }
  13574. } else {
  13575. var result4 = null;
  13576. pos = savedPos2;
  13577. }
  13578. var result5 = result4 !== null
  13579. ? (function(key, arg) {return {key:key, arg: arg}})(result4[1], result4[3])
  13580. : null;
  13581. if (result5 !== null) {
  13582. var result3 = result5;
  13583. } else {
  13584. var result3 = null;
  13585. pos = savedPos1;
  13586. }
  13587. if (result3 !== null) {
  13588. var result1 = [];
  13589. while (result3 !== null) {
  13590. result1.push(result3);
  13591. var savedPos1 = pos;
  13592. var savedPos2 = pos;
  13593. var result6 = parse_ws();
  13594. if (result6 !== null) {
  13595. var result7 = parse_keyword();
  13596. if (result7 !== null) {
  13597. var result8 = parse_ws();
  13598. if (result8 !== null) {
  13599. var result9 = parse_identifier();
  13600. if (result9 !== null) {
  13601. var result4 = [result6, result7, result8, result9];
  13602. } else {
  13603. var result4 = null;
  13604. pos = savedPos2;
  13605. }
  13606. } else {
  13607. var result4 = null;
  13608. pos = savedPos2;
  13609. }
  13610. } else {
  13611. var result4 = null;
  13612. pos = savedPos2;
  13613. }
  13614. } else {
  13615. var result4 = null;
  13616. pos = savedPos2;
  13617. }
  13618. var result5 = result4 !== null
  13619. ? (function(key, arg) {return {key:key, arg: arg}})(result4[1], result4[3])
  13620. : null;
  13621. if (result5 !== null) {
  13622. var result3 = result5;
  13623. } else {
  13624. var result3 = null;
  13625. pos = savedPos1;
  13626. }
  13627. }
  13628. } else {
  13629. var result1 = null;
  13630. }
  13631. var result2 = result1 !== null
  13632. ? (function(pairs) {
  13633. var keywords = [];
  13634. var params = [];
  13635. for(var i=0;i<pairs.length;i++){
  13636. keywords.push(pairs[i].key);
  13637. }
  13638. for(var i=0;i<pairs.length;i++){
  13639. params.push(pairs[i].arg);
  13640. }
  13641. return [keywords.join(""), params]
  13642. })(result1)
  13643. : null;
  13644. if (result2 !== null) {
  13645. var result0 = result2;
  13646. } else {
  13647. var result0 = null;
  13648. pos = savedPos0;
  13649. }
  13650. cache[cacheKey] = {
  13651. nextPos: pos,
  13652. result: result0
  13653. };
  13654. return result0;
  13655. }
  13656. function parse_binaryPattern() {
  13657. var cacheKey = 'binaryPattern@' + pos;
  13658. var cachedResult = cache[cacheKey];
  13659. if (cachedResult) {
  13660. pos = cachedResult.nextPos;
  13661. return cachedResult.result;
  13662. }
  13663. var savedPos0 = pos;
  13664. var savedPos1 = pos;
  13665. var result3 = parse_ws();
  13666. if (result3 !== null) {
  13667. var result4 = parse_binarySelector();
  13668. if (result4 !== null) {
  13669. var result5 = parse_ws();
  13670. if (result5 !== null) {
  13671. var result6 = parse_identifier();
  13672. if (result6 !== null) {
  13673. var result1 = [result3, result4, result5, result6];
  13674. } else {
  13675. var result1 = null;
  13676. pos = savedPos1;
  13677. }
  13678. } else {
  13679. var result1 = null;
  13680. pos = savedPos1;
  13681. }
  13682. } else {
  13683. var result1 = null;
  13684. pos = savedPos1;
  13685. }
  13686. } else {
  13687. var result1 = null;
  13688. pos = savedPos1;
  13689. }
  13690. var result2 = result1 !== null
  13691. ? (function(selector, arg) {return [selector, [arg]]})(result1[1], result1[3])
  13692. : null;
  13693. if (result2 !== null) {
  13694. var result0 = result2;
  13695. } else {
  13696. var result0 = null;
  13697. pos = savedPos0;
  13698. }
  13699. cache[cacheKey] = {
  13700. nextPos: pos,
  13701. result: result0
  13702. };
  13703. return result0;
  13704. }
  13705. function parse_unaryPattern() {
  13706. var cacheKey = 'unaryPattern@' + pos;
  13707. var cachedResult = cache[cacheKey];
  13708. if (cachedResult) {
  13709. pos = cachedResult.nextPos;
  13710. return cachedResult.result;
  13711. }
  13712. var savedPos0 = pos;
  13713. var savedPos1 = pos;
  13714. var result3 = parse_ws();
  13715. if (result3 !== null) {
  13716. var result4 = parse_identifier();
  13717. if (result4 !== null) {
  13718. var result1 = [result3, result4];
  13719. } else {
  13720. var result1 = null;
  13721. pos = savedPos1;
  13722. }
  13723. } else {
  13724. var result1 = null;
  13725. pos = savedPos1;
  13726. }
  13727. var result2 = result1 !== null
  13728. ? (function(selector) {return [selector, []]})(result1[1])
  13729. : null;
  13730. if (result2 !== null) {
  13731. var result0 = result2;
  13732. } else {
  13733. var result0 = null;
  13734. pos = savedPos0;
  13735. }
  13736. cache[cacheKey] = {
  13737. nextPos: pos,
  13738. result: result0
  13739. };
  13740. return result0;
  13741. }
  13742. function parse_expression() {
  13743. var cacheKey = 'expression@' + pos;
  13744. var cachedResult = cache[cacheKey];
  13745. if (cachedResult) {
  13746. pos = cachedResult.nextPos;
  13747. return cachedResult.result;
  13748. }
  13749. var result5 = parse_assignment();
  13750. if (result5 !== null) {
  13751. var result0 = result5;
  13752. } else {
  13753. var result4 = parse_cascade();
  13754. if (result4 !== null) {
  13755. var result0 = result4;
  13756. } else {
  13757. var result3 = parse_keywordSend();
  13758. if (result3 !== null) {
  13759. var result0 = result3;
  13760. } else {
  13761. var result2 = parse_binarySend();
  13762. if (result2 !== null) {
  13763. var result0 = result2;
  13764. } else {
  13765. var result1 = parse_jsStatement();
  13766. if (result1 !== null) {
  13767. var result0 = result1;
  13768. } else {
  13769. var result0 = null;;
  13770. };
  13771. };
  13772. };
  13773. };
  13774. }
  13775. cache[cacheKey] = {
  13776. nextPos: pos,
  13777. result: result0
  13778. };
  13779. return result0;
  13780. }
  13781. function parse_expressionList() {
  13782. var cacheKey = 'expressionList@' + pos;
  13783. var cachedResult = cache[cacheKey];
  13784. if (cachedResult) {
  13785. pos = cachedResult.nextPos;
  13786. return cachedResult.result;
  13787. }
  13788. var savedPos0 = pos;
  13789. var savedPos1 = pos;
  13790. var result3 = parse_ws();
  13791. if (result3 !== null) {
  13792. if (input.substr(pos, 1) === ".") {
  13793. var result4 = ".";
  13794. pos += 1;
  13795. } else {
  13796. var result4 = null;
  13797. if (reportMatchFailures) {
  13798. matchFailed("\".\"");
  13799. }
  13800. }
  13801. if (result4 !== null) {
  13802. var result5 = parse_ws();
  13803. if (result5 !== null) {
  13804. var result6 = parse_expression();
  13805. if (result6 !== null) {
  13806. var result1 = [result3, result4, result5, result6];
  13807. } else {
  13808. var result1 = null;
  13809. pos = savedPos1;
  13810. }
  13811. } else {
  13812. var result1 = null;
  13813. pos = savedPos1;
  13814. }
  13815. } else {
  13816. var result1 = null;
  13817. pos = savedPos1;
  13818. }
  13819. } else {
  13820. var result1 = null;
  13821. pos = savedPos1;
  13822. }
  13823. var result2 = result1 !== null
  13824. ? (function(expression) {return expression})(result1[3])
  13825. : null;
  13826. if (result2 !== null) {
  13827. var result0 = result2;
  13828. } else {
  13829. var result0 = null;
  13830. pos = savedPos0;
  13831. }
  13832. cache[cacheKey] = {
  13833. nextPos: pos,
  13834. result: result0
  13835. };
  13836. return result0;
  13837. }
  13838. function parse_expressions() {
  13839. var cacheKey = 'expressions@' + pos;
  13840. var cachedResult = cache[cacheKey];
  13841. if (cachedResult) {
  13842. pos = cachedResult.nextPos;
  13843. return cachedResult.result;
  13844. }
  13845. var savedPos0 = pos;
  13846. var savedPos1 = pos;
  13847. var result3 = parse_expression();
  13848. if (result3 !== null) {
  13849. var result4 = [];
  13850. var result5 = parse_expressionList();
  13851. while (result5 !== null) {
  13852. result4.push(result5);
  13853. var result5 = parse_expressionList();
  13854. }
  13855. if (result4 !== null) {
  13856. var result1 = [result3, result4];
  13857. } else {
  13858. var result1 = null;
  13859. pos = savedPos1;
  13860. }
  13861. } else {
  13862. var result1 = null;
  13863. pos = savedPos1;
  13864. }
  13865. var result2 = result1 !== null
  13866. ? (function(first, others) {
  13867. var result = [first];
  13868. for(var i=0;i<others.length;i++) {
  13869. result.push(others[i]);
  13870. }
  13871. return result;
  13872. })(result1[0], result1[1])
  13873. : null;
  13874. if (result2 !== null) {
  13875. var result0 = result2;
  13876. } else {
  13877. var result0 = null;
  13878. pos = savedPos0;
  13879. }
  13880. cache[cacheKey] = {
  13881. nextPos: pos,
  13882. result: result0
  13883. };
  13884. return result0;
  13885. }
  13886. function parse_assignment() {
  13887. var cacheKey = 'assignment@' + pos;
  13888. var cachedResult = cache[cacheKey];
  13889. if (cachedResult) {
  13890. pos = cachedResult.nextPos;
  13891. return cachedResult.result;
  13892. }
  13893. var savedPos0 = pos;
  13894. var savedPos1 = pos;
  13895. var result3 = parse_variable();
  13896. if (result3 !== null) {
  13897. var result4 = parse_ws();
  13898. if (result4 !== null) {
  13899. if (input.substr(pos, 2) === ":=") {
  13900. var result5 = ":=";
  13901. pos += 2;
  13902. } else {
  13903. var result5 = null;
  13904. if (reportMatchFailures) {
  13905. matchFailed("\":=\"");
  13906. }
  13907. }
  13908. if (result5 !== null) {
  13909. var result6 = parse_ws();
  13910. if (result6 !== null) {
  13911. var result7 = parse_expression();
  13912. if (result7 !== null) {
  13913. var result1 = [result3, result4, result5, result6, result7];
  13914. } else {
  13915. var result1 = null;
  13916. pos = savedPos1;
  13917. }
  13918. } else {
  13919. var result1 = null;
  13920. pos = savedPos1;
  13921. }
  13922. } else {
  13923. var result1 = null;
  13924. pos = savedPos1;
  13925. }
  13926. } else {
  13927. var result1 = null;
  13928. pos = savedPos1;
  13929. }
  13930. } else {
  13931. var result1 = null;
  13932. pos = savedPos1;
  13933. }
  13934. var result2 = result1 !== null
  13935. ? (function(variable, expression) {
  13936. return smalltalk.AssignmentNode._new()
  13937. ._left_(variable)
  13938. ._right_(expression)
  13939. })(result1[0], result1[4])
  13940. : null;
  13941. if (result2 !== null) {
  13942. var result0 = result2;
  13943. } else {
  13944. var result0 = null;
  13945. pos = savedPos0;
  13946. }
  13947. cache[cacheKey] = {
  13948. nextPos: pos,
  13949. result: result0
  13950. };
  13951. return result0;
  13952. }
  13953. function parse_ret() {
  13954. var cacheKey = 'ret@' + pos;
  13955. var cachedResult = cache[cacheKey];
  13956. if (cachedResult) {
  13957. pos = cachedResult.nextPos;
  13958. return cachedResult.result;
  13959. }
  13960. var savedPos0 = pos;
  13961. var savedPos1 = pos;
  13962. if (input.substr(pos, 1) === "^") {
  13963. var result3 = "^";
  13964. pos += 1;
  13965. } else {
  13966. var result3 = null;
  13967. if (reportMatchFailures) {
  13968. matchFailed("\"^\"");
  13969. }
  13970. }
  13971. if (result3 !== null) {
  13972. var result4 = parse_ws();
  13973. if (result4 !== null) {
  13974. var result5 = parse_expression();
  13975. if (result5 !== null) {
  13976. var result6 = parse_ws();
  13977. if (result6 !== null) {
  13978. if (input.substr(pos, 1) === ".") {
  13979. var result8 = ".";
  13980. pos += 1;
  13981. } else {
  13982. var result8 = null;
  13983. if (reportMatchFailures) {
  13984. matchFailed("\".\"");
  13985. }
  13986. }
  13987. var result7 = result8 !== null ? result8 : '';
  13988. if (result7 !== null) {
  13989. var result1 = [result3, result4, result5, result6, result7];
  13990. } else {
  13991. var result1 = null;
  13992. pos = savedPos1;
  13993. }
  13994. } else {
  13995. var result1 = null;
  13996. pos = savedPos1;
  13997. }
  13998. } else {
  13999. var result1 = null;
  14000. pos = savedPos1;
  14001. }
  14002. } else {
  14003. var result1 = null;
  14004. pos = savedPos1;
  14005. }
  14006. } else {
  14007. var result1 = null;
  14008. pos = savedPos1;
  14009. }
  14010. var result2 = result1 !== null
  14011. ? (function(expression) {
  14012. return smalltalk.ReturnNode._new()
  14013. ._nodes_([expression])
  14014. })(result1[2])
  14015. : null;
  14016. if (result2 !== null) {
  14017. var result0 = result2;
  14018. } else {
  14019. var result0 = null;
  14020. pos = savedPos0;
  14021. }
  14022. cache[cacheKey] = {
  14023. nextPos: pos,
  14024. result: result0
  14025. };
  14026. return result0;
  14027. }
  14028. function parse_temps() {
  14029. var cacheKey = 'temps@' + pos;
  14030. var cachedResult = cache[cacheKey];
  14031. if (cachedResult) {
  14032. pos = cachedResult.nextPos;
  14033. return cachedResult.result;
  14034. }
  14035. var savedPos0 = pos;
  14036. var savedPos1 = pos;
  14037. if (input.substr(pos, 1) === "|") {
  14038. var result3 = "|";
  14039. pos += 1;
  14040. } else {
  14041. var result3 = null;
  14042. if (reportMatchFailures) {
  14043. matchFailed("\"|\"");
  14044. }
  14045. }
  14046. if (result3 !== null) {
  14047. var result4 = [];
  14048. var savedPos2 = pos;
  14049. var savedPos3 = pos;
  14050. var result9 = parse_ws();
  14051. if (result9 !== null) {
  14052. var result10 = parse_identifier();
  14053. if (result10 !== null) {
  14054. var result11 = parse_ws();
  14055. if (result11 !== null) {
  14056. var result7 = [result9, result10, result11];
  14057. } else {
  14058. var result7 = null;
  14059. pos = savedPos3;
  14060. }
  14061. } else {
  14062. var result7 = null;
  14063. pos = savedPos3;
  14064. }
  14065. } else {
  14066. var result7 = null;
  14067. pos = savedPos3;
  14068. }
  14069. var result8 = result7 !== null
  14070. ? (function(variable) {return variable})(result7[1])
  14071. : null;
  14072. if (result8 !== null) {
  14073. var result6 = result8;
  14074. } else {
  14075. var result6 = null;
  14076. pos = savedPos2;
  14077. }
  14078. while (result6 !== null) {
  14079. result4.push(result6);
  14080. var savedPos2 = pos;
  14081. var savedPos3 = pos;
  14082. var result9 = parse_ws();
  14083. if (result9 !== null) {
  14084. var result10 = parse_identifier();
  14085. if (result10 !== null) {
  14086. var result11 = parse_ws();
  14087. if (result11 !== null) {
  14088. var result7 = [result9, result10, result11];
  14089. } else {
  14090. var result7 = null;
  14091. pos = savedPos3;
  14092. }
  14093. } else {
  14094. var result7 = null;
  14095. pos = savedPos3;
  14096. }
  14097. } else {
  14098. var result7 = null;
  14099. pos = savedPos3;
  14100. }
  14101. var result8 = result7 !== null
  14102. ? (function(variable) {return variable})(result7[1])
  14103. : null;
  14104. if (result8 !== null) {
  14105. var result6 = result8;
  14106. } else {
  14107. var result6 = null;
  14108. pos = savedPos2;
  14109. }
  14110. }
  14111. if (result4 !== null) {
  14112. if (input.substr(pos, 1) === "|") {
  14113. var result5 = "|";
  14114. pos += 1;
  14115. } else {
  14116. var result5 = null;
  14117. if (reportMatchFailures) {
  14118. matchFailed("\"|\"");
  14119. }
  14120. }
  14121. if (result5 !== null) {
  14122. var result1 = [result3, result4, result5];
  14123. } else {
  14124. var result1 = null;
  14125. pos = savedPos1;
  14126. }
  14127. } else {
  14128. var result1 = null;
  14129. pos = savedPos1;
  14130. }
  14131. } else {
  14132. var result1 = null;
  14133. pos = savedPos1;
  14134. }
  14135. var result2 = result1 !== null
  14136. ? (function(vars) {return vars})(result1[1])
  14137. : null;
  14138. if (result2 !== null) {
  14139. var result0 = result2;
  14140. } else {
  14141. var result0 = null;
  14142. pos = savedPos0;
  14143. }
  14144. cache[cacheKey] = {
  14145. nextPos: pos,
  14146. result: result0
  14147. };
  14148. return result0;
  14149. }
  14150. function parse_blockParamList() {
  14151. var cacheKey = 'blockParamList@' + pos;
  14152. var cachedResult = cache[cacheKey];
  14153. if (cachedResult) {
  14154. pos = cachedResult.nextPos;
  14155. return cachedResult.result;
  14156. }
  14157. var savedPos0 = pos;
  14158. var savedPos1 = pos;
  14159. var savedPos2 = pos;
  14160. var savedPos3 = pos;
  14161. var result9 = parse_ws();
  14162. if (result9 !== null) {
  14163. if (input.substr(pos, 1) === ":") {
  14164. var result10 = ":";
  14165. pos += 1;
  14166. } else {
  14167. var result10 = null;
  14168. if (reportMatchFailures) {
  14169. matchFailed("\":\"");
  14170. }
  14171. }
  14172. if (result10 !== null) {
  14173. var result11 = parse_ws();
  14174. if (result11 !== null) {
  14175. var result12 = parse_identifier();
  14176. if (result12 !== null) {
  14177. var result7 = [result9, result10, result11, result12];
  14178. } else {
  14179. var result7 = null;
  14180. pos = savedPos3;
  14181. }
  14182. } else {
  14183. var result7 = null;
  14184. pos = savedPos3;
  14185. }
  14186. } else {
  14187. var result7 = null;
  14188. pos = savedPos3;
  14189. }
  14190. } else {
  14191. var result7 = null;
  14192. pos = savedPos3;
  14193. }
  14194. var result8 = result7 !== null
  14195. ? (function(param) {return param})(result7[3])
  14196. : null;
  14197. if (result8 !== null) {
  14198. var result6 = result8;
  14199. } else {
  14200. var result6 = null;
  14201. pos = savedPos2;
  14202. }
  14203. if (result6 !== null) {
  14204. var result3 = [];
  14205. while (result6 !== null) {
  14206. result3.push(result6);
  14207. var savedPos2 = pos;
  14208. var savedPos3 = pos;
  14209. var result9 = parse_ws();
  14210. if (result9 !== null) {
  14211. if (input.substr(pos, 1) === ":") {
  14212. var result10 = ":";
  14213. pos += 1;
  14214. } else {
  14215. var result10 = null;
  14216. if (reportMatchFailures) {
  14217. matchFailed("\":\"");
  14218. }
  14219. }
  14220. if (result10 !== null) {
  14221. var result11 = parse_ws();
  14222. if (result11 !== null) {
  14223. var result12 = parse_identifier();
  14224. if (result12 !== null) {
  14225. var result7 = [result9, result10, result11, result12];
  14226. } else {
  14227. var result7 = null;
  14228. pos = savedPos3;
  14229. }
  14230. } else {
  14231. var result7 = null;
  14232. pos = savedPos3;
  14233. }
  14234. } else {
  14235. var result7 = null;
  14236. pos = savedPos3;
  14237. }
  14238. } else {
  14239. var result7 = null;
  14240. pos = savedPos3;
  14241. }
  14242. var result8 = result7 !== null
  14243. ? (function(param) {return param})(result7[3])
  14244. : null;
  14245. if (result8 !== null) {
  14246. var result6 = result8;
  14247. } else {
  14248. var result6 = null;
  14249. pos = savedPos2;
  14250. }
  14251. }
  14252. } else {
  14253. var result3 = null;
  14254. }
  14255. if (result3 !== null) {
  14256. var result4 = parse_ws();
  14257. if (result4 !== null) {
  14258. if (input.substr(pos, 1) === "|") {
  14259. var result5 = "|";
  14260. pos += 1;
  14261. } else {
  14262. var result5 = null;
  14263. if (reportMatchFailures) {
  14264. matchFailed("\"|\"");
  14265. }
  14266. }
  14267. if (result5 !== null) {
  14268. var result1 = [result3, result4, result5];
  14269. } else {
  14270. var result1 = null;
  14271. pos = savedPos1;
  14272. }
  14273. } else {
  14274. var result1 = null;
  14275. pos = savedPos1;
  14276. }
  14277. } else {
  14278. var result1 = null;
  14279. pos = savedPos1;
  14280. }
  14281. var result2 = result1 !== null
  14282. ? (function(params) {return params})(result1[0])
  14283. : null;
  14284. if (result2 !== null) {
  14285. var result0 = result2;
  14286. } else {
  14287. var result0 = null;
  14288. pos = savedPos0;
  14289. }
  14290. cache[cacheKey] = {
  14291. nextPos: pos,
  14292. result: result0
  14293. };
  14294. return result0;
  14295. }
  14296. function parse_subexpression() {
  14297. var cacheKey = 'subexpression@' + pos;
  14298. var cachedResult = cache[cacheKey];
  14299. if (cachedResult) {
  14300. pos = cachedResult.nextPos;
  14301. return cachedResult.result;
  14302. }
  14303. var savedPos0 = pos;
  14304. var savedPos1 = pos;
  14305. if (input.substr(pos, 1) === "(") {
  14306. var result3 = "(";
  14307. pos += 1;
  14308. } else {
  14309. var result3 = null;
  14310. if (reportMatchFailures) {
  14311. matchFailed("\"(\"");
  14312. }
  14313. }
  14314. if (result3 !== null) {
  14315. var result4 = parse_ws();
  14316. if (result4 !== null) {
  14317. var result5 = parse_expression();
  14318. if (result5 !== null) {
  14319. var result6 = parse_ws();
  14320. if (result6 !== null) {
  14321. if (input.substr(pos, 1) === ")") {
  14322. var result7 = ")";
  14323. pos += 1;
  14324. } else {
  14325. var result7 = null;
  14326. if (reportMatchFailures) {
  14327. matchFailed("\")\"");
  14328. }
  14329. }
  14330. if (result7 !== null) {
  14331. var result1 = [result3, result4, result5, result6, result7];
  14332. } else {
  14333. var result1 = null;
  14334. pos = savedPos1;
  14335. }
  14336. } else {
  14337. var result1 = null;
  14338. pos = savedPos1;
  14339. }
  14340. } else {
  14341. var result1 = null;
  14342. pos = savedPos1;
  14343. }
  14344. } else {
  14345. var result1 = null;
  14346. pos = savedPos1;
  14347. }
  14348. } else {
  14349. var result1 = null;
  14350. pos = savedPos1;
  14351. }
  14352. var result2 = result1 !== null
  14353. ? (function(expression) {return expression})(result1[2])
  14354. : null;
  14355. if (result2 !== null) {
  14356. var result0 = result2;
  14357. } else {
  14358. var result0 = null;
  14359. pos = savedPos0;
  14360. }
  14361. cache[cacheKey] = {
  14362. nextPos: pos,
  14363. result: result0
  14364. };
  14365. return result0;
  14366. }
  14367. function parse_statements() {
  14368. var cacheKey = 'statements@' + pos;
  14369. var cachedResult = cache[cacheKey];
  14370. if (cachedResult) {
  14371. pos = cachedResult.nextPos;
  14372. return cachedResult.result;
  14373. }
  14374. var savedPos4 = pos;
  14375. var savedPos5 = pos;
  14376. var result22 = parse_ret();
  14377. if (result22 !== null) {
  14378. var result23 = [];
  14379. if (input.substr(pos).match(/^[.]/) !== null) {
  14380. var result24 = input.charAt(pos);
  14381. pos++;
  14382. } else {
  14383. var result24 = null;
  14384. if (reportMatchFailures) {
  14385. matchFailed("[.]");
  14386. }
  14387. }
  14388. while (result24 !== null) {
  14389. result23.push(result24);
  14390. if (input.substr(pos).match(/^[.]/) !== null) {
  14391. var result24 = input.charAt(pos);
  14392. pos++;
  14393. } else {
  14394. var result24 = null;
  14395. if (reportMatchFailures) {
  14396. matchFailed("[.]");
  14397. }
  14398. }
  14399. }
  14400. if (result23 !== null) {
  14401. var result20 = [result22, result23];
  14402. } else {
  14403. var result20 = null;
  14404. pos = savedPos5;
  14405. }
  14406. } else {
  14407. var result20 = null;
  14408. pos = savedPos5;
  14409. }
  14410. var result21 = result20 !== null
  14411. ? (function(ret) {return [ret]})(result20[0])
  14412. : null;
  14413. if (result21 !== null) {
  14414. var result19 = result21;
  14415. } else {
  14416. var result19 = null;
  14417. pos = savedPos4;
  14418. }
  14419. if (result19 !== null) {
  14420. var result0 = result19;
  14421. } else {
  14422. var savedPos2 = pos;
  14423. var savedPos3 = pos;
  14424. var result11 = parse_expressions();
  14425. if (result11 !== null) {
  14426. var result12 = parse_ws();
  14427. if (result12 !== null) {
  14428. if (input.substr(pos).match(/^[.]/) !== null) {
  14429. var result18 = input.charAt(pos);
  14430. pos++;
  14431. } else {
  14432. var result18 = null;
  14433. if (reportMatchFailures) {
  14434. matchFailed("[.]");
  14435. }
  14436. }
  14437. if (result18 !== null) {
  14438. var result13 = [];
  14439. while (result18 !== null) {
  14440. result13.push(result18);
  14441. if (input.substr(pos).match(/^[.]/) !== null) {
  14442. var result18 = input.charAt(pos);
  14443. pos++;
  14444. } else {
  14445. var result18 = null;
  14446. if (reportMatchFailures) {
  14447. matchFailed("[.]");
  14448. }
  14449. }
  14450. }
  14451. } else {
  14452. var result13 = null;
  14453. }
  14454. if (result13 !== null) {
  14455. var result14 = parse_ws();
  14456. if (result14 !== null) {
  14457. var result15 = parse_ret();
  14458. if (result15 !== null) {
  14459. var result16 = [];
  14460. if (input.substr(pos).match(/^[.]/) !== null) {
  14461. var result17 = input.charAt(pos);
  14462. pos++;
  14463. } else {
  14464. var result17 = null;
  14465. if (reportMatchFailures) {
  14466. matchFailed("[.]");
  14467. }
  14468. }
  14469. while (result17 !== null) {
  14470. result16.push(result17);
  14471. if (input.substr(pos).match(/^[.]/) !== null) {
  14472. var result17 = input.charAt(pos);
  14473. pos++;
  14474. } else {
  14475. var result17 = null;
  14476. if (reportMatchFailures) {
  14477. matchFailed("[.]");
  14478. }
  14479. }
  14480. }
  14481. if (result16 !== null) {
  14482. var result9 = [result11, result12, result13, result14, result15, result16];
  14483. } else {
  14484. var result9 = null;
  14485. pos = savedPos3;
  14486. }
  14487. } else {
  14488. var result9 = null;
  14489. pos = savedPos3;
  14490. }
  14491. } else {
  14492. var result9 = null;
  14493. pos = savedPos3;
  14494. }
  14495. } else {
  14496. var result9 = null;
  14497. pos = savedPos3;
  14498. }
  14499. } else {
  14500. var result9 = null;
  14501. pos = savedPos3;
  14502. }
  14503. } else {
  14504. var result9 = null;
  14505. pos = savedPos3;
  14506. }
  14507. var result10 = result9 !== null
  14508. ? (function(exps, ret) {
  14509. var expressions = exps;
  14510. expressions.push(ret);
  14511. return expressions
  14512. })(result9[0], result9[4])
  14513. : null;
  14514. if (result10 !== null) {
  14515. var result8 = result10;
  14516. } else {
  14517. var result8 = null;
  14518. pos = savedPos2;
  14519. }
  14520. if (result8 !== null) {
  14521. var result0 = result8;
  14522. } else {
  14523. var savedPos0 = pos;
  14524. var savedPos1 = pos;
  14525. var result7 = parse_expressions();
  14526. var result4 = result7 !== null ? result7 : '';
  14527. if (result4 !== null) {
  14528. var result5 = [];
  14529. if (input.substr(pos).match(/^[.]/) !== null) {
  14530. var result6 = input.charAt(pos);
  14531. pos++;
  14532. } else {
  14533. var result6 = null;
  14534. if (reportMatchFailures) {
  14535. matchFailed("[.]");
  14536. }
  14537. }
  14538. while (result6 !== null) {
  14539. result5.push(result6);
  14540. if (input.substr(pos).match(/^[.]/) !== null) {
  14541. var result6 = input.charAt(pos);
  14542. pos++;
  14543. } else {
  14544. var result6 = null;
  14545. if (reportMatchFailures) {
  14546. matchFailed("[.]");
  14547. }
  14548. }
  14549. }
  14550. if (result5 !== null) {
  14551. var result2 = [result4, result5];
  14552. } else {
  14553. var result2 = null;
  14554. pos = savedPos1;
  14555. }
  14556. } else {
  14557. var result2 = null;
  14558. pos = savedPos1;
  14559. }
  14560. var result3 = result2 !== null
  14561. ? (function(expressions) {
  14562. return expressions || []
  14563. })(result2[0])
  14564. : null;
  14565. if (result3 !== null) {
  14566. var result1 = result3;
  14567. } else {
  14568. var result1 = null;
  14569. pos = savedPos0;
  14570. }
  14571. if (result1 !== null) {
  14572. var result0 = result1;
  14573. } else {
  14574. var result0 = null;;
  14575. };
  14576. };
  14577. }
  14578. cache[cacheKey] = {
  14579. nextPos: pos,
  14580. result: result0
  14581. };
  14582. return result0;
  14583. }
  14584. function parse_sequence() {
  14585. var cacheKey = 'sequence@' + pos;
  14586. var cachedResult = cache[cacheKey];
  14587. if (cachedResult) {
  14588. pos = cachedResult.nextPos;
  14589. return cachedResult.result;
  14590. }
  14591. var savedPos0 = pos;
  14592. var savedPos1 = pos;
  14593. var result8 = parse_temps();
  14594. var result3 = result8 !== null ? result8 : '';
  14595. if (result3 !== null) {
  14596. var result4 = parse_ws();
  14597. if (result4 !== null) {
  14598. var result7 = parse_statements();
  14599. var result5 = result7 !== null ? result7 : '';
  14600. if (result5 !== null) {
  14601. var result6 = parse_ws();
  14602. if (result6 !== null) {
  14603. var result1 = [result3, result4, result5, result6];
  14604. } else {
  14605. var result1 = null;
  14606. pos = savedPos1;
  14607. }
  14608. } else {
  14609. var result1 = null;
  14610. pos = savedPos1;
  14611. }
  14612. } else {
  14613. var result1 = null;
  14614. pos = savedPos1;
  14615. }
  14616. } else {
  14617. var result1 = null;
  14618. pos = savedPos1;
  14619. }
  14620. var result2 = result1 !== null
  14621. ? (function(temps, statements) {
  14622. return smalltalk.SequenceNode._new()
  14623. ._temps_(temps || [])
  14624. ._nodes_(statements || [])
  14625. })(result1[0], result1[2])
  14626. : null;
  14627. if (result2 !== null) {
  14628. var result0 = result2;
  14629. } else {
  14630. var result0 = null;
  14631. pos = savedPos0;
  14632. }
  14633. cache[cacheKey] = {
  14634. nextPos: pos,
  14635. result: result0
  14636. };
  14637. return result0;
  14638. }
  14639. function parse_block() {
  14640. var cacheKey = 'block@' + pos;
  14641. var cachedResult = cache[cacheKey];
  14642. if (cachedResult) {
  14643. pos = cachedResult.nextPos;
  14644. return cachedResult.result;
  14645. }
  14646. var savedPos0 = pos;
  14647. var savedPos1 = pos;
  14648. if (input.substr(pos, 1) === "[") {
  14649. var result3 = "[";
  14650. pos += 1;
  14651. } else {
  14652. var result3 = null;
  14653. if (reportMatchFailures) {
  14654. matchFailed("\"[\"");
  14655. }
  14656. }
  14657. if (result3 !== null) {
  14658. var result4 = parse_ws();
  14659. if (result4 !== null) {
  14660. var result11 = parse_blockParamList();
  14661. var result5 = result11 !== null ? result11 : '';
  14662. if (result5 !== null) {
  14663. var result6 = parse_ws();
  14664. if (result6 !== null) {
  14665. var result10 = parse_sequence();
  14666. var result7 = result10 !== null ? result10 : '';
  14667. if (result7 !== null) {
  14668. var result8 = parse_ws();
  14669. if (result8 !== null) {
  14670. if (input.substr(pos, 1) === "]") {
  14671. var result9 = "]";
  14672. pos += 1;
  14673. } else {
  14674. var result9 = null;
  14675. if (reportMatchFailures) {
  14676. matchFailed("\"]\"");
  14677. }
  14678. }
  14679. if (result9 !== null) {
  14680. var result1 = [result3, result4, result5, result6, result7, result8, result9];
  14681. } else {
  14682. var result1 = null;
  14683. pos = savedPos1;
  14684. }
  14685. } else {
  14686. var result1 = null;
  14687. pos = savedPos1;
  14688. }
  14689. } else {
  14690. var result1 = null;
  14691. pos = savedPos1;
  14692. }
  14693. } else {
  14694. var result1 = null;
  14695. pos = savedPos1;
  14696. }
  14697. } else {
  14698. var result1 = null;
  14699. pos = savedPos1;
  14700. }
  14701. } else {
  14702. var result1 = null;
  14703. pos = savedPos1;
  14704. }
  14705. } else {
  14706. var result1 = null;
  14707. pos = savedPos1;
  14708. }
  14709. var result2 = result1 !== null
  14710. ? (function(params, sequence) {
  14711. return smalltalk.BlockNode._new()
  14712. ._parameters_(params || [])
  14713. ._nodes_([sequence._asBlockSequenceNode()])
  14714. })(result1[2], result1[4])
  14715. : null;
  14716. if (result2 !== null) {
  14717. var result0 = result2;
  14718. } else {
  14719. var result0 = null;
  14720. pos = savedPos0;
  14721. }
  14722. cache[cacheKey] = {
  14723. nextPos: pos,
  14724. result: result0
  14725. };
  14726. return result0;
  14727. }
  14728. function parse_operand() {
  14729. var cacheKey = 'operand@' + pos;
  14730. var cachedResult = cache[cacheKey];
  14731. if (cachedResult) {
  14732. pos = cachedResult.nextPos;
  14733. return cachedResult.result;
  14734. }
  14735. var result3 = parse_literal();
  14736. if (result3 !== null) {
  14737. var result0 = result3;
  14738. } else {
  14739. var result2 = parse_reference();
  14740. if (result2 !== null) {
  14741. var result0 = result2;
  14742. } else {
  14743. var result1 = parse_subexpression();
  14744. if (result1 !== null) {
  14745. var result0 = result1;
  14746. } else {
  14747. var result0 = null;;
  14748. };
  14749. };
  14750. }
  14751. cache[cacheKey] = {
  14752. nextPos: pos,
  14753. result: result0
  14754. };
  14755. return result0;
  14756. }
  14757. function parse_unaryMessage() {
  14758. var cacheKey = 'unaryMessage@' + pos;
  14759. var cachedResult = cache[cacheKey];
  14760. if (cachedResult) {
  14761. pos = cachedResult.nextPos;
  14762. return cachedResult.result;
  14763. }
  14764. var savedPos0 = pos;
  14765. var savedPos1 = pos;
  14766. var result3 = parse_ws();
  14767. if (result3 !== null) {
  14768. var result4 = parse_identifier();
  14769. if (result4 !== null) {
  14770. var savedPos2 = pos;
  14771. var savedReportMatchFailuresVar0 = reportMatchFailures;
  14772. reportMatchFailures = false;
  14773. if (input.substr(pos).match(/^[:]/) !== null) {
  14774. var result6 = input.charAt(pos);
  14775. pos++;
  14776. } else {
  14777. var result6 = null;
  14778. if (reportMatchFailures) {
  14779. matchFailed("[:]");
  14780. }
  14781. }
  14782. reportMatchFailures = savedReportMatchFailuresVar0;
  14783. if (result6 === null) {
  14784. var result5 = '';
  14785. } else {
  14786. var result5 = null;
  14787. pos = savedPos2;
  14788. }
  14789. if (result5 !== null) {
  14790. var result1 = [result3, result4, result5];
  14791. } else {
  14792. var result1 = null;
  14793. pos = savedPos1;
  14794. }
  14795. } else {
  14796. var result1 = null;
  14797. pos = savedPos1;
  14798. }
  14799. } else {
  14800. var result1 = null;
  14801. pos = savedPos1;
  14802. }
  14803. var result2 = result1 !== null
  14804. ? (function(selector) {
  14805. return smalltalk.SendNode._new()
  14806. ._selector_(selector)
  14807. })(result1[1])
  14808. : null;
  14809. if (result2 !== null) {
  14810. var result0 = result2;
  14811. } else {
  14812. var result0 = null;
  14813. pos = savedPos0;
  14814. }
  14815. cache[cacheKey] = {
  14816. nextPos: pos,
  14817. result: result0
  14818. };
  14819. return result0;
  14820. }
  14821. function parse_unaryTail() {
  14822. var cacheKey = 'unaryTail@' + pos;
  14823. var cachedResult = cache[cacheKey];
  14824. if (cachedResult) {
  14825. pos = cachedResult.nextPos;
  14826. return cachedResult.result;
  14827. }
  14828. var savedPos0 = pos;
  14829. var savedPos1 = pos;
  14830. var result3 = parse_unaryMessage();
  14831. if (result3 !== null) {
  14832. var result4 = parse_ws();
  14833. if (result4 !== null) {
  14834. var result7 = parse_unaryTail();
  14835. var result5 = result7 !== null ? result7 : '';
  14836. if (result5 !== null) {
  14837. var result6 = parse_ws();
  14838. if (result6 !== null) {
  14839. var result1 = [result3, result4, result5, result6];
  14840. } else {
  14841. var result1 = null;
  14842. pos = savedPos1;
  14843. }
  14844. } else {
  14845. var result1 = null;
  14846. pos = savedPos1;
  14847. }
  14848. } else {
  14849. var result1 = null;
  14850. pos = savedPos1;
  14851. }
  14852. } else {
  14853. var result1 = null;
  14854. pos = savedPos1;
  14855. }
  14856. var result2 = result1 !== null
  14857. ? (function(message, tail) {
  14858. if(tail) {
  14859. return tail._valueForReceiver_(message);
  14860. }
  14861. else {
  14862. return message;
  14863. }
  14864. })(result1[0], result1[2])
  14865. : null;
  14866. if (result2 !== null) {
  14867. var result0 = result2;
  14868. } else {
  14869. var result0 = null;
  14870. pos = savedPos0;
  14871. }
  14872. cache[cacheKey] = {
  14873. nextPos: pos,
  14874. result: result0
  14875. };
  14876. return result0;
  14877. }
  14878. function parse_unarySend() {
  14879. var cacheKey = 'unarySend@' + pos;
  14880. var cachedResult = cache[cacheKey];
  14881. if (cachedResult) {
  14882. pos = cachedResult.nextPos;
  14883. return cachedResult.result;
  14884. }
  14885. var savedPos0 = pos;
  14886. var savedPos1 = pos;
  14887. var result3 = parse_operand();
  14888. if (result3 !== null) {
  14889. var result4 = parse_ws();
  14890. if (result4 !== null) {
  14891. var result6 = parse_unaryTail();
  14892. var result5 = result6 !== null ? result6 : '';
  14893. if (result5 !== null) {
  14894. var result1 = [result3, result4, result5];
  14895. } else {
  14896. var result1 = null;
  14897. pos = savedPos1;
  14898. }
  14899. } else {
  14900. var result1 = null;
  14901. pos = savedPos1;
  14902. }
  14903. } else {
  14904. var result1 = null;
  14905. pos = savedPos1;
  14906. }
  14907. var result2 = result1 !== null
  14908. ? (function(receiver, tail) {
  14909. if(tail) {
  14910. return tail._valueForReceiver_(receiver);
  14911. }
  14912. else {
  14913. return receiver;
  14914. }
  14915. })(result1[0], result1[2])
  14916. : null;
  14917. if (result2 !== null) {
  14918. var result0 = result2;
  14919. } else {
  14920. var result0 = null;
  14921. pos = savedPos0;
  14922. }
  14923. cache[cacheKey] = {
  14924. nextPos: pos,
  14925. result: result0
  14926. };
  14927. return result0;
  14928. }
  14929. function parse_binaryMessage() {
  14930. var cacheKey = 'binaryMessage@' + pos;
  14931. var cachedResult = cache[cacheKey];
  14932. if (cachedResult) {
  14933. pos = cachedResult.nextPos;
  14934. return cachedResult.result;
  14935. }
  14936. var savedPos0 = pos;
  14937. var savedPos1 = pos;
  14938. var result3 = parse_ws();
  14939. if (result3 !== null) {
  14940. var result4 = parse_binarySelector();
  14941. if (result4 !== null) {
  14942. var result5 = parse_ws();
  14943. if (result5 !== null) {
  14944. var result8 = parse_unarySend();
  14945. if (result8 !== null) {
  14946. var result6 = result8;
  14947. } else {
  14948. var result7 = parse_operand();
  14949. if (result7 !== null) {
  14950. var result6 = result7;
  14951. } else {
  14952. var result6 = null;;
  14953. };
  14954. }
  14955. if (result6 !== null) {
  14956. var result1 = [result3, result4, result5, result6];
  14957. } else {
  14958. var result1 = null;
  14959. pos = savedPos1;
  14960. }
  14961. } else {
  14962. var result1 = null;
  14963. pos = savedPos1;
  14964. }
  14965. } else {
  14966. var result1 = null;
  14967. pos = savedPos1;
  14968. }
  14969. } else {
  14970. var result1 = null;
  14971. pos = savedPos1;
  14972. }
  14973. var result2 = result1 !== null
  14974. ? (function(selector, arg) {
  14975. return smalltalk.SendNode._new()
  14976. ._selector_(selector)
  14977. ._arguments_([arg])
  14978. })(result1[1], result1[3])
  14979. : null;
  14980. if (result2 !== null) {
  14981. var result0 = result2;
  14982. } else {
  14983. var result0 = null;
  14984. pos = savedPos0;
  14985. }
  14986. cache[cacheKey] = {
  14987. nextPos: pos,
  14988. result: result0
  14989. };
  14990. return result0;
  14991. }
  14992. function parse_binaryTail() {
  14993. var cacheKey = 'binaryTail@' + pos;
  14994. var cachedResult = cache[cacheKey];
  14995. if (cachedResult) {
  14996. pos = cachedResult.nextPos;
  14997. return cachedResult.result;
  14998. }
  14999. var savedPos0 = pos;
  15000. var savedPos1 = pos;
  15001. var result3 = parse_binaryMessage();
  15002. if (result3 !== null) {
  15003. var result5 = parse_binaryTail();
  15004. var result4 = result5 !== null ? result5 : '';
  15005. if (result4 !== null) {
  15006. var result1 = [result3, result4];
  15007. } else {
  15008. var result1 = null;
  15009. pos = savedPos1;
  15010. }
  15011. } else {
  15012. var result1 = null;
  15013. pos = savedPos1;
  15014. }
  15015. var result2 = result1 !== null
  15016. ? (function(message, tail) {
  15017. if(tail) {
  15018. return tail._valueForReceiver_(message);
  15019. }
  15020. else {
  15021. return message;
  15022. }
  15023. })(result1[0], result1[1])
  15024. : null;
  15025. if (result2 !== null) {
  15026. var result0 = result2;
  15027. } else {
  15028. var result0 = null;
  15029. pos = savedPos0;
  15030. }
  15031. cache[cacheKey] = {
  15032. nextPos: pos,
  15033. result: result0
  15034. };
  15035. return result0;
  15036. }
  15037. function parse_binarySend() {
  15038. var cacheKey = 'binarySend@' + pos;
  15039. var cachedResult = cache[cacheKey];
  15040. if (cachedResult) {
  15041. pos = cachedResult.nextPos;
  15042. return cachedResult.result;
  15043. }
  15044. var savedPos0 = pos;
  15045. var savedPos1 = pos;
  15046. var result3 = parse_unarySend();
  15047. if (result3 !== null) {
  15048. var result5 = parse_binaryTail();
  15049. var result4 = result5 !== null ? result5 : '';
  15050. if (result4 !== null) {
  15051. var result1 = [result3, result4];
  15052. } else {
  15053. var result1 = null;
  15054. pos = savedPos1;
  15055. }
  15056. } else {
  15057. var result1 = null;
  15058. pos = savedPos1;
  15059. }
  15060. var result2 = result1 !== null
  15061. ? (function(receiver, tail) {
  15062. if(tail) {
  15063. return tail._valueForReceiver_(receiver);
  15064. }
  15065. else {
  15066. return receiver;
  15067. }
  15068. })(result1[0], result1[1])
  15069. : null;
  15070. if (result2 !== null) {
  15071. var result0 = result2;
  15072. } else {
  15073. var result0 = null;
  15074. pos = savedPos0;
  15075. }
  15076. cache[cacheKey] = {
  15077. nextPos: pos,
  15078. result: result0
  15079. };
  15080. return result0;
  15081. }
  15082. function parse_keywordMessage() {
  15083. var cacheKey = 'keywordMessage@' + pos;
  15084. var cachedResult = cache[cacheKey];
  15085. if (cachedResult) {
  15086. pos = cachedResult.nextPos;
  15087. return cachedResult.result;
  15088. }
  15089. var savedPos0 = pos;
  15090. var savedPos1 = pos;
  15091. var result3 = parse_ws();
  15092. if (result3 !== null) {
  15093. var savedPos2 = pos;
  15094. var savedPos3 = pos;
  15095. var result8 = parse_keywordPair();
  15096. if (result8 !== null) {
  15097. var result9 = parse_ws();
  15098. if (result9 !== null) {
  15099. var result6 = [result8, result9];
  15100. } else {
  15101. var result6 = null;
  15102. pos = savedPos3;
  15103. }
  15104. } else {
  15105. var result6 = null;
  15106. pos = savedPos3;
  15107. }
  15108. var result7 = result6 !== null
  15109. ? (function(pair) {return pair})(result6[0])
  15110. : null;
  15111. if (result7 !== null) {
  15112. var result5 = result7;
  15113. } else {
  15114. var result5 = null;
  15115. pos = savedPos2;
  15116. }
  15117. if (result5 !== null) {
  15118. var result4 = [];
  15119. while (result5 !== null) {
  15120. result4.push(result5);
  15121. var savedPos2 = pos;
  15122. var savedPos3 = pos;
  15123. var result8 = parse_keywordPair();
  15124. if (result8 !== null) {
  15125. var result9 = parse_ws();
  15126. if (result9 !== null) {
  15127. var result6 = [result8, result9];
  15128. } else {
  15129. var result6 = null;
  15130. pos = savedPos3;
  15131. }
  15132. } else {
  15133. var result6 = null;
  15134. pos = savedPos3;
  15135. }
  15136. var result7 = result6 !== null
  15137. ? (function(pair) {return pair})(result6[0])
  15138. : null;
  15139. if (result7 !== null) {
  15140. var result5 = result7;
  15141. } else {
  15142. var result5 = null;
  15143. pos = savedPos2;
  15144. }
  15145. }
  15146. } else {
  15147. var result4 = null;
  15148. }
  15149. if (result4 !== null) {
  15150. var result1 = [result3, result4];
  15151. } else {
  15152. var result1 = null;
  15153. pos = savedPos1;
  15154. }
  15155. } else {
  15156. var result1 = null;
  15157. pos = savedPos1;
  15158. }
  15159. var result2 = result1 !== null
  15160. ? (function(pairs) {
  15161. var selector = [];
  15162. var args = [];
  15163. for(var i=0;i<pairs.length;i++) {
  15164. selector.push(pairs[i].key);
  15165. args.push(pairs[i].arg);
  15166. }
  15167. return smalltalk.SendNode._new()
  15168. ._selector_(selector.join(""))
  15169. ._arguments_(args)
  15170. })(result1[1])
  15171. : null;
  15172. if (result2 !== null) {
  15173. var result0 = result2;
  15174. } else {
  15175. var result0 = null;
  15176. pos = savedPos0;
  15177. }
  15178. cache[cacheKey] = {
  15179. nextPos: pos,
  15180. result: result0
  15181. };
  15182. return result0;
  15183. }
  15184. function parse_keywordSend() {
  15185. var cacheKey = 'keywordSend@' + pos;
  15186. var cachedResult = cache[cacheKey];
  15187. if (cachedResult) {
  15188. pos = cachedResult.nextPos;
  15189. return cachedResult.result;
  15190. }
  15191. var savedPos0 = pos;
  15192. var savedPos1 = pos;
  15193. var result3 = parse_binarySend();
  15194. if (result3 !== null) {
  15195. var result4 = parse_keywordMessage();
  15196. if (result4 !== null) {
  15197. var result1 = [result3, result4];
  15198. } else {
  15199. var result1 = null;
  15200. pos = savedPos1;
  15201. }
  15202. } else {
  15203. var result1 = null;
  15204. pos = savedPos1;
  15205. }
  15206. var result2 = result1 !== null
  15207. ? (function(receiver, tail) {
  15208. return tail._valueForReceiver_(receiver);
  15209. })(result1[0], result1[1])
  15210. : null;
  15211. if (result2 !== null) {
  15212. var result0 = result2;
  15213. } else {
  15214. var result0 = null;
  15215. pos = savedPos0;
  15216. }
  15217. cache[cacheKey] = {
  15218. nextPos: pos,
  15219. result: result0
  15220. };
  15221. return result0;
  15222. }
  15223. function parse_message() {
  15224. var cacheKey = 'message@' + pos;
  15225. var cachedResult = cache[cacheKey];
  15226. if (cachedResult) {
  15227. pos = cachedResult.nextPos;
  15228. return cachedResult.result;
  15229. }
  15230. var result3 = parse_binaryMessage();
  15231. if (result3 !== null) {
  15232. var result0 = result3;
  15233. } else {
  15234. var result2 = parse_unaryMessage();
  15235. if (result2 !== null) {
  15236. var result0 = result2;
  15237. } else {
  15238. var result1 = parse_keywordMessage();
  15239. if (result1 !== null) {
  15240. var result0 = result1;
  15241. } else {
  15242. var result0 = null;;
  15243. };
  15244. };
  15245. }
  15246. cache[cacheKey] = {
  15247. nextPos: pos,
  15248. result: result0
  15249. };
  15250. return result0;
  15251. }
  15252. function parse_cascade() {
  15253. var cacheKey = 'cascade@' + pos;
  15254. var cachedResult = cache[cacheKey];
  15255. if (cachedResult) {
  15256. pos = cachedResult.nextPos;
  15257. return cachedResult.result;
  15258. }
  15259. var savedPos0 = pos;
  15260. var savedPos1 = pos;
  15261. var result3 = parse_ws();
  15262. if (result3 !== null) {
  15263. var result15 = parse_keywordSend();
  15264. if (result15 !== null) {
  15265. var result4 = result15;
  15266. } else {
  15267. var result14 = parse_binarySend();
  15268. if (result14 !== null) {
  15269. var result4 = result14;
  15270. } else {
  15271. var result4 = null;;
  15272. };
  15273. }
  15274. if (result4 !== null) {
  15275. var savedPos2 = pos;
  15276. var savedPos3 = pos;
  15277. var result9 = parse_ws();
  15278. if (result9 !== null) {
  15279. if (input.substr(pos, 1) === ";") {
  15280. var result10 = ";";
  15281. pos += 1;
  15282. } else {
  15283. var result10 = null;
  15284. if (reportMatchFailures) {
  15285. matchFailed("\";\"");
  15286. }
  15287. }
  15288. if (result10 !== null) {
  15289. var result11 = parse_ws();
  15290. if (result11 !== null) {
  15291. var result12 = parse_message();
  15292. if (result12 !== null) {
  15293. var result13 = parse_ws();
  15294. if (result13 !== null) {
  15295. var result7 = [result9, result10, result11, result12, result13];
  15296. } else {
  15297. var result7 = null;
  15298. pos = savedPos3;
  15299. }
  15300. } else {
  15301. var result7 = null;
  15302. pos = savedPos3;
  15303. }
  15304. } else {
  15305. var result7 = null;
  15306. pos = savedPos3;
  15307. }
  15308. } else {
  15309. var result7 = null;
  15310. pos = savedPos3;
  15311. }
  15312. } else {
  15313. var result7 = null;
  15314. pos = savedPos3;
  15315. }
  15316. var result8 = result7 !== null
  15317. ? (function(mess) {return mess})(result7[3])
  15318. : null;
  15319. if (result8 !== null) {
  15320. var result6 = result8;
  15321. } else {
  15322. var result6 = null;
  15323. pos = savedPos2;
  15324. }
  15325. if (result6 !== null) {
  15326. var result5 = [];
  15327. while (result6 !== null) {
  15328. result5.push(result6);
  15329. var savedPos2 = pos;
  15330. var savedPos3 = pos;
  15331. var result9 = parse_ws();
  15332. if (result9 !== null) {
  15333. if (input.substr(pos, 1) === ";") {
  15334. var result10 = ";";
  15335. pos += 1;
  15336. } else {
  15337. var result10 = null;
  15338. if (reportMatchFailures) {
  15339. matchFailed("\";\"");
  15340. }
  15341. }
  15342. if (result10 !== null) {
  15343. var result11 = parse_ws();
  15344. if (result11 !== null) {
  15345. var result12 = parse_message();
  15346. if (result12 !== null) {
  15347. var result13 = parse_ws();
  15348. if (result13 !== null) {
  15349. var result7 = [result9, result10, result11, result12, result13];
  15350. } else {
  15351. var result7 = null;
  15352. pos = savedPos3;
  15353. }
  15354. } else {
  15355. var result7 = null;
  15356. pos = savedPos3;
  15357. }
  15358. } else {
  15359. var result7 = null;
  15360. pos = savedPos3;
  15361. }
  15362. } else {
  15363. var result7 = null;
  15364. pos = savedPos3;
  15365. }
  15366. } else {
  15367. var result7 = null;
  15368. pos = savedPos3;
  15369. }
  15370. var result8 = result7 !== null
  15371. ? (function(mess) {return mess})(result7[3])
  15372. : null;
  15373. if (result8 !== null) {
  15374. var result6 = result8;
  15375. } else {
  15376. var result6 = null;
  15377. pos = savedPos2;
  15378. }
  15379. }
  15380. } else {
  15381. var result5 = null;
  15382. }
  15383. if (result5 !== null) {
  15384. var result1 = [result3, result4, result5];
  15385. } else {
  15386. var result1 = null;
  15387. pos = savedPos1;
  15388. }
  15389. } else {
  15390. var result1 = null;
  15391. pos = savedPos1;
  15392. }
  15393. } else {
  15394. var result1 = null;
  15395. pos = savedPos1;
  15396. }
  15397. var result2 = result1 !== null
  15398. ? (function(send, messages) {
  15399. var cascade = [];
  15400. cascade.push(send);
  15401. for(var i=0;i<messages.length;i++) {
  15402. cascade.push(messages[i]);
  15403. }
  15404. return smalltalk.CascadeNode._new()
  15405. ._receiver_(send._receiver())
  15406. ._nodes_(cascade)
  15407. })(result1[1], result1[2])
  15408. : null;
  15409. if (result2 !== null) {
  15410. var result0 = result2;
  15411. } else {
  15412. var result0 = null;
  15413. pos = savedPos0;
  15414. }
  15415. cache[cacheKey] = {
  15416. nextPos: pos,
  15417. result: result0
  15418. };
  15419. return result0;
  15420. }
  15421. function parse_jsStatement() {
  15422. var cacheKey = 'jsStatement@' + pos;
  15423. var cachedResult = cache[cacheKey];
  15424. if (cachedResult) {
  15425. pos = cachedResult.nextPos;
  15426. return cachedResult.result;
  15427. }
  15428. var savedPos0 = pos;
  15429. var savedPos1 = pos;
  15430. if (input.substr(pos, 1) === "<") {
  15431. var result3 = "<";
  15432. pos += 1;
  15433. } else {
  15434. var result3 = null;
  15435. if (reportMatchFailures) {
  15436. matchFailed("\"<\"");
  15437. }
  15438. }
  15439. if (result3 !== null) {
  15440. var result4 = [];
  15441. var savedPos2 = pos;
  15442. if (input.substr(pos, 2) === ">>") {
  15443. var result9 = ">>";
  15444. pos += 2;
  15445. } else {
  15446. var result9 = null;
  15447. if (reportMatchFailures) {
  15448. matchFailed("\">>\"");
  15449. }
  15450. }
  15451. var result10 = result9 !== null
  15452. ? (function() {return ">"})()
  15453. : null;
  15454. if (result10 !== null) {
  15455. var result8 = result10;
  15456. } else {
  15457. var result8 = null;
  15458. pos = savedPos2;
  15459. }
  15460. if (result8 !== null) {
  15461. var result6 = result8;
  15462. } else {
  15463. if (input.substr(pos).match(/^[^>]/) !== null) {
  15464. var result7 = input.charAt(pos);
  15465. pos++;
  15466. } else {
  15467. var result7 = null;
  15468. if (reportMatchFailures) {
  15469. matchFailed("[^>]");
  15470. }
  15471. }
  15472. if (result7 !== null) {
  15473. var result6 = result7;
  15474. } else {
  15475. var result6 = null;;
  15476. };
  15477. }
  15478. while (result6 !== null) {
  15479. result4.push(result6);
  15480. var savedPos2 = pos;
  15481. if (input.substr(pos, 2) === ">>") {
  15482. var result9 = ">>";
  15483. pos += 2;
  15484. } else {
  15485. var result9 = null;
  15486. if (reportMatchFailures) {
  15487. matchFailed("\">>\"");
  15488. }
  15489. }
  15490. var result10 = result9 !== null
  15491. ? (function() {return ">"})()
  15492. : null;
  15493. if (result10 !== null) {
  15494. var result8 = result10;
  15495. } else {
  15496. var result8 = null;
  15497. pos = savedPos2;
  15498. }
  15499. if (result8 !== null) {
  15500. var result6 = result8;
  15501. } else {
  15502. if (input.substr(pos).match(/^[^>]/) !== null) {
  15503. var result7 = input.charAt(pos);
  15504. pos++;
  15505. } else {
  15506. var result7 = null;
  15507. if (reportMatchFailures) {
  15508. matchFailed("[^>]");
  15509. }
  15510. }
  15511. if (result7 !== null) {
  15512. var result6 = result7;
  15513. } else {
  15514. var result6 = null;;
  15515. };
  15516. }
  15517. }
  15518. if (result4 !== null) {
  15519. if (input.substr(pos, 1) === ">") {
  15520. var result5 = ">";
  15521. pos += 1;
  15522. } else {
  15523. var result5 = null;
  15524. if (reportMatchFailures) {
  15525. matchFailed("\">\"");
  15526. }
  15527. }
  15528. if (result5 !== null) {
  15529. var result1 = [result3, result4, result5];
  15530. } else {
  15531. var result1 = null;
  15532. pos = savedPos1;
  15533. }
  15534. } else {
  15535. var result1 = null;
  15536. pos = savedPos1;
  15537. }
  15538. } else {
  15539. var result1 = null;
  15540. pos = savedPos1;
  15541. }
  15542. var result2 = result1 !== null
  15543. ? (function(val) {
  15544. return smalltalk.JSStatementNode._new()
  15545. ._source_(val.join(""))
  15546. })(result1[1])
  15547. : null;
  15548. if (result2 !== null) {
  15549. var result0 = result2;
  15550. } else {
  15551. var result0 = null;
  15552. pos = savedPos0;
  15553. }
  15554. cache[cacheKey] = {
  15555. nextPos: pos,
  15556. result: result0
  15557. };
  15558. return result0;
  15559. }
  15560. function parse_method() {
  15561. var cacheKey = 'method@' + pos;
  15562. var cachedResult = cache[cacheKey];
  15563. if (cachedResult) {
  15564. pos = cachedResult.nextPos;
  15565. return cachedResult.result;
  15566. }
  15567. var savedPos0 = pos;
  15568. var savedPos1 = pos;
  15569. var result3 = parse_ws();
  15570. if (result3 !== null) {
  15571. var result11 = parse_keywordPattern();
  15572. if (result11 !== null) {
  15573. var result4 = result11;
  15574. } else {
  15575. var result10 = parse_binaryPattern();
  15576. if (result10 !== null) {
  15577. var result4 = result10;
  15578. } else {
  15579. var result9 = parse_unaryPattern();
  15580. if (result9 !== null) {
  15581. var result4 = result9;
  15582. } else {
  15583. var result4 = null;;
  15584. };
  15585. };
  15586. }
  15587. if (result4 !== null) {
  15588. var result5 = parse_ws();
  15589. if (result5 !== null) {
  15590. var result8 = parse_sequence();
  15591. var result6 = result8 !== null ? result8 : '';
  15592. if (result6 !== null) {
  15593. var result7 = parse_ws();
  15594. if (result7 !== null) {
  15595. var result1 = [result3, result4, result5, result6, result7];
  15596. } else {
  15597. var result1 = null;
  15598. pos = savedPos1;
  15599. }
  15600. } else {
  15601. var result1 = null;
  15602. pos = savedPos1;
  15603. }
  15604. } else {
  15605. var result1 = null;
  15606. pos = savedPos1;
  15607. }
  15608. } else {
  15609. var result1 = null;
  15610. pos = savedPos1;
  15611. }
  15612. } else {
  15613. var result1 = null;
  15614. pos = savedPos1;
  15615. }
  15616. var result2 = result1 !== null
  15617. ? (function(pattern, sequence) {
  15618. return smalltalk.MethodNode._new()
  15619. ._selector_(pattern[0])
  15620. ._arguments_(pattern[1])
  15621. ._nodes_([sequence])
  15622. })(result1[1], result1[3])
  15623. : null;
  15624. if (result2 !== null) {
  15625. var result0 = result2;
  15626. } else {
  15627. var result0 = null;
  15628. pos = savedPos0;
  15629. }
  15630. cache[cacheKey] = {
  15631. nextPos: pos,
  15632. result: result0
  15633. };
  15634. return result0;
  15635. }
  15636. function buildErrorMessage() {
  15637. function buildExpected(failuresExpected) {
  15638. failuresExpected.sort();
  15639. var lastFailure = null;
  15640. var failuresExpectedUnique = [];
  15641. for (var i = 0; i < failuresExpected.length; i++) {
  15642. if (failuresExpected[i] !== lastFailure) {
  15643. failuresExpectedUnique.push(failuresExpected[i]);
  15644. lastFailure = failuresExpected[i];
  15645. }
  15646. }
  15647. switch (failuresExpectedUnique.length) {
  15648. case 0:
  15649. return 'end of input';
  15650. case 1:
  15651. return failuresExpectedUnique[0];
  15652. default:
  15653. return failuresExpectedUnique.slice(0, failuresExpectedUnique.length - 1).join(', ')
  15654. + ' or '
  15655. + failuresExpectedUnique[failuresExpectedUnique.length - 1];
  15656. }
  15657. }
  15658. var expected = buildExpected(rightmostMatchFailuresExpected);
  15659. var actualPos = Math.max(pos, rightmostMatchFailuresPos);
  15660. var actual = actualPos < input.length
  15661. ? quote(input.charAt(actualPos))
  15662. : 'end of input';
  15663. return 'Expected ' + expected + ' but ' + actual + ' found.';
  15664. }
  15665. function computeErrorPosition() {
  15666. /*
  15667. * The first idea was to use |String.split| to break the input up to the
  15668. * error position along newlines and derive the line and column from
  15669. * there. However IE's |split| implementation is so broken that it was
  15670. * enough to prevent it.
  15671. */
  15672. var line = 1;
  15673. var column = 1;
  15674. var seenCR = false;
  15675. for (var i = 0; i < rightmostMatchFailuresPos; i++) {
  15676. var ch = input.charAt(i);
  15677. if (ch === '\n') {
  15678. if (!seenCR) { line++; }
  15679. column = 1;
  15680. seenCR = false;
  15681. } else if (ch === '\r' | ch === '\u2028' || ch === '\u2029') {
  15682. line++;
  15683. column = 1;
  15684. seenCR = true;
  15685. } else {
  15686. column++;
  15687. seenCR = false;
  15688. }
  15689. }
  15690. return { line: line, column: column };
  15691. }
  15692. var result = parseFunctions[startRule]();
  15693. /*
  15694. * The parser is now in one of the following three states:
  15695. *
  15696. * 1. The parser successfully parsed the whole input.
  15697. *
  15698. * - |result !== null|
  15699. * - |pos === input.length|
  15700. * - |rightmostMatchFailuresExpected| may or may not contain something
  15701. *
  15702. * 2. The parser successfully parsed only a part of the input.
  15703. *
  15704. * - |result !== null|
  15705. * - |pos < input.length|
  15706. * - |rightmostMatchFailuresExpected| may or may not contain something
  15707. *
  15708. * 3. The parser did not successfully parse any part of the input.
  15709. *
  15710. * - |result === null|
  15711. * - |pos === 0|
  15712. * - |rightmostMatchFailuresExpected| contains at least one failure
  15713. *
  15714. * All code following this comment (including called functions) must
  15715. * handle these states.
  15716. */
  15717. if (result === null || pos !== input.length) {
  15718. var errorPosition = computeErrorPosition();
  15719. throw new this.SyntaxError(
  15720. buildErrorMessage(),
  15721. errorPosition.line,
  15722. errorPosition.column
  15723. );
  15724. }
  15725. return result;
  15726. },
  15727. /* Returns the parser source code. */
  15728. toSource: function() { return this._source; }
  15729. };
  15730. /* Thrown when a parser encounters a syntax error. */
  15731. result.SyntaxError = function(message, line, column) {
  15732. this.name = 'SyntaxError';
  15733. this.message = message;
  15734. this.line = line;
  15735. this.column = column;
  15736. };
  15737. result.SyntaxError.prototype = Error.prototype;
  15738. return result;
  15739. })();
  15740. smalltalk.addPackage('REPL', {});
  15741. smalltalk.addClass('Repl', smalltalk.Object, ['readline', 'interface', 'util'], 'REPL');
  15742. smalltalk.addMethod(
  15743. unescape('_prompt'),
  15744. smalltalk.method({
  15745. selector: unescape('prompt'),
  15746. category: 'accessing',
  15747. fn: function (){
  15748. var self=this;
  15749. return unescape("amber%20%3E%3E%20");
  15750. return self;},
  15751. args: [],
  15752. source: unescape('prompt%0A%09%5E%27amber%20%3E%3E%20%27'),
  15753. messageSends: [],
  15754. referencedClasses: []
  15755. }),
  15756. smalltalk.Repl);
  15757. smalltalk.addMethod(
  15758. unescape('_createInterface'),
  15759. smalltalk.method({
  15760. selector: unescape('createInterface'),
  15761. category: 'actions',
  15762. fn: function (){
  15763. var self=this;
  15764. self['@interface']=smalltalk.send(self['@readline'], "_createInterface_stdout_", [smalltalk.send((typeof process == 'undefined' ? nil : process), "_stdin", []), smalltalk.send((typeof process == 'undefined' ? nil : process), "_stdout", [])]);
  15765. smalltalk.send(self['@interface'], "_on_do_", ["line", (function(buffer){return smalltalk.send(self, "_eval_", [buffer]);})]);
  15766. smalltalk.send(self['@interface'], "_on_do_", ["close", (function(){return smalltalk.send(self, "_close", []);})]);
  15767. smalltalk.send(self, "_setPrompt", []);
  15768. smalltalk.send(self['@interface'], "_prompt", []);
  15769. return self;},
  15770. args: [],
  15771. source: unescape('createInterface%0A%09%22No%20completion%20for%20now%22%0A%09interface%20%3A%3D%20readline%20createInterface%3A%20process%20stdin%20stdout%3A%20process%20stdout.%0A%09interface%20on%3A%20%27line%27%20do%3A%20%5B%3Abuffer%20%20%7C%20self%20eval%3A%20buffer%5D.%0A%09interface%20on%3A%20%27close%27%20do%3A%20%5Bself%20close%5D.%0A%09self%20setPrompt.%0A%09interface%20prompt'),
  15772. messageSends: ["createInterface:stdout:", "stdin", "stdout", "on:do:", "eval:", "close", "setPrompt", "prompt"],
  15773. referencedClasses: []
  15774. }),
  15775. smalltalk.Repl);
  15776. smalltalk.addMethod(
  15777. unescape('_setPrompt'),
  15778. smalltalk.method({
  15779. selector: unescape('setPrompt'),
  15780. category: 'actions',
  15781. fn: function (){
  15782. var self=this;
  15783. smalltalk.send(self['@interface'], "_setPrompt_", [smalltalk.send(self, "_prompt", [])]);
  15784. return self;},
  15785. args: [],
  15786. source: unescape('setPrompt%0A%09interface%20setPrompt%3A%20self%20prompt'),
  15787. messageSends: ["setPrompt:", "prompt"],
  15788. referencedClasses: []
  15789. }),
  15790. smalltalk.Repl);
  15791. smalltalk.addMethod(
  15792. unescape('_close'),
  15793. smalltalk.method({
  15794. selector: unescape('close'),
  15795. category: 'actions',
  15796. fn: function (){
  15797. var self=this;
  15798. smalltalk.send(smalltalk.send((typeof process == 'undefined' ? nil : process), "_stdin", []), "_destroy", []);
  15799. return self;},
  15800. args: [],
  15801. source: unescape('close%0A%09process%20stdin%20destroy'),
  15802. messageSends: ["destroy", "stdin"],
  15803. referencedClasses: []
  15804. }),
  15805. smalltalk.Repl);
  15806. smalltalk.addMethod(
  15807. unescape('_eval_'),
  15808. smalltalk.method({
  15809. selector: unescape('eval%3A'),
  15810. category: 'actions',
  15811. fn: function (buffer){
  15812. var self=this;
  15813. var result=nil;
  15814. ((($receiver = smalltalk.send(buffer, "_isEmpty", [])).klass === smalltalk.Boolean) ? (! $receiver ? (function(){return smalltalk.send(self, "_try_catch_", [(function(){result=smalltalk.send(smalltalk.send((smalltalk.Compiler || Compiler), "_new", []), "_loadExpression_", [buffer]);return smalltalk.send((smalltalk.Transcript || Transcript), "_show_", [result]);}), (function(e){return ((($receiver = smalltalk.send(e, "_isSmalltalkError", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(smalltalk.send((smalltalk.ErrorHandler || ErrorHandler), "_new", []), "_handleError_", [e]);})() : (function(){return smalltalk.send(smalltalk.send((typeof process == 'undefined' ? nil : process), "_stdout", []), "_write_", [smalltalk.send(e, "_jsStack", [])]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(smalltalk.send((smalltalk.ErrorHandler || ErrorHandler), "_new", []), "_handleError_", [e]);}), (function(){return smalltalk.send(smalltalk.send((typeof process == 'undefined' ? nil : process), "_stdout", []), "_write_", [smalltalk.send(e, "_jsStack", [])]);})]));})]);})() : nil) : smalltalk.send($receiver, "_ifFalse_", [(function(){return smalltalk.send(self, "_try_catch_", [(function(){result=smalltalk.send(smalltalk.send((smalltalk.Compiler || Compiler), "_new", []), "_loadExpression_", [buffer]);return smalltalk.send((smalltalk.Transcript || Transcript), "_show_", [result]);}), (function(e){return ((($receiver = smalltalk.send(e, "_isSmalltalkError", [])).klass === smalltalk.Boolean) ? ($receiver ? (function(){return smalltalk.send(smalltalk.send((smalltalk.ErrorHandler || ErrorHandler), "_new", []), "_handleError_", [e]);})() : (function(){return smalltalk.send(smalltalk.send((typeof process == 'undefined' ? nil : process), "_stdout", []), "_write_", [smalltalk.send(e, "_jsStack", [])]);})()) : smalltalk.send($receiver, "_ifTrue_ifFalse_", [(function(){return smalltalk.send(smalltalk.send((smalltalk.ErrorHandler || ErrorHandler), "_new", []), "_handleError_", [e]);}), (function(){return smalltalk.send(smalltalk.send((typeof process == 'undefined' ? nil : process), "_stdout", []), "_write_", [smalltalk.send(e, "_jsStack", [])]);})]));})]);})]));
  15815. smalltalk.send(self['@interface'], "_prompt", []);
  15816. return self;},
  15817. args: ["buffer"],
  15818. source: unescape('eval%3A%20buffer%0A%09%7C%20result%20%7C%0A%09buffer%20isEmpty%20ifFalse%3A%20%5B%0A%09%09self%20try%3A%20%5B%0A%09%09%09result%20%3A%3D%20Compiler%20new%20loadExpression%3A%20buffer.%0A%09%09%09Transcript%20show%3A%20result%5D%0A%09%09catch%3A%20%5B%3Ae%20%7C%0A%09%09%09e%20isSmalltalkError%0A%09%09%09%20%20%20%20ifTrue%3A%20%5BErrorHandler%20new%20handleError%3A%20e%5D%0A%09%09%09%20%20%20%20ifFalse%3A%20%5Bprocess%20stdout%20write%3A%20e%20jsStack%5D%5D%5D.%0A%09interface%20prompt'),
  15819. messageSends: ["ifFalse:", "isEmpty", "try:catch:", "loadExpression:", "new", "show:", "ifTrue:ifFalse:", "isSmalltalkError", "handleError:", "write:", "stdout", "jsStack", "prompt"],
  15820. referencedClasses: ["Compiler", "Transcript", "ErrorHandler"]
  15821. }),
  15822. smalltalk.Repl);
  15823. smalltalk.addMethod(
  15824. unescape('_initialize'),
  15825. smalltalk.method({
  15826. selector: unescape('initialize'),
  15827. category: 'initialization',
  15828. fn: function (){
  15829. var self=this;
  15830. smalltalk.send(self, "_initialize", [], smalltalk.Object);
  15831. self['@readline']=smalltalk.send((typeof require == 'undefined' ? nil : require), "_value_", ["readline"]);
  15832. self['@util']=smalltalk.send((typeof require == 'undefined' ? nil : require), "_value_", ["util"]);
  15833. return self;},
  15834. args: [],
  15835. source: unescape('initialize%0A%09super%20initialize.%0A%09readline%20%3A%3D%20require%20value%3A%20%27readline%27.%0A%09util%20%3A%3D%20require%20value%3A%20%27util%27'),
  15836. messageSends: ["initialize", "value:"],
  15837. referencedClasses: []
  15838. }),
  15839. smalltalk.Repl);
  15840. smalltalk.addMethod(
  15841. unescape('_main'),
  15842. smalltalk.method({
  15843. selector: unescape('main'),
  15844. category: 'not yet classified',
  15845. fn: function (){
  15846. var self=this;
  15847. smalltalk.send(smalltalk.send(self, "_new", []), "_createInterface", []);
  15848. return self;},
  15849. args: [],
  15850. source: unescape('main%0A%09self%20new%20createInterface'),
  15851. messageSends: ["createInterface", "new"],
  15852. referencedClasses: []
  15853. }),
  15854. smalltalk.Repl.klass);
  15855. smalltalk.init(smalltalk.Object);
  15856. smalltalk.classes()._do_(function(each) {each._initialize()});
  15857. /* Similar to jQuery(document).ready() */
  15858. if(this.smalltalkReady) {
  15859. this.smalltalkReady();
  15860. }smalltalk.Repl._main()