12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351535253535354535553565357535853595360536153625363536453655366536753685369537053715372537353745375537653775378537953805381538253835384538553865387538853895390539153925393539453955396539753985399540054015402540354045405540654075408540954105411541254135414541554165417541854195420542154225423542454255426542754285429543054315432543354345435543654375438543954405441544254435444544554465447544854495450545154525453545454555456545754585459546054615462546354645465546654675468546954705471547254735474547554765477547854795480548154825483548454855486548754885489549054915492549354945495549654975498549955005501550255035504550555065507550855095510551155125513551455155516551755185519552055215522552355245525552655275528552955305531553255335534553555365537553855395540554155425543554455455546554755485549555055515552555355545555555655575558555955605561556255635564556555665567556855695570557155725573557455755576557755785579558055815582558355845585558655875588558955905591559255935594559555965597559855995600560156025603560456055606560756085609561056115612561356145615561656175618561956205621562256235624562556265627562856295630563156325633563456355636563756385639564056415642564356445645564656475648564956505651565256535654565556565657565856595660566156625663566456655666566756685669567056715672567356745675567656775678567956805681568256835684568556865687568856895690569156925693569456955696569756985699570057015702570357045705570657075708570957105711571257135714571557165717571857195720572157225723572457255726572757285729573057315732573357345735573657375738573957405741574257435744574557465747574857495750575157525753575457555756575757585759576057615762576357645765576657675768576957705771577257735774577557765777577857795780578157825783578457855786578757885789579057915792579357945795579657975798579958005801580258035804580558065807580858095810581158125813581458155816581758185819582058215822582358245825582658275828582958305831583258335834583558365837583858395840584158425843584458455846584758485849585058515852585358545855585658575858585958605861586258635864586558665867586858695870587158725873587458755876587758785879588058815882588358845885588658875888588958905891589258935894589558965897589858995900590159025903590459055906590759085909591059115912591359145915591659175918591959205921592259235924592559265927592859295930593159325933593459355936593759385939594059415942594359445945594659475948594959505951595259535954595559565957595859595960596159625963596459655966596759685969597059715972597359745975597659775978597959805981598259835984598559865987598859895990599159925993599459955996599759985999600060016002600360046005600660076008600960106011601260136014601560166017601860196020602160226023602460256026602760286029603060316032603360346035603660376038603960406041604260436044604560466047604860496050605160526053605460556056605760586059606060616062606360646065606660676068606960706071607260736074607560766077607860796080608160826083608460856086608760886089609060916092609360946095609660976098609961006101610261036104610561066107610861096110611161126113611461156116611761186119612061216122612361246125612661276128612961306131613261336134613561366137613861396140614161426143614461456146614761486149615061516152615361546155615661576158615961606161616261636164616561666167616861696170617161726173617461756176617761786179618061816182618361846185618661876188618961906191619261936194619561966197619861996200620162026203620462056206620762086209621062116212621362146215621662176218621962206221622262236224622562266227622862296230623162326233623462356236623762386239624062416242624362446245624662476248624962506251625262536254625562566257625862596260626162626263626462656266626762686269627062716272627362746275627662776278627962806281628262836284628562866287628862896290629162926293629462956296629762986299630063016302630363046305630663076308630963106311631263136314631563166317631863196320632163226323632463256326632763286329633063316332633363346335633663376338633963406341634263436344634563466347634863496350635163526353635463556356635763586359636063616362636363646365636663676368636963706371637263736374637563766377637863796380638163826383638463856386638763886389639063916392639363946395639663976398639964006401640264036404640564066407640864096410641164126413641464156416641764186419642064216422642364246425642664276428642964306431643264336434643564366437643864396440644164426443644464456446644764486449645064516452645364546455645664576458645964606461646264636464646564666467646864696470647164726473647464756476647764786479648064816482648364846485648664876488648964906491649264936494649564966497649864996500650165026503650465056506650765086509651065116512651365146515651665176518651965206521652265236524652565266527652865296530653165326533653465356536653765386539654065416542654365446545654665476548654965506551655265536554655565566557655865596560656165626563656465656566656765686569657065716572657365746575657665776578657965806581658265836584658565866587658865896590659165926593659465956596659765986599660066016602660366046605660666076608660966106611661266136614661566166617661866196620662166226623662466256626662766286629663066316632663366346635663666376638663966406641664266436644664566466647664866496650665166526653665466556656665766586659666066616662666366646665666666676668666966706671667266736674667566766677667866796680668166826683668466856686668766886689669066916692669366946695669666976698669967006701670267036704670567066707670867096710671167126713671467156716671767186719672067216722672367246725672667276728672967306731673267336734673567366737673867396740674167426743674467456746674767486749675067516752675367546755675667576758675967606761676267636764676567666767676867696770677167726773677467756776677767786779678067816782678367846785678667876788678967906791679267936794679567966797679867996800680168026803680468056806680768086809681068116812681368146815681668176818681968206821682268236824682568266827682868296830683168326833683468356836683768386839684068416842684368446845684668476848684968506851685268536854685568566857685868596860686168626863686468656866686768686869687068716872687368746875687668776878687968806881688268836884688568866887688868896890689168926893689468956896689768986899690069016902690369046905690669076908690969106911691269136914691569166917691869196920692169226923692469256926692769286929693069316932693369346935693669376938693969406941694269436944694569466947694869496950695169526953695469556956695769586959696069616962696369646965696669676968696969706971697269736974697569766977697869796980698169826983698469856986698769886989699069916992699369946995699669976998699970007001700270037004700570067007700870097010701170127013701470157016701770187019702070217022702370247025702670277028702970307031703270337034703570367037703870397040704170427043704470457046704770487049705070517052705370547055705670577058705970607061706270637064706570667067706870697070707170727073707470757076707770787079708070817082708370847085708670877088708970907091709270937094709570967097709870997100710171027103710471057106710771087109711071117112711371147115711671177118711971207121712271237124712571267127712871297130713171327133713471357136713771387139714071417142714371447145714671477148714971507151715271537154715571567157715871597160716171627163716471657166716771687169717071717172717371747175717671777178717971807181718271837184718571867187718871897190719171927193719471957196719771987199720072017202720372047205720672077208720972107211721272137214721572167217721872197220722172227223722472257226722772287229723072317232723372347235723672377238723972407241724272437244724572467247724872497250725172527253725472557256725772587259726072617262726372647265726672677268726972707271727272737274727572767277727872797280728172827283728472857286728772887289729072917292729372947295729672977298729973007301730273037304730573067307730873097310731173127313731473157316731773187319732073217322732373247325732673277328732973307331733273337334733573367337733873397340734173427343734473457346734773487349735073517352735373547355735673577358735973607361736273637364736573667367736873697370737173727373737473757376737773787379738073817382738373847385738673877388738973907391739273937394739573967397739873997400740174027403740474057406740774087409741074117412741374147415741674177418741974207421742274237424742574267427742874297430743174327433743474357436743774387439744074417442744374447445744674477448744974507451745274537454745574567457745874597460746174627463746474657466746774687469747074717472747374747475747674777478747974807481748274837484748574867487748874897490749174927493749474957496749774987499750075017502750375047505750675077508750975107511751275137514751575167517751875197520752175227523752475257526752775287529753075317532753375347535753675377538753975407541754275437544754575467547754875497550755175527553755475557556755775587559756075617562756375647565756675677568756975707571757275737574757575767577757875797580758175827583758475857586758775887589759075917592759375947595759675977598759976007601760276037604760576067607760876097610761176127613761476157616761776187619762076217622762376247625762676277628762976307631763276337634763576367637763876397640764176427643764476457646764776487649765076517652765376547655765676577658765976607661766276637664766576667667766876697670767176727673767476757676767776787679768076817682768376847685768676877688768976907691769276937694769576967697769876997700770177027703770477057706770777087709771077117712771377147715771677177718771977207721772277237724772577267727772877297730773177327733773477357736773777387739774077417742774377447745774677477748774977507751775277537754775577567757775877597760776177627763776477657766776777687769777077717772777377747775777677777778777977807781778277837784778577867787778877897790779177927793779477957796779777987799780078017802780378047805780678077808780978107811781278137814781578167817781878197820782178227823782478257826782778287829783078317832783378347835783678377838783978407841784278437844784578467847784878497850785178527853785478557856785778587859786078617862786378647865786678677868786978707871787278737874787578767877787878797880788178827883788478857886788778887889789078917892789378947895789678977898789979007901790279037904790579067907790879097910791179127913791479157916791779187919792079217922792379247925792679277928792979307931793279337934793579367937793879397940794179427943794479457946794779487949795079517952795379547955795679577958795979607961796279637964796579667967796879697970797179727973797479757976797779787979798079817982798379847985798679877988798979907991799279937994799579967997799879998000800180028003800480058006800780088009801080118012801380148015801680178018801980208021802280238024802580268027802880298030803180328033803480358036803780388039804080418042804380448045804680478048804980508051805280538054805580568057805880598060806180628063806480658066806780688069807080718072807380748075807680778078807980808081808280838084808580868087808880898090809180928093809480958096809780988099810081018102810381048105810681078108810981108111811281138114811581168117811881198120812181228123812481258126812781288129813081318132813381348135813681378138813981408141814281438144814581468147814881498150815181528153815481558156815781588159816081618162816381648165816681678168816981708171817281738174817581768177817881798180818181828183818481858186818781888189819081918192819381948195819681978198819982008201820282038204820582068207820882098210821182128213821482158216821782188219822082218222822382248225822682278228822982308231823282338234823582368237823882398240824182428243824482458246824782488249825082518252825382548255825682578258825982608261826282638264826582668267826882698270827182728273827482758276827782788279828082818282828382848285828682878288828982908291829282938294829582968297829882998300830183028303830483058306830783088309831083118312831383148315831683178318831983208321832283238324832583268327832883298330833183328333833483358336833783388339834083418342834383448345834683478348834983508351835283538354835583568357835883598360836183628363836483658366836783688369837083718372837383748375837683778378837983808381838283838384838583868387838883898390839183928393839483958396839783988399840084018402840384048405840684078408840984108411841284138414841584168417841884198420842184228423842484258426842784288429843084318432843384348435843684378438843984408441844284438444844584468447844884498450845184528453845484558456845784588459846084618462846384648465846684678468846984708471847284738474847584768477847884798480848184828483848484858486848784888489849084918492849384948495849684978498849985008501850285038504850585068507850885098510851185128513851485158516851785188519852085218522852385248525852685278528852985308531853285338534853585368537853885398540854185428543854485458546854785488549855085518552855385548555855685578558855985608561856285638564856585668567856885698570857185728573857485758576857785788579858085818582858385848585858685878588858985908591859285938594859585968597859885998600860186028603860486058606860786088609861086118612861386148615861686178618861986208621862286238624862586268627862886298630863186328633863486358636863786388639864086418642864386448645864686478648864986508651865286538654865586568657865886598660866186628663866486658666866786688669867086718672867386748675867686778678867986808681868286838684868586868687868886898690869186928693869486958696869786988699870087018702870387048705870687078708870987108711871287138714871587168717871887198720872187228723872487258726872787288729873087318732873387348735873687378738873987408741874287438744874587468747874887498750875187528753875487558756875787588759876087618762876387648765876687678768876987708771877287738774877587768777877887798780878187828783878487858786878787888789879087918792879387948795 |
- var meriyah = (function (exports) {
- 'use strict';
- const errorMessages = {
- [0]: 'Unexpected token',
- [28]: "Unexpected token: '%0'",
- [1]: 'Octal escape sequences are not allowed in strict mode',
- [2]: 'Octal escape sequences are not allowed in template strings',
- [3]: 'Unexpected token `#`',
- [4]: 'Illegal Unicode escape sequence',
- [5]: 'Invalid code point %0',
- [6]: 'Invalid hexadecimal escape sequence',
- [8]: 'Octal literals are not allowed in strict mode',
- [7]: 'Decimal integer literals with a leading zero are forbidden in strict mode',
- [9]: 'Expected number in radix %0',
- [145]: 'Invalid left-hand side assignment to a destructible right-hand side',
- [10]: 'Non-number found after exponent indicator',
- [11]: 'Invalid BigIntLiteral',
- [12]: 'No identifiers allowed directly after numeric literal',
- [13]: 'Escapes \\8 or \\9 are not syntactically valid escapes',
- [14]: 'Unterminated string literal',
- [15]: 'Unterminated template literal',
- [16]: 'Multiline comment was not closed properly',
- [17]: 'The identifier contained dynamic unicode escape that was not closed',
- [18]: "Illegal character '%0'",
- [19]: 'Missing hexadecimal digits',
- [20]: 'Invalid implicit octal',
- [21]: 'Invalid line break in string literal',
- [22]: 'Only unicode escapes are legal in identifier names',
- [23]: "Expected '%0'",
- [24]: 'Invalid left-hand side in assignment',
- [25]: 'Invalid left-hand side in async arrow',
- [26]: 'Calls to super must be in the "constructor" method of a class expression or class declaration that has a superclass',
- [27]: 'Member access on super must be in a method',
- [29]: 'Await expression not allowed in formal parameter',
- [30]: 'Yield expression not allowed in formal parameter',
- [92]: "Unexpected token: 'escaped keyword'",
- [31]: 'Unary expressions as the left operand of an exponentiation expression must be disambiguated with parentheses',
- [119]: 'Async functions can only be declared at the top level or inside a block',
- [32]: 'Unterminated regular expression',
- [33]: 'Unexpected regular expression flag',
- [34]: "Duplicate regular expression flag '%0'",
- [35]: '%0 functions must have exactly %1 argument%2',
- [36]: 'Setter function argument must not be a rest parameter',
- [37]: '%0 declaration must have a name in this context',
- [38]: 'Function name may not contain any reserved words or be eval or arguments in strict mode',
- [39]: 'The rest operator is missing an argument',
- [40]: 'A getter cannot be a generator',
- [41]: 'A computed property name must be followed by a colon or paren',
- [130]: 'Object literal keys that are strings or numbers must be a method or have a colon',
- [43]: 'Found `* async x(){}` but this should be `async * x(){}`',
- [42]: 'Getters and setters can not be generators',
- [44]: "'%0' can not be generator method",
- [45]: "No line break is allowed after '=>'",
- [46]: 'The left-hand side of the arrow can only be destructed through assignment',
- [47]: 'The binding declaration is not destructible',
- [48]: 'Async arrow can not be followed by new expression',
- [49]: "Classes may not have a static property named 'prototype'",
- [50]: 'Class constructor may not be a %0',
- [51]: 'Duplicate constructor method in class',
- [52]: 'Invalid increment/decrement operand',
- [53]: 'Invalid use of `new` keyword on an increment/decrement expression',
- [54]: '`=>` is an invalid assignment target',
- [55]: 'Rest element may not have a trailing comma',
- [56]: 'Missing initializer in %0 declaration',
- [57]: "'for-%0' loop head declarations can not have an initializer",
- [58]: 'Invalid left-hand side in for-%0 loop: Must have a single binding',
- [59]: 'Invalid shorthand property initializer',
- [60]: 'Property name __proto__ appears more than once in object literal',
- [61]: 'Let is disallowed as a lexically bound name',
- [62]: "Invalid use of '%0' inside new expression",
- [63]: "Illegal 'use strict' directive in function with non-simple parameter list",
- [64]: 'Identifier "let" disallowed as left-hand side expression in strict mode',
- [65]: 'Illegal continue statement',
- [66]: 'Illegal break statement',
- [67]: 'Cannot have `let[...]` as a var name in strict mode',
- [68]: 'Invalid destructuring assignment target',
- [69]: 'Rest parameter may not have a default initializer',
- [70]: 'The rest argument must the be last parameter',
- [71]: 'Invalid rest argument',
- [73]: 'In strict mode code, functions can only be declared at top level or inside a block',
- [74]: 'In non-strict mode code, functions can only be declared at top level, inside a block, or as the body of an if statement',
- [75]: 'Without web compatibility enabled functions can not be declared at top level, inside a block, or as the body of an if statement',
- [76]: "Class declaration can't appear in single-statement context",
- [77]: 'Invalid left-hand side in for-%0',
- [78]: 'Invalid assignment in for-%0',
- [79]: 'for await (... of ...) is only valid in async functions and async generators',
- [80]: 'The first token after the template expression should be a continuation of the template',
- [82]: '`let` declaration not allowed here and `let` cannot be a regular var name in strict mode',
- [81]: '`let \n [` is a restricted production at the start of a statement',
- [83]: 'Catch clause requires exactly one parameter, not more (and no trailing comma)',
- [84]: 'Catch clause parameter does not support default values',
- [85]: 'Missing catch or finally after try',
- [86]: 'More than one default clause in switch statement',
- [87]: 'Illegal newline after throw',
- [88]: 'Strict mode code may not include a with statement',
- [89]: 'Illegal return statement',
- [90]: 'The left hand side of the for-header binding declaration is not destructible',
- [91]: 'new.target only allowed within functions',
- [92]: "'Unexpected token: 'escaped keyword'",
- [93]: "'#' not followed by identifier",
- [99]: 'Invalid keyword',
- [98]: "Can not use 'let' as a class name",
- [97]: "'A lexical declaration can't define a 'let' binding",
- [96]: 'Can not use `let` as variable name in strict mode',
- [94]: "'%0' may not be used as an identifier in this context",
- [95]: 'Await is only valid in async functions',
- [100]: 'The %0 keyword can only be used with the module goal',
- [101]: 'Unicode codepoint must not be greater than 0x10FFFF',
- [102]: '%0 source must be string',
- [103]: 'Only a identifier can be used to indicate alias',
- [104]: "Only '*' or '{...}' can be imported after default",
- [105]: 'Trailing decorator may be followed by method',
- [106]: "Decorators can't be used with a constructor",
- [107]: "'%0' may not be used as an identifier in this context",
- [108]: 'HTML comments are only allowed with web compatibility (Annex B)',
- [109]: "The identifier 'let' must not be in expression position in strict mode",
- [110]: 'Cannot assign to `eval` and `arguments` in strict mode',
- [111]: "The left-hand side of a for-of loop may not start with 'let'",
- [112]: 'Block body arrows can not be immediately invoked without a group',
- [113]: 'Block body arrows can not be immediately accessed without a group',
- [114]: 'Unexpected strict mode reserved word',
- [115]: 'Unexpected eval or arguments in strict mode',
- [116]: 'Decorators must not be followed by a semicolon',
- [117]: 'Calling delete on expression not allowed in strict mode',
- [118]: 'Pattern can not have a tail',
- [120]: 'Can not have a `yield` expression on the left side of a ternary',
- [121]: 'An arrow function can not have a postfix update operator',
- [122]: 'Invalid object literal key character after generator star',
- [123]: 'Private fields can not be deleted',
- [125]: 'Classes may not have a field called constructor',
- [124]: 'Classes may not have a private element named constructor',
- [126]: 'A class field initializer may not contain arguments',
- [127]: 'Generators can only be declared at the top level or inside a block',
- [128]: 'Async methods are a restricted production and cannot have a newline following it',
- [129]: 'Unexpected character after object literal property name',
- [131]: 'Invalid key token',
- [132]: "Label '%0' has already been declared",
- [133]: 'continue statement must be nested within an iteration statement',
- [134]: "Undefined label '%0'",
- [135]: 'Trailing comma is disallowed inside import(...) arguments',
- [136]: 'import() requires exactly one argument',
- [137]: 'Cannot use new with import(...)',
- [138]: '... is not allowed in import()',
- [139]: "Expected '=>'",
- [140]: "Duplicate binding '%0'",
- [141]: "Cannot export a duplicate name '%0'",
- [144]: 'Duplicate %0 for-binding',
- [142]: "Exported binding '%0' needs to refer to a top-level declared variable",
- [143]: 'Unexpected private field',
- [147]: 'Numeric separators are not allowed at the end of numeric literals',
- [146]: 'Only one underscore is allowed as numeric separator',
- [148]: 'JSX value should be either an expression or a quoted JSX text',
- [149]: 'Expected corresponding JSX closing tag for %0',
- [150]: 'Adjacent JSX elements must be wrapped in an enclosing tag',
- [151]: "JSX attributes must only be assigned a non-empty 'expression'",
- [152]: "'%0' has already been declared",
- [153]: "'%0' shadowed a catch clause binding",
- [154]: 'Dot property must be an identifier',
- [155]: 'Encountered invalid input after spread/rest argument',
- [156]: 'Catch without try',
- [157]: 'Finally without try',
- [158]: 'Expected corresponding closing tag for JSX fragment',
- [159]: 'Coalescing and logical operators used together in the same expression must be disambiguated with parentheses',
- [160]: 'Invalid tagged template on optional chain',
- [161]: 'Invalid optional chain from super property',
- [162]: 'Invalid optional chain from new expression',
- [163]: 'Cannot use "import.meta" outside a module',
- [164]: 'Leading decorators must be attached to a class declaration'
- };
- class ParseError extends SyntaxError {
- constructor(startindex, line, column, type, ...params) {
- const message = '[' + line + ':' + column + ']: ' + errorMessages[type].replace(/%(\d+)/g, (_, i) => params[i]);
- super(`${message}`);
- this.index = startindex;
- this.line = line;
- this.column = column;
- this.description = message;
- this.loc = {
- line,
- column
- };
- }
- }
- function report(parser, type, ...params) {
- throw new ParseError(parser.index, parser.line, parser.column, type, ...params);
- }
- function reportScopeError(scope) {
- throw new ParseError(scope.index, scope.line, scope.column, scope.type, scope.params);
- }
- function reportMessageAt(index, line, column, type, ...params) {
- throw new ParseError(index, line, column, type, ...params);
- }
- function reportScannerError(index, line, column, type) {
- throw new ParseError(index, line, column, type);
- }
- const unicodeLookup = ((compressed, lookup) => {
- const result = new Uint32Array(104448);
- let index = 0;
- let subIndex = 0;
- while (index < 3540) {
- const inst = compressed[index++];
- if (inst < 0) {
- subIndex -= inst;
- }
- else {
- let code = compressed[index++];
- if (inst & 2)
- code = lookup[code];
- if (inst & 1) {
- result.fill(code, subIndex, subIndex += compressed[index++]);
- }
- else {
- result[subIndex++] = code;
- }
- }
- }
- return result;
- })([-1, 2, 24, 2, 25, 2, 5, -1, 0, 77595648, 3, 44, 2, 3, 0, 14, 2, 57, 2, 58, 3, 0, 3, 0, 3168796671, 0, 4294956992, 2, 1, 2, 0, 2, 59, 3, 0, 4, 0, 4294966523, 3, 0, 4, 2, 16, 2, 60, 2, 0, 0, 4294836735, 0, 3221225471, 0, 4294901942, 2, 61, 0, 134152192, 3, 0, 2, 0, 4294951935, 3, 0, 2, 0, 2683305983, 0, 2684354047, 2, 17, 2, 0, 0, 4294961151, 3, 0, 2, 2, 19, 2, 0, 0, 608174079, 2, 0, 2, 131, 2, 6, 2, 56, -1, 2, 37, 0, 4294443263, 2, 1, 3, 0, 3, 0, 4294901711, 2, 39, 0, 4089839103, 0, 2961209759, 0, 1342439375, 0, 4294543342, 0, 3547201023, 0, 1577204103, 0, 4194240, 0, 4294688750, 2, 2, 0, 80831, 0, 4261478351, 0, 4294549486, 2, 2, 0, 2967484831, 0, 196559, 0, 3594373100, 0, 3288319768, 0, 8469959, 2, 194, 2, 3, 0, 3825204735, 0, 123747807, 0, 65487, 0, 4294828015, 0, 4092591615, 0, 1080049119, 0, 458703, 2, 3, 2, 0, 0, 2163244511, 0, 4227923919, 0, 4236247022, 2, 66, 0, 4284449919, 0, 851904, 2, 4, 2, 11, 0, 67076095, -1, 2, 67, 0, 1073741743, 0, 4093591391, -1, 0, 50331649, 0, 3265266687, 2, 32, 0, 4294844415, 0, 4278190047, 2, 18, 2, 129, -1, 3, 0, 2, 2, 21, 2, 0, 2, 9, 2, 0, 2, 14, 2, 15, 3, 0, 10, 2, 69, 2, 0, 2, 70, 2, 71, 2, 72, 2, 0, 2, 73, 2, 0, 2, 10, 0, 261632, 2, 23, 3, 0, 2, 2, 12, 2, 4, 3, 0, 18, 2, 74, 2, 5, 3, 0, 2, 2, 75, 0, 2088959, 2, 27, 2, 8, 0, 909311, 3, 0, 2, 0, 814743551, 2, 41, 0, 67057664, 3, 0, 2, 2, 40, 2, 0, 2, 28, 2, 0, 2, 29, 2, 7, 0, 268374015, 2, 26, 2, 49, 2, 0, 2, 76, 0, 134153215, -1, 2, 6, 2, 0, 2, 7, 0, 2684354559, 0, 67044351, 0, 3221160064, 0, 1, -1, 3, 0, 2, 2, 42, 0, 1046528, 3, 0, 3, 2, 8, 2, 0, 2, 51, 0, 4294960127, 2, 9, 2, 38, 2, 10, 0, 4294377472, 2, 11, 3, 0, 7, 0, 4227858431, 3, 0, 8, 2, 12, 2, 0, 2, 78, 2, 9, 2, 0, 2, 79, 2, 80, 2, 81, -1, 2, 124, 0, 1048577, 2, 82, 2, 13, -1, 2, 13, 0, 131042, 2, 83, 2, 84, 2, 85, 2, 0, 2, 33, -83, 2, 0, 2, 53, 2, 7, 3, 0, 4, 0, 1046559, 2, 0, 2, 14, 2, 0, 0, 2147516671, 2, 20, 3, 86, 2, 2, 0, -16, 2, 87, 0, 524222462, 2, 4, 2, 0, 0, 4269801471, 2, 4, 2, 0, 2, 15, 2, 77, 2, 16, 3, 0, 2, 2, 47, 2, 0, -1, 2, 17, -16, 3, 0, 206, -2, 3, 0, 655, 2, 18, 3, 0, 36, 2, 68, -1, 2, 17, 2, 9, 3, 0, 8, 2, 89, 2, 121, 2, 0, 0, 3220242431, 3, 0, 3, 2, 19, 2, 90, 2, 91, 3, 0, 2, 2, 92, 2, 0, 2, 93, 2, 94, 2, 0, 0, 4351, 2, 0, 2, 8, 3, 0, 2, 0, 67043391, 0, 3909091327, 2, 0, 2, 22, 2, 8, 2, 18, 3, 0, 2, 0, 67076097, 2, 7, 2, 0, 2, 20, 0, 67059711, 0, 4236247039, 3, 0, 2, 0, 939524103, 0, 8191999, 2, 97, 2, 98, 2, 15, 2, 21, 3, 0, 3, 0, 67057663, 3, 0, 349, 2, 99, 2, 100, 2, 6, -264, 3, 0, 11, 2, 22, 3, 0, 2, 2, 31, -1, 0, 3774349439, 2, 101, 2, 102, 3, 0, 2, 2, 19, 2, 103, 3, 0, 10, 2, 9, 2, 17, 2, 0, 2, 45, 2, 0, 2, 30, 2, 104, 2, 23, 0, 1638399, 2, 172, 2, 105, 3, 0, 3, 2, 18, 2, 24, 2, 25, 2, 5, 2, 26, 2, 0, 2, 7, 2, 106, -1, 2, 107, 2, 108, 2, 109, -1, 3, 0, 3, 2, 11, -2, 2, 0, 2, 27, -3, 2, 150, -4, 2, 18, 2, 0, 2, 35, 0, 1, 2, 0, 2, 62, 2, 28, 2, 11, 2, 9, 2, 0, 2, 110, -1, 3, 0, 4, 2, 9, 2, 21, 2, 111, 2, 6, 2, 0, 2, 112, 2, 0, 2, 48, -4, 3, 0, 9, 2, 20, 2, 29, 2, 30, -4, 2, 113, 2, 114, 2, 29, 2, 20, 2, 7, -2, 2, 115, 2, 29, 2, 31, -2, 2, 0, 2, 116, -2, 0, 4277137519, 0, 2269118463, -1, 3, 18, 2, -1, 2, 32, 2, 36, 2, 0, 3, 29, 2, 2, 34, 2, 19, -3, 3, 0, 2, 2, 33, -1, 2, 0, 2, 34, 2, 0, 2, 34, 2, 0, 2, 46, -10, 2, 0, 0, 203775, -2, 2, 18, 2, 43, 2, 35, -2, 2, 17, 2, 117, 2, 20, 3, 0, 2, 2, 36, 0, 2147549120, 2, 0, 2, 11, 2, 17, 2, 135, 2, 0, 2, 37, 2, 52, 0, 5242879, 3, 0, 2, 0, 402644511, -1, 2, 120, 0, 1090519039, -2, 2, 122, 2, 38, 2, 0, 0, 67045375, 2, 39, 0, 4226678271, 0, 3766565279, 0, 2039759, -4, 3, 0, 2, 0, 3288270847, 0, 3, 3, 0, 2, 0, 67043519, -5, 2, 0, 0, 4282384383, 0, 1056964609, -1, 3, 0, 2, 0, 67043345, -1, 2, 0, 2, 40, 2, 41, -1, 2, 10, 2, 42, -6, 2, 0, 2, 11, -3, 3, 0, 2, 0, 2147484671, 2, 125, 0, 4190109695, 2, 50, -2, 2, 126, 0, 4244635647, 0, 27, 2, 0, 2, 7, 2, 43, 2, 0, 2, 63, -1, 2, 0, 2, 40, -8, 2, 54, 2, 44, 0, 67043329, 2, 127, 2, 45, 0, 8388351, -2, 2, 128, 0, 3028287487, 2, 46, 2, 130, 0, 33259519, 2, 41, -9, 2, 20, -5, 2, 64, -2, 3, 0, 28, 2, 31, -3, 3, 0, 3, 2, 47, 3, 0, 6, 2, 48, -85, 3, 0, 33, 2, 47, -126, 3, 0, 18, 2, 36, -269, 3, 0, 17, 2, 40, 2, 7, 2, 41, -2, 2, 17, 2, 49, 2, 0, 2, 20, 2, 50, 2, 132, 2, 23, -21, 3, 0, 2, -4, 3, 0, 2, 0, 4294936575, 2, 0, 0, 4294934783, -2, 0, 196635, 3, 0, 191, 2, 51, 3, 0, 38, 2, 29, -1, 2, 33, -279, 3, 0, 8, 2, 7, -1, 2, 133, 2, 52, 3, 0, 11, 2, 6, -72, 3, 0, 3, 2, 134, 0, 1677656575, -166, 0, 4161266656, 0, 4071, 0, 15360, -4, 0, 28, -13, 3, 0, 2, 2, 37, 2, 0, 2, 136, 2, 137, 2, 55, 2, 0, 2, 138, 2, 139, 2, 140, 3, 0, 10, 2, 141, 2, 142, 2, 15, 3, 37, 2, 3, 53, 2, 3, 54, 2, 0, 4294954999, 2, 0, -16, 2, 0, 2, 88, 2, 0, 0, 2105343, 0, 4160749584, 0, 65534, -42, 0, 4194303871, 0, 2011, -6, 2, 0, 0, 1073684479, 0, 17407, -11, 2, 0, 2, 31, -40, 3, 0, 6, 0, 8323103, -1, 3, 0, 2, 2, 42, -37, 2, 55, 2, 144, 2, 145, 2, 146, 2, 147, 2, 148, -105, 2, 24, -32, 3, 0, 1334, 2, 9, -1, 3, 0, 129, 2, 27, 3, 0, 6, 2, 9, 3, 0, 180, 2, 149, 3, 0, 233, 0, 1, -96, 3, 0, 16, 2, 9, -47, 3, 0, 154, 2, 56, -22381, 3, 0, 7, 2, 23, -6130, 3, 5, 2, -1, 0, 69207040, 3, 44, 2, 3, 0, 14, 2, 57, 2, 58, -3, 0, 3168731136, 0, 4294956864, 2, 1, 2, 0, 2, 59, 3, 0, 4, 0, 4294966275, 3, 0, 4, 2, 16, 2, 60, 2, 0, 2, 33, -1, 2, 17, 2, 61, -1, 2, 0, 2, 56, 0, 4294885376, 3, 0, 2, 0, 3145727, 0, 2617294944, 0, 4294770688, 2, 23, 2, 62, 3, 0, 2, 0, 131135, 2, 95, 0, 70256639, 0, 71303167, 0, 272, 2, 40, 2, 56, -1, 2, 37, 2, 30, -1, 2, 96, 2, 63, 0, 4278255616, 0, 4294836227, 0, 4294549473, 0, 600178175, 0, 2952806400, 0, 268632067, 0, 4294543328, 0, 57540095, 0, 1577058304, 0, 1835008, 0, 4294688736, 2, 65, 2, 64, 0, 33554435, 2, 123, 2, 65, 2, 151, 0, 131075, 0, 3594373096, 0, 67094296, 2, 64, -1, 0, 4294828000, 0, 603979263, 2, 160, 0, 3, 0, 4294828001, 0, 602930687, 2, 183, 0, 393219, 0, 4294828016, 0, 671088639, 0, 2154840064, 0, 4227858435, 0, 4236247008, 2, 66, 2, 36, -1, 2, 4, 0, 917503, 2, 36, -1, 2, 67, 0, 537788335, 0, 4026531935, -1, 0, 1, -1, 2, 32, 2, 68, 0, 7936, -3, 2, 0, 0, 2147485695, 0, 1010761728, 0, 4292984930, 0, 16387, 2, 0, 2, 14, 2, 15, 3, 0, 10, 2, 69, 2, 0, 2, 70, 2, 71, 2, 72, 2, 0, 2, 73, 2, 0, 2, 11, -1, 2, 23, 3, 0, 2, 2, 12, 2, 4, 3, 0, 18, 2, 74, 2, 5, 3, 0, 2, 2, 75, 0, 253951, 3, 19, 2, 0, 122879, 2, 0, 2, 8, 0, 276824064, -2, 3, 0, 2, 2, 40, 2, 0, 0, 4294903295, 2, 0, 2, 29, 2, 7, -1, 2, 17, 2, 49, 2, 0, 2, 76, 2, 41, -1, 2, 20, 2, 0, 2, 27, -2, 0, 128, -2, 2, 77, 2, 8, 0, 4064, -1, 2, 119, 0, 4227907585, 2, 0, 2, 118, 2, 0, 2, 48, 2, 173, 2, 9, 2, 38, 2, 10, -1, 0, 74440192, 3, 0, 6, -2, 3, 0, 8, 2, 12, 2, 0, 2, 78, 2, 9, 2, 0, 2, 79, 2, 80, 2, 81, -3, 2, 82, 2, 13, -3, 2, 83, 2, 84, 2, 85, 2, 0, 2, 33, -83, 2, 0, 2, 53, 2, 7, 3, 0, 4, 0, 817183, 2, 0, 2, 14, 2, 0, 0, 33023, 2, 20, 3, 86, 2, -17, 2, 87, 0, 524157950, 2, 4, 2, 0, 2, 88, 2, 4, 2, 0, 2, 15, 2, 77, 2, 16, 3, 0, 2, 2, 47, 2, 0, -1, 2, 17, -16, 3, 0, 206, -2, 3, 0, 655, 2, 18, 3, 0, 36, 2, 68, -1, 2, 17, 2, 9, 3, 0, 8, 2, 89, 0, 3072, 2, 0, 0, 2147516415, 2, 9, 3, 0, 2, 2, 23, 2, 90, 2, 91, 3, 0, 2, 2, 92, 2, 0, 2, 93, 2, 94, 0, 4294965179, 0, 7, 2, 0, 2, 8, 2, 91, 2, 8, -1, 0, 1761345536, 2, 95, 0, 4294901823, 2, 36, 2, 18, 2, 96, 2, 34, 2, 166, 0, 2080440287, 2, 0, 2, 33, 2, 143, 0, 3296722943, 2, 0, 0, 1046675455, 0, 939524101, 0, 1837055, 2, 97, 2, 98, 2, 15, 2, 21, 3, 0, 3, 0, 7, 3, 0, 349, 2, 99, 2, 100, 2, 6, -264, 3, 0, 11, 2, 22, 3, 0, 2, 2, 31, -1, 0, 2700607615, 2, 101, 2, 102, 3, 0, 2, 2, 19, 2, 103, 3, 0, 10, 2, 9, 2, 17, 2, 0, 2, 45, 2, 0, 2, 30, 2, 104, -3, 2, 105, 3, 0, 3, 2, 18, -1, 3, 5, 2, 2, 26, 2, 0, 2, 7, 2, 106, -1, 2, 107, 2, 108, 2, 109, -1, 3, 0, 3, 2, 11, -2, 2, 0, 2, 27, -8, 2, 18, 2, 0, 2, 35, -1, 2, 0, 2, 62, 2, 28, 2, 29, 2, 9, 2, 0, 2, 110, -1, 3, 0, 4, 2, 9, 2, 17, 2, 111, 2, 6, 2, 0, 2, 112, 2, 0, 2, 48, -4, 3, 0, 9, 2, 20, 2, 29, 2, 30, -4, 2, 113, 2, 114, 2, 29, 2, 20, 2, 7, -2, 2, 115, 2, 29, 2, 31, -2, 2, 0, 2, 116, -2, 0, 4277075969, 2, 29, -1, 3, 18, 2, -1, 2, 32, 2, 117, 2, 0, 3, 29, 2, 2, 34, 2, 19, -3, 3, 0, 2, 2, 33, -1, 2, 0, 2, 34, 2, 0, 2, 34, 2, 0, 2, 48, -10, 2, 0, 0, 197631, -2, 2, 18, 2, 43, 2, 118, -2, 2, 17, 2, 117, 2, 20, 2, 119, 2, 51, -2, 2, 119, 2, 23, 2, 17, 2, 33, 2, 119, 2, 36, 0, 4294901904, 0, 4718591, 2, 119, 2, 34, 0, 335544350, -1, 2, 120, 2, 121, -2, 2, 122, 2, 38, 2, 7, -1, 2, 123, 2, 65, 0, 3758161920, 0, 3, -4, 2, 0, 2, 27, 0, 2147485568, 0, 3, 2, 0, 2, 23, 0, 176, -5, 2, 0, 2, 47, 2, 186, -1, 2, 0, 2, 23, 2, 197, -1, 2, 0, 0, 16779263, -2, 2, 11, -7, 2, 0, 2, 121, -3, 3, 0, 2, 2, 124, 2, 125, 0, 2147549183, 0, 2, -2, 2, 126, 2, 35, 0, 10, 0, 4294965249, 0, 67633151, 0, 4026597376, 2, 0, 0, 536871935, -1, 2, 0, 2, 40, -8, 2, 54, 2, 47, 0, 1, 2, 127, 2, 23, -3, 2, 128, 2, 35, 2, 129, 2, 130, 0, 16778239, -10, 2, 34, -5, 2, 64, -2, 3, 0, 28, 2, 31, -3, 3, 0, 3, 2, 47, 3, 0, 6, 2, 48, -85, 3, 0, 33, 2, 47, -126, 3, 0, 18, 2, 36, -269, 3, 0, 17, 2, 40, 2, 7, -3, 2, 17, 2, 131, 2, 0, 2, 23, 2, 48, 2, 132, 2, 23, -21, 3, 0, 2, -4, 3, 0, 2, 0, 67583, -1, 2, 103, -2, 0, 11, 3, 0, 191, 2, 51, 3, 0, 38, 2, 29, -1, 2, 33, -279, 3, 0, 8, 2, 7, -1, 2, 133, 2, 52, 3, 0, 11, 2, 6, -72, 3, 0, 3, 2, 134, 2, 135, -187, 3, 0, 2, 2, 37, 2, 0, 2, 136, 2, 137, 2, 55, 2, 0, 2, 138, 2, 139, 2, 140, 3, 0, 10, 2, 141, 2, 142, 2, 15, 3, 37, 2, 3, 53, 2, 3, 54, 2, 2, 143, -73, 2, 0, 0, 1065361407, 0, 16384, -11, 2, 0, 2, 121, -40, 3, 0, 6, 2, 117, -1, 3, 0, 2, 0, 2063, -37, 2, 55, 2, 144, 2, 145, 2, 146, 2, 147, 2, 148, -138, 3, 0, 1334, 2, 9, -1, 3, 0, 129, 2, 27, 3, 0, 6, 2, 9, 3, 0, 180, 2, 149, 3, 0, 233, 0, 1, -96, 3, 0, 16, 2, 9, -47, 3, 0, 154, 2, 56, -28517, 2, 0, 0, 1, -1, 2, 124, 2, 0, 0, 8193, -21, 2, 193, 0, 10255, 0, 4, -11, 2, 64, 2, 171, -1, 0, 71680, -1, 2, 161, 0, 4292900864, 0, 805306431, -5, 2, 150, -1, 2, 157, -1, 0, 6144, -2, 2, 127, -1, 2, 154, -1, 0, 2147532800, 2, 151, 2, 165, 2, 0, 2, 164, 0, 524032, 0, 4, -4, 2, 190, 0, 205128192, 0, 1333757536, 0, 2147483696, 0, 423953, 0, 747766272, 0, 2717763192, 0, 4286578751, 0, 278545, 2, 152, 0, 4294886464, 0, 33292336, 0, 417809, 2, 152, 0, 1327482464, 0, 4278190128, 0, 700594195, 0, 1006647527, 0, 4286497336, 0, 4160749631, 2, 153, 0, 469762560, 0, 4171219488, 0, 8323120, 2, 153, 0, 202375680, 0, 3214918176, 0, 4294508592, 2, 153, -1, 0, 983584, 0, 48, 0, 58720273, 0, 3489923072, 0, 10517376, 0, 4293066815, 0, 1, 0, 2013265920, 2, 177, 2, 0, 0, 2089, 0, 3221225552, 0, 201375904, 2, 0, -2, 0, 256, 0, 122880, 0, 16777216, 2, 150, 0, 4160757760, 2, 0, -6, 2, 167, -11, 0, 3263218176, -1, 0, 49664, 0, 2160197632, 0, 8388802, -1, 0, 12713984, -1, 2, 154, 2, 159, 2, 178, -2, 2, 162, -20, 0, 3758096385, -2, 2, 155, 0, 4292878336, 2, 90, 2, 169, 0, 4294057984, -2, 2, 163, 2, 156, 2, 175, -2, 2, 155, -1, 2, 182, -1, 2, 170, 2, 124, 0, 4026593280, 0, 14, 0, 4292919296, -1, 2, 158, 0, 939588608, -1, 0, 805306368, -1, 2, 124, 0, 1610612736, 2, 156, 2, 157, 2, 4, 2, 0, -2, 2, 158, 2, 159, -3, 0, 267386880, -1, 2, 160, 0, 7168, -1, 0, 65024, 2, 154, 2, 161, 2, 179, -7, 2, 168, -8, 2, 162, -1, 0, 1426112704, 2, 163, -1, 2, 164, 0, 271581216, 0, 2149777408, 2, 23, 2, 161, 2, 124, 0, 851967, 2, 180, -1, 2, 23, 2, 181, -4, 2, 158, -20, 2, 195, 2, 165, -56, 0, 3145728, 2, 185, -4, 2, 166, 2, 124, -4, 0, 32505856, -1, 2, 167, -1, 0, 2147385088, 2, 90, 1, 2155905152, 2, -3, 2, 103, 2, 0, 2, 168, -2, 2, 169, -6, 2, 170, 0, 4026597375, 0, 1, -1, 0, 1, -1, 2, 171, -3, 2, 117, 2, 64, -2, 2, 166, -2, 2, 176, 2, 124, -878, 2, 159, -36, 2, 172, -1, 2, 201, -10, 2, 188, -5, 2, 174, -6, 0, 4294965251, 2, 27, -1, 2, 173, -1, 2, 174, -2, 0, 4227874752, -3, 0, 2146435072, 2, 159, -2, 0, 1006649344, 2, 124, -1, 2, 90, 0, 201375744, -3, 0, 134217720, 2, 90, 0, 4286677377, 0, 32896, -1, 2, 158, -3, 2, 175, -349, 2, 176, 0, 1920, 2, 177, 3, 0, 264, -11, 2, 157, -2, 2, 178, 2, 0, 0, 520617856, 0, 2692743168, 0, 36, -3, 0, 524284, -11, 2, 23, -1, 2, 187, -1, 2, 184, 0, 3221291007, 2, 178, -1, 2, 202, 0, 2158720, -3, 2, 159, 0, 1, -4, 2, 124, 0, 3808625411, 0, 3489628288, 2, 200, 0, 1207959680, 0, 3221274624, 2, 0, -3, 2, 179, 0, 120, 0, 7340032, -2, 2, 180, 2, 4, 2, 23, 2, 163, 3, 0, 4, 2, 159, -1, 2, 181, 2, 177, -1, 0, 8176, 2, 182, 2, 179, 2, 183, -1, 0, 4290773232, 2, 0, -4, 2, 163, 2, 189, 0, 15728640, 2, 177, -1, 2, 161, -1, 0, 4294934512, 3, 0, 4, -9, 2, 90, 2, 170, 2, 184, 3, 0, 4, 0, 704, 0, 1849688064, 2, 185, -1, 2, 124, 0, 4294901887, 2, 0, 0, 130547712, 0, 1879048192, 2, 199, 3, 0, 2, -1, 2, 186, 2, 187, -1, 0, 17829776, 0, 2025848832, 0, 4261477888, -2, 2, 0, -1, 0, 4286580608, -1, 0, 29360128, 2, 192, 0, 16252928, 0, 3791388672, 2, 38, 3, 0, 2, -2, 2, 196, 2, 0, -1, 2, 103, -1, 0, 66584576, -1, 2, 191, 3, 0, 9, 2, 124, -1, 0, 4294755328, 3, 0, 2, -1, 2, 161, 2, 178, 3, 0, 2, 2, 23, 2, 188, 2, 90, -2, 0, 245760, 0, 2147418112, -1, 2, 150, 2, 203, 0, 4227923456, -1, 2, 164, 2, 161, 2, 90, -3, 0, 4292870145, 0, 262144, 2, 124, 3, 0, 2, 0, 1073758848, 2, 189, -1, 0, 4227921920, 2, 190, 0, 68289024, 0, 528402016, 0, 4292927536, 3, 0, 4, -2, 0, 268435456, 2, 91, -2, 2, 191, 3, 0, 5, -1, 2, 192, 2, 163, 2, 0, -2, 0, 4227923936, 2, 62, -1, 2, 155, 2, 95, 2, 0, 2, 154, 2, 158, 3, 0, 6, -1, 2, 177, 3, 0, 3, -2, 0, 2146959360, 0, 9440640, 0, 104857600, 0, 4227923840, 3, 0, 2, 0, 768, 2, 193, 2, 77, -2, 2, 161, -2, 2, 119, -1, 2, 155, 3, 0, 8, 0, 512, 0, 8388608, 2, 194, 2, 172, 2, 187, 0, 4286578944, 3, 0, 2, 0, 1152, 0, 1266679808, 2, 191, 0, 576, 0, 4261707776, 2, 95, 3, 0, 9, 2, 155, 3, 0, 5, 2, 16, -1, 0, 2147221504, -28, 2, 178, 3, 0, 3, -3, 0, 4292902912, -6, 2, 96, 3, 0, 85, -33, 0, 4294934528, 3, 0, 126, -18, 2, 195, 3, 0, 269, -17, 2, 155, 2, 124, 2, 198, 3, 0, 2, 2, 23, 0, 4290822144, -2, 0, 67174336, 0, 520093700, 2, 17, 3, 0, 21, -2, 2, 179, 3, 0, 3, -2, 0, 30720, -1, 0, 32512, 3, 0, 2, 0, 4294770656, -191, 2, 174, -38, 2, 170, 2, 0, 2, 196, 3, 0, 279, -8, 2, 124, 2, 0, 0, 4294508543, 0, 65295, -11, 2, 177, 3, 0, 72, -3, 0, 3758159872, 0, 201391616, 3, 0, 155, -7, 2, 170, -1, 0, 384, -1, 0, 133693440, -3, 2, 196, -2, 2, 26, 3, 0, 4, 2, 169, -2, 2, 90, 2, 155, 3, 0, 4, -2, 2, 164, -1, 2, 150, 0, 335552923, 2, 197, -1, 0, 538974272, 0, 2214592512, 0, 132000, -10, 0, 192, -8, 0, 12288, -21, 0, 134213632, 0, 4294901761, 3, 0, 42, 0, 100663424, 0, 4294965284, 3, 0, 6, -1, 0, 3221282816, 2, 198, 3, 0, 11, -1, 2, 199, 3, 0, 40, -6, 0, 4286578784, 2, 0, -2, 0, 1006694400, 3, 0, 24, 2, 35, -1, 2, 94, 3, 0, 2, 0, 1, 2, 163, 3, 0, 6, 2, 197, 0, 4110942569, 0, 1432950139, 0, 2701658217, 0, 4026532864, 0, 4026532881, 2, 0, 2, 45, 3, 0, 8, -1, 2, 158, -2, 2, 169, 0, 98304, 0, 65537, 2, 170, -5, 0, 4294950912, 2, 0, 2, 118, 0, 65528, 2, 177, 0, 4294770176, 2, 26, 3, 0, 4, -30, 2, 174, 0, 3758153728, -3, 2, 169, -2, 2, 155, 2, 188, 2, 158, -1, 2, 191, -1, 2, 161, 0, 4294754304, 3, 0, 2, -3, 0, 33554432, -2, 2, 200, -3, 2, 169, 0, 4175478784, 2, 201, 0, 4286643712, 0, 4286644216, 2, 0, -4, 2, 202, -1, 2, 165, 0, 4227923967, 3, 0, 32, -1334, 2, 163, 2, 0, -129, 2, 94, -6, 2, 163, -180, 2, 203, -233, 2, 4, 3, 0, 96, -16, 2, 163, 3, 0, 47, -154, 2, 165, 3, 0, 22381, -7, 2, 17, 3, 0, 6128], [4294967295, 4294967291, 4092460543, 4294828031, 4294967294, 134217726, 268435455, 2147483647, 1048575, 1073741823, 3892314111, 134217727, 1061158911, 536805376, 4294910143, 4160749567, 4294901759, 4294901760, 536870911, 262143, 8388607, 4294902783, 4294918143, 65535, 67043328, 2281701374, 4294967232, 2097151, 4294903807, 4194303, 255, 67108863, 4294967039, 511, 524287, 131071, 127, 4292870143, 4294902271, 4294549487, 33554431, 1023, 67047423, 4294901888, 4286578687, 4294770687, 67043583, 32767, 15, 2047999, 67043343, 16777215, 4294902000, 4294934527, 4294966783, 4294967279, 2047, 262083, 20511, 4290772991, 41943039, 493567, 4294959104, 603979775, 65536, 602799615, 805044223, 4294965206, 8191, 1031749119, 4294917631, 2134769663, 4286578493, 4282253311, 4294942719, 33540095, 4294905855, 4294967264, 2868854591, 1608515583, 265232348, 534519807, 2147614720, 1060109444, 4093640016, 17376, 2139062143, 224, 4169138175, 4294909951, 4286578688, 4294967292, 4294965759, 2044, 4292870144, 4294966272, 4294967280, 8289918, 4294934399, 4294901775, 4294965375, 1602223615, 4294967259, 4294443008, 268369920, 4292804608, 486341884, 4294963199, 3087007615, 1073692671, 4128527, 4279238655, 4294902015, 4294966591, 2445279231, 3670015, 3238002687, 31, 63, 4294967288, 4294705151, 4095, 3221208447, 4294549472, 2147483648, 4285526655, 4294966527, 4294705152, 4294966143, 64, 4294966719, 16383, 3774873592, 458752, 536807423, 67043839, 3758096383, 3959414372, 3755993023, 2080374783, 4294835295, 4294967103, 4160749565, 4087, 184024726, 2862017156, 1593309078, 268434431, 268434414, 4294901763, 536870912, 2952790016, 202506752, 139264, 402653184, 4261412864, 4227922944, 49152, 61440, 3758096384, 117440512, 65280, 3233808384, 3221225472, 2097152, 4294965248, 32768, 57152, 67108864, 4293918720, 4290772992, 25165824, 57344, 4227915776, 4278190080, 4227907584, 65520, 4026531840, 4227858432, 4160749568, 3758129152, 4294836224, 63488, 1073741824, 4294967040, 4194304, 251658240, 196608, 4294963200, 64512, 417808, 4227923712, 12582912, 50331648, 65472, 4294967168, 4294966784, 16, 4294917120, 2080374784, 4096, 65408, 524288, 65532]);
- function advanceChar(parser) {
- parser.column++;
- return (parser.currentChar = parser.source.charCodeAt(++parser.index));
- }
- function consumeMultiUnitCodePoint(parser, hi) {
- if ((hi & 0xfc00) !== 55296)
- return 0;
- const lo = parser.source.charCodeAt(parser.index + 1);
- if ((lo & 0xfc00) !== 0xdc00)
- return 0;
- hi = parser.currentChar = 65536 + ((hi & 0x3ff) << 10) + (lo & 0x3ff);
- if (((unicodeLookup[(hi >>> 5) + 0] >>> hi) & 31 & 1) === 0) {
- report(parser, 18, fromCodePoint(hi));
- }
- parser.index++;
- parser.column++;
- return 1;
- }
- function consumeLineFeed(parser, state) {
- parser.currentChar = parser.source.charCodeAt(++parser.index);
- parser.flags |= 1;
- if ((state & 4) === 0) {
- parser.column = 0;
- parser.line++;
- }
- }
- function scanNewLine(parser) {
- parser.flags |= 1;
- parser.currentChar = parser.source.charCodeAt(++parser.index);
- parser.column = 0;
- parser.line++;
- }
- function isExoticECMAScriptWhitespace(ch) {
- return (ch === 160 ||
- ch === 65279 ||
- ch === 133 ||
- ch === 5760 ||
- (ch >= 8192 && ch <= 8203) ||
- ch === 8239 ||
- ch === 8287 ||
- ch === 12288 ||
- ch === 8201 ||
- ch === 65519);
- }
- function fromCodePoint(codePoint) {
- return codePoint <= 65535
- ? String.fromCharCode(codePoint)
- : String.fromCharCode(codePoint >>> 10) + String.fromCharCode(codePoint & 0x3ff);
- }
- function toHex(code) {
- return code < 65 ? code - 48 : (code - 65 + 10) & 0xf;
- }
- function convertTokenType(t) {
- switch (t) {
- case 134283266:
- return 'NumericLiteral';
- case 134283267:
- return 'StringLiteral';
- case 86021:
- case 86022:
- return 'BooleanLiteral';
- case 86023:
- return 'NullLiteral';
- case 65540:
- return 'RegularExpression';
- case 67174408:
- case 67174409:
- case 132:
- return 'TemplateLiteral';
- default:
- if ((t & 143360) === 143360)
- return 'Identifier';
- if ((t & 4096) === 4096)
- return 'Keyword';
- return 'Punctuator';
- }
- }
- const CharTypes = [
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 8 | 1024,
- 0,
- 0,
- 8 | 2048,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 8192,
- 0,
- 1 | 2,
- 0,
- 0,
- 8192,
- 0,
- 0,
- 0,
- 256,
- 0,
- 256 | 32768,
- 0,
- 0,
- 2 | 16 | 128 | 32 | 64,
- 2 | 16 | 128 | 32 | 64,
- 2 | 16 | 32 | 64,
- 2 | 16 | 32 | 64,
- 2 | 16 | 32 | 64,
- 2 | 16 | 32 | 64,
- 2 | 16 | 32 | 64,
- 2 | 16 | 32 | 64,
- 2 | 16 | 512 | 64,
- 2 | 16 | 512 | 64,
- 0,
- 0,
- 16384,
- 0,
- 0,
- 0,
- 0,
- 1 | 2 | 64,
- 1 | 2 | 64,
- 1 | 2 | 64,
- 1 | 2 | 64,
- 1 | 2 | 64,
- 1 | 2 | 64,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 1 | 2,
- 0,
- 1,
- 0,
- 0,
- 1 | 2 | 4096,
- 0,
- 1 | 2 | 4 | 64,
- 1 | 2 | 4 | 64,
- 1 | 2 | 4 | 64,
- 1 | 2 | 4 | 64,
- 1 | 2 | 4 | 64,
- 1 | 2 | 4 | 64,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 1 | 2 | 4,
- 16384,
- 0,
- 0,
- 0,
- 0
- ];
- const isIdStart = [
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 1,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 0,
- 0,
- 0,
- 0,
- 1,
- 0,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 0,
- 0,
- 0,
- 0,
- 0
- ];
- const isIdPart = [
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 1,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 0,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 0,
- 0,
- 0,
- 0,
- 1,
- 0,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 1,
- 0,
- 0,
- 0,
- 0,
- 0
- ];
- function isIdentifierStart(code) {
- return code <= 0x7F
- ? isIdStart[code]
- : (unicodeLookup[(code >>> 5) + 34816] >>> code) & 31 & 1;
- }
- function isIdentifierPart(code) {
- return code <= 0x7F
- ? isIdPart[code]
- : (unicodeLookup[(code >>> 5) + 0] >>> code) & 31 & 1 || (code === 8204 || code === 8205);
- }
- const CommentTypes = ['SingleLine', 'MultiLine', 'HTMLOpen', 'HTMLClose', 'HashbangComment'];
- function skipHashBang(parser) {
- const source = parser.source;
- if (parser.currentChar === 35 && source.charCodeAt(parser.index + 1) === 33) {
- advanceChar(parser);
- advanceChar(parser);
- skipSingleLineComment(parser, source, 0, 4, parser.tokenPos, parser.linePos, parser.colPos);
- }
- }
- function skipSingleHTMLComment(parser, source, state, context, type, start, line, column) {
- if (context & 2048)
- report(parser, 0);
- return skipSingleLineComment(parser, source, state, type, start, line, column);
- }
- function skipSingleLineComment(parser, source, state, type, start, line, column) {
- const { index } = parser;
- parser.tokenPos = parser.index;
- parser.linePos = parser.line;
- parser.colPos = parser.column;
- while (parser.index < parser.end) {
- if (CharTypes[parser.currentChar] & 8) {
- const isCR = parser.currentChar === 13;
- scanNewLine(parser);
- if (isCR && parser.index < parser.end && parser.currentChar === 10)
- parser.currentChar = source.charCodeAt(++parser.index);
- break;
- }
- else if ((parser.currentChar ^ 8232) <= 1) {
- scanNewLine(parser);
- break;
- }
- advanceChar(parser);
- parser.tokenPos = parser.index;
- parser.linePos = parser.line;
- parser.colPos = parser.column;
- }
- if (parser.onComment) {
- const loc = {
- start: {
- line,
- column
- },
- end: {
- line: parser.linePos,
- column: parser.colPos
- }
- };
- parser.onComment(CommentTypes[type & 0xff], source.slice(index, parser.tokenPos), start, parser.tokenPos, loc);
- }
- return state | 1;
- }
- function skipMultiLineComment(parser, source, state) {
- const { index } = parser;
- while (parser.index < parser.end) {
- if (parser.currentChar < 0x2b) {
- let skippedOneAsterisk = false;
- while (parser.currentChar === 42) {
- if (!skippedOneAsterisk) {
- state &= ~4;
- skippedOneAsterisk = true;
- }
- if (advanceChar(parser) === 47) {
- advanceChar(parser);
- if (parser.onComment) {
- const loc = {
- start: {
- line: parser.linePos,
- column: parser.colPos
- },
- end: {
- line: parser.line,
- column: parser.column
- }
- };
- parser.onComment(CommentTypes[1 & 0xff], source.slice(index, parser.index - 2), index - 2, parser.index, loc);
- }
- parser.tokenPos = parser.index;
- parser.linePos = parser.line;
- parser.colPos = parser.column;
- return state;
- }
- }
- if (skippedOneAsterisk) {
- continue;
- }
- if (CharTypes[parser.currentChar] & 8) {
- if (parser.currentChar === 13) {
- state |= 1 | 4;
- scanNewLine(parser);
- }
- else {
- consumeLineFeed(parser, state);
- state = (state & ~4) | 1;
- }
- }
- else {
- advanceChar(parser);
- }
- }
- else if ((parser.currentChar ^ 8232) <= 1) {
- state = (state & ~4) | 1;
- scanNewLine(parser);
- }
- else {
- state &= ~4;
- advanceChar(parser);
- }
- }
- report(parser, 16);
- }
- function scanRegularExpression(parser, context) {
- const bodyStart = parser.index;
- let preparseState = 0;
- loop: while (true) {
- const ch = parser.currentChar;
- advanceChar(parser);
- if (preparseState & 1) {
- preparseState &= ~1;
- }
- else {
- switch (ch) {
- case 47:
- if (!preparseState)
- break loop;
- else
- break;
- case 92:
- preparseState |= 1;
- break;
- case 91:
- preparseState |= 2;
- break;
- case 93:
- preparseState &= 1;
- break;
- case 13:
- case 10:
- case 8232:
- case 8233:
- report(parser, 32);
- }
- }
- if (parser.index >= parser.source.length) {
- return report(parser, 32);
- }
- }
- const bodyEnd = parser.index - 1;
- let mask = 0;
- let char = parser.currentChar;
- const { index: flagStart } = parser;
- while (isIdentifierPart(char)) {
- switch (char) {
- case 103:
- if (mask & 2)
- report(parser, 34, 'g');
- mask |= 2;
- break;
- case 105:
- if (mask & 1)
- report(parser, 34, 'i');
- mask |= 1;
- break;
- case 109:
- if (mask & 4)
- report(parser, 34, 'm');
- mask |= 4;
- break;
- case 117:
- if (mask & 16)
- report(parser, 34, 'g');
- mask |= 16;
- break;
- case 121:
- if (mask & 8)
- report(parser, 34, 'y');
- mask |= 8;
- break;
- case 115:
- if (mask & 12)
- report(parser, 34, 's');
- mask |= 12;
- break;
- default:
- report(parser, 33);
- }
- char = advanceChar(parser);
- }
- const flags = parser.source.slice(flagStart, parser.index);
- const pattern = parser.source.slice(bodyStart, bodyEnd);
- parser.tokenRegExp = { pattern, flags };
- if (context & 512)
- parser.tokenRaw = parser.source.slice(parser.tokenPos, parser.index);
- parser.tokenValue = validate(parser, pattern, flags);
- return 65540;
- }
- function validate(parser, pattern, flags) {
- try {
- return new RegExp(pattern, flags);
- }
- catch (e) {
- report(parser, 32);
- }
- }
- function scanString(parser, context, quote) {
- const { index: start } = parser;
- let ret = '';
- let char = advanceChar(parser);
- let marker = parser.index;
- while ((CharTypes[char] & 8) === 0) {
- if (char === quote) {
- ret += parser.source.slice(marker, parser.index);
- advanceChar(parser);
- if (context & 512)
- parser.tokenRaw = parser.source.slice(start, parser.index);
- parser.tokenValue = ret;
- return 134283267;
- }
- if ((char & 8) === 8 && char === 92) {
- ret += parser.source.slice(marker, parser.index);
- char = advanceChar(parser);
- if (char < 0x7f || char === 8232 || char === 8233) {
- const code = parseEscape(parser, context, char);
- if (code >= 0)
- ret += fromCodePoint(code);
- else
- handleStringError(parser, code, 0);
- }
- else {
- ret += fromCodePoint(char);
- }
- marker = parser.index + 1;
- }
- if (parser.index >= parser.end)
- report(parser, 14);
- char = advanceChar(parser);
- }
- report(parser, 14);
- }
- function parseEscape(parser, context, first) {
- switch (first) {
- case 98:
- return 8;
- case 102:
- return 12;
- case 114:
- return 13;
- case 110:
- return 10;
- case 116:
- return 9;
- case 118:
- return 11;
- case 13: {
- if (parser.index < parser.end) {
- const nextChar = parser.source.charCodeAt(parser.index + 1);
- if (nextChar === 10) {
- parser.index = parser.index + 1;
- parser.currentChar = nextChar;
- }
- }
- }
- case 10:
- case 8232:
- case 8233:
- parser.column = -1;
- parser.line++;
- return -1;
- case 48:
- case 49:
- case 50:
- case 51: {
- let code = first - 48;
- let index = parser.index + 1;
- let column = parser.column + 1;
- if (index < parser.end) {
- const next = parser.source.charCodeAt(index);
- if ((CharTypes[next] & 32) === 0) {
- if ((code !== 0 || CharTypes[next] & 512) && context & 1024)
- return -2;
- }
- else if (context & 1024) {
- return -2;
- }
- else {
- parser.currentChar = next;
- code = (code << 3) | (next - 48);
- index++;
- column++;
- if (index < parser.end) {
- const next = parser.source.charCodeAt(index);
- if (CharTypes[next] & 32) {
- parser.currentChar = next;
- code = (code << 3) | (next - 48);
- index++;
- column++;
- }
- }
- parser.flags |= 64;
- parser.index = index - 1;
- parser.column = column - 1;
- }
- }
- return code;
- }
- case 52:
- case 53:
- case 54:
- case 55: {
- if (context & 1024)
- return -2;
- let code = first - 48;
- const index = parser.index + 1;
- const column = parser.column + 1;
- if (index < parser.end) {
- const next = parser.source.charCodeAt(index);
- if (CharTypes[next] & 32) {
- code = (code << 3) | (next - 48);
- parser.currentChar = next;
- parser.index = index;
- parser.column = column;
- }
- }
- parser.flags |= 64;
- return code;
- }
- case 120: {
- const ch1 = advanceChar(parser);
- if ((CharTypes[ch1] & 64) === 0)
- return -4;
- const hi = toHex(ch1);
- const ch2 = advanceChar(parser);
- if ((CharTypes[ch2] & 64) === 0)
- return -4;
- const lo = toHex(ch2);
- return (hi << 4) | lo;
- }
- case 117: {
- const ch = advanceChar(parser);
- if (parser.currentChar === 123) {
- let code = 0;
- while ((CharTypes[advanceChar(parser)] & 64) !== 0) {
- code = (code << 4) | toHex(parser.currentChar);
- if (code > 1114111)
- return -5;
- }
- if (parser.currentChar < 1 || parser.currentChar !== 125) {
- return -4;
- }
- return code;
- }
- else {
- if ((CharTypes[ch] & 64) === 0)
- return -4;
- const ch2 = parser.source.charCodeAt(parser.index + 1);
- if ((CharTypes[ch2] & 64) === 0)
- return -4;
- const ch3 = parser.source.charCodeAt(parser.index + 2);
- if ((CharTypes[ch3] & 64) === 0)
- return -4;
- const ch4 = parser.source.charCodeAt(parser.index + 3);
- if ((CharTypes[ch4] & 64) === 0)
- return -4;
- parser.index += 3;
- parser.column += 3;
- parser.currentChar = parser.source.charCodeAt(parser.index);
- return (toHex(ch) << 12) | (toHex(ch2) << 8) | (toHex(ch3) << 4) | toHex(ch4);
- }
- }
- case 56:
- case 57:
- if ((context & 256) === 0)
- return -3;
- default:
- return first;
- }
- }
- function handleStringError(state, code, isTemplate) {
- switch (code) {
- case -1:
- return;
- case -2:
- report(state, isTemplate ? 2 : 1);
- case -3:
- report(state, 13);
- case -4:
- report(state, 6);
- case -5:
- report(state, 101);
- }
- }
- function scanTemplate(parser, context) {
- const { index: start } = parser;
- let token = 67174409;
- let ret = '';
- let char = advanceChar(parser);
- while (char !== 96) {
- if (char === 36 && parser.source.charCodeAt(parser.index + 1) === 123) {
- advanceChar(parser);
- token = 67174408;
- break;
- }
- else if ((char & 8) === 8 && char === 92) {
- char = advanceChar(parser);
- if (char > 0x7e) {
- ret += fromCodePoint(char);
- }
- else {
- const code = parseEscape(parser, context | 1024, char);
- if (code >= 0) {
- ret += fromCodePoint(code);
- }
- else if (code !== -1 && context & 65536) {
- ret = undefined;
- char = scanBadTemplate(parser, char);
- if (char < 0)
- token = 67174408;
- break;
- }
- else {
- handleStringError(parser, code, 1);
- }
- }
- }
- else {
- if (parser.index < parser.end &&
- char === 13 &&
- parser.source.charCodeAt(parser.index) === 10) {
- ret += fromCodePoint(char);
- parser.currentChar = parser.source.charCodeAt(++parser.index);
- }
- if (((char & 83) < 3 && char === 10) || (char ^ 8232) <= 1) {
- parser.column = -1;
- parser.line++;
- }
- ret += fromCodePoint(char);
- }
- if (parser.index >= parser.end)
- report(parser, 15);
- char = advanceChar(parser);
- }
- advanceChar(parser);
- parser.tokenValue = ret;
- parser.tokenRaw = parser.source.slice(start + 1, parser.index - (token === 67174409 ? 1 : 2));
- return token;
- }
- function scanBadTemplate(parser, ch) {
- while (ch !== 96) {
- switch (ch) {
- case 36: {
- const index = parser.index + 1;
- if (index < parser.end && parser.source.charCodeAt(index) === 123) {
- parser.index = index;
- parser.column++;
- return -ch;
- }
- break;
- }
- case 10:
- case 8232:
- case 8233:
- parser.column = -1;
- parser.line++;
- }
- if (parser.index >= parser.end)
- report(parser, 15);
- ch = advanceChar(parser);
- }
- return ch;
- }
- function scanTemplateTail(parser, context) {
- if (parser.index >= parser.end)
- report(parser, 0);
- parser.index--;
- parser.column--;
- return scanTemplate(parser, context);
- }
- function scanNumber(parser, context, kind) {
- let char = parser.currentChar;
- let value = 0;
- let digit = 9;
- let atStart = kind & 64 ? 0 : 1;
- let digits = 0;
- let allowSeparator = 0;
- if (kind & 64) {
- value = '.' + scanDecimalDigitsOrSeparator(parser, char);
- char = parser.currentChar;
- if (char === 110)
- report(parser, 11);
- }
- else {
- if (char === 48) {
- char = advanceChar(parser);
- if ((char | 32) === 120) {
- kind = 8 | 128;
- char = advanceChar(parser);
- while (CharTypes[char] & (64 | 4096)) {
- if (char === 95) {
- if (!allowSeparator)
- report(parser, 146);
- allowSeparator = 0;
- char = advanceChar(parser);
- continue;
- }
- allowSeparator = 1;
- value = value * 0x10 + toHex(char);
- digits++;
- char = advanceChar(parser);
- }
- if (digits < 1 || !allowSeparator) {
- report(parser, digits < 1 ? 19 : 147);
- }
- }
- else if ((char | 32) === 111) {
- kind = 4 | 128;
- char = advanceChar(parser);
- while (CharTypes[char] & (32 | 4096)) {
- if (char === 95) {
- if (!allowSeparator) {
- report(parser, 146);
- }
- allowSeparator = 0;
- char = advanceChar(parser);
- continue;
- }
- allowSeparator = 1;
- value = value * 8 + (char - 48);
- digits++;
- char = advanceChar(parser);
- }
- if (digits < 1 || !allowSeparator) {
- report(parser, digits < 1 ? 0 : 147);
- }
- }
- else if ((char | 32) === 98) {
- kind = 2 | 128;
- char = advanceChar(parser);
- while (CharTypes[char] & (128 | 4096)) {
- if (char === 95) {
- if (!allowSeparator) {
- report(parser, 146);
- }
- allowSeparator = 0;
- char = advanceChar(parser);
- continue;
- }
- allowSeparator = 1;
- value = value * 2 + (char - 48);
- digits++;
- char = advanceChar(parser);
- }
- if (digits < 1 || !allowSeparator) {
- report(parser, digits < 1 ? 0 : 147);
- }
- }
- else if (CharTypes[char] & 32) {
- if (context & 1024)
- report(parser, 1);
- kind = 1;
- while (CharTypes[char] & 16) {
- if (CharTypes[char] & 512) {
- kind = 32;
- atStart = 0;
- break;
- }
- value = value * 8 + (char - 48);
- char = advanceChar(parser);
- }
- }
- else if (CharTypes[char] & 512) {
- if (context & 1024)
- report(parser, 1);
- parser.flags |= 64;
- kind = 32;
- }
- else if (char === 95) {
- report(parser, 0);
- }
- }
- if (kind & 48) {
- if (atStart) {
- while (digit >= 0 && CharTypes[char] & (16 | 4096)) {
- if (char === 95) {
- char = advanceChar(parser);
- if (char === 95 || kind & 32) {
- reportScannerError(parser.index, parser.line, parser.index + 1, 146);
- }
- allowSeparator = 1;
- continue;
- }
- allowSeparator = 0;
- value = 10 * value + (char - 48);
- char = advanceChar(parser);
- --digit;
- }
- if (allowSeparator) {
- reportScannerError(parser.index, parser.line, parser.index + 1, 147);
- }
- if (digit >= 0 && !isIdentifierStart(char) && char !== 46) {
- parser.tokenValue = value;
- if (context & 512)
- parser.tokenRaw = parser.source.slice(parser.tokenPos, parser.index);
- return 134283266;
- }
- }
- value += scanDecimalDigitsOrSeparator(parser, char);
- char = parser.currentChar;
- if (char === 46) {
- if (advanceChar(parser) === 95)
- report(parser, 0);
- kind = 64;
- value += '.' + scanDecimalDigitsOrSeparator(parser, parser.currentChar);
- char = parser.currentChar;
- }
- }
- }
- const end = parser.index;
- let isBigInt = 0;
- if (char === 110 && kind & 128) {
- isBigInt = 1;
- char = advanceChar(parser);
- }
- else {
- if ((char | 32) === 101) {
- char = advanceChar(parser);
- if (CharTypes[char] & 256)
- char = advanceChar(parser);
- const { index } = parser;
- if ((CharTypes[char] & 16) < 1)
- report(parser, 10);
- value += parser.source.substring(end, index) + scanDecimalDigitsOrSeparator(parser, char);
- char = parser.currentChar;
- }
- }
- if ((parser.index < parser.end && CharTypes[char] & 16) || isIdentifierStart(char)) {
- report(parser, 12);
- }
- if (isBigInt) {
- parser.tokenRaw = parser.source.slice(parser.tokenPos, parser.index);
- parser.tokenValue = BigInt(value);
- return 134283389;
- }
- parser.tokenValue =
- kind & (1 | 2 | 8 | 4)
- ? value
- : kind & 32
- ? parseFloat(parser.source.substring(parser.tokenPos, parser.index))
- : +value;
- if (context & 512)
- parser.tokenRaw = parser.source.slice(parser.tokenPos, parser.index);
- return 134283266;
- }
- function scanDecimalDigitsOrSeparator(parser, char) {
- let allowSeparator = 0;
- let start = parser.index;
- let ret = '';
- while (CharTypes[char] & (16 | 4096)) {
- if (char === 95) {
- const { index } = parser;
- char = advanceChar(parser);
- if (char === 95) {
- reportScannerError(parser.index, parser.line, parser.index + 1, 146);
- }
- allowSeparator = 1;
- ret += parser.source.substring(start, index);
- start = parser.index;
- continue;
- }
- allowSeparator = 0;
- char = advanceChar(parser);
- }
- if (allowSeparator) {
- reportScannerError(parser.index, parser.line, parser.index + 1, 147);
- }
- return ret + parser.source.substring(start, parser.index);
- }
- const KeywordDescTable = [
- 'end of source',
- 'identifier', 'number', 'string', 'regular expression',
- 'false', 'true', 'null',
- 'template continuation', 'template tail',
- '=>', '(', '{', '.', '...', '}', ')', ';', ',', '[', ']', ':', '?', '\'', '"', '</', '/>',
- '++', '--',
- '=', '<<=', '>>=', '>>>=', '**=', '+=', '-=', '*=', '/=', '%=', '^=', '|=',
- '&=', '||=', '&&=', '??=',
- 'typeof', 'delete', 'void', '!', '~', '+', '-', 'in', 'instanceof', '*', '%', '/', '**', '&&',
- '||', '===', '!==', '==', '!=', '<=', '>=', '<', '>', '<<', '>>', '>>>', '&', '|', '^',
- 'var', 'let', 'const',
- 'break', 'case', 'catch', 'class', 'continue', 'debugger', 'default', 'do', 'else', 'export',
- 'extends', 'finally', 'for', 'function', 'if', 'import', 'new', 'return', 'super', 'switch',
- 'this', 'throw', 'try', 'while', 'with',
- 'implements', 'interface', 'package', 'private', 'protected', 'public', 'static', 'yield',
- 'as', 'async', 'await', 'constructor', 'get', 'set', 'from', 'of',
- 'enum', 'eval', 'arguments', 'escaped keyword', 'escaped future reserved keyword', 'reserved if strict', '#',
- 'BigIntLiteral', '??', '?.', 'WhiteSpace', 'Illegal', 'LineTerminator', 'PrivateField',
- 'Template', '@', 'target', 'meta', 'LineFeed', 'Escaped', 'JSXText'
- ];
- const descKeywordTable = Object.create(null, {
- this: { value: 86113 },
- function: { value: 86106 },
- if: { value: 20571 },
- return: { value: 20574 },
- var: { value: 86090 },
- else: { value: 20565 },
- for: { value: 20569 },
- new: { value: 86109 },
- in: { value: 8738868 },
- typeof: { value: 16863277 },
- while: { value: 20580 },
- case: { value: 20558 },
- break: { value: 20557 },
- try: { value: 20579 },
- catch: { value: 20559 },
- delete: { value: 16863278 },
- throw: { value: 86114 },
- switch: { value: 86112 },
- continue: { value: 20561 },
- default: { value: 20563 },
- instanceof: { value: 8476725 },
- do: { value: 20564 },
- void: { value: 16863279 },
- finally: { value: 20568 },
- async: { value: 209007 },
- await: { value: 209008 },
- class: { value: 86096 },
- const: { value: 86092 },
- constructor: { value: 12401 },
- debugger: { value: 20562 },
- export: { value: 20566 },
- extends: { value: 20567 },
- false: { value: 86021 },
- from: { value: 12404 },
- get: { value: 12402 },
- implements: { value: 36966 },
- import: { value: 86108 },
- interface: { value: 36967 },
- let: { value: 241739 },
- null: { value: 86023 },
- of: { value: 274549 },
- package: { value: 36968 },
- private: { value: 36969 },
- protected: { value: 36970 },
- public: { value: 36971 },
- set: { value: 12403 },
- static: { value: 36972 },
- super: { value: 86111 },
- true: { value: 86022 },
- with: { value: 20581 },
- yield: { value: 241773 },
- enum: { value: 86134 },
- eval: { value: 537079927 },
- as: { value: 77934 },
- arguments: { value: 537079928 },
- target: { value: 143494 },
- meta: { value: 143495 },
- });
- function scanIdentifier(parser, context, isValidAsKeyword) {
- while (isIdPart[advanceChar(parser)]) { }
- parser.tokenValue = parser.source.slice(parser.tokenPos, parser.index);
- return parser.currentChar !== 92 && parser.currentChar < 0x7e
- ? descKeywordTable[parser.tokenValue] || 208897
- : scanIdentifierSlowCase(parser, context, 0, isValidAsKeyword);
- }
- function scanUnicodeIdentifier(parser, context) {
- const cookedChar = scanIdentifierUnicodeEscape(parser);
- if (!isIdentifierPart(cookedChar))
- report(parser, 4);
- parser.tokenValue = fromCodePoint(cookedChar);
- return scanIdentifierSlowCase(parser, context, 1, CharTypes[cookedChar] & 4);
- }
- function scanIdentifierSlowCase(parser, context, hasEscape, isValidAsKeyword) {
- let start = parser.index;
- while (parser.index < parser.end) {
- if (parser.currentChar === 92) {
- parser.tokenValue += parser.source.slice(start, parser.index);
- hasEscape = 1;
- const code = scanIdentifierUnicodeEscape(parser);
- if (!isIdentifierPart(code))
- report(parser, 4);
- isValidAsKeyword = isValidAsKeyword && CharTypes[code] & 4;
- parser.tokenValue += fromCodePoint(code);
- start = parser.index;
- }
- else if (isIdentifierPart(parser.currentChar) || consumeMultiUnitCodePoint(parser, parser.currentChar)) {
- advanceChar(parser);
- }
- else {
- break;
- }
- }
- if (parser.index <= parser.end) {
- parser.tokenValue += parser.source.slice(start, parser.index);
- }
- const length = parser.tokenValue.length;
- if (isValidAsKeyword && length >= 2 && length <= 11) {
- const token = descKeywordTable[parser.tokenValue];
- if (token === void 0)
- return 208897;
- if (!hasEscape)
- return token;
- if (context & 1024) {
- return token === 209008 && (context & (2048 | 4194304)) === 0
- ? token
- : token === 36972
- ? 122
- : (token & 36864) === 36864
- ? 122
- : 121;
- }
- if (context & 1073741824 &&
- (context & 8192) === 0 &&
- (token & 20480) === 20480)
- return token;
- if (token === 241773) {
- return context & 1073741824
- ? 143483
- : context & 2097152
- ? 121
- : token;
- }
- return token === 209007 && context & 1073741824
- ? 143483
- : (token & 36864) === 36864
- ? token
- : token === 209008 && (context & 4194304) === 0
- ? token
- : 121;
- }
- return 208897;
- }
- function scanPrivateIdentifier(parser) {
- if (!isIdentifierStart(advanceChar(parser)))
- report(parser, 93);
- return 131;
- }
- function scanIdentifierUnicodeEscape(parser) {
- if (parser.source.charCodeAt(parser.index + 1) !== 117) {
- report(parser, 4);
- }
- parser.currentChar = parser.source.charCodeAt((parser.index += 2));
- return scanUnicodeEscape(parser);
- }
- function scanUnicodeEscape(parser) {
- let codePoint = 0;
- const char = parser.currentChar;
- if (char === 123) {
- const begin = parser.index - 2;
- while (CharTypes[advanceChar(parser)] & 64) {
- codePoint = (codePoint << 4) | toHex(parser.currentChar);
- if (codePoint > 1114111)
- reportScannerError(begin, parser.line, parser.index + 1, 101);
- }
- if (parser.currentChar !== 125) {
- reportScannerError(begin, parser.line, parser.index - 1, 6);
- }
- advanceChar(parser);
- return codePoint;
- }
- if ((CharTypes[char] & 64) === 0)
- report(parser, 6);
- const char2 = parser.source.charCodeAt(parser.index + 1);
- if ((CharTypes[char2] & 64) === 0)
- report(parser, 6);
- const char3 = parser.source.charCodeAt(parser.index + 2);
- if ((CharTypes[char3] & 64) === 0)
- report(parser, 6);
- const char4 = parser.source.charCodeAt(parser.index + 3);
- if ((CharTypes[char4] & 64) === 0)
- report(parser, 6);
- codePoint = (toHex(char) << 12) | (toHex(char2) << 8) | (toHex(char3) << 4) | toHex(char4);
- parser.currentChar = parser.source.charCodeAt((parser.index += 4));
- return codePoint;
- }
- const TokenLookup = [
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 128,
- 136,
- 128,
- 128,
- 130,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 129,
- 128,
- 16842800,
- 134283267,
- 131,
- 208897,
- 8457015,
- 8455751,
- 134283267,
- 67174411,
- 16,
- 8457014,
- 25233970,
- 18,
- 25233971,
- 67108877,
- 8457016,
- 134283266,
- 134283266,
- 134283266,
- 134283266,
- 134283266,
- 134283266,
- 134283266,
- 134283266,
- 134283266,
- 134283266,
- 21,
- 1074790417,
- 8456258,
- 1077936157,
- 8456259,
- 22,
- 133,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 208897,
- 69271571,
- 137,
- 20,
- 8455497,
- 208897,
- 132,
- 4096,
- 4096,
- 4096,
- 4096,
- 4096,
- 4096,
- 4096,
- 208897,
- 4096,
- 208897,
- 208897,
- 4096,
- 208897,
- 4096,
- 208897,
- 4096,
- 208897,
- 4096,
- 4096,
- 4096,
- 208897,
- 4096,
- 4096,
- 208897,
- 4096,
- 4096,
- 2162700,
- 8455240,
- 1074790415,
- 16842801,
- 129
- ];
- function nextToken(parser, context) {
- parser.flags = (parser.flags | 1) ^ 1;
- parser.startPos = parser.index;
- parser.startColumn = parser.column;
- parser.startLine = parser.line;
- parser.token = scanSingleToken(parser, context, 0);
- if (parser.onToken && parser.token !== 1048576) {
- const loc = {
- start: {
- line: parser.linePos,
- column: parser.colPos
- },
- end: {
- line: parser.line,
- column: parser.column
- }
- };
- parser.onToken(convertTokenType(parser.token), parser.tokenPos, parser.index, loc);
- }
- }
- function scanSingleToken(parser, context, state) {
- const isStartOfLine = parser.index === 0;
- const source = parser.source;
- let startPos = parser.index;
- let startLine = parser.line;
- let startColumn = parser.column;
- while (parser.index < parser.end) {
- parser.tokenPos = parser.index;
- parser.colPos = parser.column;
- parser.linePos = parser.line;
- let char = parser.currentChar;
- if (char <= 0x7e) {
- const token = TokenLookup[char];
- switch (token) {
- case 67174411:
- case 16:
- case 2162700:
- case 1074790415:
- case 69271571:
- case 20:
- case 21:
- case 1074790417:
- case 18:
- case 16842801:
- case 133:
- case 129:
- advanceChar(parser);
- return token;
- case 208897:
- return scanIdentifier(parser, context, 0);
- case 4096:
- return scanIdentifier(parser, context, 1);
- case 134283266:
- return scanNumber(parser, context, 16 | 128);
- case 134283267:
- return scanString(parser, context, char);
- case 132:
- return scanTemplate(parser, context);
- case 137:
- return scanUnicodeIdentifier(parser, context);
- case 131:
- return scanPrivateIdentifier(parser);
- case 128:
- advanceChar(parser);
- break;
- case 130:
- state |= 1 | 4;
- scanNewLine(parser);
- break;
- case 136:
- consumeLineFeed(parser, state);
- state = (state & ~4) | 1;
- break;
- case 8456258:
- let ch = advanceChar(parser);
- if (parser.index < parser.end) {
- if (ch === 60) {
- if (parser.index < parser.end && advanceChar(parser) === 61) {
- advanceChar(parser);
- return 4194334;
- }
- return 8456516;
- }
- else if (ch === 61) {
- advanceChar(parser);
- return 8456000;
- }
- if (ch === 33) {
- const index = parser.index + 1;
- if (index + 1 < parser.end &&
- source.charCodeAt(index) === 45 &&
- source.charCodeAt(index + 1) == 45) {
- parser.column += 3;
- parser.currentChar = source.charCodeAt((parser.index += 3));
- state = skipSingleHTMLComment(parser, source, state, context, 2, parser.tokenPos, parser.linePos, parser.colPos);
- startPos = parser.tokenPos;
- startLine = parser.linePos;
- startColumn = parser.colPos;
- continue;
- }
- return 8456258;
- }
- if (ch === 47) {
- if ((context & 16) < 1)
- return 8456258;
- const index = parser.index + 1;
- if (index < parser.end) {
- ch = source.charCodeAt(index);
- if (ch === 42 || ch === 47)
- break;
- }
- advanceChar(parser);
- return 25;
- }
- }
- return 8456258;
- case 1077936157: {
- advanceChar(parser);
- const ch = parser.currentChar;
- if (ch === 61) {
- if (advanceChar(parser) === 61) {
- advanceChar(parser);
- return 8455996;
- }
- return 8455998;
- }
- if (ch === 62) {
- advanceChar(parser);
- return 10;
- }
- return 1077936157;
- }
- case 16842800:
- if (advanceChar(parser) !== 61) {
- return 16842800;
- }
- if (advanceChar(parser) !== 61) {
- return 8455999;
- }
- advanceChar(parser);
- return 8455997;
- case 8457015:
- if (advanceChar(parser) !== 61)
- return 8457015;
- advanceChar(parser);
- return 4194342;
- case 8457014: {
- advanceChar(parser);
- if (parser.index >= parser.end)
- return 8457014;
- const ch = parser.currentChar;
- if (ch === 61) {
- advanceChar(parser);
- return 4194340;
- }
- if (ch !== 42)
- return 8457014;
- if (advanceChar(parser) !== 61)
- return 8457273;
- advanceChar(parser);
- return 4194337;
- }
- case 8455497:
- if (advanceChar(parser) !== 61)
- return 8455497;
- advanceChar(parser);
- return 4194343;
- case 25233970: {
- advanceChar(parser);
- const ch = parser.currentChar;
- if (ch === 43) {
- advanceChar(parser);
- return 33619995;
- }
- if (ch === 61) {
- advanceChar(parser);
- return 4194338;
- }
- return 25233970;
- }
- case 25233971: {
- advanceChar(parser);
- const ch = parser.currentChar;
- if (ch === 45) {
- advanceChar(parser);
- if ((state & 1 || isStartOfLine) && parser.currentChar === 62) {
- if ((context & 256) === 0)
- report(parser, 108);
- advanceChar(parser);
- state = skipSingleHTMLComment(parser, source, state, context, 3, startPos, startLine, startColumn);
- startPos = parser.tokenPos;
- startLine = parser.linePos;
- startColumn = parser.colPos;
- continue;
- }
- return 33619996;
- }
- if (ch === 61) {
- advanceChar(parser);
- return 4194339;
- }
- return 25233971;
- }
- case 8457016: {
- advanceChar(parser);
- if (parser.index < parser.end) {
- const ch = parser.currentChar;
- if (ch === 47) {
- advanceChar(parser);
- state = skipSingleLineComment(parser, source, state, 0, parser.tokenPos, parser.linePos, parser.colPos);
- startPos = parser.tokenPos;
- startLine = parser.linePos;
- startColumn = parser.colPos;
- continue;
- }
- if (ch === 42) {
- advanceChar(parser);
- state = skipMultiLineComment(parser, source, state);
- startPos = parser.tokenPos;
- startLine = parser.linePos;
- startColumn = parser.colPos;
- continue;
- }
- if (context & 32768) {
- return scanRegularExpression(parser, context);
- }
- if (ch === 61) {
- advanceChar(parser);
- return 4259877;
- }
- }
- return 8457016;
- }
- case 67108877:
- const next = advanceChar(parser);
- if (next >= 48 && next <= 57)
- return scanNumber(parser, context, 64 | 16);
- if (next === 46) {
- const index = parser.index + 1;
- if (index < parser.end && source.charCodeAt(index) === 46) {
- parser.column += 2;
- parser.currentChar = source.charCodeAt((parser.index += 2));
- return 14;
- }
- }
- return 67108877;
- case 8455240: {
- advanceChar(parser);
- const ch = parser.currentChar;
- if (ch === 124) {
- advanceChar(parser);
- if (parser.currentChar === 61) {
- advanceChar(parser);
- return 4194346;
- }
- return 8979003;
- }
- if (ch === 61) {
- advanceChar(parser);
- return 4194344;
- }
- return 8455240;
- }
- case 8456259: {
- advanceChar(parser);
- const ch = parser.currentChar;
- if (ch === 61) {
- advanceChar(parser);
- return 8456001;
- }
- if (ch !== 62)
- return 8456259;
- advanceChar(parser);
- if (parser.index < parser.end) {
- const ch = parser.currentChar;
- if (ch === 62) {
- if (advanceChar(parser) === 61) {
- advanceChar(parser);
- return 4194336;
- }
- return 8456518;
- }
- if (ch === 61) {
- advanceChar(parser);
- return 4194335;
- }
- }
- return 8456517;
- }
- case 8455751: {
- advanceChar(parser);
- const ch = parser.currentChar;
- if (ch === 38) {
- advanceChar(parser);
- if (parser.currentChar === 61) {
- advanceChar(parser);
- return 4194347;
- }
- return 8979258;
- }
- if (ch === 61) {
- advanceChar(parser);
- return 4194345;
- }
- return 8455751;
- }
- case 22: {
- let ch = advanceChar(parser);
- if (ch === 63) {
- advanceChar(parser);
- if (parser.currentChar === 61) {
- advanceChar(parser);
- return 4194348;
- }
- return 276889982;
- }
- if (ch === 46) {
- const index = parser.index + 1;
- if (index < parser.end) {
- ch = source.charCodeAt(index);
- if (!(ch >= 48 && ch <= 57)) {
- advanceChar(parser);
- return 67108991;
- }
- }
- }
- return 22;
- }
- }
- }
- else {
- if ((char ^ 8232) <= 1) {
- state = (state & ~4) | 1;
- scanNewLine(parser);
- continue;
- }
- if ((char & 0xfc00) === 0xd800 || ((unicodeLookup[(char >>> 5) + 34816] >>> char) & 31 & 1) !== 0) {
- if ((char & 0xfc00) === 0xdc00) {
- char = ((char & 0x3ff) << 10) | (char & 0x3ff) | 0x10000;
- if (((unicodeLookup[(char >>> 5) + 0] >>> char) & 31 & 1) === 0) {
- report(parser, 18, fromCodePoint(char));
- }
- parser.index++;
- parser.currentChar = char;
- }
- parser.column++;
- parser.tokenValue = '';
- return scanIdentifierSlowCase(parser, context, 0, 0);
- }
- if (isExoticECMAScriptWhitespace(char)) {
- advanceChar(parser);
- continue;
- }
- report(parser, 18, fromCodePoint(char));
- }
- }
- return 1048576;
- }
- const entities = {
- AElig: '\u00C6',
- AMP: '\u0026',
- Aacute: '\u00C1',
- Abreve: '\u0102',
- Acirc: '\u00C2',
- Acy: '\u0410',
- Afr: '\uD835\uDD04',
- Agrave: '\u00C0',
- Alpha: '\u0391',
- Amacr: '\u0100',
- And: '\u2A53',
- Aogon: '\u0104',
- Aopf: '\uD835\uDD38',
- ApplyFunction: '\u2061',
- Aring: '\u00C5',
- Ascr: '\uD835\uDC9C',
- Assign: '\u2254',
- Atilde: '\u00C3',
- Auml: '\u00C4',
- Backslash: '\u2216',
- Barv: '\u2AE7',
- Barwed: '\u2306',
- Bcy: '\u0411',
- Because: '\u2235',
- Bernoullis: '\u212C',
- Beta: '\u0392',
- Bfr: '\uD835\uDD05',
- Bopf: '\uD835\uDD39',
- Breve: '\u02D8',
- Bscr: '\u212C',
- Bumpeq: '\u224E',
- CHcy: '\u0427',
- COPY: '\u00A9',
- Cacute: '\u0106',
- Cap: '\u22D2',
- CapitalDifferentialD: '\u2145',
- Cayleys: '\u212D',
- Ccaron: '\u010C',
- Ccedil: '\u00C7',
- Ccirc: '\u0108',
- Cconint: '\u2230',
- Cdot: '\u010A',
- Cedilla: '\u00B8',
- CenterDot: '\u00B7',
- Cfr: '\u212D',
- Chi: '\u03A7',
- CircleDot: '\u2299',
- CircleMinus: '\u2296',
- CirclePlus: '\u2295',
- CircleTimes: '\u2297',
- ClockwiseContourIntegral: '\u2232',
- CloseCurlyDoubleQuote: '\u201D',
- CloseCurlyQuote: '\u2019',
- Colon: '\u2237',
- Colone: '\u2A74',
- Congruent: '\u2261',
- Conint: '\u222F',
- ContourIntegral: '\u222E',
- Copf: '\u2102',
- Coproduct: '\u2210',
- CounterClockwiseContourIntegral: '\u2233',
- Cross: '\u2A2F',
- Cscr: '\uD835\uDC9E',
- Cup: '\u22D3',
- CupCap: '\u224D',
- DD: '\u2145',
- DDotrahd: '\u2911',
- DJcy: '\u0402',
- DScy: '\u0405',
- DZcy: '\u040F',
- Dagger: '\u2021',
- Darr: '\u21A1',
- Dashv: '\u2AE4',
- Dcaron: '\u010E',
- Dcy: '\u0414',
- Del: '\u2207',
- Delta: '\u0394',
- Dfr: '\uD835\uDD07',
- DiacriticalAcute: '\u00B4',
- DiacriticalDot: '\u02D9',
- DiacriticalDoubleAcute: '\u02DD',
- DiacriticalGrave: '\u0060',
- DiacriticalTilde: '\u02DC',
- Diamond: '\u22C4',
- DifferentialD: '\u2146',
- Dopf: '\uD835\uDD3B',
- Dot: '\u00A8',
- DotDot: '\u20DC',
- DotEqual: '\u2250',
- DoubleContourIntegral: '\u222F',
- DoubleDot: '\u00A8',
- DoubleDownArrow: '\u21D3',
- DoubleLeftArrow: '\u21D0',
- DoubleLeftRightArrow: '\u21D4',
- DoubleLeftTee: '\u2AE4',
- DoubleLongLeftArrow: '\u27F8',
- DoubleLongLeftRightArrow: '\u27FA',
- DoubleLongRightArrow: '\u27F9',
- DoubleRightArrow: '\u21D2',
- DoubleRightTee: '\u22A8',
- DoubleUpArrow: '\u21D1',
- DoubleUpDownArrow: '\u21D5',
- DoubleVerticalBar: '\u2225',
- DownArrow: '\u2193',
- DownArrowBar: '\u2913',
- DownArrowUpArrow: '\u21F5',
- DownBreve: '\u0311',
- DownLeftRightVector: '\u2950',
- DownLeftTeeVector: '\u295E',
- DownLeftVector: '\u21BD',
- DownLeftVectorBar: '\u2956',
- DownRightTeeVector: '\u295F',
- DownRightVector: '\u21C1',
- DownRightVectorBar: '\u2957',
- DownTee: '\u22A4',
- DownTeeArrow: '\u21A7',
- Downarrow: '\u21D3',
- Dscr: '\uD835\uDC9F',
- Dstrok: '\u0110',
- ENG: '\u014A',
- ETH: '\u00D0',
- Eacute: '\u00C9',
- Ecaron: '\u011A',
- Ecirc: '\u00CA',
- Ecy: '\u042D',
- Edot: '\u0116',
- Efr: '\uD835\uDD08',
- Egrave: '\u00C8',
- Element: '\u2208',
- Emacr: '\u0112',
- EmptySmallSquare: '\u25FB',
- EmptyVerySmallSquare: '\u25AB',
- Eogon: '\u0118',
- Eopf: '\uD835\uDD3C',
- Epsilon: '\u0395',
- Equal: '\u2A75',
- EqualTilde: '\u2242',
- Equilibrium: '\u21CC',
- Escr: '\u2130',
- Esim: '\u2A73',
- Eta: '\u0397',
- Euml: '\u00CB',
- Exists: '\u2203',
- ExponentialE: '\u2147',
- Fcy: '\u0424',
- Ffr: '\uD835\uDD09',
- FilledSmallSquare: '\u25FC',
- FilledVerySmallSquare: '\u25AA',
- Fopf: '\uD835\uDD3D',
- ForAll: '\u2200',
- Fouriertrf: '\u2131',
- Fscr: '\u2131',
- GJcy: '\u0403',
- GT: '\u003E',
- Gamma: '\u0393',
- Gammad: '\u03DC',
- Gbreve: '\u011E',
- Gcedil: '\u0122',
- Gcirc: '\u011C',
- Gcy: '\u0413',
- Gdot: '\u0120',
- Gfr: '\uD835\uDD0A',
- Gg: '\u22D9',
- Gopf: '\uD835\uDD3E',
- GreaterEqual: '\u2265',
- GreaterEqualLess: '\u22DB',
- GreaterFullEqual: '\u2267',
- GreaterGreater: '\u2AA2',
- GreaterLess: '\u2277',
- GreaterSlantEqual: '\u2A7E',
- GreaterTilde: '\u2273',
- Gscr: '\uD835\uDCA2',
- Gt: '\u226B',
- HARDcy: '\u042A',
- Hacek: '\u02C7',
- Hat: '\u005E',
- Hcirc: '\u0124',
- Hfr: '\u210C',
- HilbertSpace: '\u210B',
- Hopf: '\u210D',
- HorizontalLine: '\u2500',
- Hscr: '\u210B',
- Hstrok: '\u0126',
- HumpDownHump: '\u224E',
- HumpEqual: '\u224F',
- IEcy: '\u0415',
- IJlig: '\u0132',
- IOcy: '\u0401',
- Iacute: '\u00CD',
- Icirc: '\u00CE',
- Icy: '\u0418',
- Idot: '\u0130',
- Ifr: '\u2111',
- Igrave: '\u00CC',
- Im: '\u2111',
- Imacr: '\u012A',
- ImaginaryI: '\u2148',
- Implies: '\u21D2',
- Int: '\u222C',
- Integral: '\u222B',
- Intersection: '\u22C2',
- InvisibleComma: '\u2063',
- InvisibleTimes: '\u2062',
- Iogon: '\u012E',
- Iopf: '\uD835\uDD40',
- Iota: '\u0399',
- Iscr: '\u2110',
- Itilde: '\u0128',
- Iukcy: '\u0406',
- Iuml: '\u00CF',
- Jcirc: '\u0134',
- Jcy: '\u0419',
- Jfr: '\uD835\uDD0D',
- Jopf: '\uD835\uDD41',
- Jscr: '\uD835\uDCA5',
- Jsercy: '\u0408',
- Jukcy: '\u0404',
- KHcy: '\u0425',
- KJcy: '\u040C',
- Kappa: '\u039A',
- Kcedil: '\u0136',
- Kcy: '\u041A',
- Kfr: '\uD835\uDD0E',
- Kopf: '\uD835\uDD42',
- Kscr: '\uD835\uDCA6',
- LJcy: '\u0409',
- LT: '\u003C',
- Lacute: '\u0139',
- Lambda: '\u039B',
- Lang: '\u27EA',
- Laplacetrf: '\u2112',
- Larr: '\u219E',
- Lcaron: '\u013D',
- Lcedil: '\u013B',
- Lcy: '\u041B',
- LeftAngleBracket: '\u27E8',
- LeftArrow: '\u2190',
- LeftArrowBar: '\u21E4',
- LeftArrowRightArrow: '\u21C6',
- LeftCeiling: '\u2308',
- LeftDoubleBracket: '\u27E6',
- LeftDownTeeVector: '\u2961',
- LeftDownVector: '\u21C3',
- LeftDownVectorBar: '\u2959',
- LeftFloor: '\u230A',
- LeftRightArrow: '\u2194',
- LeftRightVector: '\u294E',
- LeftTee: '\u22A3',
- LeftTeeArrow: '\u21A4',
- LeftTeeVector: '\u295A',
- LeftTriangle: '\u22B2',
- LeftTriangleBar: '\u29CF',
- LeftTriangleEqual: '\u22B4',
- LeftUpDownVector: '\u2951',
- LeftUpTeeVector: '\u2960',
- LeftUpVector: '\u21BF',
- LeftUpVectorBar: '\u2958',
- LeftVector: '\u21BC',
- LeftVectorBar: '\u2952',
- Leftarrow: '\u21D0',
- Leftrightarrow: '\u21D4',
- LessEqualGreater: '\u22DA',
- LessFullEqual: '\u2266',
- LessGreater: '\u2276',
- LessLess: '\u2AA1',
- LessSlantEqual: '\u2A7D',
- LessTilde: '\u2272',
- Lfr: '\uD835\uDD0F',
- Ll: '\u22D8',
- Lleftarrow: '\u21DA',
- Lmidot: '\u013F',
- LongLeftArrow: '\u27F5',
- LongLeftRightArrow: '\u27F7',
- LongRightArrow: '\u27F6',
- Longleftarrow: '\u27F8',
- Longleftrightarrow: '\u27FA',
- Longrightarrow: '\u27F9',
- Lopf: '\uD835\uDD43',
- LowerLeftArrow: '\u2199',
- LowerRightArrow: '\u2198',
- Lscr: '\u2112',
- Lsh: '\u21B0',
- Lstrok: '\u0141',
- Lt: '\u226A',
- Map: '\u2905',
- Mcy: '\u041C',
- MediumSpace: '\u205F',
- Mellintrf: '\u2133',
- Mfr: '\uD835\uDD10',
- MinusPlus: '\u2213',
- Mopf: '\uD835\uDD44',
- Mscr: '\u2133',
- Mu: '\u039C',
- NJcy: '\u040A',
- Nacute: '\u0143',
- Ncaron: '\u0147',
- Ncedil: '\u0145',
- Ncy: '\u041D',
- NegativeMediumSpace: '\u200B',
- NegativeThickSpace: '\u200B',
- NegativeThinSpace: '\u200B',
- NegativeVeryThinSpace: '\u200B',
- NestedGreaterGreater: '\u226B',
- NestedLessLess: '\u226A',
- NewLine: '\u000A',
- Nfr: '\uD835\uDD11',
- NoBreak: '\u2060',
- NonBreakingSpace: '\u00A0',
- Nopf: '\u2115',
- Not: '\u2AEC',
- NotCongruent: '\u2262',
- NotCupCap: '\u226D',
- NotDoubleVerticalBar: '\u2226',
- NotElement: '\u2209',
- NotEqual: '\u2260',
- NotEqualTilde: '\u2242\u0338',
- NotExists: '\u2204',
- NotGreater: '\u226F',
- NotGreaterEqual: '\u2271',
- NotGreaterFullEqual: '\u2267\u0338',
- NotGreaterGreater: '\u226B\u0338',
- NotGreaterLess: '\u2279',
- NotGreaterSlantEqual: '\u2A7E\u0338',
- NotGreaterTilde: '\u2275',
- NotHumpDownHump: '\u224E\u0338',
- NotHumpEqual: '\u224F\u0338',
- NotLeftTriangle: '\u22EA',
- NotLeftTriangleBar: '\u29CF\u0338',
- NotLeftTriangleEqual: '\u22EC',
- NotLess: '\u226E',
- NotLessEqual: '\u2270',
- NotLessGreater: '\u2278',
- NotLessLess: '\u226A\u0338',
- NotLessSlantEqual: '\u2A7D\u0338',
- NotLessTilde: '\u2274',
- NotNestedGreaterGreater: '\u2AA2\u0338',
- NotNestedLessLess: '\u2AA1\u0338',
- NotPrecedes: '\u2280',
- NotPrecedesEqual: '\u2AAF\u0338',
- NotPrecedesSlantEqual: '\u22E0',
- NotReverseElement: '\u220C',
- NotRightTriangle: '\u22EB',
- NotRightTriangleBar: '\u29D0\u0338',
- NotRightTriangleEqual: '\u22ED',
- NotSquareSubset: '\u228F\u0338',
- NotSquareSubsetEqual: '\u22E2',
- NotSquareSuperset: '\u2290\u0338',
- NotSquareSupersetEqual: '\u22E3',
- NotSubset: '\u2282\u20D2',
- NotSubsetEqual: '\u2288',
- NotSucceeds: '\u2281',
- NotSucceedsEqual: '\u2AB0\u0338',
- NotSucceedsSlantEqual: '\u22E1',
- NotSucceedsTilde: '\u227F\u0338',
- NotSuperset: '\u2283\u20D2',
- NotSupersetEqual: '\u2289',
- NotTilde: '\u2241',
- NotTildeEqual: '\u2244',
- NotTildeFullEqual: '\u2247',
- NotTildeTilde: '\u2249',
- NotVerticalBar: '\u2224',
- Nscr: '\uD835\uDCA9',
- Ntilde: '\u00D1',
- Nu: '\u039D',
- OElig: '\u0152',
- Oacute: '\u00D3',
- Ocirc: '\u00D4',
- Ocy: '\u041E',
- Odblac: '\u0150',
- Ofr: '\uD835\uDD12',
- Ograve: '\u00D2',
- Omacr: '\u014C',
- Omega: '\u03A9',
- Omicron: '\u039F',
- Oopf: '\uD835\uDD46',
- OpenCurlyDoubleQuote: '\u201C',
- OpenCurlyQuote: '\u2018',
- Or: '\u2A54',
- Oscr: '\uD835\uDCAA',
- Oslash: '\u00D8',
- Otilde: '\u00D5',
- Otimes: '\u2A37',
- Ouml: '\u00D6',
- OverBar: '\u203E',
- OverBrace: '\u23DE',
- OverBracket: '\u23B4',
- OverParenthesis: '\u23DC',
- PartialD: '\u2202',
- Pcy: '\u041F',
- Pfr: '\uD835\uDD13',
- Phi: '\u03A6',
- Pi: '\u03A0',
- PlusMinus: '\u00B1',
- Poincareplane: '\u210C',
- Popf: '\u2119',
- Pr: '\u2ABB',
- Precedes: '\u227A',
- PrecedesEqual: '\u2AAF',
- PrecedesSlantEqual: '\u227C',
- PrecedesTilde: '\u227E',
- Prime: '\u2033',
- Product: '\u220F',
- Proportion: '\u2237',
- Proportional: '\u221D',
- Pscr: '\uD835\uDCAB',
- Psi: '\u03A8',
- QUOT: '\u0022',
- Qfr: '\uD835\uDD14',
- Qopf: '\u211A',
- Qscr: '\uD835\uDCAC',
- RBarr: '\u2910',
- REG: '\u00AE',
- Racute: '\u0154',
- Rang: '\u27EB',
- Rarr: '\u21A0',
- Rarrtl: '\u2916',
- Rcaron: '\u0158',
- Rcedil: '\u0156',
- Rcy: '\u0420',
- Re: '\u211C',
- ReverseElement: '\u220B',
- ReverseEquilibrium: '\u21CB',
- ReverseUpEquilibrium: '\u296F',
- Rfr: '\u211C',
- Rho: '\u03A1',
- RightAngleBracket: '\u27E9',
- RightArrow: '\u2192',
- RightArrowBar: '\u21E5',
- RightArrowLeftArrow: '\u21C4',
- RightCeiling: '\u2309',
- RightDoubleBracket: '\u27E7',
- RightDownTeeVector: '\u295D',
- RightDownVector: '\u21C2',
- RightDownVectorBar: '\u2955',
- RightFloor: '\u230B',
- RightTee: '\u22A2',
- RightTeeArrow: '\u21A6',
- RightTeeVector: '\u295B',
- RightTriangle: '\u22B3',
- RightTriangleBar: '\u29D0',
- RightTriangleEqual: '\u22B5',
- RightUpDownVector: '\u294F',
- RightUpTeeVector: '\u295C',
- RightUpVector: '\u21BE',
- RightUpVectorBar: '\u2954',
- RightVector: '\u21C0',
- RightVectorBar: '\u2953',
- Rightarrow: '\u21D2',
- Ropf: '\u211D',
- RoundImplies: '\u2970',
- Rrightarrow: '\u21DB',
- Rscr: '\u211B',
- Rsh: '\u21B1',
- RuleDelayed: '\u29F4',
- SHCHcy: '\u0429',
- SHcy: '\u0428',
- SOFTcy: '\u042C',
- Sacute: '\u015A',
- Sc: '\u2ABC',
- Scaron: '\u0160',
- Scedil: '\u015E',
- Scirc: '\u015C',
- Scy: '\u0421',
- Sfr: '\uD835\uDD16',
- ShortDownArrow: '\u2193',
- ShortLeftArrow: '\u2190',
- ShortRightArrow: '\u2192',
- ShortUpArrow: '\u2191',
- Sigma: '\u03A3',
- SmallCircle: '\u2218',
- Sopf: '\uD835\uDD4A',
- Sqrt: '\u221A',
- Square: '\u25A1',
- SquareIntersection: '\u2293',
- SquareSubset: '\u228F',
- SquareSubsetEqual: '\u2291',
- SquareSuperset: '\u2290',
- SquareSupersetEqual: '\u2292',
- SquareUnion: '\u2294',
- Sscr: '\uD835\uDCAE',
- Star: '\u22C6',
- Sub: '\u22D0',
- Subset: '\u22D0',
- SubsetEqual: '\u2286',
- Succeeds: '\u227B',
- SucceedsEqual: '\u2AB0',
- SucceedsSlantEqual: '\u227D',
- SucceedsTilde: '\u227F',
- SuchThat: '\u220B',
- Sum: '\u2211',
- Sup: '\u22D1',
- Superset: '\u2283',
- SupersetEqual: '\u2287',
- Supset: '\u22D1',
- THORN: '\u00DE',
- TRADE: '\u2122',
- TSHcy: '\u040B',
- TScy: '\u0426',
- Tab: '\u0009',
- Tau: '\u03A4',
- Tcaron: '\u0164',
- Tcedil: '\u0162',
- Tcy: '\u0422',
- Tfr: '\uD835\uDD17',
- Therefore: '\u2234',
- Theta: '\u0398',
- ThickSpace: '\u205F\u200A',
- ThinSpace: '\u2009',
- Tilde: '\u223C',
- TildeEqual: '\u2243',
- TildeFullEqual: '\u2245',
- TildeTilde: '\u2248',
- Topf: '\uD835\uDD4B',
- TripleDot: '\u20DB',
- Tscr: '\uD835\uDCAF',
- Tstrok: '\u0166',
- Uacute: '\u00DA',
- Uarr: '\u219F',
- Uarrocir: '\u2949',
- Ubrcy: '\u040E',
- Ubreve: '\u016C',
- Ucirc: '\u00DB',
- Ucy: '\u0423',
- Udblac: '\u0170',
- Ufr: '\uD835\uDD18',
- Ugrave: '\u00D9',
- Umacr: '\u016A',
- UnderBar: '\u005F',
- UnderBrace: '\u23DF',
- UnderBracket: '\u23B5',
- UnderParenthesis: '\u23DD',
- Union: '\u22C3',
- UnionPlus: '\u228E',
- Uogon: '\u0172',
- Uopf: '\uD835\uDD4C',
- UpArrow: '\u2191',
- UpArrowBar: '\u2912',
- UpArrowDownArrow: '\u21C5',
- UpDownArrow: '\u2195',
- UpEquilibrium: '\u296E',
- UpTee: '\u22A5',
- UpTeeArrow: '\u21A5',
- Uparrow: '\u21D1',
- Updownarrow: '\u21D5',
- UpperLeftArrow: '\u2196',
- UpperRightArrow: '\u2197',
- Upsi: '\u03D2',
- Upsilon: '\u03A5',
- Uring: '\u016E',
- Uscr: '\uD835\uDCB0',
- Utilde: '\u0168',
- Uuml: '\u00DC',
- VDash: '\u22AB',
- Vbar: '\u2AEB',
- Vcy: '\u0412',
- Vdash: '\u22A9',
- Vdashl: '\u2AE6',
- Vee: '\u22C1',
- Verbar: '\u2016',
- Vert: '\u2016',
- VerticalBar: '\u2223',
- VerticalLine: '\u007C',
- VerticalSeparator: '\u2758',
- VerticalTilde: '\u2240',
- VeryThinSpace: '\u200A',
- Vfr: '\uD835\uDD19',
- Vopf: '\uD835\uDD4D',
- Vscr: '\uD835\uDCB1',
- Vvdash: '\u22AA',
- Wcirc: '\u0174',
- Wedge: '\u22C0',
- Wfr: '\uD835\uDD1A',
- Wopf: '\uD835\uDD4E',
- Wscr: '\uD835\uDCB2',
- Xfr: '\uD835\uDD1B',
- Xi: '\u039E',
- Xopf: '\uD835\uDD4F',
- Xscr: '\uD835\uDCB3',
- YAcy: '\u042F',
- YIcy: '\u0407',
- YUcy: '\u042E',
- Yacute: '\u00DD',
- Ycirc: '\u0176',
- Ycy: '\u042B',
- Yfr: '\uD835\uDD1C',
- Yopf: '\uD835\uDD50',
- Yscr: '\uD835\uDCB4',
- Yuml: '\u0178',
- ZHcy: '\u0416',
- Zacute: '\u0179',
- Zcaron: '\u017D',
- Zcy: '\u0417',
- Zdot: '\u017B',
- ZeroWidthSpace: '\u200B',
- Zeta: '\u0396',
- Zfr: '\u2128',
- Zopf: '\u2124',
- Zscr: '\uD835\uDCB5',
- aacute: '\u00E1',
- abreve: '\u0103',
- ac: '\u223E',
- acE: '\u223E\u0333',
- acd: '\u223F',
- acirc: '\u00E2',
- acute: '\u00B4',
- acy: '\u0430',
- aelig: '\u00E6',
- af: '\u2061',
- afr: '\uD835\uDD1E',
- agrave: '\u00E0',
- alefsym: '\u2135',
- aleph: '\u2135',
- alpha: '\u03B1',
- amacr: '\u0101',
- amalg: '\u2A3F',
- amp: '\u0026',
- and: '\u2227',
- andand: '\u2A55',
- andd: '\u2A5C',
- andslope: '\u2A58',
- andv: '\u2A5A',
- ang: '\u2220',
- ange: '\u29A4',
- angle: '\u2220',
- angmsd: '\u2221',
- angmsdaa: '\u29A8',
- angmsdab: '\u29A9',
- angmsdac: '\u29AA',
- angmsdad: '\u29AB',
- angmsdae: '\u29AC',
- angmsdaf: '\u29AD',
- angmsdag: '\u29AE',
- angmsdah: '\u29AF',
- angrt: '\u221F',
- angrtvb: '\u22BE',
- angrtvbd: '\u299D',
- angsph: '\u2222',
- angst: '\u00C5',
- angzarr: '\u237C',
- aogon: '\u0105',
- aopf: '\uD835\uDD52',
- ap: '\u2248',
- apE: '\u2A70',
- apacir: '\u2A6F',
- ape: '\u224A',
- apid: '\u224B',
- apos: '\u0027',
- approx: '\u2248',
- approxeq: '\u224A',
- aring: '\u00E5',
- ascr: '\uD835\uDCB6',
- ast: '\u002A',
- asymp: '\u2248',
- asympeq: '\u224D',
- atilde: '\u00E3',
- auml: '\u00E4',
- awconint: '\u2233',
- awint: '\u2A11',
- bNot: '\u2AED',
- backcong: '\u224C',
- backepsilon: '\u03F6',
- backprime: '\u2035',
- backsim: '\u223D',
- backsimeq: '\u22CD',
- barvee: '\u22BD',
- barwed: '\u2305',
- barwedge: '\u2305',
- bbrk: '\u23B5',
- bbrktbrk: '\u23B6',
- bcong: '\u224C',
- bcy: '\u0431',
- bdquo: '\u201E',
- becaus: '\u2235',
- because: '\u2235',
- bemptyv: '\u29B0',
- bepsi: '\u03F6',
- bernou: '\u212C',
- beta: '\u03B2',
- beth: '\u2136',
- between: '\u226C',
- bfr: '\uD835\uDD1F',
- bigcap: '\u22C2',
- bigcirc: '\u25EF',
- bigcup: '\u22C3',
- bigodot: '\u2A00',
- bigoplus: '\u2A01',
- bigotimes: '\u2A02',
- bigsqcup: '\u2A06',
- bigstar: '\u2605',
- bigtriangledown: '\u25BD',
- bigtriangleup: '\u25B3',
- biguplus: '\u2A04',
- bigvee: '\u22C1',
- bigwedge: '\u22C0',
- bkarow: '\u290D',
- blacklozenge: '\u29EB',
- blacksquare: '\u25AA',
- blacktriangle: '\u25B4',
- blacktriangledown: '\u25BE',
- blacktriangleleft: '\u25C2',
- blacktriangleright: '\u25B8',
- blank: '\u2423',
- blk12: '\u2592',
- blk14: '\u2591',
- blk34: '\u2593',
- block: '\u2588',
- bne: '\u003D\u20E5',
- bnequiv: '\u2261\u20E5',
- bnot: '\u2310',
- bopf: '\uD835\uDD53',
- bot: '\u22A5',
- bottom: '\u22A5',
- bowtie: '\u22C8',
- boxDL: '\u2557',
- boxDR: '\u2554',
- boxDl: '\u2556',
- boxDr: '\u2553',
- boxH: '\u2550',
- boxHD: '\u2566',
- boxHU: '\u2569',
- boxHd: '\u2564',
- boxHu: '\u2567',
- boxUL: '\u255D',
- boxUR: '\u255A',
- boxUl: '\u255C',
- boxUr: '\u2559',
- boxV: '\u2551',
- boxVH: '\u256C',
- boxVL: '\u2563',
- boxVR: '\u2560',
- boxVh: '\u256B',
- boxVl: '\u2562',
- boxVr: '\u255F',
- boxbox: '\u29C9',
- boxdL: '\u2555',
- boxdR: '\u2552',
- boxdl: '\u2510',
- boxdr: '\u250C',
- boxh: '\u2500',
- boxhD: '\u2565',
- boxhU: '\u2568',
- boxhd: '\u252C',
- boxhu: '\u2534',
- boxminus: '\u229F',
- boxplus: '\u229E',
- boxtimes: '\u22A0',
- boxuL: '\u255B',
- boxuR: '\u2558',
- boxul: '\u2518',
- boxur: '\u2514',
- boxv: '\u2502',
- boxvH: '\u256A',
- boxvL: '\u2561',
- boxvR: '\u255E',
- boxvh: '\u253C',
- boxvl: '\u2524',
- boxvr: '\u251C',
- bprime: '\u2035',
- breve: '\u02D8',
- brvbar: '\u00A6',
- bscr: '\uD835\uDCB7',
- bsemi: '\u204F',
- bsim: '\u223D',
- bsime: '\u22CD',
- bsol: '\u005C',
- bsolb: '\u29C5',
- bsolhsub: '\u27C8',
- bull: '\u2022',
- bullet: '\u2022',
- bump: '\u224E',
- bumpE: '\u2AAE',
- bumpe: '\u224F',
- bumpeq: '\u224F',
- cacute: '\u0107',
- cap: '\u2229',
- capand: '\u2A44',
- capbrcup: '\u2A49',
- capcap: '\u2A4B',
- capcup: '\u2A47',
- capdot: '\u2A40',
- caps: '\u2229\uFE00',
- caret: '\u2041',
- caron: '\u02C7',
- ccaps: '\u2A4D',
- ccaron: '\u010D',
- ccedil: '\u00E7',
- ccirc: '\u0109',
- ccups: '\u2A4C',
- ccupssm: '\u2A50',
- cdot: '\u010B',
- cedil: '\u00B8',
- cemptyv: '\u29B2',
- cent: '\u00A2',
- centerdot: '\u00B7',
- cfr: '\uD835\uDD20',
- chcy: '\u0447',
- check: '\u2713',
- checkmark: '\u2713',
- chi: '\u03C7',
- cir: '\u25CB',
- cirE: '\u29C3',
- circ: '\u02C6',
- circeq: '\u2257',
- circlearrowleft: '\u21BA',
- circlearrowright: '\u21BB',
- circledR: '\u00AE',
- circledS: '\u24C8',
- circledast: '\u229B',
- circledcirc: '\u229A',
- circleddash: '\u229D',
- cire: '\u2257',
- cirfnint: '\u2A10',
- cirmid: '\u2AEF',
- cirscir: '\u29C2',
- clubs: '\u2663',
- clubsuit: '\u2663',
- colon: '\u003A',
- colone: '\u2254',
- coloneq: '\u2254',
- comma: '\u002C',
- commat: '\u0040',
- comp: '\u2201',
- compfn: '\u2218',
- complement: '\u2201',
- complexes: '\u2102',
- cong: '\u2245',
- congdot: '\u2A6D',
- conint: '\u222E',
- copf: '\uD835\uDD54',
- coprod: '\u2210',
- copy: '\u00A9',
- copysr: '\u2117',
- crarr: '\u21B5',
- cross: '\u2717',
- cscr: '\uD835\uDCB8',
- csub: '\u2ACF',
- csube: '\u2AD1',
- csup: '\u2AD0',
- csupe: '\u2AD2',
- ctdot: '\u22EF',
- cudarrl: '\u2938',
- cudarrr: '\u2935',
- cuepr: '\u22DE',
- cuesc: '\u22DF',
- cularr: '\u21B6',
- cularrp: '\u293D',
- cup: '\u222A',
- cupbrcap: '\u2A48',
- cupcap: '\u2A46',
- cupcup: '\u2A4A',
- cupdot: '\u228D',
- cupor: '\u2A45',
- cups: '\u222A\uFE00',
- curarr: '\u21B7',
- curarrm: '\u293C',
- curlyeqprec: '\u22DE',
- curlyeqsucc: '\u22DF',
- curlyvee: '\u22CE',
- curlywedge: '\u22CF',
- curren: '\u00A4',
- curvearrowleft: '\u21B6',
- curvearrowright: '\u21B7',
- cuvee: '\u22CE',
- cuwed: '\u22CF',
- cwconint: '\u2232',
- cwint: '\u2231',
- cylcty: '\u232D',
- dArr: '\u21D3',
- dHar: '\u2965',
- dagger: '\u2020',
- daleth: '\u2138',
- darr: '\u2193',
- dash: '\u2010',
- dashv: '\u22A3',
- dbkarow: '\u290F',
- dblac: '\u02DD',
- dcaron: '\u010F',
- dcy: '\u0434',
- dd: '\u2146',
- ddagger: '\u2021',
- ddarr: '\u21CA',
- ddotseq: '\u2A77',
- deg: '\u00B0',
- delta: '\u03B4',
- demptyv: '\u29B1',
- dfisht: '\u297F',
- dfr: '\uD835\uDD21',
- dharl: '\u21C3',
- dharr: '\u21C2',
- diam: '\u22C4',
- diamond: '\u22C4',
- diamondsuit: '\u2666',
- diams: '\u2666',
- die: '\u00A8',
- digamma: '\u03DD',
- disin: '\u22F2',
- div: '\u00F7',
- divide: '\u00F7',
- divideontimes: '\u22C7',
- divonx: '\u22C7',
- djcy: '\u0452',
- dlcorn: '\u231E',
- dlcrop: '\u230D',
- dollar: '\u0024',
- dopf: '\uD835\uDD55',
- dot: '\u02D9',
- doteq: '\u2250',
- doteqdot: '\u2251',
- dotminus: '\u2238',
- dotplus: '\u2214',
- dotsquare: '\u22A1',
- doublebarwedge: '\u2306',
- downarrow: '\u2193',
- downdownarrows: '\u21CA',
- downharpoonleft: '\u21C3',
- downharpoonright: '\u21C2',
- drbkarow: '\u2910',
- drcorn: '\u231F',
- drcrop: '\u230C',
- dscr: '\uD835\uDCB9',
- dscy: '\u0455',
- dsol: '\u29F6',
- dstrok: '\u0111',
- dtdot: '\u22F1',
- dtri: '\u25BF',
- dtrif: '\u25BE',
- duarr: '\u21F5',
- duhar: '\u296F',
- dwangle: '\u29A6',
- dzcy: '\u045F',
- dzigrarr: '\u27FF',
- eDDot: '\u2A77',
- eDot: '\u2251',
- eacute: '\u00E9',
- easter: '\u2A6E',
- ecaron: '\u011B',
- ecir: '\u2256',
- ecirc: '\u00EA',
- ecolon: '\u2255',
- ecy: '\u044D',
- edot: '\u0117',
- ee: '\u2147',
- efDot: '\u2252',
- efr: '\uD835\uDD22',
- eg: '\u2A9A',
- egrave: '\u00E8',
- egs: '\u2A96',
- egsdot: '\u2A98',
- el: '\u2A99',
- elinters: '\u23E7',
- ell: '\u2113',
- els: '\u2A95',
- elsdot: '\u2A97',
- emacr: '\u0113',
- empty: '\u2205',
- emptyset: '\u2205',
- emptyv: '\u2205',
- emsp13: '\u2004',
- emsp14: '\u2005',
- emsp: '\u2003',
- eng: '\u014B',
- ensp: '\u2002',
- eogon: '\u0119',
- eopf: '\uD835\uDD56',
- epar: '\u22D5',
- eparsl: '\u29E3',
- eplus: '\u2A71',
- epsi: '\u03B5',
- epsilon: '\u03B5',
- epsiv: '\u03F5',
- eqcirc: '\u2256',
- eqcolon: '\u2255',
- eqsim: '\u2242',
- eqslantgtr: '\u2A96',
- eqslantless: '\u2A95',
- equals: '\u003D',
- equest: '\u225F',
- equiv: '\u2261',
- equivDD: '\u2A78',
- eqvparsl: '\u29E5',
- erDot: '\u2253',
- erarr: '\u2971',
- escr: '\u212F',
- esdot: '\u2250',
- esim: '\u2242',
- eta: '\u03B7',
- eth: '\u00F0',
- euml: '\u00EB',
- euro: '\u20AC',
- excl: '\u0021',
- exist: '\u2203',
- expectation: '\u2130',
- exponentiale: '\u2147',
- fallingdotseq: '\u2252',
- fcy: '\u0444',
- female: '\u2640',
- ffilig: '\uFB03',
- fflig: '\uFB00',
- ffllig: '\uFB04',
- ffr: '\uD835\uDD23',
- filig: '\uFB01',
- fjlig: '\u0066\u006A',
- flat: '\u266D',
- fllig: '\uFB02',
- fltns: '\u25B1',
- fnof: '\u0192',
- fopf: '\uD835\uDD57',
- forall: '\u2200',
- fork: '\u22D4',
- forkv: '\u2AD9',
- fpartint: '\u2A0D',
- frac12: '\u00BD',
- frac13: '\u2153',
- frac14: '\u00BC',
- frac15: '\u2155',
- frac16: '\u2159',
- frac18: '\u215B',
- frac23: '\u2154',
- frac25: '\u2156',
- frac34: '\u00BE',
- frac35: '\u2157',
- frac38: '\u215C',
- frac45: '\u2158',
- frac56: '\u215A',
- frac58: '\u215D',
- frac78: '\u215E',
- frasl: '\u2044',
- frown: '\u2322',
- fscr: '\uD835\uDCBB',
- gE: '\u2267',
- gEl: '\u2A8C',
- gacute: '\u01F5',
- gamma: '\u03B3',
- gammad: '\u03DD',
- gap: '\u2A86',
- gbreve: '\u011F',
- gcirc: '\u011D',
- gcy: '\u0433',
- gdot: '\u0121',
- ge: '\u2265',
- gel: '\u22DB',
- geq: '\u2265',
- geqq: '\u2267',
- geqslant: '\u2A7E',
- ges: '\u2A7E',
- gescc: '\u2AA9',
- gesdot: '\u2A80',
- gesdoto: '\u2A82',
- gesdotol: '\u2A84',
- gesl: '\u22DB\uFE00',
- gesles: '\u2A94',
- gfr: '\uD835\uDD24',
- gg: '\u226B',
- ggg: '\u22D9',
- gimel: '\u2137',
- gjcy: '\u0453',
- gl: '\u2277',
- glE: '\u2A92',
- gla: '\u2AA5',
- glj: '\u2AA4',
- gnE: '\u2269',
- gnap: '\u2A8A',
- gnapprox: '\u2A8A',
- gne: '\u2A88',
- gneq: '\u2A88',
- gneqq: '\u2269',
- gnsim: '\u22E7',
- gopf: '\uD835\uDD58',
- grave: '\u0060',
- gscr: '\u210A',
- gsim: '\u2273',
- gsime: '\u2A8E',
- gsiml: '\u2A90',
- gt: '\u003E',
- gtcc: '\u2AA7',
- gtcir: '\u2A7A',
- gtdot: '\u22D7',
- gtlPar: '\u2995',
- gtquest: '\u2A7C',
- gtrapprox: '\u2A86',
- gtrarr: '\u2978',
- gtrdot: '\u22D7',
- gtreqless: '\u22DB',
- gtreqqless: '\u2A8C',
- gtrless: '\u2277',
- gtrsim: '\u2273',
- gvertneqq: '\u2269\uFE00',
- gvnE: '\u2269\uFE00',
- hArr: '\u21D4',
- hairsp: '\u200A',
- half: '\u00BD',
- hamilt: '\u210B',
- hardcy: '\u044A',
- harr: '\u2194',
- harrcir: '\u2948',
- harrw: '\u21AD',
- hbar: '\u210F',
- hcirc: '\u0125',
- hearts: '\u2665',
- heartsuit: '\u2665',
- hellip: '\u2026',
- hercon: '\u22B9',
- hfr: '\uD835\uDD25',
- hksearow: '\u2925',
- hkswarow: '\u2926',
- hoarr: '\u21FF',
- homtht: '\u223B',
- hookleftarrow: '\u21A9',
- hookrightarrow: '\u21AA',
- hopf: '\uD835\uDD59',
- horbar: '\u2015',
- hscr: '\uD835\uDCBD',
- hslash: '\u210F',
- hstrok: '\u0127',
- hybull: '\u2043',
- hyphen: '\u2010',
- iacute: '\u00ED',
- ic: '\u2063',
- icirc: '\u00EE',
- icy: '\u0438',
- iecy: '\u0435',
- iexcl: '\u00A1',
- iff: '\u21D4',
- ifr: '\uD835\uDD26',
- igrave: '\u00EC',
- ii: '\u2148',
- iiiint: '\u2A0C',
- iiint: '\u222D',
- iinfin: '\u29DC',
- iiota: '\u2129',
- ijlig: '\u0133',
- imacr: '\u012B',
- image: '\u2111',
- imagline: '\u2110',
- imagpart: '\u2111',
- imath: '\u0131',
- imof: '\u22B7',
- imped: '\u01B5',
- in: '\u2208',
- incare: '\u2105',
- infin: '\u221E',
- infintie: '\u29DD',
- inodot: '\u0131',
- int: '\u222B',
- intcal: '\u22BA',
- integers: '\u2124',
- intercal: '\u22BA',
- intlarhk: '\u2A17',
- intprod: '\u2A3C',
- iocy: '\u0451',
- iogon: '\u012F',
- iopf: '\uD835\uDD5A',
- iota: '\u03B9',
- iprod: '\u2A3C',
- iquest: '\u00BF',
- iscr: '\uD835\uDCBE',
- isin: '\u2208',
- isinE: '\u22F9',
- isindot: '\u22F5',
- isins: '\u22F4',
- isinsv: '\u22F3',
- isinv: '\u2208',
- it: '\u2062',
- itilde: '\u0129',
- iukcy: '\u0456',
- iuml: '\u00EF',
- jcirc: '\u0135',
- jcy: '\u0439',
- jfr: '\uD835\uDD27',
- jmath: '\u0237',
- jopf: '\uD835\uDD5B',
- jscr: '\uD835\uDCBF',
- jsercy: '\u0458',
- jukcy: '\u0454',
- kappa: '\u03BA',
- kappav: '\u03F0',
- kcedil: '\u0137',
- kcy: '\u043A',
- kfr: '\uD835\uDD28',
- kgreen: '\u0138',
- khcy: '\u0445',
- kjcy: '\u045C',
- kopf: '\uD835\uDD5C',
- kscr: '\uD835\uDCC0',
- lAarr: '\u21DA',
- lArr: '\u21D0',
- lAtail: '\u291B',
- lBarr: '\u290E',
- lE: '\u2266',
- lEg: '\u2A8B',
- lHar: '\u2962',
- lacute: '\u013A',
- laemptyv: '\u29B4',
- lagran: '\u2112',
- lambda: '\u03BB',
- lang: '\u27E8',
- langd: '\u2991',
- langle: '\u27E8',
- lap: '\u2A85',
- laquo: '\u00AB',
- larr: '\u2190',
- larrb: '\u21E4',
- larrbfs: '\u291F',
- larrfs: '\u291D',
- larrhk: '\u21A9',
- larrlp: '\u21AB',
- larrpl: '\u2939',
- larrsim: '\u2973',
- larrtl: '\u21A2',
- lat: '\u2AAB',
- latail: '\u2919',
- late: '\u2AAD',
- lates: '\u2AAD\uFE00',
- lbarr: '\u290C',
- lbbrk: '\u2772',
- lbrace: '\u007B',
- lbrack: '\u005B',
- lbrke: '\u298B',
- lbrksld: '\u298F',
- lbrkslu: '\u298D',
- lcaron: '\u013E',
- lcedil: '\u013C',
- lceil: '\u2308',
- lcub: '\u007B',
- lcy: '\u043B',
- ldca: '\u2936',
- ldquo: '\u201C',
- ldquor: '\u201E',
- ldrdhar: '\u2967',
- ldrushar: '\u294B',
- ldsh: '\u21B2',
- le: '\u2264',
- leftarrow: '\u2190',
- leftarrowtail: '\u21A2',
- leftharpoondown: '\u21BD',
- leftharpoonup: '\u21BC',
- leftleftarrows: '\u21C7',
- leftrightarrow: '\u2194',
- leftrightarrows: '\u21C6',
- leftrightharpoons: '\u21CB',
- leftrightsquigarrow: '\u21AD',
- leftthreetimes: '\u22CB',
- leg: '\u22DA',
- leq: '\u2264',
- leqq: '\u2266',
- leqslant: '\u2A7D',
- les: '\u2A7D',
- lescc: '\u2AA8',
- lesdot: '\u2A7F',
- lesdoto: '\u2A81',
- lesdotor: '\u2A83',
- lesg: '\u22DA\uFE00',
- lesges: '\u2A93',
- lessapprox: '\u2A85',
- lessdot: '\u22D6',
- lesseqgtr: '\u22DA',
- lesseqqgtr: '\u2A8B',
- lessgtr: '\u2276',
- lesssim: '\u2272',
- lfisht: '\u297C',
- lfloor: '\u230A',
- lfr: '\uD835\uDD29',
- lg: '\u2276',
- lgE: '\u2A91',
- lhard: '\u21BD',
- lharu: '\u21BC',
- lharul: '\u296A',
- lhblk: '\u2584',
- ljcy: '\u0459',
- ll: '\u226A',
- llarr: '\u21C7',
- llcorner: '\u231E',
- llhard: '\u296B',
- lltri: '\u25FA',
- lmidot: '\u0140',
- lmoust: '\u23B0',
- lmoustache: '\u23B0',
- lnE: '\u2268',
- lnap: '\u2A89',
- lnapprox: '\u2A89',
- lne: '\u2A87',
- lneq: '\u2A87',
- lneqq: '\u2268',
- lnsim: '\u22E6',
- loang: '\u27EC',
- loarr: '\u21FD',
- lobrk: '\u27E6',
- longleftarrow: '\u27F5',
- longleftrightarrow: '\u27F7',
- longmapsto: '\u27FC',
- longrightarrow: '\u27F6',
- looparrowleft: '\u21AB',
- looparrowright: '\u21AC',
- lopar: '\u2985',
- lopf: '\uD835\uDD5D',
- loplus: '\u2A2D',
- lotimes: '\u2A34',
- lowast: '\u2217',
- lowbar: '\u005F',
- loz: '\u25CA',
- lozenge: '\u25CA',
- lozf: '\u29EB',
- lpar: '\u0028',
- lparlt: '\u2993',
- lrarr: '\u21C6',
- lrcorner: '\u231F',
- lrhar: '\u21CB',
- lrhard: '\u296D',
- lrm: '\u200E',
- lrtri: '\u22BF',
- lsaquo: '\u2039',
- lscr: '\uD835\uDCC1',
- lsh: '\u21B0',
- lsim: '\u2272',
- lsime: '\u2A8D',
- lsimg: '\u2A8F',
- lsqb: '\u005B',
- lsquo: '\u2018',
- lsquor: '\u201A',
- lstrok: '\u0142',
- lt: '\u003C',
- ltcc: '\u2AA6',
- ltcir: '\u2A79',
- ltdot: '\u22D6',
- lthree: '\u22CB',
- ltimes: '\u22C9',
- ltlarr: '\u2976',
- ltquest: '\u2A7B',
- ltrPar: '\u2996',
- ltri: '\u25C3',
- ltrie: '\u22B4',
- ltrif: '\u25C2',
- lurdshar: '\u294A',
- luruhar: '\u2966',
- lvertneqq: '\u2268\uFE00',
- lvnE: '\u2268\uFE00',
- mDDot: '\u223A',
- macr: '\u00AF',
- male: '\u2642',
- malt: '\u2720',
- maltese: '\u2720',
- map: '\u21A6',
- mapsto: '\u21A6',
- mapstodown: '\u21A7',
- mapstoleft: '\u21A4',
- mapstoup: '\u21A5',
- marker: '\u25AE',
- mcomma: '\u2A29',
- mcy: '\u043C',
- mdash: '\u2014',
- measuredangle: '\u2221',
- mfr: '\uD835\uDD2A',
- mho: '\u2127',
- micro: '\u00B5',
- mid: '\u2223',
- midast: '\u002A',
- midcir: '\u2AF0',
- middot: '\u00B7',
- minus: '\u2212',
- minusb: '\u229F',
- minusd: '\u2238',
- minusdu: '\u2A2A',
- mlcp: '\u2ADB',
- mldr: '\u2026',
- mnplus: '\u2213',
- models: '\u22A7',
- mopf: '\uD835\uDD5E',
- mp: '\u2213',
- mscr: '\uD835\uDCC2',
- mstpos: '\u223E',
- mu: '\u03BC',
- multimap: '\u22B8',
- mumap: '\u22B8',
- nGg: '\u22D9\u0338',
- nGt: '\u226B\u20D2',
- nGtv: '\u226B\u0338',
- nLeftarrow: '\u21CD',
- nLeftrightarrow: '\u21CE',
- nLl: '\u22D8\u0338',
- nLt: '\u226A\u20D2',
- nLtv: '\u226A\u0338',
- nRightarrow: '\u21CF',
- nVDash: '\u22AF',
- nVdash: '\u22AE',
- nabla: '\u2207',
- nacute: '\u0144',
- nang: '\u2220\u20D2',
- nap: '\u2249',
- napE: '\u2A70\u0338',
- napid: '\u224B\u0338',
- napos: '\u0149',
- napprox: '\u2249',
- natur: '\u266E',
- natural: '\u266E',
- naturals: '\u2115',
- nbsp: '\u00A0',
- nbump: '\u224E\u0338',
- nbumpe: '\u224F\u0338',
- ncap: '\u2A43',
- ncaron: '\u0148',
- ncedil: '\u0146',
- ncong: '\u2247',
- ncongdot: '\u2A6D\u0338',
- ncup: '\u2A42',
- ncy: '\u043D',
- ndash: '\u2013',
- ne: '\u2260',
- neArr: '\u21D7',
- nearhk: '\u2924',
- nearr: '\u2197',
- nearrow: '\u2197',
- nedot: '\u2250\u0338',
- nequiv: '\u2262',
- nesear: '\u2928',
- nesim: '\u2242\u0338',
- nexist: '\u2204',
- nexists: '\u2204',
- nfr: '\uD835\uDD2B',
- ngE: '\u2267\u0338',
- nge: '\u2271',
- ngeq: '\u2271',
- ngeqq: '\u2267\u0338',
- ngeqslant: '\u2A7E\u0338',
- nges: '\u2A7E\u0338',
- ngsim: '\u2275',
- ngt: '\u226F',
- ngtr: '\u226F',
- nhArr: '\u21CE',
- nharr: '\u21AE',
- nhpar: '\u2AF2',
- ni: '\u220B',
- nis: '\u22FC',
- nisd: '\u22FA',
- niv: '\u220B',
- njcy: '\u045A',
- nlArr: '\u21CD',
- nlE: '\u2266\u0338',
- nlarr: '\u219A',
- nldr: '\u2025',
- nle: '\u2270',
- nleftarrow: '\u219A',
- nleftrightarrow: '\u21AE',
- nleq: '\u2270',
- nleqq: '\u2266\u0338',
- nleqslant: '\u2A7D\u0338',
- nles: '\u2A7D\u0338',
- nless: '\u226E',
- nlsim: '\u2274',
- nlt: '\u226E',
- nltri: '\u22EA',
- nltrie: '\u22EC',
- nmid: '\u2224',
- nopf: '\uD835\uDD5F',
- not: '\u00AC',
- notin: '\u2209',
- notinE: '\u22F9\u0338',
- notindot: '\u22F5\u0338',
- notinva: '\u2209',
- notinvb: '\u22F7',
- notinvc: '\u22F6',
- notni: '\u220C',
- notniva: '\u220C',
- notnivb: '\u22FE',
- notnivc: '\u22FD',
- npar: '\u2226',
- nparallel: '\u2226',
- nparsl: '\u2AFD\u20E5',
- npart: '\u2202\u0338',
- npolint: '\u2A14',
- npr: '\u2280',
- nprcue: '\u22E0',
- npre: '\u2AAF\u0338',
- nprec: '\u2280',
- npreceq: '\u2AAF\u0338',
- nrArr: '\u21CF',
- nrarr: '\u219B',
- nrarrc: '\u2933\u0338',
- nrarrw: '\u219D\u0338',
- nrightarrow: '\u219B',
- nrtri: '\u22EB',
- nrtrie: '\u22ED',
- nsc: '\u2281',
- nsccue: '\u22E1',
- nsce: '\u2AB0\u0338',
- nscr: '\uD835\uDCC3',
- nshortmid: '\u2224',
- nshortparallel: '\u2226',
- nsim: '\u2241',
- nsime: '\u2244',
- nsimeq: '\u2244',
- nsmid: '\u2224',
- nspar: '\u2226',
- nsqsube: '\u22E2',
- nsqsupe: '\u22E3',
- nsub: '\u2284',
- nsubE: '\u2AC5\u0338',
- nsube: '\u2288',
- nsubset: '\u2282\u20D2',
- nsubseteq: '\u2288',
- nsubseteqq: '\u2AC5\u0338',
- nsucc: '\u2281',
- nsucceq: '\u2AB0\u0338',
- nsup: '\u2285',
- nsupE: '\u2AC6\u0338',
- nsupe: '\u2289',
- nsupset: '\u2283\u20D2',
- nsupseteq: '\u2289',
- nsupseteqq: '\u2AC6\u0338',
- ntgl: '\u2279',
- ntilde: '\u00F1',
- ntlg: '\u2278',
- ntriangleleft: '\u22EA',
- ntrianglelefteq: '\u22EC',
- ntriangleright: '\u22EB',
- ntrianglerighteq: '\u22ED',
- nu: '\u03BD',
- num: '\u0023',
- numero: '\u2116',
- numsp: '\u2007',
- nvDash: '\u22AD',
- nvHarr: '\u2904',
- nvap: '\u224D\u20D2',
- nvdash: '\u22AC',
- nvge: '\u2265\u20D2',
- nvgt: '\u003E\u20D2',
- nvinfin: '\u29DE',
- nvlArr: '\u2902',
- nvle: '\u2264\u20D2',
- nvlt: '\u003C\u20D2',
- nvltrie: '\u22B4\u20D2',
- nvrArr: '\u2903',
- nvrtrie: '\u22B5\u20D2',
- nvsim: '\u223C\u20D2',
- nwArr: '\u21D6',
- nwarhk: '\u2923',
- nwarr: '\u2196',
- nwarrow: '\u2196',
- nwnear: '\u2927',
- oS: '\u24C8',
- oacute: '\u00F3',
- oast: '\u229B',
- ocir: '\u229A',
- ocirc: '\u00F4',
- ocy: '\u043E',
- odash: '\u229D',
- odblac: '\u0151',
- odiv: '\u2A38',
- odot: '\u2299',
- odsold: '\u29BC',
- oelig: '\u0153',
- ofcir: '\u29BF',
- ofr: '\uD835\uDD2C',
- ogon: '\u02DB',
- ograve: '\u00F2',
- ogt: '\u29C1',
- ohbar: '\u29B5',
- ohm: '\u03A9',
- oint: '\u222E',
- olarr: '\u21BA',
- olcir: '\u29BE',
- olcross: '\u29BB',
- oline: '\u203E',
- olt: '\u29C0',
- omacr: '\u014D',
- omega: '\u03C9',
- omicron: '\u03BF',
- omid: '\u29B6',
- ominus: '\u2296',
- oopf: '\uD835\uDD60',
- opar: '\u29B7',
- operp: '\u29B9',
- oplus: '\u2295',
- or: '\u2228',
- orarr: '\u21BB',
- ord: '\u2A5D',
- order: '\u2134',
- orderof: '\u2134',
- ordf: '\u00AA',
- ordm: '\u00BA',
- origof: '\u22B6',
- oror: '\u2A56',
- orslope: '\u2A57',
- orv: '\u2A5B',
- oscr: '\u2134',
- oslash: '\u00F8',
- osol: '\u2298',
- otilde: '\u00F5',
- otimes: '\u2297',
- otimesas: '\u2A36',
- ouml: '\u00F6',
- ovbar: '\u233D',
- par: '\u2225',
- para: '\u00B6',
- parallel: '\u2225',
- parsim: '\u2AF3',
- parsl: '\u2AFD',
- part: '\u2202',
- pcy: '\u043F',
- percnt: '\u0025',
- period: '\u002E',
- permil: '\u2030',
- perp: '\u22A5',
- pertenk: '\u2031',
- pfr: '\uD835\uDD2D',
- phi: '\u03C6',
- phiv: '\u03D5',
- phmmat: '\u2133',
- phone: '\u260E',
- pi: '\u03C0',
- pitchfork: '\u22D4',
- piv: '\u03D6',
- planck: '\u210F',
- planckh: '\u210E',
- plankv: '\u210F',
- plus: '\u002B',
- plusacir: '\u2A23',
- plusb: '\u229E',
- pluscir: '\u2A22',
- plusdo: '\u2214',
- plusdu: '\u2A25',
- pluse: '\u2A72',
- plusmn: '\u00B1',
- plussim: '\u2A26',
- plustwo: '\u2A27',
- pm: '\u00B1',
- pointint: '\u2A15',
- popf: '\uD835\uDD61',
- pound: '\u00A3',
- pr: '\u227A',
- prE: '\u2AB3',
- prap: '\u2AB7',
- prcue: '\u227C',
- pre: '\u2AAF',
- prec: '\u227A',
- precapprox: '\u2AB7',
- preccurlyeq: '\u227C',
- preceq: '\u2AAF',
- precnapprox: '\u2AB9',
- precneqq: '\u2AB5',
- precnsim: '\u22E8',
- precsim: '\u227E',
- prime: '\u2032',
- primes: '\u2119',
- prnE: '\u2AB5',
- prnap: '\u2AB9',
- prnsim: '\u22E8',
- prod: '\u220F',
- profalar: '\u232E',
- profline: '\u2312',
- profsurf: '\u2313',
- prop: '\u221D',
- propto: '\u221D',
- prsim: '\u227E',
- prurel: '\u22B0',
- pscr: '\uD835\uDCC5',
- psi: '\u03C8',
- puncsp: '\u2008',
- qfr: '\uD835\uDD2E',
- qint: '\u2A0C',
- qopf: '\uD835\uDD62',
- qprime: '\u2057',
- qscr: '\uD835\uDCC6',
- quaternions: '\u210D',
- quatint: '\u2A16',
- quest: '\u003F',
- questeq: '\u225F',
- quot: '\u0022',
- rAarr: '\u21DB',
- rArr: '\u21D2',
- rAtail: '\u291C',
- rBarr: '\u290F',
- rHar: '\u2964',
- race: '\u223D\u0331',
- racute: '\u0155',
- radic: '\u221A',
- raemptyv: '\u29B3',
- rang: '\u27E9',
- rangd: '\u2992',
- range: '\u29A5',
- rangle: '\u27E9',
- raquo: '\u00BB',
- rarr: '\u2192',
- rarrap: '\u2975',
- rarrb: '\u21E5',
- rarrbfs: '\u2920',
- rarrc: '\u2933',
- rarrfs: '\u291E',
- rarrhk: '\u21AA',
- rarrlp: '\u21AC',
- rarrpl: '\u2945',
- rarrsim: '\u2974',
- rarrtl: '\u21A3',
- rarrw: '\u219D',
- ratail: '\u291A',
- ratio: '\u2236',
- rationals: '\u211A',
- rbarr: '\u290D',
- rbbrk: '\u2773',
- rbrace: '\u007D',
- rbrack: '\u005D',
- rbrke: '\u298C',
- rbrksld: '\u298E',
- rbrkslu: '\u2990',
- rcaron: '\u0159',
- rcedil: '\u0157',
- rceil: '\u2309',
- rcub: '\u007D',
- rcy: '\u0440',
- rdca: '\u2937',
- rdldhar: '\u2969',
- rdquo: '\u201D',
- rdquor: '\u201D',
- rdsh: '\u21B3',
- real: '\u211C',
- realine: '\u211B',
- realpart: '\u211C',
- reals: '\u211D',
- rect: '\u25AD',
- reg: '\u00AE',
- rfisht: '\u297D',
- rfloor: '\u230B',
- rfr: '\uD835\uDD2F',
- rhard: '\u21C1',
- rharu: '\u21C0',
- rharul: '\u296C',
- rho: '\u03C1',
- rhov: '\u03F1',
- rightarrow: '\u2192',
- rightarrowtail: '\u21A3',
- rightharpoondown: '\u21C1',
- rightharpoonup: '\u21C0',
- rightleftarrows: '\u21C4',
- rightleftharpoons: '\u21CC',
- rightrightarrows: '\u21C9',
- rightsquigarrow: '\u219D',
- rightthreetimes: '\u22CC',
- ring: '\u02DA',
- risingdotseq: '\u2253',
- rlarr: '\u21C4',
- rlhar: '\u21CC',
- rlm: '\u200F',
- rmoust: '\u23B1',
- rmoustache: '\u23B1',
- rnmid: '\u2AEE',
- roang: '\u27ED',
- roarr: '\u21FE',
- robrk: '\u27E7',
- ropar: '\u2986',
- ropf: '\uD835\uDD63',
- roplus: '\u2A2E',
- rotimes: '\u2A35',
- rpar: '\u0029',
- rpargt: '\u2994',
- rppolint: '\u2A12',
- rrarr: '\u21C9',
- rsaquo: '\u203A',
- rscr: '\uD835\uDCC7',
- rsh: '\u21B1',
- rsqb: '\u005D',
- rsquo: '\u2019',
- rsquor: '\u2019',
- rthree: '\u22CC',
- rtimes: '\u22CA',
- rtri: '\u25B9',
- rtrie: '\u22B5',
- rtrif: '\u25B8',
- rtriltri: '\u29CE',
- ruluhar: '\u2968',
- rx: '\u211E',
- sacute: '\u015B',
- sbquo: '\u201A',
- sc: '\u227B',
- scE: '\u2AB4',
- scap: '\u2AB8',
- scaron: '\u0161',
- sccue: '\u227D',
- sce: '\u2AB0',
- scedil: '\u015F',
- scirc: '\u015D',
- scnE: '\u2AB6',
- scnap: '\u2ABA',
- scnsim: '\u22E9',
- scpolint: '\u2A13',
- scsim: '\u227F',
- scy: '\u0441',
- sdot: '\u22C5',
- sdotb: '\u22A1',
- sdote: '\u2A66',
- seArr: '\u21D8',
- searhk: '\u2925',
- searr: '\u2198',
- searrow: '\u2198',
- sect: '\u00A7',
- semi: '\u003B',
- seswar: '\u2929',
- setminus: '\u2216',
- setmn: '\u2216',
- sext: '\u2736',
- sfr: '\uD835\uDD30',
- sfrown: '\u2322',
- sharp: '\u266F',
- shchcy: '\u0449',
- shcy: '\u0448',
- shortmid: '\u2223',
- shortparallel: '\u2225',
- shy: '\u00AD',
- sigma: '\u03C3',
- sigmaf: '\u03C2',
- sigmav: '\u03C2',
- sim: '\u223C',
- simdot: '\u2A6A',
- sime: '\u2243',
- simeq: '\u2243',
- simg: '\u2A9E',
- simgE: '\u2AA0',
- siml: '\u2A9D',
- simlE: '\u2A9F',
- simne: '\u2246',
- simplus: '\u2A24',
- simrarr: '\u2972',
- slarr: '\u2190',
- smallsetminus: '\u2216',
- smashp: '\u2A33',
- smeparsl: '\u29E4',
- smid: '\u2223',
- smile: '\u2323',
- smt: '\u2AAA',
- smte: '\u2AAC',
- smtes: '\u2AAC\uFE00',
- softcy: '\u044C',
- sol: '\u002F',
- solb: '\u29C4',
- solbar: '\u233F',
- sopf: '\uD835\uDD64',
- spades: '\u2660',
- spadesuit: '\u2660',
- spar: '\u2225',
- sqcap: '\u2293',
- sqcaps: '\u2293\uFE00',
- sqcup: '\u2294',
- sqcups: '\u2294\uFE00',
- sqsub: '\u228F',
- sqsube: '\u2291',
- sqsubset: '\u228F',
- sqsubseteq: '\u2291',
- sqsup: '\u2290',
- sqsupe: '\u2292',
- sqsupset: '\u2290',
- sqsupseteq: '\u2292',
- squ: '\u25A1',
- square: '\u25A1',
- squarf: '\u25AA',
- squf: '\u25AA',
- srarr: '\u2192',
- sscr: '\uD835\uDCC8',
- ssetmn: '\u2216',
- ssmile: '\u2323',
- sstarf: '\u22C6',
- star: '\u2606',
- starf: '\u2605',
- straightepsilon: '\u03F5',
- straightphi: '\u03D5',
- strns: '\u00AF',
- sub: '\u2282',
- subE: '\u2AC5',
- subdot: '\u2ABD',
- sube: '\u2286',
- subedot: '\u2AC3',
- submult: '\u2AC1',
- subnE: '\u2ACB',
- subne: '\u228A',
- subplus: '\u2ABF',
- subrarr: '\u2979',
- subset: '\u2282',
- subseteq: '\u2286',
- subseteqq: '\u2AC5',
- subsetneq: '\u228A',
- subsetneqq: '\u2ACB',
- subsim: '\u2AC7',
- subsub: '\u2AD5',
- subsup: '\u2AD3',
- succ: '\u227B',
- succapprox: '\u2AB8',
- succcurlyeq: '\u227D',
- succeq: '\u2AB0',
- succnapprox: '\u2ABA',
- succneqq: '\u2AB6',
- succnsim: '\u22E9',
- succsim: '\u227F',
- sum: '\u2211',
- sung: '\u266A',
- sup1: '\u00B9',
- sup2: '\u00B2',
- sup3: '\u00B3',
- sup: '\u2283',
- supE: '\u2AC6',
- supdot: '\u2ABE',
- supdsub: '\u2AD8',
- supe: '\u2287',
- supedot: '\u2AC4',
- suphsol: '\u27C9',
- suphsub: '\u2AD7',
- suplarr: '\u297B',
- supmult: '\u2AC2',
- supnE: '\u2ACC',
- supne: '\u228B',
- supplus: '\u2AC0',
- supset: '\u2283',
- supseteq: '\u2287',
- supseteqq: '\u2AC6',
- supsetneq: '\u228B',
- supsetneqq: '\u2ACC',
- supsim: '\u2AC8',
- supsub: '\u2AD4',
- supsup: '\u2AD6',
- swArr: '\u21D9',
- swarhk: '\u2926',
- swarr: '\u2199',
- swarrow: '\u2199',
- swnwar: '\u292A',
- szlig: '\u00DF',
- target: '\u2316',
- tau: '\u03C4',
- tbrk: '\u23B4',
- tcaron: '\u0165',
- tcedil: '\u0163',
- tcy: '\u0442',
- tdot: '\u20DB',
- telrec: '\u2315',
- tfr: '\uD835\uDD31',
- there4: '\u2234',
- therefore: '\u2234',
- theta: '\u03B8',
- thetasym: '\u03D1',
- thetav: '\u03D1',
- thickapprox: '\u2248',
- thicksim: '\u223C',
- thinsp: '\u2009',
- thkap: '\u2248',
- thksim: '\u223C',
- thorn: '\u00FE',
- tilde: '\u02DC',
- times: '\u00D7',
- timesb: '\u22A0',
- timesbar: '\u2A31',
- timesd: '\u2A30',
- tint: '\u222D',
- toea: '\u2928',
- top: '\u22A4',
- topbot: '\u2336',
- topcir: '\u2AF1',
- topf: '\uD835\uDD65',
- topfork: '\u2ADA',
- tosa: '\u2929',
- tprime: '\u2034',
- trade: '\u2122',
- triangle: '\u25B5',
- triangledown: '\u25BF',
- triangleleft: '\u25C3',
- trianglelefteq: '\u22B4',
- triangleq: '\u225C',
- triangleright: '\u25B9',
- trianglerighteq: '\u22B5',
- tridot: '\u25EC',
- trie: '\u225C',
- triminus: '\u2A3A',
- triplus: '\u2A39',
- trisb: '\u29CD',
- tritime: '\u2A3B',
- trpezium: '\u23E2',
- tscr: '\uD835\uDCC9',
- tscy: '\u0446',
- tshcy: '\u045B',
- tstrok: '\u0167',
- twixt: '\u226C',
- twoheadleftarrow: '\u219E',
- twoheadrightarrow: '\u21A0',
- uArr: '\u21D1',
- uHar: '\u2963',
- uacute: '\u00FA',
- uarr: '\u2191',
- ubrcy: '\u045E',
- ubreve: '\u016D',
- ucirc: '\u00FB',
- ucy: '\u0443',
- udarr: '\u21C5',
- udblac: '\u0171',
- udhar: '\u296E',
- ufisht: '\u297E',
- ufr: '\uD835\uDD32',
- ugrave: '\u00F9',
- uharl: '\u21BF',
- uharr: '\u21BE',
- uhblk: '\u2580',
- ulcorn: '\u231C',
- ulcorner: '\u231C',
- ulcrop: '\u230F',
- ultri: '\u25F8',
- umacr: '\u016B',
- uml: '\u00A8',
- uogon: '\u0173',
- uopf: '\uD835\uDD66',
- uparrow: '\u2191',
- updownarrow: '\u2195',
- upharpoonleft: '\u21BF',
- upharpoonright: '\u21BE',
- uplus: '\u228E',
- upsi: '\u03C5',
- upsih: '\u03D2',
- upsilon: '\u03C5',
- upuparrows: '\u21C8',
- urcorn: '\u231D',
- urcorner: '\u231D',
- urcrop: '\u230E',
- uring: '\u016F',
- urtri: '\u25F9',
- uscr: '\uD835\uDCCA',
- utdot: '\u22F0',
- utilde: '\u0169',
- utri: '\u25B5',
- utrif: '\u25B4',
- uuarr: '\u21C8',
- uuml: '\u00FC',
- uwangle: '\u29A7',
- vArr: '\u21D5',
- vBar: '\u2AE8',
- vBarv: '\u2AE9',
- vDash: '\u22A8',
- vangrt: '\u299C',
- varepsilon: '\u03F5',
- varkappa: '\u03F0',
- varnothing: '\u2205',
- varphi: '\u03D5',
- varpi: '\u03D6',
- varpropto: '\u221D',
- varr: '\u2195',
- varrho: '\u03F1',
- varsigma: '\u03C2',
- varsubsetneq: '\u228A\uFE00',
- varsubsetneqq: '\u2ACB\uFE00',
- varsupsetneq: '\u228B\uFE00',
- varsupsetneqq: '\u2ACC\uFE00',
- vartheta: '\u03D1',
- vartriangleleft: '\u22B2',
- vartriangleright: '\u22B3',
- vcy: '\u0432',
- vdash: '\u22A2',
- vee: '\u2228',
- veebar: '\u22BB',
- veeeq: '\u225A',
- vellip: '\u22EE',
- verbar: '\u007C',
- vert: '\u007C',
- vfr: '\uD835\uDD33',
- vltri: '\u22B2',
- vnsub: '\u2282\u20D2',
- vnsup: '\u2283\u20D2',
- vopf: '\uD835\uDD67',
- vprop: '\u221D',
- vrtri: '\u22B3',
- vscr: '\uD835\uDCCB',
- vsubnE: '\u2ACB\uFE00',
- vsubne: '\u228A\uFE00',
- vsupnE: '\u2ACC\uFE00',
- vsupne: '\u228B\uFE00',
- vzigzag: '\u299A',
- wcirc: '\u0175',
- wedbar: '\u2A5F',
- wedge: '\u2227',
- wedgeq: '\u2259',
- weierp: '\u2118',
- wfr: '\uD835\uDD34',
- wopf: '\uD835\uDD68',
- wp: '\u2118',
- wr: '\u2240',
- wreath: '\u2240',
- wscr: '\uD835\uDCCC',
- xcap: '\u22C2',
- xcirc: '\u25EF',
- xcup: '\u22C3',
- xdtri: '\u25BD',
- xfr: '\uD835\uDD35',
- xhArr: '\u27FA',
- xharr: '\u27F7',
- xi: '\u03BE',
- xlArr: '\u27F8',
- xlarr: '\u27F5',
- xmap: '\u27FC',
- xnis: '\u22FB',
- xodot: '\u2A00',
- xopf: '\uD835\uDD69',
- xoplus: '\u2A01',
- xotime: '\u2A02',
- xrArr: '\u27F9',
- xrarr: '\u27F6',
- xscr: '\uD835\uDCCD',
- xsqcup: '\u2A06',
- xuplus: '\u2A04',
- xutri: '\u25B3',
- xvee: '\u22C1',
- xwedge: '\u22C0',
- yacute: '\u00FD',
- yacy: '\u044F',
- ycirc: '\u0177',
- ycy: '\u044B',
- yen: '\u00A5',
- yfr: '\uD835\uDD36',
- yicy: '\u0457',
- yopf: '\uD835\uDD6A',
- yscr: '\uD835\uDCCE',
- yucy: '\u044E',
- yuml: '\u00FF',
- zacute: '\u017A',
- zcaron: '\u017E',
- zcy: '\u0437',
- zdot: '\u017C',
- zeetrf: '\u2128',
- zeta: '\u03B6',
- zfr: '\uD835\uDD37',
- zhcy: '\u0436',
- zigrarr: '\u21DD',
- zopf: '\uD835\uDD6B',
- zscr: '\uD835\uDCCF',
- zwj: '\u200D',
- zwnj: '\u200C'
- };
- const decodeMap = {
- '0': 65533,
- '128': 8364,
- '130': 8218,
- '131': 402,
- '132': 8222,
- '133': 8230,
- '134': 8224,
- '135': 8225,
- '136': 710,
- '137': 8240,
- '138': 352,
- '139': 8249,
- '140': 338,
- '142': 381,
- '145': 8216,
- '146': 8217,
- '147': 8220,
- '148': 8221,
- '149': 8226,
- '150': 8211,
- '151': 8212,
- '152': 732,
- '153': 8482,
- '154': 353,
- '155': 8250,
- '156': 339,
- '158': 382,
- '159': 376
- };
- function decodeHTMLStrict(text) {
- return text.replace(/&(?:[a-zA-Z]+|#[xX][\da-fA-F]+|#\d+);/g, (key) => {
- if (key.charAt(1) === '#') {
- const secondChar = key.charAt(2);
- const codePoint = secondChar === 'X' || secondChar === 'x'
- ? parseInt(key.slice(3), 16)
- : parseInt(key.slice(2), 10);
- return decodeCodePoint(codePoint);
- }
- return entities[key.slice(1, -1)] || key;
- });
- }
- function decodeCodePoint(codePoint) {
- if ((codePoint >= 0xd800 && codePoint <= 0xdfff) || codePoint > 0x10ffff) {
- return '\uFFFD';
- }
- if (codePoint in decodeMap) {
- codePoint = decodeMap[codePoint];
- }
- return String.fromCodePoint(codePoint);
- }
- function scanJSXAttributeValue(parser, context) {
- parser.startPos = parser.tokenPos = parser.index;
- parser.startColumn = parser.colPos = parser.column;
- parser.startLine = parser.linePos = parser.line;
- parser.token =
- CharTypes[parser.currentChar] & 8192
- ? scanJSXString(parser, context)
- : scanSingleToken(parser, context, 0);
- return parser.token;
- }
- function scanJSXString(parser, context) {
- const quote = parser.currentChar;
- let char = advanceChar(parser);
- const start = parser.index;
- while (char !== quote) {
- if (parser.index >= parser.end)
- report(parser, 14);
- char = advanceChar(parser);
- }
- if (char !== quote)
- report(parser, 14);
- parser.tokenValue = parser.source.slice(start, parser.index);
- advanceChar(parser);
- if (context & 512)
- parser.tokenRaw = parser.source.slice(parser.tokenPos, parser.index);
- return 134283267;
- }
- function scanJSXToken(parser, context) {
- parser.startPos = parser.tokenPos = parser.index;
- parser.startColumn = parser.colPos = parser.column;
- parser.startLine = parser.linePos = parser.line;
- if (parser.index >= parser.end)
- return (parser.token = 1048576);
- const token = TokenLookup[parser.source.charCodeAt(parser.index)];
- switch (token) {
- case 8456258: {
- advanceChar(parser);
- if (parser.currentChar === 47) {
- advanceChar(parser);
- parser.token = 25;
- }
- else {
- parser.token = 8456258;
- }
- break;
- }
- case 2162700: {
- advanceChar(parser);
- parser.token = 2162700;
- break;
- }
- default: {
- let state = 0;
- while (parser.index < parser.end) {
- const type = CharTypes[parser.source.charCodeAt(parser.index)];
- if (type & 1024) {
- state |= 1 | 4;
- scanNewLine(parser);
- }
- else if (type & 2048) {
- consumeLineFeed(parser, state);
- state = (state & ~4) | 1;
- }
- else {
- advanceChar(parser);
- }
- if (CharTypes[parser.currentChar] & 16384)
- break;
- }
- const raw = parser.source.slice(parser.tokenPos, parser.index);
- if (context & 512)
- parser.tokenRaw = raw;
- parser.tokenValue = decodeHTMLStrict(raw);
- parser.token = 138;
- }
- }
- return parser.token;
- }
- function scanJSXIdentifier(parser) {
- if ((parser.token & 143360) === 143360) {
- const { index } = parser;
- let char = parser.currentChar;
- while (CharTypes[char] & (32768 | 2)) {
- char = advanceChar(parser);
- }
- parser.tokenValue += parser.source.slice(index, parser.index);
- }
- parser.token = 208897;
- return parser.token;
- }
- function matchOrInsertSemicolon(parser, context, specDeviation) {
- if ((parser.flags & 1) === 0 &&
- (parser.token & 1048576) !== 1048576 &&
- !specDeviation) {
- report(parser, 28, KeywordDescTable[parser.token & 255]);
- }
- consumeOpt(parser, context, 1074790417);
- }
- function isValidStrictMode(parser, index, tokenPos, tokenValue) {
- if (index - tokenPos < 13 && tokenValue === 'use strict') {
- if ((parser.token & 1048576) === 1048576 || parser.flags & 1) {
- return 1;
- }
- }
- return 0;
- }
- function optionalBit(parser, context, t) {
- if (parser.token !== t)
- return 0;
- nextToken(parser, context);
- return 1;
- }
- function consumeOpt(parser, context, t) {
- if (parser.token !== t)
- return false;
- nextToken(parser, context);
- return true;
- }
- function consume(parser, context, t) {
- if (parser.token !== t)
- report(parser, 23, KeywordDescTable[t & 255]);
- nextToken(parser, context);
- }
- function reinterpretToPattern(state, node) {
- switch (node.type) {
- case 'ArrayExpression':
- node.type = 'ArrayPattern';
- const elements = node.elements;
- for (let i = 0, n = elements.length; i < n; ++i) {
- const element = elements[i];
- if (element)
- reinterpretToPattern(state, element);
- }
- return;
- case 'ObjectExpression':
- node.type = 'ObjectPattern';
- const properties = node.properties;
- for (let i = 0, n = properties.length; i < n; ++i) {
- reinterpretToPattern(state, properties[i]);
- }
- return;
- case 'AssignmentExpression':
- node.type = 'AssignmentPattern';
- if (node.operator !== '=')
- report(state, 68);
- delete node.operator;
- reinterpretToPattern(state, node.left);
- return;
- case 'Property':
- reinterpretToPattern(state, node.value);
- return;
- case 'SpreadElement':
- node.type = 'RestElement';
- reinterpretToPattern(state, node.argument);
- }
- }
- function validateBindingIdentifier(parser, context, kind, t, skipEvalArgCheck) {
- if (context & 1024) {
- if ((t & 36864) === 36864) {
- report(parser, 114);
- }
- if (!skipEvalArgCheck && (t & 537079808) === 537079808) {
- report(parser, 115);
- }
- }
- if ((t & 20480) === 20480) {
- report(parser, 99);
- }
- if (kind & (8 | 16) && t === 241739) {
- report(parser, 97);
- }
- if (context & (4194304 | 2048) && t === 209008) {
- report(parser, 95);
- }
- if (context & (2097152 | 1024) && t === 241773) {
- report(parser, 94, 'yield');
- }
- }
- function validateFunctionName(parser, context, t) {
- if (context & 1024) {
- if ((t & 36864) === 36864) {
- report(parser, 114);
- }
- if ((t & 537079808) === 537079808) {
- report(parser, 115);
- }
- if (t === 122) {
- report(parser, 92);
- }
- if (t === 121) {
- report(parser, 92);
- }
- }
- if ((t & 20480) === 20480) {
- report(parser, 99);
- }
- if (context & (4194304 | 2048) && t === 209008) {
- report(parser, 95);
- }
- if (context & (2097152 | 1024) && t === 241773) {
- report(parser, 94, 'yield');
- }
- }
- function isStrictReservedWord(parser, context, t) {
- if (t === 209008) {
- if (context & (4194304 | 2048))
- report(parser, 95);
- parser.destructible |= 128;
- }
- if (t === 241773 && context & 2097152)
- report(parser, 94, 'yield');
- return ((t & 20480) === 20480 ||
- (t & 36864) === 36864 ||
- t == 122);
- }
- function isPropertyWithPrivateFieldKey(expr) {
- return !expr.property ? false : expr.property.type === 'PrivateIdentifier';
- }
- function isValidLabel(parser, labels, name, isIterationStatement) {
- while (labels) {
- if (labels['$' + name]) {
- if (isIterationStatement)
- report(parser, 133);
- return 1;
- }
- if (isIterationStatement && labels.loop)
- isIterationStatement = 0;
- labels = labels['$'];
- }
- return 0;
- }
- function validateAndDeclareLabel(parser, labels, name) {
- let set = labels;
- while (set) {
- if (set['$' + name])
- report(parser, 132, name);
- set = set['$'];
- }
- labels['$' + name] = 1;
- }
- function finishNode(parser, context, start, line, column, node) {
- if (context & 2) {
- node.start = start;
- node.end = parser.startPos;
- node.range = [start, parser.startPos];
- }
- if (context & 4) {
- node.loc = {
- start: {
- line,
- column
- },
- end: {
- line: parser.startLine,
- column: parser.startColumn
- }
- };
- if (parser.sourceFile) {
- node.loc.source = parser.sourceFile;
- }
- }
- return node;
- }
- function isEqualTagName(elementName) {
- switch (elementName.type) {
- case 'JSXIdentifier':
- return elementName.name;
- case 'JSXNamespacedName':
- return elementName.namespace + ':' + elementName.name;
- case 'JSXMemberExpression':
- return isEqualTagName(elementName.object) + '.' + isEqualTagName(elementName.property);
- }
- }
- function createArrowHeadParsingScope(parser, context, value) {
- const scope = addChildScope(createScope(), 1024);
- addBlockName(parser, context, scope, value, 1, 0);
- return scope;
- }
- function recordScopeError(parser, type, ...params) {
- const { index, line, column } = parser;
- return {
- type,
- params,
- index,
- line,
- column
- };
- }
- function createScope() {
- return {
- parent: void 0,
- type: 2
- };
- }
- function addChildScope(parent, type) {
- return {
- parent,
- type,
- scopeError: void 0
- };
- }
- function addVarOrBlock(parser, context, scope, name, kind, origin) {
- if (kind & 4) {
- addVarName(parser, context, scope, name, kind);
- }
- else {
- addBlockName(parser, context, scope, name, kind, origin);
- }
- if (origin & 64) {
- declareUnboundVariable(parser, name);
- }
- }
- function addBlockName(parser, context, scope, name, kind, origin) {
- const value = scope['#' + name];
- if (value && (value & 2) === 0) {
- if (kind & 1) {
- scope.scopeError = recordScopeError(parser, 140, name);
- }
- else if (context & 256 &&
- value & 64 &&
- origin & 2) ;
- else {
- report(parser, 140, name);
- }
- }
- if (scope.type & 128 &&
- (scope.parent['#' + name] && (scope.parent['#' + name] & 2) === 0)) {
- report(parser, 140, name);
- }
- if (scope.type & 1024 && value && (value & 2) === 0) {
- if (kind & 1) {
- scope.scopeError = recordScopeError(parser, 140, name);
- }
- }
- if (scope.type & 64) {
- if (scope.parent['#' + name] & 768)
- report(parser, 153, name);
- }
- scope['#' + name] = kind;
- }
- function addVarName(parser, context, scope, name, kind) {
- let currentScope = scope;
- while (currentScope && (currentScope.type & 256) === 0) {
- const value = currentScope['#' + name];
- if (value & 248) {
- if (context & 256 &&
- (context & 1024) === 0 &&
- ((kind & 128 && value & 68) ||
- (value & 128 && kind & 68))) ;
- else {
- report(parser, 140, name);
- }
- }
- if (currentScope === scope) {
- if (value & 1 && kind & 1) {
- currentScope.scopeError = recordScopeError(parser, 140, name);
- }
- }
- if (value & (512 | 256)) {
- if ((value & 512) === 0 ||
- (context & 256) === 0 ||
- context & 1024) {
- report(parser, 140, name);
- }
- }
- currentScope['#' + name] = kind;
- currentScope = currentScope.parent;
- }
- }
- function declareUnboundVariable(parser, name) {
- if (parser.exportedNames !== void 0 && name !== '') {
- if (parser.exportedNames['#' + name]) {
- report(parser, 141, name);
- }
- parser.exportedNames['#' + name] = 1;
- }
- }
- function addBindingToExports(parser, name) {
- if (parser.exportedBindings !== void 0 && name !== '') {
- parser.exportedBindings['#' + name] = 1;
- }
- }
- function pushComment(context, array) {
- return function (type, value, start, end, loc) {
- const comment = {
- type,
- value
- };
- if (context & 2) {
- comment.start = start;
- comment.end = end;
- comment.range = [start, end];
- }
- if (context & 4) {
- comment.loc = loc;
- }
- array.push(comment);
- };
- }
- function pushToken(context, array) {
- return function (token, start, end, loc) {
- const tokens = {
- token
- };
- if (context & 2) {
- tokens.start = start;
- tokens.end = end;
- tokens.range = [start, end];
- }
- if (context & 4) {
- tokens.loc = loc;
- }
- array.push(tokens);
- };
- }
- function isValidIdentifier(context, t) {
- if (context & (1024 | 2097152)) {
- if (context & 2048 && t === 209008)
- return false;
- if (context & 2097152 && t === 241773)
- return false;
- return (t & 143360) === 143360 || (t & 12288) === 12288;
- }
- return ((t & 143360) === 143360 ||
- (t & 12288) === 12288 ||
- (t & 36864) === 36864);
- }
- function classifyIdentifier(parser, context, t, isArrow) {
- if ((t & 537079808) === 537079808) {
- if (context & 1024)
- report(parser, 115);
- if (isArrow)
- parser.flags |= 512;
- }
- if (!isValidIdentifier(context, t))
- report(parser, 0);
- }
- function create(source, sourceFile, onComment, onToken) {
- return {
- source,
- flags: 0,
- index: 0,
- line: 1,
- column: 0,
- startPos: 0,
- end: source.length,
- tokenPos: 0,
- startColumn: 0,
- colPos: 0,
- linePos: 1,
- startLine: 1,
- sourceFile,
- tokenValue: '',
- token: 1048576,
- tokenRaw: '',
- tokenRegExp: void 0,
- currentChar: source.charCodeAt(0),
- exportedNames: [],
- exportedBindings: [],
- assignable: 1,
- destructible: 0,
- onComment,
- onToken,
- leadingDecorators: []
- };
- }
- function parseSource(source, options, context) {
- let sourceFile = '';
- let onComment;
- let onToken;
- if (options != null) {
- if (options.module)
- context |= 2048 | 1024;
- if (options.next)
- context |= 1;
- if (options.loc)
- context |= 4;
- if (options.ranges)
- context |= 2;
- if (options.uniqueKeyInPattern)
- context |= -2147483648;
- if (options.lexical)
- context |= 64;
- if (options.webcompat)
- context |= 256;
- if (options.directives)
- context |= 8 | 512;
- if (options.globalReturn)
- context |= 32;
- if (options.raw)
- context |= 512;
- if (options.preserveParens)
- context |= 128;
- if (options.impliedStrict)
- context |= 1024;
- if (options.jsx)
- context |= 16;
- if (options.identifierPattern)
- context |= 268435456;
- if (options.specDeviation)
- context |= 536870912;
- if (options.source)
- sourceFile = options.source;
- if (options.onComment != null) {
- onComment = Array.isArray(options.onComment) ? pushComment(context, options.onComment) : options.onComment;
- }
- if (options.onToken != null) {
- onToken = Array.isArray(options.onToken) ? pushToken(context, options.onToken) : options.onToken;
- }
- }
- const parser = create(source, sourceFile, onComment, onToken);
- if (context & 1)
- skipHashBang(parser);
- const scope = context & 64 ? createScope() : void 0;
- let body = [];
- let sourceType = 'script';
- if (context & 2048) {
- sourceType = 'module';
- body = parseModuleItemList(parser, context | 8192, scope);
- if (scope) {
- for (const key in parser.exportedBindings) {
- if (key[0] === '#' && !scope[key])
- report(parser, 142, key.slice(1));
- }
- }
- }
- else {
- body = parseStatementList(parser, context | 8192, scope);
- }
- const node = {
- type: 'Program',
- sourceType,
- body
- };
- if (context & 2) {
- node.start = 0;
- node.end = source.length;
- node.range = [0, source.length];
- }
- if (context & 4) {
- node.loc = {
- start: { line: 1, column: 0 },
- end: { line: parser.line, column: parser.column }
- };
- if (parser.sourceFile)
- node.loc.source = sourceFile;
- }
- return node;
- }
- function parseStatementList(parser, context, scope) {
- nextToken(parser, context | 32768 | 1073741824);
- const statements = [];
- while (parser.token === 134283267) {
- const { index, tokenPos, tokenValue, linePos, colPos, token } = parser;
- const expr = parseLiteral(parser, context);
- if (isValidStrictMode(parser, index, tokenPos, tokenValue))
- context |= 1024;
- statements.push(parseDirective(parser, context, expr, token, tokenPos, linePos, colPos));
- }
- while (parser.token !== 1048576) {
- statements.push(parseStatementListItem(parser, context, scope, 4, {}));
- }
- return statements;
- }
- function parseModuleItemList(parser, context, scope) {
- nextToken(parser, context | 32768);
- const statements = [];
- if (context & 8) {
- while (parser.token === 134283267) {
- const { tokenPos, linePos, colPos, token } = parser;
- statements.push(parseDirective(parser, context, parseLiteral(parser, context), token, tokenPos, linePos, colPos));
- }
- }
- while (parser.token !== 1048576) {
- statements.push(parseModuleItem(parser, context, scope));
- }
- return statements;
- }
- function parseModuleItem(parser, context, scope) {
- parser.leadingDecorators = parseDecorators(parser, context);
- let moduleItem;
- switch (parser.token) {
- case 20566:
- moduleItem = parseExportDeclaration(parser, context, scope);
- break;
- case 86108:
- moduleItem = parseImportDeclaration(parser, context, scope);
- break;
- default:
- moduleItem = parseStatementListItem(parser, context, scope, 4, {});
- }
- if (parser.leadingDecorators.length) {
- report(parser, 164);
- }
- return moduleItem;
- }
- function parseStatementListItem(parser, context, scope, origin, labels) {
- const start = parser.tokenPos;
- const line = parser.linePos;
- const column = parser.colPos;
- switch (parser.token) {
- case 86106:
- return parseFunctionDeclaration(parser, context, scope, origin, 1, 0, 0, start, line, column);
- case 133:
- case 86096:
- return parseClassDeclaration(parser, context, scope, 0, start, line, column);
- case 86092:
- return parseLexicalDeclaration(parser, context, scope, 16, 0, start, line, column);
- case 241739:
- return parseLetIdentOrVarDeclarationStatement(parser, context, scope, origin, start, line, column);
- case 20566:
- report(parser, 100, 'export');
- case 86108:
- nextToken(parser, context);
- switch (parser.token) {
- case 67174411:
- return parseImportCallDeclaration(parser, context, start, line, column);
- case 67108877:
- return parseImportMetaDeclaration(parser, context, start, line, column);
- default:
- report(parser, 100, 'import');
- }
- case 209007:
- return parseAsyncArrowOrAsyncFunctionDeclaration(parser, context, scope, origin, labels, 1, start, line, column);
- default:
- return parseStatement(parser, context, scope, origin, labels, 1, start, line, column);
- }
- }
- function parseStatement(parser, context, scope, origin, labels, allowFuncDecl, start, line, column) {
- switch (parser.token) {
- case 86090:
- return parseVariableStatement(parser, context, scope, 0, start, line, column);
- case 20574:
- return parseReturnStatement(parser, context, start, line, column);
- case 20571:
- return parseIfStatement(parser, context, scope, labels, start, line, column);
- case 20569:
- return parseForStatement(parser, context, scope, labels, start, line, column);
- case 20564:
- return parseDoWhileStatement(parser, context, scope, labels, start, line, column);
- case 20580:
- return parseWhileStatement(parser, context, scope, labels, start, line, column);
- case 86112:
- return parseSwitchStatement(parser, context, scope, labels, start, line, column);
- case 1074790417:
- return parseEmptyStatement(parser, context, start, line, column);
- case 2162700:
- return parseBlock(parser, context, scope ? addChildScope(scope, 2) : scope, labels, start, line, column);
- case 86114:
- return parseThrowStatement(parser, context, start, line, column);
- case 20557:
- return parseBreakStatement(parser, context, labels, start, line, column);
- case 20561:
- return parseContinueStatement(parser, context, labels, start, line, column);
- case 20579:
- return parseTryStatement(parser, context, scope, labels, start, line, column);
- case 20581:
- return parseWithStatement(parser, context, scope, labels, start, line, column);
- case 20562:
- return parseDebuggerStatement(parser, context, start, line, column);
- case 209007:
- return parseAsyncArrowOrAsyncFunctionDeclaration(parser, context, scope, origin, labels, 0, start, line, column);
- case 20559:
- report(parser, 156);
- case 20568:
- report(parser, 157);
- case 86106:
- report(parser, context & 1024
- ? 73
- : (context & 256) < 1
- ? 75
- : 74);
- case 86096:
- report(parser, 76);
- default:
- return parseExpressionOrLabelledStatement(parser, context, scope, origin, labels, allowFuncDecl, start, line, column);
- }
- }
- function parseExpressionOrLabelledStatement(parser, context, scope, origin, labels, allowFuncDecl, start, line, column) {
- const { tokenValue, token } = parser;
- let expr;
- switch (token) {
- case 241739:
- expr = parseIdentifier(parser, context, 0);
- if (context & 1024)
- report(parser, 82);
- if (parser.token === 69271571)
- report(parser, 81);
- break;
- default:
- expr = parsePrimaryExpression(parser, context, 2, 0, 1, 0, 0, 1, parser.tokenPos, parser.linePos, parser.colPos);
- }
- if (token & 143360 && parser.token === 21) {
- return parseLabelledStatement(parser, context, scope, origin, labels, tokenValue, expr, token, allowFuncDecl, start, line, column);
- }
- expr = parseMemberOrUpdateExpression(parser, context, expr, 0, 0, start, line, column);
- expr = parseAssignmentExpression(parser, context, 0, 0, start, line, column, expr);
- if (parser.token === 18) {
- expr = parseSequenceExpression(parser, context, 0, start, line, column, expr);
- }
- return parseExpressionStatement(parser, context, expr, start, line, column);
- }
- function parseBlock(parser, context, scope, labels, start, line, column) {
- const body = [];
- consume(parser, context | 32768, 2162700);
- while (parser.token !== 1074790415) {
- body.push(parseStatementListItem(parser, context, scope, 2, { $: labels }));
- }
- consume(parser, context | 32768, 1074790415);
- return finishNode(parser, context, start, line, column, {
- type: 'BlockStatement',
- body
- });
- }
- function parseReturnStatement(parser, context, start, line, column) {
- if ((context & 32) < 1 && context & 8192)
- report(parser, 89);
- nextToken(parser, context | 32768);
- const argument = parser.flags & 1 || parser.token & 1048576
- ? null
- : parseExpressions(parser, context, 0, 1, parser.tokenPos, parser.line, parser.column);
- matchOrInsertSemicolon(parser, context | 32768);
- return finishNode(parser, context, start, line, column, {
- type: 'ReturnStatement',
- argument
- });
- }
- function parseExpressionStatement(parser, context, expression, start, line, column) {
- matchOrInsertSemicolon(parser, context | 32768);
- return finishNode(parser, context, start, line, column, {
- type: 'ExpressionStatement',
- expression
- });
- }
- function parseLabelledStatement(parser, context, scope, origin, labels, value, expr, token, allowFuncDecl, start, line, column) {
- validateBindingIdentifier(parser, context, 0, token, 1);
- validateAndDeclareLabel(parser, labels, value);
- nextToken(parser, context | 32768);
- const body = allowFuncDecl &&
- (context & 1024) < 1 &&
- context & 256 &&
- parser.token === 86106
- ? parseFunctionDeclaration(parser, context, addChildScope(scope, 2), origin, 0, 0, 0, parser.tokenPos, parser.linePos, parser.colPos)
- : parseStatement(parser, context, scope, origin, labels, allowFuncDecl, parser.tokenPos, parser.linePos, parser.colPos);
- return finishNode(parser, context, start, line, column, {
- type: 'LabeledStatement',
- label: expr,
- body
- });
- }
- function parseAsyncArrowOrAsyncFunctionDeclaration(parser, context, scope, origin, labels, allowFuncDecl, start, line, column) {
- const { token, tokenValue } = parser;
- let expr = parseIdentifier(parser, context, 0);
- if (parser.token === 21) {
- return parseLabelledStatement(parser, context, scope, origin, labels, tokenValue, expr, token, 1, start, line, column);
- }
- const asyncNewLine = parser.flags & 1;
- if (!asyncNewLine) {
- if (parser.token === 86106) {
- if (!allowFuncDecl)
- report(parser, 119);
- return parseFunctionDeclaration(parser, context, scope, origin, 1, 0, 1, start, line, column);
- }
- if ((parser.token & 143360) === 143360) {
- expr = parseAsyncArrowAfterIdent(parser, context, 1, start, line, column);
- if (parser.token === 18)
- expr = parseSequenceExpression(parser, context, 0, start, line, column, expr);
- return parseExpressionStatement(parser, context, expr, start, line, column);
- }
- }
- if (parser.token === 67174411) {
- expr = parseAsyncArrowOrCallExpression(parser, context, expr, 1, 1, 0, asyncNewLine, start, line, column);
- }
- else {
- if (parser.token === 10) {
- classifyIdentifier(parser, context, token, 1);
- expr = parseArrowFromIdentifier(parser, context, parser.tokenValue, expr, 0, 1, 0, start, line, column);
- }
- parser.assignable = 1;
- }
- expr = parseMemberOrUpdateExpression(parser, context, expr, 0, 0, start, line, column);
- if (parser.token === 18)
- expr = parseSequenceExpression(parser, context, 0, start, line, column, expr);
- expr = parseAssignmentExpression(parser, context, 0, 0, start, line, column, expr);
- parser.assignable = 1;
- return parseExpressionStatement(parser, context, expr, start, line, column);
- }
- function parseDirective(parser, context, expression, token, start, line, column) {
- if (token !== 1074790417) {
- parser.assignable = 2;
- expression = parseMemberOrUpdateExpression(parser, context, expression, 0, 0, start, line, column);
- if (parser.token !== 1074790417) {
- expression = parseAssignmentExpression(parser, context, 0, 0, start, line, column, expression);
- if (parser.token === 18) {
- expression = parseSequenceExpression(parser, context, 0, start, line, column, expression);
- }
- }
- matchOrInsertSemicolon(parser, context | 32768);
- }
- return context & 8 && expression.type === 'Literal' && typeof expression.value === 'string'
- ? finishNode(parser, context, start, line, column, {
- type: 'ExpressionStatement',
- expression,
- directive: expression.raw.slice(1, -1)
- })
- : finishNode(parser, context, start, line, column, {
- type: 'ExpressionStatement',
- expression
- });
- }
- function parseEmptyStatement(parser, context, start, line, column) {
- nextToken(parser, context | 32768);
- return finishNode(parser, context, start, line, column, {
- type: 'EmptyStatement'
- });
- }
- function parseThrowStatement(parser, context, start, line, column) {
- nextToken(parser, context | 32768);
- if (parser.flags & 1)
- report(parser, 87);
- const argument = parseExpressions(parser, context, 0, 1, parser.tokenPos, parser.linePos, parser.colPos);
- matchOrInsertSemicolon(parser, context | 32768);
- return finishNode(parser, context, start, line, column, {
- type: 'ThrowStatement',
- argument
- });
- }
- function parseIfStatement(parser, context, scope, labels, start, line, column) {
- nextToken(parser, context);
- consume(parser, context | 32768, 67174411);
- parser.assignable = 1;
- const test = parseExpressions(parser, context, 0, 1, parser.tokenPos, parser.line, parser.colPos);
- consume(parser, context | 32768, 16);
- const consequent = parseConsequentOrAlternative(parser, context, scope, labels, parser.tokenPos, parser.linePos, parser.colPos);
- let alternate = null;
- if (parser.token === 20565) {
- nextToken(parser, context | 32768);
- alternate = parseConsequentOrAlternative(parser, context, scope, labels, parser.tokenPos, parser.linePos, parser.colPos);
- }
- return finishNode(parser, context, start, line, column, {
- type: 'IfStatement',
- test,
- consequent,
- alternate
- });
- }
- function parseConsequentOrAlternative(parser, context, scope, labels, start, line, column) {
- return context & 1024 ||
- (context & 256) < 1 ||
- parser.token !== 86106
- ? parseStatement(parser, context, scope, 0, { $: labels }, 0, parser.tokenPos, parser.linePos, parser.colPos)
- : parseFunctionDeclaration(parser, context, addChildScope(scope, 2), 0, 0, 0, 0, start, line, column);
- }
- function parseSwitchStatement(parser, context, scope, labels, start, line, column) {
- nextToken(parser, context);
- consume(parser, context | 32768, 67174411);
- const discriminant = parseExpressions(parser, context, 0, 1, parser.tokenPos, parser.linePos, parser.colPos);
- consume(parser, context, 16);
- consume(parser, context, 2162700);
- const cases = [];
- let seenDefault = 0;
- if (scope)
- scope = addChildScope(scope, 8);
- while (parser.token !== 1074790415) {
- const { tokenPos, linePos, colPos } = parser;
- let test = null;
- const consequent = [];
- if (consumeOpt(parser, context | 32768, 20558)) {
- test = parseExpressions(parser, context, 0, 1, parser.tokenPos, parser.linePos, parser.colPos);
- }
- else {
- consume(parser, context | 32768, 20563);
- if (seenDefault)
- report(parser, 86);
- seenDefault = 1;
- }
- consume(parser, context | 32768, 21);
- while (parser.token !== 20558 &&
- parser.token !== 1074790415 &&
- parser.token !== 20563) {
- consequent.push(parseStatementListItem(parser, context | 4096, scope, 2, {
- $: labels
- }));
- }
- cases.push(finishNode(parser, context, tokenPos, linePos, colPos, {
- type: 'SwitchCase',
- test,
- consequent
- }));
- }
- consume(parser, context | 32768, 1074790415);
- return finishNode(parser, context, start, line, column, {
- type: 'SwitchStatement',
- discriminant,
- cases
- });
- }
- function parseWhileStatement(parser, context, scope, labels, start, line, column) {
- nextToken(parser, context);
- consume(parser, context | 32768, 67174411);
- const test = parseExpressions(parser, context, 0, 1, parser.tokenPos, parser.linePos, parser.colPos);
- consume(parser, context | 32768, 16);
- const body = parseIterationStatementBody(parser, context, scope, labels);
- return finishNode(parser, context, start, line, column, {
- type: 'WhileStatement',
- test,
- body
- });
- }
- function parseIterationStatementBody(parser, context, scope, labels) {
- return parseStatement(parser, ((context | 134217728) ^ 134217728) | 131072, scope, 0, { loop: 1, $: labels }, 0, parser.tokenPos, parser.linePos, parser.colPos);
- }
- function parseContinueStatement(parser, context, labels, start, line, column) {
- if ((context & 131072) < 1)
- report(parser, 65);
- nextToken(parser, context);
- let label = null;
- if ((parser.flags & 1) < 1 && parser.token & 143360) {
- const { tokenValue } = parser;
- label = parseIdentifier(parser, context | 32768, 0);
- if (!isValidLabel(parser, labels, tokenValue, 1))
- report(parser, 134, tokenValue);
- }
- matchOrInsertSemicolon(parser, context | 32768);
- return finishNode(parser, context, start, line, column, {
- type: 'ContinueStatement',
- label
- });
- }
- function parseBreakStatement(parser, context, labels, start, line, column) {
- nextToken(parser, context | 32768);
- let label = null;
- if ((parser.flags & 1) < 1 && parser.token & 143360) {
- const { tokenValue } = parser;
- label = parseIdentifier(parser, context | 32768, 0);
- if (!isValidLabel(parser, labels, tokenValue, 0))
- report(parser, 134, tokenValue);
- }
- else if ((context & (4096 | 131072)) < 1) {
- report(parser, 66);
- }
- matchOrInsertSemicolon(parser, context | 32768);
- return finishNode(parser, context, start, line, column, {
- type: 'BreakStatement',
- label
- });
- }
- function parseWithStatement(parser, context, scope, labels, start, line, column) {
- nextToken(parser, context);
- if (context & 1024)
- report(parser, 88);
- consume(parser, context | 32768, 67174411);
- const object = parseExpressions(parser, context, 0, 1, parser.tokenPos, parser.linePos, parser.colPos);
- consume(parser, context | 32768, 16);
- const body = parseStatement(parser, context, scope, 2, labels, 0, parser.tokenPos, parser.linePos, parser.colPos);
- return finishNode(parser, context, start, line, column, {
- type: 'WithStatement',
- object,
- body
- });
- }
- function parseDebuggerStatement(parser, context, start, line, column) {
- nextToken(parser, context | 32768);
- matchOrInsertSemicolon(parser, context | 32768);
- return finishNode(parser, context, start, line, column, {
- type: 'DebuggerStatement'
- });
- }
- function parseTryStatement(parser, context, scope, labels, start, line, column) {
- nextToken(parser, context | 32768);
- const firstScope = scope ? addChildScope(scope, 32) : void 0;
- const block = parseBlock(parser, context, firstScope, { $: labels }, parser.tokenPos, parser.linePos, parser.colPos);
- const { tokenPos, linePos, colPos } = parser;
- const handler = consumeOpt(parser, context | 32768, 20559)
- ? parseCatchBlock(parser, context, scope, labels, tokenPos, linePos, colPos)
- : null;
- let finalizer = null;
- if (parser.token === 20568) {
- nextToken(parser, context | 32768);
- const finalizerScope = firstScope ? addChildScope(scope, 4) : void 0;
- finalizer = parseBlock(parser, context, finalizerScope, { $: labels }, parser.tokenPos, parser.linePos, parser.colPos);
- }
- if (!handler && !finalizer) {
- report(parser, 85);
- }
- return finishNode(parser, context, start, line, column, {
- type: 'TryStatement',
- block,
- handler,
- finalizer
- });
- }
- function parseCatchBlock(parser, context, scope, labels, start, line, column) {
- let param = null;
- let additionalScope = scope;
- if (consumeOpt(parser, context, 67174411)) {
- if (scope)
- scope = addChildScope(scope, 4);
- param = parseBindingPattern(parser, context, scope, (parser.token & 2097152) === 2097152
- ? 256
- : 512, 0, parser.tokenPos, parser.linePos, parser.colPos);
- if (parser.token === 18) {
- report(parser, 83);
- }
- else if (parser.token === 1077936157) {
- report(parser, 84);
- }
- consume(parser, context | 32768, 16);
- if (scope)
- additionalScope = addChildScope(scope, 64);
- }
- const body = parseBlock(parser, context, additionalScope, { $: labels }, parser.tokenPos, parser.linePos, parser.colPos);
- return finishNode(parser, context, start, line, column, {
- type: 'CatchClause',
- param,
- body
- });
- }
- function parseDoWhileStatement(parser, context, scope, labels, start, line, column) {
- nextToken(parser, context | 32768);
- const body = parseIterationStatementBody(parser, context, scope, labels);
- consume(parser, context, 20580);
- consume(parser, context | 32768, 67174411);
- const test = parseExpressions(parser, context, 0, 1, parser.tokenPos, parser.linePos, parser.colPos);
- consume(parser, context | 32768, 16);
- consumeOpt(parser, context, 1074790417);
- return finishNode(parser, context, start, line, column, {
- type: 'DoWhileStatement',
- body,
- test
- });
- }
- function parseLetIdentOrVarDeclarationStatement(parser, context, scope, origin, start, line, column) {
- const { token, tokenValue } = parser;
- let expr = parseIdentifier(parser, context, 0);
- if (parser.token & (143360 | 2097152)) {
- const declarations = parseVariableDeclarationList(parser, context, scope, 8, 0);
- matchOrInsertSemicolon(parser, context | 32768);
- return finishNode(parser, context, start, line, column, {
- type: 'VariableDeclaration',
- kind: 'let',
- declarations
- });
- }
- parser.assignable = 1;
- if (context & 1024)
- report(parser, 82);
- if (parser.token === 21) {
- return parseLabelledStatement(parser, context, scope, origin, {}, tokenValue, expr, token, 0, start, line, column);
- }
- if (parser.token === 10) {
- let scope = void 0;
- if (context & 64)
- scope = createArrowHeadParsingScope(parser, context, tokenValue);
- parser.flags = (parser.flags | 128) ^ 128;
- expr = parseArrowFunctionExpression(parser, context, scope, [expr], 0, start, line, column);
- }
- else {
- expr = parseMemberOrUpdateExpression(parser, context, expr, 0, 0, start, line, column);
- expr = parseAssignmentExpression(parser, context, 0, 0, start, line, column, expr);
- }
- if (parser.token === 18) {
- expr = parseSequenceExpression(parser, context, 0, start, line, column, expr);
- }
- return parseExpressionStatement(parser, context, expr, start, line, column);
- }
- function parseLexicalDeclaration(parser, context, scope, kind, origin, start, line, column) {
- nextToken(parser, context);
- const declarations = parseVariableDeclarationList(parser, context, scope, kind, origin);
- matchOrInsertSemicolon(parser, context | 32768);
- return finishNode(parser, context, start, line, column, {
- type: 'VariableDeclaration',
- kind: kind & 8 ? 'let' : 'const',
- declarations
- });
- }
- function parseVariableStatement(parser, context, scope, origin, start, line, column) {
- nextToken(parser, context);
- const declarations = parseVariableDeclarationList(parser, context, scope, 4, origin);
- matchOrInsertSemicolon(parser, context | 32768);
- return finishNode(parser, context, start, line, column, {
- type: 'VariableDeclaration',
- kind: 'var',
- declarations
- });
- }
- function parseVariableDeclarationList(parser, context, scope, kind, origin) {
- let bindingCount = 1;
- const list = [parseVariableDeclaration(parser, context, scope, kind, origin)];
- while (consumeOpt(parser, context, 18)) {
- bindingCount++;
- list.push(parseVariableDeclaration(parser, context, scope, kind, origin));
- }
- if (bindingCount > 1 && origin & 32 && parser.token & 262144) {
- report(parser, 58, KeywordDescTable[parser.token & 255]);
- }
- return list;
- }
- function parseVariableDeclaration(parser, context, scope, kind, origin) {
- const { token, tokenPos, linePos, colPos } = parser;
- let init = null;
- const id = parseBindingPattern(parser, context, scope, kind, origin, tokenPos, linePos, colPos);
- if (parser.token === 1077936157) {
- nextToken(parser, context | 32768);
- init = parseExpression(parser, context, 1, 0, 0, parser.tokenPos, parser.linePos, parser.colPos);
- if (origin & 32 || (token & 2097152) < 1) {
- if (parser.token === 274549 ||
- (parser.token === 8738868 &&
- (token & 2097152 || (kind & 4) < 1 || context & 1024))) {
- reportMessageAt(tokenPos, parser.line, parser.index - 3, 57, parser.token === 274549 ? 'of' : 'in');
- }
- }
- }
- else if ((kind & 16 || (token & 2097152) > 0) &&
- (parser.token & 262144) !== 262144) {
- report(parser, 56, kind & 16 ? 'const' : 'destructuring');
- }
- return finishNode(parser, context, tokenPos, linePos, colPos, {
- type: 'VariableDeclarator',
- id,
- init
- });
- }
- function parseForStatement(parser, context, scope, labels, start, line, column) {
- nextToken(parser, context);
- const forAwait = (context & 4194304) > 0 && consumeOpt(parser, context, 209008);
- consume(parser, context | 32768, 67174411);
- if (scope)
- scope = addChildScope(scope, 1);
- let test = null;
- let update = null;
- let destructible = 0;
- let init = null;
- let isVarDecl = parser.token === 86090 || parser.token === 241739 || parser.token === 86092;
- let right;
- const { token, tokenPos, linePos, colPos } = parser;
- if (isVarDecl) {
- if (token === 241739) {
- init = parseIdentifier(parser, context, 0);
- if (parser.token & (143360 | 2097152)) {
- if (parser.token === 8738868) {
- if (context & 1024)
- report(parser, 64);
- }
- else {
- init = finishNode(parser, context, tokenPos, linePos, colPos, {
- type: 'VariableDeclaration',
- kind: 'let',
- declarations: parseVariableDeclarationList(parser, context | 134217728, scope, 8, 32)
- });
- }
- parser.assignable = 1;
- }
- else if (context & 1024) {
- report(parser, 64);
- }
- else {
- isVarDecl = false;
- parser.assignable = 1;
- init = parseMemberOrUpdateExpression(parser, context, init, 0, 0, tokenPos, linePos, colPos);
- if (parser.token === 274549)
- report(parser, 111);
- }
- }
- else {
- nextToken(parser, context);
- init = finishNode(parser, context, tokenPos, linePos, colPos, token === 86090
- ? {
- type: 'VariableDeclaration',
- kind: 'var',
- declarations: parseVariableDeclarationList(parser, context | 134217728, scope, 4, 32)
- }
- : {
- type: 'VariableDeclaration',
- kind: 'const',
- declarations: parseVariableDeclarationList(parser, context | 134217728, scope, 16, 32)
- });
- parser.assignable = 1;
- }
- }
- else if (token === 1074790417) {
- if (forAwait)
- report(parser, 79);
- }
- else if ((token & 2097152) === 2097152) {
- init =
- token === 2162700
- ? parseObjectLiteralOrPattern(parser, context, void 0, 1, 0, 0, 2, 32, tokenPos, linePos, colPos)
- : parseArrayExpressionOrPattern(parser, context, void 0, 1, 0, 0, 2, 32, tokenPos, linePos, colPos);
- destructible = parser.destructible;
- if (context & 256 && destructible & 64) {
- report(parser, 60);
- }
- parser.assignable =
- destructible & 16 ? 2 : 1;
- init = parseMemberOrUpdateExpression(parser, context | 134217728, init, 0, 0, parser.tokenPos, parser.linePos, parser.colPos);
- }
- else {
- init = parseLeftHandSideExpression(parser, context | 134217728, 1, 0, 1, tokenPos, linePos, colPos);
- }
- if ((parser.token & 262144) === 262144) {
- if (parser.token === 274549) {
- if (parser.assignable & 2)
- report(parser, 77, forAwait ? 'await' : 'of');
- reinterpretToPattern(parser, init);
- nextToken(parser, context | 32768);
- right = parseExpression(parser, context, 1, 0, 0, parser.tokenPos, parser.linePos, parser.colPos);
- consume(parser, context | 32768, 16);
- const body = parseIterationStatementBody(parser, context, scope, labels);
- return finishNode(parser, context, start, line, column, {
- type: 'ForOfStatement',
- left: init,
- right,
- body,
- await: forAwait
- });
- }
- if (parser.assignable & 2)
- report(parser, 77, 'in');
- reinterpretToPattern(parser, init);
- nextToken(parser, context | 32768);
- if (forAwait)
- report(parser, 79);
- right = parseExpressions(parser, context, 0, 1, parser.tokenPos, parser.linePos, parser.colPos);
- consume(parser, context | 32768, 16);
- const body = parseIterationStatementBody(parser, context, scope, labels);
- return finishNode(parser, context, start, line, column, {
- type: 'ForInStatement',
- body,
- left: init,
- right
- });
- }
- if (forAwait)
- report(parser, 79);
- if (!isVarDecl) {
- if (destructible & 8 && parser.token !== 1077936157) {
- report(parser, 77, 'loop');
- }
- init = parseAssignmentExpression(parser, context | 134217728, 0, 0, tokenPos, linePos, colPos, init);
- }
- if (parser.token === 18)
- init = parseSequenceExpression(parser, context, 0, parser.tokenPos, parser.linePos, parser.colPos, init);
- consume(parser, context | 32768, 1074790417);
- if (parser.token !== 1074790417)
- test = parseExpressions(parser, context, 0, 1, parser.tokenPos, parser.linePos, parser.colPos);
- consume(parser, context | 32768, 1074790417);
- if (parser.token !== 16)
- update = parseExpressions(parser, context, 0, 1, parser.tokenPos, parser.linePos, parser.colPos);
- consume(parser, context | 32768, 16);
- const body = parseIterationStatementBody(parser, context, scope, labels);
- return finishNode(parser, context, start, line, column, {
- type: 'ForStatement',
- init,
- test,
- update,
- body
- });
- }
- function parseRestrictedIdentifier(parser, context, scope) {
- if (!isValidIdentifier(context, parser.token))
- report(parser, 114);
- if ((parser.token & 537079808) === 537079808)
- report(parser, 115);
- if (scope)
- addBlockName(parser, context, scope, parser.tokenValue, 8, 0);
- return parseIdentifier(parser, context, 0);
- }
- function parseImportDeclaration(parser, context, scope) {
- const start = parser.tokenPos;
- const line = parser.linePos;
- const column = parser.colPos;
- nextToken(parser, context);
- let source = null;
- const { tokenPos, linePos, colPos } = parser;
- let specifiers = [];
- if (parser.token === 134283267) {
- source = parseLiteral(parser, context);
- }
- else {
- if (parser.token & 143360) {
- const local = parseRestrictedIdentifier(parser, context, scope);
- specifiers = [
- finishNode(parser, context, tokenPos, linePos, colPos, {
- type: 'ImportDefaultSpecifier',
- local
- })
- ];
- if (consumeOpt(parser, context, 18)) {
- switch (parser.token) {
- case 8457014:
- specifiers.push(parseImportNamespaceSpecifier(parser, context, scope));
- break;
- case 2162700:
- parseImportSpecifierOrNamedImports(parser, context, scope, specifiers);
- break;
- default:
- report(parser, 104);
- }
- }
- }
- else {
- switch (parser.token) {
- case 8457014:
- specifiers = [parseImportNamespaceSpecifier(parser, context, scope)];
- break;
- case 2162700:
- parseImportSpecifierOrNamedImports(parser, context, scope, specifiers);
- break;
- case 67174411:
- return parseImportCallDeclaration(parser, context, start, line, column);
- case 67108877:
- return parseImportMetaDeclaration(parser, context, start, line, column);
- default:
- report(parser, 28, KeywordDescTable[parser.token & 255]);
- }
- }
- source = parseModuleSpecifier(parser, context);
- }
- matchOrInsertSemicolon(parser, context | 32768);
- return finishNode(parser, context, start, line, column, {
- type: 'ImportDeclaration',
- specifiers,
- source
- });
- }
- function parseImportNamespaceSpecifier(parser, context, scope) {
- const { tokenPos, linePos, colPos } = parser;
- nextToken(parser, context);
- consume(parser, context, 77934);
- if ((parser.token & 134217728) === 134217728) {
- reportMessageAt(tokenPos, parser.line, parser.index, 28, KeywordDescTable[parser.token & 255]);
- }
- return finishNode(parser, context, tokenPos, linePos, colPos, {
- type: 'ImportNamespaceSpecifier',
- local: parseRestrictedIdentifier(parser, context, scope)
- });
- }
- function parseModuleSpecifier(parser, context) {
- consumeOpt(parser, context, 12404);
- if (parser.token !== 134283267)
- report(parser, 102, 'Import');
- return parseLiteral(parser, context);
- }
- function parseImportSpecifierOrNamedImports(parser, context, scope, specifiers) {
- nextToken(parser, context);
- while (parser.token & 143360) {
- let { token, tokenValue, tokenPos, linePos, colPos } = parser;
- const imported = parseIdentifier(parser, context, 0);
- let local;
- if (consumeOpt(parser, context, 77934)) {
- if ((parser.token & 134217728) === 134217728 || parser.token === 18) {
- report(parser, 103);
- }
- else {
- validateBindingIdentifier(parser, context, 16, parser.token, 0);
- }
- tokenValue = parser.tokenValue;
- local = parseIdentifier(parser, context, 0);
- }
- else {
- validateBindingIdentifier(parser, context, 16, token, 0);
- local = imported;
- }
- if (scope)
- addBlockName(parser, context, scope, tokenValue, 8, 0);
- specifiers.push(finishNode(parser, context, tokenPos, linePos, colPos, {
- type: 'ImportSpecifier',
- local,
- imported
- }));
- if (parser.token !== 1074790415)
- consume(parser, context, 18);
- }
- consume(parser, context, 1074790415);
- return specifiers;
- }
- function parseImportMetaDeclaration(parser, context, start, line, column) {
- let expr = parseImportMetaExpression(parser, context, finishNode(parser, context, start, line, column, {
- type: 'Identifier',
- name: 'import'
- }), start, line, column);
- expr = parseMemberOrUpdateExpression(parser, context, expr, 0, 0, start, line, column);
- expr = parseAssignmentExpression(parser, context, 0, 0, start, line, column, expr);
- return parseExpressionStatement(parser, context, expr, start, line, column);
- }
- function parseImportCallDeclaration(parser, context, start, line, column) {
- let expr = parseImportExpression(parser, context, 0, start, line, column);
- expr = parseMemberOrUpdateExpression(parser, context, expr, 0, 0, start, line, column);
- return parseExpressionStatement(parser, context, expr, start, line, column);
- }
- function parseExportDeclaration(parser, context, scope) {
- const start = parser.tokenPos;
- const line = parser.linePos;
- const column = parser.colPos;
- nextToken(parser, context | 32768);
- const specifiers = [];
- let declaration = null;
- let source = null;
- let key;
- if (consumeOpt(parser, context | 32768, 20563)) {
- switch (parser.token) {
- case 86106: {
- declaration = parseFunctionDeclaration(parser, context, scope, 4, 1, 1, 0, parser.tokenPos, parser.linePos, parser.colPos);
- break;
- }
- case 133:
- case 86096:
- declaration = parseClassDeclaration(parser, context, scope, 1, parser.tokenPos, parser.linePos, parser.colPos);
- break;
- case 209007:
- const { tokenPos, linePos, colPos } = parser;
- declaration = parseIdentifier(parser, context, 0);
- const { flags } = parser;
- if ((flags & 1) < 1) {
- if (parser.token === 86106) {
- declaration = parseFunctionDeclaration(parser, context, scope, 4, 1, 1, 1, tokenPos, linePos, colPos);
- }
- else {
- if (parser.token === 67174411) {
- declaration = parseAsyncArrowOrCallExpression(parser, context, declaration, 1, 1, 0, flags, tokenPos, linePos, colPos);
- declaration = parseMemberOrUpdateExpression(parser, context, declaration, 0, 0, tokenPos, linePos, colPos);
- declaration = parseAssignmentExpression(parser, context, 0, 0, tokenPos, linePos, colPos, declaration);
- }
- else if (parser.token & 143360) {
- if (scope)
- scope = createArrowHeadParsingScope(parser, context, parser.tokenValue);
- declaration = parseIdentifier(parser, context, 0);
- declaration = parseArrowFunctionExpression(parser, context, scope, [declaration], 1, tokenPos, linePos, colPos);
- }
- }
- }
- break;
- default:
- declaration = parseExpression(parser, context, 1, 0, 0, parser.tokenPos, parser.linePos, parser.colPos);
- matchOrInsertSemicolon(parser, context | 32768);
- }
- if (scope)
- declareUnboundVariable(parser, 'default');
- return finishNode(parser, context, start, line, column, {
- type: 'ExportDefaultDeclaration',
- declaration
- });
- }
- switch (parser.token) {
- case 8457014: {
- nextToken(parser, context);
- let exported = null;
- const isNamedDeclaration = consumeOpt(parser, context, 77934);
- if (isNamedDeclaration) {
- if (scope)
- declareUnboundVariable(parser, parser.tokenValue);
- exported = parseIdentifier(parser, context, 0);
- }
- consume(parser, context, 12404);
- if (parser.token !== 134283267)
- report(parser, 102, 'Export');
- source = parseLiteral(parser, context);
- matchOrInsertSemicolon(parser, context | 32768);
- return finishNode(parser, context, start, line, column, {
- type: 'ExportAllDeclaration',
- source,
- exported
- });
- }
- case 2162700: {
- nextToken(parser, context);
- const tmpExportedNames = [];
- const tmpExportedBindings = [];
- while (parser.token & 143360) {
- const { tokenPos, tokenValue, linePos, colPos } = parser;
- const local = parseIdentifier(parser, context, 0);
- let exported;
- if (parser.token === 77934) {
- nextToken(parser, context);
- if ((parser.token & 134217728) === 134217728) {
- report(parser, 103);
- }
- if (scope) {
- tmpExportedNames.push(parser.tokenValue);
- tmpExportedBindings.push(tokenValue);
- }
- exported = parseIdentifier(parser, context, 0);
- }
- else {
- if (scope) {
- tmpExportedNames.push(parser.tokenValue);
- tmpExportedBindings.push(parser.tokenValue);
- }
- exported = local;
- }
- specifiers.push(finishNode(parser, context, tokenPos, linePos, colPos, {
- type: 'ExportSpecifier',
- local,
- exported
- }));
- if (parser.token !== 1074790415)
- consume(parser, context, 18);
- }
- consume(parser, context, 1074790415);
- if (consumeOpt(parser, context, 12404)) {
- if (parser.token !== 134283267)
- report(parser, 102, 'Export');
- source = parseLiteral(parser, context);
- }
- else if (scope) {
- let i = 0;
- let iMax = tmpExportedNames.length;
- for (; i < iMax; i++) {
- declareUnboundVariable(parser, tmpExportedNames[i]);
- }
- i = 0;
- iMax = tmpExportedBindings.length;
- for (; i < iMax; i++) {
- addBindingToExports(parser, tmpExportedBindings[i]);
- }
- }
- matchOrInsertSemicolon(parser, context | 32768);
- break;
- }
- case 86096:
- declaration = parseClassDeclaration(parser, context, scope, 2, parser.tokenPos, parser.linePos, parser.colPos);
- break;
- case 86106:
- declaration = parseFunctionDeclaration(parser, context, scope, 4, 1, 2, 0, parser.tokenPos, parser.linePos, parser.colPos);
- break;
- case 241739:
- declaration = parseLexicalDeclaration(parser, context, scope, 8, 64, parser.tokenPos, parser.linePos, parser.colPos);
- break;
- case 86092:
- declaration = parseLexicalDeclaration(parser, context, scope, 16, 64, parser.tokenPos, parser.linePos, parser.colPos);
- break;
- case 86090:
- declaration = parseVariableStatement(parser, context, scope, 64, parser.tokenPos, parser.linePos, parser.colPos);
- break;
- case 209007:
- const { tokenPos, linePos, colPos } = parser;
- nextToken(parser, context);
- if ((parser.flags & 1) < 1 && parser.token === 86106) {
- declaration = parseFunctionDeclaration(parser, context, scope, 4, 1, 2, 1, tokenPos, linePos, colPos);
- if (scope) {
- key = declaration.id ? declaration.id.name : '';
- declareUnboundVariable(parser, key);
- }
- break;
- }
- default:
- report(parser, 28, KeywordDescTable[parser.token & 255]);
- }
- return finishNode(parser, context, start, line, column, {
- type: 'ExportNamedDeclaration',
- declaration,
- specifiers,
- source
- });
- }
- function parseExpression(parser, context, canAssign, isPattern, inGroup, start, line, column) {
- let expr = parsePrimaryExpression(parser, context, 2, 0, canAssign, isPattern, inGroup, 1, start, line, column);
- expr = parseMemberOrUpdateExpression(parser, context, expr, inGroup, 0, start, line, column);
- return parseAssignmentExpression(parser, context, inGroup, 0, start, line, column, expr);
- }
- function parseSequenceExpression(parser, context, inGroup, start, line, column, expr) {
- const expressions = [expr];
- while (consumeOpt(parser, context | 32768, 18)) {
- expressions.push(parseExpression(parser, context, 1, 0, inGroup, parser.tokenPos, parser.linePos, parser.colPos));
- }
- return finishNode(parser, context, start, line, column, {
- type: 'SequenceExpression',
- expressions
- });
- }
- function parseExpressions(parser, context, inGroup, canAssign, start, line, column) {
- const expr = parseExpression(parser, context, canAssign, 0, inGroup, start, line, column);
- return parser.token === 18
- ? parseSequenceExpression(parser, context, inGroup, start, line, column, expr)
- : expr;
- }
- function parseAssignmentExpression(parser, context, inGroup, isPattern, start, line, column, left) {
- const { token } = parser;
- if ((token & 4194304) === 4194304) {
- if (parser.assignable & 2)
- report(parser, 24);
- if ((!isPattern && token === 1077936157 && left.type === 'ArrayExpression') ||
- left.type === 'ObjectExpression') {
- reinterpretToPattern(parser, left);
- }
- nextToken(parser, context | 32768);
- const right = parseExpression(parser, context, 1, 1, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, isPattern
- ? {
- type: 'AssignmentPattern',
- left,
- right
- }
- : {
- type: 'AssignmentExpression',
- left,
- operator: KeywordDescTable[token & 255],
- right
- });
- }
- if ((token & 8454144) === 8454144) {
- left = parseBinaryExpression(parser, context, inGroup, start, line, column, 4, token, left);
- }
- if (consumeOpt(parser, context | 32768, 22)) {
- left = parseConditionalExpression(parser, context, left, start, line, column);
- }
- return left;
- }
- function parseAssignmentExpressionOrPattern(parser, context, inGroup, isPattern, start, line, column, left) {
- const { token } = parser;
- nextToken(parser, context | 32768);
- const right = parseExpression(parser, context, 1, 1, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- left = finishNode(parser, context, start, line, column, isPattern
- ? {
- type: 'AssignmentPattern',
- left,
- right
- }
- : {
- type: 'AssignmentExpression',
- left,
- operator: KeywordDescTable[token & 255],
- right
- });
- parser.assignable = 2;
- return left;
- }
- function parseConditionalExpression(parser, context, test, start, line, column) {
- const consequent = parseExpression(parser, (context | 134217728) ^ 134217728, 1, 0, 0, parser.tokenPos, parser.linePos, parser.colPos);
- consume(parser, context | 32768, 21);
- parser.assignable = 1;
- const alternate = parseExpression(parser, context, 1, 0, 0, parser.tokenPos, parser.linePos, parser.colPos);
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, {
- type: 'ConditionalExpression',
- test,
- consequent,
- alternate
- });
- }
- function parseBinaryExpression(parser, context, inGroup, start, line, column, minPrec, operator, left) {
- const bit = -((context & 134217728) > 0) & 8738868;
- let t;
- let prec;
- parser.assignable = 2;
- while (parser.token & 8454144) {
- t = parser.token;
- prec = t & 3840;
- if ((t & 524288 && operator & 268435456) || (operator & 524288 && t & 268435456)) {
- report(parser, 159);
- }
- if (prec + ((t === 8457273) << 8) - ((bit === t) << 12) <= minPrec)
- break;
- nextToken(parser, context | 32768);
- left = finishNode(parser, context, start, line, column, {
- type: t & 524288 || t & 268435456 ? 'LogicalExpression' : 'BinaryExpression',
- left,
- right: parseBinaryExpression(parser, context, inGroup, parser.tokenPos, parser.linePos, parser.colPos, prec, t, parseLeftHandSideExpression(parser, context, 0, inGroup, 1, parser.tokenPos, parser.linePos, parser.colPos)),
- operator: KeywordDescTable[t & 255]
- });
- }
- if (parser.token === 1077936157)
- report(parser, 24);
- return left;
- }
- function parseUnaryExpression(parser, context, isLHS, start, line, column, inGroup) {
- if (!isLHS)
- report(parser, 0);
- const unaryOperator = parser.token;
- nextToken(parser, context | 32768);
- const arg = parseLeftHandSideExpression(parser, context, 0, inGroup, 1, parser.tokenPos, parser.linePos, parser.colPos);
- if (parser.token === 8457273)
- report(parser, 31);
- if (context & 1024 && unaryOperator === 16863278) {
- if (arg.type === 'Identifier') {
- report(parser, 117);
- }
- else if (isPropertyWithPrivateFieldKey(arg)) {
- report(parser, 123);
- }
- }
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, {
- type: 'UnaryExpression',
- operator: KeywordDescTable[unaryOperator & 255],
- argument: arg,
- prefix: true
- });
- }
- function parseAsyncExpression(parser, context, inGroup, isLHS, canAssign, isPattern, inNew, start, line, column) {
- const { token } = parser;
- const expr = parseIdentifier(parser, context, isPattern);
- const { flags } = parser;
- if ((flags & 1) < 1) {
- if (parser.token === 86106) {
- return parseFunctionExpression(parser, context, 1, inGroup, start, line, column);
- }
- if ((parser.token & 143360) === 143360) {
- if (!isLHS)
- report(parser, 0);
- return parseAsyncArrowAfterIdent(parser, context, canAssign, start, line, column);
- }
- }
- if (!inNew && parser.token === 67174411) {
- return parseAsyncArrowOrCallExpression(parser, context, expr, canAssign, 1, 0, flags, start, line, column);
- }
- if (parser.token === 10) {
- classifyIdentifier(parser, context, token, 1);
- if (inNew)
- report(parser, 48);
- return parseArrowFromIdentifier(parser, context, parser.tokenValue, expr, inNew, canAssign, 0, start, line, column);
- }
- return expr;
- }
- function parseYieldExpression(parser, context, inGroup, canAssign, start, line, column) {
- if (inGroup)
- parser.destructible |= 256;
- if (context & 2097152) {
- nextToken(parser, context | 32768);
- if (context & 8388608)
- report(parser, 30);
- if (!canAssign)
- report(parser, 24);
- if (parser.token === 22)
- report(parser, 120);
- let argument = null;
- let delegate = false;
- if ((parser.flags & 1) < 1) {
- delegate = consumeOpt(parser, context | 32768, 8457014);
- if (parser.token & (12288 | 65536) || delegate) {
- argument = parseExpression(parser, context, 1, 0, 0, parser.tokenPos, parser.linePos, parser.colPos);
- }
- }
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, {
- type: 'YieldExpression',
- argument,
- delegate
- });
- }
- if (context & 1024)
- report(parser, 94, 'yield');
- return parseIdentifierOrArrow(parser, context, start, line, column);
- }
- function parseAwaitExpression(parser, context, inNew, inGroup, start, line, column) {
- if (inGroup)
- parser.destructible |= 128;
- if (context & 4194304) {
- if (inNew)
- report(parser, 0);
- if (context & 8388608) {
- reportMessageAt(parser.index, parser.line, parser.index, 29);
- }
- nextToken(parser, context | 32768);
- const argument = parseLeftHandSideExpression(parser, context, 0, 0, 1, parser.tokenPos, parser.linePos, parser.colPos);
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, {
- type: 'AwaitExpression',
- argument
- });
- }
- if (context & 2048)
- report(parser, 107, 'Await');
- return parseIdentifierOrArrow(parser, context, start, line, column);
- }
- function parseFunctionBody(parser, context, scope, origin, firstRestricted, scopeError) {
- const { tokenPos, linePos, colPos } = parser;
- consume(parser, context | 32768, 2162700);
- const body = [];
- const prevContext = context;
- if (parser.token !== 1074790415) {
- while (parser.token === 134283267) {
- const { index, tokenPos, tokenValue, token } = parser;
- const expr = parseLiteral(parser, context);
- if (isValidStrictMode(parser, index, tokenPos, tokenValue)) {
- context |= 1024;
- if (parser.flags & 128) {
- reportMessageAt(parser.index, parser.line, parser.tokenPos, 63);
- }
- if (parser.flags & 64) {
- reportMessageAt(parser.index, parser.line, parser.tokenPos, 8);
- }
- }
- body.push(parseDirective(parser, context, expr, token, tokenPos, parser.linePos, parser.colPos));
- }
- if (context & 1024) {
- if (firstRestricted) {
- if ((firstRestricted & 537079808) === 537079808) {
- report(parser, 115);
- }
- if ((firstRestricted & 36864) === 36864) {
- report(parser, 38);
- }
- }
- if (parser.flags & 512)
- report(parser, 115);
- if (parser.flags & 256)
- report(parser, 114);
- }
- if (context & 64 &&
- scope &&
- scopeError !== void 0 &&
- (prevContext & 1024) < 1 &&
- (context & 8192) < 1) {
- reportScopeError(scopeError);
- }
- }
- parser.flags =
- (parser.flags | 512 | 256 | 64) ^
- (512 | 256 | 64);
- parser.destructible = (parser.destructible | 256) ^ 256;
- while (parser.token !== 1074790415) {
- body.push(parseStatementListItem(parser, context, scope, 4, {}));
- }
- consume(parser, origin & (16 | 8) ? context | 32768 : context, 1074790415);
- parser.flags &= ~(128 | 64);
- if (parser.token === 1077936157)
- report(parser, 24);
- return finishNode(parser, context, tokenPos, linePos, colPos, {
- type: 'BlockStatement',
- body
- });
- }
- function parseSuperExpression(parser, context, start, line, column) {
- nextToken(parser, context);
- switch (parser.token) {
- case 67108991:
- report(parser, 161);
- case 67174411: {
- if ((context & 524288) < 1)
- report(parser, 26);
- if (context & 16384)
- report(parser, 143);
- parser.assignable = 2;
- break;
- }
- case 69271571:
- case 67108877: {
- if ((context & 262144) < 1)
- report(parser, 27);
- if (context & 16384)
- report(parser, 143);
- parser.assignable = 1;
- break;
- }
- default:
- report(parser, 28, 'super');
- }
- return finishNode(parser, context, start, line, column, { type: 'Super' });
- }
- function parseLeftHandSideExpression(parser, context, canAssign, inGroup, isLHS, start, line, column) {
- const expression = parsePrimaryExpression(parser, context, 2, 0, canAssign, 0, inGroup, isLHS, start, line, column);
- return parseMemberOrUpdateExpression(parser, context, expression, inGroup, 0, start, line, column);
- }
- function parseUpdateExpression(parser, context, expr, start, line, column) {
- if (parser.assignable & 2)
- report(parser, 52);
- const { token } = parser;
- nextToken(parser, context);
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, {
- type: 'UpdateExpression',
- argument: expr,
- operator: KeywordDescTable[token & 255],
- prefix: false
- });
- }
- function parseMemberOrUpdateExpression(parser, context, expr, inGroup, inChain, start, line, column) {
- if ((parser.token & 33619968) === 33619968 && (parser.flags & 1) < 1) {
- expr = parseUpdateExpression(parser, context, expr, start, line, column);
- }
- else if ((parser.token & 67108864) === 67108864) {
- context = (context | 134217728 | 8192) ^ (134217728 | 8192);
- switch (parser.token) {
- case 67108877: {
- nextToken(parser, context | 1073741824);
- parser.assignable = 1;
- const property = parsePropertyOrPrivatePropertyName(parser, context);
- expr = finishNode(parser, context, start, line, column, {
- type: 'MemberExpression',
- object: expr,
- computed: false,
- property
- });
- break;
- }
- case 69271571: {
- let restoreHasOptionalChaining = false;
- if ((parser.flags & 2048) === 2048) {
- restoreHasOptionalChaining = true;
- parser.flags = (parser.flags | 2048) ^ 2048;
- }
- nextToken(parser, context | 32768);
- const { tokenPos, linePos, colPos } = parser;
- const property = parseExpressions(parser, context, inGroup, 1, tokenPos, linePos, colPos);
- consume(parser, context, 20);
- parser.assignable = 1;
- expr = finishNode(parser, context, start, line, column, {
- type: 'MemberExpression',
- object: expr,
- computed: true,
- property
- });
- if (restoreHasOptionalChaining) {
- parser.flags |= 2048;
- }
- break;
- }
- case 67174411: {
- if ((parser.flags & 1024) === 1024) {
- parser.flags = (parser.flags | 1024) ^ 1024;
- return expr;
- }
- let restoreHasOptionalChaining = false;
- if ((parser.flags & 2048) === 2048) {
- restoreHasOptionalChaining = true;
- parser.flags = (parser.flags | 2048) ^ 2048;
- }
- const args = parseArguments(parser, context, inGroup);
- parser.assignable = 2;
- expr = finishNode(parser, context, start, line, column, {
- type: 'CallExpression',
- callee: expr,
- arguments: args
- });
- if (restoreHasOptionalChaining) {
- parser.flags |= 2048;
- }
- break;
- }
- case 67108991: {
- nextToken(parser, context);
- parser.flags |= 2048;
- parser.assignable = 2;
- expr = parseOptionalChain(parser, context, expr, start, line, column);
- break;
- }
- default:
- if ((parser.flags & 2048) === 2048) {
- report(parser, 160);
- }
- parser.assignable = 2;
- expr = finishNode(parser, context, start, line, column, {
- type: 'TaggedTemplateExpression',
- tag: expr,
- quasi: parser.token === 67174408
- ? parseTemplate(parser, context | 65536)
- : parseTemplateLiteral(parser, context, parser.tokenPos, parser.linePos, parser.colPos)
- });
- }
- expr = parseMemberOrUpdateExpression(parser, context, expr, 0, 1, start, line, column);
- }
- if (inChain === 0 && (parser.flags & 2048) === 2048) {
- parser.flags = (parser.flags | 2048) ^ 2048;
- expr = finishNode(parser, context, start, line, column, {
- type: 'ChainExpression',
- expression: expr
- });
- }
- return expr;
- }
- function parseOptionalChain(parser, context, expr, start, line, column) {
- let restoreHasOptionalChaining = false;
- let node;
- if (parser.token === 69271571 || parser.token === 67174411) {
- if ((parser.flags & 2048) === 2048) {
- restoreHasOptionalChaining = true;
- parser.flags = (parser.flags | 2048) ^ 2048;
- }
- }
- if (parser.token === 69271571) {
- nextToken(parser, context | 32768);
- const { tokenPos, linePos, colPos } = parser;
- const property = parseExpressions(parser, context, 0, 1, tokenPos, linePos, colPos);
- consume(parser, context, 20);
- parser.assignable = 2;
- node = finishNode(parser, context, start, line, column, {
- type: 'MemberExpression',
- object: expr,
- computed: true,
- optional: true,
- property
- });
- }
- else if (parser.token === 67174411) {
- const args = parseArguments(parser, context, 0);
- parser.assignable = 2;
- node = finishNode(parser, context, start, line, column, {
- type: 'CallExpression',
- callee: expr,
- arguments: args,
- optional: true
- });
- }
- else {
- if ((parser.token & (143360 | 4096)) < 1)
- report(parser, 154);
- const property = parseIdentifier(parser, context, 0);
- parser.assignable = 2;
- node = finishNode(parser, context, start, line, column, {
- type: 'MemberExpression',
- object: expr,
- computed: false,
- optional: true,
- property
- });
- }
- if (restoreHasOptionalChaining) {
- parser.flags |= 2048;
- }
- return node;
- }
- function parsePropertyOrPrivatePropertyName(parser, context) {
- if ((parser.token & (143360 | 4096)) < 1 && parser.token !== 131) {
- report(parser, 154);
- }
- return context & 1 && parser.token === 131
- ? parsePrivateIdentifier(parser, context, parser.tokenPos, parser.linePos, parser.colPos)
- : parseIdentifier(parser, context, 0);
- }
- function parseUpdateExpressionPrefixed(parser, context, inNew, isLHS, start, line, column) {
- if (inNew)
- report(parser, 53);
- if (!isLHS)
- report(parser, 0);
- const { token } = parser;
- nextToken(parser, context | 32768);
- const arg = parseLeftHandSideExpression(parser, context, 0, 0, 1, parser.tokenPos, parser.linePos, parser.colPos);
- if (parser.assignable & 2) {
- report(parser, 52);
- }
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, {
- type: 'UpdateExpression',
- argument: arg,
- operator: KeywordDescTable[token & 255],
- prefix: true
- });
- }
- function parsePrimaryExpression(parser, context, kind, inNew, canAssign, isPattern, inGroup, isLHS, start, line, column) {
- if ((parser.token & 143360) === 143360) {
- switch (parser.token) {
- case 209008:
- return parseAwaitExpression(parser, context, inNew, inGroup, start, line, column);
- case 241773:
- return parseYieldExpression(parser, context, inGroup, canAssign, start, line, column);
- case 209007:
- return parseAsyncExpression(parser, context, inGroup, isLHS, canAssign, isPattern, inNew, start, line, column);
- }
- const { token, tokenValue } = parser;
- const expr = parseIdentifier(parser, context | 65536, isPattern);
- if (parser.token === 10) {
- if (!isLHS)
- report(parser, 0);
- classifyIdentifier(parser, context, token, 1);
- return parseArrowFromIdentifier(parser, context, tokenValue, expr, inNew, canAssign, 0, start, line, column);
- }
- if (context & 16384 && token === 537079928)
- report(parser, 126);
- if (token === 241739) {
- if (context & 1024)
- report(parser, 109);
- if (kind & (8 | 16))
- report(parser, 97);
- }
- parser.assignable =
- context & 1024 && (token & 537079808) === 537079808
- ? 2
- : 1;
- return expr;
- }
- if ((parser.token & 134217728) === 134217728) {
- return parseLiteral(parser, context);
- }
- switch (parser.token) {
- case 33619995:
- case 33619996:
- return parseUpdateExpressionPrefixed(parser, context, inNew, isLHS, start, line, column);
- case 16863278:
- case 16842800:
- case 16842801:
- case 25233970:
- case 25233971:
- case 16863277:
- case 16863279:
- return parseUnaryExpression(parser, context, isLHS, start, line, column, inGroup);
- case 86106:
- return parseFunctionExpression(parser, context, 0, inGroup, start, line, column);
- case 2162700:
- return parseObjectLiteral(parser, context, canAssign ? 0 : 1, inGroup, start, line, column);
- case 69271571:
- return parseArrayLiteral(parser, context, canAssign ? 0 : 1, inGroup, start, line, column);
- case 67174411:
- return parseParenthesizedExpression(parser, context, canAssign, 1, 0, start, line, column);
- case 86021:
- case 86022:
- case 86023:
- return parseNullOrTrueOrFalseLiteral(parser, context, start, line, column);
- case 86113:
- return parseThisExpression(parser, context);
- case 65540:
- return parseRegExpLiteral(parser, context, start, line, column);
- case 133:
- case 86096:
- return parseClassExpression(parser, context, inGroup, start, line, column);
- case 86111:
- return parseSuperExpression(parser, context, start, line, column);
- case 67174409:
- return parseTemplateLiteral(parser, context, start, line, column);
- case 67174408:
- return parseTemplate(parser, context);
- case 86109:
- return parseNewExpression(parser, context, inGroup, start, line, column);
- case 134283389:
- return parseBigIntLiteral(parser, context, start, line, column);
- case 131:
- return parsePrivateIdentifier(parser, context, start, line, column);
- case 86108:
- return parseImportCallOrMetaExpression(parser, context, inNew, inGroup, start, line, column);
- case 8456258:
- if (context & 16)
- return parseJSXRootElementOrFragment(parser, context, 1, start, line, column);
- default:
- if (isValidIdentifier(context, parser.token))
- return parseIdentifierOrArrow(parser, context, start, line, column);
- report(parser, 28, KeywordDescTable[parser.token & 255]);
- }
- }
- function parseImportCallOrMetaExpression(parser, context, inNew, inGroup, start, line, column) {
- let expr = parseIdentifier(parser, context, 0);
- if (parser.token === 67108877) {
- return parseImportMetaExpression(parser, context, expr, start, line, column);
- }
- if (inNew)
- report(parser, 137);
- expr = parseImportExpression(parser, context, inGroup, start, line, column);
- parser.assignable = 2;
- return parseMemberOrUpdateExpression(parser, context, expr, inGroup, 0, start, line, column);
- }
- function parseImportMetaExpression(parser, context, meta, start, line, column) {
- if ((context & 2048) === 0)
- report(parser, 163);
- nextToken(parser, context);
- if (parser.token !== 143495 && parser.tokenValue !== 'meta')
- report(parser, 28, KeywordDescTable[parser.token & 255]);
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, {
- type: 'MetaProperty',
- meta,
- property: parseIdentifier(parser, context, 0)
- });
- }
- function parseImportExpression(parser, context, inGroup, start, line, column) {
- consume(parser, context | 32768, 67174411);
- if (parser.token === 14)
- report(parser, 138);
- const source = parseExpression(parser, context, 1, 0, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- consume(parser, context, 16);
- return finishNode(parser, context, start, line, column, {
- type: 'ImportExpression',
- source
- });
- }
- function parseBigIntLiteral(parser, context, start, line, column) {
- const { tokenRaw, tokenValue } = parser;
- nextToken(parser, context);
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, context & 512
- ? {
- type: 'Literal',
- value: tokenValue,
- bigint: tokenRaw.slice(0, -1),
- raw: tokenRaw
- }
- : {
- type: 'Literal',
- value: tokenValue,
- bigint: tokenRaw.slice(0, -1)
- });
- }
- function parseTemplateLiteral(parser, context, start, line, column) {
- parser.assignable = 2;
- const { tokenValue, tokenRaw, tokenPos, linePos, colPos } = parser;
- consume(parser, context, 67174409);
- const quasis = [parseTemplateElement(parser, context, tokenValue, tokenRaw, tokenPos, linePos, colPos, true)];
- return finishNode(parser, context, start, line, column, {
- type: 'TemplateLiteral',
- expressions: [],
- quasis
- });
- }
- function parseTemplate(parser, context) {
- context = (context | 134217728) ^ 134217728;
- const { tokenValue, tokenRaw, tokenPos, linePos, colPos } = parser;
- consume(parser, context | 32768, 67174408);
- const quasis = [
- parseTemplateElement(parser, context, tokenValue, tokenRaw, tokenPos, linePos, colPos, false)
- ];
- const expressions = [parseExpressions(parser, context, 0, 1, parser.tokenPos, parser.linePos, parser.colPos)];
- if (parser.token !== 1074790415)
- report(parser, 80);
- while ((parser.token = scanTemplateTail(parser, context)) !== 67174409) {
- const { tokenValue, tokenRaw, tokenPos, linePos, colPos } = parser;
- consume(parser, context | 32768, 67174408);
- quasis.push(parseTemplateElement(parser, context, tokenValue, tokenRaw, tokenPos, linePos, colPos, false));
- expressions.push(parseExpressions(parser, context, 0, 1, parser.tokenPos, parser.linePos, parser.colPos));
- if (parser.token !== 1074790415)
- report(parser, 80);
- }
- {
- const { tokenValue, tokenRaw, tokenPos, linePos, colPos } = parser;
- consume(parser, context, 67174409);
- quasis.push(parseTemplateElement(parser, context, tokenValue, tokenRaw, tokenPos, linePos, colPos, true));
- }
- return finishNode(parser, context, tokenPos, linePos, colPos, {
- type: 'TemplateLiteral',
- expressions,
- quasis
- });
- }
- function parseTemplateElement(parser, context, cooked, raw, start, line, col, tail) {
- const node = finishNode(parser, context, start, line, col, {
- type: 'TemplateElement',
- value: {
- cooked,
- raw
- },
- tail
- });
- const tailSize = tail ? 1 : 2;
- if (context & 2) {
- node.start += 1;
- node.range[0] += 1;
- node.end -= tailSize;
- node.range[1] -= tailSize;
- }
- if (context & 4) {
- node.loc.start.column += 1;
- node.loc.end.column -= tailSize;
- }
- return node;
- }
- function parseSpreadElement(parser, context, start, line, column) {
- context = (context | 134217728) ^ 134217728;
- consume(parser, context | 32768, 14);
- const argument = parseExpression(parser, context, 1, 0, 0, parser.tokenPos, parser.linePos, parser.colPos);
- parser.assignable = 1;
- return finishNode(parser, context, start, line, column, {
- type: 'SpreadElement',
- argument
- });
- }
- function parseArguments(parser, context, inGroup) {
- nextToken(parser, context | 32768);
- const args = [];
- if (parser.token === 16) {
- nextToken(parser, context);
- return args;
- }
- while (parser.token !== 16) {
- if (parser.token === 14) {
- args.push(parseSpreadElement(parser, context, parser.tokenPos, parser.linePos, parser.colPos));
- }
- else {
- args.push(parseExpression(parser, context, 1, 0, inGroup, parser.tokenPos, parser.linePos, parser.colPos));
- }
- if (parser.token !== 18)
- break;
- nextToken(parser, context | 32768);
- if (parser.token === 16)
- break;
- }
- consume(parser, context, 16);
- return args;
- }
- function parseIdentifier(parser, context, isPattern) {
- const { tokenValue, tokenPos, linePos, colPos } = parser;
- nextToken(parser, context);
- return finishNode(parser, context, tokenPos, linePos, colPos, context & 268435456
- ? {
- type: 'Identifier',
- name: tokenValue,
- pattern: isPattern === 1
- }
- : {
- type: 'Identifier',
- name: tokenValue
- });
- }
- function parseLiteral(parser, context) {
- const { tokenValue, tokenRaw, tokenPos, linePos, colPos } = parser;
- if (parser.token === 134283389) {
- return parseBigIntLiteral(parser, context, tokenPos, linePos, colPos);
- }
- nextToken(parser, context);
- parser.assignable = 2;
- return finishNode(parser, context, tokenPos, linePos, colPos, context & 512
- ? {
- type: 'Literal',
- value: tokenValue,
- raw: tokenRaw
- }
- : {
- type: 'Literal',
- value: tokenValue
- });
- }
- function parseNullOrTrueOrFalseLiteral(parser, context, start, line, column) {
- const raw = KeywordDescTable[parser.token & 255];
- const value = parser.token === 86023 ? null : raw === 'true';
- nextToken(parser, context);
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, context & 512
- ? {
- type: 'Literal',
- value,
- raw
- }
- : {
- type: 'Literal',
- value
- });
- }
- function parseThisExpression(parser, context) {
- const { tokenPos, linePos, colPos } = parser;
- nextToken(parser, context);
- parser.assignable = 2;
- return finishNode(parser, context, tokenPos, linePos, colPos, {
- type: 'ThisExpression'
- });
- }
- function parseFunctionDeclaration(parser, context, scope, origin, allowGen, flags, isAsync, start, line, column) {
- nextToken(parser, context | 32768);
- const isGenerator = allowGen ? optionalBit(parser, context, 8457014) : 0;
- let id = null;
- let firstRestricted;
- let functionScope = scope ? createScope() : void 0;
- if (parser.token === 67174411) {
- if ((flags & 1) < 1)
- report(parser, 37, 'Function');
- }
- else {
- const kind = origin & 4 && ((context & 8192) < 1 || (context & 2048) < 1)
- ? 4
- : 64;
- validateFunctionName(parser, context | ((context & 3072) << 11), parser.token);
- if (scope) {
- if (kind & 4) {
- addVarName(parser, context, scope, parser.tokenValue, kind);
- }
- else {
- addBlockName(parser, context, scope, parser.tokenValue, kind, origin);
- }
- functionScope = addChildScope(functionScope, 256);
- if (flags) {
- if (flags & 2) {
- declareUnboundVariable(parser, parser.tokenValue);
- }
- }
- }
- firstRestricted = parser.token;
- if (parser.token & 143360) {
- id = parseIdentifier(parser, context, 0);
- }
- else {
- report(parser, 28, KeywordDescTable[parser.token & 255]);
- }
- }
- context =
- ((context | 32243712) ^ 32243712) |
- 67108864 |
- ((isAsync * 2 + isGenerator) << 21) |
- (isGenerator ? 0 : 1073741824);
- if (scope)
- functionScope = addChildScope(functionScope, 512);
- const params = parseFormalParametersOrFormalList(parser, context | 8388608, functionScope, 0, 1);
- const body = parseFunctionBody(parser, (context | 8192 | 4096 | 131072) ^
- (8192 | 4096 | 131072), scope ? addChildScope(functionScope, 128) : functionScope, 8, firstRestricted, scope ? functionScope.scopeError : void 0);
- return finishNode(parser, context, start, line, column, {
- type: 'FunctionDeclaration',
- id,
- params,
- body,
- async: isAsync === 1,
- generator: isGenerator === 1
- });
- }
- function parseFunctionExpression(parser, context, isAsync, inGroup, start, line, column) {
- nextToken(parser, context | 32768);
- const isGenerator = optionalBit(parser, context, 8457014);
- const generatorAndAsyncFlags = (isAsync * 2 + isGenerator) << 21;
- let id = null;
- let firstRestricted;
- let scope = context & 64 ? createScope() : void 0;
- if ((parser.token & (143360 | 4096 | 36864)) > 0) {
- validateFunctionName(parser, ((context | 0x1ec0000) ^ 0x1ec0000) | generatorAndAsyncFlags, parser.token);
- if (scope)
- scope = addChildScope(scope, 256);
- firstRestricted = parser.token;
- id = parseIdentifier(parser, context, 0);
- }
- context =
- ((context | 32243712) ^ 32243712) |
- 67108864 |
- generatorAndAsyncFlags |
- (isGenerator ? 0 : 1073741824);
- if (scope)
- scope = addChildScope(scope, 512);
- const params = parseFormalParametersOrFormalList(parser, context | 8388608, scope, inGroup, 1);
- const body = parseFunctionBody(parser, context & ~(0x8001000 | 8192 | 4096 | 131072 | 16384), scope ? addChildScope(scope, 128) : scope, 0, firstRestricted, void 0);
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, {
- type: 'FunctionExpression',
- id,
- params,
- body,
- async: isAsync === 1,
- generator: isGenerator === 1
- });
- }
- function parseArrayLiteral(parser, context, skipInitializer, inGroup, start, line, column) {
- const expr = parseArrayExpressionOrPattern(parser, context, void 0, skipInitializer, inGroup, 0, 2, 0, start, line, column);
- if (context & 256 && parser.destructible & 64) {
- report(parser, 60);
- }
- if (parser.destructible & 8) {
- report(parser, 59);
- }
- return expr;
- }
- function parseArrayExpressionOrPattern(parser, context, scope, skipInitializer, inGroup, isPattern, kind, origin, start, line, column) {
- nextToken(parser, context | 32768);
- const elements = [];
- let destructible = 0;
- context = (context | 134217728) ^ 134217728;
- while (parser.token !== 20) {
- if (consumeOpt(parser, context | 32768, 18)) {
- elements.push(null);
- }
- else {
- let left;
- const { token, tokenPos, linePos, colPos, tokenValue } = parser;
- if (token & 143360) {
- left = parsePrimaryExpression(parser, context, kind, 0, 1, 0, inGroup, 1, tokenPos, linePos, colPos);
- if (parser.token === 1077936157) {
- if (parser.assignable & 2)
- report(parser, 24);
- nextToken(parser, context | 32768);
- if (scope)
- addVarOrBlock(parser, context, scope, tokenValue, kind, origin);
- const right = parseExpression(parser, context, 1, 1, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- left = finishNode(parser, context, tokenPos, linePos, colPos, isPattern
- ? {
- type: 'AssignmentPattern',
- left,
- right
- }
- : {
- type: 'AssignmentExpression',
- operator: '=',
- left,
- right
- });
- destructible |=
- parser.destructible & 256
- ? 256
- : 0 | (parser.destructible & 128)
- ? 128
- : 0;
- }
- else if (parser.token === 18 || parser.token === 20) {
- if (parser.assignable & 2) {
- destructible |= 16;
- }
- else if (scope) {
- addVarOrBlock(parser, context, scope, tokenValue, kind, origin);
- }
- destructible |=
- parser.destructible & 256
- ? 256
- : 0 | (parser.destructible & 128)
- ? 128
- : 0;
- }
- else {
- destructible |=
- kind & 1
- ? 32
- : (kind & 2) < 1
- ? 16
- : 0;
- left = parseMemberOrUpdateExpression(parser, context, left, inGroup, 0, tokenPos, linePos, colPos);
- if (parser.token !== 18 && parser.token !== 20) {
- if (parser.token !== 1077936157)
- destructible |= 16;
- left = parseAssignmentExpression(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, left);
- }
- else if (parser.token !== 1077936157) {
- destructible |=
- parser.assignable & 2
- ? 16
- : 32;
- }
- }
- }
- else if (token & 2097152) {
- left =
- parser.token === 2162700
- ? parseObjectLiteralOrPattern(parser, context, scope, 0, inGroup, isPattern, kind, origin, tokenPos, linePos, colPos)
- : parseArrayExpressionOrPattern(parser, context, scope, 0, inGroup, isPattern, kind, origin, tokenPos, linePos, colPos);
- destructible |= parser.destructible;
- parser.assignable =
- parser.destructible & 16
- ? 2
- : 1;
- if (parser.token === 18 || parser.token === 20) {
- if (parser.assignable & 2) {
- destructible |= 16;
- }
- }
- else if (parser.destructible & 8) {
- report(parser, 68);
- }
- else {
- left = parseMemberOrUpdateExpression(parser, context, left, inGroup, 0, tokenPos, linePos, colPos);
- destructible = parser.assignable & 2 ? 16 : 0;
- if (parser.token !== 18 && parser.token !== 20) {
- left = parseAssignmentExpression(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, left);
- }
- else if (parser.token !== 1077936157) {
- destructible |=
- parser.assignable & 2
- ? 16
- : 32;
- }
- }
- }
- else if (token === 14) {
- left = parseSpreadOrRestElement(parser, context, scope, 20, kind, origin, 0, inGroup, isPattern, tokenPos, linePos, colPos);
- destructible |= parser.destructible;
- if (parser.token !== 18 && parser.token !== 20)
- report(parser, 28, KeywordDescTable[parser.token & 255]);
- }
- else {
- left = parseLeftHandSideExpression(parser, context, 1, 0, 1, tokenPos, linePos, colPos);
- if (parser.token !== 18 && parser.token !== 20) {
- left = parseAssignmentExpression(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, left);
- if ((kind & (2 | 1)) < 1 && token === 67174411)
- destructible |= 16;
- }
- else if (parser.assignable & 2) {
- destructible |= 16;
- }
- else if (token === 67174411) {
- destructible |=
- parser.assignable & 1 && kind & (2 | 1)
- ? 32
- : 16;
- }
- }
- elements.push(left);
- if (consumeOpt(parser, context | 32768, 18)) {
- if (parser.token === 20)
- break;
- }
- else
- break;
- }
- }
- consume(parser, context, 20);
- const node = finishNode(parser, context, start, line, column, {
- type: isPattern ? 'ArrayPattern' : 'ArrayExpression',
- elements
- });
- if (!skipInitializer && parser.token & 4194304) {
- return parseArrayOrObjectAssignmentPattern(parser, context, destructible, inGroup, isPattern, start, line, column, node);
- }
- parser.destructible = destructible;
- return node;
- }
- function parseArrayOrObjectAssignmentPattern(parser, context, destructible, inGroup, isPattern, start, line, column, node) {
- if (parser.token !== 1077936157)
- report(parser, 24);
- nextToken(parser, context | 32768);
- if (destructible & 16)
- report(parser, 24);
- if (!isPattern)
- reinterpretToPattern(parser, node);
- const { tokenPos, linePos, colPos } = parser;
- const right = parseExpression(parser, context, 1, 1, inGroup, tokenPos, linePos, colPos);
- parser.destructible =
- ((destructible | 64 | 8) ^
- (8 | 64)) |
- (parser.destructible & 128 ? 128 : 0) |
- (parser.destructible & 256 ? 256 : 0);
- return finishNode(parser, context, start, line, column, isPattern
- ? {
- type: 'AssignmentPattern',
- left: node,
- right
- }
- : {
- type: 'AssignmentExpression',
- left: node,
- operator: '=',
- right
- });
- }
- function parseSpreadOrRestElement(parser, context, scope, closingToken, kind, origin, isAsync, inGroup, isPattern, start, line, column) {
- nextToken(parser, context | 32768);
- let argument = null;
- let destructible = 0;
- let { token, tokenValue, tokenPos, linePos, colPos } = parser;
- if (token & (4096 | 143360)) {
- parser.assignable = 1;
- argument = parsePrimaryExpression(parser, context, kind, 0, 1, 0, inGroup, 1, tokenPos, linePos, colPos);
- token = parser.token;
- argument = parseMemberOrUpdateExpression(parser, context, argument, inGroup, 0, tokenPos, linePos, colPos);
- if (parser.token !== 18 && parser.token !== closingToken) {
- if (parser.assignable & 2 && parser.token === 1077936157)
- report(parser, 68);
- destructible |= 16;
- argument = parseAssignmentExpression(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, argument);
- }
- if (parser.assignable & 2) {
- destructible |= 16;
- }
- else if (token === closingToken || token === 18) {
- if (scope)
- addVarOrBlock(parser, context, scope, tokenValue, kind, origin);
- }
- else {
- destructible |= 32;
- }
- destructible |= parser.destructible & 128 ? 128 : 0;
- }
- else if (token === closingToken) {
- report(parser, 39);
- }
- else if (token & 2097152) {
- argument =
- parser.token === 2162700
- ? parseObjectLiteralOrPattern(parser, context, scope, 1, inGroup, isPattern, kind, origin, tokenPos, linePos, colPos)
- : parseArrayExpressionOrPattern(parser, context, scope, 1, inGroup, isPattern, kind, origin, tokenPos, linePos, colPos);
- token = parser.token;
- if (token !== 1077936157 && token !== closingToken && token !== 18) {
- if (parser.destructible & 8)
- report(parser, 68);
- argument = parseMemberOrUpdateExpression(parser, context, argument, inGroup, 0, tokenPos, linePos, colPos);
- destructible |= parser.assignable & 2 ? 16 : 0;
- if ((parser.token & 4194304) === 4194304) {
- if (parser.token !== 1077936157)
- destructible |= 16;
- argument = parseAssignmentExpression(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, argument);
- }
- else {
- if ((parser.token & 8454144) === 8454144) {
- argument = parseBinaryExpression(parser, context, 1, tokenPos, linePos, colPos, 4, token, argument);
- }
- if (consumeOpt(parser, context | 32768, 22)) {
- argument = parseConditionalExpression(parser, context, argument, tokenPos, linePos, colPos);
- }
- destructible |=
- parser.assignable & 2
- ? 16
- : 32;
- }
- }
- else {
- destructible |=
- closingToken === 1074790415 && token !== 1077936157
- ? 16
- : parser.destructible;
- }
- }
- else {
- destructible |= 32;
- argument = parseLeftHandSideExpression(parser, context, 1, inGroup, 1, parser.tokenPos, parser.linePos, parser.colPos);
- const { token, tokenPos, linePos, colPos } = parser;
- if (token === 1077936157 && token !== closingToken && token !== 18) {
- if (parser.assignable & 2)
- report(parser, 24);
- argument = parseAssignmentExpression(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, argument);
- destructible |= 16;
- }
- else {
- if (token === 18) {
- destructible |= 16;
- }
- else if (token !== closingToken) {
- argument = parseAssignmentExpression(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, argument);
- }
- destructible |=
- parser.assignable & 1 ? 32 : 16;
- }
- parser.destructible = destructible;
- if (parser.token !== closingToken && parser.token !== 18)
- report(parser, 155);
- return finishNode(parser, context, start, line, column, {
- type: isPattern ? 'RestElement' : 'SpreadElement',
- argument: argument
- });
- }
- if (parser.token !== closingToken) {
- if (kind & 1)
- destructible |= isAsync ? 16 : 32;
- if (consumeOpt(parser, context | 32768, 1077936157)) {
- if (destructible & 16)
- report(parser, 24);
- reinterpretToPattern(parser, argument);
- const right = parseExpression(parser, context, 1, 1, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- argument = finishNode(parser, context, tokenPos, linePos, colPos, isPattern
- ? {
- type: 'AssignmentPattern',
- left: argument,
- right
- }
- : {
- type: 'AssignmentExpression',
- left: argument,
- operator: '=',
- right
- });
- destructible = 16;
- }
- else {
- destructible |= 16;
- }
- }
- parser.destructible = destructible;
- return finishNode(parser, context, start, line, column, {
- type: isPattern ? 'RestElement' : 'SpreadElement',
- argument: argument
- });
- }
- function parseMethodDefinition(parser, context, kind, inGroup, start, line, column) {
- const modifierFlags = (kind & 64) < 1 ? 31981568 : 14680064;
- context =
- ((context | modifierFlags) ^ modifierFlags) |
- ((kind & 88) << 18) |
- 100925440;
- let scope = context & 64 ? addChildScope(createScope(), 512) : void 0;
- const params = parseMethodFormals(parser, context | 8388608, scope, kind, 1, inGroup);
- if (scope)
- scope = addChildScope(scope, 128);
- const body = parseFunctionBody(parser, context & ~(0x8001000 | 8192), scope, 0, void 0, void 0);
- return finishNode(parser, context, start, line, column, {
- type: 'FunctionExpression',
- params,
- body,
- async: (kind & 16) > 0,
- generator: (kind & 8) > 0,
- id: null
- });
- }
- function parseObjectLiteral(parser, context, skipInitializer, inGroup, start, line, column) {
- const expr = parseObjectLiteralOrPattern(parser, context, void 0, skipInitializer, inGroup, 0, 2, 0, start, line, column);
- if (context & 256 && parser.destructible & 64) {
- report(parser, 60);
- }
- if (parser.destructible & 8) {
- report(parser, 59);
- }
- return expr;
- }
- function parseObjectLiteralOrPattern(parser, context, scope, skipInitializer, inGroup, isPattern, kind, origin, start, line, column) {
- nextToken(parser, context);
- const properties = [];
- let destructible = 0;
- let prototypeCount = 0;
- context = (context | 134217728) ^ 134217728;
- while (parser.token !== 1074790415) {
- const { token, tokenValue, linePos, colPos, tokenPos } = parser;
- if (token === 14) {
- properties.push(parseSpreadOrRestElement(parser, context, scope, 1074790415, kind, origin, 0, inGroup, isPattern, tokenPos, linePos, colPos));
- }
- else {
- let state = 0;
- let key = null;
- let value;
- const t = parser.token;
- if (parser.token & (143360 | 4096) || parser.token === 121) {
- key = parseIdentifier(parser, context, 0);
- if (parser.token === 18 || parser.token === 1074790415 || parser.token === 1077936157) {
- state |= 4;
- if (context & 1024 && (token & 537079808) === 537079808) {
- destructible |= 16;
- }
- else {
- validateBindingIdentifier(parser, context, kind, token, 0);
- }
- if (scope)
- addVarOrBlock(parser, context, scope, tokenValue, kind, origin);
- if (consumeOpt(parser, context | 32768, 1077936157)) {
- destructible |= 8;
- const right = parseExpression(parser, context, 1, 1, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- destructible |=
- parser.destructible & 256
- ? 256
- : 0 | (parser.destructible & 128)
- ? 128
- : 0;
- value = finishNode(parser, context, tokenPos, linePos, colPos, {
- type: 'AssignmentPattern',
- left: context & -2147483648 ? Object.assign({}, key) : key,
- right
- });
- }
- else {
- destructible |=
- (token === 209008 ? 128 : 0) |
- (token === 121 ? 16 : 0);
- value = context & -2147483648 ? Object.assign({}, key) : key;
- }
- }
- else if (consumeOpt(parser, context | 32768, 21)) {
- const { tokenPos, linePos, colPos } = parser;
- if (tokenValue === '__proto__')
- prototypeCount++;
- if (parser.token & 143360) {
- const tokenAfterColon = parser.token;
- const valueAfterColon = parser.tokenValue;
- destructible |= t === 121 ? 16 : 0;
- value = parsePrimaryExpression(parser, context, kind, 0, 1, 0, inGroup, 1, tokenPos, linePos, colPos);
- const { token } = parser;
- value = parseMemberOrUpdateExpression(parser, context, value, inGroup, 0, tokenPos, linePos, colPos);
- if (parser.token === 18 || parser.token === 1074790415) {
- if (token === 1077936157 || token === 1074790415 || token === 18) {
- destructible |= parser.destructible & 128 ? 128 : 0;
- if (parser.assignable & 2) {
- destructible |= 16;
- }
- else if (scope && (tokenAfterColon & 143360) === 143360) {
- addVarOrBlock(parser, context, scope, valueAfterColon, kind, origin);
- }
- }
- else {
- destructible |=
- parser.assignable & 1
- ? 32
- : 16;
- }
- }
- else if ((parser.token & 4194304) === 4194304) {
- if (parser.assignable & 2) {
- destructible |= 16;
- }
- else if (token !== 1077936157) {
- destructible |= 32;
- }
- else if (scope) {
- addVarOrBlock(parser, context, scope, valueAfterColon, kind, origin);
- }
- value = parseAssignmentExpression(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, value);
- }
- else {
- destructible |= 16;
- if ((parser.token & 8454144) === 8454144) {
- value = parseBinaryExpression(parser, context, 1, tokenPos, linePos, colPos, 4, token, value);
- }
- if (consumeOpt(parser, context | 32768, 22)) {
- value = parseConditionalExpression(parser, context, value, tokenPos, linePos, colPos);
- }
- }
- }
- else if ((parser.token & 2097152) === 2097152) {
- value =
- parser.token === 69271571
- ? parseArrayExpressionOrPattern(parser, context, scope, 0, inGroup, isPattern, kind, origin, tokenPos, linePos, colPos)
- : parseObjectLiteralOrPattern(parser, context, scope, 0, inGroup, isPattern, kind, origin, tokenPos, linePos, colPos);
- destructible = parser.destructible;
- parser.assignable =
- destructible & 16 ? 2 : 1;
- if (parser.token === 18 || parser.token === 1074790415) {
- if (parser.assignable & 2)
- destructible |= 16;
- }
- else if (parser.destructible & 8) {
- report(parser, 68);
- }
- else {
- value = parseMemberOrUpdateExpression(parser, context, value, inGroup, 0, tokenPos, linePos, colPos);
- destructible = parser.assignable & 2 ? 16 : 0;
- if ((parser.token & 4194304) === 4194304) {
- value = parseAssignmentExpressionOrPattern(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, value);
- }
- else {
- if ((parser.token & 8454144) === 8454144) {
- value = parseBinaryExpression(parser, context, 1, tokenPos, linePos, colPos, 4, token, value);
- }
- if (consumeOpt(parser, context | 32768, 22)) {
- value = parseConditionalExpression(parser, context, value, tokenPos, linePos, colPos);
- }
- destructible |=
- parser.assignable & 2
- ? 16
- : 32;
- }
- }
- }
- else {
- value = parseLeftHandSideExpression(parser, context, 1, inGroup, 1, tokenPos, linePos, colPos);
- destructible |=
- parser.assignable & 1
- ? 32
- : 16;
- if (parser.token === 18 || parser.token === 1074790415) {
- if (parser.assignable & 2)
- destructible |= 16;
- }
- else {
- value = parseMemberOrUpdateExpression(parser, context, value, inGroup, 0, tokenPos, linePos, colPos);
- destructible = parser.assignable & 2 ? 16 : 0;
- if (parser.token !== 18 && token !== 1074790415) {
- if (parser.token !== 1077936157)
- destructible |= 16;
- value = parseAssignmentExpression(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, value);
- }
- }
- }
- }
- else if (parser.token === 69271571) {
- destructible |= 16;
- if (token === 209007)
- state |= 16;
- state |=
- (token === 12402
- ? 256
- : token === 12403
- ? 512
- : 1) | 2;
- key = parseComputedPropertyName(parser, context, inGroup);
- destructible |= parser.assignable;
- value = parseMethodDefinition(parser, context, state, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- }
- else if (parser.token & (143360 | 4096)) {
- destructible |= 16;
- if (token === 121)
- report(parser, 92);
- if (token === 209007) {
- if (parser.flags & 1)
- report(parser, 128);
- state |= 16;
- }
- key = parseIdentifier(parser, context, 0);
- state |=
- token === 12402
- ? 256
- : token === 12403
- ? 512
- : 1;
- value = parseMethodDefinition(parser, context, state, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- }
- else if (parser.token === 67174411) {
- destructible |= 16;
- state |= 1;
- value = parseMethodDefinition(parser, context, state, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- }
- else if (parser.token === 8457014) {
- destructible |= 16;
- if (token === 12402 || token === 12403) {
- report(parser, 40);
- }
- else if (token === 143483) {
- report(parser, 92);
- }
- nextToken(parser, context);
- state |=
- 8 | 1 | (token === 209007 ? 16 : 0);
- if (parser.token & 143360) {
- key = parseIdentifier(parser, context, 0);
- }
- else if ((parser.token & 134217728) === 134217728) {
- key = parseLiteral(parser, context);
- }
- else if (parser.token === 69271571) {
- state |= 2;
- key = parseComputedPropertyName(parser, context, inGroup);
- destructible |= parser.assignable;
- }
- else {
- report(parser, 28, KeywordDescTable[parser.token & 255]);
- }
- value = parseMethodDefinition(parser, context, state, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- }
- else if ((parser.token & 134217728) === 134217728) {
- if (token === 209007)
- state |= 16;
- state |=
- token === 12402
- ? 256
- : token === 12403
- ? 512
- : 1;
- destructible |= 16;
- key = parseLiteral(parser, context);
- value = parseMethodDefinition(parser, context, state, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- }
- else {
- report(parser, 129);
- }
- }
- else if ((parser.token & 134217728) === 134217728) {
- key = parseLiteral(parser, context);
- if (parser.token === 21) {
- consume(parser, context | 32768, 21);
- const { tokenPos, linePos, colPos } = parser;
- if (tokenValue === '__proto__')
- prototypeCount++;
- if (parser.token & 143360) {
- value = parsePrimaryExpression(parser, context, kind, 0, 1, 0, inGroup, 1, tokenPos, linePos, colPos);
- const { token, tokenValue: valueAfterColon } = parser;
- value = parseMemberOrUpdateExpression(parser, context, value, inGroup, 0, tokenPos, linePos, colPos);
- if (parser.token === 18 || parser.token === 1074790415) {
- if (token === 1077936157 || token === 1074790415 || token === 18) {
- if (parser.assignable & 2) {
- destructible |= 16;
- }
- else if (scope) {
- addVarOrBlock(parser, context, scope, valueAfterColon, kind, origin);
- }
- }
- else {
- destructible |=
- parser.assignable & 1
- ? 32
- : 16;
- }
- }
- else if (parser.token === 1077936157) {
- if (parser.assignable & 2)
- destructible |= 16;
- value = parseAssignmentExpression(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, value);
- }
- else {
- destructible |= 16;
- value = parseAssignmentExpression(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, value);
- }
- }
- else if ((parser.token & 2097152) === 2097152) {
- value =
- parser.token === 69271571
- ? parseArrayExpressionOrPattern(parser, context, scope, 0, inGroup, isPattern, kind, origin, tokenPos, linePos, colPos)
- : parseObjectLiteralOrPattern(parser, context, scope, 0, inGroup, isPattern, kind, origin, tokenPos, linePos, colPos);
- destructible = parser.destructible;
- parser.assignable =
- destructible & 16 ? 2 : 1;
- if (parser.token === 18 || parser.token === 1074790415) {
- if (parser.assignable & 2) {
- destructible |= 16;
- }
- }
- else if ((parser.destructible & 8) !== 8) {
- value = parseMemberOrUpdateExpression(parser, context, value, inGroup, 0, tokenPos, linePos, colPos);
- destructible = parser.assignable & 2 ? 16 : 0;
- if ((parser.token & 4194304) === 4194304) {
- value = parseAssignmentExpressionOrPattern(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, value);
- }
- else {
- if ((parser.token & 8454144) === 8454144) {
- value = parseBinaryExpression(parser, context, 1, tokenPos, linePos, colPos, 4, token, value);
- }
- if (consumeOpt(parser, context | 32768, 22)) {
- value = parseConditionalExpression(parser, context, value, tokenPos, linePos, colPos);
- }
- destructible |=
- parser.assignable & 2
- ? 16
- : 32;
- }
- }
- }
- else {
- value = parseLeftHandSideExpression(parser, context, 1, 0, 1, tokenPos, linePos, colPos);
- destructible |=
- parser.assignable & 1
- ? 32
- : 16;
- if (parser.token === 18 || parser.token === 1074790415) {
- if (parser.assignable & 2) {
- destructible |= 16;
- }
- }
- else {
- value = parseMemberOrUpdateExpression(parser, context, value, inGroup, 0, tokenPos, linePos, colPos);
- destructible = parser.assignable & 1 ? 0 : 16;
- if (parser.token !== 18 && parser.token !== 1074790415) {
- if (parser.token !== 1077936157)
- destructible |= 16;
- value = parseAssignmentExpression(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, value);
- }
- }
- }
- }
- else if (parser.token === 67174411) {
- state |= 1;
- value = parseMethodDefinition(parser, context, state, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- destructible = parser.assignable | 16;
- }
- else {
- report(parser, 130);
- }
- }
- else if (parser.token === 69271571) {
- key = parseComputedPropertyName(parser, context, inGroup);
- destructible |= parser.destructible & 256 ? 256 : 0;
- state |= 2;
- if (parser.token === 21) {
- nextToken(parser, context | 32768);
- const { tokenPos, linePos, colPos, tokenValue, token: tokenAfterColon } = parser;
- if (parser.token & 143360) {
- value = parsePrimaryExpression(parser, context, kind, 0, 1, 0, inGroup, 1, tokenPos, linePos, colPos);
- const { token } = parser;
- value = parseMemberOrUpdateExpression(parser, context, value, inGroup, 0, tokenPos, linePos, colPos);
- if ((parser.token & 4194304) === 4194304) {
- destructible |=
- parser.assignable & 2
- ? 16
- : token === 1077936157
- ? 0
- : 32;
- value = parseAssignmentExpressionOrPattern(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, value);
- }
- else if (parser.token === 18 || parser.token === 1074790415) {
- if (token === 1077936157 || token === 1074790415 || token === 18) {
- if (parser.assignable & 2) {
- destructible |= 16;
- }
- else if (scope && (tokenAfterColon & 143360) === 143360) {
- addVarOrBlock(parser, context, scope, tokenValue, kind, origin);
- }
- }
- else {
- destructible |=
- parser.assignable & 1
- ? 32
- : 16;
- }
- }
- else {
- destructible |= 16;
- value = parseAssignmentExpression(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, value);
- }
- }
- else if ((parser.token & 2097152) === 2097152) {
- value =
- parser.token === 69271571
- ? parseArrayExpressionOrPattern(parser, context, scope, 0, inGroup, isPattern, kind, origin, tokenPos, linePos, colPos)
- : parseObjectLiteralOrPattern(parser, context, scope, 0, inGroup, isPattern, kind, origin, tokenPos, linePos, colPos);
- destructible = parser.destructible;
- parser.assignable =
- destructible & 16 ? 2 : 1;
- if (parser.token === 18 || parser.token === 1074790415) {
- if (parser.assignable & 2)
- destructible |= 16;
- }
- else if (destructible & 8) {
- report(parser, 59);
- }
- else {
- value = parseMemberOrUpdateExpression(parser, context, value, inGroup, 0, tokenPos, linePos, colPos);
- destructible =
- parser.assignable & 2 ? destructible | 16 : 0;
- if ((parser.token & 4194304) === 4194304) {
- if (parser.token !== 1077936157)
- destructible |= 16;
- value = parseAssignmentExpressionOrPattern(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, value);
- }
- else {
- if ((parser.token & 8454144) === 8454144) {
- value = parseBinaryExpression(parser, context, 1, tokenPos, linePos, colPos, 4, token, value);
- }
- if (consumeOpt(parser, context | 32768, 22)) {
- value = parseConditionalExpression(parser, context, value, tokenPos, linePos, colPos);
- }
- destructible |=
- parser.assignable & 2
- ? 16
- : 32;
- }
- }
- }
- else {
- value = parseLeftHandSideExpression(parser, context, 1, 0, 1, tokenPos, linePos, colPos);
- destructible |=
- parser.assignable & 1
- ? 32
- : 16;
- if (parser.token === 18 || parser.token === 1074790415) {
- if (parser.assignable & 2)
- destructible |= 16;
- }
- else {
- value = parseMemberOrUpdateExpression(parser, context, value, inGroup, 0, tokenPos, linePos, colPos);
- destructible = parser.assignable & 1 ? 0 : 16;
- if (parser.token !== 18 && parser.token !== 1074790415) {
- if (parser.token !== 1077936157)
- destructible |= 16;
- value = parseAssignmentExpression(parser, context, inGroup, isPattern, tokenPos, linePos, colPos, value);
- }
- }
- }
- }
- else if (parser.token === 67174411) {
- state |= 1;
- value = parseMethodDefinition(parser, context, state, inGroup, parser.tokenPos, linePos, colPos);
- destructible = 16;
- }
- else {
- report(parser, 41);
- }
- }
- else if (token === 8457014) {
- consume(parser, context | 32768, 8457014);
- state |= 8;
- if (parser.token & 143360) {
- const { token, line, index } = parser;
- key = parseIdentifier(parser, context, 0);
- state |= 1;
- if (parser.token === 67174411) {
- destructible |= 16;
- value = parseMethodDefinition(parser, context, state, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- }
- else {
- reportMessageAt(index, line, index, token === 209007
- ? 43
- : token === 12402 || parser.token === 12403
- ? 42
- : 44, KeywordDescTable[token & 255]);
- }
- }
- else if ((parser.token & 134217728) === 134217728) {
- destructible |= 16;
- key = parseLiteral(parser, context);
- state |= 1;
- value = parseMethodDefinition(parser, context, state, inGroup, tokenPos, linePos, colPos);
- }
- else if (parser.token === 69271571) {
- destructible |= 16;
- state |= 2 | 1;
- key = parseComputedPropertyName(parser, context, inGroup);
- value = parseMethodDefinition(parser, context, state, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- }
- else {
- report(parser, 122);
- }
- }
- else {
- report(parser, 28, KeywordDescTable[token & 255]);
- }
- destructible |= parser.destructible & 128 ? 128 : 0;
- parser.destructible = destructible;
- properties.push(finishNode(parser, context, tokenPos, linePos, colPos, {
- type: 'Property',
- key: key,
- value,
- kind: !(state & 768) ? 'init' : state & 512 ? 'set' : 'get',
- computed: (state & 2) > 0,
- method: (state & 1) > 0,
- shorthand: (state & 4) > 0
- }));
- }
- destructible |= parser.destructible;
- if (parser.token !== 18)
- break;
- nextToken(parser, context);
- }
- consume(parser, context, 1074790415);
- if (prototypeCount > 1)
- destructible |= 64;
- const node = finishNode(parser, context, start, line, column, {
- type: isPattern ? 'ObjectPattern' : 'ObjectExpression',
- properties
- });
- if (!skipInitializer && parser.token & 4194304) {
- return parseArrayOrObjectAssignmentPattern(parser, context, destructible, inGroup, isPattern, start, line, column, node);
- }
- parser.destructible = destructible;
- return node;
- }
- function parseMethodFormals(parser, context, scope, kind, type, inGroup) {
- consume(parser, context, 67174411);
- const params = [];
- parser.flags = (parser.flags | 128) ^ 128;
- if (parser.token === 16) {
- if (kind & 512) {
- report(parser, 35, 'Setter', 'one', '');
- }
- nextToken(parser, context);
- return params;
- }
- if (kind & 256) {
- report(parser, 35, 'Getter', 'no', 's');
- }
- if (kind & 512 && parser.token === 14) {
- report(parser, 36);
- }
- context = (context | 134217728) ^ 134217728;
- let setterArgs = 0;
- let isSimpleParameterList = 0;
- while (parser.token !== 18) {
- let left = null;
- const { tokenPos, linePos, colPos } = parser;
- if (parser.token & 143360) {
- if ((context & 1024) < 1) {
- if ((parser.token & 36864) === 36864) {
- parser.flags |= 256;
- }
- if ((parser.token & 537079808) === 537079808) {
- parser.flags |= 512;
- }
- }
- left = parseAndClassifyIdentifier(parser, context, scope, kind | 1, 0, tokenPos, linePos, colPos);
- }
- else {
- if (parser.token === 2162700) {
- left = parseObjectLiteralOrPattern(parser, context, scope, 1, inGroup, 1, type, 0, tokenPos, linePos, colPos);
- }
- else if (parser.token === 69271571) {
- left = parseArrayExpressionOrPattern(parser, context, scope, 1, inGroup, 1, type, 0, tokenPos, linePos, colPos);
- }
- else if (parser.token === 14) {
- left = parseSpreadOrRestElement(parser, context, scope, 16, type, 0, 0, inGroup, 1, tokenPos, linePos, colPos);
- }
- isSimpleParameterList = 1;
- if (parser.destructible & (32 | 16))
- report(parser, 47);
- }
- if (parser.token === 1077936157) {
- nextToken(parser, context | 32768);
- isSimpleParameterList = 1;
- const right = parseExpression(parser, context, 1, 1, 0, parser.tokenPos, parser.linePos, parser.colPos);
- left = finishNode(parser, context, tokenPos, linePos, colPos, {
- type: 'AssignmentPattern',
- left: left,
- right
- });
- }
- setterArgs++;
- params.push(left);
- if (!consumeOpt(parser, context, 18))
- break;
- if (parser.token === 16) {
- break;
- }
- }
- if (kind & 512 && setterArgs !== 1) {
- report(parser, 35, 'Setter', 'one', '');
- }
- if (scope && scope.scopeError !== void 0)
- reportScopeError(scope.scopeError);
- if (isSimpleParameterList)
- parser.flags |= 128;
- consume(parser, context, 16);
- return params;
- }
- function parseComputedPropertyName(parser, context, inGroup) {
- nextToken(parser, context | 32768);
- const key = parseExpression(parser, (context | 134217728) ^ 134217728, 1, 0, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- consume(parser, context, 20);
- return key;
- }
- function parseParenthesizedExpression(parser, context, canAssign, kind, origin, start, line, column) {
- parser.flags = (parser.flags | 128) ^ 128;
- const { tokenPos: piStart, linePos: plStart, colPos: pcStart } = parser;
- nextToken(parser, context | 32768 | 1073741824);
- const scope = context & 64 ? addChildScope(createScope(), 1024) : void 0;
- context = (context | 134217728 | 8192) ^ (8192 | 134217728);
- if (consumeOpt(parser, context, 16)) {
- return parseParenthesizedArrow(parser, context, scope, [], canAssign, 0, start, line, column);
- }
- let destructible = 0;
- parser.destructible &= ~(256 | 128);
- let expr;
- let expressions = [];
- let isSequence = 0;
- let isSimpleParameterList = 0;
- const { tokenPos: iStart, linePos: lStart, colPos: cStart } = parser;
- parser.assignable = 1;
- while (parser.token !== 16) {
- const { token, tokenPos, linePos, colPos } = parser;
- if (token & (143360 | 4096)) {
- if (scope)
- addBlockName(parser, context, scope, parser.tokenValue, 1, 0);
- expr = parsePrimaryExpression(parser, context, kind, 0, 1, 0, 1, 1, tokenPos, linePos, colPos);
- if (parser.token === 16 || parser.token === 18) {
- if (parser.assignable & 2) {
- destructible |= 16;
- isSimpleParameterList = 1;
- }
- else if ((token & 537079808) === 537079808 ||
- (token & 36864) === 36864) {
- isSimpleParameterList = 1;
- }
- }
- else {
- if (parser.token === 1077936157) {
- isSimpleParameterList = 1;
- }
- else {
- destructible |= 16;
- }
- expr = parseMemberOrUpdateExpression(parser, context, expr, 1, 0, tokenPos, linePos, colPos);
- if (parser.token !== 16 && parser.token !== 18) {
- expr = parseAssignmentExpression(parser, context, 1, 0, tokenPos, linePos, colPos, expr);
- }
- }
- }
- else if ((token & 2097152) === 2097152) {
- expr =
- token === 2162700
- ? parseObjectLiteralOrPattern(parser, context | 1073741824, scope, 0, 1, 0, kind, origin, tokenPos, linePos, colPos)
- : parseArrayExpressionOrPattern(parser, context | 1073741824, scope, 0, 1, 0, kind, origin, tokenPos, linePos, colPos);
- destructible |= parser.destructible;
- isSimpleParameterList = 1;
- parser.assignable = 2;
- if (parser.token !== 16 && parser.token !== 18) {
- if (destructible & 8)
- report(parser, 118);
- expr = parseMemberOrUpdateExpression(parser, context, expr, 0, 0, tokenPos, linePos, colPos);
- destructible |= 16;
- if (parser.token !== 16 && parser.token !== 18) {
- expr = parseAssignmentExpression(parser, context, 0, 0, tokenPos, linePos, colPos, expr);
- }
- }
- }
- else if (token === 14) {
- expr = parseSpreadOrRestElement(parser, context, scope, 16, kind, origin, 0, 1, 0, tokenPos, linePos, colPos);
- if (parser.destructible & 16)
- report(parser, 71);
- isSimpleParameterList = 1;
- if (isSequence && (parser.token === 16 || parser.token === 18)) {
- expressions.push(expr);
- }
- destructible |= 8;
- break;
- }
- else {
- destructible |= 16;
- expr = parseExpression(parser, context, 1, 0, 1, tokenPos, linePos, colPos);
- if (isSequence && (parser.token === 16 || parser.token === 18)) {
- expressions.push(expr);
- }
- if (parser.token === 18) {
- if (!isSequence) {
- isSequence = 1;
- expressions = [expr];
- }
- }
- if (isSequence) {
- while (consumeOpt(parser, context | 32768, 18)) {
- expressions.push(parseExpression(parser, context, 1, 0, 1, parser.tokenPos, parser.linePos, parser.colPos));
- }
- parser.assignable = 2;
- expr = finishNode(parser, context, iStart, lStart, cStart, {
- type: 'SequenceExpression',
- expressions
- });
- }
- consume(parser, context, 16);
- parser.destructible = destructible;
- return expr;
- }
- if (isSequence && (parser.token === 16 || parser.token === 18)) {
- expressions.push(expr);
- }
- if (!consumeOpt(parser, context | 32768, 18))
- break;
- if (!isSequence) {
- isSequence = 1;
- expressions = [expr];
- }
- if (parser.token === 16) {
- destructible |= 8;
- break;
- }
- }
- if (isSequence) {
- parser.assignable = 2;
- expr = finishNode(parser, context, iStart, lStart, cStart, {
- type: 'SequenceExpression',
- expressions
- });
- }
- consume(parser, context, 16);
- if (destructible & 16 && destructible & 8)
- report(parser, 145);
- destructible |=
- parser.destructible & 256
- ? 256
- : 0 | (parser.destructible & 128)
- ? 128
- : 0;
- if (parser.token === 10) {
- if (destructible & (32 | 16))
- report(parser, 46);
- if (context & (4194304 | 2048) && destructible & 128)
- report(parser, 29);
- if (context & (1024 | 2097152) && destructible & 256) {
- report(parser, 30);
- }
- if (isSimpleParameterList)
- parser.flags |= 128;
- return parseParenthesizedArrow(parser, context, scope, isSequence ? expressions : [expr], canAssign, 0, start, line, column);
- }
- else if (destructible & 8) {
- report(parser, 139);
- }
- parser.destructible = ((parser.destructible | 256) ^ 256) | destructible;
- return context & 128
- ? finishNode(parser, context, piStart, plStart, pcStart, {
- type: 'ParenthesizedExpression',
- expression: expr
- })
- : expr;
- }
- function parseIdentifierOrArrow(parser, context, start, line, column) {
- const { tokenValue } = parser;
- const expr = parseIdentifier(parser, context, 0);
- parser.assignable = 1;
- if (parser.token === 10) {
- let scope = void 0;
- if (context & 64)
- scope = createArrowHeadParsingScope(parser, context, tokenValue);
- parser.flags = (parser.flags | 128) ^ 128;
- return parseArrowFunctionExpression(parser, context, scope, [expr], 0, start, line, column);
- }
- return expr;
- }
- function parseArrowFromIdentifier(parser, context, value, expr, inNew, canAssign, isAsync, start, line, column) {
- if (!canAssign)
- report(parser, 54);
- if (inNew)
- report(parser, 48);
- parser.flags &= ~128;
- const scope = context & 64 ? createArrowHeadParsingScope(parser, context, value) : void 0;
- return parseArrowFunctionExpression(parser, context, scope, [expr], isAsync, start, line, column);
- }
- function parseParenthesizedArrow(parser, context, scope, params, canAssign, isAsync, start, line, column) {
- if (!canAssign)
- report(parser, 54);
- for (let i = 0; i < params.length; ++i)
- reinterpretToPattern(parser, params[i]);
- return parseArrowFunctionExpression(parser, context, scope, params, isAsync, start, line, column);
- }
- function parseArrowFunctionExpression(parser, context, scope, params, isAsync, start, line, column) {
- if (parser.flags & 1)
- report(parser, 45);
- consume(parser, context | 32768, 10);
- context = ((context | 15728640) ^ 15728640) | (isAsync << 22);
- const expression = parser.token !== 2162700;
- let body;
- if (scope && scope.scopeError !== void 0) {
- reportScopeError(scope.scopeError);
- }
- if (expression) {
- body = parseExpression(parser, context, 1, 0, 0, parser.tokenPos, parser.linePos, parser.colPos);
- }
- else {
- if (scope)
- scope = addChildScope(scope, 128);
- body = parseFunctionBody(parser, (context | 134221824 | 8192 | 16384) ^
- (134221824 | 8192 | 16384), scope, 16, void 0, void 0);
- switch (parser.token) {
- case 69271571:
- if ((parser.flags & 1) < 1) {
- report(parser, 112);
- }
- break;
- case 67108877:
- case 67174409:
- case 22:
- report(parser, 113);
- case 67174411:
- if ((parser.flags & 1) < 1) {
- report(parser, 112);
- }
- parser.flags |= 1024;
- break;
- }
- if ((parser.token & 8454144) === 8454144 && (parser.flags & 1) < 1)
- report(parser, 28, KeywordDescTable[parser.token & 255]);
- if ((parser.token & 33619968) === 33619968)
- report(parser, 121);
- }
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, {
- type: 'ArrowFunctionExpression',
- params,
- body,
- async: isAsync === 1,
- expression
- });
- }
- function parseFormalParametersOrFormalList(parser, context, scope, inGroup, kind) {
- consume(parser, context, 67174411);
- parser.flags = (parser.flags | 128) ^ 128;
- const params = [];
- if (consumeOpt(parser, context, 16))
- return params;
- context = (context | 134217728) ^ 134217728;
- let isSimpleParameterList = 0;
- while (parser.token !== 18) {
- let left;
- const { tokenPos, linePos, colPos } = parser;
- if (parser.token & 143360) {
- if ((context & 1024) < 1) {
- if ((parser.token & 36864) === 36864) {
- parser.flags |= 256;
- }
- if ((parser.token & 537079808) === 537079808) {
- parser.flags |= 512;
- }
- }
- left = parseAndClassifyIdentifier(parser, context, scope, kind | 1, 0, tokenPos, linePos, colPos);
- }
- else {
- if (parser.token === 2162700) {
- left = parseObjectLiteralOrPattern(parser, context, scope, 1, inGroup, 1, kind, 0, tokenPos, linePos, colPos);
- }
- else if (parser.token === 69271571) {
- left = parseArrayExpressionOrPattern(parser, context, scope, 1, inGroup, 1, kind, 0, tokenPos, linePos, colPos);
- }
- else if (parser.token === 14) {
- left = parseSpreadOrRestElement(parser, context, scope, 16, kind, 0, 0, inGroup, 1, tokenPos, linePos, colPos);
- }
- else {
- report(parser, 28, KeywordDescTable[parser.token & 255]);
- }
- isSimpleParameterList = 1;
- if (parser.destructible & (32 | 16)) {
- report(parser, 47);
- }
- }
- if (parser.token === 1077936157) {
- nextToken(parser, context | 32768);
- isSimpleParameterList = 1;
- const right = parseExpression(parser, context, 1, 1, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- left = finishNode(parser, context, tokenPos, linePos, colPos, {
- type: 'AssignmentPattern',
- left,
- right
- });
- }
- params.push(left);
- if (!consumeOpt(parser, context, 18))
- break;
- if (parser.token === 16) {
- break;
- }
- }
- if (isSimpleParameterList)
- parser.flags |= 128;
- if (scope && (isSimpleParameterList || context & 1024) && scope.scopeError !== void 0) {
- reportScopeError(scope.scopeError);
- }
- consume(parser, context, 16);
- return params;
- }
- function parseMembeExpressionNoCall(parser, context, expr, inGroup, start, line, column) {
- const { token } = parser;
- if (token & 67108864) {
- if (token === 67108877) {
- nextToken(parser, context | 1073741824);
- parser.assignable = 1;
- const property = parsePropertyOrPrivatePropertyName(parser, context);
- return parseMembeExpressionNoCall(parser, context, finishNode(parser, context, start, line, column, {
- type: 'MemberExpression',
- object: expr,
- computed: false,
- property
- }), 0, start, line, column);
- }
- else if (token === 69271571) {
- nextToken(parser, context | 32768);
- const { tokenPos, linePos, colPos } = parser;
- const property = parseExpressions(parser, context, inGroup, 1, tokenPos, linePos, colPos);
- consume(parser, context, 20);
- parser.assignable = 1;
- return parseMembeExpressionNoCall(parser, context, finishNode(parser, context, start, line, column, {
- type: 'MemberExpression',
- object: expr,
- computed: true,
- property
- }), 0, start, line, column);
- }
- else if (token === 67174408 || token === 67174409) {
- parser.assignable = 2;
- return parseMembeExpressionNoCall(parser, context, finishNode(parser, context, start, line, column, {
- type: 'TaggedTemplateExpression',
- tag: expr,
- quasi: parser.token === 67174408
- ? parseTemplate(parser, context | 65536)
- : parseTemplateLiteral(parser, context, parser.tokenPos, parser.linePos, parser.colPos)
- }), 0, start, line, column);
- }
- }
- return expr;
- }
- function parseNewExpression(parser, context, inGroup, start, line, column) {
- const id = parseIdentifier(parser, context | 32768, 0);
- const { tokenPos, linePos, colPos } = parser;
- if (consumeOpt(parser, context, 67108877)) {
- if (context & 67108864 && parser.token === 143494) {
- parser.assignable = 2;
- return parseMetaProperty(parser, context, id, start, line, column);
- }
- report(parser, 91);
- }
- parser.assignable = 2;
- if ((parser.token & 16842752) === 16842752) {
- report(parser, 62, KeywordDescTable[parser.token & 255]);
- }
- const expr = parsePrimaryExpression(parser, context, 2, 1, 0, 0, inGroup, 1, tokenPos, linePos, colPos);
- context = (context | 134217728) ^ 134217728;
- if (parser.token === 67108991)
- report(parser, 162);
- const callee = parseMembeExpressionNoCall(parser, context, expr, inGroup, tokenPos, linePos, colPos);
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, {
- type: 'NewExpression',
- callee,
- arguments: parser.token === 67174411 ? parseArguments(parser, context, inGroup) : []
- });
- }
- function parseMetaProperty(parser, context, meta, start, line, column) {
- const property = parseIdentifier(parser, context, 0);
- return finishNode(parser, context, start, line, column, {
- type: 'MetaProperty',
- meta,
- property
- });
- }
- function parseAsyncArrowAfterIdent(parser, context, canAssign, start, line, column) {
- if (parser.token === 209008)
- report(parser, 29);
- if (context & (1024 | 2097152) && parser.token === 241773) {
- report(parser, 30);
- }
- if ((parser.token & 537079808) === 537079808) {
- parser.flags |= 512;
- }
- return parseArrowFromIdentifier(parser, context, parser.tokenValue, parseIdentifier(parser, context, 0), 0, canAssign, 1, start, line, column);
- }
- function parseAsyncArrowOrCallExpression(parser, context, callee, canAssign, kind, origin, flags, start, line, column) {
- nextToken(parser, context | 32768);
- const scope = context & 64 ? addChildScope(createScope(), 1024) : void 0;
- context = (context | 134217728) ^ 134217728;
- if (consumeOpt(parser, context, 16)) {
- if (parser.token === 10) {
- if (flags & 1)
- report(parser, 45);
- return parseParenthesizedArrow(parser, context, scope, [], canAssign, 1, start, line, column);
- }
- return finishNode(parser, context, start, line, column, {
- type: 'CallExpression',
- callee,
- arguments: []
- });
- }
- let destructible = 0;
- let expr = null;
- let isSimpleParameterList = 0;
- parser.destructible =
- (parser.destructible | 256 | 128) ^
- (256 | 128);
- const params = [];
- while (parser.token !== 16) {
- const { token, tokenPos, linePos, colPos } = parser;
- if (token & (143360 | 4096)) {
- if (scope)
- addBlockName(parser, context, scope, parser.tokenValue, kind, 0);
- expr = parsePrimaryExpression(parser, context, kind, 0, 1, 0, 1, 1, tokenPos, linePos, colPos);
- if (parser.token === 16 || parser.token === 18) {
- if (parser.assignable & 2) {
- destructible |= 16;
- isSimpleParameterList = 1;
- }
- else if ((token & 537079808) === 537079808) {
- parser.flags |= 512;
- }
- else if ((token & 36864) === 36864) {
- parser.flags |= 256;
- }
- }
- else {
- if (parser.token === 1077936157) {
- isSimpleParameterList = 1;
- }
- else {
- destructible |= 16;
- }
- expr = parseMemberOrUpdateExpression(parser, context, expr, 1, 0, tokenPos, linePos, colPos);
- if (parser.token !== 16 && parser.token !== 18) {
- expr = parseAssignmentExpression(parser, context, 1, 0, tokenPos, linePos, colPos, expr);
- }
- }
- }
- else if (token & 2097152) {
- expr =
- token === 2162700
- ? parseObjectLiteralOrPattern(parser, context, scope, 0, 1, 0, kind, origin, tokenPos, linePos, colPos)
- : parseArrayExpressionOrPattern(parser, context, scope, 0, 1, 0, kind, origin, tokenPos, linePos, colPos);
- destructible |= parser.destructible;
- isSimpleParameterList = 1;
- if (parser.token !== 16 && parser.token !== 18) {
- if (destructible & 8)
- report(parser, 118);
- expr = parseMemberOrUpdateExpression(parser, context, expr, 0, 0, tokenPos, linePos, colPos);
- destructible |= 16;
- if ((parser.token & 8454144) === 8454144) {
- expr = parseBinaryExpression(parser, context, 1, start, line, column, 4, token, expr);
- }
- if (consumeOpt(parser, context | 32768, 22)) {
- expr = parseConditionalExpression(parser, context, expr, start, line, column);
- }
- }
- }
- else if (token === 14) {
- expr = parseSpreadOrRestElement(parser, context, scope, 16, kind, origin, 1, 1, 0, tokenPos, linePos, colPos);
- destructible |= (parser.token === 16 ? 0 : 16) | parser.destructible;
- isSimpleParameterList = 1;
- }
- else {
- expr = parseExpression(parser, context, 1, 0, 0, tokenPos, linePos, colPos);
- destructible = parser.assignable;
- params.push(expr);
- while (consumeOpt(parser, context | 32768, 18)) {
- params.push(parseExpression(parser, context, 1, 0, 0, tokenPos, linePos, colPos));
- }
- destructible |= parser.assignable;
- consume(parser, context, 16);
- parser.destructible = destructible | 16;
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, {
- type: 'CallExpression',
- callee,
- arguments: params
- });
- }
- params.push(expr);
- if (!consumeOpt(parser, context | 32768, 18))
- break;
- }
- consume(parser, context, 16);
- destructible |=
- parser.destructible & 256
- ? 256
- : 0 | (parser.destructible & 128)
- ? 128
- : 0;
- if (parser.token === 10) {
- if (destructible & (32 | 16))
- report(parser, 25);
- if (parser.flags & 1 || flags & 1)
- report(parser, 45);
- if (destructible & 128)
- report(parser, 29);
- if (context & (1024 | 2097152) && destructible & 256)
- report(parser, 30);
- if (isSimpleParameterList)
- parser.flags |= 128;
- return parseParenthesizedArrow(parser, context, scope, params, canAssign, 1, start, line, column);
- }
- else if (destructible & 8) {
- report(parser, 59);
- }
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, {
- type: 'CallExpression',
- callee,
- arguments: params
- });
- }
- function parseRegExpLiteral(parser, context, start, line, column) {
- const { tokenRaw, tokenRegExp, tokenValue } = parser;
- nextToken(parser, context);
- parser.assignable = 2;
- return context & 512
- ? finishNode(parser, context, start, line, column, {
- type: 'Literal',
- value: tokenValue,
- regex: tokenRegExp,
- raw: tokenRaw
- })
- : finishNode(parser, context, start, line, column, {
- type: 'Literal',
- value: tokenValue,
- regex: tokenRegExp
- });
- }
- function parseClassDeclaration(parser, context, scope, flags, start, line, column) {
- context = (context | 16777216 | 1024) ^ 16777216;
- let decorators = parseDecorators(parser, context);
- if (decorators.length) {
- start = parser.tokenPos;
- line = parser.linePos;
- column = parser.colPos;
- }
- if (parser.leadingDecorators.length) {
- parser.leadingDecorators.push(...decorators);
- decorators = parser.leadingDecorators;
- parser.leadingDecorators = [];
- }
- nextToken(parser, context);
- let id = null;
- let superClass = null;
- const { tokenValue } = parser;
- if (parser.token & 4096 && parser.token !== 20567) {
- if (isStrictReservedWord(parser, context, parser.token)) {
- report(parser, 114);
- }
- if ((parser.token & 537079808) === 537079808) {
- report(parser, 115);
- }
- if (scope) {
- addBlockName(parser, context, scope, tokenValue, 32, 0);
- if (flags) {
- if (flags & 2) {
- declareUnboundVariable(parser, tokenValue);
- }
- }
- }
- id = parseIdentifier(parser, context, 0);
- }
- else {
- if ((flags & 1) < 1)
- report(parser, 37, 'Class');
- }
- let inheritedContext = context;
- if (consumeOpt(parser, context | 32768, 20567)) {
- superClass = parseLeftHandSideExpression(parser, context, 0, 0, 0, parser.tokenPos, parser.linePos, parser.colPos);
- inheritedContext |= 524288;
- }
- else {
- inheritedContext = (inheritedContext | 524288) ^ 524288;
- }
- const body = parseClassBody(parser, inheritedContext, context, scope, 2, 8, 0);
- return finishNode(parser, context, start, line, column, context & 1
- ? {
- type: 'ClassDeclaration',
- id,
- superClass,
- decorators,
- body
- }
- : {
- type: 'ClassDeclaration',
- id,
- superClass,
- body
- });
- }
- function parseClassExpression(parser, context, inGroup, start, line, column) {
- let id = null;
- let superClass = null;
- context = (context | 1024 | 16777216) ^ 16777216;
- const decorators = parseDecorators(parser, context);
- if (decorators.length) {
- start = parser.tokenPos;
- line = parser.linePos;
- column = parser.colPos;
- }
- nextToken(parser, context);
- if (parser.token & 4096 && parser.token !== 20567) {
- if (isStrictReservedWord(parser, context, parser.token))
- report(parser, 114);
- if ((parser.token & 537079808) === 537079808) {
- report(parser, 115);
- }
- id = parseIdentifier(parser, context, 0);
- }
- let inheritedContext = context;
- if (consumeOpt(parser, context | 32768, 20567)) {
- superClass = parseLeftHandSideExpression(parser, context, 0, inGroup, 0, parser.tokenPos, parser.linePos, parser.colPos);
- inheritedContext |= 524288;
- }
- else {
- inheritedContext = (inheritedContext | 524288) ^ 524288;
- }
- const body = parseClassBody(parser, inheritedContext, context, void 0, 2, 0, inGroup);
- parser.assignable = 2;
- return finishNode(parser, context, start, line, column, context & 1
- ? {
- type: 'ClassExpression',
- id,
- superClass,
- decorators,
- body
- }
- : {
- type: 'ClassExpression',
- id,
- superClass,
- body
- });
- }
- function parseDecorators(parser, context) {
- const list = [];
- if (context & 1) {
- while (parser.token === 133) {
- list.push(parseDecoratorList(parser, context, parser.tokenPos, parser.linePos, parser.colPos));
- }
- }
- return list;
- }
- function parseDecoratorList(parser, context, start, line, column) {
- nextToken(parser, context | 32768);
- let expression = parsePrimaryExpression(parser, context, 2, 0, 1, 0, 0, 1, start, line, column);
- expression = parseMemberOrUpdateExpression(parser, context, expression, 0, 0, start, line, column);
- return finishNode(parser, context, start, line, column, {
- type: 'Decorator',
- expression
- });
- }
- function parseClassBody(parser, context, inheritedContext, scope, kind, origin, inGroup) {
- const { tokenPos, linePos, colPos } = parser;
- consume(parser, context | 32768, 2162700);
- context = (context | 134217728) ^ 134217728;
- parser.flags = (parser.flags | 32) ^ 32;
- const body = [];
- let decorators;
- while (parser.token !== 1074790415) {
- let length = 0;
- decorators = parseDecorators(parser, context);
- length = decorators.length;
- if (length > 0 && parser.tokenValue === 'constructor') {
- report(parser, 106);
- }
- if (parser.token === 1074790415)
- report(parser, 105);
- if (consumeOpt(parser, context, 1074790417)) {
- if (length > 0)
- report(parser, 116);
- continue;
- }
- body.push(parseClassElementList(parser, context, scope, inheritedContext, kind, decorators, 0, inGroup, parser.tokenPos, parser.linePos, parser.colPos));
- }
- consume(parser, origin & 8 ? context | 32768 : context, 1074790415);
- return finishNode(parser, context, tokenPos, linePos, colPos, {
- type: 'ClassBody',
- body
- });
- }
- function parseClassElementList(parser, context, scope, inheritedContext, type, decorators, isStatic, inGroup, start, line, column) {
- let kind = isStatic ? 32 : 0;
- let key = null;
- const { token, tokenPos, linePos, colPos } = parser;
- if (token & (143360 | 36864)) {
- key = parseIdentifier(parser, context, 0);
- switch (token) {
- case 36972:
- if (!isStatic && parser.token !== 67174411) {
- return parseClassElementList(parser, context, scope, inheritedContext, type, decorators, 1, inGroup, start, line, column);
- }
- break;
- case 209007:
- if (parser.token !== 67174411 && (parser.flags & 1) < 1) {
- if (context & 1 && (parser.token & 1073741824) === 1073741824) {
- return parsePropertyDefinition(parser, context, key, kind, decorators, tokenPos, linePos, colPos);
- }
- kind |= 16 | (optionalBit(parser, context, 8457014) ? 8 : 0);
- }
- break;
- case 12402:
- if (parser.token !== 67174411) {
- if (context & 1 && (parser.token & 1073741824) === 1073741824) {
- return parsePropertyDefinition(parser, context, key, kind, decorators, tokenPos, linePos, colPos);
- }
- kind |= 256;
- }
- break;
- case 12403:
- if (parser.token !== 67174411) {
- if (context & 1 && (parser.token & 1073741824) === 1073741824) {
- return parsePropertyDefinition(parser, context, key, kind, decorators, tokenPos, linePos, colPos);
- }
- kind |= 512;
- }
- break;
- }
- }
- else if (token === 69271571) {
- kind |= 2;
- key = parseComputedPropertyName(parser, inheritedContext, inGroup);
- }
- else if ((token & 134217728) === 134217728) {
- key = parseLiteral(parser, context);
- }
- else if (token === 8457014) {
- kind |= 8;
- nextToken(parser, context);
- }
- else if (context & 1 && parser.token === 131) {
- kind |= 4096;
- key = parsePrivateIdentifier(parser, context, tokenPos, linePos, colPos);
- context = context | 16384;
- }
- else if (context & 1 && (parser.token & 1073741824) === 1073741824) {
- kind |= 128;
- context = context | 16384;
- }
- else if (token === 122) {
- key = parseIdentifier(parser, context, 0);
- if (parser.token !== 67174411)
- report(parser, 28, KeywordDescTable[parser.token & 255]);
- }
- else {
- report(parser, 28, KeywordDescTable[parser.token & 255]);
- }
- if (kind & (8 | 16 | 768)) {
- if (parser.token & 143360) {
- key = parseIdentifier(parser, context, 0);
- }
- else if ((parser.token & 134217728) === 134217728) {
- key = parseLiteral(parser, context);
- }
- else if (parser.token === 69271571) {
- kind |= 2;
- key = parseComputedPropertyName(parser, context, 0);
- }
- else if (parser.token === 122) {
- key = parseIdentifier(parser, context, 0);
- }
- else if (context & 1 && parser.token === 131) {
- kind |= 4096;
- key = parsePrivateIdentifier(parser, context, tokenPos, linePos, colPos);
- }
- else
- report(parser, 131);
- }
- if ((kind & 2) < 1) {
- if (parser.tokenValue === 'constructor') {
- if ((parser.token & 1073741824) === 1073741824) {
- report(parser, 125);
- }
- else if ((kind & 32) < 1 && parser.token === 67174411) {
- if (kind & (768 | 16 | 128 | 8)) {
- report(parser, 50, 'accessor');
- }
- else if ((context & 524288) < 1) {
- if (parser.flags & 32)
- report(parser, 51);
- else
- parser.flags |= 32;
- }
- }
- kind |= 64;
- }
- else if ((kind & 4096) < 1 &&
- kind & (32 | 768 | 8 | 16) &&
- parser.tokenValue === 'prototype') {
- report(parser, 49);
- }
- }
- if (context & 1 && parser.token !== 67174411) {
- return parsePropertyDefinition(parser, context, key, kind, decorators, tokenPos, linePos, colPos);
- }
- const value = parseMethodDefinition(parser, context, kind, inGroup, parser.tokenPos, parser.linePos, parser.colPos);
- return finishNode(parser, context, start, line, column, context & 1
- ? {
- type: 'MethodDefinition',
- kind: (kind & 32) < 1 && kind & 64
- ? 'constructor'
- : kind & 256
- ? 'get'
- : kind & 512
- ? 'set'
- : 'method',
- static: (kind & 32) > 0,
- computed: (kind & 2) > 0,
- key,
- decorators,
- value
- }
- : {
- type: 'MethodDefinition',
- kind: (kind & 32) < 1 && kind & 64
- ? 'constructor'
- : kind & 256
- ? 'get'
- : kind & 512
- ? 'set'
- : 'method',
- static: (kind & 32) > 0,
- computed: (kind & 2) > 0,
- key,
- value
- });
- }
- function parsePrivateIdentifier(parser, context, start, line, column) {
- nextToken(parser, context);
- const { tokenValue } = parser;
- if (tokenValue === 'constructor')
- report(parser, 124);
- nextToken(parser, context);
- return finishNode(parser, context, start, line, column, {
- type: 'PrivateIdentifier',
- name: tokenValue
- });
- }
- function parsePropertyDefinition(parser, context, key, state, decorators, start, line, column) {
- let value = null;
- if (state & 8)
- report(parser, 0);
- if (parser.token === 1077936157) {
- nextToken(parser, context | 32768);
- const { tokenPos, linePos, colPos } = parser;
- if (parser.token === 537079928)
- report(parser, 115);
- value = parsePrimaryExpression(parser, context | 16384, 2, 0, 1, 0, 0, 1, tokenPos, linePos, colPos);
- if ((parser.token & 1073741824) !== 1073741824) {
- value = parseMemberOrUpdateExpression(parser, context | 16384, value, 0, 0, tokenPos, linePos, colPos);
- value = parseAssignmentExpression(parser, context | 16384, 0, 0, tokenPos, linePos, colPos, value);
- if (parser.token === 18) {
- value = parseSequenceExpression(parser, context, 0, start, line, column, value);
- }
- }
- }
- return finishNode(parser, context, start, line, column, {
- type: 'PropertyDefinition',
- key,
- value,
- static: (state & 32) > 0,
- computed: (state & 2) > 0,
- decorators
- });
- }
- function parseBindingPattern(parser, context, scope, type, origin, start, line, column) {
- if (parser.token & 143360)
- return parseAndClassifyIdentifier(parser, context, scope, type, origin, start, line, column);
- if ((parser.token & 2097152) !== 2097152)
- report(parser, 28, KeywordDescTable[parser.token & 255]);
- const left = parser.token === 69271571
- ? parseArrayExpressionOrPattern(parser, context, scope, 1, 0, 1, type, origin, start, line, column)
- : parseObjectLiteralOrPattern(parser, context, scope, 1, 0, 1, type, origin, start, line, column);
- if (parser.destructible & 16)
- report(parser, 47);
- if (parser.destructible & 32)
- report(parser, 47);
- return left;
- }
- function parseAndClassifyIdentifier(parser, context, scope, kind, origin, start, line, column) {
- const { tokenValue, token } = parser;
- if (context & 1024) {
- if ((token & 537079808) === 537079808) {
- report(parser, 115);
- }
- else if ((token & 36864) === 36864) {
- report(parser, 114);
- }
- }
- if ((token & 20480) === 20480) {
- report(parser, 99);
- }
- if (context & (2048 | 2097152) && token === 241773) {
- report(parser, 30);
- }
- if (token === 241739) {
- if (kind & (8 | 16))
- report(parser, 97);
- }
- if (context & (4194304 | 2048) && token === 209008) {
- report(parser, 95);
- }
- nextToken(parser, context);
- if (scope)
- addVarOrBlock(parser, context, scope, tokenValue, kind, origin);
- return finishNode(parser, context, start, line, column, {
- type: 'Identifier',
- name: tokenValue
- });
- }
- function parseJSXRootElementOrFragment(parser, context, inJSXChild, start, line, column) {
- nextToken(parser, context);
- if (parser.token === 8456259) {
- return finishNode(parser, context, start, line, column, {
- type: 'JSXFragment',
- openingFragment: parseOpeningFragment(parser, context, start, line, column),
- children: parseJSXChildren(parser, context),
- closingFragment: parseJSXClosingFragment(parser, context, inJSXChild, parser.tokenPos, parser.linePos, parser.colPos)
- });
- }
- let closingElement = null;
- let children = [];
- const openingElement = parseJSXOpeningFragmentOrSelfCloseElement(parser, context, inJSXChild, start, line, column);
- if (!openingElement.selfClosing) {
- children = parseJSXChildren(parser, context);
- closingElement = parseJSXClosingElement(parser, context, inJSXChild, parser.tokenPos, parser.linePos, parser.colPos);
- const close = isEqualTagName(closingElement.name);
- if (isEqualTagName(openingElement.name) !== close)
- report(parser, 149, close);
- }
- return finishNode(parser, context, start, line, column, {
- type: 'JSXElement',
- children,
- openingElement,
- closingElement
- });
- }
- function parseOpeningFragment(parser, context, start, line, column) {
- scanJSXToken(parser, context);
- return finishNode(parser, context, start, line, column, {
- type: 'JSXOpeningFragment'
- });
- }
- function parseJSXClosingElement(parser, context, inJSXChild, start, line, column) {
- consume(parser, context, 25);
- const name = parseJSXElementName(parser, context, parser.tokenPos, parser.linePos, parser.colPos);
- if (inJSXChild) {
- consume(parser, context, 8456259);
- }
- else {
- parser.token = scanJSXToken(parser, context);
- }
- return finishNode(parser, context, start, line, column, {
- type: 'JSXClosingElement',
- name
- });
- }
- function parseJSXClosingFragment(parser, context, inJSXChild, start, line, column) {
- consume(parser, context, 25);
- if (inJSXChild) {
- consume(parser, context, 8456259);
- }
- else {
- consume(parser, context, 8456259);
- }
- return finishNode(parser, context, start, line, column, {
- type: 'JSXClosingFragment'
- });
- }
- function parseJSXChildren(parser, context) {
- const children = [];
- while (parser.token !== 25) {
- parser.index = parser.tokenPos = parser.startPos;
- parser.column = parser.colPos = parser.startColumn;
- parser.line = parser.linePos = parser.startLine;
- scanJSXToken(parser, context);
- children.push(parseJSXChild(parser, context, parser.tokenPos, parser.linePos, parser.colPos));
- }
- return children;
- }
- function parseJSXChild(parser, context, start, line, column) {
- if (parser.token === 138)
- return parseJSXText(parser, context, start, line, column);
- if (parser.token === 2162700)
- return parseJSXExpressionContainer(parser, context, 0, 0, start, line, column);
- if (parser.token === 8456258)
- return parseJSXRootElementOrFragment(parser, context, 0, start, line, column);
- report(parser, 0);
- }
- function parseJSXText(parser, context, start, line, column) {
- scanJSXToken(parser, context);
- const node = {
- type: 'JSXText',
- value: parser.tokenValue
- };
- if (context & 512) {
- node.raw = parser.tokenRaw;
- }
- return finishNode(parser, context, start, line, column, node);
- }
- function parseJSXOpeningFragmentOrSelfCloseElement(parser, context, inJSXChild, start, line, column) {
- if ((parser.token & 143360) !== 143360 && (parser.token & 4096) !== 4096)
- report(parser, 0);
- const tagName = parseJSXElementName(parser, context, parser.tokenPos, parser.linePos, parser.colPos);
- const attributes = parseJSXAttributes(parser, context);
- const selfClosing = parser.token === 8457016;
- if (parser.token === 8456259) {
- scanJSXToken(parser, context);
- }
- else {
- consume(parser, context, 8457016);
- if (inJSXChild) {
- consume(parser, context, 8456259);
- }
- else {
- scanJSXToken(parser, context);
- }
- }
- return finishNode(parser, context, start, line, column, {
- type: 'JSXOpeningElement',
- name: tagName,
- attributes,
- selfClosing
- });
- }
- function parseJSXElementName(parser, context, start, line, column) {
- scanJSXIdentifier(parser);
- let key = parseJSXIdentifier(parser, context, start, line, column);
- if (parser.token === 21)
- return parseJSXNamespacedName(parser, context, key, start, line, column);
- while (consumeOpt(parser, context, 67108877)) {
- scanJSXIdentifier(parser);
- key = parseJSXMemberExpression(parser, context, key, start, line, column);
- }
- return key;
- }
- function parseJSXMemberExpression(parser, context, object, start, line, column) {
- const property = parseJSXIdentifier(parser, context, parser.tokenPos, parser.linePos, parser.colPos);
- return finishNode(parser, context, start, line, column, {
- type: 'JSXMemberExpression',
- object,
- property
- });
- }
- function parseJSXAttributes(parser, context) {
- const attributes = [];
- while (parser.token !== 8457016 && parser.token !== 8456259 && parser.token !== 1048576) {
- attributes.push(parseJsxAttribute(parser, context, parser.tokenPos, parser.linePos, parser.colPos));
- }
- return attributes;
- }
- function parseJSXSpreadAttribute(parser, context, start, line, column) {
- nextToken(parser, context);
- consume(parser, context, 14);
- const expression = parseExpression(parser, context, 1, 0, 0, parser.tokenPos, parser.linePos, parser.colPos);
- consume(parser, context, 1074790415);
- return finishNode(parser, context, start, line, column, {
- type: 'JSXSpreadAttribute',
- argument: expression
- });
- }
- function parseJsxAttribute(parser, context, start, line, column) {
- if (parser.token === 2162700)
- return parseJSXSpreadAttribute(parser, context, start, line, column);
- scanJSXIdentifier(parser);
- let value = null;
- let name = parseJSXIdentifier(parser, context, start, line, column);
- if (parser.token === 21) {
- name = parseJSXNamespacedName(parser, context, name, start, line, column);
- }
- if (parser.token === 1077936157) {
- const token = scanJSXAttributeValue(parser, context);
- const { tokenPos, linePos, colPos } = parser;
- switch (token) {
- case 134283267:
- value = parseLiteral(parser, context);
- break;
- case 8456258:
- value = parseJSXRootElementOrFragment(parser, context, 1, tokenPos, linePos, colPos);
- break;
- case 2162700:
- value = parseJSXExpressionContainer(parser, context, 1, 1, tokenPos, linePos, colPos);
- break;
- default:
- report(parser, 148);
- }
- }
- return finishNode(parser, context, start, line, column, {
- type: 'JSXAttribute',
- value,
- name
- });
- }
- function parseJSXNamespacedName(parser, context, namespace, start, line, column) {
- consume(parser, context, 21);
- const name = parseJSXIdentifier(parser, context, parser.tokenPos, parser.linePos, parser.colPos);
- return finishNode(parser, context, start, line, column, {
- type: 'JSXNamespacedName',
- namespace,
- name
- });
- }
- function parseJSXExpressionContainer(parser, context, inJSXChild, isAttr, start, line, column) {
- nextToken(parser, context);
- const { tokenPos, linePos, colPos } = parser;
- if (parser.token === 14)
- return parseJSXSpreadChild(parser, context, tokenPos, linePos, colPos);
- let expression = null;
- if (parser.token === 1074790415) {
- if (isAttr)
- report(parser, 151);
- expression = parseJSXEmptyExpression(parser, context, parser.startPos, parser.startLine, parser.startColumn);
- }
- else {
- expression = parseExpression(parser, context, 1, 0, 0, tokenPos, linePos, colPos);
- }
- if (inJSXChild) {
- consume(parser, context, 1074790415);
- }
- else {
- scanJSXToken(parser, context);
- }
- return finishNode(parser, context, start, line, column, {
- type: 'JSXExpressionContainer',
- expression
- });
- }
- function parseJSXSpreadChild(parser, context, start, line, column) {
- consume(parser, context, 14);
- const expression = parseExpression(parser, context, 1, 0, 0, parser.tokenPos, parser.linePos, parser.colPos);
- consume(parser, context, 1074790415);
- return finishNode(parser, context, start, line, column, {
- type: 'JSXSpreadChild',
- expression
- });
- }
- function parseJSXEmptyExpression(parser, context, start, line, column) {
- parser.startPos = parser.tokenPos;
- parser.startLine = parser.linePos;
- parser.startColumn = parser.colPos;
- return finishNode(parser, context, start, line, column, {
- type: 'JSXEmptyExpression'
- });
- }
- function parseJSXIdentifier(parser, context, start, line, column) {
- const { tokenValue } = parser;
- nextToken(parser, context);
- return finishNode(parser, context, start, line, column, {
- type: 'JSXIdentifier',
- name: tokenValue
- });
- }
- var estree = /*#__PURE__*/Object.freeze({
- __proto__: null
- });
- var version$1 = "4.1.5";
- const version = version$1;
- function parseScript(source, options) {
- return parseSource(source, options, 0);
- }
- function parseModule(source, options) {
- return parseSource(source, options, 1024 | 2048);
- }
- function parse(source, options) {
- return parseSource(source, options, 0);
- }
- exports.ESTree = estree;
- exports.parse = parse;
- exports.parseModule = parseModule;
- exports.parseScript = parseScript;
- exports.version = version;
- Object.defineProperty(exports, '__esModule', { value: true });
- return exports;
- }({}));
|