_yaml.c 1.1 MB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351535253535354535553565357535853595360536153625363536453655366536753685369537053715372537353745375537653775378537953805381538253835384538553865387538853895390539153925393539453955396539753985399540054015402540354045405540654075408540954105411541254135414541554165417541854195420542154225423542454255426542754285429543054315432543354345435543654375438543954405441544254435444544554465447544854495450545154525453545454555456545754585459546054615462546354645465546654675468546954705471547254735474547554765477547854795480548154825483548454855486548754885489549054915492549354945495549654975498549955005501550255035504550555065507550855095510551155125513551455155516551755185519552055215522552355245525552655275528552955305531553255335534553555365537553855395540554155425543554455455546554755485549555055515552555355545555555655575558555955605561556255635564556555665567556855695570557155725573557455755576557755785579558055815582558355845585558655875588558955905591559255935594559555965597559855995600560156025603560456055606560756085609561056115612561356145615561656175618561956205621562256235624562556265627562856295630563156325633563456355636563756385639564056415642564356445645564656475648564956505651565256535654565556565657565856595660566156625663566456655666566756685669567056715672567356745675567656775678567956805681568256835684568556865687568856895690569156925693569456955696569756985699570057015702570357045705570657075708570957105711571257135714571557165717571857195720572157225723572457255726572757285729573057315732573357345735573657375738573957405741574257435744574557465747574857495750575157525753575457555756575757585759576057615762576357645765576657675768576957705771577257735774577557765777577857795780578157825783578457855786578757885789579057915792579357945795579657975798579958005801580258035804580558065807580858095810581158125813581458155816581758185819582058215822582358245825582658275828582958305831583258335834583558365837583858395840584158425843584458455846584758485849585058515852585358545855585658575858585958605861586258635864586558665867586858695870587158725873587458755876587758785879588058815882588358845885588658875888588958905891589258935894589558965897589858995900590159025903590459055906590759085909591059115912591359145915591659175918591959205921592259235924592559265927592859295930593159325933593459355936593759385939594059415942594359445945594659475948594959505951595259535954595559565957595859595960596159625963596459655966596759685969597059715972597359745975597659775978597959805981598259835984598559865987598859895990599159925993599459955996599759985999600060016002600360046005600660076008600960106011601260136014601560166017601860196020602160226023602460256026602760286029603060316032603360346035603660376038603960406041604260436044604560466047604860496050605160526053605460556056605760586059606060616062606360646065606660676068606960706071607260736074607560766077607860796080608160826083608460856086608760886089609060916092609360946095609660976098609961006101610261036104610561066107610861096110611161126113611461156116611761186119612061216122612361246125612661276128612961306131613261336134613561366137613861396140614161426143614461456146614761486149615061516152615361546155615661576158615961606161616261636164616561666167616861696170617161726173617461756176617761786179618061816182618361846185618661876188618961906191619261936194619561966197619861996200620162026203620462056206620762086209621062116212621362146215621662176218621962206221622262236224622562266227622862296230623162326233623462356236623762386239624062416242624362446245624662476248624962506251625262536254625562566257625862596260626162626263626462656266626762686269627062716272627362746275627662776278627962806281628262836284628562866287628862896290629162926293629462956296629762986299630063016302630363046305630663076308630963106311631263136314631563166317631863196320632163226323632463256326632763286329633063316332633363346335633663376338633963406341634263436344634563466347634863496350635163526353635463556356635763586359636063616362636363646365636663676368636963706371637263736374637563766377637863796380638163826383638463856386638763886389639063916392639363946395639663976398639964006401640264036404640564066407640864096410641164126413641464156416641764186419642064216422642364246425642664276428642964306431643264336434643564366437643864396440644164426443644464456446644764486449645064516452645364546455645664576458645964606461646264636464646564666467646864696470647164726473647464756476647764786479648064816482648364846485648664876488648964906491649264936494649564966497649864996500650165026503650465056506650765086509651065116512651365146515651665176518651965206521652265236524652565266527652865296530653165326533653465356536653765386539654065416542654365446545654665476548654965506551655265536554655565566557655865596560656165626563656465656566656765686569657065716572657365746575657665776578657965806581658265836584658565866587658865896590659165926593659465956596659765986599660066016602660366046605660666076608660966106611661266136614661566166617661866196620662166226623662466256626662766286629663066316632663366346635663666376638663966406641664266436644664566466647664866496650665166526653665466556656665766586659666066616662666366646665666666676668666966706671667266736674667566766677667866796680668166826683668466856686668766886689669066916692669366946695669666976698669967006701670267036704670567066707670867096710671167126713671467156716671767186719672067216722672367246725672667276728672967306731673267336734673567366737673867396740674167426743674467456746674767486749675067516752675367546755675667576758675967606761676267636764676567666767676867696770677167726773677467756776677767786779678067816782678367846785678667876788678967906791679267936794679567966797679867996800680168026803680468056806680768086809681068116812681368146815681668176818681968206821682268236824682568266827682868296830683168326833683468356836683768386839684068416842684368446845684668476848684968506851685268536854685568566857685868596860686168626863686468656866686768686869687068716872687368746875687668776878687968806881688268836884688568866887688868896890689168926893689468956896689768986899690069016902690369046905690669076908690969106911691269136914691569166917691869196920692169226923692469256926692769286929693069316932693369346935693669376938693969406941694269436944694569466947694869496950695169526953695469556956695769586959696069616962696369646965696669676968696969706971697269736974697569766977697869796980698169826983698469856986698769886989699069916992699369946995699669976998699970007001700270037004700570067007700870097010701170127013701470157016701770187019702070217022702370247025702670277028702970307031703270337034703570367037703870397040704170427043704470457046704770487049705070517052705370547055705670577058705970607061706270637064706570667067706870697070707170727073707470757076707770787079708070817082708370847085708670877088708970907091709270937094709570967097709870997100710171027103710471057106710771087109711071117112711371147115711671177118711971207121712271237124712571267127712871297130713171327133713471357136713771387139714071417142714371447145714671477148714971507151715271537154715571567157715871597160716171627163716471657166716771687169717071717172717371747175717671777178717971807181718271837184718571867187718871897190719171927193719471957196719771987199720072017202720372047205720672077208720972107211721272137214721572167217721872197220722172227223722472257226722772287229723072317232723372347235723672377238723972407241724272437244724572467247724872497250725172527253725472557256725772587259726072617262726372647265726672677268726972707271727272737274727572767277727872797280728172827283728472857286728772887289729072917292729372947295729672977298729973007301730273037304730573067307730873097310731173127313731473157316731773187319732073217322732373247325732673277328732973307331733273337334733573367337733873397340734173427343734473457346734773487349735073517352735373547355735673577358735973607361736273637364736573667367736873697370737173727373737473757376737773787379738073817382738373847385738673877388738973907391739273937394739573967397739873997400740174027403740474057406740774087409741074117412741374147415741674177418741974207421742274237424742574267427742874297430743174327433743474357436743774387439744074417442744374447445744674477448744974507451745274537454745574567457745874597460746174627463746474657466746774687469747074717472747374747475747674777478747974807481748274837484748574867487748874897490749174927493749474957496749774987499750075017502750375047505750675077508750975107511751275137514751575167517751875197520752175227523752475257526752775287529753075317532753375347535753675377538753975407541754275437544754575467547754875497550755175527553755475557556755775587559756075617562756375647565756675677568756975707571757275737574757575767577757875797580758175827583758475857586758775887589759075917592759375947595759675977598759976007601760276037604760576067607760876097610761176127613761476157616761776187619762076217622762376247625762676277628762976307631763276337634763576367637763876397640764176427643764476457646764776487649765076517652765376547655765676577658765976607661766276637664766576667667766876697670767176727673767476757676767776787679768076817682768376847685768676877688768976907691769276937694769576967697769876997700770177027703770477057706770777087709771077117712771377147715771677177718771977207721772277237724772577267727772877297730773177327733773477357736773777387739774077417742774377447745774677477748774977507751775277537754775577567757775877597760776177627763776477657766776777687769777077717772777377747775777677777778777977807781778277837784778577867787778877897790779177927793779477957796779777987799780078017802780378047805780678077808780978107811781278137814781578167817781878197820782178227823782478257826782778287829783078317832783378347835783678377838783978407841784278437844784578467847784878497850785178527853785478557856785778587859786078617862786378647865786678677868786978707871787278737874787578767877787878797880788178827883788478857886788778887889789078917892789378947895789678977898789979007901790279037904790579067907790879097910791179127913791479157916791779187919792079217922792379247925792679277928792979307931793279337934793579367937793879397940794179427943794479457946794779487949795079517952795379547955795679577958795979607961796279637964796579667967796879697970797179727973797479757976797779787979798079817982798379847985798679877988798979907991799279937994799579967997799879998000800180028003800480058006800780088009801080118012801380148015801680178018801980208021802280238024802580268027802880298030803180328033803480358036803780388039804080418042804380448045804680478048804980508051805280538054805580568057805880598060806180628063806480658066806780688069807080718072807380748075807680778078807980808081808280838084808580868087808880898090809180928093809480958096809780988099810081018102810381048105810681078108810981108111811281138114811581168117811881198120812181228123812481258126812781288129813081318132813381348135813681378138813981408141814281438144814581468147814881498150815181528153815481558156815781588159816081618162816381648165816681678168816981708171817281738174817581768177817881798180818181828183818481858186818781888189819081918192819381948195819681978198819982008201820282038204820582068207820882098210821182128213821482158216821782188219822082218222822382248225822682278228822982308231823282338234823582368237823882398240824182428243824482458246824782488249825082518252825382548255825682578258825982608261826282638264826582668267826882698270827182728273827482758276827782788279828082818282828382848285828682878288828982908291829282938294829582968297829882998300830183028303830483058306830783088309831083118312831383148315831683178318831983208321832283238324832583268327832883298330833183328333833483358336833783388339834083418342834383448345834683478348834983508351835283538354835583568357835883598360836183628363836483658366836783688369837083718372837383748375837683778378837983808381838283838384838583868387838883898390839183928393839483958396839783988399840084018402840384048405840684078408840984108411841284138414841584168417841884198420842184228423842484258426842784288429843084318432843384348435843684378438843984408441844284438444844584468447844884498450845184528453845484558456845784588459846084618462846384648465846684678468846984708471847284738474847584768477847884798480848184828483848484858486848784888489849084918492849384948495849684978498849985008501850285038504850585068507850885098510851185128513851485158516851785188519852085218522852385248525852685278528852985308531853285338534853585368537853885398540854185428543854485458546854785488549855085518552855385548555855685578558855985608561856285638564856585668567856885698570857185728573857485758576857785788579858085818582858385848585858685878588858985908591859285938594859585968597859885998600860186028603860486058606860786088609861086118612861386148615861686178618861986208621862286238624862586268627862886298630863186328633863486358636863786388639864086418642864386448645864686478648864986508651865286538654865586568657865886598660866186628663866486658666866786688669867086718672867386748675867686778678867986808681868286838684868586868687868886898690869186928693869486958696869786988699870087018702870387048705870687078708870987108711871287138714871587168717871887198720872187228723872487258726872787288729873087318732873387348735873687378738873987408741874287438744874587468747874887498750875187528753875487558756875787588759876087618762876387648765876687678768876987708771877287738774877587768777877887798780878187828783878487858786878787888789879087918792879387948795879687978798879988008801880288038804880588068807880888098810881188128813881488158816881788188819882088218822882388248825882688278828882988308831883288338834883588368837883888398840884188428843884488458846884788488849885088518852885388548855885688578858885988608861886288638864886588668867886888698870887188728873887488758876887788788879888088818882888388848885888688878888888988908891889288938894889588968897889888998900890189028903890489058906890789088909891089118912891389148915891689178918891989208921892289238924892589268927892889298930893189328933893489358936893789388939894089418942894389448945894689478948894989508951895289538954895589568957895889598960896189628963896489658966896789688969897089718972897389748975897689778978897989808981898289838984898589868987898889898990899189928993899489958996899789988999900090019002900390049005900690079008900990109011901290139014901590169017901890199020902190229023902490259026902790289029903090319032903390349035903690379038903990409041904290439044904590469047904890499050905190529053905490559056905790589059906090619062906390649065906690679068906990709071907290739074907590769077907890799080908190829083908490859086908790889089909090919092909390949095909690979098909991009101910291039104910591069107910891099110911191129113911491159116911791189119912091219122912391249125912691279128912991309131913291339134913591369137913891399140914191429143914491459146914791489149915091519152915391549155915691579158915991609161916291639164916591669167916891699170917191729173917491759176917791789179918091819182918391849185918691879188918991909191919291939194919591969197919891999200920192029203920492059206920792089209921092119212921392149215921692179218921992209221922292239224922592269227922892299230923192329233923492359236923792389239924092419242924392449245924692479248924992509251925292539254925592569257925892599260926192629263926492659266926792689269927092719272927392749275927692779278927992809281928292839284928592869287928892899290929192929293929492959296929792989299930093019302930393049305930693079308930993109311931293139314931593169317931893199320932193229323932493259326932793289329933093319332933393349335933693379338933993409341934293439344934593469347934893499350935193529353935493559356935793589359936093619362936393649365936693679368936993709371937293739374937593769377937893799380938193829383938493859386938793889389939093919392939393949395939693979398939994009401940294039404940594069407940894099410941194129413941494159416941794189419942094219422942394249425942694279428942994309431943294339434943594369437943894399440944194429443944494459446944794489449945094519452945394549455945694579458945994609461946294639464946594669467946894699470947194729473947494759476947794789479948094819482948394849485948694879488948994909491949294939494949594969497949894999500950195029503950495059506950795089509951095119512951395149515951695179518951995209521952295239524952595269527952895299530953195329533953495359536953795389539954095419542954395449545954695479548954995509551955295539554955595569557955895599560956195629563956495659566956795689569957095719572957395749575957695779578957995809581958295839584958595869587958895899590959195929593959495959596959795989599960096019602960396049605960696079608960996109611961296139614961596169617961896199620962196229623962496259626962796289629963096319632963396349635963696379638963996409641964296439644964596469647964896499650965196529653965496559656965796589659966096619662966396649665966696679668966996709671967296739674967596769677967896799680968196829683968496859686968796889689969096919692969396949695969696979698969997009701970297039704970597069707970897099710971197129713971497159716971797189719972097219722972397249725972697279728972997309731973297339734973597369737973897399740974197429743974497459746974797489749975097519752975397549755975697579758975997609761976297639764976597669767976897699770977197729773977497759776977797789779978097819782978397849785978697879788978997909791979297939794979597969797979897999800980198029803980498059806980798089809981098119812981398149815981698179818981998209821982298239824982598269827982898299830983198329833983498359836983798389839984098419842984398449845984698479848984998509851985298539854985598569857985898599860986198629863986498659866986798689869987098719872987398749875987698779878987998809881988298839884988598869887988898899890989198929893989498959896989798989899990099019902990399049905990699079908990999109911991299139914991599169917991899199920992199229923992499259926992799289929993099319932993399349935993699379938993999409941994299439944994599469947994899499950995199529953995499559956995799589959996099619962996399649965996699679968996999709971997299739974997599769977997899799980998199829983998499859986998799889989999099919992999399949995999699979998999910000100011000210003100041000510006100071000810009100101001110012100131001410015100161001710018100191002010021100221002310024100251002610027100281002910030100311003210033100341003510036100371003810039100401004110042100431004410045100461004710048100491005010051100521005310054100551005610057100581005910060100611006210063100641006510066100671006810069100701007110072100731007410075100761007710078100791008010081100821008310084100851008610087100881008910090100911009210093100941009510096100971009810099101001010110102101031010410105101061010710108101091011010111101121011310114101151011610117101181011910120101211012210123101241012510126101271012810129101301013110132101331013410135101361013710138101391014010141101421014310144101451014610147101481014910150101511015210153101541015510156101571015810159101601016110162101631016410165101661016710168101691017010171101721017310174101751017610177101781017910180101811018210183101841018510186101871018810189101901019110192101931019410195101961019710198101991020010201102021020310204102051020610207102081020910210102111021210213102141021510216102171021810219102201022110222102231022410225102261022710228102291023010231102321023310234102351023610237102381023910240102411024210243102441024510246102471024810249102501025110252102531025410255102561025710258102591026010261102621026310264102651026610267102681026910270102711027210273102741027510276102771027810279102801028110282102831028410285102861028710288102891029010291102921029310294102951029610297102981029910300103011030210303103041030510306103071030810309103101031110312103131031410315103161031710318103191032010321103221032310324103251032610327103281032910330103311033210333103341033510336103371033810339103401034110342103431034410345103461034710348103491035010351103521035310354103551035610357103581035910360103611036210363103641036510366103671036810369103701037110372103731037410375103761037710378103791038010381103821038310384103851038610387103881038910390103911039210393103941039510396103971039810399104001040110402104031040410405104061040710408104091041010411104121041310414104151041610417104181041910420104211042210423104241042510426104271042810429104301043110432104331043410435104361043710438104391044010441104421044310444104451044610447104481044910450104511045210453104541045510456104571045810459104601046110462104631046410465104661046710468104691047010471104721047310474104751047610477104781047910480104811048210483104841048510486104871048810489104901049110492104931049410495104961049710498104991050010501105021050310504105051050610507105081050910510105111051210513105141051510516105171051810519105201052110522105231052410525105261052710528105291053010531105321053310534105351053610537105381053910540105411054210543105441054510546105471054810549105501055110552105531055410555105561055710558105591056010561105621056310564105651056610567105681056910570105711057210573105741057510576105771057810579105801058110582105831058410585105861058710588105891059010591105921059310594105951059610597105981059910600106011060210603106041060510606106071060810609106101061110612106131061410615106161061710618106191062010621106221062310624106251062610627106281062910630106311063210633106341063510636106371063810639106401064110642106431064410645106461064710648106491065010651106521065310654106551065610657106581065910660106611066210663106641066510666106671066810669106701067110672106731067410675106761067710678106791068010681106821068310684106851068610687106881068910690106911069210693106941069510696106971069810699107001070110702107031070410705107061070710708107091071010711107121071310714107151071610717107181071910720107211072210723107241072510726107271072810729107301073110732107331073410735107361073710738107391074010741107421074310744107451074610747107481074910750107511075210753107541075510756107571075810759107601076110762107631076410765107661076710768107691077010771107721077310774107751077610777107781077910780107811078210783107841078510786107871078810789107901079110792107931079410795107961079710798107991080010801108021080310804108051080610807108081080910810108111081210813108141081510816108171081810819108201082110822108231082410825108261082710828108291083010831108321083310834108351083610837108381083910840108411084210843108441084510846108471084810849108501085110852108531085410855108561085710858108591086010861108621086310864108651086610867108681086910870108711087210873108741087510876108771087810879108801088110882108831088410885108861088710888108891089010891108921089310894108951089610897108981089910900109011090210903109041090510906109071090810909109101091110912109131091410915109161091710918109191092010921109221092310924109251092610927109281092910930109311093210933109341093510936109371093810939109401094110942109431094410945109461094710948109491095010951109521095310954109551095610957109581095910960109611096210963109641096510966109671096810969109701097110972109731097410975109761097710978109791098010981109821098310984109851098610987109881098910990109911099210993109941099510996109971099810999110001100111002110031100411005110061100711008110091101011011110121101311014110151101611017110181101911020110211102211023110241102511026110271102811029110301103111032110331103411035110361103711038110391104011041110421104311044110451104611047110481104911050110511105211053110541105511056110571105811059110601106111062110631106411065110661106711068110691107011071110721107311074110751107611077110781107911080110811108211083110841108511086110871108811089110901109111092110931109411095110961109711098110991110011101111021110311104111051110611107111081110911110111111111211113111141111511116111171111811119111201112111122111231112411125111261112711128111291113011131111321113311134111351113611137111381113911140111411114211143111441114511146111471114811149111501115111152111531115411155111561115711158111591116011161111621116311164111651116611167111681116911170111711117211173111741117511176111771117811179111801118111182111831118411185111861118711188111891119011191111921119311194111951119611197111981119911200112011120211203112041120511206112071120811209112101121111212112131121411215112161121711218112191122011221112221122311224112251122611227112281122911230112311123211233112341123511236112371123811239112401124111242112431124411245112461124711248112491125011251112521125311254112551125611257112581125911260112611126211263112641126511266112671126811269112701127111272112731127411275112761127711278112791128011281112821128311284112851128611287112881128911290112911129211293112941129511296112971129811299113001130111302113031130411305113061130711308113091131011311113121131311314113151131611317113181131911320113211132211323113241132511326113271132811329113301133111332113331133411335113361133711338113391134011341113421134311344113451134611347113481134911350113511135211353113541135511356113571135811359113601136111362113631136411365113661136711368113691137011371113721137311374113751137611377113781137911380113811138211383113841138511386113871138811389113901139111392113931139411395113961139711398113991140011401114021140311404114051140611407114081140911410114111141211413114141141511416114171141811419114201142111422114231142411425114261142711428114291143011431114321143311434114351143611437114381143911440114411144211443114441144511446114471144811449114501145111452114531145411455114561145711458114591146011461114621146311464114651146611467114681146911470114711147211473114741147511476114771147811479114801148111482114831148411485114861148711488114891149011491114921149311494114951149611497114981149911500115011150211503115041150511506115071150811509115101151111512115131151411515115161151711518115191152011521115221152311524115251152611527115281152911530115311153211533115341153511536115371153811539115401154111542115431154411545115461154711548115491155011551115521155311554115551155611557115581155911560115611156211563115641156511566115671156811569115701157111572115731157411575115761157711578115791158011581115821158311584115851158611587115881158911590115911159211593115941159511596115971159811599116001160111602116031160411605116061160711608116091161011611116121161311614116151161611617116181161911620116211162211623116241162511626116271162811629116301163111632116331163411635116361163711638116391164011641116421164311644116451164611647116481164911650116511165211653116541165511656116571165811659116601166111662116631166411665116661166711668116691167011671116721167311674116751167611677116781167911680116811168211683116841168511686116871168811689116901169111692116931169411695116961169711698116991170011701117021170311704117051170611707117081170911710117111171211713117141171511716117171171811719117201172111722117231172411725117261172711728117291173011731117321173311734117351173611737117381173911740117411174211743117441174511746117471174811749117501175111752117531175411755117561175711758117591176011761117621176311764117651176611767117681176911770117711177211773117741177511776117771177811779117801178111782117831178411785117861178711788117891179011791117921179311794117951179611797117981179911800118011180211803118041180511806118071180811809118101181111812118131181411815118161181711818118191182011821118221182311824118251182611827118281182911830118311183211833118341183511836118371183811839118401184111842118431184411845118461184711848118491185011851118521185311854118551185611857118581185911860118611186211863118641186511866118671186811869118701187111872118731187411875118761187711878118791188011881118821188311884118851188611887118881188911890118911189211893118941189511896118971189811899119001190111902119031190411905119061190711908119091191011911119121191311914119151191611917119181191911920119211192211923119241192511926119271192811929119301193111932119331193411935119361193711938119391194011941119421194311944119451194611947119481194911950119511195211953119541195511956119571195811959119601196111962119631196411965119661196711968119691197011971119721197311974119751197611977119781197911980119811198211983119841198511986119871198811989119901199111992119931199411995119961199711998119991200012001120021200312004120051200612007120081200912010120111201212013120141201512016120171201812019120201202112022120231202412025120261202712028120291203012031120321203312034120351203612037120381203912040120411204212043120441204512046120471204812049120501205112052120531205412055120561205712058120591206012061120621206312064120651206612067120681206912070120711207212073120741207512076120771207812079120801208112082120831208412085120861208712088120891209012091120921209312094120951209612097120981209912100121011210212103121041210512106121071210812109121101211112112121131211412115121161211712118121191212012121121221212312124121251212612127121281212912130121311213212133121341213512136121371213812139121401214112142121431214412145121461214712148121491215012151121521215312154121551215612157121581215912160121611216212163121641216512166121671216812169121701217112172121731217412175121761217712178121791218012181121821218312184121851218612187121881218912190121911219212193121941219512196121971219812199122001220112202122031220412205122061220712208122091221012211122121221312214122151221612217122181221912220122211222212223122241222512226122271222812229122301223112232122331223412235122361223712238122391224012241122421224312244122451224612247122481224912250122511225212253122541225512256122571225812259122601226112262122631226412265122661226712268122691227012271122721227312274122751227612277122781227912280122811228212283122841228512286122871228812289122901229112292122931229412295122961229712298122991230012301123021230312304123051230612307123081230912310123111231212313123141231512316123171231812319123201232112322123231232412325123261232712328123291233012331123321233312334123351233612337123381233912340123411234212343123441234512346123471234812349123501235112352123531235412355123561235712358123591236012361123621236312364123651236612367123681236912370123711237212373123741237512376123771237812379123801238112382123831238412385123861238712388123891239012391123921239312394123951239612397123981239912400124011240212403124041240512406124071240812409124101241112412124131241412415124161241712418124191242012421124221242312424124251242612427124281242912430124311243212433124341243512436124371243812439124401244112442124431244412445124461244712448124491245012451124521245312454124551245612457124581245912460124611246212463124641246512466124671246812469124701247112472124731247412475124761247712478124791248012481124821248312484124851248612487124881248912490124911249212493124941249512496124971249812499125001250112502125031250412505125061250712508125091251012511125121251312514125151251612517125181251912520125211252212523125241252512526125271252812529125301253112532125331253412535125361253712538125391254012541125421254312544125451254612547125481254912550125511255212553125541255512556125571255812559125601256112562125631256412565125661256712568125691257012571125721257312574125751257612577125781257912580125811258212583125841258512586125871258812589125901259112592125931259412595125961259712598125991260012601126021260312604126051260612607126081260912610126111261212613126141261512616126171261812619126201262112622126231262412625126261262712628126291263012631126321263312634126351263612637126381263912640126411264212643126441264512646126471264812649126501265112652126531265412655126561265712658126591266012661126621266312664126651266612667126681266912670126711267212673126741267512676126771267812679126801268112682126831268412685126861268712688126891269012691126921269312694126951269612697126981269912700127011270212703127041270512706127071270812709127101271112712127131271412715127161271712718127191272012721127221272312724127251272612727127281272912730127311273212733127341273512736127371273812739127401274112742127431274412745127461274712748127491275012751127521275312754127551275612757127581275912760127611276212763127641276512766127671276812769127701277112772127731277412775127761277712778127791278012781127821278312784127851278612787127881278912790127911279212793127941279512796127971279812799128001280112802128031280412805128061280712808128091281012811128121281312814128151281612817128181281912820128211282212823128241282512826128271282812829128301283112832128331283412835128361283712838128391284012841128421284312844128451284612847128481284912850128511285212853128541285512856128571285812859128601286112862128631286412865128661286712868128691287012871128721287312874128751287612877128781287912880128811288212883128841288512886128871288812889128901289112892128931289412895128961289712898128991290012901129021290312904129051290612907129081290912910129111291212913129141291512916129171291812919129201292112922129231292412925129261292712928129291293012931129321293312934129351293612937129381293912940129411294212943129441294512946129471294812949129501295112952129531295412955129561295712958129591296012961129621296312964129651296612967129681296912970129711297212973129741297512976129771297812979129801298112982129831298412985129861298712988129891299012991129921299312994129951299612997129981299913000130011300213003130041300513006130071300813009130101301113012130131301413015130161301713018130191302013021130221302313024130251302613027130281302913030130311303213033130341303513036130371303813039130401304113042130431304413045130461304713048130491305013051130521305313054130551305613057130581305913060130611306213063130641306513066130671306813069130701307113072130731307413075130761307713078130791308013081130821308313084130851308613087130881308913090130911309213093130941309513096130971309813099131001310113102131031310413105131061310713108131091311013111131121311313114131151311613117131181311913120131211312213123131241312513126131271312813129131301313113132131331313413135131361313713138131391314013141131421314313144131451314613147131481314913150131511315213153131541315513156131571315813159131601316113162131631316413165131661316713168131691317013171131721317313174131751317613177131781317913180131811318213183131841318513186131871318813189131901319113192131931319413195131961319713198131991320013201132021320313204132051320613207132081320913210132111321213213132141321513216132171321813219132201322113222132231322413225132261322713228132291323013231132321323313234132351323613237132381323913240132411324213243132441324513246132471324813249132501325113252132531325413255132561325713258132591326013261132621326313264132651326613267132681326913270132711327213273132741327513276132771327813279132801328113282132831328413285132861328713288132891329013291132921329313294132951329613297132981329913300133011330213303133041330513306133071330813309133101331113312133131331413315133161331713318133191332013321133221332313324133251332613327133281332913330133311333213333133341333513336133371333813339133401334113342133431334413345133461334713348133491335013351133521335313354133551335613357133581335913360133611336213363133641336513366133671336813369133701337113372133731337413375133761337713378133791338013381133821338313384133851338613387133881338913390133911339213393133941339513396133971339813399134001340113402134031340413405134061340713408134091341013411134121341313414134151341613417134181341913420134211342213423134241342513426134271342813429134301343113432134331343413435134361343713438134391344013441134421344313444134451344613447134481344913450134511345213453134541345513456134571345813459134601346113462134631346413465134661346713468134691347013471134721347313474134751347613477134781347913480134811348213483134841348513486134871348813489134901349113492134931349413495134961349713498134991350013501135021350313504135051350613507135081350913510135111351213513135141351513516135171351813519135201352113522135231352413525135261352713528135291353013531135321353313534135351353613537135381353913540135411354213543135441354513546135471354813549135501355113552135531355413555135561355713558135591356013561135621356313564135651356613567135681356913570135711357213573135741357513576135771357813579135801358113582135831358413585135861358713588135891359013591135921359313594135951359613597135981359913600136011360213603136041360513606136071360813609136101361113612136131361413615136161361713618136191362013621136221362313624136251362613627136281362913630136311363213633136341363513636136371363813639136401364113642136431364413645136461364713648136491365013651136521365313654136551365613657136581365913660136611366213663136641366513666136671366813669136701367113672136731367413675136761367713678136791368013681136821368313684136851368613687136881368913690136911369213693136941369513696136971369813699137001370113702137031370413705137061370713708137091371013711137121371313714137151371613717137181371913720137211372213723137241372513726137271372813729137301373113732137331373413735137361373713738137391374013741137421374313744137451374613747137481374913750137511375213753137541375513756137571375813759137601376113762137631376413765137661376713768137691377013771137721377313774137751377613777137781377913780137811378213783137841378513786137871378813789137901379113792137931379413795137961379713798137991380013801138021380313804138051380613807138081380913810138111381213813138141381513816138171381813819138201382113822138231382413825138261382713828138291383013831138321383313834138351383613837138381383913840138411384213843138441384513846138471384813849138501385113852138531385413855138561385713858138591386013861138621386313864138651386613867138681386913870138711387213873138741387513876138771387813879138801388113882138831388413885138861388713888138891389013891138921389313894138951389613897138981389913900139011390213903139041390513906139071390813909139101391113912139131391413915139161391713918139191392013921139221392313924139251392613927139281392913930139311393213933139341393513936139371393813939139401394113942139431394413945139461394713948139491395013951139521395313954139551395613957139581395913960139611396213963139641396513966139671396813969139701397113972139731397413975139761397713978139791398013981139821398313984139851398613987139881398913990139911399213993139941399513996139971399813999140001400114002140031400414005140061400714008140091401014011140121401314014140151401614017140181401914020140211402214023140241402514026140271402814029140301403114032140331403414035140361403714038140391404014041140421404314044140451404614047140481404914050140511405214053140541405514056140571405814059140601406114062140631406414065140661406714068140691407014071140721407314074140751407614077140781407914080140811408214083140841408514086140871408814089140901409114092140931409414095140961409714098140991410014101141021410314104141051410614107141081410914110141111411214113141141411514116141171411814119141201412114122141231412414125141261412714128141291413014131141321413314134141351413614137141381413914140141411414214143141441414514146141471414814149141501415114152141531415414155141561415714158141591416014161141621416314164141651416614167141681416914170141711417214173141741417514176141771417814179141801418114182141831418414185141861418714188141891419014191141921419314194141951419614197141981419914200142011420214203142041420514206142071420814209142101421114212142131421414215142161421714218142191422014221142221422314224142251422614227142281422914230142311423214233142341423514236142371423814239142401424114242142431424414245142461424714248142491425014251142521425314254142551425614257142581425914260142611426214263142641426514266142671426814269142701427114272142731427414275142761427714278142791428014281142821428314284142851428614287142881428914290142911429214293142941429514296142971429814299143001430114302143031430414305143061430714308143091431014311143121431314314143151431614317143181431914320143211432214323143241432514326143271432814329143301433114332143331433414335143361433714338143391434014341143421434314344143451434614347143481434914350143511435214353143541435514356143571435814359143601436114362143631436414365143661436714368143691437014371143721437314374143751437614377143781437914380143811438214383143841438514386143871438814389143901439114392143931439414395143961439714398143991440014401144021440314404144051440614407144081440914410144111441214413144141441514416144171441814419144201442114422144231442414425144261442714428144291443014431144321443314434144351443614437144381443914440144411444214443144441444514446144471444814449144501445114452144531445414455144561445714458144591446014461144621446314464144651446614467144681446914470144711447214473144741447514476144771447814479144801448114482144831448414485144861448714488144891449014491144921449314494144951449614497144981449914500145011450214503145041450514506145071450814509145101451114512145131451414515145161451714518145191452014521145221452314524145251452614527145281452914530145311453214533145341453514536145371453814539145401454114542145431454414545145461454714548145491455014551145521455314554145551455614557145581455914560145611456214563145641456514566145671456814569145701457114572145731457414575145761457714578145791458014581145821458314584145851458614587145881458914590145911459214593145941459514596145971459814599146001460114602146031460414605146061460714608146091461014611146121461314614146151461614617146181461914620146211462214623146241462514626146271462814629146301463114632146331463414635146361463714638146391464014641146421464314644146451464614647146481464914650146511465214653146541465514656146571465814659146601466114662146631466414665146661466714668146691467014671146721467314674146751467614677146781467914680146811468214683146841468514686146871468814689146901469114692146931469414695146961469714698146991470014701147021470314704147051470614707147081470914710147111471214713147141471514716147171471814719147201472114722147231472414725147261472714728147291473014731147321473314734147351473614737147381473914740147411474214743147441474514746147471474814749147501475114752147531475414755147561475714758147591476014761147621476314764147651476614767147681476914770147711477214773147741477514776147771477814779147801478114782147831478414785147861478714788147891479014791147921479314794147951479614797147981479914800148011480214803148041480514806148071480814809148101481114812148131481414815148161481714818148191482014821148221482314824148251482614827148281482914830148311483214833148341483514836148371483814839148401484114842148431484414845148461484714848148491485014851148521485314854148551485614857148581485914860148611486214863148641486514866148671486814869148701487114872148731487414875148761487714878148791488014881148821488314884148851488614887148881488914890148911489214893148941489514896148971489814899149001490114902149031490414905149061490714908149091491014911149121491314914149151491614917149181491914920149211492214923149241492514926149271492814929149301493114932149331493414935149361493714938149391494014941149421494314944149451494614947149481494914950149511495214953149541495514956149571495814959149601496114962149631496414965149661496714968149691497014971149721497314974149751497614977149781497914980149811498214983149841498514986149871498814989149901499114992149931499414995149961499714998149991500015001150021500315004150051500615007150081500915010150111501215013150141501515016150171501815019150201502115022150231502415025150261502715028150291503015031150321503315034150351503615037150381503915040150411504215043150441504515046150471504815049150501505115052150531505415055150561505715058150591506015061150621506315064150651506615067150681506915070150711507215073150741507515076150771507815079150801508115082150831508415085150861508715088150891509015091150921509315094150951509615097150981509915100151011510215103151041510515106151071510815109151101511115112151131511415115151161511715118151191512015121151221512315124151251512615127151281512915130151311513215133151341513515136151371513815139151401514115142151431514415145151461514715148151491515015151151521515315154151551515615157151581515915160151611516215163151641516515166151671516815169151701517115172151731517415175151761517715178151791518015181151821518315184151851518615187151881518915190151911519215193151941519515196151971519815199152001520115202152031520415205152061520715208152091521015211152121521315214152151521615217152181521915220152211522215223152241522515226152271522815229152301523115232152331523415235152361523715238152391524015241152421524315244152451524615247152481524915250152511525215253152541525515256152571525815259152601526115262152631526415265152661526715268152691527015271152721527315274152751527615277152781527915280152811528215283152841528515286152871528815289152901529115292152931529415295152961529715298152991530015301153021530315304153051530615307153081530915310153111531215313153141531515316153171531815319153201532115322153231532415325153261532715328153291533015331153321533315334153351533615337153381533915340153411534215343153441534515346153471534815349153501535115352153531535415355153561535715358153591536015361153621536315364153651536615367153681536915370153711537215373153741537515376153771537815379153801538115382153831538415385153861538715388153891539015391153921539315394153951539615397153981539915400154011540215403154041540515406154071540815409154101541115412154131541415415154161541715418154191542015421154221542315424154251542615427154281542915430154311543215433154341543515436154371543815439154401544115442154431544415445154461544715448154491545015451154521545315454154551545615457154581545915460154611546215463154641546515466154671546815469154701547115472154731547415475154761547715478154791548015481154821548315484154851548615487154881548915490154911549215493154941549515496154971549815499155001550115502155031550415505155061550715508155091551015511155121551315514155151551615517155181551915520155211552215523155241552515526155271552815529155301553115532155331553415535155361553715538155391554015541155421554315544155451554615547155481554915550155511555215553155541555515556155571555815559155601556115562155631556415565155661556715568155691557015571155721557315574155751557615577155781557915580155811558215583155841558515586155871558815589155901559115592155931559415595155961559715598155991560015601156021560315604156051560615607156081560915610156111561215613156141561515616156171561815619156201562115622156231562415625156261562715628156291563015631156321563315634156351563615637156381563915640156411564215643156441564515646156471564815649156501565115652156531565415655156561565715658156591566015661156621566315664156651566615667156681566915670156711567215673156741567515676156771567815679156801568115682156831568415685156861568715688156891569015691156921569315694156951569615697156981569915700157011570215703157041570515706157071570815709157101571115712157131571415715157161571715718157191572015721157221572315724157251572615727157281572915730157311573215733157341573515736157371573815739157401574115742157431574415745157461574715748157491575015751157521575315754157551575615757157581575915760157611576215763157641576515766157671576815769157701577115772157731577415775157761577715778157791578015781157821578315784157851578615787157881578915790157911579215793157941579515796157971579815799158001580115802158031580415805158061580715808158091581015811158121581315814158151581615817158181581915820158211582215823158241582515826158271582815829158301583115832158331583415835158361583715838158391584015841158421584315844158451584615847158481584915850158511585215853158541585515856158571585815859158601586115862158631586415865158661586715868158691587015871158721587315874158751587615877158781587915880158811588215883158841588515886158871588815889158901589115892158931589415895158961589715898158991590015901159021590315904159051590615907159081590915910159111591215913159141591515916159171591815919159201592115922159231592415925159261592715928159291593015931159321593315934159351593615937159381593915940159411594215943159441594515946159471594815949159501595115952159531595415955159561595715958159591596015961159621596315964159651596615967159681596915970159711597215973159741597515976159771597815979159801598115982159831598415985159861598715988159891599015991159921599315994159951599615997159981599916000160011600216003160041600516006160071600816009160101601116012160131601416015160161601716018160191602016021160221602316024160251602616027160281602916030160311603216033160341603516036160371603816039160401604116042160431604416045160461604716048160491605016051160521605316054160551605616057160581605916060160611606216063160641606516066160671606816069160701607116072160731607416075160761607716078160791608016081160821608316084160851608616087160881608916090160911609216093160941609516096160971609816099161001610116102161031610416105161061610716108161091611016111161121611316114161151611616117161181611916120161211612216123161241612516126161271612816129161301613116132161331613416135161361613716138161391614016141161421614316144161451614616147161481614916150161511615216153161541615516156161571615816159161601616116162161631616416165161661616716168161691617016171161721617316174161751617616177161781617916180161811618216183161841618516186161871618816189161901619116192161931619416195161961619716198161991620016201162021620316204162051620616207162081620916210162111621216213162141621516216162171621816219162201622116222162231622416225162261622716228162291623016231162321623316234162351623616237162381623916240162411624216243162441624516246162471624816249162501625116252162531625416255162561625716258162591626016261162621626316264162651626616267162681626916270162711627216273162741627516276162771627816279162801628116282162831628416285162861628716288162891629016291162921629316294162951629616297162981629916300163011630216303163041630516306163071630816309163101631116312163131631416315163161631716318163191632016321163221632316324163251632616327163281632916330163311633216333163341633516336163371633816339163401634116342163431634416345163461634716348163491635016351163521635316354163551635616357163581635916360163611636216363163641636516366163671636816369163701637116372163731637416375163761637716378163791638016381163821638316384163851638616387163881638916390163911639216393163941639516396163971639816399164001640116402164031640416405164061640716408164091641016411164121641316414164151641616417164181641916420164211642216423164241642516426164271642816429164301643116432164331643416435164361643716438164391644016441164421644316444164451644616447164481644916450164511645216453164541645516456164571645816459164601646116462164631646416465164661646716468164691647016471164721647316474164751647616477164781647916480164811648216483164841648516486164871648816489164901649116492164931649416495164961649716498164991650016501165021650316504165051650616507165081650916510165111651216513165141651516516165171651816519165201652116522165231652416525165261652716528165291653016531165321653316534165351653616537165381653916540165411654216543165441654516546165471654816549165501655116552165531655416555165561655716558165591656016561165621656316564165651656616567165681656916570165711657216573165741657516576165771657816579165801658116582165831658416585165861658716588165891659016591165921659316594165951659616597165981659916600166011660216603166041660516606166071660816609166101661116612166131661416615166161661716618166191662016621166221662316624166251662616627166281662916630166311663216633166341663516636166371663816639166401664116642166431664416645166461664716648166491665016651166521665316654166551665616657166581665916660166611666216663166641666516666166671666816669166701667116672166731667416675166761667716678166791668016681166821668316684166851668616687166881668916690166911669216693166941669516696166971669816699167001670116702167031670416705167061670716708167091671016711167121671316714167151671616717167181671916720167211672216723167241672516726167271672816729167301673116732167331673416735167361673716738167391674016741167421674316744167451674616747167481674916750167511675216753167541675516756167571675816759167601676116762167631676416765167661676716768167691677016771167721677316774167751677616777167781677916780167811678216783167841678516786167871678816789167901679116792167931679416795167961679716798167991680016801168021680316804168051680616807168081680916810168111681216813168141681516816168171681816819168201682116822168231682416825168261682716828168291683016831168321683316834168351683616837168381683916840168411684216843168441684516846168471684816849168501685116852168531685416855168561685716858168591686016861168621686316864168651686616867168681686916870168711687216873168741687516876168771687816879168801688116882168831688416885168861688716888168891689016891168921689316894168951689616897168981689916900169011690216903169041690516906169071690816909169101691116912169131691416915169161691716918169191692016921169221692316924169251692616927169281692916930169311693216933169341693516936169371693816939169401694116942169431694416945169461694716948169491695016951169521695316954169551695616957169581695916960169611696216963169641696516966169671696816969169701697116972169731697416975169761697716978169791698016981169821698316984169851698616987169881698916990169911699216993169941699516996169971699816999170001700117002170031700417005170061700717008170091701017011170121701317014170151701617017170181701917020170211702217023170241702517026170271702817029170301703117032170331703417035170361703717038170391704017041170421704317044170451704617047170481704917050170511705217053170541705517056170571705817059170601706117062170631706417065170661706717068170691707017071170721707317074170751707617077170781707917080170811708217083170841708517086170871708817089170901709117092170931709417095170961709717098170991710017101171021710317104171051710617107171081710917110171111711217113171141711517116171171711817119171201712117122171231712417125171261712717128171291713017131171321713317134171351713617137171381713917140171411714217143171441714517146171471714817149171501715117152171531715417155171561715717158171591716017161171621716317164171651716617167171681716917170171711717217173171741717517176171771717817179171801718117182171831718417185171861718717188171891719017191171921719317194171951719617197171981719917200172011720217203172041720517206172071720817209172101721117212172131721417215172161721717218172191722017221172221722317224172251722617227172281722917230172311723217233172341723517236172371723817239172401724117242172431724417245172461724717248172491725017251172521725317254172551725617257172581725917260172611726217263172641726517266172671726817269172701727117272172731727417275172761727717278172791728017281172821728317284172851728617287172881728917290172911729217293172941729517296172971729817299173001730117302173031730417305173061730717308173091731017311173121731317314173151731617317173181731917320173211732217323173241732517326173271732817329173301733117332173331733417335173361733717338173391734017341173421734317344173451734617347173481734917350173511735217353173541735517356173571735817359173601736117362173631736417365173661736717368173691737017371173721737317374173751737617377173781737917380173811738217383173841738517386173871738817389173901739117392173931739417395173961739717398173991740017401174021740317404174051740617407174081740917410174111741217413174141741517416174171741817419174201742117422174231742417425174261742717428174291743017431174321743317434174351743617437174381743917440174411744217443174441744517446174471744817449174501745117452174531745417455174561745717458174591746017461174621746317464174651746617467174681746917470174711747217473174741747517476174771747817479174801748117482174831748417485174861748717488174891749017491174921749317494174951749617497174981749917500175011750217503175041750517506175071750817509175101751117512175131751417515175161751717518175191752017521175221752317524175251752617527175281752917530175311753217533175341753517536175371753817539175401754117542175431754417545175461754717548175491755017551175521755317554175551755617557175581755917560175611756217563175641756517566175671756817569175701757117572175731757417575175761757717578175791758017581175821758317584175851758617587175881758917590175911759217593175941759517596175971759817599176001760117602176031760417605176061760717608176091761017611176121761317614176151761617617176181761917620176211762217623176241762517626176271762817629176301763117632176331763417635176361763717638176391764017641176421764317644176451764617647176481764917650176511765217653176541765517656176571765817659176601766117662176631766417665176661766717668176691767017671176721767317674176751767617677176781767917680176811768217683176841768517686176871768817689176901769117692176931769417695176961769717698176991770017701177021770317704177051770617707177081770917710177111771217713177141771517716177171771817719177201772117722177231772417725177261772717728177291773017731177321773317734177351773617737177381773917740177411774217743177441774517746177471774817749177501775117752177531775417755177561775717758177591776017761177621776317764177651776617767177681776917770177711777217773177741777517776177771777817779177801778117782177831778417785177861778717788177891779017791177921779317794177951779617797177981779917800178011780217803178041780517806178071780817809178101781117812178131781417815178161781717818178191782017821178221782317824178251782617827178281782917830178311783217833178341783517836178371783817839178401784117842178431784417845178461784717848178491785017851178521785317854178551785617857178581785917860178611786217863178641786517866178671786817869178701787117872178731787417875178761787717878178791788017881178821788317884178851788617887178881788917890178911789217893178941789517896178971789817899179001790117902179031790417905179061790717908179091791017911179121791317914179151791617917179181791917920179211792217923179241792517926179271792817929179301793117932179331793417935179361793717938179391794017941179421794317944179451794617947179481794917950179511795217953179541795517956179571795817959179601796117962179631796417965179661796717968179691797017971179721797317974179751797617977179781797917980179811798217983179841798517986179871798817989179901799117992179931799417995179961799717998179991800018001180021800318004180051800618007180081800918010180111801218013180141801518016180171801818019180201802118022180231802418025180261802718028180291803018031180321803318034180351803618037180381803918040180411804218043180441804518046180471804818049180501805118052180531805418055180561805718058180591806018061180621806318064180651806618067180681806918070180711807218073180741807518076180771807818079180801808118082180831808418085180861808718088180891809018091180921809318094180951809618097180981809918100181011810218103181041810518106181071810818109181101811118112181131811418115181161811718118181191812018121181221812318124181251812618127181281812918130181311813218133181341813518136181371813818139181401814118142181431814418145181461814718148181491815018151181521815318154181551815618157181581815918160181611816218163181641816518166181671816818169181701817118172181731817418175181761817718178181791818018181181821818318184181851818618187181881818918190181911819218193181941819518196181971819818199182001820118202182031820418205182061820718208182091821018211182121821318214182151821618217182181821918220182211822218223182241822518226182271822818229182301823118232182331823418235182361823718238182391824018241182421824318244182451824618247182481824918250182511825218253182541825518256182571825818259182601826118262182631826418265182661826718268182691827018271182721827318274182751827618277182781827918280182811828218283182841828518286182871828818289182901829118292182931829418295182961829718298182991830018301183021830318304183051830618307183081830918310183111831218313183141831518316183171831818319183201832118322183231832418325183261832718328183291833018331183321833318334183351833618337183381833918340183411834218343183441834518346183471834818349183501835118352183531835418355183561835718358183591836018361183621836318364183651836618367183681836918370183711837218373183741837518376183771837818379183801838118382183831838418385183861838718388183891839018391183921839318394183951839618397183981839918400184011840218403184041840518406184071840818409184101841118412184131841418415184161841718418184191842018421184221842318424184251842618427184281842918430184311843218433184341843518436184371843818439184401844118442184431844418445184461844718448184491845018451184521845318454184551845618457184581845918460184611846218463184641846518466184671846818469184701847118472184731847418475184761847718478184791848018481184821848318484184851848618487184881848918490184911849218493184941849518496184971849818499185001850118502185031850418505185061850718508185091851018511185121851318514185151851618517185181851918520185211852218523185241852518526185271852818529185301853118532185331853418535185361853718538185391854018541185421854318544185451854618547185481854918550185511855218553185541855518556185571855818559185601856118562185631856418565185661856718568185691857018571185721857318574185751857618577185781857918580185811858218583185841858518586185871858818589185901859118592185931859418595185961859718598185991860018601186021860318604186051860618607186081860918610186111861218613186141861518616186171861818619186201862118622186231862418625186261862718628186291863018631186321863318634186351863618637186381863918640186411864218643186441864518646186471864818649186501865118652186531865418655186561865718658186591866018661186621866318664186651866618667186681866918670186711867218673186741867518676186771867818679186801868118682186831868418685186861868718688186891869018691186921869318694186951869618697186981869918700187011870218703187041870518706187071870818709187101871118712187131871418715187161871718718187191872018721187221872318724187251872618727187281872918730187311873218733187341873518736187371873818739187401874118742187431874418745187461874718748187491875018751187521875318754187551875618757187581875918760187611876218763187641876518766187671876818769187701877118772187731877418775187761877718778187791878018781187821878318784187851878618787187881878918790187911879218793187941879518796187971879818799188001880118802188031880418805188061880718808188091881018811188121881318814188151881618817188181881918820188211882218823188241882518826188271882818829188301883118832188331883418835188361883718838188391884018841188421884318844188451884618847188481884918850188511885218853188541885518856188571885818859188601886118862188631886418865188661886718868188691887018871188721887318874188751887618877188781887918880188811888218883188841888518886188871888818889188901889118892188931889418895188961889718898188991890018901189021890318904189051890618907189081890918910189111891218913189141891518916189171891818919189201892118922189231892418925189261892718928189291893018931189321893318934189351893618937189381893918940189411894218943189441894518946189471894818949189501895118952189531895418955189561895718958189591896018961189621896318964189651896618967189681896918970189711897218973189741897518976189771897818979189801898118982189831898418985189861898718988189891899018991189921899318994189951899618997189981899919000190011900219003190041900519006190071900819009190101901119012190131901419015190161901719018190191902019021190221902319024190251902619027190281902919030190311903219033190341903519036190371903819039190401904119042190431904419045190461904719048190491905019051190521905319054190551905619057190581905919060190611906219063190641906519066190671906819069190701907119072190731907419075190761907719078190791908019081190821908319084190851908619087190881908919090190911909219093190941909519096190971909819099191001910119102191031910419105191061910719108191091911019111191121911319114191151911619117191181911919120191211912219123191241912519126191271912819129191301913119132191331913419135191361913719138191391914019141191421914319144191451914619147191481914919150191511915219153191541915519156191571915819159191601916119162191631916419165191661916719168191691917019171191721917319174191751917619177191781917919180191811918219183191841918519186191871918819189191901919119192191931919419195191961919719198191991920019201192021920319204192051920619207192081920919210192111921219213192141921519216192171921819219192201922119222192231922419225192261922719228192291923019231192321923319234192351923619237192381923919240192411924219243192441924519246192471924819249192501925119252192531925419255192561925719258192591926019261192621926319264192651926619267192681926919270192711927219273192741927519276192771927819279192801928119282192831928419285192861928719288192891929019291192921929319294192951929619297192981929919300193011930219303193041930519306193071930819309193101931119312193131931419315193161931719318193191932019321193221932319324193251932619327193281932919330193311933219333193341933519336193371933819339193401934119342193431934419345193461934719348193491935019351193521935319354193551935619357193581935919360193611936219363193641936519366193671936819369193701937119372193731937419375193761937719378193791938019381193821938319384193851938619387193881938919390193911939219393193941939519396193971939819399194001940119402194031940419405194061940719408194091941019411194121941319414194151941619417194181941919420194211942219423194241942519426194271942819429194301943119432194331943419435194361943719438194391944019441194421944319444194451944619447194481944919450194511945219453194541945519456194571945819459194601946119462194631946419465194661946719468194691947019471194721947319474194751947619477194781947919480194811948219483194841948519486194871948819489194901949119492194931949419495194961949719498194991950019501195021950319504195051950619507195081950919510195111951219513195141951519516195171951819519195201952119522195231952419525195261952719528195291953019531195321953319534195351953619537195381953919540195411954219543195441954519546195471954819549195501955119552195531955419555195561955719558195591956019561195621956319564195651956619567195681956919570195711957219573195741957519576195771957819579195801958119582195831958419585195861958719588195891959019591195921959319594195951959619597195981959919600196011960219603196041960519606196071960819609196101961119612196131961419615196161961719618196191962019621196221962319624196251962619627196281962919630196311963219633196341963519636196371963819639196401964119642196431964419645196461964719648196491965019651196521965319654196551965619657196581965919660196611966219663196641966519666196671966819669196701967119672196731967419675196761967719678196791968019681196821968319684196851968619687196881968919690196911969219693196941969519696196971969819699197001970119702197031970419705197061970719708197091971019711197121971319714197151971619717197181971919720197211972219723197241972519726197271972819729197301973119732197331973419735197361973719738197391974019741197421974319744197451974619747197481974919750197511975219753197541975519756197571975819759197601976119762197631976419765197661976719768197691977019771197721977319774197751977619777197781977919780197811978219783197841978519786197871978819789197901979119792197931979419795197961979719798197991980019801198021980319804198051980619807198081980919810198111981219813198141981519816198171981819819198201982119822198231982419825198261982719828198291983019831198321983319834198351983619837198381983919840198411984219843198441984519846198471984819849198501985119852198531985419855198561985719858198591986019861198621986319864198651986619867198681986919870198711987219873198741987519876198771987819879198801988119882198831988419885198861988719888198891989019891198921989319894198951989619897198981989919900199011990219903199041990519906199071990819909199101991119912199131991419915199161991719918199191992019921199221992319924199251992619927199281992919930199311993219933199341993519936199371993819939199401994119942199431994419945199461994719948199491995019951199521995319954199551995619957199581995919960199611996219963199641996519966199671996819969199701997119972199731997419975199761997719978199791998019981199821998319984199851998619987199881998919990199911999219993199941999519996199971999819999200002000120002200032000420005200062000720008200092001020011200122001320014200152001620017200182001920020200212002220023200242002520026200272002820029200302003120032200332003420035200362003720038200392004020041200422004320044200452004620047200482004920050200512005220053200542005520056200572005820059200602006120062200632006420065200662006720068200692007020071200722007320074200752007620077200782007920080200812008220083200842008520086200872008820089200902009120092200932009420095200962009720098200992010020101201022010320104201052010620107201082010920110201112011220113201142011520116201172011820119201202012120122201232012420125201262012720128201292013020131201322013320134201352013620137201382013920140201412014220143201442014520146201472014820149201502015120152201532015420155201562015720158201592016020161201622016320164201652016620167201682016920170201712017220173201742017520176201772017820179201802018120182201832018420185201862018720188201892019020191201922019320194201952019620197201982019920200202012020220203202042020520206202072020820209202102021120212202132021420215202162021720218202192022020221202222022320224202252022620227202282022920230202312023220233202342023520236202372023820239202402024120242202432024420245202462024720248202492025020251202522025320254202552025620257202582025920260202612026220263202642026520266202672026820269202702027120272202732027420275202762027720278202792028020281202822028320284202852028620287202882028920290202912029220293202942029520296202972029820299203002030120302203032030420305203062030720308203092031020311203122031320314203152031620317203182031920320203212032220323203242032520326203272032820329203302033120332203332033420335203362033720338203392034020341203422034320344203452034620347203482034920350203512035220353203542035520356203572035820359203602036120362203632036420365203662036720368203692037020371203722037320374203752037620377203782037920380203812038220383203842038520386203872038820389203902039120392203932039420395203962039720398203992040020401204022040320404204052040620407204082040920410204112041220413204142041520416204172041820419204202042120422204232042420425204262042720428204292043020431204322043320434204352043620437204382043920440204412044220443204442044520446204472044820449204502045120452204532045420455204562045720458204592046020461204622046320464204652046620467204682046920470204712047220473204742047520476204772047820479204802048120482204832048420485204862048720488204892049020491204922049320494204952049620497204982049920500205012050220503205042050520506205072050820509205102051120512205132051420515205162051720518205192052020521205222052320524205252052620527205282052920530205312053220533205342053520536205372053820539205402054120542205432054420545205462054720548205492055020551205522055320554205552055620557205582055920560205612056220563205642056520566205672056820569205702057120572205732057420575205762057720578205792058020581205822058320584205852058620587205882058920590205912059220593205942059520596205972059820599206002060120602206032060420605206062060720608206092061020611206122061320614206152061620617206182061920620206212062220623206242062520626206272062820629206302063120632206332063420635206362063720638206392064020641206422064320644206452064620647206482064920650206512065220653206542065520656206572065820659206602066120662206632066420665206662066720668206692067020671206722067320674206752067620677206782067920680206812068220683206842068520686206872068820689206902069120692206932069420695206962069720698206992070020701207022070320704207052070620707207082070920710207112071220713207142071520716207172071820719207202072120722207232072420725207262072720728207292073020731207322073320734207352073620737207382073920740207412074220743207442074520746207472074820749207502075120752207532075420755207562075720758207592076020761207622076320764207652076620767207682076920770207712077220773207742077520776207772077820779207802078120782207832078420785207862078720788207892079020791207922079320794207952079620797207982079920800208012080220803208042080520806208072080820809208102081120812208132081420815208162081720818208192082020821208222082320824208252082620827208282082920830208312083220833208342083520836208372083820839208402084120842208432084420845208462084720848208492085020851208522085320854208552085620857208582085920860208612086220863208642086520866208672086820869208702087120872208732087420875208762087720878208792088020881208822088320884208852088620887208882088920890208912089220893208942089520896208972089820899209002090120902209032090420905209062090720908209092091020911209122091320914209152091620917209182091920920209212092220923209242092520926209272092820929209302093120932209332093420935209362093720938209392094020941209422094320944209452094620947209482094920950209512095220953209542095520956209572095820959209602096120962209632096420965209662096720968209692097020971209722097320974209752097620977209782097920980209812098220983209842098520986209872098820989209902099120992209932099420995209962099720998209992100021001210022100321004210052100621007210082100921010210112101221013210142101521016210172101821019210202102121022210232102421025210262102721028210292103021031210322103321034210352103621037210382103921040210412104221043210442104521046210472104821049210502105121052210532105421055210562105721058210592106021061210622106321064210652106621067210682106921070210712107221073210742107521076210772107821079210802108121082210832108421085210862108721088210892109021091210922109321094210952109621097210982109921100211012110221103211042110521106211072110821109211102111121112211132111421115211162111721118211192112021121211222112321124211252112621127211282112921130211312113221133211342113521136211372113821139211402114121142211432114421145211462114721148211492115021151211522115321154211552115621157211582115921160211612116221163211642116521166211672116821169211702117121172211732117421175211762117721178211792118021181211822118321184211852118621187211882118921190211912119221193211942119521196211972119821199212002120121202212032120421205212062120721208212092121021211212122121321214212152121621217212182121921220212212122221223212242122521226212272122821229212302123121232212332123421235212362123721238212392124021241212422124321244212452124621247212482124921250212512125221253212542125521256212572125821259212602126121262212632126421265212662126721268212692127021271212722127321274212752127621277212782127921280212812128221283212842128521286212872128821289212902129121292212932129421295212962129721298212992130021301213022130321304213052130621307213082130921310213112131221313213142131521316213172131821319213202132121322213232132421325213262132721328213292133021331213322133321334213352133621337213382133921340213412134221343213442134521346213472134821349213502135121352213532135421355213562135721358213592136021361213622136321364213652136621367213682136921370213712137221373213742137521376213772137821379213802138121382213832138421385213862138721388213892139021391213922139321394213952139621397213982139921400214012140221403214042140521406214072140821409214102141121412214132141421415214162141721418214192142021421214222142321424214252142621427214282142921430214312143221433214342143521436214372143821439214402144121442214432144421445214462144721448214492145021451214522145321454214552145621457214582145921460214612146221463214642146521466214672146821469214702147121472214732147421475214762147721478214792148021481214822148321484214852148621487214882148921490214912149221493214942149521496214972149821499215002150121502215032150421505215062150721508215092151021511215122151321514215152151621517215182151921520215212152221523215242152521526215272152821529215302153121532215332153421535215362153721538215392154021541215422154321544215452154621547215482154921550215512155221553215542155521556215572155821559215602156121562215632156421565215662156721568215692157021571215722157321574215752157621577215782157921580215812158221583215842158521586215872158821589215902159121592215932159421595215962159721598215992160021601216022160321604216052160621607216082160921610216112161221613216142161521616216172161821619216202162121622216232162421625216262162721628216292163021631216322163321634216352163621637216382163921640216412164221643216442164521646216472164821649216502165121652216532165421655216562165721658216592166021661216622166321664216652166621667216682166921670216712167221673216742167521676216772167821679216802168121682216832168421685216862168721688216892169021691216922169321694216952169621697216982169921700217012170221703217042170521706217072170821709217102171121712217132171421715217162171721718217192172021721217222172321724217252172621727217282172921730217312173221733217342173521736217372173821739217402174121742217432174421745217462174721748217492175021751217522175321754217552175621757217582175921760217612176221763217642176521766217672176821769217702177121772217732177421775217762177721778217792178021781217822178321784217852178621787217882178921790217912179221793217942179521796217972179821799218002180121802218032180421805218062180721808218092181021811218122181321814218152181621817218182181921820218212182221823218242182521826218272182821829218302183121832218332183421835218362183721838218392184021841218422184321844218452184621847218482184921850218512185221853218542185521856218572185821859218602186121862218632186421865218662186721868218692187021871218722187321874218752187621877218782187921880218812188221883218842188521886218872188821889218902189121892218932189421895218962189721898218992190021901219022190321904219052190621907219082190921910219112191221913219142191521916219172191821919219202192121922219232192421925219262192721928219292193021931219322193321934219352193621937219382193921940219412194221943219442194521946219472194821949219502195121952219532195421955219562195721958219592196021961219622196321964219652196621967219682196921970219712197221973219742197521976219772197821979219802198121982219832198421985219862198721988219892199021991219922199321994219952199621997219982199922000220012200222003220042200522006220072200822009220102201122012220132201422015220162201722018220192202022021220222202322024220252202622027220282202922030220312203222033220342203522036220372203822039220402204122042220432204422045220462204722048220492205022051220522205322054220552205622057220582205922060220612206222063220642206522066220672206822069220702207122072220732207422075220762207722078220792208022081220822208322084220852208622087220882208922090220912209222093220942209522096220972209822099221002210122102221032210422105221062210722108221092211022111221122211322114221152211622117221182211922120221212212222123221242212522126221272212822129221302213122132221332213422135221362213722138221392214022141221422214322144221452214622147221482214922150221512215222153221542215522156221572215822159221602216122162221632216422165221662216722168221692217022171221722217322174221752217622177221782217922180221812218222183221842218522186221872218822189221902219122192221932219422195221962219722198221992220022201222022220322204222052220622207222082220922210222112221222213222142221522216222172221822219222202222122222222232222422225222262222722228222292223022231222322223322234222352223622237222382223922240222412224222243222442224522246222472224822249222502225122252222532225422255222562225722258222592226022261222622226322264222652226622267222682226922270222712227222273222742227522276222772227822279222802228122282222832228422285222862228722288222892229022291222922229322294222952229622297222982229922300223012230222303223042230522306223072230822309223102231122312223132231422315223162231722318223192232022321223222232322324223252232622327223282232922330223312233222333223342233522336223372233822339223402234122342223432234422345223462234722348223492235022351223522235322354223552235622357223582235922360223612236222363223642236522366223672236822369223702237122372223732237422375223762237722378223792238022381223822238322384223852238622387223882238922390223912239222393223942239522396223972239822399224002240122402224032240422405224062240722408224092241022411224122241322414224152241622417224182241922420224212242222423224242242522426224272242822429224302243122432224332243422435224362243722438224392244022441224422244322444224452244622447224482244922450224512245222453224542245522456224572245822459224602246122462224632246422465224662246722468224692247022471224722247322474224752247622477224782247922480224812248222483224842248522486224872248822489224902249122492224932249422495224962249722498224992250022501225022250322504225052250622507225082250922510225112251222513225142251522516225172251822519225202252122522225232252422525225262252722528225292253022531225322253322534225352253622537225382253922540225412254222543225442254522546225472254822549225502255122552225532255422555225562255722558225592256022561225622256322564225652256622567225682256922570225712257222573225742257522576225772257822579225802258122582225832258422585225862258722588225892259022591225922259322594225952259622597225982259922600226012260222603226042260522606226072260822609226102261122612226132261422615226162261722618226192262022621226222262322624226252262622627226282262922630226312263222633226342263522636226372263822639226402264122642226432264422645226462264722648226492265022651226522265322654226552265622657226582265922660226612266222663226642266522666226672266822669226702267122672226732267422675226762267722678226792268022681226822268322684226852268622687226882268922690226912269222693226942269522696226972269822699227002270122702227032270422705227062270722708227092271022711227122271322714227152271622717227182271922720227212272222723227242272522726227272272822729227302273122732227332273422735227362273722738227392274022741227422274322744227452274622747227482274922750227512275222753227542275522756227572275822759227602276122762227632276422765227662276722768227692277022771227722277322774227752277622777227782277922780227812278222783227842278522786227872278822789227902279122792227932279422795227962279722798227992280022801228022280322804228052280622807228082280922810228112281222813228142281522816228172281822819228202282122822228232282422825228262282722828228292283022831228322283322834228352283622837228382283922840228412284222843228442284522846228472284822849228502285122852228532285422855228562285722858228592286022861228622286322864228652286622867228682286922870228712287222873228742287522876228772287822879228802288122882228832288422885228862288722888228892289022891228922289322894228952289622897228982289922900229012290222903229042290522906229072290822909229102291122912229132291422915229162291722918229192292022921229222292322924229252292622927229282292922930229312293222933229342293522936229372293822939229402294122942229432294422945229462294722948229492295022951229522295322954229552295622957229582295922960229612296222963229642296522966229672296822969229702297122972229732297422975229762297722978229792298022981229822298322984229852298622987229882298922990229912299222993229942299522996229972299822999230002300123002230032300423005230062300723008230092301023011230122301323014230152301623017230182301923020230212302223023230242302523026230272302823029230302303123032230332303423035230362303723038230392304023041230422304323044230452304623047230482304923050230512305223053230542305523056230572305823059230602306123062230632306423065230662306723068230692307023071230722307323074230752307623077230782307923080230812308223083230842308523086230872308823089230902309123092230932309423095230962309723098230992310023101231022310323104231052310623107231082310923110231112311223113231142311523116231172311823119231202312123122231232312423125231262312723128231292313023131231322313323134231352313623137231382313923140231412314223143231442314523146231472314823149231502315123152231532315423155231562315723158231592316023161231622316323164231652316623167231682316923170231712317223173231742317523176231772317823179231802318123182231832318423185231862318723188231892319023191231922319323194231952319623197231982319923200232012320223203232042320523206232072320823209232102321123212232132321423215232162321723218232192322023221232222322323224232252322623227232282322923230232312323223233232342323523236232372323823239232402324123242232432324423245232462324723248232492325023251232522325323254232552325623257232582325923260232612326223263232642326523266232672326823269232702327123272232732327423275232762327723278232792328023281232822328323284232852328623287232882328923290232912329223293232942329523296232972329823299233002330123302233032330423305233062330723308233092331023311233122331323314233152331623317233182331923320233212332223323233242332523326233272332823329233302333123332233332333423335233362333723338233392334023341233422334323344233452334623347233482334923350233512335223353233542335523356233572335823359233602336123362233632336423365233662336723368233692337023371233722337323374233752337623377233782337923380233812338223383233842338523386233872338823389233902339123392233932339423395233962339723398233992340023401234022340323404234052340623407234082340923410234112341223413234142341523416234172341823419234202342123422234232342423425234262342723428234292343023431234322343323434234352343623437234382343923440234412344223443234442344523446234472344823449234502345123452234532345423455234562345723458234592346023461234622346323464234652346623467234682346923470234712347223473234742347523476234772347823479234802348123482234832348423485234862348723488234892349023491234922349323494234952349623497234982349923500235012350223503235042350523506235072350823509235102351123512235132351423515235162351723518235192352023521235222352323524235252352623527235282352923530235312353223533235342353523536235372353823539235402354123542235432354423545235462354723548235492355023551235522355323554235552355623557235582355923560235612356223563235642356523566235672356823569235702357123572235732357423575235762357723578235792358023581235822358323584235852358623587235882358923590235912359223593235942359523596235972359823599236002360123602236032360423605236062360723608236092361023611236122361323614236152361623617236182361923620236212362223623236242362523626236272362823629236302363123632236332363423635236362363723638236392364023641236422364323644236452364623647236482364923650236512365223653236542365523656236572365823659236602366123662236632366423665236662366723668236692367023671236722367323674236752367623677236782367923680236812368223683236842368523686236872368823689236902369123692236932369423695236962369723698236992370023701237022370323704237052370623707237082370923710237112371223713237142371523716237172371823719237202372123722237232372423725237262372723728237292373023731237322373323734237352373623737237382373923740237412374223743237442374523746237472374823749237502375123752237532375423755237562375723758237592376023761237622376323764237652376623767237682376923770237712377223773237742377523776237772377823779237802378123782237832378423785237862378723788237892379023791237922379323794237952379623797237982379923800238012380223803238042380523806238072380823809238102381123812238132381423815238162381723818238192382023821238222382323824238252382623827238282382923830238312383223833238342383523836238372383823839238402384123842238432384423845238462384723848238492385023851238522385323854238552385623857238582385923860238612386223863238642386523866238672386823869238702387123872238732387423875238762387723878238792388023881238822388323884238852388623887238882388923890238912389223893238942389523896238972389823899239002390123902239032390423905239062390723908239092391023911239122391323914239152391623917239182391923920239212392223923239242392523926239272392823929239302393123932239332393423935239362393723938239392394023941239422394323944239452394623947239482394923950239512395223953239542395523956239572395823959239602396123962239632396423965239662396723968239692397023971239722397323974239752397623977239782397923980239812398223983239842398523986239872398823989239902399123992239932399423995239962399723998239992400024001240022400324004240052400624007240082400924010240112401224013240142401524016240172401824019240202402124022240232402424025240262402724028240292403024031240322403324034240352403624037240382403924040240412404224043240442404524046240472404824049240502405124052240532405424055240562405724058240592406024061240622406324064240652406624067240682406924070240712407224073240742407524076240772407824079240802408124082240832408424085240862408724088240892409024091240922409324094240952409624097240982409924100241012410224103241042410524106241072410824109241102411124112241132411424115241162411724118241192412024121241222412324124241252412624127241282412924130241312413224133241342413524136241372413824139241402414124142241432414424145241462414724148241492415024151241522415324154241552415624157241582415924160241612416224163241642416524166241672416824169241702417124172241732417424175241762417724178241792418024181241822418324184241852418624187241882418924190241912419224193241942419524196241972419824199242002420124202242032420424205242062420724208242092421024211242122421324214242152421624217242182421924220242212422224223242242422524226242272422824229242302423124232242332423424235242362423724238242392424024241242422424324244242452424624247242482424924250242512425224253242542425524256242572425824259242602426124262242632426424265242662426724268242692427024271242722427324274242752427624277242782427924280242812428224283242842428524286242872428824289242902429124292242932429424295242962429724298242992430024301243022430324304243052430624307243082430924310243112431224313243142431524316243172431824319243202432124322243232432424325243262432724328243292433024331243322433324334243352433624337243382433924340243412434224343243442434524346243472434824349243502435124352243532435424355243562435724358243592436024361243622436324364243652436624367243682436924370243712437224373243742437524376243772437824379243802438124382243832438424385243862438724388243892439024391243922439324394243952439624397243982439924400244012440224403244042440524406244072440824409244102441124412244132441424415244162441724418244192442024421244222442324424244252442624427244282442924430244312443224433244342443524436244372443824439244402444124442244432444424445244462444724448244492445024451244522445324454244552445624457244582445924460244612446224463244642446524466244672446824469244702447124472244732447424475244762447724478244792448024481244822448324484244852448624487244882448924490244912449224493244942449524496244972449824499245002450124502245032450424505245062450724508245092451024511245122451324514245152451624517245182451924520245212452224523245242452524526245272452824529245302453124532245332453424535245362453724538245392454024541245422454324544245452454624547245482454924550245512455224553245542455524556245572455824559245602456124562245632456424565245662456724568245692457024571245722457324574245752457624577245782457924580245812458224583245842458524586245872458824589245902459124592245932459424595245962459724598245992460024601246022460324604246052460624607246082460924610246112461224613246142461524616246172461824619246202462124622246232462424625246262462724628246292463024631246322463324634246352463624637246382463924640246412464224643246442464524646246472464824649246502465124652246532465424655246562465724658246592466024661246622466324664246652466624667246682466924670246712467224673246742467524676246772467824679246802468124682246832468424685246862468724688246892469024691246922469324694246952469624697246982469924700247012470224703247042470524706247072470824709247102471124712247132471424715247162471724718247192472024721247222472324724247252472624727247282472924730247312473224733247342473524736247372473824739247402474124742247432474424745247462474724748247492475024751247522475324754247552475624757247582475924760247612476224763247642476524766247672476824769247702477124772247732477424775247762477724778247792478024781247822478324784247852478624787247882478924790247912479224793247942479524796247972479824799248002480124802248032480424805248062480724808248092481024811248122481324814248152481624817248182481924820248212482224823248242482524826248272482824829248302483124832248332483424835248362483724838248392484024841248422484324844248452484624847248482484924850248512485224853248542485524856248572485824859248602486124862248632486424865248662486724868248692487024871248722487324874248752487624877248782487924880248812488224883248842488524886248872488824889248902489124892248932489424895248962489724898248992490024901249022490324904249052490624907249082490924910249112491224913249142491524916249172491824919249202492124922249232492424925249262492724928249292493024931249322493324934249352493624937249382493924940249412494224943249442494524946249472494824949249502495124952249532495424955249562495724958249592496024961249622496324964249652496624967249682496924970249712497224973249742497524976249772497824979249802498124982249832498424985249862498724988249892499024991249922499324994249952499624997249982499925000250012500225003250042500525006250072500825009250102501125012250132501425015250162501725018250192502025021250222502325024250252502625027250282502925030250312503225033250342503525036250372503825039250402504125042250432504425045250462504725048250492505025051250522505325054250552505625057250582505925060250612506225063250642506525066250672506825069250702507125072250732507425075250762507725078250792508025081250822508325084250852508625087250882508925090250912509225093250942509525096250972509825099251002510125102251032510425105251062510725108251092511025111251122511325114251152511625117251182511925120251212512225123251242512525126251272512825129251302513125132251332513425135251362513725138251392514025141251422514325144251452514625147251482514925150251512515225153251542515525156251572515825159251602516125162251632516425165251662516725168251692517025171251722517325174251752517625177251782517925180251812518225183251842518525186251872518825189251902519125192251932519425195251962519725198251992520025201252022520325204252052520625207252082520925210252112521225213252142521525216252172521825219252202522125222252232522425225252262522725228252292523025231252322523325234252352523625237252382523925240252412524225243252442524525246252472524825249252502525125252252532525425255252562525725258252592526025261252622526325264252652526625267252682526925270252712527225273252742527525276252772527825279252802528125282252832528425285252862528725288252892529025291252922529325294252952529625297252982529925300253012530225303253042530525306253072530825309253102531125312253132531425315253162531725318253192532025321253222532325324253252532625327253282532925330253312533225333253342533525336253372533825339253402534125342253432534425345253462534725348253492535025351253522535325354253552535625357253582535925360253612536225363253642536525366253672536825369253702537125372253732537425375253762537725378253792538025381253822538325384253852538625387253882538925390253912539225393253942539525396253972539825399254002540125402254032540425405254062540725408254092541025411254122541325414254152541625417254182541925420254212542225423254242542525426254272542825429254302543125432254332543425435254362543725438254392544025441254422544325444254452544625447254482544925450254512545225453254542545525456254572545825459254602546125462254632546425465254662546725468254692547025471254722547325474254752547625477254782547925480254812548225483254842548525486254872548825489254902549125492254932549425495254962549725498254992550025501255022550325504255052550625507255082550925510255112551225513255142551525516255172551825519255202552125522255232552425525255262552725528255292553025531255322553325534255352553625537255382553925540255412554225543255442554525546255472554825549255502555125552255532555425555255562555725558255592556025561255622556325564255652556625567255682556925570255712557225573255742557525576255772557825579255802558125582255832558425585255862558725588255892559025591255922559325594255952559625597255982559925600256012560225603256042560525606256072560825609256102561125612256132561425615256162561725618256192562025621256222562325624256252562625627256282562925630256312563225633256342563525636256372563825639256402564125642256432564425645256462564725648256492565025651256522565325654256552565625657256582565925660256612566225663256642566525666256672566825669256702567125672256732567425675256762567725678256792568025681256822568325684256852568625687256882568925690256912569225693256942569525696256972569825699257002570125702257032570425705257062570725708257092571025711257122571325714257152571625717257182571925720257212572225723257242572525726257272572825729257302573125732257332573425735257362573725738257392574025741257422574325744257452574625747257482574925750257512575225753257542575525756257572575825759257602576125762257632576425765257662576725768257692577025771257722577325774257752577625777257782577925780257812578225783257842578525786257872578825789257902579125792257932579425795257962579725798257992580025801258022580325804258052580625807258082580925810258112581225813258142581525816258172581825819258202582125822258232582425825258262582725828258292583025831258322583325834258352583625837258382583925840258412584225843258442584525846258472584825849258502585125852258532585425855258562585725858258592586025861258622586325864258652586625867258682586925870258712587225873258742587525876258772587825879258802588125882258832588425885258862588725888258892589025891258922589325894258952589625897258982589925900259012590225903259042590525906259072590825909259102591125912259132591425915259162591725918259192592025921259222592325924259252592625927259282592925930259312593225933259342593525936259372593825939259402594125942259432594425945259462594725948259492595025951259522595325954259552595625957259582595925960259612596225963259642596525966259672596825969259702597125972259732597425975259762597725978259792598025981259822598325984259852598625987259882598925990259912599225993259942599525996259972599825999260002600126002260032600426005260062600726008260092601026011260122601326014260152601626017260182601926020260212602226023260242602526026260272602826029260302603126032260332603426035260362603726038260392604026041260422604326044260452604626047260482604926050260512605226053260542605526056260572605826059260602606126062260632606426065260662606726068260692607026071260722607326074260752607626077260782607926080260812608226083260842608526086260872608826089260902609126092260932609426095260962609726098260992610026101261022610326104261052610626107261082610926110261112611226113261142611526116261172611826119261202612126122261232612426125261262612726128261292613026131261322613326134261352613626137261382613926140261412614226143261442614526146261472614826149261502615126152261532615426155261562615726158261592616026161261622616326164261652616626167261682616926170261712617226173261742617526176261772617826179261802618126182261832618426185261862618726188261892619026191261922619326194261952619626197261982619926200262012620226203262042620526206262072620826209262102621126212262132621426215262162621726218262192622026221262222622326224262252622626227262282622926230262312623226233262342623526236262372623826239262402624126242262432624426245262462624726248262492625026251262522625326254262552625626257262582625926260262612626226263262642626526266262672626826269262702627126272262732627426275262762627726278262792628026281262822628326284262852628626287262882628926290262912629226293262942629526296262972629826299263002630126302263032630426305263062630726308263092631026311263122631326314263152631626317263182631926320263212632226323263242632526326263272632826329263302633126332263332633426335263362633726338263392634026341263422634326344263452634626347263482634926350263512635226353263542635526356263572635826359263602636126362263632636426365263662636726368263692637026371263722637326374263752637626377263782637926380263812638226383263842638526386263872638826389263902639126392263932639426395263962639726398263992640026401264022640326404264052640626407264082640926410264112641226413264142641526416264172641826419264202642126422264232642426425264262642726428264292643026431264322643326434264352643626437264382643926440264412644226443264442644526446264472644826449264502645126452264532645426455264562645726458264592646026461264622646326464264652646626467264682646926470264712647226473264742647526476264772647826479264802648126482264832648426485264862648726488264892649026491264922649326494264952649626497264982649926500265012650226503265042650526506265072650826509265102651126512265132651426515265162651726518265192652026521265222652326524265252652626527265282652926530265312653226533265342653526536265372653826539265402654126542265432654426545265462654726548265492655026551265522655326554265552655626557265582655926560265612656226563265642656526566265672656826569265702657126572265732657426575265762657726578265792658026581265822658326584265852658626587265882658926590265912659226593265942659526596265972659826599266002660126602266032660426605266062660726608266092661026611266122661326614266152661626617266182661926620266212662226623266242662526626266272662826629266302663126632266332663426635266362663726638266392664026641266422664326644266452664626647266482664926650266512665226653266542665526656266572665826659266602666126662266632666426665266662666726668266692667026671266722667326674266752667626677266782667926680266812668226683266842668526686266872668826689266902669126692266932669426695266962669726698266992670026701267022670326704267052670626707267082670926710267112671226713267142671526716267172671826719267202672126722267232672426725267262672726728267292673026731267322673326734267352673626737267382673926740267412674226743267442674526746267472674826749267502675126752267532675426755267562675726758267592676026761267622676326764267652676626767267682676926770267712677226773267742677526776267772677826779267802678126782267832678426785267862678726788267892679026791267922679326794267952679626797267982679926800268012680226803268042680526806268072680826809268102681126812268132681426815268162681726818268192682026821268222682326824268252682626827268282682926830268312683226833268342683526836268372683826839268402684126842268432684426845268462684726848268492685026851268522685326854268552685626857268582685926860268612686226863268642686526866268672686826869268702687126872268732687426875268762687726878268792688026881268822688326884268852688626887268882688926890268912689226893268942689526896268972689826899269002690126902269032690426905269062690726908269092691026911269122691326914269152691626917269182691926920269212692226923269242692526926269272692826929269302693126932269332693426935269362693726938269392694026941269422694326944269452694626947269482694926950269512695226953269542695526956269572695826959269602696126962269632696426965269662696726968269692697026971269722697326974269752697626977269782697926980269812698226983269842698526986269872698826989269902699126992269932699426995269962699726998269992700027001270022700327004270052700627007270082700927010270112701227013270142701527016270172701827019270202702127022270232702427025270262702727028270292703027031270322703327034270352703627037270382703927040270412704227043270442704527046270472704827049270502705127052270532705427055270562705727058270592706027061270622706327064270652706627067270682706927070270712707227073270742707527076270772707827079270802708127082270832708427085270862708727088270892709027091270922709327094270952709627097270982709927100271012710227103271042710527106271072710827109271102711127112271132711427115271162711727118271192712027121271222712327124271252712627127271282712927130271312713227133271342713527136271372713827139271402714127142271432714427145271462714727148271492715027151271522715327154271552715627157271582715927160271612716227163271642716527166271672716827169271702717127172271732717427175271762717727178271792718027181271822718327184271852718627187271882718927190271912719227193271942719527196271972719827199272002720127202272032720427205272062720727208272092721027211272122721327214272152721627217272182721927220272212722227223272242722527226272272722827229272302723127232272332723427235272362723727238272392724027241272422724327244272452724627247272482724927250272512725227253272542725527256272572725827259272602726127262272632726427265272662726727268272692727027271272722727327274272752727627277272782727927280272812728227283272842728527286272872728827289272902729127292272932729427295272962729727298272992730027301273022730327304273052730627307273082730927310273112731227313273142731527316273172731827319273202732127322273232732427325273262732727328273292733027331273322733327334273352733627337273382733927340273412734227343273442734527346273472734827349273502735127352273532735427355273562735727358273592736027361273622736327364273652736627367273682736927370273712737227373273742737527376273772737827379273802738127382273832738427385273862738727388273892739027391273922739327394273952739627397273982739927400274012740227403274042740527406274072740827409274102741127412274132741427415274162741727418274192742027421274222742327424274252742627427274282742927430274312743227433274342743527436274372743827439274402744127442274432744427445274462744727448274492745027451274522745327454274552745627457274582745927460274612746227463274642746527466274672746827469274702747127472274732747427475274762747727478274792748027481274822748327484274852748627487274882748927490274912749227493274942749527496274972749827499275002750127502275032750427505275062750727508275092751027511275122751327514275152751627517275182751927520275212752227523275242752527526275272752827529275302753127532275332753427535275362753727538275392754027541275422754327544275452754627547275482754927550275512755227553275542755527556275572755827559275602756127562275632756427565275662756727568275692757027571275722757327574275752757627577275782757927580275812758227583275842758527586275872758827589275902759127592275932759427595275962759727598275992760027601276022760327604276052760627607276082760927610276112761227613276142761527616276172761827619276202762127622276232762427625276262762727628276292763027631276322763327634276352763627637276382763927640276412764227643276442764527646276472764827649276502765127652276532765427655276562765727658276592766027661276622766327664276652766627667276682766927670276712767227673276742767527676276772767827679276802768127682276832768427685276862768727688276892769027691276922769327694276952769627697276982769927700277012770227703277042770527706277072770827709277102771127712277132771427715277162771727718277192772027721277222772327724277252772627727277282772927730277312773227733277342773527736277372773827739277402774127742277432774427745277462774727748277492775027751277522775327754277552775627757277582775927760277612776227763277642776527766277672776827769277702777127772277732777427775277762777727778277792778027781277822778327784277852778627787277882778927790277912779227793277942779527796277972779827799278002780127802278032780427805278062780727808278092781027811278122781327814278152781627817278182781927820278212782227823278242782527826278272782827829278302783127832278332783427835278362783727838278392784027841278422784327844278452784627847278482784927850278512785227853278542785527856278572785827859278602786127862278632786427865278662786727868278692787027871278722787327874278752787627877278782787927880278812788227883278842788527886278872788827889278902789127892278932789427895278962789727898278992790027901279022790327904279052790627907279082790927910279112791227913279142791527916279172791827919279202792127922279232792427925279262792727928279292793027931279322793327934279352793627937279382793927940279412794227943279442794527946279472794827949279502795127952279532795427955279562795727958279592796027961279622796327964279652796627967279682796927970279712797227973279742797527976279772797827979279802798127982279832798427985279862798727988279892799027991279922799327994279952799627997279982799928000280012800228003280042800528006280072800828009280102801128012280132801428015280162801728018280192802028021280222802328024280252802628027280282802928030280312803228033280342803528036280372803828039280402804128042280432804428045280462804728048280492805028051280522805328054280552805628057280582805928060280612806228063280642806528066280672806828069280702807128072280732807428075280762807728078280792808028081280822808328084280852808628087280882808928090280912809228093280942809528096280972809828099281002810128102281032810428105281062810728108281092811028111281122811328114281152811628117281182811928120281212812228123281242812528126281272812828129281302813128132281332813428135281362813728138281392814028141281422814328144281452814628147281482814928150281512815228153281542815528156281572815828159281602816128162281632816428165281662816728168281692817028171281722817328174281752817628177281782817928180281812818228183281842818528186281872818828189281902819128192281932819428195281962819728198281992820028201282022820328204282052820628207282082820928210282112821228213282142821528216282172821828219282202822128222282232822428225282262822728228282292823028231282322823328234282352823628237282382823928240282412824228243282442824528246282472824828249282502825128252282532825428255282562825728258282592826028261282622826328264282652826628267282682826928270282712827228273282742827528276282772827828279282802828128282282832828428285282862828728288282892829028291282922829328294282952829628297282982829928300283012830228303283042830528306283072830828309283102831128312283132831428315283162831728318283192832028321283222832328324283252832628327283282832928330283312833228333283342833528336283372833828339283402834128342283432834428345283462834728348283492835028351283522835328354283552835628357283582835928360283612836228363283642836528366283672836828369283702837128372283732837428375283762837728378283792838028381283822838328384283852838628387283882838928390283912839228393283942839528396283972839828399284002840128402284032840428405284062840728408284092841028411284122841328414284152841628417284182841928420284212842228423284242842528426284272842828429284302843128432284332843428435284362843728438284392844028441284422844328444284452844628447284482844928450284512845228453284542845528456284572845828459284602846128462284632846428465284662846728468284692847028471284722847328474284752847628477284782847928480284812848228483284842848528486284872848828489284902849128492284932849428495284962849728498284992850028501285022850328504285052850628507285082850928510285112851228513285142851528516285172851828519285202852128522285232852428525285262852728528285292853028531285322853328534285352853628537285382853928540285412854228543285442854528546285472854828549285502855128552285532855428555285562855728558285592856028561285622856328564285652856628567285682856928570285712857228573285742857528576285772857828579285802858128582285832858428585285862858728588285892859028591285922859328594285952859628597285982859928600286012860228603286042860528606286072860828609286102861128612286132861428615286162861728618286192862028621286222862328624286252862628627286282862928630286312863228633286342863528636286372863828639286402864128642286432864428645286462864728648286492865028651286522865328654286552865628657286582865928660286612866228663286642866528666286672866828669286702867128672286732867428675286762867728678286792868028681286822868328684286852868628687286882868928690286912869228693286942869528696286972869828699287002870128702287032870428705287062870728708287092871028711287122871328714287152871628717287182871928720287212872228723287242872528726287272872828729287302873128732287332873428735287362873728738287392874028741287422874328744
  1. /* Generated by Cython 0.29.14 */
  2. #define PY_SSIZE_T_CLEAN
  3. #include "Python.h"
  4. #ifndef Py_PYTHON_H
  5. #error Python headers needed to compile C extensions, please install development version of Python.
  6. #elif PY_VERSION_HEX < 0x02060000 || (0x03000000 <= PY_VERSION_HEX && PY_VERSION_HEX < 0x03030000)
  7. #error Cython requires Python 2.6+ or Python 3.3+.
  8. #else
  9. #define CYTHON_ABI "0_29_14"
  10. #define CYTHON_HEX_VERSION 0x001D0EF0
  11. #define CYTHON_FUTURE_DIVISION 0
  12. #include <stddef.h>
  13. #ifndef offsetof
  14. #define offsetof(type, member) ( (size_t) & ((type*)0) -> member )
  15. #endif
  16. #if !defined(WIN32) && !defined(MS_WINDOWS)
  17. #ifndef __stdcall
  18. #define __stdcall
  19. #endif
  20. #ifndef __cdecl
  21. #define __cdecl
  22. #endif
  23. #ifndef __fastcall
  24. #define __fastcall
  25. #endif
  26. #endif
  27. #ifndef DL_IMPORT
  28. #define DL_IMPORT(t) t
  29. #endif
  30. #ifndef DL_EXPORT
  31. #define DL_EXPORT(t) t
  32. #endif
  33. #define __PYX_COMMA ,
  34. #ifndef HAVE_LONG_LONG
  35. #if PY_VERSION_HEX >= 0x02070000
  36. #define HAVE_LONG_LONG
  37. #endif
  38. #endif
  39. #ifndef PY_LONG_LONG
  40. #define PY_LONG_LONG LONG_LONG
  41. #endif
  42. #ifndef Py_HUGE_VAL
  43. #define Py_HUGE_VAL HUGE_VAL
  44. #endif
  45. #ifdef PYPY_VERSION
  46. #define CYTHON_COMPILING_IN_PYPY 1
  47. #define CYTHON_COMPILING_IN_PYSTON 0
  48. #define CYTHON_COMPILING_IN_CPYTHON 0
  49. #undef CYTHON_USE_TYPE_SLOTS
  50. #define CYTHON_USE_TYPE_SLOTS 0
  51. #undef CYTHON_USE_PYTYPE_LOOKUP
  52. #define CYTHON_USE_PYTYPE_LOOKUP 0
  53. #if PY_VERSION_HEX < 0x03050000
  54. #undef CYTHON_USE_ASYNC_SLOTS
  55. #define CYTHON_USE_ASYNC_SLOTS 0
  56. #elif !defined(CYTHON_USE_ASYNC_SLOTS)
  57. #define CYTHON_USE_ASYNC_SLOTS 1
  58. #endif
  59. #undef CYTHON_USE_PYLIST_INTERNALS
  60. #define CYTHON_USE_PYLIST_INTERNALS 0
  61. #undef CYTHON_USE_UNICODE_INTERNALS
  62. #define CYTHON_USE_UNICODE_INTERNALS 0
  63. #undef CYTHON_USE_UNICODE_WRITER
  64. #define CYTHON_USE_UNICODE_WRITER 0
  65. #undef CYTHON_USE_PYLONG_INTERNALS
  66. #define CYTHON_USE_PYLONG_INTERNALS 0
  67. #undef CYTHON_AVOID_BORROWED_REFS
  68. #define CYTHON_AVOID_BORROWED_REFS 1
  69. #undef CYTHON_ASSUME_SAFE_MACROS
  70. #define CYTHON_ASSUME_SAFE_MACROS 0
  71. #undef CYTHON_UNPACK_METHODS
  72. #define CYTHON_UNPACK_METHODS 0
  73. #undef CYTHON_FAST_THREAD_STATE
  74. #define CYTHON_FAST_THREAD_STATE 0
  75. #undef CYTHON_FAST_PYCALL
  76. #define CYTHON_FAST_PYCALL 0
  77. #undef CYTHON_PEP489_MULTI_PHASE_INIT
  78. #define CYTHON_PEP489_MULTI_PHASE_INIT 0
  79. #undef CYTHON_USE_TP_FINALIZE
  80. #define CYTHON_USE_TP_FINALIZE 0
  81. #undef CYTHON_USE_DICT_VERSIONS
  82. #define CYTHON_USE_DICT_VERSIONS 0
  83. #undef CYTHON_USE_EXC_INFO_STACK
  84. #define CYTHON_USE_EXC_INFO_STACK 0
  85. #elif defined(PYSTON_VERSION)
  86. #define CYTHON_COMPILING_IN_PYPY 0
  87. #define CYTHON_COMPILING_IN_PYSTON 1
  88. #define CYTHON_COMPILING_IN_CPYTHON 0
  89. #ifndef CYTHON_USE_TYPE_SLOTS
  90. #define CYTHON_USE_TYPE_SLOTS 1
  91. #endif
  92. #undef CYTHON_USE_PYTYPE_LOOKUP
  93. #define CYTHON_USE_PYTYPE_LOOKUP 0
  94. #undef CYTHON_USE_ASYNC_SLOTS
  95. #define CYTHON_USE_ASYNC_SLOTS 0
  96. #undef CYTHON_USE_PYLIST_INTERNALS
  97. #define CYTHON_USE_PYLIST_INTERNALS 0
  98. #ifndef CYTHON_USE_UNICODE_INTERNALS
  99. #define CYTHON_USE_UNICODE_INTERNALS 1
  100. #endif
  101. #undef CYTHON_USE_UNICODE_WRITER
  102. #define CYTHON_USE_UNICODE_WRITER 0
  103. #undef CYTHON_USE_PYLONG_INTERNALS
  104. #define CYTHON_USE_PYLONG_INTERNALS 0
  105. #ifndef CYTHON_AVOID_BORROWED_REFS
  106. #define CYTHON_AVOID_BORROWED_REFS 0
  107. #endif
  108. #ifndef CYTHON_ASSUME_SAFE_MACROS
  109. #define CYTHON_ASSUME_SAFE_MACROS 1
  110. #endif
  111. #ifndef CYTHON_UNPACK_METHODS
  112. #define CYTHON_UNPACK_METHODS 1
  113. #endif
  114. #undef CYTHON_FAST_THREAD_STATE
  115. #define CYTHON_FAST_THREAD_STATE 0
  116. #undef CYTHON_FAST_PYCALL
  117. #define CYTHON_FAST_PYCALL 0
  118. #undef CYTHON_PEP489_MULTI_PHASE_INIT
  119. #define CYTHON_PEP489_MULTI_PHASE_INIT 0
  120. #undef CYTHON_USE_TP_FINALIZE
  121. #define CYTHON_USE_TP_FINALIZE 0
  122. #undef CYTHON_USE_DICT_VERSIONS
  123. #define CYTHON_USE_DICT_VERSIONS 0
  124. #undef CYTHON_USE_EXC_INFO_STACK
  125. #define CYTHON_USE_EXC_INFO_STACK 0
  126. #else
  127. #define CYTHON_COMPILING_IN_PYPY 0
  128. #define CYTHON_COMPILING_IN_PYSTON 0
  129. #define CYTHON_COMPILING_IN_CPYTHON 1
  130. #ifndef CYTHON_USE_TYPE_SLOTS
  131. #define CYTHON_USE_TYPE_SLOTS 1
  132. #endif
  133. #if PY_VERSION_HEX < 0x02070000
  134. #undef CYTHON_USE_PYTYPE_LOOKUP
  135. #define CYTHON_USE_PYTYPE_LOOKUP 0
  136. #elif !defined(CYTHON_USE_PYTYPE_LOOKUP)
  137. #define CYTHON_USE_PYTYPE_LOOKUP 1
  138. #endif
  139. #if PY_MAJOR_VERSION < 3
  140. #undef CYTHON_USE_ASYNC_SLOTS
  141. #define CYTHON_USE_ASYNC_SLOTS 0
  142. #elif !defined(CYTHON_USE_ASYNC_SLOTS)
  143. #define CYTHON_USE_ASYNC_SLOTS 1
  144. #endif
  145. #if PY_VERSION_HEX < 0x02070000
  146. #undef CYTHON_USE_PYLONG_INTERNALS
  147. #define CYTHON_USE_PYLONG_INTERNALS 0
  148. #elif !defined(CYTHON_USE_PYLONG_INTERNALS)
  149. #define CYTHON_USE_PYLONG_INTERNALS 1
  150. #endif
  151. #ifndef CYTHON_USE_PYLIST_INTERNALS
  152. #define CYTHON_USE_PYLIST_INTERNALS 1
  153. #endif
  154. #ifndef CYTHON_USE_UNICODE_INTERNALS
  155. #define CYTHON_USE_UNICODE_INTERNALS 1
  156. #endif
  157. #if PY_VERSION_HEX < 0x030300F0
  158. #undef CYTHON_USE_UNICODE_WRITER
  159. #define CYTHON_USE_UNICODE_WRITER 0
  160. #elif !defined(CYTHON_USE_UNICODE_WRITER)
  161. #define CYTHON_USE_UNICODE_WRITER 1
  162. #endif
  163. #ifndef CYTHON_AVOID_BORROWED_REFS
  164. #define CYTHON_AVOID_BORROWED_REFS 0
  165. #endif
  166. #ifndef CYTHON_ASSUME_SAFE_MACROS
  167. #define CYTHON_ASSUME_SAFE_MACROS 1
  168. #endif
  169. #ifndef CYTHON_UNPACK_METHODS
  170. #define CYTHON_UNPACK_METHODS 1
  171. #endif
  172. #ifndef CYTHON_FAST_THREAD_STATE
  173. #define CYTHON_FAST_THREAD_STATE 1
  174. #endif
  175. #ifndef CYTHON_FAST_PYCALL
  176. #define CYTHON_FAST_PYCALL 1
  177. #endif
  178. #ifndef CYTHON_PEP489_MULTI_PHASE_INIT
  179. #define CYTHON_PEP489_MULTI_PHASE_INIT (PY_VERSION_HEX >= 0x03050000)
  180. #endif
  181. #ifndef CYTHON_USE_TP_FINALIZE
  182. #define CYTHON_USE_TP_FINALIZE (PY_VERSION_HEX >= 0x030400a1)
  183. #endif
  184. #ifndef CYTHON_USE_DICT_VERSIONS
  185. #define CYTHON_USE_DICT_VERSIONS (PY_VERSION_HEX >= 0x030600B1)
  186. #endif
  187. #ifndef CYTHON_USE_EXC_INFO_STACK
  188. #define CYTHON_USE_EXC_INFO_STACK (PY_VERSION_HEX >= 0x030700A3)
  189. #endif
  190. #endif
  191. #if !defined(CYTHON_FAST_PYCCALL)
  192. #define CYTHON_FAST_PYCCALL (CYTHON_FAST_PYCALL && PY_VERSION_HEX >= 0x030600B1)
  193. #endif
  194. #if CYTHON_USE_PYLONG_INTERNALS
  195. #include "longintrepr.h"
  196. #undef SHIFT
  197. #undef BASE
  198. #undef MASK
  199. #ifdef SIZEOF_VOID_P
  200. enum { __pyx_check_sizeof_voidp = 1 / (int)(SIZEOF_VOID_P == sizeof(void*)) };
  201. #endif
  202. #endif
  203. #ifndef __has_attribute
  204. #define __has_attribute(x) 0
  205. #endif
  206. #ifndef __has_cpp_attribute
  207. #define __has_cpp_attribute(x) 0
  208. #endif
  209. #ifndef CYTHON_RESTRICT
  210. #if defined(__GNUC__)
  211. #define CYTHON_RESTRICT __restrict__
  212. #elif defined(_MSC_VER) && _MSC_VER >= 1400
  213. #define CYTHON_RESTRICT __restrict
  214. #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
  215. #define CYTHON_RESTRICT restrict
  216. #else
  217. #define CYTHON_RESTRICT
  218. #endif
  219. #endif
  220. #ifndef CYTHON_UNUSED
  221. # if defined(__GNUC__)
  222. # if !(defined(__cplusplus)) || (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4))
  223. # define CYTHON_UNUSED __attribute__ ((__unused__))
  224. # else
  225. # define CYTHON_UNUSED
  226. # endif
  227. # elif defined(__ICC) || (defined(__INTEL_COMPILER) && !defined(_MSC_VER))
  228. # define CYTHON_UNUSED __attribute__ ((__unused__))
  229. # else
  230. # define CYTHON_UNUSED
  231. # endif
  232. #endif
  233. #ifndef CYTHON_MAYBE_UNUSED_VAR
  234. # if defined(__cplusplus)
  235. template<class T> void CYTHON_MAYBE_UNUSED_VAR( const T& ) { }
  236. # else
  237. # define CYTHON_MAYBE_UNUSED_VAR(x) (void)(x)
  238. # endif
  239. #endif
  240. #ifndef CYTHON_NCP_UNUSED
  241. # if CYTHON_COMPILING_IN_CPYTHON
  242. # define CYTHON_NCP_UNUSED
  243. # else
  244. # define CYTHON_NCP_UNUSED CYTHON_UNUSED
  245. # endif
  246. #endif
  247. #define __Pyx_void_to_None(void_result) ((void)(void_result), Py_INCREF(Py_None), Py_None)
  248. #ifdef _MSC_VER
  249. #ifndef _MSC_STDINT_H_
  250. #if _MSC_VER < 1300
  251. typedef unsigned char uint8_t;
  252. typedef unsigned int uint32_t;
  253. #else
  254. typedef unsigned __int8 uint8_t;
  255. typedef unsigned __int32 uint32_t;
  256. #endif
  257. #endif
  258. #else
  259. #include <stdint.h>
  260. #endif
  261. #ifndef CYTHON_FALLTHROUGH
  262. #if defined(__cplusplus) && __cplusplus >= 201103L
  263. #if __has_cpp_attribute(fallthrough)
  264. #define CYTHON_FALLTHROUGH [[fallthrough]]
  265. #elif __has_cpp_attribute(clang::fallthrough)
  266. #define CYTHON_FALLTHROUGH [[clang::fallthrough]]
  267. #elif __has_cpp_attribute(gnu::fallthrough)
  268. #define CYTHON_FALLTHROUGH [[gnu::fallthrough]]
  269. #endif
  270. #endif
  271. #ifndef CYTHON_FALLTHROUGH
  272. #if __has_attribute(fallthrough)
  273. #define CYTHON_FALLTHROUGH __attribute__((fallthrough))
  274. #else
  275. #define CYTHON_FALLTHROUGH
  276. #endif
  277. #endif
  278. #if defined(__clang__ ) && defined(__apple_build_version__)
  279. #if __apple_build_version__ < 7000000
  280. #undef CYTHON_FALLTHROUGH
  281. #define CYTHON_FALLTHROUGH
  282. #endif
  283. #endif
  284. #endif
  285. #ifndef CYTHON_INLINE
  286. #if defined(__clang__)
  287. #define CYTHON_INLINE __inline__ __attribute__ ((__unused__))
  288. #elif defined(__GNUC__)
  289. #define CYTHON_INLINE __inline__
  290. #elif defined(_MSC_VER)
  291. #define CYTHON_INLINE __inline
  292. #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
  293. #define CYTHON_INLINE inline
  294. #else
  295. #define CYTHON_INLINE
  296. #endif
  297. #endif
  298. #if CYTHON_COMPILING_IN_PYPY && PY_VERSION_HEX < 0x02070600 && !defined(Py_OptimizeFlag)
  299. #define Py_OptimizeFlag 0
  300. #endif
  301. #define __PYX_BUILD_PY_SSIZE_T "n"
  302. #define CYTHON_FORMAT_SSIZE_T "z"
  303. #if PY_MAJOR_VERSION < 3
  304. #define __Pyx_BUILTIN_MODULE_NAME "__builtin__"
  305. #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\
  306. PyCode_New(a+k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
  307. #define __Pyx_DefaultClassType PyClass_Type
  308. #else
  309. #define __Pyx_BUILTIN_MODULE_NAME "builtins"
  310. #if PY_VERSION_HEX >= 0x030800A4 && PY_VERSION_HEX < 0x030800B2
  311. #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\
  312. PyCode_New(a, 0, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
  313. #else
  314. #define __Pyx_PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)\
  315. PyCode_New(a, k, l, s, f, code, c, n, v, fv, cell, fn, name, fline, lnos)
  316. #endif
  317. #define __Pyx_DefaultClassType PyType_Type
  318. #endif
  319. #ifndef Py_TPFLAGS_CHECKTYPES
  320. #define Py_TPFLAGS_CHECKTYPES 0
  321. #endif
  322. #ifndef Py_TPFLAGS_HAVE_INDEX
  323. #define Py_TPFLAGS_HAVE_INDEX 0
  324. #endif
  325. #ifndef Py_TPFLAGS_HAVE_NEWBUFFER
  326. #define Py_TPFLAGS_HAVE_NEWBUFFER 0
  327. #endif
  328. #ifndef Py_TPFLAGS_HAVE_FINALIZE
  329. #define Py_TPFLAGS_HAVE_FINALIZE 0
  330. #endif
  331. #ifndef METH_STACKLESS
  332. #define METH_STACKLESS 0
  333. #endif
  334. #if PY_VERSION_HEX <= 0x030700A3 || !defined(METH_FASTCALL)
  335. #ifndef METH_FASTCALL
  336. #define METH_FASTCALL 0x80
  337. #endif
  338. typedef PyObject *(*__Pyx_PyCFunctionFast) (PyObject *self, PyObject *const *args, Py_ssize_t nargs);
  339. typedef PyObject *(*__Pyx_PyCFunctionFastWithKeywords) (PyObject *self, PyObject *const *args,
  340. Py_ssize_t nargs, PyObject *kwnames);
  341. #else
  342. #define __Pyx_PyCFunctionFast _PyCFunctionFast
  343. #define __Pyx_PyCFunctionFastWithKeywords _PyCFunctionFastWithKeywords
  344. #endif
  345. #if CYTHON_FAST_PYCCALL
  346. #define __Pyx_PyFastCFunction_Check(func)\
  347. ((PyCFunction_Check(func) && (METH_FASTCALL == (PyCFunction_GET_FLAGS(func) & ~(METH_CLASS | METH_STATIC | METH_COEXIST | METH_KEYWORDS | METH_STACKLESS)))))
  348. #else
  349. #define __Pyx_PyFastCFunction_Check(func) 0
  350. #endif
  351. #if CYTHON_COMPILING_IN_PYPY && !defined(PyObject_Malloc)
  352. #define PyObject_Malloc(s) PyMem_Malloc(s)
  353. #define PyObject_Free(p) PyMem_Free(p)
  354. #define PyObject_Realloc(p) PyMem_Realloc(p)
  355. #endif
  356. #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX < 0x030400A1
  357. #define PyMem_RawMalloc(n) PyMem_Malloc(n)
  358. #define PyMem_RawRealloc(p, n) PyMem_Realloc(p, n)
  359. #define PyMem_RawFree(p) PyMem_Free(p)
  360. #endif
  361. #if CYTHON_COMPILING_IN_PYSTON
  362. #define __Pyx_PyCode_HasFreeVars(co) PyCode_HasFreeVars(co)
  363. #define __Pyx_PyFrame_SetLineNumber(frame, lineno) PyFrame_SetLineNumber(frame, lineno)
  364. #else
  365. #define __Pyx_PyCode_HasFreeVars(co) (PyCode_GetNumFree(co) > 0)
  366. #define __Pyx_PyFrame_SetLineNumber(frame, lineno) (frame)->f_lineno = (lineno)
  367. #endif
  368. #if !CYTHON_FAST_THREAD_STATE || PY_VERSION_HEX < 0x02070000
  369. #define __Pyx_PyThreadState_Current PyThreadState_GET()
  370. #elif PY_VERSION_HEX >= 0x03060000
  371. #define __Pyx_PyThreadState_Current _PyThreadState_UncheckedGet()
  372. #elif PY_VERSION_HEX >= 0x03000000
  373. #define __Pyx_PyThreadState_Current PyThreadState_GET()
  374. #else
  375. #define __Pyx_PyThreadState_Current _PyThreadState_Current
  376. #endif
  377. #if PY_VERSION_HEX < 0x030700A2 && !defined(PyThread_tss_create) && !defined(Py_tss_NEEDS_INIT)
  378. #include "pythread.h"
  379. #define Py_tss_NEEDS_INIT 0
  380. typedef int Py_tss_t;
  381. static CYTHON_INLINE int PyThread_tss_create(Py_tss_t *key) {
  382. *key = PyThread_create_key();
  383. return 0;
  384. }
  385. static CYTHON_INLINE Py_tss_t * PyThread_tss_alloc(void) {
  386. Py_tss_t *key = (Py_tss_t *)PyObject_Malloc(sizeof(Py_tss_t));
  387. *key = Py_tss_NEEDS_INIT;
  388. return key;
  389. }
  390. static CYTHON_INLINE void PyThread_tss_free(Py_tss_t *key) {
  391. PyObject_Free(key);
  392. }
  393. static CYTHON_INLINE int PyThread_tss_is_created(Py_tss_t *key) {
  394. return *key != Py_tss_NEEDS_INIT;
  395. }
  396. static CYTHON_INLINE void PyThread_tss_delete(Py_tss_t *key) {
  397. PyThread_delete_key(*key);
  398. *key = Py_tss_NEEDS_INIT;
  399. }
  400. static CYTHON_INLINE int PyThread_tss_set(Py_tss_t *key, void *value) {
  401. return PyThread_set_key_value(*key, value);
  402. }
  403. static CYTHON_INLINE void * PyThread_tss_get(Py_tss_t *key) {
  404. return PyThread_get_key_value(*key);
  405. }
  406. #endif
  407. #if CYTHON_COMPILING_IN_CPYTHON || defined(_PyDict_NewPresized)
  408. #define __Pyx_PyDict_NewPresized(n) ((n <= 8) ? PyDict_New() : _PyDict_NewPresized(n))
  409. #else
  410. #define __Pyx_PyDict_NewPresized(n) PyDict_New()
  411. #endif
  412. #if PY_MAJOR_VERSION >= 3 || CYTHON_FUTURE_DIVISION
  413. #define __Pyx_PyNumber_Divide(x,y) PyNumber_TrueDivide(x,y)
  414. #define __Pyx_PyNumber_InPlaceDivide(x,y) PyNumber_InPlaceTrueDivide(x,y)
  415. #else
  416. #define __Pyx_PyNumber_Divide(x,y) PyNumber_Divide(x,y)
  417. #define __Pyx_PyNumber_InPlaceDivide(x,y) PyNumber_InPlaceDivide(x,y)
  418. #endif
  419. #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030500A1 && CYTHON_USE_UNICODE_INTERNALS
  420. #define __Pyx_PyDict_GetItemStr(dict, name) _PyDict_GetItem_KnownHash(dict, name, ((PyASCIIObject *) name)->hash)
  421. #else
  422. #define __Pyx_PyDict_GetItemStr(dict, name) PyDict_GetItem(dict, name)
  423. #endif
  424. #if PY_VERSION_HEX > 0x03030000 && defined(PyUnicode_KIND)
  425. #define CYTHON_PEP393_ENABLED 1
  426. #define __Pyx_PyUnicode_READY(op) (likely(PyUnicode_IS_READY(op)) ?\
  427. 0 : _PyUnicode_Ready((PyObject *)(op)))
  428. #define __Pyx_PyUnicode_GET_LENGTH(u) PyUnicode_GET_LENGTH(u)
  429. #define __Pyx_PyUnicode_READ_CHAR(u, i) PyUnicode_READ_CHAR(u, i)
  430. #define __Pyx_PyUnicode_MAX_CHAR_VALUE(u) PyUnicode_MAX_CHAR_VALUE(u)
  431. #define __Pyx_PyUnicode_KIND(u) PyUnicode_KIND(u)
  432. #define __Pyx_PyUnicode_DATA(u) PyUnicode_DATA(u)
  433. #define __Pyx_PyUnicode_READ(k, d, i) PyUnicode_READ(k, d, i)
  434. #define __Pyx_PyUnicode_WRITE(k, d, i, ch) PyUnicode_WRITE(k, d, i, ch)
  435. #define __Pyx_PyUnicode_IS_TRUE(u) (0 != (likely(PyUnicode_IS_READY(u)) ? PyUnicode_GET_LENGTH(u) : PyUnicode_GET_SIZE(u)))
  436. #else
  437. #define CYTHON_PEP393_ENABLED 0
  438. #define PyUnicode_1BYTE_KIND 1
  439. #define PyUnicode_2BYTE_KIND 2
  440. #define PyUnicode_4BYTE_KIND 4
  441. #define __Pyx_PyUnicode_READY(op) (0)
  442. #define __Pyx_PyUnicode_GET_LENGTH(u) PyUnicode_GET_SIZE(u)
  443. #define __Pyx_PyUnicode_READ_CHAR(u, i) ((Py_UCS4)(PyUnicode_AS_UNICODE(u)[i]))
  444. #define __Pyx_PyUnicode_MAX_CHAR_VALUE(u) ((sizeof(Py_UNICODE) == 2) ? 65535 : 1114111)
  445. #define __Pyx_PyUnicode_KIND(u) (sizeof(Py_UNICODE))
  446. #define __Pyx_PyUnicode_DATA(u) ((void*)PyUnicode_AS_UNICODE(u))
  447. #define __Pyx_PyUnicode_READ(k, d, i) ((void)(k), (Py_UCS4)(((Py_UNICODE*)d)[i]))
  448. #define __Pyx_PyUnicode_WRITE(k, d, i, ch) (((void)(k)), ((Py_UNICODE*)d)[i] = ch)
  449. #define __Pyx_PyUnicode_IS_TRUE(u) (0 != PyUnicode_GET_SIZE(u))
  450. #endif
  451. #if CYTHON_COMPILING_IN_PYPY
  452. #define __Pyx_PyUnicode_Concat(a, b) PyNumber_Add(a, b)
  453. #define __Pyx_PyUnicode_ConcatSafe(a, b) PyNumber_Add(a, b)
  454. #else
  455. #define __Pyx_PyUnicode_Concat(a, b) PyUnicode_Concat(a, b)
  456. #define __Pyx_PyUnicode_ConcatSafe(a, b) ((unlikely((a) == Py_None) || unlikely((b) == Py_None)) ?\
  457. PyNumber_Add(a, b) : __Pyx_PyUnicode_Concat(a, b))
  458. #endif
  459. #if CYTHON_COMPILING_IN_PYPY && !defined(PyUnicode_Contains)
  460. #define PyUnicode_Contains(u, s) PySequence_Contains(u, s)
  461. #endif
  462. #if CYTHON_COMPILING_IN_PYPY && !defined(PyByteArray_Check)
  463. #define PyByteArray_Check(obj) PyObject_TypeCheck(obj, &PyByteArray_Type)
  464. #endif
  465. #if CYTHON_COMPILING_IN_PYPY && !defined(PyObject_Format)
  466. #define PyObject_Format(obj, fmt) PyObject_CallMethod(obj, "__format__", "O", fmt)
  467. #endif
  468. #define __Pyx_PyString_FormatSafe(a, b) ((unlikely((a) == Py_None || (PyString_Check(b) && !PyString_CheckExact(b)))) ? PyNumber_Remainder(a, b) : __Pyx_PyString_Format(a, b))
  469. #define __Pyx_PyUnicode_FormatSafe(a, b) ((unlikely((a) == Py_None || (PyUnicode_Check(b) && !PyUnicode_CheckExact(b)))) ? PyNumber_Remainder(a, b) : PyUnicode_Format(a, b))
  470. #if PY_MAJOR_VERSION >= 3
  471. #define __Pyx_PyString_Format(a, b) PyUnicode_Format(a, b)
  472. #else
  473. #define __Pyx_PyString_Format(a, b) PyString_Format(a, b)
  474. #endif
  475. #if PY_MAJOR_VERSION < 3 && !defined(PyObject_ASCII)
  476. #define PyObject_ASCII(o) PyObject_Repr(o)
  477. #endif
  478. #if PY_MAJOR_VERSION >= 3
  479. #define PyBaseString_Type PyUnicode_Type
  480. #define PyStringObject PyUnicodeObject
  481. #define PyString_Type PyUnicode_Type
  482. #define PyString_Check PyUnicode_Check
  483. #define PyString_CheckExact PyUnicode_CheckExact
  484. #define PyObject_Unicode PyObject_Str
  485. #endif
  486. #if PY_MAJOR_VERSION >= 3
  487. #define __Pyx_PyBaseString_Check(obj) PyUnicode_Check(obj)
  488. #define __Pyx_PyBaseString_CheckExact(obj) PyUnicode_CheckExact(obj)
  489. #else
  490. #define __Pyx_PyBaseString_Check(obj) (PyString_Check(obj) || PyUnicode_Check(obj))
  491. #define __Pyx_PyBaseString_CheckExact(obj) (PyString_CheckExact(obj) || PyUnicode_CheckExact(obj))
  492. #endif
  493. #ifndef PySet_CheckExact
  494. #define PySet_CheckExact(obj) (Py_TYPE(obj) == &PySet_Type)
  495. #endif
  496. #if CYTHON_ASSUME_SAFE_MACROS
  497. #define __Pyx_PySequence_SIZE(seq) Py_SIZE(seq)
  498. #else
  499. #define __Pyx_PySequence_SIZE(seq) PySequence_Size(seq)
  500. #endif
  501. #if PY_MAJOR_VERSION >= 3
  502. #define PyIntObject PyLongObject
  503. #define PyInt_Type PyLong_Type
  504. #define PyInt_Check(op) PyLong_Check(op)
  505. #define PyInt_CheckExact(op) PyLong_CheckExact(op)
  506. #define PyInt_FromString PyLong_FromString
  507. #define PyInt_FromUnicode PyLong_FromUnicode
  508. #define PyInt_FromLong PyLong_FromLong
  509. #define PyInt_FromSize_t PyLong_FromSize_t
  510. #define PyInt_FromSsize_t PyLong_FromSsize_t
  511. #define PyInt_AsLong PyLong_AsLong
  512. #define PyInt_AS_LONG PyLong_AS_LONG
  513. #define PyInt_AsSsize_t PyLong_AsSsize_t
  514. #define PyInt_AsUnsignedLongMask PyLong_AsUnsignedLongMask
  515. #define PyInt_AsUnsignedLongLongMask PyLong_AsUnsignedLongLongMask
  516. #define PyNumber_Int PyNumber_Long
  517. #endif
  518. #if PY_MAJOR_VERSION >= 3
  519. #define PyBoolObject PyLongObject
  520. #endif
  521. #if PY_MAJOR_VERSION >= 3 && CYTHON_COMPILING_IN_PYPY
  522. #ifndef PyUnicode_InternFromString
  523. #define PyUnicode_InternFromString(s) PyUnicode_FromString(s)
  524. #endif
  525. #endif
  526. #if PY_VERSION_HEX < 0x030200A4
  527. typedef long Py_hash_t;
  528. #define __Pyx_PyInt_FromHash_t PyInt_FromLong
  529. #define __Pyx_PyInt_AsHash_t PyInt_AsLong
  530. #else
  531. #define __Pyx_PyInt_FromHash_t PyInt_FromSsize_t
  532. #define __Pyx_PyInt_AsHash_t PyInt_AsSsize_t
  533. #endif
  534. #if PY_MAJOR_VERSION >= 3
  535. #define __Pyx_PyMethod_New(func, self, klass) ((self) ? PyMethod_New(func, self) : (Py_INCREF(func), func))
  536. #else
  537. #define __Pyx_PyMethod_New(func, self, klass) PyMethod_New(func, self, klass)
  538. #endif
  539. #if CYTHON_USE_ASYNC_SLOTS
  540. #if PY_VERSION_HEX >= 0x030500B1
  541. #define __Pyx_PyAsyncMethodsStruct PyAsyncMethods
  542. #define __Pyx_PyType_AsAsync(obj) (Py_TYPE(obj)->tp_as_async)
  543. #else
  544. #define __Pyx_PyType_AsAsync(obj) ((__Pyx_PyAsyncMethodsStruct*) (Py_TYPE(obj)->tp_reserved))
  545. #endif
  546. #else
  547. #define __Pyx_PyType_AsAsync(obj) NULL
  548. #endif
  549. #ifndef __Pyx_PyAsyncMethodsStruct
  550. typedef struct {
  551. unaryfunc am_await;
  552. unaryfunc am_aiter;
  553. unaryfunc am_anext;
  554. } __Pyx_PyAsyncMethodsStruct;
  555. #endif
  556. #if defined(WIN32) || defined(MS_WINDOWS)
  557. #define _USE_MATH_DEFINES
  558. #endif
  559. #include <math.h>
  560. #ifdef NAN
  561. #define __PYX_NAN() ((float) NAN)
  562. #else
  563. static CYTHON_INLINE float __PYX_NAN() {
  564. float value;
  565. memset(&value, 0xFF, sizeof(value));
  566. return value;
  567. }
  568. #endif
  569. #if defined(__CYGWIN__) && defined(_LDBL_EQ_DBL)
  570. #define __Pyx_truncl trunc
  571. #else
  572. #define __Pyx_truncl truncl
  573. #endif
  574. #define __PYX_ERR(f_index, lineno, Ln_error) \
  575. { \
  576. __pyx_filename = __pyx_f[f_index]; __pyx_lineno = lineno; __pyx_clineno = __LINE__; goto Ln_error; \
  577. }
  578. #ifndef __PYX_EXTERN_C
  579. #ifdef __cplusplus
  580. #define __PYX_EXTERN_C extern "C"
  581. #else
  582. #define __PYX_EXTERN_C extern
  583. #endif
  584. #endif
  585. #define __PYX_HAVE___yaml
  586. #define __PYX_HAVE_API___yaml
  587. /* Early includes */
  588. #include "_yaml.h"
  589. #ifdef _OPENMP
  590. #include <omp.h>
  591. #endif /* _OPENMP */
  592. #if defined(PYREX_WITHOUT_ASSERTIONS) && !defined(CYTHON_WITHOUT_ASSERTIONS)
  593. #define CYTHON_WITHOUT_ASSERTIONS
  594. #endif
  595. typedef struct {PyObject **p; const char *s; const Py_ssize_t n; const char* encoding;
  596. const char is_unicode; const char is_str; const char intern; } __Pyx_StringTabEntry;
  597. #define __PYX_DEFAULT_STRING_ENCODING_IS_ASCII 0
  598. #define __PYX_DEFAULT_STRING_ENCODING_IS_UTF8 0
  599. #define __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT (PY_MAJOR_VERSION >= 3 && __PYX_DEFAULT_STRING_ENCODING_IS_UTF8)
  600. #define __PYX_DEFAULT_STRING_ENCODING ""
  601. #define __Pyx_PyObject_FromString __Pyx_PyBytes_FromString
  602. #define __Pyx_PyObject_FromStringAndSize __Pyx_PyBytes_FromStringAndSize
  603. #define __Pyx_uchar_cast(c) ((unsigned char)c)
  604. #define __Pyx_long_cast(x) ((long)x)
  605. #define __Pyx_fits_Py_ssize_t(v, type, is_signed) (\
  606. (sizeof(type) < sizeof(Py_ssize_t)) ||\
  607. (sizeof(type) > sizeof(Py_ssize_t) &&\
  608. likely(v < (type)PY_SSIZE_T_MAX ||\
  609. v == (type)PY_SSIZE_T_MAX) &&\
  610. (!is_signed || likely(v > (type)PY_SSIZE_T_MIN ||\
  611. v == (type)PY_SSIZE_T_MIN))) ||\
  612. (sizeof(type) == sizeof(Py_ssize_t) &&\
  613. (is_signed || likely(v < (type)PY_SSIZE_T_MAX ||\
  614. v == (type)PY_SSIZE_T_MAX))) )
  615. static CYTHON_INLINE int __Pyx_is_valid_index(Py_ssize_t i, Py_ssize_t limit) {
  616. return (size_t) i < (size_t) limit;
  617. }
  618. #if defined (__cplusplus) && __cplusplus >= 201103L
  619. #include <cstdlib>
  620. #define __Pyx_sst_abs(value) std::abs(value)
  621. #elif SIZEOF_INT >= SIZEOF_SIZE_T
  622. #define __Pyx_sst_abs(value) abs(value)
  623. #elif SIZEOF_LONG >= SIZEOF_SIZE_T
  624. #define __Pyx_sst_abs(value) labs(value)
  625. #elif defined (_MSC_VER)
  626. #define __Pyx_sst_abs(value) ((Py_ssize_t)_abs64(value))
  627. #elif defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L
  628. #define __Pyx_sst_abs(value) llabs(value)
  629. #elif defined (__GNUC__)
  630. #define __Pyx_sst_abs(value) __builtin_llabs(value)
  631. #else
  632. #define __Pyx_sst_abs(value) ((value<0) ? -value : value)
  633. #endif
  634. static CYTHON_INLINE const char* __Pyx_PyObject_AsString(PyObject*);
  635. static CYTHON_INLINE const char* __Pyx_PyObject_AsStringAndSize(PyObject*, Py_ssize_t* length);
  636. #define __Pyx_PyByteArray_FromString(s) PyByteArray_FromStringAndSize((const char*)s, strlen((const char*)s))
  637. #define __Pyx_PyByteArray_FromStringAndSize(s, l) PyByteArray_FromStringAndSize((const char*)s, l)
  638. #define __Pyx_PyBytes_FromString PyBytes_FromString
  639. #define __Pyx_PyBytes_FromStringAndSize PyBytes_FromStringAndSize
  640. static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(const char*);
  641. #if PY_MAJOR_VERSION < 3
  642. #define __Pyx_PyStr_FromString __Pyx_PyBytes_FromString
  643. #define __Pyx_PyStr_FromStringAndSize __Pyx_PyBytes_FromStringAndSize
  644. #else
  645. #define __Pyx_PyStr_FromString __Pyx_PyUnicode_FromString
  646. #define __Pyx_PyStr_FromStringAndSize __Pyx_PyUnicode_FromStringAndSize
  647. #endif
  648. #define __Pyx_PyBytes_AsWritableString(s) ((char*) PyBytes_AS_STRING(s))
  649. #define __Pyx_PyBytes_AsWritableSString(s) ((signed char*) PyBytes_AS_STRING(s))
  650. #define __Pyx_PyBytes_AsWritableUString(s) ((unsigned char*) PyBytes_AS_STRING(s))
  651. #define __Pyx_PyBytes_AsString(s) ((const char*) PyBytes_AS_STRING(s))
  652. #define __Pyx_PyBytes_AsSString(s) ((const signed char*) PyBytes_AS_STRING(s))
  653. #define __Pyx_PyBytes_AsUString(s) ((const unsigned char*) PyBytes_AS_STRING(s))
  654. #define __Pyx_PyObject_AsWritableString(s) ((char*) __Pyx_PyObject_AsString(s))
  655. #define __Pyx_PyObject_AsWritableSString(s) ((signed char*) __Pyx_PyObject_AsString(s))
  656. #define __Pyx_PyObject_AsWritableUString(s) ((unsigned char*) __Pyx_PyObject_AsString(s))
  657. #define __Pyx_PyObject_AsSString(s) ((const signed char*) __Pyx_PyObject_AsString(s))
  658. #define __Pyx_PyObject_AsUString(s) ((const unsigned char*) __Pyx_PyObject_AsString(s))
  659. #define __Pyx_PyObject_FromCString(s) __Pyx_PyObject_FromString((const char*)s)
  660. #define __Pyx_PyBytes_FromCString(s) __Pyx_PyBytes_FromString((const char*)s)
  661. #define __Pyx_PyByteArray_FromCString(s) __Pyx_PyByteArray_FromString((const char*)s)
  662. #define __Pyx_PyStr_FromCString(s) __Pyx_PyStr_FromString((const char*)s)
  663. #define __Pyx_PyUnicode_FromCString(s) __Pyx_PyUnicode_FromString((const char*)s)
  664. static CYTHON_INLINE size_t __Pyx_Py_UNICODE_strlen(const Py_UNICODE *u) {
  665. const Py_UNICODE *u_end = u;
  666. while (*u_end++) ;
  667. return (size_t)(u_end - u - 1);
  668. }
  669. #define __Pyx_PyUnicode_FromUnicode(u) PyUnicode_FromUnicode(u, __Pyx_Py_UNICODE_strlen(u))
  670. #define __Pyx_PyUnicode_FromUnicodeAndLength PyUnicode_FromUnicode
  671. #define __Pyx_PyUnicode_AsUnicode PyUnicode_AsUnicode
  672. #define __Pyx_NewRef(obj) (Py_INCREF(obj), obj)
  673. #define __Pyx_Owned_Py_None(b) __Pyx_NewRef(Py_None)
  674. static CYTHON_INLINE PyObject * __Pyx_PyBool_FromLong(long b);
  675. static CYTHON_INLINE int __Pyx_PyObject_IsTrue(PyObject*);
  676. static CYTHON_INLINE int __Pyx_PyObject_IsTrueAndDecref(PyObject*);
  677. static CYTHON_INLINE PyObject* __Pyx_PyNumber_IntOrLong(PyObject* x);
  678. #define __Pyx_PySequence_Tuple(obj)\
  679. (likely(PyTuple_CheckExact(obj)) ? __Pyx_NewRef(obj) : PySequence_Tuple(obj))
  680. static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject*);
  681. static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(size_t);
  682. #if CYTHON_ASSUME_SAFE_MACROS
  683. #define __pyx_PyFloat_AsDouble(x) (PyFloat_CheckExact(x) ? PyFloat_AS_DOUBLE(x) : PyFloat_AsDouble(x))
  684. #else
  685. #define __pyx_PyFloat_AsDouble(x) PyFloat_AsDouble(x)
  686. #endif
  687. #define __pyx_PyFloat_AsFloat(x) ((float) __pyx_PyFloat_AsDouble(x))
  688. #if PY_MAJOR_VERSION >= 3
  689. #define __Pyx_PyNumber_Int(x) (PyLong_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Long(x))
  690. #else
  691. #define __Pyx_PyNumber_Int(x) (PyInt_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Int(x))
  692. #endif
  693. #define __Pyx_PyNumber_Float(x) (PyFloat_CheckExact(x) ? __Pyx_NewRef(x) : PyNumber_Float(x))
  694. #if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
  695. static int __Pyx_sys_getdefaultencoding_not_ascii;
  696. static int __Pyx_init_sys_getdefaultencoding_params(void) {
  697. PyObject* sys;
  698. PyObject* default_encoding = NULL;
  699. PyObject* ascii_chars_u = NULL;
  700. PyObject* ascii_chars_b = NULL;
  701. const char* default_encoding_c;
  702. sys = PyImport_ImportModule("sys");
  703. if (!sys) goto bad;
  704. default_encoding = PyObject_CallMethod(sys, (char*) "getdefaultencoding", NULL);
  705. Py_DECREF(sys);
  706. if (!default_encoding) goto bad;
  707. default_encoding_c = PyBytes_AsString(default_encoding);
  708. if (!default_encoding_c) goto bad;
  709. if (strcmp(default_encoding_c, "ascii") == 0) {
  710. __Pyx_sys_getdefaultencoding_not_ascii = 0;
  711. } else {
  712. char ascii_chars[128];
  713. int c;
  714. for (c = 0; c < 128; c++) {
  715. ascii_chars[c] = c;
  716. }
  717. __Pyx_sys_getdefaultencoding_not_ascii = 1;
  718. ascii_chars_u = PyUnicode_DecodeASCII(ascii_chars, 128, NULL);
  719. if (!ascii_chars_u) goto bad;
  720. ascii_chars_b = PyUnicode_AsEncodedString(ascii_chars_u, default_encoding_c, NULL);
  721. if (!ascii_chars_b || !PyBytes_Check(ascii_chars_b) || memcmp(ascii_chars, PyBytes_AS_STRING(ascii_chars_b), 128) != 0) {
  722. PyErr_Format(
  723. PyExc_ValueError,
  724. "This module compiled with c_string_encoding=ascii, but default encoding '%.200s' is not a superset of ascii.",
  725. default_encoding_c);
  726. goto bad;
  727. }
  728. Py_DECREF(ascii_chars_u);
  729. Py_DECREF(ascii_chars_b);
  730. }
  731. Py_DECREF(default_encoding);
  732. return 0;
  733. bad:
  734. Py_XDECREF(default_encoding);
  735. Py_XDECREF(ascii_chars_u);
  736. Py_XDECREF(ascii_chars_b);
  737. return -1;
  738. }
  739. #endif
  740. #if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT && PY_MAJOR_VERSION >= 3
  741. #define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_DecodeUTF8(c_str, size, NULL)
  742. #else
  743. #define __Pyx_PyUnicode_FromStringAndSize(c_str, size) PyUnicode_Decode(c_str, size, __PYX_DEFAULT_STRING_ENCODING, NULL)
  744. #if __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
  745. static char* __PYX_DEFAULT_STRING_ENCODING;
  746. static int __Pyx_init_sys_getdefaultencoding_params(void) {
  747. PyObject* sys;
  748. PyObject* default_encoding = NULL;
  749. char* default_encoding_c;
  750. sys = PyImport_ImportModule("sys");
  751. if (!sys) goto bad;
  752. default_encoding = PyObject_CallMethod(sys, (char*) (const char*) "getdefaultencoding", NULL);
  753. Py_DECREF(sys);
  754. if (!default_encoding) goto bad;
  755. default_encoding_c = PyBytes_AsString(default_encoding);
  756. if (!default_encoding_c) goto bad;
  757. __PYX_DEFAULT_STRING_ENCODING = (char*) malloc(strlen(default_encoding_c) + 1);
  758. if (!__PYX_DEFAULT_STRING_ENCODING) goto bad;
  759. strcpy(__PYX_DEFAULT_STRING_ENCODING, default_encoding_c);
  760. Py_DECREF(default_encoding);
  761. return 0;
  762. bad:
  763. Py_XDECREF(default_encoding);
  764. return -1;
  765. }
  766. #endif
  767. #endif
  768. /* Test for GCC > 2.95 */
  769. #if defined(__GNUC__) && (__GNUC__ > 2 || (__GNUC__ == 2 && (__GNUC_MINOR__ > 95)))
  770. #define likely(x) __builtin_expect(!!(x), 1)
  771. #define unlikely(x) __builtin_expect(!!(x), 0)
  772. #else /* !__GNUC__ or GCC < 2.95 */
  773. #define likely(x) (x)
  774. #define unlikely(x) (x)
  775. #endif /* __GNUC__ */
  776. static CYTHON_INLINE void __Pyx_pretend_to_initialize(void* ptr) { (void)ptr; }
  777. static PyObject *__pyx_m = NULL;
  778. static PyObject *__pyx_d;
  779. static PyObject *__pyx_b;
  780. static PyObject *__pyx_cython_runtime = NULL;
  781. static PyObject *__pyx_empty_tuple;
  782. static PyObject *__pyx_empty_bytes;
  783. static PyObject *__pyx_empty_unicode;
  784. static int __pyx_lineno;
  785. static int __pyx_clineno = 0;
  786. static const char * __pyx_cfilenm= __FILE__;
  787. static const char *__pyx_filename;
  788. static const char *__pyx_f[] = {
  789. "ext/_yaml.pyx",
  790. "stringsource",
  791. };
  792. /*--- Type declarations ---*/
  793. struct __pyx_obj_5_yaml_Mark;
  794. struct __pyx_obj_5_yaml_CParser;
  795. struct __pyx_obj_5_yaml_CEmitter;
  796. /* "_yaml.pyx":64
  797. * MappingNode = yaml.nodes.MappingNode
  798. *
  799. * cdef class Mark: # <<<<<<<<<<<<<<
  800. * cdef readonly object name
  801. * cdef readonly size_t index
  802. */
  803. struct __pyx_obj_5_yaml_Mark {
  804. PyObject_HEAD
  805. PyObject *name;
  806. size_t index;
  807. size_t line;
  808. size_t column;
  809. PyObject *buffer;
  810. PyObject *pointer;
  811. };
  812. /* "_yaml.pyx":247
  813. * # self.style = style
  814. *
  815. * cdef class CParser: # <<<<<<<<<<<<<<
  816. *
  817. * cdef yaml_parser_t parser
  818. */
  819. struct __pyx_obj_5_yaml_CParser {
  820. PyObject_HEAD
  821. struct __pyx_vtabstruct_5_yaml_CParser *__pyx_vtab;
  822. yaml_parser_t parser;
  823. yaml_event_t parsed_event;
  824. PyObject *stream;
  825. PyObject *stream_name;
  826. PyObject *current_token;
  827. PyObject *current_event;
  828. PyObject *anchors;
  829. PyObject *stream_cache;
  830. int stream_cache_len;
  831. int stream_cache_pos;
  832. int unicode_source;
  833. };
  834. /* "_yaml.pyx":935
  835. * return 1
  836. *
  837. * cdef class CEmitter: # <<<<<<<<<<<<<<
  838. *
  839. * cdef yaml_emitter_t emitter
  840. */
  841. struct __pyx_obj_5_yaml_CEmitter {
  842. PyObject_HEAD
  843. struct __pyx_vtabstruct_5_yaml_CEmitter *__pyx_vtab;
  844. yaml_emitter_t emitter;
  845. PyObject *stream;
  846. int document_start_implicit;
  847. int document_end_implicit;
  848. PyObject *use_version;
  849. PyObject *use_tags;
  850. PyObject *serialized_nodes;
  851. PyObject *anchors;
  852. int last_alias_id;
  853. int closed;
  854. int dump_unicode;
  855. PyObject *use_encoding;
  856. };
  857. /* "_yaml.pyx":247
  858. * # self.style = style
  859. *
  860. * cdef class CParser: # <<<<<<<<<<<<<<
  861. *
  862. * cdef yaml_parser_t parser
  863. */
  864. struct __pyx_vtabstruct_5_yaml_CParser {
  865. PyObject *(*_parser_error)(struct __pyx_obj_5_yaml_CParser *);
  866. PyObject *(*_scan)(struct __pyx_obj_5_yaml_CParser *);
  867. PyObject *(*_token_to_object)(struct __pyx_obj_5_yaml_CParser *, yaml_token_t *);
  868. PyObject *(*_parse)(struct __pyx_obj_5_yaml_CParser *);
  869. PyObject *(*_event_to_object)(struct __pyx_obj_5_yaml_CParser *, yaml_event_t *);
  870. PyObject *(*_compose_document)(struct __pyx_obj_5_yaml_CParser *);
  871. PyObject *(*_compose_node)(struct __pyx_obj_5_yaml_CParser *, PyObject *, PyObject *);
  872. PyObject *(*_compose_scalar_node)(struct __pyx_obj_5_yaml_CParser *, PyObject *);
  873. PyObject *(*_compose_sequence_node)(struct __pyx_obj_5_yaml_CParser *, PyObject *);
  874. PyObject *(*_compose_mapping_node)(struct __pyx_obj_5_yaml_CParser *, PyObject *);
  875. int (*_parse_next_event)(struct __pyx_obj_5_yaml_CParser *);
  876. };
  877. static struct __pyx_vtabstruct_5_yaml_CParser *__pyx_vtabptr_5_yaml_CParser;
  878. /* "_yaml.pyx":935
  879. * return 1
  880. *
  881. * cdef class CEmitter: # <<<<<<<<<<<<<<
  882. *
  883. * cdef yaml_emitter_t emitter
  884. */
  885. struct __pyx_vtabstruct_5_yaml_CEmitter {
  886. PyObject *(*_emitter_error)(struct __pyx_obj_5_yaml_CEmitter *);
  887. int (*_object_to_event)(struct __pyx_obj_5_yaml_CEmitter *, PyObject *, yaml_event_t *);
  888. int (*_anchor_node)(struct __pyx_obj_5_yaml_CEmitter *, PyObject *);
  889. int (*_serialize_node)(struct __pyx_obj_5_yaml_CEmitter *, PyObject *, PyObject *, PyObject *);
  890. };
  891. static struct __pyx_vtabstruct_5_yaml_CEmitter *__pyx_vtabptr_5_yaml_CEmitter;
  892. /* --- Runtime support code (head) --- */
  893. /* Refnanny.proto */
  894. #ifndef CYTHON_REFNANNY
  895. #define CYTHON_REFNANNY 0
  896. #endif
  897. #if CYTHON_REFNANNY
  898. typedef struct {
  899. void (*INCREF)(void*, PyObject*, int);
  900. void (*DECREF)(void*, PyObject*, int);
  901. void (*GOTREF)(void*, PyObject*, int);
  902. void (*GIVEREF)(void*, PyObject*, int);
  903. void* (*SetupContext)(const char*, int, const char*);
  904. void (*FinishContext)(void**);
  905. } __Pyx_RefNannyAPIStruct;
  906. static __Pyx_RefNannyAPIStruct *__Pyx_RefNanny = NULL;
  907. static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(const char *modname);
  908. #define __Pyx_RefNannyDeclarations void *__pyx_refnanny = NULL;
  909. #ifdef WITH_THREAD
  910. #define __Pyx_RefNannySetupContext(name, acquire_gil)\
  911. if (acquire_gil) {\
  912. PyGILState_STATE __pyx_gilstate_save = PyGILState_Ensure();\
  913. __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__);\
  914. PyGILState_Release(__pyx_gilstate_save);\
  915. } else {\
  916. __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__);\
  917. }
  918. #else
  919. #define __Pyx_RefNannySetupContext(name, acquire_gil)\
  920. __pyx_refnanny = __Pyx_RefNanny->SetupContext((name), __LINE__, __FILE__)
  921. #endif
  922. #define __Pyx_RefNannyFinishContext()\
  923. __Pyx_RefNanny->FinishContext(&__pyx_refnanny)
  924. #define __Pyx_INCREF(r) __Pyx_RefNanny->INCREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
  925. #define __Pyx_DECREF(r) __Pyx_RefNanny->DECREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
  926. #define __Pyx_GOTREF(r) __Pyx_RefNanny->GOTREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
  927. #define __Pyx_GIVEREF(r) __Pyx_RefNanny->GIVEREF(__pyx_refnanny, (PyObject *)(r), __LINE__)
  928. #define __Pyx_XINCREF(r) do { if((r) != NULL) {__Pyx_INCREF(r); }} while(0)
  929. #define __Pyx_XDECREF(r) do { if((r) != NULL) {__Pyx_DECREF(r); }} while(0)
  930. #define __Pyx_XGOTREF(r) do { if((r) != NULL) {__Pyx_GOTREF(r); }} while(0)
  931. #define __Pyx_XGIVEREF(r) do { if((r) != NULL) {__Pyx_GIVEREF(r);}} while(0)
  932. #else
  933. #define __Pyx_RefNannyDeclarations
  934. #define __Pyx_RefNannySetupContext(name, acquire_gil)
  935. #define __Pyx_RefNannyFinishContext()
  936. #define __Pyx_INCREF(r) Py_INCREF(r)
  937. #define __Pyx_DECREF(r) Py_DECREF(r)
  938. #define __Pyx_GOTREF(r)
  939. #define __Pyx_GIVEREF(r)
  940. #define __Pyx_XINCREF(r) Py_XINCREF(r)
  941. #define __Pyx_XDECREF(r) Py_XDECREF(r)
  942. #define __Pyx_XGOTREF(r)
  943. #define __Pyx_XGIVEREF(r)
  944. #endif
  945. #define __Pyx_XDECREF_SET(r, v) do {\
  946. PyObject *tmp = (PyObject *) r;\
  947. r = v; __Pyx_XDECREF(tmp);\
  948. } while (0)
  949. #define __Pyx_DECREF_SET(r, v) do {\
  950. PyObject *tmp = (PyObject *) r;\
  951. r = v; __Pyx_DECREF(tmp);\
  952. } while (0)
  953. #define __Pyx_CLEAR(r) do { PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);} while(0)
  954. #define __Pyx_XCLEAR(r) do { if((r) != NULL) {PyObject* tmp = ((PyObject*)(r)); r = NULL; __Pyx_DECREF(tmp);}} while(0)
  955. /* PyObjectGetAttrStr.proto */
  956. #if CYTHON_USE_TYPE_SLOTS
  957. static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStr(PyObject* obj, PyObject* attr_name);
  958. #else
  959. #define __Pyx_PyObject_GetAttrStr(o,n) PyObject_GetAttr(o,n)
  960. #endif
  961. /* GetBuiltinName.proto */
  962. static PyObject *__Pyx_GetBuiltinName(PyObject *name);
  963. /* RaiseArgTupleInvalid.proto */
  964. static void __Pyx_RaiseArgtupleInvalid(const char* func_name, int exact,
  965. Py_ssize_t num_min, Py_ssize_t num_max, Py_ssize_t num_found);
  966. /* RaiseDoubleKeywords.proto */
  967. static void __Pyx_RaiseDoubleKeywordsError(const char* func_name, PyObject* kw_name);
  968. /* ParseKeywords.proto */
  969. static int __Pyx_ParseOptionalKeywords(PyObject *kwds, PyObject **argnames[],\
  970. PyObject *kwds2, PyObject *values[], Py_ssize_t num_pos_args,\
  971. const char* function_name);
  972. /* PyErrExceptionMatches.proto */
  973. #if CYTHON_FAST_THREAD_STATE
  974. #define __Pyx_PyErr_ExceptionMatches(err) __Pyx_PyErr_ExceptionMatchesInState(__pyx_tstate, err)
  975. static CYTHON_INLINE int __Pyx_PyErr_ExceptionMatchesInState(PyThreadState* tstate, PyObject* err);
  976. #else
  977. #define __Pyx_PyErr_ExceptionMatches(err) PyErr_ExceptionMatches(err)
  978. #endif
  979. /* PyThreadStateGet.proto */
  980. #if CYTHON_FAST_THREAD_STATE
  981. #define __Pyx_PyThreadState_declare PyThreadState *__pyx_tstate;
  982. #define __Pyx_PyThreadState_assign __pyx_tstate = __Pyx_PyThreadState_Current;
  983. #define __Pyx_PyErr_Occurred() __pyx_tstate->curexc_type
  984. #else
  985. #define __Pyx_PyThreadState_declare
  986. #define __Pyx_PyThreadState_assign
  987. #define __Pyx_PyErr_Occurred() PyErr_Occurred()
  988. #endif
  989. /* PyErrFetchRestore.proto */
  990. #if CYTHON_FAST_THREAD_STATE
  991. #define __Pyx_PyErr_Clear() __Pyx_ErrRestore(NULL, NULL, NULL)
  992. #define __Pyx_ErrRestoreWithState(type, value, tb) __Pyx_ErrRestoreInState(PyThreadState_GET(), type, value, tb)
  993. #define __Pyx_ErrFetchWithState(type, value, tb) __Pyx_ErrFetchInState(PyThreadState_GET(), type, value, tb)
  994. #define __Pyx_ErrRestore(type, value, tb) __Pyx_ErrRestoreInState(__pyx_tstate, type, value, tb)
  995. #define __Pyx_ErrFetch(type, value, tb) __Pyx_ErrFetchInState(__pyx_tstate, type, value, tb)
  996. static CYTHON_INLINE void __Pyx_ErrRestoreInState(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb);
  997. static CYTHON_INLINE void __Pyx_ErrFetchInState(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
  998. #if CYTHON_COMPILING_IN_CPYTHON
  999. #define __Pyx_PyErr_SetNone(exc) (Py_INCREF(exc), __Pyx_ErrRestore((exc), NULL, NULL))
  1000. #else
  1001. #define __Pyx_PyErr_SetNone(exc) PyErr_SetNone(exc)
  1002. #endif
  1003. #else
  1004. #define __Pyx_PyErr_Clear() PyErr_Clear()
  1005. #define __Pyx_PyErr_SetNone(exc) PyErr_SetNone(exc)
  1006. #define __Pyx_ErrRestoreWithState(type, value, tb) PyErr_Restore(type, value, tb)
  1007. #define __Pyx_ErrFetchWithState(type, value, tb) PyErr_Fetch(type, value, tb)
  1008. #define __Pyx_ErrRestoreInState(tstate, type, value, tb) PyErr_Restore(type, value, tb)
  1009. #define __Pyx_ErrFetchInState(tstate, type, value, tb) PyErr_Fetch(type, value, tb)
  1010. #define __Pyx_ErrRestore(type, value, tb) PyErr_Restore(type, value, tb)
  1011. #define __Pyx_ErrFetch(type, value, tb) PyErr_Fetch(type, value, tb)
  1012. #endif
  1013. /* GetAttr.proto */
  1014. static CYTHON_INLINE PyObject *__Pyx_GetAttr(PyObject *, PyObject *);
  1015. /* GetAttr3.proto */
  1016. static CYTHON_INLINE PyObject *__Pyx_GetAttr3(PyObject *, PyObject *, PyObject *);
  1017. /* PyDictVersioning.proto */
  1018. #if CYTHON_USE_DICT_VERSIONS && CYTHON_USE_TYPE_SLOTS
  1019. #define __PYX_DICT_VERSION_INIT ((PY_UINT64_T) -1)
  1020. #define __PYX_GET_DICT_VERSION(dict) (((PyDictObject*)(dict))->ma_version_tag)
  1021. #define __PYX_UPDATE_DICT_CACHE(dict, value, cache_var, version_var)\
  1022. (version_var) = __PYX_GET_DICT_VERSION(dict);\
  1023. (cache_var) = (value);
  1024. #define __PYX_PY_DICT_LOOKUP_IF_MODIFIED(VAR, DICT, LOOKUP) {\
  1025. static PY_UINT64_T __pyx_dict_version = 0;\
  1026. static PyObject *__pyx_dict_cached_value = NULL;\
  1027. if (likely(__PYX_GET_DICT_VERSION(DICT) == __pyx_dict_version)) {\
  1028. (VAR) = __pyx_dict_cached_value;\
  1029. } else {\
  1030. (VAR) = __pyx_dict_cached_value = (LOOKUP);\
  1031. __pyx_dict_version = __PYX_GET_DICT_VERSION(DICT);\
  1032. }\
  1033. }
  1034. static CYTHON_INLINE PY_UINT64_T __Pyx_get_tp_dict_version(PyObject *obj);
  1035. static CYTHON_INLINE PY_UINT64_T __Pyx_get_object_dict_version(PyObject *obj);
  1036. static CYTHON_INLINE int __Pyx_object_dict_version_matches(PyObject* obj, PY_UINT64_T tp_dict_version, PY_UINT64_T obj_dict_version);
  1037. #else
  1038. #define __PYX_GET_DICT_VERSION(dict) (0)
  1039. #define __PYX_UPDATE_DICT_CACHE(dict, value, cache_var, version_var)
  1040. #define __PYX_PY_DICT_LOOKUP_IF_MODIFIED(VAR, DICT, LOOKUP) (VAR) = (LOOKUP);
  1041. #endif
  1042. /* GetModuleGlobalName.proto */
  1043. #if CYTHON_USE_DICT_VERSIONS
  1044. #define __Pyx_GetModuleGlobalName(var, name) {\
  1045. static PY_UINT64_T __pyx_dict_version = 0;\
  1046. static PyObject *__pyx_dict_cached_value = NULL;\
  1047. (var) = (likely(__pyx_dict_version == __PYX_GET_DICT_VERSION(__pyx_d))) ?\
  1048. (likely(__pyx_dict_cached_value) ? __Pyx_NewRef(__pyx_dict_cached_value) : __Pyx_GetBuiltinName(name)) :\
  1049. __Pyx__GetModuleGlobalName(name, &__pyx_dict_version, &__pyx_dict_cached_value);\
  1050. }
  1051. #define __Pyx_GetModuleGlobalNameUncached(var, name) {\
  1052. PY_UINT64_T __pyx_dict_version;\
  1053. PyObject *__pyx_dict_cached_value;\
  1054. (var) = __Pyx__GetModuleGlobalName(name, &__pyx_dict_version, &__pyx_dict_cached_value);\
  1055. }
  1056. static PyObject *__Pyx__GetModuleGlobalName(PyObject *name, PY_UINT64_T *dict_version, PyObject **dict_cached_value);
  1057. #else
  1058. #define __Pyx_GetModuleGlobalName(var, name) (var) = __Pyx__GetModuleGlobalName(name)
  1059. #define __Pyx_GetModuleGlobalNameUncached(var, name) (var) = __Pyx__GetModuleGlobalName(name)
  1060. static CYTHON_INLINE PyObject *__Pyx__GetModuleGlobalName(PyObject *name);
  1061. #endif
  1062. /* GetTopmostException.proto */
  1063. #if CYTHON_USE_EXC_INFO_STACK
  1064. static _PyErr_StackItem * __Pyx_PyErr_GetTopmostException(PyThreadState *tstate);
  1065. #endif
  1066. /* SaveResetException.proto */
  1067. #if CYTHON_FAST_THREAD_STATE
  1068. #define __Pyx_ExceptionSave(type, value, tb) __Pyx__ExceptionSave(__pyx_tstate, type, value, tb)
  1069. static CYTHON_INLINE void __Pyx__ExceptionSave(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
  1070. #define __Pyx_ExceptionReset(type, value, tb) __Pyx__ExceptionReset(__pyx_tstate, type, value, tb)
  1071. static CYTHON_INLINE void __Pyx__ExceptionReset(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb);
  1072. #else
  1073. #define __Pyx_ExceptionSave(type, value, tb) PyErr_GetExcInfo(type, value, tb)
  1074. #define __Pyx_ExceptionReset(type, value, tb) PyErr_SetExcInfo(type, value, tb)
  1075. #endif
  1076. /* GetException.proto */
  1077. #if CYTHON_FAST_THREAD_STATE
  1078. #define __Pyx_GetException(type, value, tb) __Pyx__GetException(__pyx_tstate, type, value, tb)
  1079. static int __Pyx__GetException(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb);
  1080. #else
  1081. static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb);
  1082. #endif
  1083. /* PyObjectCall.proto */
  1084. #if CYTHON_COMPILING_IN_CPYTHON
  1085. static CYTHON_INLINE PyObject* __Pyx_PyObject_Call(PyObject *func, PyObject *arg, PyObject *kw);
  1086. #else
  1087. #define __Pyx_PyObject_Call(func, arg, kw) PyObject_Call(func, arg, kw)
  1088. #endif
  1089. /* RaiseException.proto */
  1090. static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause);
  1091. /* PyFunctionFastCall.proto */
  1092. #if CYTHON_FAST_PYCALL
  1093. #define __Pyx_PyFunction_FastCall(func, args, nargs)\
  1094. __Pyx_PyFunction_FastCallDict((func), (args), (nargs), NULL)
  1095. #if 1 || PY_VERSION_HEX < 0x030600B1
  1096. static PyObject *__Pyx_PyFunction_FastCallDict(PyObject *func, PyObject **args, Py_ssize_t nargs, PyObject *kwargs);
  1097. #else
  1098. #define __Pyx_PyFunction_FastCallDict(func, args, nargs, kwargs) _PyFunction_FastCallDict(func, args, nargs, kwargs)
  1099. #endif
  1100. #define __Pyx_BUILD_ASSERT_EXPR(cond)\
  1101. (sizeof(char [1 - 2*!(cond)]) - 1)
  1102. #ifndef Py_MEMBER_SIZE
  1103. #define Py_MEMBER_SIZE(type, member) sizeof(((type *)0)->member)
  1104. #endif
  1105. static size_t __pyx_pyframe_localsplus_offset = 0;
  1106. #include "frameobject.h"
  1107. #define __Pxy_PyFrame_Initialize_Offsets()\
  1108. ((void)__Pyx_BUILD_ASSERT_EXPR(sizeof(PyFrameObject) == offsetof(PyFrameObject, f_localsplus) + Py_MEMBER_SIZE(PyFrameObject, f_localsplus)),\
  1109. (void)(__pyx_pyframe_localsplus_offset = ((size_t)PyFrame_Type.tp_basicsize) - Py_MEMBER_SIZE(PyFrameObject, f_localsplus)))
  1110. #define __Pyx_PyFrame_GetLocalsplus(frame)\
  1111. (assert(__pyx_pyframe_localsplus_offset), (PyObject **)(((char *)(frame)) + __pyx_pyframe_localsplus_offset))
  1112. #endif
  1113. /* PyCFunctionFastCall.proto */
  1114. #if CYTHON_FAST_PYCCALL
  1115. static CYTHON_INLINE PyObject *__Pyx_PyCFunction_FastCall(PyObject *func, PyObject **args, Py_ssize_t nargs);
  1116. #else
  1117. #define __Pyx_PyCFunction_FastCall(func, args, nargs) (assert(0), NULL)
  1118. #endif
  1119. /* KeywordStringCheck.proto */
  1120. static int __Pyx_CheckKeywordStrings(PyObject *kwdict, const char* function_name, int kw_allowed);
  1121. /* PySequenceContains.proto */
  1122. static CYTHON_INLINE int __Pyx_PySequence_ContainsTF(PyObject* item, PyObject* seq, int eq) {
  1123. int result = PySequence_Contains(seq, item);
  1124. return unlikely(result < 0) ? result : (result == (eq == Py_EQ));
  1125. }
  1126. /* GetItemInt.proto */
  1127. #define __Pyx_GetItemInt(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
  1128. (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
  1129. __Pyx_GetItemInt_Fast(o, (Py_ssize_t)i, is_list, wraparound, boundscheck) :\
  1130. (is_list ? (PyErr_SetString(PyExc_IndexError, "list index out of range"), (PyObject*)NULL) :\
  1131. __Pyx_GetItemInt_Generic(o, to_py_func(i))))
  1132. #define __Pyx_GetItemInt_List(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
  1133. (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
  1134. __Pyx_GetItemInt_List_Fast(o, (Py_ssize_t)i, wraparound, boundscheck) :\
  1135. (PyErr_SetString(PyExc_IndexError, "list index out of range"), (PyObject*)NULL))
  1136. static CYTHON_INLINE PyObject *__Pyx_GetItemInt_List_Fast(PyObject *o, Py_ssize_t i,
  1137. int wraparound, int boundscheck);
  1138. #define __Pyx_GetItemInt_Tuple(o, i, type, is_signed, to_py_func, is_list, wraparound, boundscheck)\
  1139. (__Pyx_fits_Py_ssize_t(i, type, is_signed) ?\
  1140. __Pyx_GetItemInt_Tuple_Fast(o, (Py_ssize_t)i, wraparound, boundscheck) :\
  1141. (PyErr_SetString(PyExc_IndexError, "tuple index out of range"), (PyObject*)NULL))
  1142. static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Tuple_Fast(PyObject *o, Py_ssize_t i,
  1143. int wraparound, int boundscheck);
  1144. static PyObject *__Pyx_GetItemInt_Generic(PyObject *o, PyObject* j);
  1145. static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Fast(PyObject *o, Py_ssize_t i,
  1146. int is_list, int wraparound, int boundscheck);
  1147. /* ObjectGetItem.proto */
  1148. #if CYTHON_USE_TYPE_SLOTS
  1149. static CYTHON_INLINE PyObject *__Pyx_PyObject_GetItem(PyObject *obj, PyObject* key);
  1150. #else
  1151. #define __Pyx_PyObject_GetItem(obj, key) PyObject_GetItem(obj, key)
  1152. #endif
  1153. /* PyObjectCallMethO.proto */
  1154. #if CYTHON_COMPILING_IN_CPYTHON
  1155. static CYTHON_INLINE PyObject* __Pyx_PyObject_CallMethO(PyObject *func, PyObject *arg);
  1156. #endif
  1157. /* PyObjectCallNoArg.proto */
  1158. #if CYTHON_COMPILING_IN_CPYTHON
  1159. static CYTHON_INLINE PyObject* __Pyx_PyObject_CallNoArg(PyObject *func);
  1160. #else
  1161. #define __Pyx_PyObject_CallNoArg(func) __Pyx_PyObject_Call(func, __pyx_empty_tuple, NULL)
  1162. #endif
  1163. /* PyObjectCallOneArg.proto */
  1164. static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg);
  1165. /* None.proto */
  1166. static CYTHON_INLINE void __Pyx_RaiseUnboundLocalError(const char *varname);
  1167. /* ListAppend.proto */
  1168. #if CYTHON_USE_PYLIST_INTERNALS && CYTHON_ASSUME_SAFE_MACROS
  1169. static CYTHON_INLINE int __Pyx_PyList_Append(PyObject* list, PyObject* x) {
  1170. PyListObject* L = (PyListObject*) list;
  1171. Py_ssize_t len = Py_SIZE(list);
  1172. if (likely(L->allocated > len) & likely(len > (L->allocated >> 1))) {
  1173. Py_INCREF(x);
  1174. PyList_SET_ITEM(list, len, x);
  1175. Py_SIZE(list) = len+1;
  1176. return 0;
  1177. }
  1178. return PyList_Append(list, x);
  1179. }
  1180. #else
  1181. #define __Pyx_PyList_Append(L,x) PyList_Append(L,x)
  1182. #endif
  1183. /* PyObjectSetAttrStr.proto */
  1184. #if CYTHON_USE_TYPE_SLOTS
  1185. #define __Pyx_PyObject_DelAttrStr(o,n) __Pyx_PyObject_SetAttrStr(o, n, NULL)
  1186. static CYTHON_INLINE int __Pyx_PyObject_SetAttrStr(PyObject* obj, PyObject* attr_name, PyObject* value);
  1187. #else
  1188. #define __Pyx_PyObject_DelAttrStr(o,n) PyObject_DelAttr(o,n)
  1189. #define __Pyx_PyObject_SetAttrStr(o,n,v) PyObject_SetAttr(o,n,v)
  1190. #endif
  1191. /* PyObjectCall2Args.proto */
  1192. static CYTHON_UNUSED PyObject* __Pyx_PyObject_Call2Args(PyObject* function, PyObject* arg1, PyObject* arg2);
  1193. /* HasAttr.proto */
  1194. static CYTHON_INLINE int __Pyx_HasAttr(PyObject *, PyObject *);
  1195. /* IncludeStringH.proto */
  1196. #include <string.h>
  1197. /* BytesEquals.proto */
  1198. static CYTHON_INLINE int __Pyx_PyBytes_Equals(PyObject* s1, PyObject* s2, int equals);
  1199. /* UnicodeEquals.proto */
  1200. static CYTHON_INLINE int __Pyx_PyUnicode_Equals(PyObject* s1, PyObject* s2, int equals);
  1201. /* StrEquals.proto */
  1202. #if PY_MAJOR_VERSION >= 3
  1203. #define __Pyx_PyString_Equals __Pyx_PyUnicode_Equals
  1204. #else
  1205. #define __Pyx_PyString_Equals __Pyx_PyBytes_Equals
  1206. #endif
  1207. /* RaiseTooManyValuesToUnpack.proto */
  1208. static CYTHON_INLINE void __Pyx_RaiseTooManyValuesError(Py_ssize_t expected);
  1209. /* RaiseNeedMoreValuesToUnpack.proto */
  1210. static CYTHON_INLINE void __Pyx_RaiseNeedMoreValuesError(Py_ssize_t index);
  1211. /* IterFinish.proto */
  1212. static CYTHON_INLINE int __Pyx_IterFinish(void);
  1213. /* UnpackItemEndCheck.proto */
  1214. static int __Pyx_IternextUnpackEndCheck(PyObject *retval, Py_ssize_t expected);
  1215. /* Import.proto */
  1216. static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, int level);
  1217. /* ImportFrom.proto */
  1218. static PyObject* __Pyx_ImportFrom(PyObject* module, PyObject* name);
  1219. /* PyObject_GenericGetAttrNoDict.proto */
  1220. #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
  1221. static CYTHON_INLINE PyObject* __Pyx_PyObject_GenericGetAttrNoDict(PyObject* obj, PyObject* attr_name);
  1222. #else
  1223. #define __Pyx_PyObject_GenericGetAttrNoDict PyObject_GenericGetAttr
  1224. #endif
  1225. /* PyObject_GenericGetAttr.proto */
  1226. #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
  1227. static PyObject* __Pyx_PyObject_GenericGetAttr(PyObject* obj, PyObject* attr_name);
  1228. #else
  1229. #define __Pyx_PyObject_GenericGetAttr PyObject_GenericGetAttr
  1230. #endif
  1231. /* SetupReduce.proto */
  1232. static int __Pyx_setup_reduce(PyObject* type_obj);
  1233. /* SetVTable.proto */
  1234. static int __Pyx_SetVtable(PyObject *dict, void *vtable);
  1235. /* CLineInTraceback.proto */
  1236. #ifdef CYTHON_CLINE_IN_TRACEBACK
  1237. #define __Pyx_CLineForTraceback(tstate, c_line) (((CYTHON_CLINE_IN_TRACEBACK)) ? c_line : 0)
  1238. #else
  1239. static int __Pyx_CLineForTraceback(PyThreadState *tstate, int c_line);
  1240. #endif
  1241. /* CodeObjectCache.proto */
  1242. typedef struct {
  1243. PyCodeObject* code_object;
  1244. int code_line;
  1245. } __Pyx_CodeObjectCacheEntry;
  1246. struct __Pyx_CodeObjectCache {
  1247. int count;
  1248. int max_count;
  1249. __Pyx_CodeObjectCacheEntry* entries;
  1250. };
  1251. static struct __Pyx_CodeObjectCache __pyx_code_cache = {0,0,NULL};
  1252. static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries, int count, int code_line);
  1253. static PyCodeObject *__pyx_find_code_object(int code_line);
  1254. static void __pyx_insert_code_object(int code_line, PyCodeObject* code_object);
  1255. /* AddTraceback.proto */
  1256. static void __Pyx_AddTraceback(const char *funcname, int c_line,
  1257. int py_line, const char *filename);
  1258. /* CIntToPy.proto */
  1259. static CYTHON_INLINE PyObject* __Pyx_PyInt_From_int(int value);
  1260. /* CIntToPy.proto */
  1261. static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(long value);
  1262. /* CIntFromPy.proto */
  1263. static CYTHON_INLINE size_t __Pyx_PyInt_As_size_t(PyObject *);
  1264. /* CIntFromPy.proto */
  1265. static CYTHON_INLINE long __Pyx_PyInt_As_long(PyObject *);
  1266. /* CIntFromPy.proto */
  1267. static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *);
  1268. /* FastTypeChecks.proto */
  1269. #if CYTHON_COMPILING_IN_CPYTHON
  1270. #define __Pyx_TypeCheck(obj, type) __Pyx_IsSubtype(Py_TYPE(obj), (PyTypeObject *)type)
  1271. static CYTHON_INLINE int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b);
  1272. static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches(PyObject *err, PyObject *type);
  1273. static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches2(PyObject *err, PyObject *type1, PyObject *type2);
  1274. #else
  1275. #define __Pyx_TypeCheck(obj, type) PyObject_TypeCheck(obj, (PyTypeObject *)type)
  1276. #define __Pyx_PyErr_GivenExceptionMatches(err, type) PyErr_GivenExceptionMatches(err, type)
  1277. #define __Pyx_PyErr_GivenExceptionMatches2(err, type1, type2) (PyErr_GivenExceptionMatches(err, type1) || PyErr_GivenExceptionMatches(err, type2))
  1278. #endif
  1279. #define __Pyx_PyException_Check(obj) __Pyx_TypeCheck(obj, PyExc_Exception)
  1280. /* CheckBinaryVersion.proto */
  1281. static int __Pyx_check_binary_version(void);
  1282. /* InitStrings.proto */
  1283. static int __Pyx_InitStrings(__Pyx_StringTabEntry *t);
  1284. static PyObject *__pyx_f_5_yaml_7CParser__parser_error(struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto*/
  1285. static PyObject *__pyx_f_5_yaml_7CParser__scan(struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto*/
  1286. static PyObject *__pyx_f_5_yaml_7CParser__token_to_object(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, yaml_token_t *__pyx_v_token); /* proto*/
  1287. static PyObject *__pyx_f_5_yaml_7CParser__parse(struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto*/
  1288. static PyObject *__pyx_f_5_yaml_7CParser__event_to_object(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, yaml_event_t *__pyx_v_event); /* proto*/
  1289. static PyObject *__pyx_f_5_yaml_7CParser__compose_document(struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto*/
  1290. static PyObject *__pyx_f_5_yaml_7CParser__compose_node(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, PyObject *__pyx_v_parent, PyObject *__pyx_v_index); /* proto*/
  1291. static PyObject *__pyx_f_5_yaml_7CParser__compose_scalar_node(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, PyObject *__pyx_v_anchor); /* proto*/
  1292. static PyObject *__pyx_f_5_yaml_7CParser__compose_sequence_node(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, PyObject *__pyx_v_anchor); /* proto*/
  1293. static PyObject *__pyx_f_5_yaml_7CParser__compose_mapping_node(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, PyObject *__pyx_v_anchor); /* proto*/
  1294. static int __pyx_f_5_yaml_7CParser__parse_next_event(struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto*/
  1295. static PyObject *__pyx_f_5_yaml_8CEmitter__emitter_error(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self); /* proto*/
  1296. static int __pyx_f_5_yaml_8CEmitter__object_to_event(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self, PyObject *__pyx_v_event_object, yaml_event_t *__pyx_v_event); /* proto*/
  1297. static int __pyx_f_5_yaml_8CEmitter__anchor_node(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self, PyObject *__pyx_v_node); /* proto*/
  1298. static int __pyx_f_5_yaml_8CEmitter__serialize_node(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self, PyObject *__pyx_v_node, PyObject *__pyx_v_parent, PyObject *__pyx_v_index); /* proto*/
  1299. /* Module declarations from '_yaml' */
  1300. static PyTypeObject *__pyx_ptype_5_yaml_Mark = 0;
  1301. static PyTypeObject *__pyx_ptype_5_yaml_CParser = 0;
  1302. static PyTypeObject *__pyx_ptype_5_yaml_CEmitter = 0;
  1303. static int __pyx_f_5_yaml_input_handler(void *, char *, size_t, size_t *); /*proto*/
  1304. static int __pyx_f_5_yaml_output_handler(void *, char *, size_t); /*proto*/
  1305. static PyObject *__pyx_f_5_yaml___pyx_unpickle_Mark__set_state(struct __pyx_obj_5_yaml_Mark *, PyObject *); /*proto*/
  1306. #define __Pyx_MODULE_NAME "_yaml"
  1307. extern int __pyx_module_is_main__yaml;
  1308. int __pyx_module_is_main__yaml = 0;
  1309. /* Implementation of '_yaml' */
  1310. static PyObject *__pyx_builtin_MemoryError;
  1311. static PyObject *__pyx_builtin_AttributeError;
  1312. static PyObject *__pyx_builtin_TypeError;
  1313. static PyObject *__pyx_builtin_ValueError;
  1314. static const char __pyx_k__3[] = "?";
  1315. static const char __pyx_k__6[] = "";
  1316. static const char __pyx_k__7[] = "'";
  1317. static const char __pyx_k__8[] = "\"";
  1318. static const char __pyx_k__9[] = "|";
  1319. static const char __pyx_k_TAG[] = "TAG";
  1320. static const char __pyx_k__10[] = ">";
  1321. static const char __pyx_k__19[] = "\r";
  1322. static const char __pyx_k__20[] = "\n";
  1323. static const char __pyx_k__21[] = "\r\n";
  1324. static const char __pyx_k_new[] = "__new__";
  1325. static const char __pyx_k_tag[] = "tag";
  1326. static const char __pyx_k_Mark[] = "Mark";
  1327. static const char __pyx_k_YAML[] = "YAML";
  1328. static const char __pyx_k_dict[] = "__dict__";
  1329. static const char __pyx_k_file[] = "<file>";
  1330. static const char __pyx_k_line[] = "line";
  1331. static const char __pyx_k_main[] = "__main__";
  1332. static const char __pyx_k_name[] = "name";
  1333. static const char __pyx_k_read[] = "read";
  1334. static const char __pyx_k_tags[] = "tags";
  1335. static const char __pyx_k_test[] = "__test__";
  1336. static const char __pyx_k_yaml[] = "yaml";
  1337. static const char __pyx_k_class[] = "__class__";
  1338. static const char __pyx_k_error[] = "error";
  1339. static const char __pyx_k_index[] = "index";
  1340. static const char __pyx_k_major[] = "major";
  1341. static const char __pyx_k_minor[] = "minor";
  1342. static const char __pyx_k_nodes[] = "nodes";
  1343. static const char __pyx_k_patch[] = "patch";
  1344. static const char __pyx_k_style[] = "style";
  1345. static const char __pyx_k_utf_8[] = "utf-8";
  1346. static const char __pyx_k_value[] = "value";
  1347. static const char __pyx_k_width[] = "width";
  1348. static const char __pyx_k_write[] = "write";
  1349. static const char __pyx_k_anchor[] = "anchor";
  1350. static const char __pyx_k_buffer[] = "buffer";
  1351. static const char __pyx_k_column[] = "column";
  1352. static const char __pyx_k_events[] = "events";
  1353. static const char __pyx_k_id_03d[] = "id%03d";
  1354. static const char __pyx_k_import[] = "__import__";
  1355. static const char __pyx_k_indent[] = "indent";
  1356. static const char __pyx_k_name_2[] = "__name__";
  1357. static const char __pyx_k_parser[] = "parser";
  1358. static const char __pyx_k_pickle[] = "pickle";
  1359. static const char __pyx_k_reader[] = "reader";
  1360. static const char __pyx_k_reduce[] = "__reduce__";
  1361. static const char __pyx_k_stream[] = "stream";
  1362. static const char __pyx_k_tokens[] = "tokens";
  1363. static const char __pyx_k_update[] = "update";
  1364. static const char __pyx_k_yaml_2[] = "_yaml";
  1365. static const char __pyx_k_CParser[] = "CParser";
  1366. static const char __pyx_k_emitter[] = "emitter";
  1367. static const char __pyx_k_pointer[] = "pointer";
  1368. static const char __pyx_k_resolve[] = "resolve";
  1369. static const char __pyx_k_scanner[] = "scanner";
  1370. static const char __pyx_k_version[] = "version";
  1371. static const char __pyx_k_CEmitter[] = "CEmitter";
  1372. static const char __pyx_k_KeyToken[] = "KeyToken";
  1373. static const char __pyx_k_TagToken[] = "TagToken";
  1374. static const char __pyx_k_composer[] = "composer";
  1375. static const char __pyx_k_encoding[] = "encoding";
  1376. static const char __pyx_k_end_mark[] = "end_mark";
  1377. static const char __pyx_k_explicit[] = "explicit";
  1378. static const char __pyx_k_getstate[] = "__getstate__";
  1379. static const char __pyx_k_implicit[] = "implicit";
  1380. static const char __pyx_k_pyx_type[] = "__pyx_type";
  1381. static const char __pyx_k_setstate[] = "__setstate__";
  1382. static const char __pyx_k_TypeError[] = "TypeError";
  1383. static const char __pyx_k_YAMLError[] = "YAMLError";
  1384. static const char __pyx_k_canonical[] = "canonical";
  1385. static const char __pyx_k_pyx_state[] = "__pyx_state";
  1386. static const char __pyx_k_reduce_ex[] = "__reduce_ex__";
  1387. static const char __pyx_k_utf_16_be[] = "utf-16-be";
  1388. static const char __pyx_k_utf_16_le[] = "utf-16-le";
  1389. static const char __pyx_k_AliasEvent[] = "AliasEvent";
  1390. static const char __pyx_k_AliasToken[] = "AliasToken";
  1391. static const char __pyx_k_ScalarNode[] = "ScalarNode";
  1392. static const char __pyx_k_ValueError[] = "ValueError";
  1393. static const char __pyx_k_ValueToken[] = "ValueToken";
  1394. static const char __pyx_k_flow_style[] = "flow_style";
  1395. static const char __pyx_k_line_break[] = "line_break";
  1396. static const char __pyx_k_pyx_result[] = "__pyx_result";
  1397. static const char __pyx_k_pyx_vtable[] = "__pyx_vtable__";
  1398. static const char __pyx_k_serializer[] = "serializer";
  1399. static const char __pyx_k_start_mark[] = "start_mark";
  1400. static const char __pyx_k_AnchorToken[] = "AnchorToken";
  1401. static const char __pyx_k_MappingNode[] = "MappingNode";
  1402. static const char __pyx_k_MemoryError[] = "MemoryError";
  1403. static const char __pyx_k_ParserError[] = "ParserError";
  1404. static const char __pyx_k_PickleError[] = "PickleError";
  1405. static const char __pyx_k_ReaderError[] = "ReaderError";
  1406. static const char __pyx_k_ScalarEvent[] = "ScalarEvent";
  1407. static const char __pyx_k_ScalarToken[] = "ScalarToken";
  1408. static const char __pyx_k_byte_string[] = "<byte string>";
  1409. static const char __pyx_k_constructor[] = "constructor";
  1410. static const char __pyx_k_get_version[] = "get_version";
  1411. static const char __pyx_k_representer[] = "representer";
  1412. static const char __pyx_k_EmitterError[] = "EmitterError";
  1413. static const char __pyx_k_ScannerError[] = "ScannerError";
  1414. static const char __pyx_k_SequenceNode[] = "SequenceNode";
  1415. static const char __pyx_k_explicit_end[] = "explicit_end";
  1416. static const char __pyx_k_pyx_checksum[] = "__pyx_checksum";
  1417. static const char __pyx_k_stringsource[] = "stringsource";
  1418. static const char __pyx_k_BlockEndToken[] = "BlockEndToken";
  1419. static const char __pyx_k_ComposerError[] = "ComposerError";
  1420. static const char __pyx_k_allow_unicode[] = "allow_unicode";
  1421. static const char __pyx_k_ext__yaml_pyx[] = "ext/_yaml.pyx";
  1422. static const char __pyx_k_reduce_cython[] = "__reduce_cython__";
  1423. static const char __pyx_k_too_many_tags[] = "too many tags";
  1424. static const char __pyx_k_AttributeError[] = "AttributeError";
  1425. static const char __pyx_k_DirectiveToken[] = "DirectiveToken";
  1426. static const char __pyx_k_FlowEntryToken[] = "FlowEntryToken";
  1427. static const char __pyx_k_StreamEndEvent[] = "StreamEndEvent";
  1428. static const char __pyx_k_StreamEndToken[] = "StreamEndToken";
  1429. static const char __pyx_k_explicit_start[] = "explicit_start";
  1430. static const char __pyx_k_unicode_string[] = "<unicode string>";
  1431. static const char __pyx_k_BlockEntryToken[] = "BlockEntryToken";
  1432. static const char __pyx_k_MappingEndEvent[] = "MappingEndEvent";
  1433. static const char __pyx_k_SerializerError[] = "SerializerError";
  1434. static const char __pyx_k_ascend_resolver[] = "ascend_resolver";
  1435. static const char __pyx_k_invalid_event_s[] = "invalid event %s";
  1436. static const char __pyx_k_no_parser_error[] = "no parser error";
  1437. static const char __pyx_k_pyx_PickleError[] = "__pyx_PickleError";
  1438. static const char __pyx_k_setstate_cython[] = "__setstate_cython__";
  1439. static const char __pyx_k_ConstructorError[] = "ConstructorError";
  1440. static const char __pyx_k_DocumentEndEvent[] = "DocumentEndEvent";
  1441. static const char __pyx_k_DocumentEndToken[] = "DocumentEndToken";
  1442. static const char __pyx_k_RepresenterError[] = "RepresenterError";
  1443. static const char __pyx_k_SequenceEndEvent[] = "SequenceEndEvent";
  1444. static const char __pyx_k_StreamStartEvent[] = "StreamStartEvent";
  1445. static const char __pyx_k_StreamStartToken[] = "StreamStartToken";
  1446. static const char __pyx_k_descend_resolver[] = "descend_resolver";
  1447. static const char __pyx_k_no_emitter_error[] = "no emitter error";
  1448. static const char __pyx_k_MappingStartEvent[] = "MappingStartEvent";
  1449. static const char __pyx_k_pyx_unpickle_Mark[] = "__pyx_unpickle_Mark";
  1450. static const char __pyx_k_second_occurrence[] = "second occurrence";
  1451. static const char __pyx_k_DocumentStartEvent[] = "DocumentStartEvent";
  1452. static const char __pyx_k_DocumentStartToken[] = "DocumentStartToken";
  1453. static const char __pyx_k_SequenceStartEvent[] = "SequenceStartEvent";
  1454. static const char __pyx_k_cline_in_traceback[] = "cline_in_traceback";
  1455. static const char __pyx_k_get_version_string[] = "get_version_string";
  1456. static const char __pyx_k_unknown_event_type[] = "unknown event type";
  1457. static const char __pyx_k_unknown_token_type[] = "unknown token type";
  1458. static const char __pyx_k_FlowMappingEndToken[] = "FlowMappingEndToken";
  1459. static const char __pyx_k_FlowSequenceEndToken[] = "FlowSequenceEndToken";
  1460. static const char __pyx_k_in_s_line_d_column_d[] = " in \"%s\", line %d, column %d";
  1461. static const char __pyx_k_serializer_is_closed[] = "serializer is closed";
  1462. static const char __pyx_k_tag_must_be_a_string[] = "tag must be a string";
  1463. static const char __pyx_k_FlowMappingStartToken[] = "FlowMappingStartToken";
  1464. static const char __pyx_k_found_undefined_alias[] = "found undefined alias";
  1465. static const char __pyx_k_BlockMappingStartToken[] = "BlockMappingStartToken";
  1466. static const char __pyx_k_FlowSequenceStartToken[] = "FlowSequenceStartToken";
  1467. static const char __pyx_k_value_must_be_a_string[] = "value must be a string";
  1468. static const char __pyx_k_BlockSequenceStartToken[] = "BlockSequenceStartToken";
  1469. static const char __pyx_k_anchor_must_be_a_string[] = "anchor must be a string";
  1470. static const char __pyx_k_serializer_is_not_opened[] = "serializer is not opened";
  1471. static const char __pyx_k_a_string_value_is_expected[] = "a string value is expected";
  1472. static const char __pyx_k_but_found_another_document[] = "but found another document";
  1473. static const char __pyx_k_tag_handle_must_be_a_string[] = "tag handle must be a string";
  1474. static const char __pyx_k_tag_prefix_must_be_a_string[] = "tag prefix must be a string";
  1475. static const char __pyx_k_serializer_is_already_opened[] = "serializer is already opened";
  1476. static const char __pyx_k_Pickling_of_struct_members_such[] = "Pickling of struct members such as self.emitter must be explicitly requested with @auto_pickle(True)";
  1477. static const char __pyx_k_Incompatible_checksums_s_vs_0x3f[] = "Incompatible checksums (%s vs 0x3fa45b6 = (buffer, column, index, line, name, pointer))";
  1478. static const char __pyx_k_a_string_or_stream_input_is_requ[] = "a string or stream input is required";
  1479. static const char __pyx_k_expected_a_single_document_in_th[] = "expected a single document in the stream";
  1480. static const char __pyx_k_found_duplicate_anchor_first_occ[] = "found duplicate anchor; first occurrence";
  1481. static const char __pyx_k_self_parsed_event_cannot_be_conv[] = "self.parsed_event cannot be converted to a Python object for pickling";
  1482. static PyObject *__pyx_n_s_AliasEvent;
  1483. static PyObject *__pyx_n_s_AliasToken;
  1484. static PyObject *__pyx_n_s_AnchorToken;
  1485. static PyObject *__pyx_n_s_AttributeError;
  1486. static PyObject *__pyx_n_s_BlockEndToken;
  1487. static PyObject *__pyx_n_s_BlockEntryToken;
  1488. static PyObject *__pyx_n_s_BlockMappingStartToken;
  1489. static PyObject *__pyx_n_s_BlockSequenceStartToken;
  1490. static PyObject *__pyx_n_s_CEmitter;
  1491. static PyObject *__pyx_n_s_CParser;
  1492. static PyObject *__pyx_n_s_ComposerError;
  1493. static PyObject *__pyx_n_s_ConstructorError;
  1494. static PyObject *__pyx_n_s_DirectiveToken;
  1495. static PyObject *__pyx_n_s_DocumentEndEvent;
  1496. static PyObject *__pyx_n_s_DocumentEndToken;
  1497. static PyObject *__pyx_n_s_DocumentStartEvent;
  1498. static PyObject *__pyx_n_s_DocumentStartToken;
  1499. static PyObject *__pyx_n_s_EmitterError;
  1500. static PyObject *__pyx_n_s_FlowEntryToken;
  1501. static PyObject *__pyx_n_s_FlowMappingEndToken;
  1502. static PyObject *__pyx_n_s_FlowMappingStartToken;
  1503. static PyObject *__pyx_n_s_FlowSequenceEndToken;
  1504. static PyObject *__pyx_n_s_FlowSequenceStartToken;
  1505. static PyObject *__pyx_kp_s_Incompatible_checksums_s_vs_0x3f;
  1506. static PyObject *__pyx_n_s_KeyToken;
  1507. static PyObject *__pyx_n_s_MappingEndEvent;
  1508. static PyObject *__pyx_n_s_MappingNode;
  1509. static PyObject *__pyx_n_s_MappingStartEvent;
  1510. static PyObject *__pyx_n_s_Mark;
  1511. static PyObject *__pyx_n_s_MemoryError;
  1512. static PyObject *__pyx_n_s_ParserError;
  1513. static PyObject *__pyx_n_s_PickleError;
  1514. static PyObject *__pyx_kp_s_Pickling_of_struct_members_such;
  1515. static PyObject *__pyx_n_s_ReaderError;
  1516. static PyObject *__pyx_n_s_RepresenterError;
  1517. static PyObject *__pyx_n_s_ScalarEvent;
  1518. static PyObject *__pyx_n_s_ScalarNode;
  1519. static PyObject *__pyx_n_s_ScalarToken;
  1520. static PyObject *__pyx_n_s_ScannerError;
  1521. static PyObject *__pyx_n_s_SequenceEndEvent;
  1522. static PyObject *__pyx_n_s_SequenceNode;
  1523. static PyObject *__pyx_n_s_SequenceStartEvent;
  1524. static PyObject *__pyx_n_s_SerializerError;
  1525. static PyObject *__pyx_n_s_StreamEndEvent;
  1526. static PyObject *__pyx_n_s_StreamEndToken;
  1527. static PyObject *__pyx_n_s_StreamStartEvent;
  1528. static PyObject *__pyx_n_s_StreamStartToken;
  1529. static PyObject *__pyx_n_u_TAG;
  1530. static PyObject *__pyx_n_s_TagToken;
  1531. static PyObject *__pyx_n_s_TypeError;
  1532. static PyObject *__pyx_n_s_ValueError;
  1533. static PyObject *__pyx_n_s_ValueToken;
  1534. static PyObject *__pyx_n_u_YAML;
  1535. static PyObject *__pyx_n_s_YAMLError;
  1536. static PyObject *__pyx_kp_s__10;
  1537. static PyObject *__pyx_kp_u__10;
  1538. static PyObject *__pyx_kp_s__19;
  1539. static PyObject *__pyx_kp_s__20;
  1540. static PyObject *__pyx_kp_s__21;
  1541. static PyObject *__pyx_kp_s__3;
  1542. static PyObject *__pyx_kp_u__3;
  1543. static PyObject *__pyx_kp_u__6;
  1544. static PyObject *__pyx_kp_s__7;
  1545. static PyObject *__pyx_kp_u__7;
  1546. static PyObject *__pyx_kp_s__8;
  1547. static PyObject *__pyx_kp_u__8;
  1548. static PyObject *__pyx_kp_s__9;
  1549. static PyObject *__pyx_kp_u__9;
  1550. static PyObject *__pyx_kp_s_a_string_or_stream_input_is_requ;
  1551. static PyObject *__pyx_kp_u_a_string_or_stream_input_is_requ;
  1552. static PyObject *__pyx_kp_s_a_string_value_is_expected;
  1553. static PyObject *__pyx_kp_u_a_string_value_is_expected;
  1554. static PyObject *__pyx_n_s_allow_unicode;
  1555. static PyObject *__pyx_n_s_anchor;
  1556. static PyObject *__pyx_kp_s_anchor_must_be_a_string;
  1557. static PyObject *__pyx_kp_u_anchor_must_be_a_string;
  1558. static PyObject *__pyx_n_s_ascend_resolver;
  1559. static PyObject *__pyx_n_s_buffer;
  1560. static PyObject *__pyx_kp_s_but_found_another_document;
  1561. static PyObject *__pyx_kp_u_but_found_another_document;
  1562. static PyObject *__pyx_kp_s_byte_string;
  1563. static PyObject *__pyx_kp_u_byte_string;
  1564. static PyObject *__pyx_n_s_canonical;
  1565. static PyObject *__pyx_n_s_class;
  1566. static PyObject *__pyx_n_s_cline_in_traceback;
  1567. static PyObject *__pyx_n_s_column;
  1568. static PyObject *__pyx_n_s_composer;
  1569. static PyObject *__pyx_n_s_constructor;
  1570. static PyObject *__pyx_n_s_descend_resolver;
  1571. static PyObject *__pyx_n_s_dict;
  1572. static PyObject *__pyx_n_s_emitter;
  1573. static PyObject *__pyx_n_s_encoding;
  1574. static PyObject *__pyx_n_u_encoding;
  1575. static PyObject *__pyx_n_s_end_mark;
  1576. static PyObject *__pyx_n_s_error;
  1577. static PyObject *__pyx_n_s_events;
  1578. static PyObject *__pyx_kp_s_expected_a_single_document_in_th;
  1579. static PyObject *__pyx_kp_u_expected_a_single_document_in_th;
  1580. static PyObject *__pyx_n_s_explicit;
  1581. static PyObject *__pyx_n_s_explicit_end;
  1582. static PyObject *__pyx_n_s_explicit_start;
  1583. static PyObject *__pyx_kp_s_ext__yaml_pyx;
  1584. static PyObject *__pyx_kp_s_file;
  1585. static PyObject *__pyx_kp_u_file;
  1586. static PyObject *__pyx_n_s_flow_style;
  1587. static PyObject *__pyx_kp_s_found_duplicate_anchor_first_occ;
  1588. static PyObject *__pyx_kp_u_found_duplicate_anchor_first_occ;
  1589. static PyObject *__pyx_kp_s_found_undefined_alias;
  1590. static PyObject *__pyx_kp_u_found_undefined_alias;
  1591. static PyObject *__pyx_n_s_get_version;
  1592. static PyObject *__pyx_n_s_get_version_string;
  1593. static PyObject *__pyx_n_s_getstate;
  1594. static PyObject *__pyx_kp_u_id_03d;
  1595. static PyObject *__pyx_n_s_implicit;
  1596. static PyObject *__pyx_n_s_import;
  1597. static PyObject *__pyx_kp_s_in_s_line_d_column_d;
  1598. static PyObject *__pyx_n_s_indent;
  1599. static PyObject *__pyx_n_s_index;
  1600. static PyObject *__pyx_kp_s_invalid_event_s;
  1601. static PyObject *__pyx_kp_u_invalid_event_s;
  1602. static PyObject *__pyx_n_s_line;
  1603. static PyObject *__pyx_n_s_line_break;
  1604. static PyObject *__pyx_n_s_main;
  1605. static PyObject *__pyx_n_s_major;
  1606. static PyObject *__pyx_n_s_minor;
  1607. static PyObject *__pyx_n_s_name;
  1608. static PyObject *__pyx_n_s_name_2;
  1609. static PyObject *__pyx_n_s_new;
  1610. static PyObject *__pyx_kp_s_no_emitter_error;
  1611. static PyObject *__pyx_kp_u_no_emitter_error;
  1612. static PyObject *__pyx_kp_s_no_parser_error;
  1613. static PyObject *__pyx_kp_u_no_parser_error;
  1614. static PyObject *__pyx_n_s_nodes;
  1615. static PyObject *__pyx_n_s_parser;
  1616. static PyObject *__pyx_n_s_patch;
  1617. static PyObject *__pyx_n_s_pickle;
  1618. static PyObject *__pyx_n_s_pointer;
  1619. static PyObject *__pyx_n_s_pyx_PickleError;
  1620. static PyObject *__pyx_n_s_pyx_checksum;
  1621. static PyObject *__pyx_n_s_pyx_result;
  1622. static PyObject *__pyx_n_s_pyx_state;
  1623. static PyObject *__pyx_n_s_pyx_type;
  1624. static PyObject *__pyx_n_s_pyx_unpickle_Mark;
  1625. static PyObject *__pyx_n_s_pyx_vtable;
  1626. static PyObject *__pyx_n_s_read;
  1627. static PyObject *__pyx_n_s_reader;
  1628. static PyObject *__pyx_n_s_reduce;
  1629. static PyObject *__pyx_n_s_reduce_cython;
  1630. static PyObject *__pyx_n_s_reduce_ex;
  1631. static PyObject *__pyx_n_s_representer;
  1632. static PyObject *__pyx_n_s_resolve;
  1633. static PyObject *__pyx_n_s_scanner;
  1634. static PyObject *__pyx_kp_s_second_occurrence;
  1635. static PyObject *__pyx_kp_u_second_occurrence;
  1636. static PyObject *__pyx_kp_s_self_parsed_event_cannot_be_conv;
  1637. static PyObject *__pyx_n_s_serializer;
  1638. static PyObject *__pyx_kp_s_serializer_is_already_opened;
  1639. static PyObject *__pyx_kp_u_serializer_is_already_opened;
  1640. static PyObject *__pyx_kp_s_serializer_is_closed;
  1641. static PyObject *__pyx_kp_u_serializer_is_closed;
  1642. static PyObject *__pyx_kp_s_serializer_is_not_opened;
  1643. static PyObject *__pyx_kp_u_serializer_is_not_opened;
  1644. static PyObject *__pyx_n_s_setstate;
  1645. static PyObject *__pyx_n_s_setstate_cython;
  1646. static PyObject *__pyx_n_s_start_mark;
  1647. static PyObject *__pyx_n_s_stream;
  1648. static PyObject *__pyx_kp_s_stringsource;
  1649. static PyObject *__pyx_n_s_style;
  1650. static PyObject *__pyx_n_s_tag;
  1651. static PyObject *__pyx_kp_s_tag_handle_must_be_a_string;
  1652. static PyObject *__pyx_kp_u_tag_handle_must_be_a_string;
  1653. static PyObject *__pyx_kp_s_tag_must_be_a_string;
  1654. static PyObject *__pyx_kp_u_tag_must_be_a_string;
  1655. static PyObject *__pyx_kp_s_tag_prefix_must_be_a_string;
  1656. static PyObject *__pyx_kp_u_tag_prefix_must_be_a_string;
  1657. static PyObject *__pyx_n_s_tags;
  1658. static PyObject *__pyx_n_s_test;
  1659. static PyObject *__pyx_n_s_tokens;
  1660. static PyObject *__pyx_kp_s_too_many_tags;
  1661. static PyObject *__pyx_kp_u_too_many_tags;
  1662. static PyObject *__pyx_kp_s_unicode_string;
  1663. static PyObject *__pyx_kp_u_unicode_string;
  1664. static PyObject *__pyx_kp_s_unknown_event_type;
  1665. static PyObject *__pyx_kp_u_unknown_event_type;
  1666. static PyObject *__pyx_kp_s_unknown_token_type;
  1667. static PyObject *__pyx_kp_u_unknown_token_type;
  1668. static PyObject *__pyx_n_s_update;
  1669. static PyObject *__pyx_kp_s_utf_16_be;
  1670. static PyObject *__pyx_kp_u_utf_16_be;
  1671. static PyObject *__pyx_kp_s_utf_16_le;
  1672. static PyObject *__pyx_kp_u_utf_16_le;
  1673. static PyObject *__pyx_kp_u_utf_8;
  1674. static PyObject *__pyx_n_s_value;
  1675. static PyObject *__pyx_kp_s_value_must_be_a_string;
  1676. static PyObject *__pyx_kp_u_value_must_be_a_string;
  1677. static PyObject *__pyx_n_s_version;
  1678. static PyObject *__pyx_n_s_width;
  1679. static PyObject *__pyx_n_s_write;
  1680. static PyObject *__pyx_n_s_yaml;
  1681. static PyObject *__pyx_n_s_yaml_2;
  1682. static PyObject *__pyx_pf_5_yaml_get_version_string(CYTHON_UNUSED PyObject *__pyx_self); /* proto */
  1683. static PyObject *__pyx_pf_5_yaml_2get_version(CYTHON_UNUSED PyObject *__pyx_self); /* proto */
  1684. static int __pyx_pf_5_yaml_4Mark___init__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self, PyObject *__pyx_v_name, size_t __pyx_v_index, size_t __pyx_v_line, size_t __pyx_v_column, PyObject *__pyx_v_buffer, PyObject *__pyx_v_pointer); /* proto */
  1685. static PyObject *__pyx_pf_5_yaml_4Mark_2get_snippet(CYTHON_UNUSED struct __pyx_obj_5_yaml_Mark *__pyx_v_self); /* proto */
  1686. static PyObject *__pyx_pf_5_yaml_4Mark_4__str__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self); /* proto */
  1687. static PyObject *__pyx_pf_5_yaml_4Mark_4name___get__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self); /* proto */
  1688. static PyObject *__pyx_pf_5_yaml_4Mark_5index___get__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self); /* proto */
  1689. static PyObject *__pyx_pf_5_yaml_4Mark_4line___get__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self); /* proto */
  1690. static PyObject *__pyx_pf_5_yaml_4Mark_6column___get__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self); /* proto */
  1691. static PyObject *__pyx_pf_5_yaml_4Mark_6buffer___get__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self); /* proto */
  1692. static PyObject *__pyx_pf_5_yaml_4Mark_7pointer___get__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self); /* proto */
  1693. static PyObject *__pyx_pf_5_yaml_4Mark_6__reduce_cython__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self); /* proto */
  1694. static PyObject *__pyx_pf_5_yaml_4Mark_8__setstate_cython__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self, PyObject *__pyx_v___pyx_state); /* proto */
  1695. static int __pyx_pf_5_yaml_7CParser___init__(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, PyObject *__pyx_v_stream); /* proto */
  1696. static void __pyx_pf_5_yaml_7CParser_2__dealloc__(struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto */
  1697. static PyObject *__pyx_pf_5_yaml_7CParser_4dispose(CYTHON_UNUSED struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto */
  1698. static PyObject *__pyx_pf_5_yaml_7CParser_6raw_scan(struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto */
  1699. static PyObject *__pyx_pf_5_yaml_7CParser_8get_token(struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto */
  1700. static PyObject *__pyx_pf_5_yaml_7CParser_10peek_token(struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto */
  1701. static PyObject *__pyx_pf_5_yaml_7CParser_12check_token(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, PyObject *__pyx_v_choices); /* proto */
  1702. static PyObject *__pyx_pf_5_yaml_7CParser_14raw_parse(struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto */
  1703. static PyObject *__pyx_pf_5_yaml_7CParser_16get_event(struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto */
  1704. static PyObject *__pyx_pf_5_yaml_7CParser_18peek_event(struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto */
  1705. static PyObject *__pyx_pf_5_yaml_7CParser_20check_event(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, PyObject *__pyx_v_choices); /* proto */
  1706. static PyObject *__pyx_pf_5_yaml_7CParser_22check_node(struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto */
  1707. static PyObject *__pyx_pf_5_yaml_7CParser_24get_node(struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto */
  1708. static PyObject *__pyx_pf_5_yaml_7CParser_26get_single_node(struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto */
  1709. static PyObject *__pyx_pf_5_yaml_7CParser_28__reduce_cython__(CYTHON_UNUSED struct __pyx_obj_5_yaml_CParser *__pyx_v_self); /* proto */
  1710. static PyObject *__pyx_pf_5_yaml_7CParser_30__setstate_cython__(CYTHON_UNUSED struct __pyx_obj_5_yaml_CParser *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state); /* proto */
  1711. static int __pyx_pf_5_yaml_8CEmitter___init__(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self, PyObject *__pyx_v_stream, PyObject *__pyx_v_canonical, PyObject *__pyx_v_indent, PyObject *__pyx_v_width, PyObject *__pyx_v_allow_unicode, PyObject *__pyx_v_line_break, PyObject *__pyx_v_encoding, PyObject *__pyx_v_explicit_start, PyObject *__pyx_v_explicit_end, PyObject *__pyx_v_version, PyObject *__pyx_v_tags); /* proto */
  1712. static void __pyx_pf_5_yaml_8CEmitter_2__dealloc__(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self); /* proto */
  1713. static PyObject *__pyx_pf_5_yaml_8CEmitter_4dispose(CYTHON_UNUSED struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self); /* proto */
  1714. static PyObject *__pyx_pf_5_yaml_8CEmitter_6emit(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self, PyObject *__pyx_v_event_object); /* proto */
  1715. static PyObject *__pyx_pf_5_yaml_8CEmitter_8open(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self); /* proto */
  1716. static PyObject *__pyx_pf_5_yaml_8CEmitter_10close(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self); /* proto */
  1717. static PyObject *__pyx_pf_5_yaml_8CEmitter_12serialize(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self, PyObject *__pyx_v_node); /* proto */
  1718. static PyObject *__pyx_pf_5_yaml_8CEmitter_14__reduce_cython__(CYTHON_UNUSED struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self); /* proto */
  1719. static PyObject *__pyx_pf_5_yaml_8CEmitter_16__setstate_cython__(CYTHON_UNUSED struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state); /* proto */
  1720. static PyObject *__pyx_pf_5_yaml_4__pyx_unpickle_Mark(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state); /* proto */
  1721. static PyObject *__pyx_tp_new_5_yaml_Mark(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/
  1722. static PyObject *__pyx_tp_new_5_yaml_CParser(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/
  1723. static PyObject *__pyx_tp_new_5_yaml_CEmitter(PyTypeObject *t, PyObject *a, PyObject *k); /*proto*/
  1724. static PyObject *__pyx_int_0;
  1725. static PyObject *__pyx_int_1;
  1726. static PyObject *__pyx_int_66733494;
  1727. static PyObject *__pyx_tuple_;
  1728. static PyObject *__pyx_tuple__2;
  1729. static PyObject *__pyx_tuple__4;
  1730. static PyObject *__pyx_tuple__5;
  1731. static PyObject *__pyx_tuple__11;
  1732. static PyObject *__pyx_tuple__12;
  1733. static PyObject *__pyx_tuple__13;
  1734. static PyObject *__pyx_tuple__14;
  1735. static PyObject *__pyx_tuple__15;
  1736. static PyObject *__pyx_tuple__16;
  1737. static PyObject *__pyx_tuple__17;
  1738. static PyObject *__pyx_tuple__18;
  1739. static PyObject *__pyx_tuple__22;
  1740. static PyObject *__pyx_tuple__23;
  1741. static PyObject *__pyx_tuple__24;
  1742. static PyObject *__pyx_tuple__25;
  1743. static PyObject *__pyx_tuple__26;
  1744. static PyObject *__pyx_tuple__27;
  1745. static PyObject *__pyx_tuple__28;
  1746. static PyObject *__pyx_tuple__29;
  1747. static PyObject *__pyx_tuple__30;
  1748. static PyObject *__pyx_tuple__31;
  1749. static PyObject *__pyx_tuple__32;
  1750. static PyObject *__pyx_tuple__33;
  1751. static PyObject *__pyx_tuple__34;
  1752. static PyObject *__pyx_tuple__35;
  1753. static PyObject *__pyx_tuple__36;
  1754. static PyObject *__pyx_tuple__37;
  1755. static PyObject *__pyx_tuple__38;
  1756. static PyObject *__pyx_tuple__39;
  1757. static PyObject *__pyx_tuple__40;
  1758. static PyObject *__pyx_tuple__42;
  1759. static PyObject *__pyx_tuple__44;
  1760. static PyObject *__pyx_codeobj__41;
  1761. static PyObject *__pyx_codeobj__43;
  1762. static PyObject *__pyx_codeobj__45;
  1763. /* Late includes */
  1764. /* "_yaml.pyx":4
  1765. * import yaml
  1766. *
  1767. * def get_version_string(): # <<<<<<<<<<<<<<
  1768. * cdef char *value
  1769. * value = yaml_get_version_string()
  1770. */
  1771. /* Python wrapper */
  1772. static PyObject *__pyx_pw_5_yaml_1get_version_string(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  1773. static PyMethodDef __pyx_mdef_5_yaml_1get_version_string = {"get_version_string", (PyCFunction)__pyx_pw_5_yaml_1get_version_string, METH_NOARGS, 0};
  1774. static PyObject *__pyx_pw_5_yaml_1get_version_string(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused) {
  1775. PyObject *__pyx_r = 0;
  1776. __Pyx_RefNannyDeclarations
  1777. __Pyx_RefNannySetupContext("get_version_string (wrapper)", 0);
  1778. __pyx_r = __pyx_pf_5_yaml_get_version_string(__pyx_self);
  1779. /* function exit code */
  1780. __Pyx_RefNannyFinishContext();
  1781. return __pyx_r;
  1782. }
  1783. static PyObject *__pyx_pf_5_yaml_get_version_string(CYTHON_UNUSED PyObject *__pyx_self) {
  1784. char *__pyx_v_value;
  1785. PyObject *__pyx_r = NULL;
  1786. __Pyx_RefNannyDeclarations
  1787. int __pyx_t_1;
  1788. PyObject *__pyx_t_2 = NULL;
  1789. __Pyx_RefNannySetupContext("get_version_string", 0);
  1790. /* "_yaml.pyx":6
  1791. * def get_version_string():
  1792. * cdef char *value
  1793. * value = yaml_get_version_string() # <<<<<<<<<<<<<<
  1794. * if PY_MAJOR_VERSION < 3:
  1795. * return value
  1796. */
  1797. __pyx_v_value = yaml_get_version_string();
  1798. /* "_yaml.pyx":7
  1799. * cdef char *value
  1800. * value = yaml_get_version_string()
  1801. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  1802. * return value
  1803. * else:
  1804. */
  1805. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  1806. if (__pyx_t_1) {
  1807. /* "_yaml.pyx":8
  1808. * value = yaml_get_version_string()
  1809. * if PY_MAJOR_VERSION < 3:
  1810. * return value # <<<<<<<<<<<<<<
  1811. * else:
  1812. * return PyUnicode_FromString(value)
  1813. */
  1814. __Pyx_XDECREF(__pyx_r);
  1815. __pyx_t_2 = __Pyx_PyBytes_FromString(__pyx_v_value); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 8, __pyx_L1_error)
  1816. __Pyx_GOTREF(__pyx_t_2);
  1817. __pyx_r = __pyx_t_2;
  1818. __pyx_t_2 = 0;
  1819. goto __pyx_L0;
  1820. /* "_yaml.pyx":7
  1821. * cdef char *value
  1822. * value = yaml_get_version_string()
  1823. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  1824. * return value
  1825. * else:
  1826. */
  1827. }
  1828. /* "_yaml.pyx":10
  1829. * return value
  1830. * else:
  1831. * return PyUnicode_FromString(value) # <<<<<<<<<<<<<<
  1832. *
  1833. * def get_version():
  1834. */
  1835. /*else*/ {
  1836. __Pyx_XDECREF(__pyx_r);
  1837. __pyx_t_2 = PyUnicode_FromString(__pyx_v_value); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 10, __pyx_L1_error)
  1838. __Pyx_GOTREF(__pyx_t_2);
  1839. __pyx_r = __pyx_t_2;
  1840. __pyx_t_2 = 0;
  1841. goto __pyx_L0;
  1842. }
  1843. /* "_yaml.pyx":4
  1844. * import yaml
  1845. *
  1846. * def get_version_string(): # <<<<<<<<<<<<<<
  1847. * cdef char *value
  1848. * value = yaml_get_version_string()
  1849. */
  1850. /* function exit code */
  1851. __pyx_L1_error:;
  1852. __Pyx_XDECREF(__pyx_t_2);
  1853. __Pyx_AddTraceback("_yaml.get_version_string", __pyx_clineno, __pyx_lineno, __pyx_filename);
  1854. __pyx_r = NULL;
  1855. __pyx_L0:;
  1856. __Pyx_XGIVEREF(__pyx_r);
  1857. __Pyx_RefNannyFinishContext();
  1858. return __pyx_r;
  1859. }
  1860. /* "_yaml.pyx":12
  1861. * return PyUnicode_FromString(value)
  1862. *
  1863. * def get_version(): # <<<<<<<<<<<<<<
  1864. * cdef int major, minor, patch
  1865. * yaml_get_version(&major, &minor, &patch)
  1866. */
  1867. /* Python wrapper */
  1868. static PyObject *__pyx_pw_5_yaml_3get_version(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  1869. static PyMethodDef __pyx_mdef_5_yaml_3get_version = {"get_version", (PyCFunction)__pyx_pw_5_yaml_3get_version, METH_NOARGS, 0};
  1870. static PyObject *__pyx_pw_5_yaml_3get_version(PyObject *__pyx_self, CYTHON_UNUSED PyObject *unused) {
  1871. PyObject *__pyx_r = 0;
  1872. __Pyx_RefNannyDeclarations
  1873. __Pyx_RefNannySetupContext("get_version (wrapper)", 0);
  1874. __pyx_r = __pyx_pf_5_yaml_2get_version(__pyx_self);
  1875. /* function exit code */
  1876. __Pyx_RefNannyFinishContext();
  1877. return __pyx_r;
  1878. }
  1879. static PyObject *__pyx_pf_5_yaml_2get_version(CYTHON_UNUSED PyObject *__pyx_self) {
  1880. int __pyx_v_major;
  1881. int __pyx_v_minor;
  1882. int __pyx_v_patch;
  1883. PyObject *__pyx_r = NULL;
  1884. __Pyx_RefNannyDeclarations
  1885. PyObject *__pyx_t_1 = NULL;
  1886. PyObject *__pyx_t_2 = NULL;
  1887. PyObject *__pyx_t_3 = NULL;
  1888. PyObject *__pyx_t_4 = NULL;
  1889. __Pyx_RefNannySetupContext("get_version", 0);
  1890. /* "_yaml.pyx":14
  1891. * def get_version():
  1892. * cdef int major, minor, patch
  1893. * yaml_get_version(&major, &minor, &patch) # <<<<<<<<<<<<<<
  1894. * return (major, minor, patch)
  1895. *
  1896. */
  1897. yaml_get_version((&__pyx_v_major), (&__pyx_v_minor), (&__pyx_v_patch));
  1898. /* "_yaml.pyx":15
  1899. * cdef int major, minor, patch
  1900. * yaml_get_version(&major, &minor, &patch)
  1901. * return (major, minor, patch) # <<<<<<<<<<<<<<
  1902. *
  1903. * #Mark = yaml.error.Mark
  1904. */
  1905. __Pyx_XDECREF(__pyx_r);
  1906. __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_major); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 15, __pyx_L1_error)
  1907. __Pyx_GOTREF(__pyx_t_1);
  1908. __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_minor); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 15, __pyx_L1_error)
  1909. __Pyx_GOTREF(__pyx_t_2);
  1910. __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_patch); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 15, __pyx_L1_error)
  1911. __Pyx_GOTREF(__pyx_t_3);
  1912. __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 15, __pyx_L1_error)
  1913. __Pyx_GOTREF(__pyx_t_4);
  1914. __Pyx_GIVEREF(__pyx_t_1);
  1915. PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_1);
  1916. __Pyx_GIVEREF(__pyx_t_2);
  1917. PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_2);
  1918. __Pyx_GIVEREF(__pyx_t_3);
  1919. PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_3);
  1920. __pyx_t_1 = 0;
  1921. __pyx_t_2 = 0;
  1922. __pyx_t_3 = 0;
  1923. __pyx_r = __pyx_t_4;
  1924. __pyx_t_4 = 0;
  1925. goto __pyx_L0;
  1926. /* "_yaml.pyx":12
  1927. * return PyUnicode_FromString(value)
  1928. *
  1929. * def get_version(): # <<<<<<<<<<<<<<
  1930. * cdef int major, minor, patch
  1931. * yaml_get_version(&major, &minor, &patch)
  1932. */
  1933. /* function exit code */
  1934. __pyx_L1_error:;
  1935. __Pyx_XDECREF(__pyx_t_1);
  1936. __Pyx_XDECREF(__pyx_t_2);
  1937. __Pyx_XDECREF(__pyx_t_3);
  1938. __Pyx_XDECREF(__pyx_t_4);
  1939. __Pyx_AddTraceback("_yaml.get_version", __pyx_clineno, __pyx_lineno, __pyx_filename);
  1940. __pyx_r = NULL;
  1941. __pyx_L0:;
  1942. __Pyx_XGIVEREF(__pyx_r);
  1943. __Pyx_RefNannyFinishContext();
  1944. return __pyx_r;
  1945. }
  1946. /* "_yaml.pyx":72
  1947. * cdef readonly pointer
  1948. *
  1949. * def __init__(self, object name, size_t index, size_t line, size_t column, # <<<<<<<<<<<<<<
  1950. * object buffer, object pointer):
  1951. * self.name = name
  1952. */
  1953. /* Python wrapper */
  1954. static int __pyx_pw_5_yaml_4Mark_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
  1955. static int __pyx_pw_5_yaml_4Mark_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  1956. PyObject *__pyx_v_name = 0;
  1957. size_t __pyx_v_index;
  1958. size_t __pyx_v_line;
  1959. size_t __pyx_v_column;
  1960. PyObject *__pyx_v_buffer = 0;
  1961. PyObject *__pyx_v_pointer = 0;
  1962. int __pyx_r;
  1963. __Pyx_RefNannyDeclarations
  1964. __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  1965. {
  1966. static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_name,&__pyx_n_s_index,&__pyx_n_s_line,&__pyx_n_s_column,&__pyx_n_s_buffer,&__pyx_n_s_pointer,0};
  1967. PyObject* values[6] = {0,0,0,0,0,0};
  1968. if (unlikely(__pyx_kwds)) {
  1969. Py_ssize_t kw_args;
  1970. const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
  1971. switch (pos_args) {
  1972. case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
  1973. CYTHON_FALLTHROUGH;
  1974. case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
  1975. CYTHON_FALLTHROUGH;
  1976. case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
  1977. CYTHON_FALLTHROUGH;
  1978. case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
  1979. CYTHON_FALLTHROUGH;
  1980. case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
  1981. CYTHON_FALLTHROUGH;
  1982. case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
  1983. CYTHON_FALLTHROUGH;
  1984. case 0: break;
  1985. default: goto __pyx_L5_argtuple_error;
  1986. }
  1987. kw_args = PyDict_Size(__pyx_kwds);
  1988. switch (pos_args) {
  1989. case 0:
  1990. if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_name)) != 0)) kw_args--;
  1991. else goto __pyx_L5_argtuple_error;
  1992. CYTHON_FALLTHROUGH;
  1993. case 1:
  1994. if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_index)) != 0)) kw_args--;
  1995. else {
  1996. __Pyx_RaiseArgtupleInvalid("__init__", 1, 6, 6, 1); __PYX_ERR(0, 72, __pyx_L3_error)
  1997. }
  1998. CYTHON_FALLTHROUGH;
  1999. case 2:
  2000. if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_line)) != 0)) kw_args--;
  2001. else {
  2002. __Pyx_RaiseArgtupleInvalid("__init__", 1, 6, 6, 2); __PYX_ERR(0, 72, __pyx_L3_error)
  2003. }
  2004. CYTHON_FALLTHROUGH;
  2005. case 3:
  2006. if (likely((values[3] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_column)) != 0)) kw_args--;
  2007. else {
  2008. __Pyx_RaiseArgtupleInvalid("__init__", 1, 6, 6, 3); __PYX_ERR(0, 72, __pyx_L3_error)
  2009. }
  2010. CYTHON_FALLTHROUGH;
  2011. case 4:
  2012. if (likely((values[4] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_buffer)) != 0)) kw_args--;
  2013. else {
  2014. __Pyx_RaiseArgtupleInvalid("__init__", 1, 6, 6, 4); __PYX_ERR(0, 72, __pyx_L3_error)
  2015. }
  2016. CYTHON_FALLTHROUGH;
  2017. case 5:
  2018. if (likely((values[5] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pointer)) != 0)) kw_args--;
  2019. else {
  2020. __Pyx_RaiseArgtupleInvalid("__init__", 1, 6, 6, 5); __PYX_ERR(0, 72, __pyx_L3_error)
  2021. }
  2022. }
  2023. if (unlikely(kw_args > 0)) {
  2024. if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(0, 72, __pyx_L3_error)
  2025. }
  2026. } else if (PyTuple_GET_SIZE(__pyx_args) != 6) {
  2027. goto __pyx_L5_argtuple_error;
  2028. } else {
  2029. values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
  2030. values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
  2031. values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
  2032. values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
  2033. values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
  2034. values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
  2035. }
  2036. __pyx_v_name = values[0];
  2037. __pyx_v_index = __Pyx_PyInt_As_size_t(values[1]); if (unlikely((__pyx_v_index == (size_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 72, __pyx_L3_error)
  2038. __pyx_v_line = __Pyx_PyInt_As_size_t(values[2]); if (unlikely((__pyx_v_line == (size_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 72, __pyx_L3_error)
  2039. __pyx_v_column = __Pyx_PyInt_As_size_t(values[3]); if (unlikely((__pyx_v_column == (size_t)-1) && PyErr_Occurred())) __PYX_ERR(0, 72, __pyx_L3_error)
  2040. __pyx_v_buffer = values[4];
  2041. __pyx_v_pointer = values[5];
  2042. }
  2043. goto __pyx_L4_argument_unpacking_done;
  2044. __pyx_L5_argtuple_error:;
  2045. __Pyx_RaiseArgtupleInvalid("__init__", 1, 6, 6, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 72, __pyx_L3_error)
  2046. __pyx_L3_error:;
  2047. __Pyx_AddTraceback("_yaml.Mark.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  2048. __Pyx_RefNannyFinishContext();
  2049. return -1;
  2050. __pyx_L4_argument_unpacking_done:;
  2051. __pyx_r = __pyx_pf_5_yaml_4Mark___init__(((struct __pyx_obj_5_yaml_Mark *)__pyx_v_self), __pyx_v_name, __pyx_v_index, __pyx_v_line, __pyx_v_column, __pyx_v_buffer, __pyx_v_pointer);
  2052. /* function exit code */
  2053. __Pyx_RefNannyFinishContext();
  2054. return __pyx_r;
  2055. }
  2056. static int __pyx_pf_5_yaml_4Mark___init__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self, PyObject *__pyx_v_name, size_t __pyx_v_index, size_t __pyx_v_line, size_t __pyx_v_column, PyObject *__pyx_v_buffer, PyObject *__pyx_v_pointer) {
  2057. int __pyx_r;
  2058. __Pyx_RefNannyDeclarations
  2059. __Pyx_RefNannySetupContext("__init__", 0);
  2060. /* "_yaml.pyx":74
  2061. * def __init__(self, object name, size_t index, size_t line, size_t column,
  2062. * object buffer, object pointer):
  2063. * self.name = name # <<<<<<<<<<<<<<
  2064. * self.index = index
  2065. * self.line = line
  2066. */
  2067. __Pyx_INCREF(__pyx_v_name);
  2068. __Pyx_GIVEREF(__pyx_v_name);
  2069. __Pyx_GOTREF(__pyx_v_self->name);
  2070. __Pyx_DECREF(__pyx_v_self->name);
  2071. __pyx_v_self->name = __pyx_v_name;
  2072. /* "_yaml.pyx":75
  2073. * object buffer, object pointer):
  2074. * self.name = name
  2075. * self.index = index # <<<<<<<<<<<<<<
  2076. * self.line = line
  2077. * self.column = column
  2078. */
  2079. __pyx_v_self->index = __pyx_v_index;
  2080. /* "_yaml.pyx":76
  2081. * self.name = name
  2082. * self.index = index
  2083. * self.line = line # <<<<<<<<<<<<<<
  2084. * self.column = column
  2085. * self.buffer = buffer
  2086. */
  2087. __pyx_v_self->line = __pyx_v_line;
  2088. /* "_yaml.pyx":77
  2089. * self.index = index
  2090. * self.line = line
  2091. * self.column = column # <<<<<<<<<<<<<<
  2092. * self.buffer = buffer
  2093. * self.pointer = pointer
  2094. */
  2095. __pyx_v_self->column = __pyx_v_column;
  2096. /* "_yaml.pyx":78
  2097. * self.line = line
  2098. * self.column = column
  2099. * self.buffer = buffer # <<<<<<<<<<<<<<
  2100. * self.pointer = pointer
  2101. *
  2102. */
  2103. __Pyx_INCREF(__pyx_v_buffer);
  2104. __Pyx_GIVEREF(__pyx_v_buffer);
  2105. __Pyx_GOTREF(__pyx_v_self->buffer);
  2106. __Pyx_DECREF(__pyx_v_self->buffer);
  2107. __pyx_v_self->buffer = __pyx_v_buffer;
  2108. /* "_yaml.pyx":79
  2109. * self.column = column
  2110. * self.buffer = buffer
  2111. * self.pointer = pointer # <<<<<<<<<<<<<<
  2112. *
  2113. * def get_snippet(self):
  2114. */
  2115. __Pyx_INCREF(__pyx_v_pointer);
  2116. __Pyx_GIVEREF(__pyx_v_pointer);
  2117. __Pyx_GOTREF(__pyx_v_self->pointer);
  2118. __Pyx_DECREF(__pyx_v_self->pointer);
  2119. __pyx_v_self->pointer = __pyx_v_pointer;
  2120. /* "_yaml.pyx":72
  2121. * cdef readonly pointer
  2122. *
  2123. * def __init__(self, object name, size_t index, size_t line, size_t column, # <<<<<<<<<<<<<<
  2124. * object buffer, object pointer):
  2125. * self.name = name
  2126. */
  2127. /* function exit code */
  2128. __pyx_r = 0;
  2129. __Pyx_RefNannyFinishContext();
  2130. return __pyx_r;
  2131. }
  2132. /* "_yaml.pyx":81
  2133. * self.pointer = pointer
  2134. *
  2135. * def get_snippet(self): # <<<<<<<<<<<<<<
  2136. * return None
  2137. *
  2138. */
  2139. /* Python wrapper */
  2140. static PyObject *__pyx_pw_5_yaml_4Mark_3get_snippet(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  2141. static PyObject *__pyx_pw_5_yaml_4Mark_3get_snippet(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  2142. PyObject *__pyx_r = 0;
  2143. __Pyx_RefNannyDeclarations
  2144. __Pyx_RefNannySetupContext("get_snippet (wrapper)", 0);
  2145. __pyx_r = __pyx_pf_5_yaml_4Mark_2get_snippet(((struct __pyx_obj_5_yaml_Mark *)__pyx_v_self));
  2146. /* function exit code */
  2147. __Pyx_RefNannyFinishContext();
  2148. return __pyx_r;
  2149. }
  2150. static PyObject *__pyx_pf_5_yaml_4Mark_2get_snippet(CYTHON_UNUSED struct __pyx_obj_5_yaml_Mark *__pyx_v_self) {
  2151. PyObject *__pyx_r = NULL;
  2152. __Pyx_RefNannyDeclarations
  2153. __Pyx_RefNannySetupContext("get_snippet", 0);
  2154. /* "_yaml.pyx":82
  2155. *
  2156. * def get_snippet(self):
  2157. * return None # <<<<<<<<<<<<<<
  2158. *
  2159. * def __str__(self):
  2160. */
  2161. __Pyx_XDECREF(__pyx_r);
  2162. __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  2163. goto __pyx_L0;
  2164. /* "_yaml.pyx":81
  2165. * self.pointer = pointer
  2166. *
  2167. * def get_snippet(self): # <<<<<<<<<<<<<<
  2168. * return None
  2169. *
  2170. */
  2171. /* function exit code */
  2172. __pyx_L0:;
  2173. __Pyx_XGIVEREF(__pyx_r);
  2174. __Pyx_RefNannyFinishContext();
  2175. return __pyx_r;
  2176. }
  2177. /* "_yaml.pyx":84
  2178. * return None
  2179. *
  2180. * def __str__(self): # <<<<<<<<<<<<<<
  2181. * where = " in \"%s\", line %d, column %d" \
  2182. * % (self.name, self.line+1, self.column+1)
  2183. */
  2184. /* Python wrapper */
  2185. static PyObject *__pyx_pw_5_yaml_4Mark_5__str__(PyObject *__pyx_v_self); /*proto*/
  2186. static PyObject *__pyx_pw_5_yaml_4Mark_5__str__(PyObject *__pyx_v_self) {
  2187. PyObject *__pyx_r = 0;
  2188. __Pyx_RefNannyDeclarations
  2189. __Pyx_RefNannySetupContext("__str__ (wrapper)", 0);
  2190. __pyx_r = __pyx_pf_5_yaml_4Mark_4__str__(((struct __pyx_obj_5_yaml_Mark *)__pyx_v_self));
  2191. /* function exit code */
  2192. __Pyx_RefNannyFinishContext();
  2193. return __pyx_r;
  2194. }
  2195. static PyObject *__pyx_pf_5_yaml_4Mark_4__str__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self) {
  2196. PyObject *__pyx_v_where = NULL;
  2197. PyObject *__pyx_r = NULL;
  2198. __Pyx_RefNannyDeclarations
  2199. PyObject *__pyx_t_1 = NULL;
  2200. PyObject *__pyx_t_2 = NULL;
  2201. PyObject *__pyx_t_3 = NULL;
  2202. __Pyx_RefNannySetupContext("__str__", 0);
  2203. /* "_yaml.pyx":86
  2204. * def __str__(self):
  2205. * where = " in \"%s\", line %d, column %d" \
  2206. * % (self.name, self.line+1, self.column+1) # <<<<<<<<<<<<<<
  2207. * return where
  2208. *
  2209. */
  2210. __pyx_t_1 = __Pyx_PyInt_FromSize_t((__pyx_v_self->line + 1)); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 86, __pyx_L1_error)
  2211. __Pyx_GOTREF(__pyx_t_1);
  2212. __pyx_t_2 = __Pyx_PyInt_FromSize_t((__pyx_v_self->column + 1)); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 86, __pyx_L1_error)
  2213. __Pyx_GOTREF(__pyx_t_2);
  2214. __pyx_t_3 = PyTuple_New(3); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 86, __pyx_L1_error)
  2215. __Pyx_GOTREF(__pyx_t_3);
  2216. __Pyx_INCREF(__pyx_v_self->name);
  2217. __Pyx_GIVEREF(__pyx_v_self->name);
  2218. PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_self->name);
  2219. __Pyx_GIVEREF(__pyx_t_1);
  2220. PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_1);
  2221. __Pyx_GIVEREF(__pyx_t_2);
  2222. PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_t_2);
  2223. __pyx_t_1 = 0;
  2224. __pyx_t_2 = 0;
  2225. __pyx_t_2 = __Pyx_PyString_Format(__pyx_kp_s_in_s_line_d_column_d, __pyx_t_3); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 86, __pyx_L1_error)
  2226. __Pyx_GOTREF(__pyx_t_2);
  2227. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  2228. __pyx_v_where = ((PyObject*)__pyx_t_2);
  2229. __pyx_t_2 = 0;
  2230. /* "_yaml.pyx":87
  2231. * where = " in \"%s\", line %d, column %d" \
  2232. * % (self.name, self.line+1, self.column+1)
  2233. * return where # <<<<<<<<<<<<<<
  2234. *
  2235. * #class YAMLError(Exception):
  2236. */
  2237. __Pyx_XDECREF(__pyx_r);
  2238. __Pyx_INCREF(__pyx_v_where);
  2239. __pyx_r = __pyx_v_where;
  2240. goto __pyx_L0;
  2241. /* "_yaml.pyx":84
  2242. * return None
  2243. *
  2244. * def __str__(self): # <<<<<<<<<<<<<<
  2245. * where = " in \"%s\", line %d, column %d" \
  2246. * % (self.name, self.line+1, self.column+1)
  2247. */
  2248. /* function exit code */
  2249. __pyx_L1_error:;
  2250. __Pyx_XDECREF(__pyx_t_1);
  2251. __Pyx_XDECREF(__pyx_t_2);
  2252. __Pyx_XDECREF(__pyx_t_3);
  2253. __Pyx_AddTraceback("_yaml.Mark.__str__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  2254. __pyx_r = NULL;
  2255. __pyx_L0:;
  2256. __Pyx_XDECREF(__pyx_v_where);
  2257. __Pyx_XGIVEREF(__pyx_r);
  2258. __Pyx_RefNannyFinishContext();
  2259. return __pyx_r;
  2260. }
  2261. /* "_yaml.pyx":65
  2262. *
  2263. * cdef class Mark:
  2264. * cdef readonly object name # <<<<<<<<<<<<<<
  2265. * cdef readonly size_t index
  2266. * cdef readonly size_t line
  2267. */
  2268. /* Python wrapper */
  2269. static PyObject *__pyx_pw_5_yaml_4Mark_4name_1__get__(PyObject *__pyx_v_self); /*proto*/
  2270. static PyObject *__pyx_pw_5_yaml_4Mark_4name_1__get__(PyObject *__pyx_v_self) {
  2271. PyObject *__pyx_r = 0;
  2272. __Pyx_RefNannyDeclarations
  2273. __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  2274. __pyx_r = __pyx_pf_5_yaml_4Mark_4name___get__(((struct __pyx_obj_5_yaml_Mark *)__pyx_v_self));
  2275. /* function exit code */
  2276. __Pyx_RefNannyFinishContext();
  2277. return __pyx_r;
  2278. }
  2279. static PyObject *__pyx_pf_5_yaml_4Mark_4name___get__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self) {
  2280. PyObject *__pyx_r = NULL;
  2281. __Pyx_RefNannyDeclarations
  2282. __Pyx_RefNannySetupContext("__get__", 0);
  2283. __Pyx_XDECREF(__pyx_r);
  2284. __Pyx_INCREF(__pyx_v_self->name);
  2285. __pyx_r = __pyx_v_self->name;
  2286. goto __pyx_L0;
  2287. /* function exit code */
  2288. __pyx_L0:;
  2289. __Pyx_XGIVEREF(__pyx_r);
  2290. __Pyx_RefNannyFinishContext();
  2291. return __pyx_r;
  2292. }
  2293. /* "_yaml.pyx":66
  2294. * cdef class Mark:
  2295. * cdef readonly object name
  2296. * cdef readonly size_t index # <<<<<<<<<<<<<<
  2297. * cdef readonly size_t line
  2298. * cdef readonly size_t column
  2299. */
  2300. /* Python wrapper */
  2301. static PyObject *__pyx_pw_5_yaml_4Mark_5index_1__get__(PyObject *__pyx_v_self); /*proto*/
  2302. static PyObject *__pyx_pw_5_yaml_4Mark_5index_1__get__(PyObject *__pyx_v_self) {
  2303. PyObject *__pyx_r = 0;
  2304. __Pyx_RefNannyDeclarations
  2305. __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  2306. __pyx_r = __pyx_pf_5_yaml_4Mark_5index___get__(((struct __pyx_obj_5_yaml_Mark *)__pyx_v_self));
  2307. /* function exit code */
  2308. __Pyx_RefNannyFinishContext();
  2309. return __pyx_r;
  2310. }
  2311. static PyObject *__pyx_pf_5_yaml_4Mark_5index___get__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self) {
  2312. PyObject *__pyx_r = NULL;
  2313. __Pyx_RefNannyDeclarations
  2314. PyObject *__pyx_t_1 = NULL;
  2315. __Pyx_RefNannySetupContext("__get__", 0);
  2316. __Pyx_XDECREF(__pyx_r);
  2317. __pyx_t_1 = __Pyx_PyInt_FromSize_t(__pyx_v_self->index); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 66, __pyx_L1_error)
  2318. __Pyx_GOTREF(__pyx_t_1);
  2319. __pyx_r = __pyx_t_1;
  2320. __pyx_t_1 = 0;
  2321. goto __pyx_L0;
  2322. /* function exit code */
  2323. __pyx_L1_error:;
  2324. __Pyx_XDECREF(__pyx_t_1);
  2325. __Pyx_AddTraceback("_yaml.Mark.index.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  2326. __pyx_r = NULL;
  2327. __pyx_L0:;
  2328. __Pyx_XGIVEREF(__pyx_r);
  2329. __Pyx_RefNannyFinishContext();
  2330. return __pyx_r;
  2331. }
  2332. /* "_yaml.pyx":67
  2333. * cdef readonly object name
  2334. * cdef readonly size_t index
  2335. * cdef readonly size_t line # <<<<<<<<<<<<<<
  2336. * cdef readonly size_t column
  2337. * cdef readonly buffer
  2338. */
  2339. /* Python wrapper */
  2340. static PyObject *__pyx_pw_5_yaml_4Mark_4line_1__get__(PyObject *__pyx_v_self); /*proto*/
  2341. static PyObject *__pyx_pw_5_yaml_4Mark_4line_1__get__(PyObject *__pyx_v_self) {
  2342. PyObject *__pyx_r = 0;
  2343. __Pyx_RefNannyDeclarations
  2344. __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  2345. __pyx_r = __pyx_pf_5_yaml_4Mark_4line___get__(((struct __pyx_obj_5_yaml_Mark *)__pyx_v_self));
  2346. /* function exit code */
  2347. __Pyx_RefNannyFinishContext();
  2348. return __pyx_r;
  2349. }
  2350. static PyObject *__pyx_pf_5_yaml_4Mark_4line___get__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self) {
  2351. PyObject *__pyx_r = NULL;
  2352. __Pyx_RefNannyDeclarations
  2353. PyObject *__pyx_t_1 = NULL;
  2354. __Pyx_RefNannySetupContext("__get__", 0);
  2355. __Pyx_XDECREF(__pyx_r);
  2356. __pyx_t_1 = __Pyx_PyInt_FromSize_t(__pyx_v_self->line); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 67, __pyx_L1_error)
  2357. __Pyx_GOTREF(__pyx_t_1);
  2358. __pyx_r = __pyx_t_1;
  2359. __pyx_t_1 = 0;
  2360. goto __pyx_L0;
  2361. /* function exit code */
  2362. __pyx_L1_error:;
  2363. __Pyx_XDECREF(__pyx_t_1);
  2364. __Pyx_AddTraceback("_yaml.Mark.line.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  2365. __pyx_r = NULL;
  2366. __pyx_L0:;
  2367. __Pyx_XGIVEREF(__pyx_r);
  2368. __Pyx_RefNannyFinishContext();
  2369. return __pyx_r;
  2370. }
  2371. /* "_yaml.pyx":68
  2372. * cdef readonly size_t index
  2373. * cdef readonly size_t line
  2374. * cdef readonly size_t column # <<<<<<<<<<<<<<
  2375. * cdef readonly buffer
  2376. * cdef readonly pointer
  2377. */
  2378. /* Python wrapper */
  2379. static PyObject *__pyx_pw_5_yaml_4Mark_6column_1__get__(PyObject *__pyx_v_self); /*proto*/
  2380. static PyObject *__pyx_pw_5_yaml_4Mark_6column_1__get__(PyObject *__pyx_v_self) {
  2381. PyObject *__pyx_r = 0;
  2382. __Pyx_RefNannyDeclarations
  2383. __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  2384. __pyx_r = __pyx_pf_5_yaml_4Mark_6column___get__(((struct __pyx_obj_5_yaml_Mark *)__pyx_v_self));
  2385. /* function exit code */
  2386. __Pyx_RefNannyFinishContext();
  2387. return __pyx_r;
  2388. }
  2389. static PyObject *__pyx_pf_5_yaml_4Mark_6column___get__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self) {
  2390. PyObject *__pyx_r = NULL;
  2391. __Pyx_RefNannyDeclarations
  2392. PyObject *__pyx_t_1 = NULL;
  2393. __Pyx_RefNannySetupContext("__get__", 0);
  2394. __Pyx_XDECREF(__pyx_r);
  2395. __pyx_t_1 = __Pyx_PyInt_FromSize_t(__pyx_v_self->column); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 68, __pyx_L1_error)
  2396. __Pyx_GOTREF(__pyx_t_1);
  2397. __pyx_r = __pyx_t_1;
  2398. __pyx_t_1 = 0;
  2399. goto __pyx_L0;
  2400. /* function exit code */
  2401. __pyx_L1_error:;
  2402. __Pyx_XDECREF(__pyx_t_1);
  2403. __Pyx_AddTraceback("_yaml.Mark.column.__get__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  2404. __pyx_r = NULL;
  2405. __pyx_L0:;
  2406. __Pyx_XGIVEREF(__pyx_r);
  2407. __Pyx_RefNannyFinishContext();
  2408. return __pyx_r;
  2409. }
  2410. /* "_yaml.pyx":69
  2411. * cdef readonly size_t line
  2412. * cdef readonly size_t column
  2413. * cdef readonly buffer # <<<<<<<<<<<<<<
  2414. * cdef readonly pointer
  2415. *
  2416. */
  2417. /* Python wrapper */
  2418. static PyObject *__pyx_pw_5_yaml_4Mark_6buffer_1__get__(PyObject *__pyx_v_self); /*proto*/
  2419. static PyObject *__pyx_pw_5_yaml_4Mark_6buffer_1__get__(PyObject *__pyx_v_self) {
  2420. PyObject *__pyx_r = 0;
  2421. __Pyx_RefNannyDeclarations
  2422. __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  2423. __pyx_r = __pyx_pf_5_yaml_4Mark_6buffer___get__(((struct __pyx_obj_5_yaml_Mark *)__pyx_v_self));
  2424. /* function exit code */
  2425. __Pyx_RefNannyFinishContext();
  2426. return __pyx_r;
  2427. }
  2428. static PyObject *__pyx_pf_5_yaml_4Mark_6buffer___get__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self) {
  2429. PyObject *__pyx_r = NULL;
  2430. __Pyx_RefNannyDeclarations
  2431. __Pyx_RefNannySetupContext("__get__", 0);
  2432. __Pyx_XDECREF(__pyx_r);
  2433. __Pyx_INCREF(__pyx_v_self->buffer);
  2434. __pyx_r = __pyx_v_self->buffer;
  2435. goto __pyx_L0;
  2436. /* function exit code */
  2437. __pyx_L0:;
  2438. __Pyx_XGIVEREF(__pyx_r);
  2439. __Pyx_RefNannyFinishContext();
  2440. return __pyx_r;
  2441. }
  2442. /* "_yaml.pyx":70
  2443. * cdef readonly size_t column
  2444. * cdef readonly buffer
  2445. * cdef readonly pointer # <<<<<<<<<<<<<<
  2446. *
  2447. * def __init__(self, object name, size_t index, size_t line, size_t column,
  2448. */
  2449. /* Python wrapper */
  2450. static PyObject *__pyx_pw_5_yaml_4Mark_7pointer_1__get__(PyObject *__pyx_v_self); /*proto*/
  2451. static PyObject *__pyx_pw_5_yaml_4Mark_7pointer_1__get__(PyObject *__pyx_v_self) {
  2452. PyObject *__pyx_r = 0;
  2453. __Pyx_RefNannyDeclarations
  2454. __Pyx_RefNannySetupContext("__get__ (wrapper)", 0);
  2455. __pyx_r = __pyx_pf_5_yaml_4Mark_7pointer___get__(((struct __pyx_obj_5_yaml_Mark *)__pyx_v_self));
  2456. /* function exit code */
  2457. __Pyx_RefNannyFinishContext();
  2458. return __pyx_r;
  2459. }
  2460. static PyObject *__pyx_pf_5_yaml_4Mark_7pointer___get__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self) {
  2461. PyObject *__pyx_r = NULL;
  2462. __Pyx_RefNannyDeclarations
  2463. __Pyx_RefNannySetupContext("__get__", 0);
  2464. __Pyx_XDECREF(__pyx_r);
  2465. __Pyx_INCREF(__pyx_v_self->pointer);
  2466. __pyx_r = __pyx_v_self->pointer;
  2467. goto __pyx_L0;
  2468. /* function exit code */
  2469. __pyx_L0:;
  2470. __Pyx_XGIVEREF(__pyx_r);
  2471. __Pyx_RefNannyFinishContext();
  2472. return __pyx_r;
  2473. }
  2474. /* "(tree fragment)":1
  2475. * def __reduce_cython__(self): # <<<<<<<<<<<<<<
  2476. * cdef tuple state
  2477. * cdef object _dict
  2478. */
  2479. /* Python wrapper */
  2480. static PyObject *__pyx_pw_5_yaml_4Mark_7__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  2481. static PyObject *__pyx_pw_5_yaml_4Mark_7__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  2482. PyObject *__pyx_r = 0;
  2483. __Pyx_RefNannyDeclarations
  2484. __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0);
  2485. __pyx_r = __pyx_pf_5_yaml_4Mark_6__reduce_cython__(((struct __pyx_obj_5_yaml_Mark *)__pyx_v_self));
  2486. /* function exit code */
  2487. __Pyx_RefNannyFinishContext();
  2488. return __pyx_r;
  2489. }
  2490. static PyObject *__pyx_pf_5_yaml_4Mark_6__reduce_cython__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self) {
  2491. PyObject *__pyx_v_state = 0;
  2492. PyObject *__pyx_v__dict = 0;
  2493. int __pyx_v_use_setstate;
  2494. PyObject *__pyx_r = NULL;
  2495. __Pyx_RefNannyDeclarations
  2496. PyObject *__pyx_t_1 = NULL;
  2497. PyObject *__pyx_t_2 = NULL;
  2498. PyObject *__pyx_t_3 = NULL;
  2499. PyObject *__pyx_t_4 = NULL;
  2500. int __pyx_t_5;
  2501. int __pyx_t_6;
  2502. int __pyx_t_7;
  2503. __Pyx_RefNannySetupContext("__reduce_cython__", 0);
  2504. /* "(tree fragment)":5
  2505. * cdef object _dict
  2506. * cdef bint use_setstate
  2507. * state = (self.buffer, self.column, self.index, self.line, self.name, self.pointer) # <<<<<<<<<<<<<<
  2508. * _dict = getattr(self, '__dict__', None)
  2509. * if _dict is not None:
  2510. */
  2511. __pyx_t_1 = __Pyx_PyInt_FromSize_t(__pyx_v_self->column); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 5, __pyx_L1_error)
  2512. __Pyx_GOTREF(__pyx_t_1);
  2513. __pyx_t_2 = __Pyx_PyInt_FromSize_t(__pyx_v_self->index); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 5, __pyx_L1_error)
  2514. __Pyx_GOTREF(__pyx_t_2);
  2515. __pyx_t_3 = __Pyx_PyInt_FromSize_t(__pyx_v_self->line); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
  2516. __Pyx_GOTREF(__pyx_t_3);
  2517. __pyx_t_4 = PyTuple_New(6); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 5, __pyx_L1_error)
  2518. __Pyx_GOTREF(__pyx_t_4);
  2519. __Pyx_INCREF(__pyx_v_self->buffer);
  2520. __Pyx_GIVEREF(__pyx_v_self->buffer);
  2521. PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->buffer);
  2522. __Pyx_GIVEREF(__pyx_t_1);
  2523. PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1);
  2524. __Pyx_GIVEREF(__pyx_t_2);
  2525. PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_2);
  2526. __Pyx_GIVEREF(__pyx_t_3);
  2527. PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_t_3);
  2528. __Pyx_INCREF(__pyx_v_self->name);
  2529. __Pyx_GIVEREF(__pyx_v_self->name);
  2530. PyTuple_SET_ITEM(__pyx_t_4, 4, __pyx_v_self->name);
  2531. __Pyx_INCREF(__pyx_v_self->pointer);
  2532. __Pyx_GIVEREF(__pyx_v_self->pointer);
  2533. PyTuple_SET_ITEM(__pyx_t_4, 5, __pyx_v_self->pointer);
  2534. __pyx_t_1 = 0;
  2535. __pyx_t_2 = 0;
  2536. __pyx_t_3 = 0;
  2537. __pyx_v_state = ((PyObject*)__pyx_t_4);
  2538. __pyx_t_4 = 0;
  2539. /* "(tree fragment)":6
  2540. * cdef bint use_setstate
  2541. * state = (self.buffer, self.column, self.index, self.line, self.name, self.pointer)
  2542. * _dict = getattr(self, '__dict__', None) # <<<<<<<<<<<<<<
  2543. * if _dict is not None:
  2544. * state += (_dict,)
  2545. */
  2546. __pyx_t_4 = __Pyx_GetAttr3(((PyObject *)__pyx_v_self), __pyx_n_s_dict, Py_None); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 6, __pyx_L1_error)
  2547. __Pyx_GOTREF(__pyx_t_4);
  2548. __pyx_v__dict = __pyx_t_4;
  2549. __pyx_t_4 = 0;
  2550. /* "(tree fragment)":7
  2551. * state = (self.buffer, self.column, self.index, self.line, self.name, self.pointer)
  2552. * _dict = getattr(self, '__dict__', None)
  2553. * if _dict is not None: # <<<<<<<<<<<<<<
  2554. * state += (_dict,)
  2555. * use_setstate = True
  2556. */
  2557. __pyx_t_5 = (__pyx_v__dict != Py_None);
  2558. __pyx_t_6 = (__pyx_t_5 != 0);
  2559. if (__pyx_t_6) {
  2560. /* "(tree fragment)":8
  2561. * _dict = getattr(self, '__dict__', None)
  2562. * if _dict is not None:
  2563. * state += (_dict,) # <<<<<<<<<<<<<<
  2564. * use_setstate = True
  2565. * else:
  2566. */
  2567. __pyx_t_4 = PyTuple_New(1); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 8, __pyx_L1_error)
  2568. __Pyx_GOTREF(__pyx_t_4);
  2569. __Pyx_INCREF(__pyx_v__dict);
  2570. __Pyx_GIVEREF(__pyx_v__dict);
  2571. PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v__dict);
  2572. __pyx_t_3 = PyNumber_InPlaceAdd(__pyx_v_state, __pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 8, __pyx_L1_error)
  2573. __Pyx_GOTREF(__pyx_t_3);
  2574. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  2575. __Pyx_DECREF_SET(__pyx_v_state, ((PyObject*)__pyx_t_3));
  2576. __pyx_t_3 = 0;
  2577. /* "(tree fragment)":9
  2578. * if _dict is not None:
  2579. * state += (_dict,)
  2580. * use_setstate = True # <<<<<<<<<<<<<<
  2581. * else:
  2582. * use_setstate = self.buffer is not None or self.name is not None or self.pointer is not None
  2583. */
  2584. __pyx_v_use_setstate = 1;
  2585. /* "(tree fragment)":7
  2586. * state = (self.buffer, self.column, self.index, self.line, self.name, self.pointer)
  2587. * _dict = getattr(self, '__dict__', None)
  2588. * if _dict is not None: # <<<<<<<<<<<<<<
  2589. * state += (_dict,)
  2590. * use_setstate = True
  2591. */
  2592. goto __pyx_L3;
  2593. }
  2594. /* "(tree fragment)":11
  2595. * use_setstate = True
  2596. * else:
  2597. * use_setstate = self.buffer is not None or self.name is not None or self.pointer is not None # <<<<<<<<<<<<<<
  2598. * if use_setstate:
  2599. * return __pyx_unpickle_Mark, (type(self), 0x3fa45b6, None), state
  2600. */
  2601. /*else*/ {
  2602. __pyx_t_5 = (__pyx_v_self->buffer != Py_None);
  2603. __pyx_t_7 = (__pyx_t_5 != 0);
  2604. if (!__pyx_t_7) {
  2605. } else {
  2606. __pyx_t_6 = __pyx_t_7;
  2607. goto __pyx_L4_bool_binop_done;
  2608. }
  2609. __pyx_t_7 = (__pyx_v_self->name != Py_None);
  2610. __pyx_t_5 = (__pyx_t_7 != 0);
  2611. if (!__pyx_t_5) {
  2612. } else {
  2613. __pyx_t_6 = __pyx_t_5;
  2614. goto __pyx_L4_bool_binop_done;
  2615. }
  2616. __pyx_t_5 = (__pyx_v_self->pointer != Py_None);
  2617. __pyx_t_7 = (__pyx_t_5 != 0);
  2618. __pyx_t_6 = __pyx_t_7;
  2619. __pyx_L4_bool_binop_done:;
  2620. __pyx_v_use_setstate = __pyx_t_6;
  2621. }
  2622. __pyx_L3:;
  2623. /* "(tree fragment)":12
  2624. * else:
  2625. * use_setstate = self.buffer is not None or self.name is not None or self.pointer is not None
  2626. * if use_setstate: # <<<<<<<<<<<<<<
  2627. * return __pyx_unpickle_Mark, (type(self), 0x3fa45b6, None), state
  2628. * else:
  2629. */
  2630. __pyx_t_6 = (__pyx_v_use_setstate != 0);
  2631. if (__pyx_t_6) {
  2632. /* "(tree fragment)":13
  2633. * use_setstate = self.buffer is not None or self.name is not None or self.pointer is not None
  2634. * if use_setstate:
  2635. * return __pyx_unpickle_Mark, (type(self), 0x3fa45b6, None), state # <<<<<<<<<<<<<<
  2636. * else:
  2637. * return __pyx_unpickle_Mark, (type(self), 0x3fa45b6, state)
  2638. */
  2639. __Pyx_XDECREF(__pyx_r);
  2640. __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_pyx_unpickle_Mark); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 13, __pyx_L1_error)
  2641. __Pyx_GOTREF(__pyx_t_3);
  2642. __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 13, __pyx_L1_error)
  2643. __Pyx_GOTREF(__pyx_t_4);
  2644. __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
  2645. __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
  2646. PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
  2647. __Pyx_INCREF(__pyx_int_66733494);
  2648. __Pyx_GIVEREF(__pyx_int_66733494);
  2649. PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_66733494);
  2650. __Pyx_INCREF(Py_None);
  2651. __Pyx_GIVEREF(Py_None);
  2652. PyTuple_SET_ITEM(__pyx_t_4, 2, Py_None);
  2653. __pyx_t_2 = PyTuple_New(3); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 13, __pyx_L1_error)
  2654. __Pyx_GOTREF(__pyx_t_2);
  2655. __Pyx_GIVEREF(__pyx_t_3);
  2656. PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_3);
  2657. __Pyx_GIVEREF(__pyx_t_4);
  2658. PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_4);
  2659. __Pyx_INCREF(__pyx_v_state);
  2660. __Pyx_GIVEREF(__pyx_v_state);
  2661. PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_v_state);
  2662. __pyx_t_3 = 0;
  2663. __pyx_t_4 = 0;
  2664. __pyx_r = __pyx_t_2;
  2665. __pyx_t_2 = 0;
  2666. goto __pyx_L0;
  2667. /* "(tree fragment)":12
  2668. * else:
  2669. * use_setstate = self.buffer is not None or self.name is not None or self.pointer is not None
  2670. * if use_setstate: # <<<<<<<<<<<<<<
  2671. * return __pyx_unpickle_Mark, (type(self), 0x3fa45b6, None), state
  2672. * else:
  2673. */
  2674. }
  2675. /* "(tree fragment)":15
  2676. * return __pyx_unpickle_Mark, (type(self), 0x3fa45b6, None), state
  2677. * else:
  2678. * return __pyx_unpickle_Mark, (type(self), 0x3fa45b6, state) # <<<<<<<<<<<<<<
  2679. * def __setstate_cython__(self, __pyx_state):
  2680. * __pyx_unpickle_Mark__set_state(self, __pyx_state)
  2681. */
  2682. /*else*/ {
  2683. __Pyx_XDECREF(__pyx_r);
  2684. __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_pyx_unpickle_Mark); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 15, __pyx_L1_error)
  2685. __Pyx_GOTREF(__pyx_t_2);
  2686. __pyx_t_4 = PyTuple_New(3); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 15, __pyx_L1_error)
  2687. __Pyx_GOTREF(__pyx_t_4);
  2688. __Pyx_INCREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
  2689. __Pyx_GIVEREF(((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
  2690. PyTuple_SET_ITEM(__pyx_t_4, 0, ((PyObject *)Py_TYPE(((PyObject *)__pyx_v_self))));
  2691. __Pyx_INCREF(__pyx_int_66733494);
  2692. __Pyx_GIVEREF(__pyx_int_66733494);
  2693. PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_int_66733494);
  2694. __Pyx_INCREF(__pyx_v_state);
  2695. __Pyx_GIVEREF(__pyx_v_state);
  2696. PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_v_state);
  2697. __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 15, __pyx_L1_error)
  2698. __Pyx_GOTREF(__pyx_t_3);
  2699. __Pyx_GIVEREF(__pyx_t_2);
  2700. PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2);
  2701. __Pyx_GIVEREF(__pyx_t_4);
  2702. PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_4);
  2703. __pyx_t_2 = 0;
  2704. __pyx_t_4 = 0;
  2705. __pyx_r = __pyx_t_3;
  2706. __pyx_t_3 = 0;
  2707. goto __pyx_L0;
  2708. }
  2709. /* "(tree fragment)":1
  2710. * def __reduce_cython__(self): # <<<<<<<<<<<<<<
  2711. * cdef tuple state
  2712. * cdef object _dict
  2713. */
  2714. /* function exit code */
  2715. __pyx_L1_error:;
  2716. __Pyx_XDECREF(__pyx_t_1);
  2717. __Pyx_XDECREF(__pyx_t_2);
  2718. __Pyx_XDECREF(__pyx_t_3);
  2719. __Pyx_XDECREF(__pyx_t_4);
  2720. __Pyx_AddTraceback("_yaml.Mark.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  2721. __pyx_r = NULL;
  2722. __pyx_L0:;
  2723. __Pyx_XDECREF(__pyx_v_state);
  2724. __Pyx_XDECREF(__pyx_v__dict);
  2725. __Pyx_XGIVEREF(__pyx_r);
  2726. __Pyx_RefNannyFinishContext();
  2727. return __pyx_r;
  2728. }
  2729. /* "(tree fragment)":16
  2730. * else:
  2731. * return __pyx_unpickle_Mark, (type(self), 0x3fa45b6, state)
  2732. * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<<
  2733. * __pyx_unpickle_Mark__set_state(self, __pyx_state)
  2734. */
  2735. /* Python wrapper */
  2736. static PyObject *__pyx_pw_5_yaml_4Mark_9__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/
  2737. static PyObject *__pyx_pw_5_yaml_4Mark_9__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
  2738. PyObject *__pyx_r = 0;
  2739. __Pyx_RefNannyDeclarations
  2740. __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0);
  2741. __pyx_r = __pyx_pf_5_yaml_4Mark_8__setstate_cython__(((struct __pyx_obj_5_yaml_Mark *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state));
  2742. /* function exit code */
  2743. __Pyx_RefNannyFinishContext();
  2744. return __pyx_r;
  2745. }
  2746. static PyObject *__pyx_pf_5_yaml_4Mark_8__setstate_cython__(struct __pyx_obj_5_yaml_Mark *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
  2747. PyObject *__pyx_r = NULL;
  2748. __Pyx_RefNannyDeclarations
  2749. PyObject *__pyx_t_1 = NULL;
  2750. __Pyx_RefNannySetupContext("__setstate_cython__", 0);
  2751. /* "(tree fragment)":17
  2752. * return __pyx_unpickle_Mark, (type(self), 0x3fa45b6, state)
  2753. * def __setstate_cython__(self, __pyx_state):
  2754. * __pyx_unpickle_Mark__set_state(self, __pyx_state) # <<<<<<<<<<<<<<
  2755. */
  2756. if (!(likely(PyTuple_CheckExact(__pyx_v___pyx_state))||((__pyx_v___pyx_state) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v___pyx_state)->tp_name), 0))) __PYX_ERR(1, 17, __pyx_L1_error)
  2757. __pyx_t_1 = __pyx_f_5_yaml___pyx_unpickle_Mark__set_state(__pyx_v_self, ((PyObject*)__pyx_v___pyx_state)); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 17, __pyx_L1_error)
  2758. __Pyx_GOTREF(__pyx_t_1);
  2759. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  2760. /* "(tree fragment)":16
  2761. * else:
  2762. * return __pyx_unpickle_Mark, (type(self), 0x3fa45b6, state)
  2763. * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<<
  2764. * __pyx_unpickle_Mark__set_state(self, __pyx_state)
  2765. */
  2766. /* function exit code */
  2767. __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  2768. goto __pyx_L0;
  2769. __pyx_L1_error:;
  2770. __Pyx_XDECREF(__pyx_t_1);
  2771. __Pyx_AddTraceback("_yaml.Mark.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  2772. __pyx_r = NULL;
  2773. __pyx_L0:;
  2774. __Pyx_XGIVEREF(__pyx_r);
  2775. __Pyx_RefNannyFinishContext();
  2776. return __pyx_r;
  2777. }
  2778. /* "_yaml.pyx":262
  2779. * cdef int unicode_source
  2780. *
  2781. * def __init__(self, stream): # <<<<<<<<<<<<<<
  2782. * cdef is_readable
  2783. * if yaml_parser_initialize(&self.parser) == 0:
  2784. */
  2785. /* Python wrapper */
  2786. static int __pyx_pw_5_yaml_7CParser_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
  2787. static int __pyx_pw_5_yaml_7CParser_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  2788. PyObject *__pyx_v_stream = 0;
  2789. int __pyx_r;
  2790. __Pyx_RefNannyDeclarations
  2791. __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  2792. {
  2793. static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_stream,0};
  2794. PyObject* values[1] = {0};
  2795. if (unlikely(__pyx_kwds)) {
  2796. Py_ssize_t kw_args;
  2797. const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
  2798. switch (pos_args) {
  2799. case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
  2800. CYTHON_FALLTHROUGH;
  2801. case 0: break;
  2802. default: goto __pyx_L5_argtuple_error;
  2803. }
  2804. kw_args = PyDict_Size(__pyx_kwds);
  2805. switch (pos_args) {
  2806. case 0:
  2807. if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_stream)) != 0)) kw_args--;
  2808. else goto __pyx_L5_argtuple_error;
  2809. }
  2810. if (unlikely(kw_args > 0)) {
  2811. if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(0, 262, __pyx_L3_error)
  2812. }
  2813. } else if (PyTuple_GET_SIZE(__pyx_args) != 1) {
  2814. goto __pyx_L5_argtuple_error;
  2815. } else {
  2816. values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
  2817. }
  2818. __pyx_v_stream = values[0];
  2819. }
  2820. goto __pyx_L4_argument_unpacking_done;
  2821. __pyx_L5_argtuple_error:;
  2822. __Pyx_RaiseArgtupleInvalid("__init__", 1, 1, 1, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 262, __pyx_L3_error)
  2823. __pyx_L3_error:;
  2824. __Pyx_AddTraceback("_yaml.CParser.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  2825. __Pyx_RefNannyFinishContext();
  2826. return -1;
  2827. __pyx_L4_argument_unpacking_done:;
  2828. __pyx_r = __pyx_pf_5_yaml_7CParser___init__(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self), __pyx_v_stream);
  2829. /* function exit code */
  2830. __Pyx_RefNannyFinishContext();
  2831. return __pyx_r;
  2832. }
  2833. static int __pyx_pf_5_yaml_7CParser___init__(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, PyObject *__pyx_v_stream) {
  2834. PyObject *__pyx_v_is_readable = 0;
  2835. int __pyx_r;
  2836. __Pyx_RefNannyDeclarations
  2837. int __pyx_t_1;
  2838. PyObject *__pyx_t_2 = NULL;
  2839. PyObject *__pyx_t_3 = NULL;
  2840. PyObject *__pyx_t_4 = NULL;
  2841. PyObject *__pyx_t_5 = NULL;
  2842. int __pyx_t_6;
  2843. PyObject *__pyx_t_7 = NULL;
  2844. PyObject *__pyx_t_8 = NULL;
  2845. __Pyx_RefNannySetupContext("__init__", 0);
  2846. __Pyx_INCREF(__pyx_v_stream);
  2847. /* "_yaml.pyx":264
  2848. * def __init__(self, stream):
  2849. * cdef is_readable
  2850. * if yaml_parser_initialize(&self.parser) == 0: # <<<<<<<<<<<<<<
  2851. * raise MemoryError
  2852. * self.parsed_event.type = YAML_NO_EVENT
  2853. */
  2854. __pyx_t_1 = ((yaml_parser_initialize((&__pyx_v_self->parser)) == 0) != 0);
  2855. if (unlikely(__pyx_t_1)) {
  2856. /* "_yaml.pyx":265
  2857. * cdef is_readable
  2858. * if yaml_parser_initialize(&self.parser) == 0:
  2859. * raise MemoryError # <<<<<<<<<<<<<<
  2860. * self.parsed_event.type = YAML_NO_EVENT
  2861. * is_readable = 1
  2862. */
  2863. PyErr_NoMemory(); __PYX_ERR(0, 265, __pyx_L1_error)
  2864. /* "_yaml.pyx":264
  2865. * def __init__(self, stream):
  2866. * cdef is_readable
  2867. * if yaml_parser_initialize(&self.parser) == 0: # <<<<<<<<<<<<<<
  2868. * raise MemoryError
  2869. * self.parsed_event.type = YAML_NO_EVENT
  2870. */
  2871. }
  2872. /* "_yaml.pyx":266
  2873. * if yaml_parser_initialize(&self.parser) == 0:
  2874. * raise MemoryError
  2875. * self.parsed_event.type = YAML_NO_EVENT # <<<<<<<<<<<<<<
  2876. * is_readable = 1
  2877. * try:
  2878. */
  2879. __pyx_v_self->parsed_event.type = YAML_NO_EVENT;
  2880. /* "_yaml.pyx":267
  2881. * raise MemoryError
  2882. * self.parsed_event.type = YAML_NO_EVENT
  2883. * is_readable = 1 # <<<<<<<<<<<<<<
  2884. * try:
  2885. * stream.read
  2886. */
  2887. __Pyx_INCREF(__pyx_int_1);
  2888. __pyx_v_is_readable = __pyx_int_1;
  2889. /* "_yaml.pyx":268
  2890. * self.parsed_event.type = YAML_NO_EVENT
  2891. * is_readable = 1
  2892. * try: # <<<<<<<<<<<<<<
  2893. * stream.read
  2894. * except AttributeError:
  2895. */
  2896. {
  2897. __Pyx_PyThreadState_declare
  2898. __Pyx_PyThreadState_assign
  2899. __Pyx_ExceptionSave(&__pyx_t_2, &__pyx_t_3, &__pyx_t_4);
  2900. __Pyx_XGOTREF(__pyx_t_2);
  2901. __Pyx_XGOTREF(__pyx_t_3);
  2902. __Pyx_XGOTREF(__pyx_t_4);
  2903. /*try:*/ {
  2904. /* "_yaml.pyx":269
  2905. * is_readable = 1
  2906. * try:
  2907. * stream.read # <<<<<<<<<<<<<<
  2908. * except AttributeError:
  2909. * is_readable = 0
  2910. */
  2911. __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_stream, __pyx_n_s_read); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 269, __pyx_L4_error)
  2912. __Pyx_GOTREF(__pyx_t_5);
  2913. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  2914. /* "_yaml.pyx":268
  2915. * self.parsed_event.type = YAML_NO_EVENT
  2916. * is_readable = 1
  2917. * try: # <<<<<<<<<<<<<<
  2918. * stream.read
  2919. * except AttributeError:
  2920. */
  2921. }
  2922. __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
  2923. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  2924. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  2925. goto __pyx_L9_try_end;
  2926. __pyx_L4_error:;
  2927. __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
  2928. /* "_yaml.pyx":270
  2929. * try:
  2930. * stream.read
  2931. * except AttributeError: # <<<<<<<<<<<<<<
  2932. * is_readable = 0
  2933. * self.unicode_source = 0
  2934. */
  2935. __pyx_t_6 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_AttributeError);
  2936. if (__pyx_t_6) {
  2937. __Pyx_AddTraceback("_yaml.CParser.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  2938. if (__Pyx_GetException(&__pyx_t_5, &__pyx_t_7, &__pyx_t_8) < 0) __PYX_ERR(0, 270, __pyx_L6_except_error)
  2939. __Pyx_GOTREF(__pyx_t_5);
  2940. __Pyx_GOTREF(__pyx_t_7);
  2941. __Pyx_GOTREF(__pyx_t_8);
  2942. /* "_yaml.pyx":271
  2943. * stream.read
  2944. * except AttributeError:
  2945. * is_readable = 0 # <<<<<<<<<<<<<<
  2946. * self.unicode_source = 0
  2947. * if is_readable:
  2948. */
  2949. __Pyx_INCREF(__pyx_int_0);
  2950. __Pyx_DECREF_SET(__pyx_v_is_readable, __pyx_int_0);
  2951. __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
  2952. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  2953. __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
  2954. goto __pyx_L5_exception_handled;
  2955. }
  2956. goto __pyx_L6_except_error;
  2957. __pyx_L6_except_error:;
  2958. /* "_yaml.pyx":268
  2959. * self.parsed_event.type = YAML_NO_EVENT
  2960. * is_readable = 1
  2961. * try: # <<<<<<<<<<<<<<
  2962. * stream.read
  2963. * except AttributeError:
  2964. */
  2965. __Pyx_XGIVEREF(__pyx_t_2);
  2966. __Pyx_XGIVEREF(__pyx_t_3);
  2967. __Pyx_XGIVEREF(__pyx_t_4);
  2968. __Pyx_ExceptionReset(__pyx_t_2, __pyx_t_3, __pyx_t_4);
  2969. goto __pyx_L1_error;
  2970. __pyx_L5_exception_handled:;
  2971. __Pyx_XGIVEREF(__pyx_t_2);
  2972. __Pyx_XGIVEREF(__pyx_t_3);
  2973. __Pyx_XGIVEREF(__pyx_t_4);
  2974. __Pyx_ExceptionReset(__pyx_t_2, __pyx_t_3, __pyx_t_4);
  2975. __pyx_L9_try_end:;
  2976. }
  2977. /* "_yaml.pyx":272
  2978. * except AttributeError:
  2979. * is_readable = 0
  2980. * self.unicode_source = 0 # <<<<<<<<<<<<<<
  2981. * if is_readable:
  2982. * self.stream = stream
  2983. */
  2984. __pyx_v_self->unicode_source = 0;
  2985. /* "_yaml.pyx":273
  2986. * is_readable = 0
  2987. * self.unicode_source = 0
  2988. * if is_readable: # <<<<<<<<<<<<<<
  2989. * self.stream = stream
  2990. * try:
  2991. */
  2992. __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_is_readable); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 273, __pyx_L1_error)
  2993. if (__pyx_t_1) {
  2994. /* "_yaml.pyx":274
  2995. * self.unicode_source = 0
  2996. * if is_readable:
  2997. * self.stream = stream # <<<<<<<<<<<<<<
  2998. * try:
  2999. * self.stream_name = stream.name
  3000. */
  3001. __Pyx_INCREF(__pyx_v_stream);
  3002. __Pyx_GIVEREF(__pyx_v_stream);
  3003. __Pyx_GOTREF(__pyx_v_self->stream);
  3004. __Pyx_DECREF(__pyx_v_self->stream);
  3005. __pyx_v_self->stream = __pyx_v_stream;
  3006. /* "_yaml.pyx":275
  3007. * if is_readable:
  3008. * self.stream = stream
  3009. * try: # <<<<<<<<<<<<<<
  3010. * self.stream_name = stream.name
  3011. * except AttributeError:
  3012. */
  3013. {
  3014. __Pyx_PyThreadState_declare
  3015. __Pyx_PyThreadState_assign
  3016. __Pyx_ExceptionSave(&__pyx_t_4, &__pyx_t_3, &__pyx_t_2);
  3017. __Pyx_XGOTREF(__pyx_t_4);
  3018. __Pyx_XGOTREF(__pyx_t_3);
  3019. __Pyx_XGOTREF(__pyx_t_2);
  3020. /*try:*/ {
  3021. /* "_yaml.pyx":276
  3022. * self.stream = stream
  3023. * try:
  3024. * self.stream_name = stream.name # <<<<<<<<<<<<<<
  3025. * except AttributeError:
  3026. * if PY_MAJOR_VERSION < 3:
  3027. */
  3028. __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_stream, __pyx_n_s_name); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 276, __pyx_L13_error)
  3029. __Pyx_GOTREF(__pyx_t_8);
  3030. __Pyx_GIVEREF(__pyx_t_8);
  3031. __Pyx_GOTREF(__pyx_v_self->stream_name);
  3032. __Pyx_DECREF(__pyx_v_self->stream_name);
  3033. __pyx_v_self->stream_name = __pyx_t_8;
  3034. __pyx_t_8 = 0;
  3035. /* "_yaml.pyx":275
  3036. * if is_readable:
  3037. * self.stream = stream
  3038. * try: # <<<<<<<<<<<<<<
  3039. * self.stream_name = stream.name
  3040. * except AttributeError:
  3041. */
  3042. }
  3043. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  3044. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  3045. __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
  3046. goto __pyx_L18_try_end;
  3047. __pyx_L13_error:;
  3048. __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
  3049. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  3050. __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
  3051. /* "_yaml.pyx":277
  3052. * try:
  3053. * self.stream_name = stream.name
  3054. * except AttributeError: # <<<<<<<<<<<<<<
  3055. * if PY_MAJOR_VERSION < 3:
  3056. * self.stream_name = '<file>'
  3057. */
  3058. __pyx_t_6 = __Pyx_PyErr_ExceptionMatches(__pyx_builtin_AttributeError);
  3059. if (__pyx_t_6) {
  3060. __Pyx_AddTraceback("_yaml.CParser.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  3061. if (__Pyx_GetException(&__pyx_t_8, &__pyx_t_7, &__pyx_t_5) < 0) __PYX_ERR(0, 277, __pyx_L15_except_error)
  3062. __Pyx_GOTREF(__pyx_t_8);
  3063. __Pyx_GOTREF(__pyx_t_7);
  3064. __Pyx_GOTREF(__pyx_t_5);
  3065. /* "_yaml.pyx":278
  3066. * self.stream_name = stream.name
  3067. * except AttributeError:
  3068. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  3069. * self.stream_name = '<file>'
  3070. * else:
  3071. */
  3072. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  3073. if (__pyx_t_1) {
  3074. /* "_yaml.pyx":279
  3075. * except AttributeError:
  3076. * if PY_MAJOR_VERSION < 3:
  3077. * self.stream_name = '<file>' # <<<<<<<<<<<<<<
  3078. * else:
  3079. * self.stream_name = u'<file>'
  3080. */
  3081. __Pyx_INCREF(__pyx_kp_s_file);
  3082. __Pyx_GIVEREF(__pyx_kp_s_file);
  3083. __Pyx_GOTREF(__pyx_v_self->stream_name);
  3084. __Pyx_DECREF(__pyx_v_self->stream_name);
  3085. __pyx_v_self->stream_name = __pyx_kp_s_file;
  3086. /* "_yaml.pyx":278
  3087. * self.stream_name = stream.name
  3088. * except AttributeError:
  3089. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  3090. * self.stream_name = '<file>'
  3091. * else:
  3092. */
  3093. goto __pyx_L21;
  3094. }
  3095. /* "_yaml.pyx":281
  3096. * self.stream_name = '<file>'
  3097. * else:
  3098. * self.stream_name = u'<file>' # <<<<<<<<<<<<<<
  3099. * self.stream_cache = None
  3100. * self.stream_cache_len = 0
  3101. */
  3102. /*else*/ {
  3103. __Pyx_INCREF(__pyx_kp_u_file);
  3104. __Pyx_GIVEREF(__pyx_kp_u_file);
  3105. __Pyx_GOTREF(__pyx_v_self->stream_name);
  3106. __Pyx_DECREF(__pyx_v_self->stream_name);
  3107. __pyx_v_self->stream_name = __pyx_kp_u_file;
  3108. }
  3109. __pyx_L21:;
  3110. __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
  3111. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  3112. __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
  3113. goto __pyx_L14_exception_handled;
  3114. }
  3115. goto __pyx_L15_except_error;
  3116. __pyx_L15_except_error:;
  3117. /* "_yaml.pyx":275
  3118. * if is_readable:
  3119. * self.stream = stream
  3120. * try: # <<<<<<<<<<<<<<
  3121. * self.stream_name = stream.name
  3122. * except AttributeError:
  3123. */
  3124. __Pyx_XGIVEREF(__pyx_t_4);
  3125. __Pyx_XGIVEREF(__pyx_t_3);
  3126. __Pyx_XGIVEREF(__pyx_t_2);
  3127. __Pyx_ExceptionReset(__pyx_t_4, __pyx_t_3, __pyx_t_2);
  3128. goto __pyx_L1_error;
  3129. __pyx_L14_exception_handled:;
  3130. __Pyx_XGIVEREF(__pyx_t_4);
  3131. __Pyx_XGIVEREF(__pyx_t_3);
  3132. __Pyx_XGIVEREF(__pyx_t_2);
  3133. __Pyx_ExceptionReset(__pyx_t_4, __pyx_t_3, __pyx_t_2);
  3134. __pyx_L18_try_end:;
  3135. }
  3136. /* "_yaml.pyx":282
  3137. * else:
  3138. * self.stream_name = u'<file>'
  3139. * self.stream_cache = None # <<<<<<<<<<<<<<
  3140. * self.stream_cache_len = 0
  3141. * self.stream_cache_pos = 0
  3142. */
  3143. __Pyx_INCREF(Py_None);
  3144. __Pyx_GIVEREF(Py_None);
  3145. __Pyx_GOTREF(__pyx_v_self->stream_cache);
  3146. __Pyx_DECREF(__pyx_v_self->stream_cache);
  3147. __pyx_v_self->stream_cache = Py_None;
  3148. /* "_yaml.pyx":283
  3149. * self.stream_name = u'<file>'
  3150. * self.stream_cache = None
  3151. * self.stream_cache_len = 0 # <<<<<<<<<<<<<<
  3152. * self.stream_cache_pos = 0
  3153. * yaml_parser_set_input(&self.parser, input_handler, <void *>self)
  3154. */
  3155. __pyx_v_self->stream_cache_len = 0;
  3156. /* "_yaml.pyx":284
  3157. * self.stream_cache = None
  3158. * self.stream_cache_len = 0
  3159. * self.stream_cache_pos = 0 # <<<<<<<<<<<<<<
  3160. * yaml_parser_set_input(&self.parser, input_handler, <void *>self)
  3161. * else:
  3162. */
  3163. __pyx_v_self->stream_cache_pos = 0;
  3164. /* "_yaml.pyx":285
  3165. * self.stream_cache_len = 0
  3166. * self.stream_cache_pos = 0
  3167. * yaml_parser_set_input(&self.parser, input_handler, <void *>self) # <<<<<<<<<<<<<<
  3168. * else:
  3169. * if PyUnicode_CheckExact(stream) != 0:
  3170. */
  3171. yaml_parser_set_input((&__pyx_v_self->parser), __pyx_f_5_yaml_input_handler, ((void *)__pyx_v_self));
  3172. /* "_yaml.pyx":273
  3173. * is_readable = 0
  3174. * self.unicode_source = 0
  3175. * if is_readable: # <<<<<<<<<<<<<<
  3176. * self.stream = stream
  3177. * try:
  3178. */
  3179. goto __pyx_L12;
  3180. }
  3181. /* "_yaml.pyx":287
  3182. * yaml_parser_set_input(&self.parser, input_handler, <void *>self)
  3183. * else:
  3184. * if PyUnicode_CheckExact(stream) != 0: # <<<<<<<<<<<<<<
  3185. * stream = PyUnicode_AsUTF8String(stream)
  3186. * if PY_MAJOR_VERSION < 3:
  3187. */
  3188. /*else*/ {
  3189. __pyx_t_1 = ((PyUnicode_CheckExact(__pyx_v_stream) != 0) != 0);
  3190. if (__pyx_t_1) {
  3191. /* "_yaml.pyx":288
  3192. * else:
  3193. * if PyUnicode_CheckExact(stream) != 0:
  3194. * stream = PyUnicode_AsUTF8String(stream) # <<<<<<<<<<<<<<
  3195. * if PY_MAJOR_VERSION < 3:
  3196. * self.stream_name = '<unicode string>'
  3197. */
  3198. __pyx_t_5 = PyUnicode_AsUTF8String(__pyx_v_stream); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 288, __pyx_L1_error)
  3199. __Pyx_GOTREF(__pyx_t_5);
  3200. __Pyx_DECREF_SET(__pyx_v_stream, __pyx_t_5);
  3201. __pyx_t_5 = 0;
  3202. /* "_yaml.pyx":289
  3203. * if PyUnicode_CheckExact(stream) != 0:
  3204. * stream = PyUnicode_AsUTF8String(stream)
  3205. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  3206. * self.stream_name = '<unicode string>'
  3207. * else:
  3208. */
  3209. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  3210. if (__pyx_t_1) {
  3211. /* "_yaml.pyx":290
  3212. * stream = PyUnicode_AsUTF8String(stream)
  3213. * if PY_MAJOR_VERSION < 3:
  3214. * self.stream_name = '<unicode string>' # <<<<<<<<<<<<<<
  3215. * else:
  3216. * self.stream_name = u'<unicode string>'
  3217. */
  3218. __Pyx_INCREF(__pyx_kp_s_unicode_string);
  3219. __Pyx_GIVEREF(__pyx_kp_s_unicode_string);
  3220. __Pyx_GOTREF(__pyx_v_self->stream_name);
  3221. __Pyx_DECREF(__pyx_v_self->stream_name);
  3222. __pyx_v_self->stream_name = __pyx_kp_s_unicode_string;
  3223. /* "_yaml.pyx":289
  3224. * if PyUnicode_CheckExact(stream) != 0:
  3225. * stream = PyUnicode_AsUTF8String(stream)
  3226. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  3227. * self.stream_name = '<unicode string>'
  3228. * else:
  3229. */
  3230. goto __pyx_L23;
  3231. }
  3232. /* "_yaml.pyx":292
  3233. * self.stream_name = '<unicode string>'
  3234. * else:
  3235. * self.stream_name = u'<unicode string>' # <<<<<<<<<<<<<<
  3236. * self.unicode_source = 1
  3237. * else:
  3238. */
  3239. /*else*/ {
  3240. __Pyx_INCREF(__pyx_kp_u_unicode_string);
  3241. __Pyx_GIVEREF(__pyx_kp_u_unicode_string);
  3242. __Pyx_GOTREF(__pyx_v_self->stream_name);
  3243. __Pyx_DECREF(__pyx_v_self->stream_name);
  3244. __pyx_v_self->stream_name = __pyx_kp_u_unicode_string;
  3245. }
  3246. __pyx_L23:;
  3247. /* "_yaml.pyx":293
  3248. * else:
  3249. * self.stream_name = u'<unicode string>'
  3250. * self.unicode_source = 1 # <<<<<<<<<<<<<<
  3251. * else:
  3252. * if PY_MAJOR_VERSION < 3:
  3253. */
  3254. __pyx_v_self->unicode_source = 1;
  3255. /* "_yaml.pyx":287
  3256. * yaml_parser_set_input(&self.parser, input_handler, <void *>self)
  3257. * else:
  3258. * if PyUnicode_CheckExact(stream) != 0: # <<<<<<<<<<<<<<
  3259. * stream = PyUnicode_AsUTF8String(stream)
  3260. * if PY_MAJOR_VERSION < 3:
  3261. */
  3262. goto __pyx_L22;
  3263. }
  3264. /* "_yaml.pyx":295
  3265. * self.unicode_source = 1
  3266. * else:
  3267. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  3268. * self.stream_name = '<byte string>'
  3269. * else:
  3270. */
  3271. /*else*/ {
  3272. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  3273. if (__pyx_t_1) {
  3274. /* "_yaml.pyx":296
  3275. * else:
  3276. * if PY_MAJOR_VERSION < 3:
  3277. * self.stream_name = '<byte string>' # <<<<<<<<<<<<<<
  3278. * else:
  3279. * self.stream_name = u'<byte string>'
  3280. */
  3281. __Pyx_INCREF(__pyx_kp_s_byte_string);
  3282. __Pyx_GIVEREF(__pyx_kp_s_byte_string);
  3283. __Pyx_GOTREF(__pyx_v_self->stream_name);
  3284. __Pyx_DECREF(__pyx_v_self->stream_name);
  3285. __pyx_v_self->stream_name = __pyx_kp_s_byte_string;
  3286. /* "_yaml.pyx":295
  3287. * self.unicode_source = 1
  3288. * else:
  3289. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  3290. * self.stream_name = '<byte string>'
  3291. * else:
  3292. */
  3293. goto __pyx_L24;
  3294. }
  3295. /* "_yaml.pyx":298
  3296. * self.stream_name = '<byte string>'
  3297. * else:
  3298. * self.stream_name = u'<byte string>' # <<<<<<<<<<<<<<
  3299. * if PyString_CheckExact(stream) == 0:
  3300. * if PY_MAJOR_VERSION < 3:
  3301. */
  3302. /*else*/ {
  3303. __Pyx_INCREF(__pyx_kp_u_byte_string);
  3304. __Pyx_GIVEREF(__pyx_kp_u_byte_string);
  3305. __Pyx_GOTREF(__pyx_v_self->stream_name);
  3306. __Pyx_DECREF(__pyx_v_self->stream_name);
  3307. __pyx_v_self->stream_name = __pyx_kp_u_byte_string;
  3308. }
  3309. __pyx_L24:;
  3310. }
  3311. __pyx_L22:;
  3312. /* "_yaml.pyx":299
  3313. * else:
  3314. * self.stream_name = u'<byte string>'
  3315. * if PyString_CheckExact(stream) == 0: # <<<<<<<<<<<<<<
  3316. * if PY_MAJOR_VERSION < 3:
  3317. * raise TypeError("a string or stream input is required")
  3318. */
  3319. __pyx_t_1 = ((PyString_CheckExact(__pyx_v_stream) == 0) != 0);
  3320. if (__pyx_t_1) {
  3321. /* "_yaml.pyx":300
  3322. * self.stream_name = u'<byte string>'
  3323. * if PyString_CheckExact(stream) == 0:
  3324. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  3325. * raise TypeError("a string or stream input is required")
  3326. * else:
  3327. */
  3328. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  3329. if (unlikely(__pyx_t_1)) {
  3330. /* "_yaml.pyx":301
  3331. * if PyString_CheckExact(stream) == 0:
  3332. * if PY_MAJOR_VERSION < 3:
  3333. * raise TypeError("a string or stream input is required") # <<<<<<<<<<<<<<
  3334. * else:
  3335. * raise TypeError(u"a string or stream input is required")
  3336. */
  3337. __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple_, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 301, __pyx_L1_error)
  3338. __Pyx_GOTREF(__pyx_t_5);
  3339. __Pyx_Raise(__pyx_t_5, 0, 0, 0);
  3340. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  3341. __PYX_ERR(0, 301, __pyx_L1_error)
  3342. /* "_yaml.pyx":300
  3343. * self.stream_name = u'<byte string>'
  3344. * if PyString_CheckExact(stream) == 0:
  3345. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  3346. * raise TypeError("a string or stream input is required")
  3347. * else:
  3348. */
  3349. }
  3350. /* "_yaml.pyx":303
  3351. * raise TypeError("a string or stream input is required")
  3352. * else:
  3353. * raise TypeError(u"a string or stream input is required") # <<<<<<<<<<<<<<
  3354. * self.stream = stream
  3355. * yaml_parser_set_input_string(&self.parser, PyString_AS_STRING(stream), PyString_GET_SIZE(stream))
  3356. */
  3357. /*else*/ {
  3358. __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__2, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 303, __pyx_L1_error)
  3359. __Pyx_GOTREF(__pyx_t_5);
  3360. __Pyx_Raise(__pyx_t_5, 0, 0, 0);
  3361. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  3362. __PYX_ERR(0, 303, __pyx_L1_error)
  3363. }
  3364. /* "_yaml.pyx":299
  3365. * else:
  3366. * self.stream_name = u'<byte string>'
  3367. * if PyString_CheckExact(stream) == 0: # <<<<<<<<<<<<<<
  3368. * if PY_MAJOR_VERSION < 3:
  3369. * raise TypeError("a string or stream input is required")
  3370. */
  3371. }
  3372. /* "_yaml.pyx":304
  3373. * else:
  3374. * raise TypeError(u"a string or stream input is required")
  3375. * self.stream = stream # <<<<<<<<<<<<<<
  3376. * yaml_parser_set_input_string(&self.parser, PyString_AS_STRING(stream), PyString_GET_SIZE(stream))
  3377. * self.current_token = None
  3378. */
  3379. __Pyx_INCREF(__pyx_v_stream);
  3380. __Pyx_GIVEREF(__pyx_v_stream);
  3381. __Pyx_GOTREF(__pyx_v_self->stream);
  3382. __Pyx_DECREF(__pyx_v_self->stream);
  3383. __pyx_v_self->stream = __pyx_v_stream;
  3384. /* "_yaml.pyx":305
  3385. * raise TypeError(u"a string or stream input is required")
  3386. * self.stream = stream
  3387. * yaml_parser_set_input_string(&self.parser, PyString_AS_STRING(stream), PyString_GET_SIZE(stream)) # <<<<<<<<<<<<<<
  3388. * self.current_token = None
  3389. * self.current_event = None
  3390. */
  3391. yaml_parser_set_input_string((&__pyx_v_self->parser), PyString_AS_STRING(__pyx_v_stream), PyString_GET_SIZE(__pyx_v_stream));
  3392. }
  3393. __pyx_L12:;
  3394. /* "_yaml.pyx":306
  3395. * self.stream = stream
  3396. * yaml_parser_set_input_string(&self.parser, PyString_AS_STRING(stream), PyString_GET_SIZE(stream))
  3397. * self.current_token = None # <<<<<<<<<<<<<<
  3398. * self.current_event = None
  3399. * self.anchors = {}
  3400. */
  3401. __Pyx_INCREF(Py_None);
  3402. __Pyx_GIVEREF(Py_None);
  3403. __Pyx_GOTREF(__pyx_v_self->current_token);
  3404. __Pyx_DECREF(__pyx_v_self->current_token);
  3405. __pyx_v_self->current_token = Py_None;
  3406. /* "_yaml.pyx":307
  3407. * yaml_parser_set_input_string(&self.parser, PyString_AS_STRING(stream), PyString_GET_SIZE(stream))
  3408. * self.current_token = None
  3409. * self.current_event = None # <<<<<<<<<<<<<<
  3410. * self.anchors = {}
  3411. *
  3412. */
  3413. __Pyx_INCREF(Py_None);
  3414. __Pyx_GIVEREF(Py_None);
  3415. __Pyx_GOTREF(__pyx_v_self->current_event);
  3416. __Pyx_DECREF(__pyx_v_self->current_event);
  3417. __pyx_v_self->current_event = Py_None;
  3418. /* "_yaml.pyx":308
  3419. * self.current_token = None
  3420. * self.current_event = None
  3421. * self.anchors = {} # <<<<<<<<<<<<<<
  3422. *
  3423. * def __dealloc__(self):
  3424. */
  3425. __pyx_t_5 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 308, __pyx_L1_error)
  3426. __Pyx_GOTREF(__pyx_t_5);
  3427. __Pyx_GIVEREF(__pyx_t_5);
  3428. __Pyx_GOTREF(__pyx_v_self->anchors);
  3429. __Pyx_DECREF(__pyx_v_self->anchors);
  3430. __pyx_v_self->anchors = __pyx_t_5;
  3431. __pyx_t_5 = 0;
  3432. /* "_yaml.pyx":262
  3433. * cdef int unicode_source
  3434. *
  3435. * def __init__(self, stream): # <<<<<<<<<<<<<<
  3436. * cdef is_readable
  3437. * if yaml_parser_initialize(&self.parser) == 0:
  3438. */
  3439. /* function exit code */
  3440. __pyx_r = 0;
  3441. goto __pyx_L0;
  3442. __pyx_L1_error:;
  3443. __Pyx_XDECREF(__pyx_t_5);
  3444. __Pyx_XDECREF(__pyx_t_7);
  3445. __Pyx_XDECREF(__pyx_t_8);
  3446. __Pyx_AddTraceback("_yaml.CParser.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  3447. __pyx_r = -1;
  3448. __pyx_L0:;
  3449. __Pyx_XDECREF(__pyx_v_is_readable);
  3450. __Pyx_XDECREF(__pyx_v_stream);
  3451. __Pyx_RefNannyFinishContext();
  3452. return __pyx_r;
  3453. }
  3454. /* "_yaml.pyx":310
  3455. * self.anchors = {}
  3456. *
  3457. * def __dealloc__(self): # <<<<<<<<<<<<<<
  3458. * yaml_parser_delete(&self.parser)
  3459. * yaml_event_delete(&self.parsed_event)
  3460. */
  3461. /* Python wrapper */
  3462. static void __pyx_pw_5_yaml_7CParser_3__dealloc__(PyObject *__pyx_v_self); /*proto*/
  3463. static void __pyx_pw_5_yaml_7CParser_3__dealloc__(PyObject *__pyx_v_self) {
  3464. __Pyx_RefNannyDeclarations
  3465. __Pyx_RefNannySetupContext("__dealloc__ (wrapper)", 0);
  3466. __pyx_pf_5_yaml_7CParser_2__dealloc__(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self));
  3467. /* function exit code */
  3468. __Pyx_RefNannyFinishContext();
  3469. }
  3470. static void __pyx_pf_5_yaml_7CParser_2__dealloc__(struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  3471. __Pyx_RefNannyDeclarations
  3472. __Pyx_RefNannySetupContext("__dealloc__", 0);
  3473. /* "_yaml.pyx":311
  3474. *
  3475. * def __dealloc__(self):
  3476. * yaml_parser_delete(&self.parser) # <<<<<<<<<<<<<<
  3477. * yaml_event_delete(&self.parsed_event)
  3478. *
  3479. */
  3480. yaml_parser_delete((&__pyx_v_self->parser));
  3481. /* "_yaml.pyx":312
  3482. * def __dealloc__(self):
  3483. * yaml_parser_delete(&self.parser)
  3484. * yaml_event_delete(&self.parsed_event) # <<<<<<<<<<<<<<
  3485. *
  3486. * def dispose(self):
  3487. */
  3488. yaml_event_delete((&__pyx_v_self->parsed_event));
  3489. /* "_yaml.pyx":310
  3490. * self.anchors = {}
  3491. *
  3492. * def __dealloc__(self): # <<<<<<<<<<<<<<
  3493. * yaml_parser_delete(&self.parser)
  3494. * yaml_event_delete(&self.parsed_event)
  3495. */
  3496. /* function exit code */
  3497. __Pyx_RefNannyFinishContext();
  3498. }
  3499. /* "_yaml.pyx":314
  3500. * yaml_event_delete(&self.parsed_event)
  3501. *
  3502. * def dispose(self): # <<<<<<<<<<<<<<
  3503. * pass
  3504. *
  3505. */
  3506. /* Python wrapper */
  3507. static PyObject *__pyx_pw_5_yaml_7CParser_5dispose(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  3508. static PyObject *__pyx_pw_5_yaml_7CParser_5dispose(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  3509. PyObject *__pyx_r = 0;
  3510. __Pyx_RefNannyDeclarations
  3511. __Pyx_RefNannySetupContext("dispose (wrapper)", 0);
  3512. __pyx_r = __pyx_pf_5_yaml_7CParser_4dispose(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self));
  3513. /* function exit code */
  3514. __Pyx_RefNannyFinishContext();
  3515. return __pyx_r;
  3516. }
  3517. static PyObject *__pyx_pf_5_yaml_7CParser_4dispose(CYTHON_UNUSED struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  3518. PyObject *__pyx_r = NULL;
  3519. __Pyx_RefNannyDeclarations
  3520. __Pyx_RefNannySetupContext("dispose", 0);
  3521. /* function exit code */
  3522. __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  3523. __Pyx_XGIVEREF(__pyx_r);
  3524. __Pyx_RefNannyFinishContext();
  3525. return __pyx_r;
  3526. }
  3527. /* "_yaml.pyx":317
  3528. * pass
  3529. *
  3530. * cdef object _parser_error(self): # <<<<<<<<<<<<<<
  3531. * if self.parser.error == YAML_MEMORY_ERROR:
  3532. * return MemoryError
  3533. */
  3534. static PyObject *__pyx_f_5_yaml_7CParser__parser_error(struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  3535. struct __pyx_obj_5_yaml_Mark *__pyx_v_context_mark = NULL;
  3536. struct __pyx_obj_5_yaml_Mark *__pyx_v_problem_mark = NULL;
  3537. PyObject *__pyx_v_context = NULL;
  3538. PyObject *__pyx_v_problem = NULL;
  3539. PyObject *__pyx_r = NULL;
  3540. __Pyx_RefNannyDeclarations
  3541. int __pyx_t_1;
  3542. PyObject *__pyx_t_2 = NULL;
  3543. PyObject *__pyx_t_3 = NULL;
  3544. PyObject *__pyx_t_4 = NULL;
  3545. PyObject *__pyx_t_5 = NULL;
  3546. PyObject *__pyx_t_6 = NULL;
  3547. PyObject *__pyx_t_7 = NULL;
  3548. int __pyx_t_8;
  3549. PyObject *__pyx_t_9 = NULL;
  3550. __Pyx_RefNannySetupContext("_parser_error", 0);
  3551. /* "_yaml.pyx":318
  3552. *
  3553. * cdef object _parser_error(self):
  3554. * if self.parser.error == YAML_MEMORY_ERROR: # <<<<<<<<<<<<<<
  3555. * return MemoryError
  3556. * elif self.parser.error == YAML_READER_ERROR:
  3557. */
  3558. switch (__pyx_v_self->parser.error) {
  3559. case YAML_MEMORY_ERROR:
  3560. /* "_yaml.pyx":319
  3561. * cdef object _parser_error(self):
  3562. * if self.parser.error == YAML_MEMORY_ERROR:
  3563. * return MemoryError # <<<<<<<<<<<<<<
  3564. * elif self.parser.error == YAML_READER_ERROR:
  3565. * if PY_MAJOR_VERSION < 3:
  3566. */
  3567. __Pyx_XDECREF(__pyx_r);
  3568. __Pyx_INCREF(__pyx_builtin_MemoryError);
  3569. __pyx_r = __pyx_builtin_MemoryError;
  3570. goto __pyx_L0;
  3571. /* "_yaml.pyx":318
  3572. *
  3573. * cdef object _parser_error(self):
  3574. * if self.parser.error == YAML_MEMORY_ERROR: # <<<<<<<<<<<<<<
  3575. * return MemoryError
  3576. * elif self.parser.error == YAML_READER_ERROR:
  3577. */
  3578. break;
  3579. case YAML_READER_ERROR:
  3580. /* "_yaml.pyx":321
  3581. * return MemoryError
  3582. * elif self.parser.error == YAML_READER_ERROR:
  3583. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  3584. * return ReaderError(self.stream_name, self.parser.problem_offset,
  3585. * self.parser.problem_value, '?', self.parser.problem)
  3586. */
  3587. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  3588. if (__pyx_t_1) {
  3589. /* "_yaml.pyx":322
  3590. * elif self.parser.error == YAML_READER_ERROR:
  3591. * if PY_MAJOR_VERSION < 3:
  3592. * return ReaderError(self.stream_name, self.parser.problem_offset, # <<<<<<<<<<<<<<
  3593. * self.parser.problem_value, '?', self.parser.problem)
  3594. * else:
  3595. */
  3596. __Pyx_XDECREF(__pyx_r);
  3597. __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_ReaderError); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 322, __pyx_L1_error)
  3598. __Pyx_GOTREF(__pyx_t_3);
  3599. __pyx_t_4 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parser.problem_offset); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 322, __pyx_L1_error)
  3600. __Pyx_GOTREF(__pyx_t_4);
  3601. /* "_yaml.pyx":323
  3602. * if PY_MAJOR_VERSION < 3:
  3603. * return ReaderError(self.stream_name, self.parser.problem_offset,
  3604. * self.parser.problem_value, '?', self.parser.problem) # <<<<<<<<<<<<<<
  3605. * else:
  3606. * return ReaderError(self.stream_name, self.parser.problem_offset,
  3607. */
  3608. __pyx_t_5 = __Pyx_PyInt_From_int(__pyx_v_self->parser.problem_value); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 323, __pyx_L1_error)
  3609. __Pyx_GOTREF(__pyx_t_5);
  3610. __pyx_t_6 = __Pyx_PyBytes_FromString(__pyx_v_self->parser.problem); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 323, __pyx_L1_error)
  3611. __Pyx_GOTREF(__pyx_t_6);
  3612. __pyx_t_7 = NULL;
  3613. __pyx_t_8 = 0;
  3614. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
  3615. __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_3);
  3616. if (likely(__pyx_t_7)) {
  3617. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
  3618. __Pyx_INCREF(__pyx_t_7);
  3619. __Pyx_INCREF(function);
  3620. __Pyx_DECREF_SET(__pyx_t_3, function);
  3621. __pyx_t_8 = 1;
  3622. }
  3623. }
  3624. #if CYTHON_FAST_PYCALL
  3625. if (PyFunction_Check(__pyx_t_3)) {
  3626. PyObject *__pyx_temp[6] = {__pyx_t_7, __pyx_v_self->stream_name, __pyx_t_4, __pyx_t_5, __pyx_kp_s__3, __pyx_t_6};
  3627. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_8, 5+__pyx_t_8); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 322, __pyx_L1_error)
  3628. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  3629. __Pyx_GOTREF(__pyx_t_2);
  3630. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  3631. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  3632. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  3633. } else
  3634. #endif
  3635. #if CYTHON_FAST_PYCCALL
  3636. if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) {
  3637. PyObject *__pyx_temp[6] = {__pyx_t_7, __pyx_v_self->stream_name, __pyx_t_4, __pyx_t_5, __pyx_kp_s__3, __pyx_t_6};
  3638. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_8, 5+__pyx_t_8); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 322, __pyx_L1_error)
  3639. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  3640. __Pyx_GOTREF(__pyx_t_2);
  3641. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  3642. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  3643. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  3644. } else
  3645. #endif
  3646. {
  3647. __pyx_t_9 = PyTuple_New(5+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 322, __pyx_L1_error)
  3648. __Pyx_GOTREF(__pyx_t_9);
  3649. if (__pyx_t_7) {
  3650. __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_7); __pyx_t_7 = NULL;
  3651. }
  3652. __Pyx_INCREF(__pyx_v_self->stream_name);
  3653. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  3654. PyTuple_SET_ITEM(__pyx_t_9, 0+__pyx_t_8, __pyx_v_self->stream_name);
  3655. __Pyx_GIVEREF(__pyx_t_4);
  3656. PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_8, __pyx_t_4);
  3657. __Pyx_GIVEREF(__pyx_t_5);
  3658. PyTuple_SET_ITEM(__pyx_t_9, 2+__pyx_t_8, __pyx_t_5);
  3659. __Pyx_INCREF(__pyx_kp_s__3);
  3660. __Pyx_GIVEREF(__pyx_kp_s__3);
  3661. PyTuple_SET_ITEM(__pyx_t_9, 3+__pyx_t_8, __pyx_kp_s__3);
  3662. __Pyx_GIVEREF(__pyx_t_6);
  3663. PyTuple_SET_ITEM(__pyx_t_9, 4+__pyx_t_8, __pyx_t_6);
  3664. __pyx_t_4 = 0;
  3665. __pyx_t_5 = 0;
  3666. __pyx_t_6 = 0;
  3667. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_9, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 322, __pyx_L1_error)
  3668. __Pyx_GOTREF(__pyx_t_2);
  3669. __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
  3670. }
  3671. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  3672. __pyx_r = __pyx_t_2;
  3673. __pyx_t_2 = 0;
  3674. goto __pyx_L0;
  3675. /* "_yaml.pyx":321
  3676. * return MemoryError
  3677. * elif self.parser.error == YAML_READER_ERROR:
  3678. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  3679. * return ReaderError(self.stream_name, self.parser.problem_offset,
  3680. * self.parser.problem_value, '?', self.parser.problem)
  3681. */
  3682. }
  3683. /* "_yaml.pyx":325
  3684. * self.parser.problem_value, '?', self.parser.problem)
  3685. * else:
  3686. * return ReaderError(self.stream_name, self.parser.problem_offset, # <<<<<<<<<<<<<<
  3687. * self.parser.problem_value, u'?', PyUnicode_FromString(self.parser.problem))
  3688. * elif self.parser.error == YAML_SCANNER_ERROR \
  3689. */
  3690. /*else*/ {
  3691. __Pyx_XDECREF(__pyx_r);
  3692. __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_ReaderError); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 325, __pyx_L1_error)
  3693. __Pyx_GOTREF(__pyx_t_3);
  3694. __pyx_t_9 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parser.problem_offset); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 325, __pyx_L1_error)
  3695. __Pyx_GOTREF(__pyx_t_9);
  3696. /* "_yaml.pyx":326
  3697. * else:
  3698. * return ReaderError(self.stream_name, self.parser.problem_offset,
  3699. * self.parser.problem_value, u'?', PyUnicode_FromString(self.parser.problem)) # <<<<<<<<<<<<<<
  3700. * elif self.parser.error == YAML_SCANNER_ERROR \
  3701. * or self.parser.error == YAML_PARSER_ERROR:
  3702. */
  3703. __pyx_t_6 = __Pyx_PyInt_From_int(__pyx_v_self->parser.problem_value); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 326, __pyx_L1_error)
  3704. __Pyx_GOTREF(__pyx_t_6);
  3705. __pyx_t_5 = PyUnicode_FromString(__pyx_v_self->parser.problem); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 326, __pyx_L1_error)
  3706. __Pyx_GOTREF(__pyx_t_5);
  3707. __pyx_t_4 = NULL;
  3708. __pyx_t_8 = 0;
  3709. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
  3710. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
  3711. if (likely(__pyx_t_4)) {
  3712. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
  3713. __Pyx_INCREF(__pyx_t_4);
  3714. __Pyx_INCREF(function);
  3715. __Pyx_DECREF_SET(__pyx_t_3, function);
  3716. __pyx_t_8 = 1;
  3717. }
  3718. }
  3719. #if CYTHON_FAST_PYCALL
  3720. if (PyFunction_Check(__pyx_t_3)) {
  3721. PyObject *__pyx_temp[6] = {__pyx_t_4, __pyx_v_self->stream_name, __pyx_t_9, __pyx_t_6, __pyx_kp_u__3, __pyx_t_5};
  3722. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_8, 5+__pyx_t_8); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 325, __pyx_L1_error)
  3723. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  3724. __Pyx_GOTREF(__pyx_t_2);
  3725. __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
  3726. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  3727. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  3728. } else
  3729. #endif
  3730. #if CYTHON_FAST_PYCCALL
  3731. if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) {
  3732. PyObject *__pyx_temp[6] = {__pyx_t_4, __pyx_v_self->stream_name, __pyx_t_9, __pyx_t_6, __pyx_kp_u__3, __pyx_t_5};
  3733. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_8, 5+__pyx_t_8); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 325, __pyx_L1_error)
  3734. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  3735. __Pyx_GOTREF(__pyx_t_2);
  3736. __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
  3737. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  3738. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  3739. } else
  3740. #endif
  3741. {
  3742. __pyx_t_7 = PyTuple_New(5+__pyx_t_8); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 325, __pyx_L1_error)
  3743. __Pyx_GOTREF(__pyx_t_7);
  3744. if (__pyx_t_4) {
  3745. __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_4); __pyx_t_4 = NULL;
  3746. }
  3747. __Pyx_INCREF(__pyx_v_self->stream_name);
  3748. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  3749. PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_8, __pyx_v_self->stream_name);
  3750. __Pyx_GIVEREF(__pyx_t_9);
  3751. PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_8, __pyx_t_9);
  3752. __Pyx_GIVEREF(__pyx_t_6);
  3753. PyTuple_SET_ITEM(__pyx_t_7, 2+__pyx_t_8, __pyx_t_6);
  3754. __Pyx_INCREF(__pyx_kp_u__3);
  3755. __Pyx_GIVEREF(__pyx_kp_u__3);
  3756. PyTuple_SET_ITEM(__pyx_t_7, 3+__pyx_t_8, __pyx_kp_u__3);
  3757. __Pyx_GIVEREF(__pyx_t_5);
  3758. PyTuple_SET_ITEM(__pyx_t_7, 4+__pyx_t_8, __pyx_t_5);
  3759. __pyx_t_9 = 0;
  3760. __pyx_t_6 = 0;
  3761. __pyx_t_5 = 0;
  3762. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_7, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 325, __pyx_L1_error)
  3763. __Pyx_GOTREF(__pyx_t_2);
  3764. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  3765. }
  3766. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  3767. __pyx_r = __pyx_t_2;
  3768. __pyx_t_2 = 0;
  3769. goto __pyx_L0;
  3770. }
  3771. /* "_yaml.pyx":320
  3772. * if self.parser.error == YAML_MEMORY_ERROR:
  3773. * return MemoryError
  3774. * elif self.parser.error == YAML_READER_ERROR: # <<<<<<<<<<<<<<
  3775. * if PY_MAJOR_VERSION < 3:
  3776. * return ReaderError(self.stream_name, self.parser.problem_offset,
  3777. */
  3778. break;
  3779. case YAML_SCANNER_ERROR:
  3780. /* "_yaml.pyx":327
  3781. * return ReaderError(self.stream_name, self.parser.problem_offset,
  3782. * self.parser.problem_value, u'?', PyUnicode_FromString(self.parser.problem))
  3783. * elif self.parser.error == YAML_SCANNER_ERROR \ # <<<<<<<<<<<<<<
  3784. * or self.parser.error == YAML_PARSER_ERROR:
  3785. * context_mark = None
  3786. */
  3787. case YAML_PARSER_ERROR:
  3788. /* "_yaml.pyx":329
  3789. * elif self.parser.error == YAML_SCANNER_ERROR \
  3790. * or self.parser.error == YAML_PARSER_ERROR:
  3791. * context_mark = None # <<<<<<<<<<<<<<
  3792. * problem_mark = None
  3793. * if self.parser.context != NULL:
  3794. */
  3795. __Pyx_INCREF(Py_None);
  3796. __pyx_v_context_mark = ((struct __pyx_obj_5_yaml_Mark *)Py_None);
  3797. /* "_yaml.pyx":330
  3798. * or self.parser.error == YAML_PARSER_ERROR:
  3799. * context_mark = None
  3800. * problem_mark = None # <<<<<<<<<<<<<<
  3801. * if self.parser.context != NULL:
  3802. * context_mark = Mark(self.stream_name,
  3803. */
  3804. __Pyx_INCREF(Py_None);
  3805. __pyx_v_problem_mark = ((struct __pyx_obj_5_yaml_Mark *)Py_None);
  3806. /* "_yaml.pyx":331
  3807. * context_mark = None
  3808. * problem_mark = None
  3809. * if self.parser.context != NULL: # <<<<<<<<<<<<<<
  3810. * context_mark = Mark(self.stream_name,
  3811. * self.parser.context_mark.index,
  3812. */
  3813. __pyx_t_1 = ((__pyx_v_self->parser.context != NULL) != 0);
  3814. if (__pyx_t_1) {
  3815. /* "_yaml.pyx":333
  3816. * if self.parser.context != NULL:
  3817. * context_mark = Mark(self.stream_name,
  3818. * self.parser.context_mark.index, # <<<<<<<<<<<<<<
  3819. * self.parser.context_mark.line,
  3820. * self.parser.context_mark.column, None, None)
  3821. */
  3822. __pyx_t_2 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parser.context_mark.index); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 333, __pyx_L1_error)
  3823. __Pyx_GOTREF(__pyx_t_2);
  3824. /* "_yaml.pyx":334
  3825. * context_mark = Mark(self.stream_name,
  3826. * self.parser.context_mark.index,
  3827. * self.parser.context_mark.line, # <<<<<<<<<<<<<<
  3828. * self.parser.context_mark.column, None, None)
  3829. * if self.parser.problem != NULL:
  3830. */
  3831. __pyx_t_3 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parser.context_mark.line); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 334, __pyx_L1_error)
  3832. __Pyx_GOTREF(__pyx_t_3);
  3833. /* "_yaml.pyx":335
  3834. * self.parser.context_mark.index,
  3835. * self.parser.context_mark.line,
  3836. * self.parser.context_mark.column, None, None) # <<<<<<<<<<<<<<
  3837. * if self.parser.problem != NULL:
  3838. * problem_mark = Mark(self.stream_name,
  3839. */
  3840. __pyx_t_7 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parser.context_mark.column); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 335, __pyx_L1_error)
  3841. __Pyx_GOTREF(__pyx_t_7);
  3842. /* "_yaml.pyx":332
  3843. * problem_mark = None
  3844. * if self.parser.context != NULL:
  3845. * context_mark = Mark(self.stream_name, # <<<<<<<<<<<<<<
  3846. * self.parser.context_mark.index,
  3847. * self.parser.context_mark.line,
  3848. */
  3849. __pyx_t_5 = PyTuple_New(6); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 332, __pyx_L1_error)
  3850. __Pyx_GOTREF(__pyx_t_5);
  3851. __Pyx_INCREF(__pyx_v_self->stream_name);
  3852. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  3853. PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_v_self->stream_name);
  3854. __Pyx_GIVEREF(__pyx_t_2);
  3855. PyTuple_SET_ITEM(__pyx_t_5, 1, __pyx_t_2);
  3856. __Pyx_GIVEREF(__pyx_t_3);
  3857. PyTuple_SET_ITEM(__pyx_t_5, 2, __pyx_t_3);
  3858. __Pyx_GIVEREF(__pyx_t_7);
  3859. PyTuple_SET_ITEM(__pyx_t_5, 3, __pyx_t_7);
  3860. __Pyx_INCREF(Py_None);
  3861. __Pyx_GIVEREF(Py_None);
  3862. PyTuple_SET_ITEM(__pyx_t_5, 4, Py_None);
  3863. __Pyx_INCREF(Py_None);
  3864. __Pyx_GIVEREF(Py_None);
  3865. PyTuple_SET_ITEM(__pyx_t_5, 5, Py_None);
  3866. __pyx_t_2 = 0;
  3867. __pyx_t_3 = 0;
  3868. __pyx_t_7 = 0;
  3869. __pyx_t_7 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_t_5, NULL); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 332, __pyx_L1_error)
  3870. __Pyx_GOTREF(__pyx_t_7);
  3871. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  3872. __Pyx_DECREF_SET(__pyx_v_context_mark, ((struct __pyx_obj_5_yaml_Mark *)__pyx_t_7));
  3873. __pyx_t_7 = 0;
  3874. /* "_yaml.pyx":331
  3875. * context_mark = None
  3876. * problem_mark = None
  3877. * if self.parser.context != NULL: # <<<<<<<<<<<<<<
  3878. * context_mark = Mark(self.stream_name,
  3879. * self.parser.context_mark.index,
  3880. */
  3881. }
  3882. /* "_yaml.pyx":336
  3883. * self.parser.context_mark.line,
  3884. * self.parser.context_mark.column, None, None)
  3885. * if self.parser.problem != NULL: # <<<<<<<<<<<<<<
  3886. * problem_mark = Mark(self.stream_name,
  3887. * self.parser.problem_mark.index,
  3888. */
  3889. __pyx_t_1 = ((__pyx_v_self->parser.problem != NULL) != 0);
  3890. if (__pyx_t_1) {
  3891. /* "_yaml.pyx":338
  3892. * if self.parser.problem != NULL:
  3893. * problem_mark = Mark(self.stream_name,
  3894. * self.parser.problem_mark.index, # <<<<<<<<<<<<<<
  3895. * self.parser.problem_mark.line,
  3896. * self.parser.problem_mark.column, None, None)
  3897. */
  3898. __pyx_t_7 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parser.problem_mark.index); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 338, __pyx_L1_error)
  3899. __Pyx_GOTREF(__pyx_t_7);
  3900. /* "_yaml.pyx":339
  3901. * problem_mark = Mark(self.stream_name,
  3902. * self.parser.problem_mark.index,
  3903. * self.parser.problem_mark.line, # <<<<<<<<<<<<<<
  3904. * self.parser.problem_mark.column, None, None)
  3905. * context = None
  3906. */
  3907. __pyx_t_5 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parser.problem_mark.line); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 339, __pyx_L1_error)
  3908. __Pyx_GOTREF(__pyx_t_5);
  3909. /* "_yaml.pyx":340
  3910. * self.parser.problem_mark.index,
  3911. * self.parser.problem_mark.line,
  3912. * self.parser.problem_mark.column, None, None) # <<<<<<<<<<<<<<
  3913. * context = None
  3914. * if self.parser.context != NULL:
  3915. */
  3916. __pyx_t_3 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parser.problem_mark.column); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 340, __pyx_L1_error)
  3917. __Pyx_GOTREF(__pyx_t_3);
  3918. /* "_yaml.pyx":337
  3919. * self.parser.context_mark.column, None, None)
  3920. * if self.parser.problem != NULL:
  3921. * problem_mark = Mark(self.stream_name, # <<<<<<<<<<<<<<
  3922. * self.parser.problem_mark.index,
  3923. * self.parser.problem_mark.line,
  3924. */
  3925. __pyx_t_2 = PyTuple_New(6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 337, __pyx_L1_error)
  3926. __Pyx_GOTREF(__pyx_t_2);
  3927. __Pyx_INCREF(__pyx_v_self->stream_name);
  3928. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  3929. PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_v_self->stream_name);
  3930. __Pyx_GIVEREF(__pyx_t_7);
  3931. PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_7);
  3932. __Pyx_GIVEREF(__pyx_t_5);
  3933. PyTuple_SET_ITEM(__pyx_t_2, 2, __pyx_t_5);
  3934. __Pyx_GIVEREF(__pyx_t_3);
  3935. PyTuple_SET_ITEM(__pyx_t_2, 3, __pyx_t_3);
  3936. __Pyx_INCREF(Py_None);
  3937. __Pyx_GIVEREF(Py_None);
  3938. PyTuple_SET_ITEM(__pyx_t_2, 4, Py_None);
  3939. __Pyx_INCREF(Py_None);
  3940. __Pyx_GIVEREF(Py_None);
  3941. PyTuple_SET_ITEM(__pyx_t_2, 5, Py_None);
  3942. __pyx_t_7 = 0;
  3943. __pyx_t_5 = 0;
  3944. __pyx_t_3 = 0;
  3945. __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_t_2, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 337, __pyx_L1_error)
  3946. __Pyx_GOTREF(__pyx_t_3);
  3947. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  3948. __Pyx_DECREF_SET(__pyx_v_problem_mark, ((struct __pyx_obj_5_yaml_Mark *)__pyx_t_3));
  3949. __pyx_t_3 = 0;
  3950. /* "_yaml.pyx":336
  3951. * self.parser.context_mark.line,
  3952. * self.parser.context_mark.column, None, None)
  3953. * if self.parser.problem != NULL: # <<<<<<<<<<<<<<
  3954. * problem_mark = Mark(self.stream_name,
  3955. * self.parser.problem_mark.index,
  3956. */
  3957. }
  3958. /* "_yaml.pyx":341
  3959. * self.parser.problem_mark.line,
  3960. * self.parser.problem_mark.column, None, None)
  3961. * context = None # <<<<<<<<<<<<<<
  3962. * if self.parser.context != NULL:
  3963. * if PY_MAJOR_VERSION < 3:
  3964. */
  3965. __Pyx_INCREF(Py_None);
  3966. __pyx_v_context = Py_None;
  3967. /* "_yaml.pyx":342
  3968. * self.parser.problem_mark.column, None, None)
  3969. * context = None
  3970. * if self.parser.context != NULL: # <<<<<<<<<<<<<<
  3971. * if PY_MAJOR_VERSION < 3:
  3972. * context = self.parser.context
  3973. */
  3974. __pyx_t_1 = ((__pyx_v_self->parser.context != NULL) != 0);
  3975. if (__pyx_t_1) {
  3976. /* "_yaml.pyx":343
  3977. * context = None
  3978. * if self.parser.context != NULL:
  3979. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  3980. * context = self.parser.context
  3981. * else:
  3982. */
  3983. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  3984. if (__pyx_t_1) {
  3985. /* "_yaml.pyx":344
  3986. * if self.parser.context != NULL:
  3987. * if PY_MAJOR_VERSION < 3:
  3988. * context = self.parser.context # <<<<<<<<<<<<<<
  3989. * else:
  3990. * context = PyUnicode_FromString(self.parser.context)
  3991. */
  3992. __pyx_t_3 = __Pyx_PyBytes_FromString(__pyx_v_self->parser.context); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 344, __pyx_L1_error)
  3993. __Pyx_GOTREF(__pyx_t_3);
  3994. __Pyx_DECREF_SET(__pyx_v_context, __pyx_t_3);
  3995. __pyx_t_3 = 0;
  3996. /* "_yaml.pyx":343
  3997. * context = None
  3998. * if self.parser.context != NULL:
  3999. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  4000. * context = self.parser.context
  4001. * else:
  4002. */
  4003. goto __pyx_L7;
  4004. }
  4005. /* "_yaml.pyx":346
  4006. * context = self.parser.context
  4007. * else:
  4008. * context = PyUnicode_FromString(self.parser.context) # <<<<<<<<<<<<<<
  4009. * if PY_MAJOR_VERSION < 3:
  4010. * problem = self.parser.problem
  4011. */
  4012. /*else*/ {
  4013. __pyx_t_3 = PyUnicode_FromString(__pyx_v_self->parser.context); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 346, __pyx_L1_error)
  4014. __Pyx_GOTREF(__pyx_t_3);
  4015. __Pyx_DECREF_SET(__pyx_v_context, __pyx_t_3);
  4016. __pyx_t_3 = 0;
  4017. }
  4018. __pyx_L7:;
  4019. /* "_yaml.pyx":342
  4020. * self.parser.problem_mark.column, None, None)
  4021. * context = None
  4022. * if self.parser.context != NULL: # <<<<<<<<<<<<<<
  4023. * if PY_MAJOR_VERSION < 3:
  4024. * context = self.parser.context
  4025. */
  4026. }
  4027. /* "_yaml.pyx":347
  4028. * else:
  4029. * context = PyUnicode_FromString(self.parser.context)
  4030. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  4031. * problem = self.parser.problem
  4032. * else:
  4033. */
  4034. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  4035. if (__pyx_t_1) {
  4036. /* "_yaml.pyx":348
  4037. * context = PyUnicode_FromString(self.parser.context)
  4038. * if PY_MAJOR_VERSION < 3:
  4039. * problem = self.parser.problem # <<<<<<<<<<<<<<
  4040. * else:
  4041. * problem = PyUnicode_FromString(self.parser.problem)
  4042. */
  4043. __pyx_t_3 = __Pyx_PyBytes_FromString(__pyx_v_self->parser.problem); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 348, __pyx_L1_error)
  4044. __Pyx_GOTREF(__pyx_t_3);
  4045. __pyx_v_problem = __pyx_t_3;
  4046. __pyx_t_3 = 0;
  4047. /* "_yaml.pyx":347
  4048. * else:
  4049. * context = PyUnicode_FromString(self.parser.context)
  4050. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  4051. * problem = self.parser.problem
  4052. * else:
  4053. */
  4054. goto __pyx_L8;
  4055. }
  4056. /* "_yaml.pyx":350
  4057. * problem = self.parser.problem
  4058. * else:
  4059. * problem = PyUnicode_FromString(self.parser.problem) # <<<<<<<<<<<<<<
  4060. * if self.parser.error == YAML_SCANNER_ERROR:
  4061. * return ScannerError(context, context_mark, problem, problem_mark)
  4062. */
  4063. /*else*/ {
  4064. __pyx_t_3 = PyUnicode_FromString(__pyx_v_self->parser.problem); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 350, __pyx_L1_error)
  4065. __Pyx_GOTREF(__pyx_t_3);
  4066. __pyx_v_problem = __pyx_t_3;
  4067. __pyx_t_3 = 0;
  4068. }
  4069. __pyx_L8:;
  4070. /* "_yaml.pyx":351
  4071. * else:
  4072. * problem = PyUnicode_FromString(self.parser.problem)
  4073. * if self.parser.error == YAML_SCANNER_ERROR: # <<<<<<<<<<<<<<
  4074. * return ScannerError(context, context_mark, problem, problem_mark)
  4075. * else:
  4076. */
  4077. __pyx_t_1 = ((__pyx_v_self->parser.error == YAML_SCANNER_ERROR) != 0);
  4078. if (__pyx_t_1) {
  4079. /* "_yaml.pyx":352
  4080. * problem = PyUnicode_FromString(self.parser.problem)
  4081. * if self.parser.error == YAML_SCANNER_ERROR:
  4082. * return ScannerError(context, context_mark, problem, problem_mark) # <<<<<<<<<<<<<<
  4083. * else:
  4084. * return ParserError(context, context_mark, problem, problem_mark)
  4085. */
  4086. __Pyx_XDECREF(__pyx_r);
  4087. __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_ScannerError); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 352, __pyx_L1_error)
  4088. __Pyx_GOTREF(__pyx_t_2);
  4089. __pyx_t_5 = NULL;
  4090. __pyx_t_8 = 0;
  4091. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) {
  4092. __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_2);
  4093. if (likely(__pyx_t_5)) {
  4094. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
  4095. __Pyx_INCREF(__pyx_t_5);
  4096. __Pyx_INCREF(function);
  4097. __Pyx_DECREF_SET(__pyx_t_2, function);
  4098. __pyx_t_8 = 1;
  4099. }
  4100. }
  4101. #if CYTHON_FAST_PYCALL
  4102. if (PyFunction_Check(__pyx_t_2)) {
  4103. PyObject *__pyx_temp[5] = {__pyx_t_5, __pyx_v_context, ((PyObject *)__pyx_v_context_mark), __pyx_v_problem, ((PyObject *)__pyx_v_problem_mark)};
  4104. __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 4+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 352, __pyx_L1_error)
  4105. __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
  4106. __Pyx_GOTREF(__pyx_t_3);
  4107. } else
  4108. #endif
  4109. #if CYTHON_FAST_PYCCALL
  4110. if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) {
  4111. PyObject *__pyx_temp[5] = {__pyx_t_5, __pyx_v_context, ((PyObject *)__pyx_v_context_mark), __pyx_v_problem, ((PyObject *)__pyx_v_problem_mark)};
  4112. __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 4+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 352, __pyx_L1_error)
  4113. __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
  4114. __Pyx_GOTREF(__pyx_t_3);
  4115. } else
  4116. #endif
  4117. {
  4118. __pyx_t_7 = PyTuple_New(4+__pyx_t_8); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 352, __pyx_L1_error)
  4119. __Pyx_GOTREF(__pyx_t_7);
  4120. if (__pyx_t_5) {
  4121. __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_5); __pyx_t_5 = NULL;
  4122. }
  4123. __Pyx_INCREF(__pyx_v_context);
  4124. __Pyx_GIVEREF(__pyx_v_context);
  4125. PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_8, __pyx_v_context);
  4126. __Pyx_INCREF(((PyObject *)__pyx_v_context_mark));
  4127. __Pyx_GIVEREF(((PyObject *)__pyx_v_context_mark));
  4128. PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_8, ((PyObject *)__pyx_v_context_mark));
  4129. __Pyx_INCREF(__pyx_v_problem);
  4130. __Pyx_GIVEREF(__pyx_v_problem);
  4131. PyTuple_SET_ITEM(__pyx_t_7, 2+__pyx_t_8, __pyx_v_problem);
  4132. __Pyx_INCREF(((PyObject *)__pyx_v_problem_mark));
  4133. __Pyx_GIVEREF(((PyObject *)__pyx_v_problem_mark));
  4134. PyTuple_SET_ITEM(__pyx_t_7, 3+__pyx_t_8, ((PyObject *)__pyx_v_problem_mark));
  4135. __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_7, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 352, __pyx_L1_error)
  4136. __Pyx_GOTREF(__pyx_t_3);
  4137. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  4138. }
  4139. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  4140. __pyx_r = __pyx_t_3;
  4141. __pyx_t_3 = 0;
  4142. goto __pyx_L0;
  4143. /* "_yaml.pyx":351
  4144. * else:
  4145. * problem = PyUnicode_FromString(self.parser.problem)
  4146. * if self.parser.error == YAML_SCANNER_ERROR: # <<<<<<<<<<<<<<
  4147. * return ScannerError(context, context_mark, problem, problem_mark)
  4148. * else:
  4149. */
  4150. }
  4151. /* "_yaml.pyx":354
  4152. * return ScannerError(context, context_mark, problem, problem_mark)
  4153. * else:
  4154. * return ParserError(context, context_mark, problem, problem_mark) # <<<<<<<<<<<<<<
  4155. * if PY_MAJOR_VERSION < 3:
  4156. * raise ValueError("no parser error")
  4157. */
  4158. /*else*/ {
  4159. __Pyx_XDECREF(__pyx_r);
  4160. __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_ParserError); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 354, __pyx_L1_error)
  4161. __Pyx_GOTREF(__pyx_t_2);
  4162. __pyx_t_7 = NULL;
  4163. __pyx_t_8 = 0;
  4164. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) {
  4165. __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_2);
  4166. if (likely(__pyx_t_7)) {
  4167. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
  4168. __Pyx_INCREF(__pyx_t_7);
  4169. __Pyx_INCREF(function);
  4170. __Pyx_DECREF_SET(__pyx_t_2, function);
  4171. __pyx_t_8 = 1;
  4172. }
  4173. }
  4174. #if CYTHON_FAST_PYCALL
  4175. if (PyFunction_Check(__pyx_t_2)) {
  4176. PyObject *__pyx_temp[5] = {__pyx_t_7, __pyx_v_context, ((PyObject *)__pyx_v_context_mark), __pyx_v_problem, ((PyObject *)__pyx_v_problem_mark)};
  4177. __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 4+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 354, __pyx_L1_error)
  4178. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  4179. __Pyx_GOTREF(__pyx_t_3);
  4180. } else
  4181. #endif
  4182. #if CYTHON_FAST_PYCCALL
  4183. if (__Pyx_PyFastCFunction_Check(__pyx_t_2)) {
  4184. PyObject *__pyx_temp[5] = {__pyx_t_7, __pyx_v_context, ((PyObject *)__pyx_v_context_mark), __pyx_v_problem, ((PyObject *)__pyx_v_problem_mark)};
  4185. __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_2, __pyx_temp+1-__pyx_t_8, 4+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 354, __pyx_L1_error)
  4186. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  4187. __Pyx_GOTREF(__pyx_t_3);
  4188. } else
  4189. #endif
  4190. {
  4191. __pyx_t_5 = PyTuple_New(4+__pyx_t_8); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 354, __pyx_L1_error)
  4192. __Pyx_GOTREF(__pyx_t_5);
  4193. if (__pyx_t_7) {
  4194. __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_7); __pyx_t_7 = NULL;
  4195. }
  4196. __Pyx_INCREF(__pyx_v_context);
  4197. __Pyx_GIVEREF(__pyx_v_context);
  4198. PyTuple_SET_ITEM(__pyx_t_5, 0+__pyx_t_8, __pyx_v_context);
  4199. __Pyx_INCREF(((PyObject *)__pyx_v_context_mark));
  4200. __Pyx_GIVEREF(((PyObject *)__pyx_v_context_mark));
  4201. PyTuple_SET_ITEM(__pyx_t_5, 1+__pyx_t_8, ((PyObject *)__pyx_v_context_mark));
  4202. __Pyx_INCREF(__pyx_v_problem);
  4203. __Pyx_GIVEREF(__pyx_v_problem);
  4204. PyTuple_SET_ITEM(__pyx_t_5, 2+__pyx_t_8, __pyx_v_problem);
  4205. __Pyx_INCREF(((PyObject *)__pyx_v_problem_mark));
  4206. __Pyx_GIVEREF(((PyObject *)__pyx_v_problem_mark));
  4207. PyTuple_SET_ITEM(__pyx_t_5, 3+__pyx_t_8, ((PyObject *)__pyx_v_problem_mark));
  4208. __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_2, __pyx_t_5, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 354, __pyx_L1_error)
  4209. __Pyx_GOTREF(__pyx_t_3);
  4210. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  4211. }
  4212. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  4213. __pyx_r = __pyx_t_3;
  4214. __pyx_t_3 = 0;
  4215. goto __pyx_L0;
  4216. }
  4217. /* "_yaml.pyx":327
  4218. * return ReaderError(self.stream_name, self.parser.problem_offset,
  4219. * self.parser.problem_value, u'?', PyUnicode_FromString(self.parser.problem))
  4220. * elif self.parser.error == YAML_SCANNER_ERROR \ # <<<<<<<<<<<<<<
  4221. * or self.parser.error == YAML_PARSER_ERROR:
  4222. * context_mark = None
  4223. */
  4224. break;
  4225. default: break;
  4226. }
  4227. /* "_yaml.pyx":355
  4228. * else:
  4229. * return ParserError(context, context_mark, problem, problem_mark)
  4230. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  4231. * raise ValueError("no parser error")
  4232. * else:
  4233. */
  4234. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  4235. if (unlikely(__pyx_t_1)) {
  4236. /* "_yaml.pyx":356
  4237. * return ParserError(context, context_mark, problem, problem_mark)
  4238. * if PY_MAJOR_VERSION < 3:
  4239. * raise ValueError("no parser error") # <<<<<<<<<<<<<<
  4240. * else:
  4241. * raise ValueError(u"no parser error")
  4242. */
  4243. __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__4, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 356, __pyx_L1_error)
  4244. __Pyx_GOTREF(__pyx_t_3);
  4245. __Pyx_Raise(__pyx_t_3, 0, 0, 0);
  4246. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  4247. __PYX_ERR(0, 356, __pyx_L1_error)
  4248. /* "_yaml.pyx":355
  4249. * else:
  4250. * return ParserError(context, context_mark, problem, problem_mark)
  4251. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  4252. * raise ValueError("no parser error")
  4253. * else:
  4254. */
  4255. }
  4256. /* "_yaml.pyx":358
  4257. * raise ValueError("no parser error")
  4258. * else:
  4259. * raise ValueError(u"no parser error") # <<<<<<<<<<<<<<
  4260. *
  4261. * def raw_scan(self):
  4262. */
  4263. /*else*/ {
  4264. __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__5, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 358, __pyx_L1_error)
  4265. __Pyx_GOTREF(__pyx_t_3);
  4266. __Pyx_Raise(__pyx_t_3, 0, 0, 0);
  4267. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  4268. __PYX_ERR(0, 358, __pyx_L1_error)
  4269. }
  4270. /* "_yaml.pyx":317
  4271. * pass
  4272. *
  4273. * cdef object _parser_error(self): # <<<<<<<<<<<<<<
  4274. * if self.parser.error == YAML_MEMORY_ERROR:
  4275. * return MemoryError
  4276. */
  4277. /* function exit code */
  4278. __pyx_L1_error:;
  4279. __Pyx_XDECREF(__pyx_t_2);
  4280. __Pyx_XDECREF(__pyx_t_3);
  4281. __Pyx_XDECREF(__pyx_t_4);
  4282. __Pyx_XDECREF(__pyx_t_5);
  4283. __Pyx_XDECREF(__pyx_t_6);
  4284. __Pyx_XDECREF(__pyx_t_7);
  4285. __Pyx_XDECREF(__pyx_t_9);
  4286. __Pyx_AddTraceback("_yaml.CParser._parser_error", __pyx_clineno, __pyx_lineno, __pyx_filename);
  4287. __pyx_r = 0;
  4288. __pyx_L0:;
  4289. __Pyx_XDECREF((PyObject *)__pyx_v_context_mark);
  4290. __Pyx_XDECREF((PyObject *)__pyx_v_problem_mark);
  4291. __Pyx_XDECREF(__pyx_v_context);
  4292. __Pyx_XDECREF(__pyx_v_problem);
  4293. __Pyx_XGIVEREF(__pyx_r);
  4294. __Pyx_RefNannyFinishContext();
  4295. return __pyx_r;
  4296. }
  4297. /* "_yaml.pyx":360
  4298. * raise ValueError(u"no parser error")
  4299. *
  4300. * def raw_scan(self): # <<<<<<<<<<<<<<
  4301. * cdef yaml_token_t token
  4302. * cdef int done
  4303. */
  4304. /* Python wrapper */
  4305. static PyObject *__pyx_pw_5_yaml_7CParser_7raw_scan(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  4306. static PyObject *__pyx_pw_5_yaml_7CParser_7raw_scan(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  4307. PyObject *__pyx_r = 0;
  4308. __Pyx_RefNannyDeclarations
  4309. __Pyx_RefNannySetupContext("raw_scan (wrapper)", 0);
  4310. __pyx_r = __pyx_pf_5_yaml_7CParser_6raw_scan(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self));
  4311. /* function exit code */
  4312. __Pyx_RefNannyFinishContext();
  4313. return __pyx_r;
  4314. }
  4315. static PyObject *__pyx_pf_5_yaml_7CParser_6raw_scan(struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  4316. yaml_token_t __pyx_v_token;
  4317. int __pyx_v_done;
  4318. int __pyx_v_count;
  4319. PyObject *__pyx_v_error = NULL;
  4320. PyObject *__pyx_r = NULL;
  4321. __Pyx_RefNannyDeclarations
  4322. int __pyx_t_1;
  4323. int __pyx_t_2;
  4324. PyObject *__pyx_t_3 = NULL;
  4325. __Pyx_RefNannySetupContext("raw_scan", 0);
  4326. /* "_yaml.pyx":364
  4327. * cdef int done
  4328. * cdef int count
  4329. * count = 0 # <<<<<<<<<<<<<<
  4330. * done = 0
  4331. * while done == 0:
  4332. */
  4333. __pyx_v_count = 0;
  4334. /* "_yaml.pyx":365
  4335. * cdef int count
  4336. * count = 0
  4337. * done = 0 # <<<<<<<<<<<<<<
  4338. * while done == 0:
  4339. * if yaml_parser_scan(&self.parser, &token) == 0:
  4340. */
  4341. __pyx_v_done = 0;
  4342. /* "_yaml.pyx":366
  4343. * count = 0
  4344. * done = 0
  4345. * while done == 0: # <<<<<<<<<<<<<<
  4346. * if yaml_parser_scan(&self.parser, &token) == 0:
  4347. * error = self._parser_error()
  4348. */
  4349. while (1) {
  4350. __pyx_t_1 = ((__pyx_v_done == 0) != 0);
  4351. if (!__pyx_t_1) break;
  4352. /* "_yaml.pyx":367
  4353. * done = 0
  4354. * while done == 0:
  4355. * if yaml_parser_scan(&self.parser, &token) == 0: # <<<<<<<<<<<<<<
  4356. * error = self._parser_error()
  4357. * raise error
  4358. */
  4359. __pyx_t_2 = yaml_parser_scan((&__pyx_v_self->parser), (&__pyx_v_token)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 367, __pyx_L1_error)
  4360. __pyx_t_1 = ((__pyx_t_2 == 0) != 0);
  4361. if (unlikely(__pyx_t_1)) {
  4362. /* "_yaml.pyx":368
  4363. * while done == 0:
  4364. * if yaml_parser_scan(&self.parser, &token) == 0:
  4365. * error = self._parser_error() # <<<<<<<<<<<<<<
  4366. * raise error
  4367. * if token.type == YAML_NO_TOKEN:
  4368. */
  4369. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parser_error(__pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 368, __pyx_L1_error)
  4370. __Pyx_GOTREF(__pyx_t_3);
  4371. __pyx_v_error = __pyx_t_3;
  4372. __pyx_t_3 = 0;
  4373. /* "_yaml.pyx":369
  4374. * if yaml_parser_scan(&self.parser, &token) == 0:
  4375. * error = self._parser_error()
  4376. * raise error # <<<<<<<<<<<<<<
  4377. * if token.type == YAML_NO_TOKEN:
  4378. * done = 1
  4379. */
  4380. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  4381. __PYX_ERR(0, 369, __pyx_L1_error)
  4382. /* "_yaml.pyx":367
  4383. * done = 0
  4384. * while done == 0:
  4385. * if yaml_parser_scan(&self.parser, &token) == 0: # <<<<<<<<<<<<<<
  4386. * error = self._parser_error()
  4387. * raise error
  4388. */
  4389. }
  4390. /* "_yaml.pyx":370
  4391. * error = self._parser_error()
  4392. * raise error
  4393. * if token.type == YAML_NO_TOKEN: # <<<<<<<<<<<<<<
  4394. * done = 1
  4395. * else:
  4396. */
  4397. __pyx_t_1 = ((__pyx_v_token.type == YAML_NO_TOKEN) != 0);
  4398. if (__pyx_t_1) {
  4399. /* "_yaml.pyx":371
  4400. * raise error
  4401. * if token.type == YAML_NO_TOKEN:
  4402. * done = 1 # <<<<<<<<<<<<<<
  4403. * else:
  4404. * count = count+1
  4405. */
  4406. __pyx_v_done = 1;
  4407. /* "_yaml.pyx":370
  4408. * error = self._parser_error()
  4409. * raise error
  4410. * if token.type == YAML_NO_TOKEN: # <<<<<<<<<<<<<<
  4411. * done = 1
  4412. * else:
  4413. */
  4414. goto __pyx_L6;
  4415. }
  4416. /* "_yaml.pyx":373
  4417. * done = 1
  4418. * else:
  4419. * count = count+1 # <<<<<<<<<<<<<<
  4420. * yaml_token_delete(&token)
  4421. * return count
  4422. */
  4423. /*else*/ {
  4424. __pyx_v_count = (__pyx_v_count + 1);
  4425. }
  4426. __pyx_L6:;
  4427. /* "_yaml.pyx":374
  4428. * else:
  4429. * count = count+1
  4430. * yaml_token_delete(&token) # <<<<<<<<<<<<<<
  4431. * return count
  4432. *
  4433. */
  4434. yaml_token_delete((&__pyx_v_token));
  4435. }
  4436. /* "_yaml.pyx":375
  4437. * count = count+1
  4438. * yaml_token_delete(&token)
  4439. * return count # <<<<<<<<<<<<<<
  4440. *
  4441. * cdef object _scan(self):
  4442. */
  4443. __Pyx_XDECREF(__pyx_r);
  4444. __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_count); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 375, __pyx_L1_error)
  4445. __Pyx_GOTREF(__pyx_t_3);
  4446. __pyx_r = __pyx_t_3;
  4447. __pyx_t_3 = 0;
  4448. goto __pyx_L0;
  4449. /* "_yaml.pyx":360
  4450. * raise ValueError(u"no parser error")
  4451. *
  4452. * def raw_scan(self): # <<<<<<<<<<<<<<
  4453. * cdef yaml_token_t token
  4454. * cdef int done
  4455. */
  4456. /* function exit code */
  4457. __pyx_L1_error:;
  4458. __Pyx_XDECREF(__pyx_t_3);
  4459. __Pyx_AddTraceback("_yaml.CParser.raw_scan", __pyx_clineno, __pyx_lineno, __pyx_filename);
  4460. __pyx_r = NULL;
  4461. __pyx_L0:;
  4462. __Pyx_XDECREF(__pyx_v_error);
  4463. __Pyx_XGIVEREF(__pyx_r);
  4464. __Pyx_RefNannyFinishContext();
  4465. return __pyx_r;
  4466. }
  4467. /* "_yaml.pyx":377
  4468. * return count
  4469. *
  4470. * cdef object _scan(self): # <<<<<<<<<<<<<<
  4471. * cdef yaml_token_t token
  4472. * if yaml_parser_scan(&self.parser, &token) == 0:
  4473. */
  4474. static PyObject *__pyx_f_5_yaml_7CParser__scan(struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  4475. yaml_token_t __pyx_v_token;
  4476. PyObject *__pyx_v_error = NULL;
  4477. PyObject *__pyx_v_token_object = NULL;
  4478. PyObject *__pyx_r = NULL;
  4479. __Pyx_RefNannyDeclarations
  4480. int __pyx_t_1;
  4481. int __pyx_t_2;
  4482. PyObject *__pyx_t_3 = NULL;
  4483. __Pyx_RefNannySetupContext("_scan", 0);
  4484. /* "_yaml.pyx":379
  4485. * cdef object _scan(self):
  4486. * cdef yaml_token_t token
  4487. * if yaml_parser_scan(&self.parser, &token) == 0: # <<<<<<<<<<<<<<
  4488. * error = self._parser_error()
  4489. * raise error
  4490. */
  4491. __pyx_t_1 = yaml_parser_scan((&__pyx_v_self->parser), (&__pyx_v_token)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 379, __pyx_L1_error)
  4492. __pyx_t_2 = ((__pyx_t_1 == 0) != 0);
  4493. if (unlikely(__pyx_t_2)) {
  4494. /* "_yaml.pyx":380
  4495. * cdef yaml_token_t token
  4496. * if yaml_parser_scan(&self.parser, &token) == 0:
  4497. * error = self._parser_error() # <<<<<<<<<<<<<<
  4498. * raise error
  4499. * token_object = self._token_to_object(&token)
  4500. */
  4501. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parser_error(__pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 380, __pyx_L1_error)
  4502. __Pyx_GOTREF(__pyx_t_3);
  4503. __pyx_v_error = __pyx_t_3;
  4504. __pyx_t_3 = 0;
  4505. /* "_yaml.pyx":381
  4506. * if yaml_parser_scan(&self.parser, &token) == 0:
  4507. * error = self._parser_error()
  4508. * raise error # <<<<<<<<<<<<<<
  4509. * token_object = self._token_to_object(&token)
  4510. * yaml_token_delete(&token)
  4511. */
  4512. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  4513. __PYX_ERR(0, 381, __pyx_L1_error)
  4514. /* "_yaml.pyx":379
  4515. * cdef object _scan(self):
  4516. * cdef yaml_token_t token
  4517. * if yaml_parser_scan(&self.parser, &token) == 0: # <<<<<<<<<<<<<<
  4518. * error = self._parser_error()
  4519. * raise error
  4520. */
  4521. }
  4522. /* "_yaml.pyx":382
  4523. * error = self._parser_error()
  4524. * raise error
  4525. * token_object = self._token_to_object(&token) # <<<<<<<<<<<<<<
  4526. * yaml_token_delete(&token)
  4527. * return token_object
  4528. */
  4529. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_token_to_object(__pyx_v_self, (&__pyx_v_token)); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 382, __pyx_L1_error)
  4530. __Pyx_GOTREF(__pyx_t_3);
  4531. __pyx_v_token_object = __pyx_t_3;
  4532. __pyx_t_3 = 0;
  4533. /* "_yaml.pyx":383
  4534. * raise error
  4535. * token_object = self._token_to_object(&token)
  4536. * yaml_token_delete(&token) # <<<<<<<<<<<<<<
  4537. * return token_object
  4538. *
  4539. */
  4540. yaml_token_delete((&__pyx_v_token));
  4541. /* "_yaml.pyx":384
  4542. * token_object = self._token_to_object(&token)
  4543. * yaml_token_delete(&token)
  4544. * return token_object # <<<<<<<<<<<<<<
  4545. *
  4546. * cdef object _token_to_object(self, yaml_token_t *token):
  4547. */
  4548. __Pyx_XDECREF(__pyx_r);
  4549. __Pyx_INCREF(__pyx_v_token_object);
  4550. __pyx_r = __pyx_v_token_object;
  4551. goto __pyx_L0;
  4552. /* "_yaml.pyx":377
  4553. * return count
  4554. *
  4555. * cdef object _scan(self): # <<<<<<<<<<<<<<
  4556. * cdef yaml_token_t token
  4557. * if yaml_parser_scan(&self.parser, &token) == 0:
  4558. */
  4559. /* function exit code */
  4560. __pyx_L1_error:;
  4561. __Pyx_XDECREF(__pyx_t_3);
  4562. __Pyx_AddTraceback("_yaml.CParser._scan", __pyx_clineno, __pyx_lineno, __pyx_filename);
  4563. __pyx_r = 0;
  4564. __pyx_L0:;
  4565. __Pyx_XDECREF(__pyx_v_error);
  4566. __Pyx_XDECREF(__pyx_v_token_object);
  4567. __Pyx_XGIVEREF(__pyx_r);
  4568. __Pyx_RefNannyFinishContext();
  4569. return __pyx_r;
  4570. }
  4571. /* "_yaml.pyx":386
  4572. * return token_object
  4573. *
  4574. * cdef object _token_to_object(self, yaml_token_t *token): # <<<<<<<<<<<<<<
  4575. * start_mark = Mark(self.stream_name,
  4576. * token.start_mark.index,
  4577. */
  4578. static PyObject *__pyx_f_5_yaml_7CParser__token_to_object(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, yaml_token_t *__pyx_v_token) {
  4579. struct __pyx_obj_5_yaml_Mark *__pyx_v_start_mark = NULL;
  4580. struct __pyx_obj_5_yaml_Mark *__pyx_v_end_mark = NULL;
  4581. PyObject *__pyx_v_encoding = NULL;
  4582. PyObject *__pyx_v_handle = NULL;
  4583. PyObject *__pyx_v_prefix = NULL;
  4584. PyObject *__pyx_v_value = NULL;
  4585. PyObject *__pyx_v_suffix = NULL;
  4586. int __pyx_v_plain;
  4587. PyObject *__pyx_v_style = NULL;
  4588. PyObject *__pyx_r = NULL;
  4589. __Pyx_RefNannyDeclarations
  4590. PyObject *__pyx_t_1 = NULL;
  4591. PyObject *__pyx_t_2 = NULL;
  4592. PyObject *__pyx_t_3 = NULL;
  4593. PyObject *__pyx_t_4 = NULL;
  4594. int __pyx_t_5;
  4595. int __pyx_t_6;
  4596. PyObject *__pyx_t_7 = NULL;
  4597. int __pyx_t_8;
  4598. __Pyx_RefNannySetupContext("_token_to_object", 0);
  4599. /* "_yaml.pyx":388
  4600. * cdef object _token_to_object(self, yaml_token_t *token):
  4601. * start_mark = Mark(self.stream_name,
  4602. * token.start_mark.index, # <<<<<<<<<<<<<<
  4603. * token.start_mark.line,
  4604. * token.start_mark.column,
  4605. */
  4606. __pyx_t_1 = __Pyx_PyInt_FromSize_t(__pyx_v_token->start_mark.index); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 388, __pyx_L1_error)
  4607. __Pyx_GOTREF(__pyx_t_1);
  4608. /* "_yaml.pyx":389
  4609. * start_mark = Mark(self.stream_name,
  4610. * token.start_mark.index,
  4611. * token.start_mark.line, # <<<<<<<<<<<<<<
  4612. * token.start_mark.column,
  4613. * None, None)
  4614. */
  4615. __pyx_t_2 = __Pyx_PyInt_FromSize_t(__pyx_v_token->start_mark.line); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 389, __pyx_L1_error)
  4616. __Pyx_GOTREF(__pyx_t_2);
  4617. /* "_yaml.pyx":390
  4618. * token.start_mark.index,
  4619. * token.start_mark.line,
  4620. * token.start_mark.column, # <<<<<<<<<<<<<<
  4621. * None, None)
  4622. * end_mark = Mark(self.stream_name,
  4623. */
  4624. __pyx_t_3 = __Pyx_PyInt_FromSize_t(__pyx_v_token->start_mark.column); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 390, __pyx_L1_error)
  4625. __Pyx_GOTREF(__pyx_t_3);
  4626. /* "_yaml.pyx":387
  4627. *
  4628. * cdef object _token_to_object(self, yaml_token_t *token):
  4629. * start_mark = Mark(self.stream_name, # <<<<<<<<<<<<<<
  4630. * token.start_mark.index,
  4631. * token.start_mark.line,
  4632. */
  4633. __pyx_t_4 = PyTuple_New(6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 387, __pyx_L1_error)
  4634. __Pyx_GOTREF(__pyx_t_4);
  4635. __Pyx_INCREF(__pyx_v_self->stream_name);
  4636. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  4637. PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->stream_name);
  4638. __Pyx_GIVEREF(__pyx_t_1);
  4639. PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1);
  4640. __Pyx_GIVEREF(__pyx_t_2);
  4641. PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_2);
  4642. __Pyx_GIVEREF(__pyx_t_3);
  4643. PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_t_3);
  4644. __Pyx_INCREF(Py_None);
  4645. __Pyx_GIVEREF(Py_None);
  4646. PyTuple_SET_ITEM(__pyx_t_4, 4, Py_None);
  4647. __Pyx_INCREF(Py_None);
  4648. __Pyx_GIVEREF(Py_None);
  4649. PyTuple_SET_ITEM(__pyx_t_4, 5, Py_None);
  4650. __pyx_t_1 = 0;
  4651. __pyx_t_2 = 0;
  4652. __pyx_t_3 = 0;
  4653. __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 387, __pyx_L1_error)
  4654. __Pyx_GOTREF(__pyx_t_3);
  4655. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  4656. __pyx_v_start_mark = ((struct __pyx_obj_5_yaml_Mark *)__pyx_t_3);
  4657. __pyx_t_3 = 0;
  4658. /* "_yaml.pyx":393
  4659. * None, None)
  4660. * end_mark = Mark(self.stream_name,
  4661. * token.end_mark.index, # <<<<<<<<<<<<<<
  4662. * token.end_mark.line,
  4663. * token.end_mark.column,
  4664. */
  4665. __pyx_t_3 = __Pyx_PyInt_FromSize_t(__pyx_v_token->end_mark.index); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 393, __pyx_L1_error)
  4666. __Pyx_GOTREF(__pyx_t_3);
  4667. /* "_yaml.pyx":394
  4668. * end_mark = Mark(self.stream_name,
  4669. * token.end_mark.index,
  4670. * token.end_mark.line, # <<<<<<<<<<<<<<
  4671. * token.end_mark.column,
  4672. * None, None)
  4673. */
  4674. __pyx_t_4 = __Pyx_PyInt_FromSize_t(__pyx_v_token->end_mark.line); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 394, __pyx_L1_error)
  4675. __Pyx_GOTREF(__pyx_t_4);
  4676. /* "_yaml.pyx":395
  4677. * token.end_mark.index,
  4678. * token.end_mark.line,
  4679. * token.end_mark.column, # <<<<<<<<<<<<<<
  4680. * None, None)
  4681. * if token.type == YAML_NO_TOKEN:
  4682. */
  4683. __pyx_t_2 = __Pyx_PyInt_FromSize_t(__pyx_v_token->end_mark.column); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 395, __pyx_L1_error)
  4684. __Pyx_GOTREF(__pyx_t_2);
  4685. /* "_yaml.pyx":392
  4686. * token.start_mark.column,
  4687. * None, None)
  4688. * end_mark = Mark(self.stream_name, # <<<<<<<<<<<<<<
  4689. * token.end_mark.index,
  4690. * token.end_mark.line,
  4691. */
  4692. __pyx_t_1 = PyTuple_New(6); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 392, __pyx_L1_error)
  4693. __Pyx_GOTREF(__pyx_t_1);
  4694. __Pyx_INCREF(__pyx_v_self->stream_name);
  4695. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  4696. PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_self->stream_name);
  4697. __Pyx_GIVEREF(__pyx_t_3);
  4698. PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3);
  4699. __Pyx_GIVEREF(__pyx_t_4);
  4700. PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_t_4);
  4701. __Pyx_GIVEREF(__pyx_t_2);
  4702. PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_t_2);
  4703. __Pyx_INCREF(Py_None);
  4704. __Pyx_GIVEREF(Py_None);
  4705. PyTuple_SET_ITEM(__pyx_t_1, 4, Py_None);
  4706. __Pyx_INCREF(Py_None);
  4707. __Pyx_GIVEREF(Py_None);
  4708. PyTuple_SET_ITEM(__pyx_t_1, 5, Py_None);
  4709. __pyx_t_3 = 0;
  4710. __pyx_t_4 = 0;
  4711. __pyx_t_2 = 0;
  4712. __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 392, __pyx_L1_error)
  4713. __Pyx_GOTREF(__pyx_t_2);
  4714. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  4715. __pyx_v_end_mark = ((struct __pyx_obj_5_yaml_Mark *)__pyx_t_2);
  4716. __pyx_t_2 = 0;
  4717. /* "_yaml.pyx":397
  4718. * token.end_mark.column,
  4719. * None, None)
  4720. * if token.type == YAML_NO_TOKEN: # <<<<<<<<<<<<<<
  4721. * return None
  4722. * elif token.type == YAML_STREAM_START_TOKEN:
  4723. */
  4724. switch (__pyx_v_token->type) {
  4725. case YAML_NO_TOKEN:
  4726. /* "_yaml.pyx":398
  4727. * None, None)
  4728. * if token.type == YAML_NO_TOKEN:
  4729. * return None # <<<<<<<<<<<<<<
  4730. * elif token.type == YAML_STREAM_START_TOKEN:
  4731. * encoding = None
  4732. */
  4733. __Pyx_XDECREF(__pyx_r);
  4734. __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  4735. goto __pyx_L0;
  4736. /* "_yaml.pyx":397
  4737. * token.end_mark.column,
  4738. * None, None)
  4739. * if token.type == YAML_NO_TOKEN: # <<<<<<<<<<<<<<
  4740. * return None
  4741. * elif token.type == YAML_STREAM_START_TOKEN:
  4742. */
  4743. break;
  4744. case YAML_STREAM_START_TOKEN:
  4745. /* "_yaml.pyx":400
  4746. * return None
  4747. * elif token.type == YAML_STREAM_START_TOKEN:
  4748. * encoding = None # <<<<<<<<<<<<<<
  4749. * if token.data.stream_start.encoding == YAML_UTF8_ENCODING:
  4750. * if self.unicode_source == 0:
  4751. */
  4752. __Pyx_INCREF(Py_None);
  4753. __pyx_v_encoding = ((PyObject*)Py_None);
  4754. /* "_yaml.pyx":401
  4755. * elif token.type == YAML_STREAM_START_TOKEN:
  4756. * encoding = None
  4757. * if token.data.stream_start.encoding == YAML_UTF8_ENCODING: # <<<<<<<<<<<<<<
  4758. * if self.unicode_source == 0:
  4759. * encoding = u"utf-8"
  4760. */
  4761. switch (__pyx_v_token->data.stream_start.encoding) {
  4762. case YAML_UTF8_ENCODING:
  4763. /* "_yaml.pyx":402
  4764. * encoding = None
  4765. * if token.data.stream_start.encoding == YAML_UTF8_ENCODING:
  4766. * if self.unicode_source == 0: # <<<<<<<<<<<<<<
  4767. * encoding = u"utf-8"
  4768. * elif token.data.stream_start.encoding == YAML_UTF16LE_ENCODING:
  4769. */
  4770. __pyx_t_5 = ((__pyx_v_self->unicode_source == 0) != 0);
  4771. if (__pyx_t_5) {
  4772. /* "_yaml.pyx":403
  4773. * if token.data.stream_start.encoding == YAML_UTF8_ENCODING:
  4774. * if self.unicode_source == 0:
  4775. * encoding = u"utf-8" # <<<<<<<<<<<<<<
  4776. * elif token.data.stream_start.encoding == YAML_UTF16LE_ENCODING:
  4777. * encoding = u"utf-16-le"
  4778. */
  4779. __Pyx_INCREF(__pyx_kp_u_utf_8);
  4780. __Pyx_DECREF_SET(__pyx_v_encoding, __pyx_kp_u_utf_8);
  4781. /* "_yaml.pyx":402
  4782. * encoding = None
  4783. * if token.data.stream_start.encoding == YAML_UTF8_ENCODING:
  4784. * if self.unicode_source == 0: # <<<<<<<<<<<<<<
  4785. * encoding = u"utf-8"
  4786. * elif token.data.stream_start.encoding == YAML_UTF16LE_ENCODING:
  4787. */
  4788. }
  4789. /* "_yaml.pyx":401
  4790. * elif token.type == YAML_STREAM_START_TOKEN:
  4791. * encoding = None
  4792. * if token.data.stream_start.encoding == YAML_UTF8_ENCODING: # <<<<<<<<<<<<<<
  4793. * if self.unicode_source == 0:
  4794. * encoding = u"utf-8"
  4795. */
  4796. break;
  4797. case YAML_UTF16LE_ENCODING:
  4798. /* "_yaml.pyx":405
  4799. * encoding = u"utf-8"
  4800. * elif token.data.stream_start.encoding == YAML_UTF16LE_ENCODING:
  4801. * encoding = u"utf-16-le" # <<<<<<<<<<<<<<
  4802. * elif token.data.stream_start.encoding == YAML_UTF16BE_ENCODING:
  4803. * encoding = u"utf-16-be"
  4804. */
  4805. __Pyx_INCREF(__pyx_kp_u_utf_16_le);
  4806. __Pyx_DECREF_SET(__pyx_v_encoding, __pyx_kp_u_utf_16_le);
  4807. /* "_yaml.pyx":404
  4808. * if self.unicode_source == 0:
  4809. * encoding = u"utf-8"
  4810. * elif token.data.stream_start.encoding == YAML_UTF16LE_ENCODING: # <<<<<<<<<<<<<<
  4811. * encoding = u"utf-16-le"
  4812. * elif token.data.stream_start.encoding == YAML_UTF16BE_ENCODING:
  4813. */
  4814. break;
  4815. case YAML_UTF16BE_ENCODING:
  4816. /* "_yaml.pyx":407
  4817. * encoding = u"utf-16-le"
  4818. * elif token.data.stream_start.encoding == YAML_UTF16BE_ENCODING:
  4819. * encoding = u"utf-16-be" # <<<<<<<<<<<<<<
  4820. * return StreamStartToken(start_mark, end_mark, encoding)
  4821. * elif token.type == YAML_STREAM_END_TOKEN:
  4822. */
  4823. __Pyx_INCREF(__pyx_kp_u_utf_16_be);
  4824. __Pyx_DECREF_SET(__pyx_v_encoding, __pyx_kp_u_utf_16_be);
  4825. /* "_yaml.pyx":406
  4826. * elif token.data.stream_start.encoding == YAML_UTF16LE_ENCODING:
  4827. * encoding = u"utf-16-le"
  4828. * elif token.data.stream_start.encoding == YAML_UTF16BE_ENCODING: # <<<<<<<<<<<<<<
  4829. * encoding = u"utf-16-be"
  4830. * return StreamStartToken(start_mark, end_mark, encoding)
  4831. */
  4832. break;
  4833. default: break;
  4834. }
  4835. /* "_yaml.pyx":408
  4836. * elif token.data.stream_start.encoding == YAML_UTF16BE_ENCODING:
  4837. * encoding = u"utf-16-be"
  4838. * return StreamStartToken(start_mark, end_mark, encoding) # <<<<<<<<<<<<<<
  4839. * elif token.type == YAML_STREAM_END_TOKEN:
  4840. * return StreamEndToken(start_mark, end_mark)
  4841. */
  4842. __Pyx_XDECREF(__pyx_r);
  4843. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_StreamStartToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 408, __pyx_L1_error)
  4844. __Pyx_GOTREF(__pyx_t_1);
  4845. __pyx_t_4 = NULL;
  4846. __pyx_t_6 = 0;
  4847. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  4848. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_1);
  4849. if (likely(__pyx_t_4)) {
  4850. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  4851. __Pyx_INCREF(__pyx_t_4);
  4852. __Pyx_INCREF(function);
  4853. __Pyx_DECREF_SET(__pyx_t_1, function);
  4854. __pyx_t_6 = 1;
  4855. }
  4856. }
  4857. #if CYTHON_FAST_PYCALL
  4858. if (PyFunction_Check(__pyx_t_1)) {
  4859. PyObject *__pyx_temp[4] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_v_encoding};
  4860. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 408, __pyx_L1_error)
  4861. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  4862. __Pyx_GOTREF(__pyx_t_2);
  4863. } else
  4864. #endif
  4865. #if CYTHON_FAST_PYCCALL
  4866. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  4867. PyObject *__pyx_temp[4] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_v_encoding};
  4868. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 408, __pyx_L1_error)
  4869. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  4870. __Pyx_GOTREF(__pyx_t_2);
  4871. } else
  4872. #endif
  4873. {
  4874. __pyx_t_3 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 408, __pyx_L1_error)
  4875. __Pyx_GOTREF(__pyx_t_3);
  4876. if (__pyx_t_4) {
  4877. __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); __pyx_t_4 = NULL;
  4878. }
  4879. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  4880. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  4881. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  4882. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  4883. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  4884. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  4885. __Pyx_INCREF(__pyx_v_encoding);
  4886. __Pyx_GIVEREF(__pyx_v_encoding);
  4887. PyTuple_SET_ITEM(__pyx_t_3, 2+__pyx_t_6, __pyx_v_encoding);
  4888. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 408, __pyx_L1_error)
  4889. __Pyx_GOTREF(__pyx_t_2);
  4890. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  4891. }
  4892. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  4893. __pyx_r = __pyx_t_2;
  4894. __pyx_t_2 = 0;
  4895. goto __pyx_L0;
  4896. /* "_yaml.pyx":399
  4897. * if token.type == YAML_NO_TOKEN:
  4898. * return None
  4899. * elif token.type == YAML_STREAM_START_TOKEN: # <<<<<<<<<<<<<<
  4900. * encoding = None
  4901. * if token.data.stream_start.encoding == YAML_UTF8_ENCODING:
  4902. */
  4903. break;
  4904. case YAML_STREAM_END_TOKEN:
  4905. /* "_yaml.pyx":410
  4906. * return StreamStartToken(start_mark, end_mark, encoding)
  4907. * elif token.type == YAML_STREAM_END_TOKEN:
  4908. * return StreamEndToken(start_mark, end_mark) # <<<<<<<<<<<<<<
  4909. * elif token.type == YAML_VERSION_DIRECTIVE_TOKEN:
  4910. * return DirectiveToken(u"YAML",
  4911. */
  4912. __Pyx_XDECREF(__pyx_r);
  4913. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_StreamEndToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 410, __pyx_L1_error)
  4914. __Pyx_GOTREF(__pyx_t_1);
  4915. __pyx_t_3 = NULL;
  4916. __pyx_t_6 = 0;
  4917. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  4918. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  4919. if (likely(__pyx_t_3)) {
  4920. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  4921. __Pyx_INCREF(__pyx_t_3);
  4922. __Pyx_INCREF(function);
  4923. __Pyx_DECREF_SET(__pyx_t_1, function);
  4924. __pyx_t_6 = 1;
  4925. }
  4926. }
  4927. #if CYTHON_FAST_PYCALL
  4928. if (PyFunction_Check(__pyx_t_1)) {
  4929. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  4930. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 410, __pyx_L1_error)
  4931. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  4932. __Pyx_GOTREF(__pyx_t_2);
  4933. } else
  4934. #endif
  4935. #if CYTHON_FAST_PYCCALL
  4936. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  4937. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  4938. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 410, __pyx_L1_error)
  4939. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  4940. __Pyx_GOTREF(__pyx_t_2);
  4941. } else
  4942. #endif
  4943. {
  4944. __pyx_t_4 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 410, __pyx_L1_error)
  4945. __Pyx_GOTREF(__pyx_t_4);
  4946. if (__pyx_t_3) {
  4947. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL;
  4948. }
  4949. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  4950. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  4951. PyTuple_SET_ITEM(__pyx_t_4, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  4952. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  4953. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  4954. PyTuple_SET_ITEM(__pyx_t_4, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  4955. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 410, __pyx_L1_error)
  4956. __Pyx_GOTREF(__pyx_t_2);
  4957. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  4958. }
  4959. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  4960. __pyx_r = __pyx_t_2;
  4961. __pyx_t_2 = 0;
  4962. goto __pyx_L0;
  4963. /* "_yaml.pyx":409
  4964. * encoding = u"utf-16-be"
  4965. * return StreamStartToken(start_mark, end_mark, encoding)
  4966. * elif token.type == YAML_STREAM_END_TOKEN: # <<<<<<<<<<<<<<
  4967. * return StreamEndToken(start_mark, end_mark)
  4968. * elif token.type == YAML_VERSION_DIRECTIVE_TOKEN:
  4969. */
  4970. break;
  4971. case YAML_VERSION_DIRECTIVE_TOKEN:
  4972. /* "_yaml.pyx":412
  4973. * return StreamEndToken(start_mark, end_mark)
  4974. * elif token.type == YAML_VERSION_DIRECTIVE_TOKEN:
  4975. * return DirectiveToken(u"YAML", # <<<<<<<<<<<<<<
  4976. * (token.data.version_directive.major,
  4977. * token.data.version_directive.minor),
  4978. */
  4979. __Pyx_XDECREF(__pyx_r);
  4980. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_DirectiveToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 412, __pyx_L1_error)
  4981. __Pyx_GOTREF(__pyx_t_1);
  4982. /* "_yaml.pyx":413
  4983. * elif token.type == YAML_VERSION_DIRECTIVE_TOKEN:
  4984. * return DirectiveToken(u"YAML",
  4985. * (token.data.version_directive.major, # <<<<<<<<<<<<<<
  4986. * token.data.version_directive.minor),
  4987. * start_mark, end_mark)
  4988. */
  4989. __pyx_t_4 = __Pyx_PyInt_From_int(__pyx_v_token->data.version_directive.major); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 413, __pyx_L1_error)
  4990. __Pyx_GOTREF(__pyx_t_4);
  4991. /* "_yaml.pyx":414
  4992. * return DirectiveToken(u"YAML",
  4993. * (token.data.version_directive.major,
  4994. * token.data.version_directive.minor), # <<<<<<<<<<<<<<
  4995. * start_mark, end_mark)
  4996. * elif token.type == YAML_TAG_DIRECTIVE_TOKEN:
  4997. */
  4998. __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_token->data.version_directive.minor); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 414, __pyx_L1_error)
  4999. __Pyx_GOTREF(__pyx_t_3);
  5000. /* "_yaml.pyx":413
  5001. * elif token.type == YAML_VERSION_DIRECTIVE_TOKEN:
  5002. * return DirectiveToken(u"YAML",
  5003. * (token.data.version_directive.major, # <<<<<<<<<<<<<<
  5004. * token.data.version_directive.minor),
  5005. * start_mark, end_mark)
  5006. */
  5007. __pyx_t_7 = PyTuple_New(2); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 413, __pyx_L1_error)
  5008. __Pyx_GOTREF(__pyx_t_7);
  5009. __Pyx_GIVEREF(__pyx_t_4);
  5010. PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_4);
  5011. __Pyx_GIVEREF(__pyx_t_3);
  5012. PyTuple_SET_ITEM(__pyx_t_7, 1, __pyx_t_3);
  5013. __pyx_t_4 = 0;
  5014. __pyx_t_3 = 0;
  5015. /* "_yaml.pyx":415
  5016. * (token.data.version_directive.major,
  5017. * token.data.version_directive.minor),
  5018. * start_mark, end_mark) # <<<<<<<<<<<<<<
  5019. * elif token.type == YAML_TAG_DIRECTIVE_TOKEN:
  5020. * handle = PyUnicode_FromString(token.data.tag_directive.handle)
  5021. */
  5022. __pyx_t_3 = NULL;
  5023. __pyx_t_6 = 0;
  5024. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  5025. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  5026. if (likely(__pyx_t_3)) {
  5027. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  5028. __Pyx_INCREF(__pyx_t_3);
  5029. __Pyx_INCREF(function);
  5030. __Pyx_DECREF_SET(__pyx_t_1, function);
  5031. __pyx_t_6 = 1;
  5032. }
  5033. }
  5034. #if CYTHON_FAST_PYCALL
  5035. if (PyFunction_Check(__pyx_t_1)) {
  5036. PyObject *__pyx_temp[5] = {__pyx_t_3, __pyx_n_u_YAML, __pyx_t_7, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5037. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 4+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 412, __pyx_L1_error)
  5038. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  5039. __Pyx_GOTREF(__pyx_t_2);
  5040. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  5041. } else
  5042. #endif
  5043. #if CYTHON_FAST_PYCCALL
  5044. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  5045. PyObject *__pyx_temp[5] = {__pyx_t_3, __pyx_n_u_YAML, __pyx_t_7, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5046. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 4+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 412, __pyx_L1_error)
  5047. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  5048. __Pyx_GOTREF(__pyx_t_2);
  5049. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  5050. } else
  5051. #endif
  5052. {
  5053. __pyx_t_4 = PyTuple_New(4+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 412, __pyx_L1_error)
  5054. __Pyx_GOTREF(__pyx_t_4);
  5055. if (__pyx_t_3) {
  5056. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL;
  5057. }
  5058. __Pyx_INCREF(__pyx_n_u_YAML);
  5059. __Pyx_GIVEREF(__pyx_n_u_YAML);
  5060. PyTuple_SET_ITEM(__pyx_t_4, 0+__pyx_t_6, __pyx_n_u_YAML);
  5061. __Pyx_GIVEREF(__pyx_t_7);
  5062. PyTuple_SET_ITEM(__pyx_t_4, 1+__pyx_t_6, __pyx_t_7);
  5063. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  5064. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  5065. PyTuple_SET_ITEM(__pyx_t_4, 2+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  5066. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  5067. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  5068. PyTuple_SET_ITEM(__pyx_t_4, 3+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  5069. __pyx_t_7 = 0;
  5070. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 412, __pyx_L1_error)
  5071. __Pyx_GOTREF(__pyx_t_2);
  5072. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  5073. }
  5074. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  5075. __pyx_r = __pyx_t_2;
  5076. __pyx_t_2 = 0;
  5077. goto __pyx_L0;
  5078. /* "_yaml.pyx":411
  5079. * elif token.type == YAML_STREAM_END_TOKEN:
  5080. * return StreamEndToken(start_mark, end_mark)
  5081. * elif token.type == YAML_VERSION_DIRECTIVE_TOKEN: # <<<<<<<<<<<<<<
  5082. * return DirectiveToken(u"YAML",
  5083. * (token.data.version_directive.major,
  5084. */
  5085. break;
  5086. case YAML_TAG_DIRECTIVE_TOKEN:
  5087. /* "_yaml.pyx":417
  5088. * start_mark, end_mark)
  5089. * elif token.type == YAML_TAG_DIRECTIVE_TOKEN:
  5090. * handle = PyUnicode_FromString(token.data.tag_directive.handle) # <<<<<<<<<<<<<<
  5091. * prefix = PyUnicode_FromString(token.data.tag_directive.prefix)
  5092. * return DirectiveToken(u"TAG", (handle, prefix),
  5093. */
  5094. __pyx_t_2 = PyUnicode_FromString(__pyx_v_token->data.tag_directive.handle); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 417, __pyx_L1_error)
  5095. __Pyx_GOTREF(__pyx_t_2);
  5096. __pyx_v_handle = __pyx_t_2;
  5097. __pyx_t_2 = 0;
  5098. /* "_yaml.pyx":418
  5099. * elif token.type == YAML_TAG_DIRECTIVE_TOKEN:
  5100. * handle = PyUnicode_FromString(token.data.tag_directive.handle)
  5101. * prefix = PyUnicode_FromString(token.data.tag_directive.prefix) # <<<<<<<<<<<<<<
  5102. * return DirectiveToken(u"TAG", (handle, prefix),
  5103. * start_mark, end_mark)
  5104. */
  5105. __pyx_t_2 = PyUnicode_FromString(__pyx_v_token->data.tag_directive.prefix); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 418, __pyx_L1_error)
  5106. __Pyx_GOTREF(__pyx_t_2);
  5107. __pyx_v_prefix = __pyx_t_2;
  5108. __pyx_t_2 = 0;
  5109. /* "_yaml.pyx":419
  5110. * handle = PyUnicode_FromString(token.data.tag_directive.handle)
  5111. * prefix = PyUnicode_FromString(token.data.tag_directive.prefix)
  5112. * return DirectiveToken(u"TAG", (handle, prefix), # <<<<<<<<<<<<<<
  5113. * start_mark, end_mark)
  5114. * elif token.type == YAML_DOCUMENT_START_TOKEN:
  5115. */
  5116. __Pyx_XDECREF(__pyx_r);
  5117. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_DirectiveToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 419, __pyx_L1_error)
  5118. __Pyx_GOTREF(__pyx_t_1);
  5119. __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 419, __pyx_L1_error)
  5120. __Pyx_GOTREF(__pyx_t_4);
  5121. __Pyx_INCREF(__pyx_v_handle);
  5122. __Pyx_GIVEREF(__pyx_v_handle);
  5123. PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_handle);
  5124. __Pyx_INCREF(__pyx_v_prefix);
  5125. __Pyx_GIVEREF(__pyx_v_prefix);
  5126. PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_prefix);
  5127. /* "_yaml.pyx":420
  5128. * prefix = PyUnicode_FromString(token.data.tag_directive.prefix)
  5129. * return DirectiveToken(u"TAG", (handle, prefix),
  5130. * start_mark, end_mark) # <<<<<<<<<<<<<<
  5131. * elif token.type == YAML_DOCUMENT_START_TOKEN:
  5132. * return DocumentStartToken(start_mark, end_mark)
  5133. */
  5134. __pyx_t_7 = NULL;
  5135. __pyx_t_6 = 0;
  5136. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  5137. __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_1);
  5138. if (likely(__pyx_t_7)) {
  5139. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  5140. __Pyx_INCREF(__pyx_t_7);
  5141. __Pyx_INCREF(function);
  5142. __Pyx_DECREF_SET(__pyx_t_1, function);
  5143. __pyx_t_6 = 1;
  5144. }
  5145. }
  5146. #if CYTHON_FAST_PYCALL
  5147. if (PyFunction_Check(__pyx_t_1)) {
  5148. PyObject *__pyx_temp[5] = {__pyx_t_7, __pyx_n_u_TAG, __pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5149. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 4+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 419, __pyx_L1_error)
  5150. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  5151. __Pyx_GOTREF(__pyx_t_2);
  5152. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  5153. } else
  5154. #endif
  5155. #if CYTHON_FAST_PYCCALL
  5156. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  5157. PyObject *__pyx_temp[5] = {__pyx_t_7, __pyx_n_u_TAG, __pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5158. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 4+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 419, __pyx_L1_error)
  5159. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  5160. __Pyx_GOTREF(__pyx_t_2);
  5161. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  5162. } else
  5163. #endif
  5164. {
  5165. __pyx_t_3 = PyTuple_New(4+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 419, __pyx_L1_error)
  5166. __Pyx_GOTREF(__pyx_t_3);
  5167. if (__pyx_t_7) {
  5168. __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_7); __pyx_t_7 = NULL;
  5169. }
  5170. __Pyx_INCREF(__pyx_n_u_TAG);
  5171. __Pyx_GIVEREF(__pyx_n_u_TAG);
  5172. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_6, __pyx_n_u_TAG);
  5173. __Pyx_GIVEREF(__pyx_t_4);
  5174. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_6, __pyx_t_4);
  5175. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  5176. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  5177. PyTuple_SET_ITEM(__pyx_t_3, 2+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  5178. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  5179. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  5180. PyTuple_SET_ITEM(__pyx_t_3, 3+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  5181. __pyx_t_4 = 0;
  5182. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 419, __pyx_L1_error)
  5183. __Pyx_GOTREF(__pyx_t_2);
  5184. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  5185. }
  5186. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  5187. __pyx_r = __pyx_t_2;
  5188. __pyx_t_2 = 0;
  5189. goto __pyx_L0;
  5190. /* "_yaml.pyx":416
  5191. * token.data.version_directive.minor),
  5192. * start_mark, end_mark)
  5193. * elif token.type == YAML_TAG_DIRECTIVE_TOKEN: # <<<<<<<<<<<<<<
  5194. * handle = PyUnicode_FromString(token.data.tag_directive.handle)
  5195. * prefix = PyUnicode_FromString(token.data.tag_directive.prefix)
  5196. */
  5197. break;
  5198. case YAML_DOCUMENT_START_TOKEN:
  5199. /* "_yaml.pyx":422
  5200. * start_mark, end_mark)
  5201. * elif token.type == YAML_DOCUMENT_START_TOKEN:
  5202. * return DocumentStartToken(start_mark, end_mark) # <<<<<<<<<<<<<<
  5203. * elif token.type == YAML_DOCUMENT_END_TOKEN:
  5204. * return DocumentEndToken(start_mark, end_mark)
  5205. */
  5206. __Pyx_XDECREF(__pyx_r);
  5207. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_DocumentStartToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 422, __pyx_L1_error)
  5208. __Pyx_GOTREF(__pyx_t_1);
  5209. __pyx_t_3 = NULL;
  5210. __pyx_t_6 = 0;
  5211. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  5212. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  5213. if (likely(__pyx_t_3)) {
  5214. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  5215. __Pyx_INCREF(__pyx_t_3);
  5216. __Pyx_INCREF(function);
  5217. __Pyx_DECREF_SET(__pyx_t_1, function);
  5218. __pyx_t_6 = 1;
  5219. }
  5220. }
  5221. #if CYTHON_FAST_PYCALL
  5222. if (PyFunction_Check(__pyx_t_1)) {
  5223. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5224. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 422, __pyx_L1_error)
  5225. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  5226. __Pyx_GOTREF(__pyx_t_2);
  5227. } else
  5228. #endif
  5229. #if CYTHON_FAST_PYCCALL
  5230. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  5231. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5232. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 422, __pyx_L1_error)
  5233. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  5234. __Pyx_GOTREF(__pyx_t_2);
  5235. } else
  5236. #endif
  5237. {
  5238. __pyx_t_4 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 422, __pyx_L1_error)
  5239. __Pyx_GOTREF(__pyx_t_4);
  5240. if (__pyx_t_3) {
  5241. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL;
  5242. }
  5243. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  5244. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  5245. PyTuple_SET_ITEM(__pyx_t_4, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  5246. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  5247. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  5248. PyTuple_SET_ITEM(__pyx_t_4, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  5249. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 422, __pyx_L1_error)
  5250. __Pyx_GOTREF(__pyx_t_2);
  5251. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  5252. }
  5253. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  5254. __pyx_r = __pyx_t_2;
  5255. __pyx_t_2 = 0;
  5256. goto __pyx_L0;
  5257. /* "_yaml.pyx":421
  5258. * return DirectiveToken(u"TAG", (handle, prefix),
  5259. * start_mark, end_mark)
  5260. * elif token.type == YAML_DOCUMENT_START_TOKEN: # <<<<<<<<<<<<<<
  5261. * return DocumentStartToken(start_mark, end_mark)
  5262. * elif token.type == YAML_DOCUMENT_END_TOKEN:
  5263. */
  5264. break;
  5265. case YAML_DOCUMENT_END_TOKEN:
  5266. /* "_yaml.pyx":424
  5267. * return DocumentStartToken(start_mark, end_mark)
  5268. * elif token.type == YAML_DOCUMENT_END_TOKEN:
  5269. * return DocumentEndToken(start_mark, end_mark) # <<<<<<<<<<<<<<
  5270. * elif token.type == YAML_BLOCK_SEQUENCE_START_TOKEN:
  5271. * return BlockSequenceStartToken(start_mark, end_mark)
  5272. */
  5273. __Pyx_XDECREF(__pyx_r);
  5274. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_DocumentEndToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 424, __pyx_L1_error)
  5275. __Pyx_GOTREF(__pyx_t_1);
  5276. __pyx_t_4 = NULL;
  5277. __pyx_t_6 = 0;
  5278. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  5279. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_1);
  5280. if (likely(__pyx_t_4)) {
  5281. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  5282. __Pyx_INCREF(__pyx_t_4);
  5283. __Pyx_INCREF(function);
  5284. __Pyx_DECREF_SET(__pyx_t_1, function);
  5285. __pyx_t_6 = 1;
  5286. }
  5287. }
  5288. #if CYTHON_FAST_PYCALL
  5289. if (PyFunction_Check(__pyx_t_1)) {
  5290. PyObject *__pyx_temp[3] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5291. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 424, __pyx_L1_error)
  5292. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  5293. __Pyx_GOTREF(__pyx_t_2);
  5294. } else
  5295. #endif
  5296. #if CYTHON_FAST_PYCCALL
  5297. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  5298. PyObject *__pyx_temp[3] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5299. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 424, __pyx_L1_error)
  5300. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  5301. __Pyx_GOTREF(__pyx_t_2);
  5302. } else
  5303. #endif
  5304. {
  5305. __pyx_t_3 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 424, __pyx_L1_error)
  5306. __Pyx_GOTREF(__pyx_t_3);
  5307. if (__pyx_t_4) {
  5308. __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); __pyx_t_4 = NULL;
  5309. }
  5310. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  5311. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  5312. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  5313. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  5314. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  5315. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  5316. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 424, __pyx_L1_error)
  5317. __Pyx_GOTREF(__pyx_t_2);
  5318. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  5319. }
  5320. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  5321. __pyx_r = __pyx_t_2;
  5322. __pyx_t_2 = 0;
  5323. goto __pyx_L0;
  5324. /* "_yaml.pyx":423
  5325. * elif token.type == YAML_DOCUMENT_START_TOKEN:
  5326. * return DocumentStartToken(start_mark, end_mark)
  5327. * elif token.type == YAML_DOCUMENT_END_TOKEN: # <<<<<<<<<<<<<<
  5328. * return DocumentEndToken(start_mark, end_mark)
  5329. * elif token.type == YAML_BLOCK_SEQUENCE_START_TOKEN:
  5330. */
  5331. break;
  5332. case YAML_BLOCK_SEQUENCE_START_TOKEN:
  5333. /* "_yaml.pyx":426
  5334. * return DocumentEndToken(start_mark, end_mark)
  5335. * elif token.type == YAML_BLOCK_SEQUENCE_START_TOKEN:
  5336. * return BlockSequenceStartToken(start_mark, end_mark) # <<<<<<<<<<<<<<
  5337. * elif token.type == YAML_BLOCK_MAPPING_START_TOKEN:
  5338. * return BlockMappingStartToken(start_mark, end_mark)
  5339. */
  5340. __Pyx_XDECREF(__pyx_r);
  5341. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_BlockSequenceStartToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 426, __pyx_L1_error)
  5342. __Pyx_GOTREF(__pyx_t_1);
  5343. __pyx_t_3 = NULL;
  5344. __pyx_t_6 = 0;
  5345. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  5346. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  5347. if (likely(__pyx_t_3)) {
  5348. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  5349. __Pyx_INCREF(__pyx_t_3);
  5350. __Pyx_INCREF(function);
  5351. __Pyx_DECREF_SET(__pyx_t_1, function);
  5352. __pyx_t_6 = 1;
  5353. }
  5354. }
  5355. #if CYTHON_FAST_PYCALL
  5356. if (PyFunction_Check(__pyx_t_1)) {
  5357. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5358. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 426, __pyx_L1_error)
  5359. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  5360. __Pyx_GOTREF(__pyx_t_2);
  5361. } else
  5362. #endif
  5363. #if CYTHON_FAST_PYCCALL
  5364. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  5365. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5366. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 426, __pyx_L1_error)
  5367. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  5368. __Pyx_GOTREF(__pyx_t_2);
  5369. } else
  5370. #endif
  5371. {
  5372. __pyx_t_4 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 426, __pyx_L1_error)
  5373. __Pyx_GOTREF(__pyx_t_4);
  5374. if (__pyx_t_3) {
  5375. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL;
  5376. }
  5377. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  5378. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  5379. PyTuple_SET_ITEM(__pyx_t_4, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  5380. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  5381. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  5382. PyTuple_SET_ITEM(__pyx_t_4, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  5383. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 426, __pyx_L1_error)
  5384. __Pyx_GOTREF(__pyx_t_2);
  5385. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  5386. }
  5387. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  5388. __pyx_r = __pyx_t_2;
  5389. __pyx_t_2 = 0;
  5390. goto __pyx_L0;
  5391. /* "_yaml.pyx":425
  5392. * elif token.type == YAML_DOCUMENT_END_TOKEN:
  5393. * return DocumentEndToken(start_mark, end_mark)
  5394. * elif token.type == YAML_BLOCK_SEQUENCE_START_TOKEN: # <<<<<<<<<<<<<<
  5395. * return BlockSequenceStartToken(start_mark, end_mark)
  5396. * elif token.type == YAML_BLOCK_MAPPING_START_TOKEN:
  5397. */
  5398. break;
  5399. case YAML_BLOCK_MAPPING_START_TOKEN:
  5400. /* "_yaml.pyx":428
  5401. * return BlockSequenceStartToken(start_mark, end_mark)
  5402. * elif token.type == YAML_BLOCK_MAPPING_START_TOKEN:
  5403. * return BlockMappingStartToken(start_mark, end_mark) # <<<<<<<<<<<<<<
  5404. * elif token.type == YAML_BLOCK_END_TOKEN:
  5405. * return BlockEndToken(start_mark, end_mark)
  5406. */
  5407. __Pyx_XDECREF(__pyx_r);
  5408. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_BlockMappingStartToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 428, __pyx_L1_error)
  5409. __Pyx_GOTREF(__pyx_t_1);
  5410. __pyx_t_4 = NULL;
  5411. __pyx_t_6 = 0;
  5412. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  5413. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_1);
  5414. if (likely(__pyx_t_4)) {
  5415. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  5416. __Pyx_INCREF(__pyx_t_4);
  5417. __Pyx_INCREF(function);
  5418. __Pyx_DECREF_SET(__pyx_t_1, function);
  5419. __pyx_t_6 = 1;
  5420. }
  5421. }
  5422. #if CYTHON_FAST_PYCALL
  5423. if (PyFunction_Check(__pyx_t_1)) {
  5424. PyObject *__pyx_temp[3] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5425. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 428, __pyx_L1_error)
  5426. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  5427. __Pyx_GOTREF(__pyx_t_2);
  5428. } else
  5429. #endif
  5430. #if CYTHON_FAST_PYCCALL
  5431. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  5432. PyObject *__pyx_temp[3] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5433. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 428, __pyx_L1_error)
  5434. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  5435. __Pyx_GOTREF(__pyx_t_2);
  5436. } else
  5437. #endif
  5438. {
  5439. __pyx_t_3 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 428, __pyx_L1_error)
  5440. __Pyx_GOTREF(__pyx_t_3);
  5441. if (__pyx_t_4) {
  5442. __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); __pyx_t_4 = NULL;
  5443. }
  5444. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  5445. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  5446. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  5447. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  5448. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  5449. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  5450. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 428, __pyx_L1_error)
  5451. __Pyx_GOTREF(__pyx_t_2);
  5452. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  5453. }
  5454. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  5455. __pyx_r = __pyx_t_2;
  5456. __pyx_t_2 = 0;
  5457. goto __pyx_L0;
  5458. /* "_yaml.pyx":427
  5459. * elif token.type == YAML_BLOCK_SEQUENCE_START_TOKEN:
  5460. * return BlockSequenceStartToken(start_mark, end_mark)
  5461. * elif token.type == YAML_BLOCK_MAPPING_START_TOKEN: # <<<<<<<<<<<<<<
  5462. * return BlockMappingStartToken(start_mark, end_mark)
  5463. * elif token.type == YAML_BLOCK_END_TOKEN:
  5464. */
  5465. break;
  5466. case YAML_BLOCK_END_TOKEN:
  5467. /* "_yaml.pyx":430
  5468. * return BlockMappingStartToken(start_mark, end_mark)
  5469. * elif token.type == YAML_BLOCK_END_TOKEN:
  5470. * return BlockEndToken(start_mark, end_mark) # <<<<<<<<<<<<<<
  5471. * elif token.type == YAML_FLOW_SEQUENCE_START_TOKEN:
  5472. * return FlowSequenceStartToken(start_mark, end_mark)
  5473. */
  5474. __Pyx_XDECREF(__pyx_r);
  5475. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_BlockEndToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 430, __pyx_L1_error)
  5476. __Pyx_GOTREF(__pyx_t_1);
  5477. __pyx_t_3 = NULL;
  5478. __pyx_t_6 = 0;
  5479. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  5480. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  5481. if (likely(__pyx_t_3)) {
  5482. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  5483. __Pyx_INCREF(__pyx_t_3);
  5484. __Pyx_INCREF(function);
  5485. __Pyx_DECREF_SET(__pyx_t_1, function);
  5486. __pyx_t_6 = 1;
  5487. }
  5488. }
  5489. #if CYTHON_FAST_PYCALL
  5490. if (PyFunction_Check(__pyx_t_1)) {
  5491. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5492. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 430, __pyx_L1_error)
  5493. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  5494. __Pyx_GOTREF(__pyx_t_2);
  5495. } else
  5496. #endif
  5497. #if CYTHON_FAST_PYCCALL
  5498. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  5499. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5500. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 430, __pyx_L1_error)
  5501. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  5502. __Pyx_GOTREF(__pyx_t_2);
  5503. } else
  5504. #endif
  5505. {
  5506. __pyx_t_4 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 430, __pyx_L1_error)
  5507. __Pyx_GOTREF(__pyx_t_4);
  5508. if (__pyx_t_3) {
  5509. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL;
  5510. }
  5511. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  5512. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  5513. PyTuple_SET_ITEM(__pyx_t_4, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  5514. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  5515. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  5516. PyTuple_SET_ITEM(__pyx_t_4, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  5517. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 430, __pyx_L1_error)
  5518. __Pyx_GOTREF(__pyx_t_2);
  5519. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  5520. }
  5521. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  5522. __pyx_r = __pyx_t_2;
  5523. __pyx_t_2 = 0;
  5524. goto __pyx_L0;
  5525. /* "_yaml.pyx":429
  5526. * elif token.type == YAML_BLOCK_MAPPING_START_TOKEN:
  5527. * return BlockMappingStartToken(start_mark, end_mark)
  5528. * elif token.type == YAML_BLOCK_END_TOKEN: # <<<<<<<<<<<<<<
  5529. * return BlockEndToken(start_mark, end_mark)
  5530. * elif token.type == YAML_FLOW_SEQUENCE_START_TOKEN:
  5531. */
  5532. break;
  5533. case YAML_FLOW_SEQUENCE_START_TOKEN:
  5534. /* "_yaml.pyx":432
  5535. * return BlockEndToken(start_mark, end_mark)
  5536. * elif token.type == YAML_FLOW_SEQUENCE_START_TOKEN:
  5537. * return FlowSequenceStartToken(start_mark, end_mark) # <<<<<<<<<<<<<<
  5538. * elif token.type == YAML_FLOW_SEQUENCE_END_TOKEN:
  5539. * return FlowSequenceEndToken(start_mark, end_mark)
  5540. */
  5541. __Pyx_XDECREF(__pyx_r);
  5542. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_FlowSequenceStartToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 432, __pyx_L1_error)
  5543. __Pyx_GOTREF(__pyx_t_1);
  5544. __pyx_t_4 = NULL;
  5545. __pyx_t_6 = 0;
  5546. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  5547. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_1);
  5548. if (likely(__pyx_t_4)) {
  5549. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  5550. __Pyx_INCREF(__pyx_t_4);
  5551. __Pyx_INCREF(function);
  5552. __Pyx_DECREF_SET(__pyx_t_1, function);
  5553. __pyx_t_6 = 1;
  5554. }
  5555. }
  5556. #if CYTHON_FAST_PYCALL
  5557. if (PyFunction_Check(__pyx_t_1)) {
  5558. PyObject *__pyx_temp[3] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5559. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 432, __pyx_L1_error)
  5560. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  5561. __Pyx_GOTREF(__pyx_t_2);
  5562. } else
  5563. #endif
  5564. #if CYTHON_FAST_PYCCALL
  5565. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  5566. PyObject *__pyx_temp[3] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5567. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 432, __pyx_L1_error)
  5568. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  5569. __Pyx_GOTREF(__pyx_t_2);
  5570. } else
  5571. #endif
  5572. {
  5573. __pyx_t_3 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 432, __pyx_L1_error)
  5574. __Pyx_GOTREF(__pyx_t_3);
  5575. if (__pyx_t_4) {
  5576. __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); __pyx_t_4 = NULL;
  5577. }
  5578. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  5579. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  5580. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  5581. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  5582. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  5583. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  5584. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 432, __pyx_L1_error)
  5585. __Pyx_GOTREF(__pyx_t_2);
  5586. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  5587. }
  5588. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  5589. __pyx_r = __pyx_t_2;
  5590. __pyx_t_2 = 0;
  5591. goto __pyx_L0;
  5592. /* "_yaml.pyx":431
  5593. * elif token.type == YAML_BLOCK_END_TOKEN:
  5594. * return BlockEndToken(start_mark, end_mark)
  5595. * elif token.type == YAML_FLOW_SEQUENCE_START_TOKEN: # <<<<<<<<<<<<<<
  5596. * return FlowSequenceStartToken(start_mark, end_mark)
  5597. * elif token.type == YAML_FLOW_SEQUENCE_END_TOKEN:
  5598. */
  5599. break;
  5600. case YAML_FLOW_SEQUENCE_END_TOKEN:
  5601. /* "_yaml.pyx":434
  5602. * return FlowSequenceStartToken(start_mark, end_mark)
  5603. * elif token.type == YAML_FLOW_SEQUENCE_END_TOKEN:
  5604. * return FlowSequenceEndToken(start_mark, end_mark) # <<<<<<<<<<<<<<
  5605. * elif token.type == YAML_FLOW_MAPPING_START_TOKEN:
  5606. * return FlowMappingStartToken(start_mark, end_mark)
  5607. */
  5608. __Pyx_XDECREF(__pyx_r);
  5609. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_FlowSequenceEndToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 434, __pyx_L1_error)
  5610. __Pyx_GOTREF(__pyx_t_1);
  5611. __pyx_t_3 = NULL;
  5612. __pyx_t_6 = 0;
  5613. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  5614. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  5615. if (likely(__pyx_t_3)) {
  5616. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  5617. __Pyx_INCREF(__pyx_t_3);
  5618. __Pyx_INCREF(function);
  5619. __Pyx_DECREF_SET(__pyx_t_1, function);
  5620. __pyx_t_6 = 1;
  5621. }
  5622. }
  5623. #if CYTHON_FAST_PYCALL
  5624. if (PyFunction_Check(__pyx_t_1)) {
  5625. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5626. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 434, __pyx_L1_error)
  5627. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  5628. __Pyx_GOTREF(__pyx_t_2);
  5629. } else
  5630. #endif
  5631. #if CYTHON_FAST_PYCCALL
  5632. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  5633. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5634. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 434, __pyx_L1_error)
  5635. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  5636. __Pyx_GOTREF(__pyx_t_2);
  5637. } else
  5638. #endif
  5639. {
  5640. __pyx_t_4 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 434, __pyx_L1_error)
  5641. __Pyx_GOTREF(__pyx_t_4);
  5642. if (__pyx_t_3) {
  5643. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL;
  5644. }
  5645. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  5646. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  5647. PyTuple_SET_ITEM(__pyx_t_4, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  5648. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  5649. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  5650. PyTuple_SET_ITEM(__pyx_t_4, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  5651. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 434, __pyx_L1_error)
  5652. __Pyx_GOTREF(__pyx_t_2);
  5653. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  5654. }
  5655. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  5656. __pyx_r = __pyx_t_2;
  5657. __pyx_t_2 = 0;
  5658. goto __pyx_L0;
  5659. /* "_yaml.pyx":433
  5660. * elif token.type == YAML_FLOW_SEQUENCE_START_TOKEN:
  5661. * return FlowSequenceStartToken(start_mark, end_mark)
  5662. * elif token.type == YAML_FLOW_SEQUENCE_END_TOKEN: # <<<<<<<<<<<<<<
  5663. * return FlowSequenceEndToken(start_mark, end_mark)
  5664. * elif token.type == YAML_FLOW_MAPPING_START_TOKEN:
  5665. */
  5666. break;
  5667. case YAML_FLOW_MAPPING_START_TOKEN:
  5668. /* "_yaml.pyx":436
  5669. * return FlowSequenceEndToken(start_mark, end_mark)
  5670. * elif token.type == YAML_FLOW_MAPPING_START_TOKEN:
  5671. * return FlowMappingStartToken(start_mark, end_mark) # <<<<<<<<<<<<<<
  5672. * elif token.type == YAML_FLOW_MAPPING_END_TOKEN:
  5673. * return FlowMappingEndToken(start_mark, end_mark)
  5674. */
  5675. __Pyx_XDECREF(__pyx_r);
  5676. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_FlowMappingStartToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 436, __pyx_L1_error)
  5677. __Pyx_GOTREF(__pyx_t_1);
  5678. __pyx_t_4 = NULL;
  5679. __pyx_t_6 = 0;
  5680. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  5681. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_1);
  5682. if (likely(__pyx_t_4)) {
  5683. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  5684. __Pyx_INCREF(__pyx_t_4);
  5685. __Pyx_INCREF(function);
  5686. __Pyx_DECREF_SET(__pyx_t_1, function);
  5687. __pyx_t_6 = 1;
  5688. }
  5689. }
  5690. #if CYTHON_FAST_PYCALL
  5691. if (PyFunction_Check(__pyx_t_1)) {
  5692. PyObject *__pyx_temp[3] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5693. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 436, __pyx_L1_error)
  5694. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  5695. __Pyx_GOTREF(__pyx_t_2);
  5696. } else
  5697. #endif
  5698. #if CYTHON_FAST_PYCCALL
  5699. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  5700. PyObject *__pyx_temp[3] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5701. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 436, __pyx_L1_error)
  5702. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  5703. __Pyx_GOTREF(__pyx_t_2);
  5704. } else
  5705. #endif
  5706. {
  5707. __pyx_t_3 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 436, __pyx_L1_error)
  5708. __Pyx_GOTREF(__pyx_t_3);
  5709. if (__pyx_t_4) {
  5710. __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); __pyx_t_4 = NULL;
  5711. }
  5712. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  5713. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  5714. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  5715. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  5716. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  5717. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  5718. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 436, __pyx_L1_error)
  5719. __Pyx_GOTREF(__pyx_t_2);
  5720. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  5721. }
  5722. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  5723. __pyx_r = __pyx_t_2;
  5724. __pyx_t_2 = 0;
  5725. goto __pyx_L0;
  5726. /* "_yaml.pyx":435
  5727. * elif token.type == YAML_FLOW_SEQUENCE_END_TOKEN:
  5728. * return FlowSequenceEndToken(start_mark, end_mark)
  5729. * elif token.type == YAML_FLOW_MAPPING_START_TOKEN: # <<<<<<<<<<<<<<
  5730. * return FlowMappingStartToken(start_mark, end_mark)
  5731. * elif token.type == YAML_FLOW_MAPPING_END_TOKEN:
  5732. */
  5733. break;
  5734. case YAML_FLOW_MAPPING_END_TOKEN:
  5735. /* "_yaml.pyx":438
  5736. * return FlowMappingStartToken(start_mark, end_mark)
  5737. * elif token.type == YAML_FLOW_MAPPING_END_TOKEN:
  5738. * return FlowMappingEndToken(start_mark, end_mark) # <<<<<<<<<<<<<<
  5739. * elif token.type == YAML_BLOCK_ENTRY_TOKEN:
  5740. * return BlockEntryToken(start_mark, end_mark)
  5741. */
  5742. __Pyx_XDECREF(__pyx_r);
  5743. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_FlowMappingEndToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 438, __pyx_L1_error)
  5744. __Pyx_GOTREF(__pyx_t_1);
  5745. __pyx_t_3 = NULL;
  5746. __pyx_t_6 = 0;
  5747. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  5748. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  5749. if (likely(__pyx_t_3)) {
  5750. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  5751. __Pyx_INCREF(__pyx_t_3);
  5752. __Pyx_INCREF(function);
  5753. __Pyx_DECREF_SET(__pyx_t_1, function);
  5754. __pyx_t_6 = 1;
  5755. }
  5756. }
  5757. #if CYTHON_FAST_PYCALL
  5758. if (PyFunction_Check(__pyx_t_1)) {
  5759. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5760. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 438, __pyx_L1_error)
  5761. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  5762. __Pyx_GOTREF(__pyx_t_2);
  5763. } else
  5764. #endif
  5765. #if CYTHON_FAST_PYCCALL
  5766. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  5767. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5768. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 438, __pyx_L1_error)
  5769. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  5770. __Pyx_GOTREF(__pyx_t_2);
  5771. } else
  5772. #endif
  5773. {
  5774. __pyx_t_4 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 438, __pyx_L1_error)
  5775. __Pyx_GOTREF(__pyx_t_4);
  5776. if (__pyx_t_3) {
  5777. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL;
  5778. }
  5779. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  5780. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  5781. PyTuple_SET_ITEM(__pyx_t_4, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  5782. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  5783. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  5784. PyTuple_SET_ITEM(__pyx_t_4, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  5785. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 438, __pyx_L1_error)
  5786. __Pyx_GOTREF(__pyx_t_2);
  5787. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  5788. }
  5789. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  5790. __pyx_r = __pyx_t_2;
  5791. __pyx_t_2 = 0;
  5792. goto __pyx_L0;
  5793. /* "_yaml.pyx":437
  5794. * elif token.type == YAML_FLOW_MAPPING_START_TOKEN:
  5795. * return FlowMappingStartToken(start_mark, end_mark)
  5796. * elif token.type == YAML_FLOW_MAPPING_END_TOKEN: # <<<<<<<<<<<<<<
  5797. * return FlowMappingEndToken(start_mark, end_mark)
  5798. * elif token.type == YAML_BLOCK_ENTRY_TOKEN:
  5799. */
  5800. break;
  5801. case YAML_BLOCK_ENTRY_TOKEN:
  5802. /* "_yaml.pyx":440
  5803. * return FlowMappingEndToken(start_mark, end_mark)
  5804. * elif token.type == YAML_BLOCK_ENTRY_TOKEN:
  5805. * return BlockEntryToken(start_mark, end_mark) # <<<<<<<<<<<<<<
  5806. * elif token.type == YAML_FLOW_ENTRY_TOKEN:
  5807. * return FlowEntryToken(start_mark, end_mark)
  5808. */
  5809. __Pyx_XDECREF(__pyx_r);
  5810. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_BlockEntryToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 440, __pyx_L1_error)
  5811. __Pyx_GOTREF(__pyx_t_1);
  5812. __pyx_t_4 = NULL;
  5813. __pyx_t_6 = 0;
  5814. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  5815. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_1);
  5816. if (likely(__pyx_t_4)) {
  5817. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  5818. __Pyx_INCREF(__pyx_t_4);
  5819. __Pyx_INCREF(function);
  5820. __Pyx_DECREF_SET(__pyx_t_1, function);
  5821. __pyx_t_6 = 1;
  5822. }
  5823. }
  5824. #if CYTHON_FAST_PYCALL
  5825. if (PyFunction_Check(__pyx_t_1)) {
  5826. PyObject *__pyx_temp[3] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5827. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 440, __pyx_L1_error)
  5828. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  5829. __Pyx_GOTREF(__pyx_t_2);
  5830. } else
  5831. #endif
  5832. #if CYTHON_FAST_PYCCALL
  5833. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  5834. PyObject *__pyx_temp[3] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5835. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 440, __pyx_L1_error)
  5836. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  5837. __Pyx_GOTREF(__pyx_t_2);
  5838. } else
  5839. #endif
  5840. {
  5841. __pyx_t_3 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 440, __pyx_L1_error)
  5842. __Pyx_GOTREF(__pyx_t_3);
  5843. if (__pyx_t_4) {
  5844. __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); __pyx_t_4 = NULL;
  5845. }
  5846. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  5847. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  5848. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  5849. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  5850. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  5851. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  5852. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 440, __pyx_L1_error)
  5853. __Pyx_GOTREF(__pyx_t_2);
  5854. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  5855. }
  5856. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  5857. __pyx_r = __pyx_t_2;
  5858. __pyx_t_2 = 0;
  5859. goto __pyx_L0;
  5860. /* "_yaml.pyx":439
  5861. * elif token.type == YAML_FLOW_MAPPING_END_TOKEN:
  5862. * return FlowMappingEndToken(start_mark, end_mark)
  5863. * elif token.type == YAML_BLOCK_ENTRY_TOKEN: # <<<<<<<<<<<<<<
  5864. * return BlockEntryToken(start_mark, end_mark)
  5865. * elif token.type == YAML_FLOW_ENTRY_TOKEN:
  5866. */
  5867. break;
  5868. case YAML_FLOW_ENTRY_TOKEN:
  5869. /* "_yaml.pyx":442
  5870. * return BlockEntryToken(start_mark, end_mark)
  5871. * elif token.type == YAML_FLOW_ENTRY_TOKEN:
  5872. * return FlowEntryToken(start_mark, end_mark) # <<<<<<<<<<<<<<
  5873. * elif token.type == YAML_KEY_TOKEN:
  5874. * return KeyToken(start_mark, end_mark)
  5875. */
  5876. __Pyx_XDECREF(__pyx_r);
  5877. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_FlowEntryToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 442, __pyx_L1_error)
  5878. __Pyx_GOTREF(__pyx_t_1);
  5879. __pyx_t_3 = NULL;
  5880. __pyx_t_6 = 0;
  5881. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  5882. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  5883. if (likely(__pyx_t_3)) {
  5884. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  5885. __Pyx_INCREF(__pyx_t_3);
  5886. __Pyx_INCREF(function);
  5887. __Pyx_DECREF_SET(__pyx_t_1, function);
  5888. __pyx_t_6 = 1;
  5889. }
  5890. }
  5891. #if CYTHON_FAST_PYCALL
  5892. if (PyFunction_Check(__pyx_t_1)) {
  5893. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5894. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 442, __pyx_L1_error)
  5895. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  5896. __Pyx_GOTREF(__pyx_t_2);
  5897. } else
  5898. #endif
  5899. #if CYTHON_FAST_PYCCALL
  5900. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  5901. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5902. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 442, __pyx_L1_error)
  5903. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  5904. __Pyx_GOTREF(__pyx_t_2);
  5905. } else
  5906. #endif
  5907. {
  5908. __pyx_t_4 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 442, __pyx_L1_error)
  5909. __Pyx_GOTREF(__pyx_t_4);
  5910. if (__pyx_t_3) {
  5911. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL;
  5912. }
  5913. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  5914. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  5915. PyTuple_SET_ITEM(__pyx_t_4, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  5916. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  5917. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  5918. PyTuple_SET_ITEM(__pyx_t_4, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  5919. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 442, __pyx_L1_error)
  5920. __Pyx_GOTREF(__pyx_t_2);
  5921. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  5922. }
  5923. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  5924. __pyx_r = __pyx_t_2;
  5925. __pyx_t_2 = 0;
  5926. goto __pyx_L0;
  5927. /* "_yaml.pyx":441
  5928. * elif token.type == YAML_BLOCK_ENTRY_TOKEN:
  5929. * return BlockEntryToken(start_mark, end_mark)
  5930. * elif token.type == YAML_FLOW_ENTRY_TOKEN: # <<<<<<<<<<<<<<
  5931. * return FlowEntryToken(start_mark, end_mark)
  5932. * elif token.type == YAML_KEY_TOKEN:
  5933. */
  5934. break;
  5935. case YAML_KEY_TOKEN:
  5936. /* "_yaml.pyx":444
  5937. * return FlowEntryToken(start_mark, end_mark)
  5938. * elif token.type == YAML_KEY_TOKEN:
  5939. * return KeyToken(start_mark, end_mark) # <<<<<<<<<<<<<<
  5940. * elif token.type == YAML_VALUE_TOKEN:
  5941. * return ValueToken(start_mark, end_mark)
  5942. */
  5943. __Pyx_XDECREF(__pyx_r);
  5944. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_KeyToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 444, __pyx_L1_error)
  5945. __Pyx_GOTREF(__pyx_t_1);
  5946. __pyx_t_4 = NULL;
  5947. __pyx_t_6 = 0;
  5948. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  5949. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_1);
  5950. if (likely(__pyx_t_4)) {
  5951. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  5952. __Pyx_INCREF(__pyx_t_4);
  5953. __Pyx_INCREF(function);
  5954. __Pyx_DECREF_SET(__pyx_t_1, function);
  5955. __pyx_t_6 = 1;
  5956. }
  5957. }
  5958. #if CYTHON_FAST_PYCALL
  5959. if (PyFunction_Check(__pyx_t_1)) {
  5960. PyObject *__pyx_temp[3] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5961. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 444, __pyx_L1_error)
  5962. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  5963. __Pyx_GOTREF(__pyx_t_2);
  5964. } else
  5965. #endif
  5966. #if CYTHON_FAST_PYCCALL
  5967. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  5968. PyObject *__pyx_temp[3] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  5969. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 444, __pyx_L1_error)
  5970. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  5971. __Pyx_GOTREF(__pyx_t_2);
  5972. } else
  5973. #endif
  5974. {
  5975. __pyx_t_3 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 444, __pyx_L1_error)
  5976. __Pyx_GOTREF(__pyx_t_3);
  5977. if (__pyx_t_4) {
  5978. __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); __pyx_t_4 = NULL;
  5979. }
  5980. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  5981. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  5982. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  5983. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  5984. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  5985. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  5986. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 444, __pyx_L1_error)
  5987. __Pyx_GOTREF(__pyx_t_2);
  5988. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  5989. }
  5990. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  5991. __pyx_r = __pyx_t_2;
  5992. __pyx_t_2 = 0;
  5993. goto __pyx_L0;
  5994. /* "_yaml.pyx":443
  5995. * elif token.type == YAML_FLOW_ENTRY_TOKEN:
  5996. * return FlowEntryToken(start_mark, end_mark)
  5997. * elif token.type == YAML_KEY_TOKEN: # <<<<<<<<<<<<<<
  5998. * return KeyToken(start_mark, end_mark)
  5999. * elif token.type == YAML_VALUE_TOKEN:
  6000. */
  6001. break;
  6002. case YAML_VALUE_TOKEN:
  6003. /* "_yaml.pyx":446
  6004. * return KeyToken(start_mark, end_mark)
  6005. * elif token.type == YAML_VALUE_TOKEN:
  6006. * return ValueToken(start_mark, end_mark) # <<<<<<<<<<<<<<
  6007. * elif token.type == YAML_ALIAS_TOKEN:
  6008. * value = PyUnicode_FromString(token.data.alias.value)
  6009. */
  6010. __Pyx_XDECREF(__pyx_r);
  6011. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_ValueToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 446, __pyx_L1_error)
  6012. __Pyx_GOTREF(__pyx_t_1);
  6013. __pyx_t_3 = NULL;
  6014. __pyx_t_6 = 0;
  6015. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  6016. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  6017. if (likely(__pyx_t_3)) {
  6018. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  6019. __Pyx_INCREF(__pyx_t_3);
  6020. __Pyx_INCREF(function);
  6021. __Pyx_DECREF_SET(__pyx_t_1, function);
  6022. __pyx_t_6 = 1;
  6023. }
  6024. }
  6025. #if CYTHON_FAST_PYCALL
  6026. if (PyFunction_Check(__pyx_t_1)) {
  6027. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  6028. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 446, __pyx_L1_error)
  6029. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  6030. __Pyx_GOTREF(__pyx_t_2);
  6031. } else
  6032. #endif
  6033. #if CYTHON_FAST_PYCCALL
  6034. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  6035. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  6036. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 446, __pyx_L1_error)
  6037. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  6038. __Pyx_GOTREF(__pyx_t_2);
  6039. } else
  6040. #endif
  6041. {
  6042. __pyx_t_4 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 446, __pyx_L1_error)
  6043. __Pyx_GOTREF(__pyx_t_4);
  6044. if (__pyx_t_3) {
  6045. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL;
  6046. }
  6047. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  6048. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  6049. PyTuple_SET_ITEM(__pyx_t_4, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  6050. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  6051. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  6052. PyTuple_SET_ITEM(__pyx_t_4, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  6053. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 446, __pyx_L1_error)
  6054. __Pyx_GOTREF(__pyx_t_2);
  6055. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  6056. }
  6057. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  6058. __pyx_r = __pyx_t_2;
  6059. __pyx_t_2 = 0;
  6060. goto __pyx_L0;
  6061. /* "_yaml.pyx":445
  6062. * elif token.type == YAML_KEY_TOKEN:
  6063. * return KeyToken(start_mark, end_mark)
  6064. * elif token.type == YAML_VALUE_TOKEN: # <<<<<<<<<<<<<<
  6065. * return ValueToken(start_mark, end_mark)
  6066. * elif token.type == YAML_ALIAS_TOKEN:
  6067. */
  6068. break;
  6069. case YAML_ALIAS_TOKEN:
  6070. /* "_yaml.pyx":448
  6071. * return ValueToken(start_mark, end_mark)
  6072. * elif token.type == YAML_ALIAS_TOKEN:
  6073. * value = PyUnicode_FromString(token.data.alias.value) # <<<<<<<<<<<<<<
  6074. * return AliasToken(value, start_mark, end_mark)
  6075. * elif token.type == YAML_ANCHOR_TOKEN:
  6076. */
  6077. __pyx_t_2 = PyUnicode_FromString(__pyx_v_token->data.alias.value); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 448, __pyx_L1_error)
  6078. __Pyx_GOTREF(__pyx_t_2);
  6079. __pyx_v_value = __pyx_t_2;
  6080. __pyx_t_2 = 0;
  6081. /* "_yaml.pyx":449
  6082. * elif token.type == YAML_ALIAS_TOKEN:
  6083. * value = PyUnicode_FromString(token.data.alias.value)
  6084. * return AliasToken(value, start_mark, end_mark) # <<<<<<<<<<<<<<
  6085. * elif token.type == YAML_ANCHOR_TOKEN:
  6086. * value = PyUnicode_FromString(token.data.anchor.value)
  6087. */
  6088. __Pyx_XDECREF(__pyx_r);
  6089. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_AliasToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 449, __pyx_L1_error)
  6090. __Pyx_GOTREF(__pyx_t_1);
  6091. __pyx_t_4 = NULL;
  6092. __pyx_t_6 = 0;
  6093. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  6094. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_1);
  6095. if (likely(__pyx_t_4)) {
  6096. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  6097. __Pyx_INCREF(__pyx_t_4);
  6098. __Pyx_INCREF(function);
  6099. __Pyx_DECREF_SET(__pyx_t_1, function);
  6100. __pyx_t_6 = 1;
  6101. }
  6102. }
  6103. #if CYTHON_FAST_PYCALL
  6104. if (PyFunction_Check(__pyx_t_1)) {
  6105. PyObject *__pyx_temp[4] = {__pyx_t_4, __pyx_v_value, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  6106. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 449, __pyx_L1_error)
  6107. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  6108. __Pyx_GOTREF(__pyx_t_2);
  6109. } else
  6110. #endif
  6111. #if CYTHON_FAST_PYCCALL
  6112. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  6113. PyObject *__pyx_temp[4] = {__pyx_t_4, __pyx_v_value, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  6114. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 449, __pyx_L1_error)
  6115. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  6116. __Pyx_GOTREF(__pyx_t_2);
  6117. } else
  6118. #endif
  6119. {
  6120. __pyx_t_3 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 449, __pyx_L1_error)
  6121. __Pyx_GOTREF(__pyx_t_3);
  6122. if (__pyx_t_4) {
  6123. __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); __pyx_t_4 = NULL;
  6124. }
  6125. __Pyx_INCREF(__pyx_v_value);
  6126. __Pyx_GIVEREF(__pyx_v_value);
  6127. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_6, __pyx_v_value);
  6128. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  6129. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  6130. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  6131. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  6132. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  6133. PyTuple_SET_ITEM(__pyx_t_3, 2+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  6134. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 449, __pyx_L1_error)
  6135. __Pyx_GOTREF(__pyx_t_2);
  6136. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  6137. }
  6138. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  6139. __pyx_r = __pyx_t_2;
  6140. __pyx_t_2 = 0;
  6141. goto __pyx_L0;
  6142. /* "_yaml.pyx":447
  6143. * elif token.type == YAML_VALUE_TOKEN:
  6144. * return ValueToken(start_mark, end_mark)
  6145. * elif token.type == YAML_ALIAS_TOKEN: # <<<<<<<<<<<<<<
  6146. * value = PyUnicode_FromString(token.data.alias.value)
  6147. * return AliasToken(value, start_mark, end_mark)
  6148. */
  6149. break;
  6150. case YAML_ANCHOR_TOKEN:
  6151. /* "_yaml.pyx":451
  6152. * return AliasToken(value, start_mark, end_mark)
  6153. * elif token.type == YAML_ANCHOR_TOKEN:
  6154. * value = PyUnicode_FromString(token.data.anchor.value) # <<<<<<<<<<<<<<
  6155. * return AnchorToken(value, start_mark, end_mark)
  6156. * elif token.type == YAML_TAG_TOKEN:
  6157. */
  6158. __pyx_t_2 = PyUnicode_FromString(__pyx_v_token->data.anchor.value); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 451, __pyx_L1_error)
  6159. __Pyx_GOTREF(__pyx_t_2);
  6160. __pyx_v_value = __pyx_t_2;
  6161. __pyx_t_2 = 0;
  6162. /* "_yaml.pyx":452
  6163. * elif token.type == YAML_ANCHOR_TOKEN:
  6164. * value = PyUnicode_FromString(token.data.anchor.value)
  6165. * return AnchorToken(value, start_mark, end_mark) # <<<<<<<<<<<<<<
  6166. * elif token.type == YAML_TAG_TOKEN:
  6167. * handle = PyUnicode_FromString(token.data.tag.handle)
  6168. */
  6169. __Pyx_XDECREF(__pyx_r);
  6170. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_AnchorToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 452, __pyx_L1_error)
  6171. __Pyx_GOTREF(__pyx_t_1);
  6172. __pyx_t_3 = NULL;
  6173. __pyx_t_6 = 0;
  6174. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  6175. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  6176. if (likely(__pyx_t_3)) {
  6177. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  6178. __Pyx_INCREF(__pyx_t_3);
  6179. __Pyx_INCREF(function);
  6180. __Pyx_DECREF_SET(__pyx_t_1, function);
  6181. __pyx_t_6 = 1;
  6182. }
  6183. }
  6184. #if CYTHON_FAST_PYCALL
  6185. if (PyFunction_Check(__pyx_t_1)) {
  6186. PyObject *__pyx_temp[4] = {__pyx_t_3, __pyx_v_value, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  6187. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 452, __pyx_L1_error)
  6188. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  6189. __Pyx_GOTREF(__pyx_t_2);
  6190. } else
  6191. #endif
  6192. #if CYTHON_FAST_PYCCALL
  6193. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  6194. PyObject *__pyx_temp[4] = {__pyx_t_3, __pyx_v_value, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  6195. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 452, __pyx_L1_error)
  6196. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  6197. __Pyx_GOTREF(__pyx_t_2);
  6198. } else
  6199. #endif
  6200. {
  6201. __pyx_t_4 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 452, __pyx_L1_error)
  6202. __Pyx_GOTREF(__pyx_t_4);
  6203. if (__pyx_t_3) {
  6204. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL;
  6205. }
  6206. __Pyx_INCREF(__pyx_v_value);
  6207. __Pyx_GIVEREF(__pyx_v_value);
  6208. PyTuple_SET_ITEM(__pyx_t_4, 0+__pyx_t_6, __pyx_v_value);
  6209. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  6210. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  6211. PyTuple_SET_ITEM(__pyx_t_4, 1+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  6212. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  6213. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  6214. PyTuple_SET_ITEM(__pyx_t_4, 2+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  6215. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 452, __pyx_L1_error)
  6216. __Pyx_GOTREF(__pyx_t_2);
  6217. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  6218. }
  6219. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  6220. __pyx_r = __pyx_t_2;
  6221. __pyx_t_2 = 0;
  6222. goto __pyx_L0;
  6223. /* "_yaml.pyx":450
  6224. * value = PyUnicode_FromString(token.data.alias.value)
  6225. * return AliasToken(value, start_mark, end_mark)
  6226. * elif token.type == YAML_ANCHOR_TOKEN: # <<<<<<<<<<<<<<
  6227. * value = PyUnicode_FromString(token.data.anchor.value)
  6228. * return AnchorToken(value, start_mark, end_mark)
  6229. */
  6230. break;
  6231. case YAML_TAG_TOKEN:
  6232. /* "_yaml.pyx":454
  6233. * return AnchorToken(value, start_mark, end_mark)
  6234. * elif token.type == YAML_TAG_TOKEN:
  6235. * handle = PyUnicode_FromString(token.data.tag.handle) # <<<<<<<<<<<<<<
  6236. * suffix = PyUnicode_FromString(token.data.tag.suffix)
  6237. * if not handle:
  6238. */
  6239. __pyx_t_2 = PyUnicode_FromString(__pyx_v_token->data.tag.handle); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 454, __pyx_L1_error)
  6240. __Pyx_GOTREF(__pyx_t_2);
  6241. __pyx_v_handle = __pyx_t_2;
  6242. __pyx_t_2 = 0;
  6243. /* "_yaml.pyx":455
  6244. * elif token.type == YAML_TAG_TOKEN:
  6245. * handle = PyUnicode_FromString(token.data.tag.handle)
  6246. * suffix = PyUnicode_FromString(token.data.tag.suffix) # <<<<<<<<<<<<<<
  6247. * if not handle:
  6248. * handle = None
  6249. */
  6250. __pyx_t_2 = PyUnicode_FromString(__pyx_v_token->data.tag.suffix); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 455, __pyx_L1_error)
  6251. __Pyx_GOTREF(__pyx_t_2);
  6252. __pyx_v_suffix = __pyx_t_2;
  6253. __pyx_t_2 = 0;
  6254. /* "_yaml.pyx":456
  6255. * handle = PyUnicode_FromString(token.data.tag.handle)
  6256. * suffix = PyUnicode_FromString(token.data.tag.suffix)
  6257. * if not handle: # <<<<<<<<<<<<<<
  6258. * handle = None
  6259. * return TagToken((handle, suffix), start_mark, end_mark)
  6260. */
  6261. __pyx_t_5 = __Pyx_PyObject_IsTrue(__pyx_v_handle); if (unlikely(__pyx_t_5 < 0)) __PYX_ERR(0, 456, __pyx_L1_error)
  6262. __pyx_t_8 = ((!__pyx_t_5) != 0);
  6263. if (__pyx_t_8) {
  6264. /* "_yaml.pyx":457
  6265. * suffix = PyUnicode_FromString(token.data.tag.suffix)
  6266. * if not handle:
  6267. * handle = None # <<<<<<<<<<<<<<
  6268. * return TagToken((handle, suffix), start_mark, end_mark)
  6269. * elif token.type == YAML_SCALAR_TOKEN:
  6270. */
  6271. __Pyx_INCREF(Py_None);
  6272. __Pyx_DECREF_SET(__pyx_v_handle, Py_None);
  6273. /* "_yaml.pyx":456
  6274. * handle = PyUnicode_FromString(token.data.tag.handle)
  6275. * suffix = PyUnicode_FromString(token.data.tag.suffix)
  6276. * if not handle: # <<<<<<<<<<<<<<
  6277. * handle = None
  6278. * return TagToken((handle, suffix), start_mark, end_mark)
  6279. */
  6280. }
  6281. /* "_yaml.pyx":458
  6282. * if not handle:
  6283. * handle = None
  6284. * return TagToken((handle, suffix), start_mark, end_mark) # <<<<<<<<<<<<<<
  6285. * elif token.type == YAML_SCALAR_TOKEN:
  6286. * value = PyUnicode_DecodeUTF8(token.data.scalar.value,
  6287. */
  6288. __Pyx_XDECREF(__pyx_r);
  6289. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_TagToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 458, __pyx_L1_error)
  6290. __Pyx_GOTREF(__pyx_t_1);
  6291. __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 458, __pyx_L1_error)
  6292. __Pyx_GOTREF(__pyx_t_4);
  6293. __Pyx_INCREF(__pyx_v_handle);
  6294. __Pyx_GIVEREF(__pyx_v_handle);
  6295. PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_handle);
  6296. __Pyx_INCREF(__pyx_v_suffix);
  6297. __Pyx_GIVEREF(__pyx_v_suffix);
  6298. PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_v_suffix);
  6299. __pyx_t_3 = NULL;
  6300. __pyx_t_6 = 0;
  6301. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  6302. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  6303. if (likely(__pyx_t_3)) {
  6304. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  6305. __Pyx_INCREF(__pyx_t_3);
  6306. __Pyx_INCREF(function);
  6307. __Pyx_DECREF_SET(__pyx_t_1, function);
  6308. __pyx_t_6 = 1;
  6309. }
  6310. }
  6311. #if CYTHON_FAST_PYCALL
  6312. if (PyFunction_Check(__pyx_t_1)) {
  6313. PyObject *__pyx_temp[4] = {__pyx_t_3, __pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  6314. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 458, __pyx_L1_error)
  6315. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  6316. __Pyx_GOTREF(__pyx_t_2);
  6317. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  6318. } else
  6319. #endif
  6320. #if CYTHON_FAST_PYCCALL
  6321. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  6322. PyObject *__pyx_temp[4] = {__pyx_t_3, __pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  6323. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 458, __pyx_L1_error)
  6324. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  6325. __Pyx_GOTREF(__pyx_t_2);
  6326. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  6327. } else
  6328. #endif
  6329. {
  6330. __pyx_t_7 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 458, __pyx_L1_error)
  6331. __Pyx_GOTREF(__pyx_t_7);
  6332. if (__pyx_t_3) {
  6333. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_3); __pyx_t_3 = NULL;
  6334. }
  6335. __Pyx_GIVEREF(__pyx_t_4);
  6336. PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_6, __pyx_t_4);
  6337. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  6338. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  6339. PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  6340. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  6341. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  6342. PyTuple_SET_ITEM(__pyx_t_7, 2+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  6343. __pyx_t_4 = 0;
  6344. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_7, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 458, __pyx_L1_error)
  6345. __Pyx_GOTREF(__pyx_t_2);
  6346. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  6347. }
  6348. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  6349. __pyx_r = __pyx_t_2;
  6350. __pyx_t_2 = 0;
  6351. goto __pyx_L0;
  6352. /* "_yaml.pyx":453
  6353. * value = PyUnicode_FromString(token.data.anchor.value)
  6354. * return AnchorToken(value, start_mark, end_mark)
  6355. * elif token.type == YAML_TAG_TOKEN: # <<<<<<<<<<<<<<
  6356. * handle = PyUnicode_FromString(token.data.tag.handle)
  6357. * suffix = PyUnicode_FromString(token.data.tag.suffix)
  6358. */
  6359. break;
  6360. case YAML_SCALAR_TOKEN:
  6361. /* "_yaml.pyx":460
  6362. * return TagToken((handle, suffix), start_mark, end_mark)
  6363. * elif token.type == YAML_SCALAR_TOKEN:
  6364. * value = PyUnicode_DecodeUTF8(token.data.scalar.value, # <<<<<<<<<<<<<<
  6365. * token.data.scalar.length, 'strict')
  6366. * plain = False
  6367. */
  6368. __pyx_t_2 = PyUnicode_DecodeUTF8(__pyx_v_token->data.scalar.value, __pyx_v_token->data.scalar.length, ((char *)"strict")); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 460, __pyx_L1_error)
  6369. __Pyx_GOTREF(__pyx_t_2);
  6370. __pyx_v_value = __pyx_t_2;
  6371. __pyx_t_2 = 0;
  6372. /* "_yaml.pyx":462
  6373. * value = PyUnicode_DecodeUTF8(token.data.scalar.value,
  6374. * token.data.scalar.length, 'strict')
  6375. * plain = False # <<<<<<<<<<<<<<
  6376. * style = None
  6377. * if token.data.scalar.style == YAML_PLAIN_SCALAR_STYLE:
  6378. */
  6379. __pyx_v_plain = 0;
  6380. /* "_yaml.pyx":463
  6381. * token.data.scalar.length, 'strict')
  6382. * plain = False
  6383. * style = None # <<<<<<<<<<<<<<
  6384. * if token.data.scalar.style == YAML_PLAIN_SCALAR_STYLE:
  6385. * plain = True
  6386. */
  6387. __Pyx_INCREF(Py_None);
  6388. __pyx_v_style = ((PyObject*)Py_None);
  6389. /* "_yaml.pyx":464
  6390. * plain = False
  6391. * style = None
  6392. * if token.data.scalar.style == YAML_PLAIN_SCALAR_STYLE: # <<<<<<<<<<<<<<
  6393. * plain = True
  6394. * style = u''
  6395. */
  6396. switch (__pyx_v_token->data.scalar.style) {
  6397. case YAML_PLAIN_SCALAR_STYLE:
  6398. /* "_yaml.pyx":465
  6399. * style = None
  6400. * if token.data.scalar.style == YAML_PLAIN_SCALAR_STYLE:
  6401. * plain = True # <<<<<<<<<<<<<<
  6402. * style = u''
  6403. * elif token.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE:
  6404. */
  6405. __pyx_v_plain = 1;
  6406. /* "_yaml.pyx":466
  6407. * if token.data.scalar.style == YAML_PLAIN_SCALAR_STYLE:
  6408. * plain = True
  6409. * style = u'' # <<<<<<<<<<<<<<
  6410. * elif token.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE:
  6411. * style = u'\''
  6412. */
  6413. __Pyx_INCREF(__pyx_kp_u__6);
  6414. __Pyx_DECREF_SET(__pyx_v_style, __pyx_kp_u__6);
  6415. /* "_yaml.pyx":464
  6416. * plain = False
  6417. * style = None
  6418. * if token.data.scalar.style == YAML_PLAIN_SCALAR_STYLE: # <<<<<<<<<<<<<<
  6419. * plain = True
  6420. * style = u''
  6421. */
  6422. break;
  6423. case YAML_SINGLE_QUOTED_SCALAR_STYLE:
  6424. /* "_yaml.pyx":468
  6425. * style = u''
  6426. * elif token.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE:
  6427. * style = u'\'' # <<<<<<<<<<<<<<
  6428. * elif token.data.scalar.style == YAML_DOUBLE_QUOTED_SCALAR_STYLE:
  6429. * style = u'"'
  6430. */
  6431. __Pyx_INCREF(__pyx_kp_u__7);
  6432. __Pyx_DECREF_SET(__pyx_v_style, __pyx_kp_u__7);
  6433. /* "_yaml.pyx":467
  6434. * plain = True
  6435. * style = u''
  6436. * elif token.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE: # <<<<<<<<<<<<<<
  6437. * style = u'\''
  6438. * elif token.data.scalar.style == YAML_DOUBLE_QUOTED_SCALAR_STYLE:
  6439. */
  6440. break;
  6441. case YAML_DOUBLE_QUOTED_SCALAR_STYLE:
  6442. /* "_yaml.pyx":470
  6443. * style = u'\''
  6444. * elif token.data.scalar.style == YAML_DOUBLE_QUOTED_SCALAR_STYLE:
  6445. * style = u'"' # <<<<<<<<<<<<<<
  6446. * elif token.data.scalar.style == YAML_LITERAL_SCALAR_STYLE:
  6447. * style = u'|'
  6448. */
  6449. __Pyx_INCREF(__pyx_kp_u__8);
  6450. __Pyx_DECREF_SET(__pyx_v_style, __pyx_kp_u__8);
  6451. /* "_yaml.pyx":469
  6452. * elif token.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE:
  6453. * style = u'\''
  6454. * elif token.data.scalar.style == YAML_DOUBLE_QUOTED_SCALAR_STYLE: # <<<<<<<<<<<<<<
  6455. * style = u'"'
  6456. * elif token.data.scalar.style == YAML_LITERAL_SCALAR_STYLE:
  6457. */
  6458. break;
  6459. case YAML_LITERAL_SCALAR_STYLE:
  6460. /* "_yaml.pyx":472
  6461. * style = u'"'
  6462. * elif token.data.scalar.style == YAML_LITERAL_SCALAR_STYLE:
  6463. * style = u'|' # <<<<<<<<<<<<<<
  6464. * elif token.data.scalar.style == YAML_FOLDED_SCALAR_STYLE:
  6465. * style = u'>'
  6466. */
  6467. __Pyx_INCREF(__pyx_kp_u__9);
  6468. __Pyx_DECREF_SET(__pyx_v_style, __pyx_kp_u__9);
  6469. /* "_yaml.pyx":471
  6470. * elif token.data.scalar.style == YAML_DOUBLE_QUOTED_SCALAR_STYLE:
  6471. * style = u'"'
  6472. * elif token.data.scalar.style == YAML_LITERAL_SCALAR_STYLE: # <<<<<<<<<<<<<<
  6473. * style = u'|'
  6474. * elif token.data.scalar.style == YAML_FOLDED_SCALAR_STYLE:
  6475. */
  6476. break;
  6477. case YAML_FOLDED_SCALAR_STYLE:
  6478. /* "_yaml.pyx":474
  6479. * style = u'|'
  6480. * elif token.data.scalar.style == YAML_FOLDED_SCALAR_STYLE:
  6481. * style = u'>' # <<<<<<<<<<<<<<
  6482. * return ScalarToken(value, plain,
  6483. * start_mark, end_mark, style)
  6484. */
  6485. __Pyx_INCREF(__pyx_kp_u__10);
  6486. __Pyx_DECREF_SET(__pyx_v_style, __pyx_kp_u__10);
  6487. /* "_yaml.pyx":473
  6488. * elif token.data.scalar.style == YAML_LITERAL_SCALAR_STYLE:
  6489. * style = u'|'
  6490. * elif token.data.scalar.style == YAML_FOLDED_SCALAR_STYLE: # <<<<<<<<<<<<<<
  6491. * style = u'>'
  6492. * return ScalarToken(value, plain,
  6493. */
  6494. break;
  6495. default: break;
  6496. }
  6497. /* "_yaml.pyx":475
  6498. * elif token.data.scalar.style == YAML_FOLDED_SCALAR_STYLE:
  6499. * style = u'>'
  6500. * return ScalarToken(value, plain, # <<<<<<<<<<<<<<
  6501. * start_mark, end_mark, style)
  6502. * else:
  6503. */
  6504. __Pyx_XDECREF(__pyx_r);
  6505. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_ScalarToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 475, __pyx_L1_error)
  6506. __Pyx_GOTREF(__pyx_t_1);
  6507. __pyx_t_7 = __Pyx_PyBool_FromLong(__pyx_v_plain); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 475, __pyx_L1_error)
  6508. __Pyx_GOTREF(__pyx_t_7);
  6509. /* "_yaml.pyx":476
  6510. * style = u'>'
  6511. * return ScalarToken(value, plain,
  6512. * start_mark, end_mark, style) # <<<<<<<<<<<<<<
  6513. * else:
  6514. * if PY_MAJOR_VERSION < 3:
  6515. */
  6516. __pyx_t_4 = NULL;
  6517. __pyx_t_6 = 0;
  6518. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  6519. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_1);
  6520. if (likely(__pyx_t_4)) {
  6521. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  6522. __Pyx_INCREF(__pyx_t_4);
  6523. __Pyx_INCREF(function);
  6524. __Pyx_DECREF_SET(__pyx_t_1, function);
  6525. __pyx_t_6 = 1;
  6526. }
  6527. }
  6528. #if CYTHON_FAST_PYCALL
  6529. if (PyFunction_Check(__pyx_t_1)) {
  6530. PyObject *__pyx_temp[6] = {__pyx_t_4, __pyx_v_value, __pyx_t_7, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_v_style};
  6531. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 5+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 475, __pyx_L1_error)
  6532. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  6533. __Pyx_GOTREF(__pyx_t_2);
  6534. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  6535. } else
  6536. #endif
  6537. #if CYTHON_FAST_PYCCALL
  6538. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  6539. PyObject *__pyx_temp[6] = {__pyx_t_4, __pyx_v_value, __pyx_t_7, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_v_style};
  6540. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 5+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 475, __pyx_L1_error)
  6541. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  6542. __Pyx_GOTREF(__pyx_t_2);
  6543. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  6544. } else
  6545. #endif
  6546. {
  6547. __pyx_t_3 = PyTuple_New(5+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 475, __pyx_L1_error)
  6548. __Pyx_GOTREF(__pyx_t_3);
  6549. if (__pyx_t_4) {
  6550. __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); __pyx_t_4 = NULL;
  6551. }
  6552. __Pyx_INCREF(__pyx_v_value);
  6553. __Pyx_GIVEREF(__pyx_v_value);
  6554. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_6, __pyx_v_value);
  6555. __Pyx_GIVEREF(__pyx_t_7);
  6556. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_6, __pyx_t_7);
  6557. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  6558. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  6559. PyTuple_SET_ITEM(__pyx_t_3, 2+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  6560. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  6561. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  6562. PyTuple_SET_ITEM(__pyx_t_3, 3+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  6563. __Pyx_INCREF(__pyx_v_style);
  6564. __Pyx_GIVEREF(__pyx_v_style);
  6565. PyTuple_SET_ITEM(__pyx_t_3, 4+__pyx_t_6, __pyx_v_style);
  6566. __pyx_t_7 = 0;
  6567. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 475, __pyx_L1_error)
  6568. __Pyx_GOTREF(__pyx_t_2);
  6569. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  6570. }
  6571. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  6572. __pyx_r = __pyx_t_2;
  6573. __pyx_t_2 = 0;
  6574. goto __pyx_L0;
  6575. /* "_yaml.pyx":459
  6576. * handle = None
  6577. * return TagToken((handle, suffix), start_mark, end_mark)
  6578. * elif token.type == YAML_SCALAR_TOKEN: # <<<<<<<<<<<<<<
  6579. * value = PyUnicode_DecodeUTF8(token.data.scalar.value,
  6580. * token.data.scalar.length, 'strict')
  6581. */
  6582. break;
  6583. default:
  6584. /* "_yaml.pyx":478
  6585. * start_mark, end_mark, style)
  6586. * else:
  6587. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  6588. * raise ValueError("unknown token type")
  6589. * else:
  6590. */
  6591. __pyx_t_8 = ((PY_MAJOR_VERSION < 3) != 0);
  6592. if (unlikely(__pyx_t_8)) {
  6593. /* "_yaml.pyx":479
  6594. * else:
  6595. * if PY_MAJOR_VERSION < 3:
  6596. * raise ValueError("unknown token type") # <<<<<<<<<<<<<<
  6597. * else:
  6598. * raise ValueError(u"unknown token type")
  6599. */
  6600. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__11, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 479, __pyx_L1_error)
  6601. __Pyx_GOTREF(__pyx_t_2);
  6602. __Pyx_Raise(__pyx_t_2, 0, 0, 0);
  6603. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  6604. __PYX_ERR(0, 479, __pyx_L1_error)
  6605. /* "_yaml.pyx":478
  6606. * start_mark, end_mark, style)
  6607. * else:
  6608. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  6609. * raise ValueError("unknown token type")
  6610. * else:
  6611. */
  6612. }
  6613. /* "_yaml.pyx":481
  6614. * raise ValueError("unknown token type")
  6615. * else:
  6616. * raise ValueError(u"unknown token type") # <<<<<<<<<<<<<<
  6617. *
  6618. * def get_token(self):
  6619. */
  6620. /*else*/ {
  6621. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__12, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 481, __pyx_L1_error)
  6622. __Pyx_GOTREF(__pyx_t_2);
  6623. __Pyx_Raise(__pyx_t_2, 0, 0, 0);
  6624. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  6625. __PYX_ERR(0, 481, __pyx_L1_error)
  6626. }
  6627. break;
  6628. }
  6629. /* "_yaml.pyx":386
  6630. * return token_object
  6631. *
  6632. * cdef object _token_to_object(self, yaml_token_t *token): # <<<<<<<<<<<<<<
  6633. * start_mark = Mark(self.stream_name,
  6634. * token.start_mark.index,
  6635. */
  6636. /* function exit code */
  6637. __pyx_L1_error:;
  6638. __Pyx_XDECREF(__pyx_t_1);
  6639. __Pyx_XDECREF(__pyx_t_2);
  6640. __Pyx_XDECREF(__pyx_t_3);
  6641. __Pyx_XDECREF(__pyx_t_4);
  6642. __Pyx_XDECREF(__pyx_t_7);
  6643. __Pyx_AddTraceback("_yaml.CParser._token_to_object", __pyx_clineno, __pyx_lineno, __pyx_filename);
  6644. __pyx_r = 0;
  6645. __pyx_L0:;
  6646. __Pyx_XDECREF((PyObject *)__pyx_v_start_mark);
  6647. __Pyx_XDECREF((PyObject *)__pyx_v_end_mark);
  6648. __Pyx_XDECREF(__pyx_v_encoding);
  6649. __Pyx_XDECREF(__pyx_v_handle);
  6650. __Pyx_XDECREF(__pyx_v_prefix);
  6651. __Pyx_XDECREF(__pyx_v_value);
  6652. __Pyx_XDECREF(__pyx_v_suffix);
  6653. __Pyx_XDECREF(__pyx_v_style);
  6654. __Pyx_XGIVEREF(__pyx_r);
  6655. __Pyx_RefNannyFinishContext();
  6656. return __pyx_r;
  6657. }
  6658. /* "_yaml.pyx":483
  6659. * raise ValueError(u"unknown token type")
  6660. *
  6661. * def get_token(self): # <<<<<<<<<<<<<<
  6662. * if self.current_token is not None:
  6663. * value = self.current_token
  6664. */
  6665. /* Python wrapper */
  6666. static PyObject *__pyx_pw_5_yaml_7CParser_9get_token(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  6667. static PyObject *__pyx_pw_5_yaml_7CParser_9get_token(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  6668. PyObject *__pyx_r = 0;
  6669. __Pyx_RefNannyDeclarations
  6670. __Pyx_RefNannySetupContext("get_token (wrapper)", 0);
  6671. __pyx_r = __pyx_pf_5_yaml_7CParser_8get_token(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self));
  6672. /* function exit code */
  6673. __Pyx_RefNannyFinishContext();
  6674. return __pyx_r;
  6675. }
  6676. static PyObject *__pyx_pf_5_yaml_7CParser_8get_token(struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  6677. PyObject *__pyx_v_value = NULL;
  6678. PyObject *__pyx_r = NULL;
  6679. __Pyx_RefNannyDeclarations
  6680. int __pyx_t_1;
  6681. int __pyx_t_2;
  6682. PyObject *__pyx_t_3 = NULL;
  6683. __Pyx_RefNannySetupContext("get_token", 0);
  6684. /* "_yaml.pyx":484
  6685. *
  6686. * def get_token(self):
  6687. * if self.current_token is not None: # <<<<<<<<<<<<<<
  6688. * value = self.current_token
  6689. * self.current_token = None
  6690. */
  6691. __pyx_t_1 = (__pyx_v_self->current_token != Py_None);
  6692. __pyx_t_2 = (__pyx_t_1 != 0);
  6693. if (__pyx_t_2) {
  6694. /* "_yaml.pyx":485
  6695. * def get_token(self):
  6696. * if self.current_token is not None:
  6697. * value = self.current_token # <<<<<<<<<<<<<<
  6698. * self.current_token = None
  6699. * else:
  6700. */
  6701. __pyx_t_3 = __pyx_v_self->current_token;
  6702. __Pyx_INCREF(__pyx_t_3);
  6703. __pyx_v_value = __pyx_t_3;
  6704. __pyx_t_3 = 0;
  6705. /* "_yaml.pyx":486
  6706. * if self.current_token is not None:
  6707. * value = self.current_token
  6708. * self.current_token = None # <<<<<<<<<<<<<<
  6709. * else:
  6710. * value = self._scan()
  6711. */
  6712. __Pyx_INCREF(Py_None);
  6713. __Pyx_GIVEREF(Py_None);
  6714. __Pyx_GOTREF(__pyx_v_self->current_token);
  6715. __Pyx_DECREF(__pyx_v_self->current_token);
  6716. __pyx_v_self->current_token = Py_None;
  6717. /* "_yaml.pyx":484
  6718. *
  6719. * def get_token(self):
  6720. * if self.current_token is not None: # <<<<<<<<<<<<<<
  6721. * value = self.current_token
  6722. * self.current_token = None
  6723. */
  6724. goto __pyx_L3;
  6725. }
  6726. /* "_yaml.pyx":488
  6727. * self.current_token = None
  6728. * else:
  6729. * value = self._scan() # <<<<<<<<<<<<<<
  6730. * return value
  6731. *
  6732. */
  6733. /*else*/ {
  6734. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_scan(__pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 488, __pyx_L1_error)
  6735. __Pyx_GOTREF(__pyx_t_3);
  6736. __pyx_v_value = __pyx_t_3;
  6737. __pyx_t_3 = 0;
  6738. }
  6739. __pyx_L3:;
  6740. /* "_yaml.pyx":489
  6741. * else:
  6742. * value = self._scan()
  6743. * return value # <<<<<<<<<<<<<<
  6744. *
  6745. * def peek_token(self):
  6746. */
  6747. __Pyx_XDECREF(__pyx_r);
  6748. __Pyx_INCREF(__pyx_v_value);
  6749. __pyx_r = __pyx_v_value;
  6750. goto __pyx_L0;
  6751. /* "_yaml.pyx":483
  6752. * raise ValueError(u"unknown token type")
  6753. *
  6754. * def get_token(self): # <<<<<<<<<<<<<<
  6755. * if self.current_token is not None:
  6756. * value = self.current_token
  6757. */
  6758. /* function exit code */
  6759. __pyx_L1_error:;
  6760. __Pyx_XDECREF(__pyx_t_3);
  6761. __Pyx_AddTraceback("_yaml.CParser.get_token", __pyx_clineno, __pyx_lineno, __pyx_filename);
  6762. __pyx_r = NULL;
  6763. __pyx_L0:;
  6764. __Pyx_XDECREF(__pyx_v_value);
  6765. __Pyx_XGIVEREF(__pyx_r);
  6766. __Pyx_RefNannyFinishContext();
  6767. return __pyx_r;
  6768. }
  6769. /* "_yaml.pyx":491
  6770. * return value
  6771. *
  6772. * def peek_token(self): # <<<<<<<<<<<<<<
  6773. * if self.current_token is None:
  6774. * self.current_token = self._scan()
  6775. */
  6776. /* Python wrapper */
  6777. static PyObject *__pyx_pw_5_yaml_7CParser_11peek_token(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  6778. static PyObject *__pyx_pw_5_yaml_7CParser_11peek_token(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  6779. PyObject *__pyx_r = 0;
  6780. __Pyx_RefNannyDeclarations
  6781. __Pyx_RefNannySetupContext("peek_token (wrapper)", 0);
  6782. __pyx_r = __pyx_pf_5_yaml_7CParser_10peek_token(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self));
  6783. /* function exit code */
  6784. __Pyx_RefNannyFinishContext();
  6785. return __pyx_r;
  6786. }
  6787. static PyObject *__pyx_pf_5_yaml_7CParser_10peek_token(struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  6788. PyObject *__pyx_r = NULL;
  6789. __Pyx_RefNannyDeclarations
  6790. int __pyx_t_1;
  6791. int __pyx_t_2;
  6792. PyObject *__pyx_t_3 = NULL;
  6793. __Pyx_RefNannySetupContext("peek_token", 0);
  6794. /* "_yaml.pyx":492
  6795. *
  6796. * def peek_token(self):
  6797. * if self.current_token is None: # <<<<<<<<<<<<<<
  6798. * self.current_token = self._scan()
  6799. * return self.current_token
  6800. */
  6801. __pyx_t_1 = (__pyx_v_self->current_token == Py_None);
  6802. __pyx_t_2 = (__pyx_t_1 != 0);
  6803. if (__pyx_t_2) {
  6804. /* "_yaml.pyx":493
  6805. * def peek_token(self):
  6806. * if self.current_token is None:
  6807. * self.current_token = self._scan() # <<<<<<<<<<<<<<
  6808. * return self.current_token
  6809. *
  6810. */
  6811. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_scan(__pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 493, __pyx_L1_error)
  6812. __Pyx_GOTREF(__pyx_t_3);
  6813. __Pyx_GIVEREF(__pyx_t_3);
  6814. __Pyx_GOTREF(__pyx_v_self->current_token);
  6815. __Pyx_DECREF(__pyx_v_self->current_token);
  6816. __pyx_v_self->current_token = __pyx_t_3;
  6817. __pyx_t_3 = 0;
  6818. /* "_yaml.pyx":492
  6819. *
  6820. * def peek_token(self):
  6821. * if self.current_token is None: # <<<<<<<<<<<<<<
  6822. * self.current_token = self._scan()
  6823. * return self.current_token
  6824. */
  6825. }
  6826. /* "_yaml.pyx":494
  6827. * if self.current_token is None:
  6828. * self.current_token = self._scan()
  6829. * return self.current_token # <<<<<<<<<<<<<<
  6830. *
  6831. * def check_token(self, *choices):
  6832. */
  6833. __Pyx_XDECREF(__pyx_r);
  6834. __Pyx_INCREF(__pyx_v_self->current_token);
  6835. __pyx_r = __pyx_v_self->current_token;
  6836. goto __pyx_L0;
  6837. /* "_yaml.pyx":491
  6838. * return value
  6839. *
  6840. * def peek_token(self): # <<<<<<<<<<<<<<
  6841. * if self.current_token is None:
  6842. * self.current_token = self._scan()
  6843. */
  6844. /* function exit code */
  6845. __pyx_L1_error:;
  6846. __Pyx_XDECREF(__pyx_t_3);
  6847. __Pyx_AddTraceback("_yaml.CParser.peek_token", __pyx_clineno, __pyx_lineno, __pyx_filename);
  6848. __pyx_r = NULL;
  6849. __pyx_L0:;
  6850. __Pyx_XGIVEREF(__pyx_r);
  6851. __Pyx_RefNannyFinishContext();
  6852. return __pyx_r;
  6853. }
  6854. /* "_yaml.pyx":496
  6855. * return self.current_token
  6856. *
  6857. * def check_token(self, *choices): # <<<<<<<<<<<<<<
  6858. * if self.current_token is None:
  6859. * self.current_token = self._scan()
  6860. */
  6861. /* Python wrapper */
  6862. static PyObject *__pyx_pw_5_yaml_7CParser_13check_token(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
  6863. static PyObject *__pyx_pw_5_yaml_7CParser_13check_token(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  6864. PyObject *__pyx_v_choices = 0;
  6865. PyObject *__pyx_r = 0;
  6866. __Pyx_RefNannyDeclarations
  6867. __Pyx_RefNannySetupContext("check_token (wrapper)", 0);
  6868. if (unlikely(__pyx_kwds) && unlikely(PyDict_Size(__pyx_kwds) > 0) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "check_token", 0))) return NULL;
  6869. __Pyx_INCREF(__pyx_args);
  6870. __pyx_v_choices = __pyx_args;
  6871. __pyx_r = __pyx_pf_5_yaml_7CParser_12check_token(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self), __pyx_v_choices);
  6872. /* function exit code */
  6873. __Pyx_XDECREF(__pyx_v_choices);
  6874. __Pyx_RefNannyFinishContext();
  6875. return __pyx_r;
  6876. }
  6877. static PyObject *__pyx_pf_5_yaml_7CParser_12check_token(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, PyObject *__pyx_v_choices) {
  6878. PyObject *__pyx_v_token_class = NULL;
  6879. PyObject *__pyx_v_choice = NULL;
  6880. PyObject *__pyx_r = NULL;
  6881. __Pyx_RefNannyDeclarations
  6882. int __pyx_t_1;
  6883. int __pyx_t_2;
  6884. PyObject *__pyx_t_3 = NULL;
  6885. Py_ssize_t __pyx_t_4;
  6886. PyObject *__pyx_t_5 = NULL;
  6887. __Pyx_RefNannySetupContext("check_token", 0);
  6888. /* "_yaml.pyx":497
  6889. *
  6890. * def check_token(self, *choices):
  6891. * if self.current_token is None: # <<<<<<<<<<<<<<
  6892. * self.current_token = self._scan()
  6893. * if self.current_token is None:
  6894. */
  6895. __pyx_t_1 = (__pyx_v_self->current_token == Py_None);
  6896. __pyx_t_2 = (__pyx_t_1 != 0);
  6897. if (__pyx_t_2) {
  6898. /* "_yaml.pyx":498
  6899. * def check_token(self, *choices):
  6900. * if self.current_token is None:
  6901. * self.current_token = self._scan() # <<<<<<<<<<<<<<
  6902. * if self.current_token is None:
  6903. * return False
  6904. */
  6905. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_scan(__pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 498, __pyx_L1_error)
  6906. __Pyx_GOTREF(__pyx_t_3);
  6907. __Pyx_GIVEREF(__pyx_t_3);
  6908. __Pyx_GOTREF(__pyx_v_self->current_token);
  6909. __Pyx_DECREF(__pyx_v_self->current_token);
  6910. __pyx_v_self->current_token = __pyx_t_3;
  6911. __pyx_t_3 = 0;
  6912. /* "_yaml.pyx":497
  6913. *
  6914. * def check_token(self, *choices):
  6915. * if self.current_token is None: # <<<<<<<<<<<<<<
  6916. * self.current_token = self._scan()
  6917. * if self.current_token is None:
  6918. */
  6919. }
  6920. /* "_yaml.pyx":499
  6921. * if self.current_token is None:
  6922. * self.current_token = self._scan()
  6923. * if self.current_token is None: # <<<<<<<<<<<<<<
  6924. * return False
  6925. * if not choices:
  6926. */
  6927. __pyx_t_2 = (__pyx_v_self->current_token == Py_None);
  6928. __pyx_t_1 = (__pyx_t_2 != 0);
  6929. if (__pyx_t_1) {
  6930. /* "_yaml.pyx":500
  6931. * self.current_token = self._scan()
  6932. * if self.current_token is None:
  6933. * return False # <<<<<<<<<<<<<<
  6934. * if not choices:
  6935. * return True
  6936. */
  6937. __Pyx_XDECREF(__pyx_r);
  6938. __Pyx_INCREF(Py_False);
  6939. __pyx_r = Py_False;
  6940. goto __pyx_L0;
  6941. /* "_yaml.pyx":499
  6942. * if self.current_token is None:
  6943. * self.current_token = self._scan()
  6944. * if self.current_token is None: # <<<<<<<<<<<<<<
  6945. * return False
  6946. * if not choices:
  6947. */
  6948. }
  6949. /* "_yaml.pyx":501
  6950. * if self.current_token is None:
  6951. * return False
  6952. * if not choices: # <<<<<<<<<<<<<<
  6953. * return True
  6954. * token_class = self.current_token.__class__
  6955. */
  6956. __pyx_t_1 = (PyTuple_GET_SIZE(__pyx_v_choices) != 0);
  6957. __pyx_t_2 = ((!__pyx_t_1) != 0);
  6958. if (__pyx_t_2) {
  6959. /* "_yaml.pyx":502
  6960. * return False
  6961. * if not choices:
  6962. * return True # <<<<<<<<<<<<<<
  6963. * token_class = self.current_token.__class__
  6964. * for choice in choices:
  6965. */
  6966. __Pyx_XDECREF(__pyx_r);
  6967. __Pyx_INCREF(Py_True);
  6968. __pyx_r = Py_True;
  6969. goto __pyx_L0;
  6970. /* "_yaml.pyx":501
  6971. * if self.current_token is None:
  6972. * return False
  6973. * if not choices: # <<<<<<<<<<<<<<
  6974. * return True
  6975. * token_class = self.current_token.__class__
  6976. */
  6977. }
  6978. /* "_yaml.pyx":503
  6979. * if not choices:
  6980. * return True
  6981. * token_class = self.current_token.__class__ # <<<<<<<<<<<<<<
  6982. * for choice in choices:
  6983. * if token_class is choice:
  6984. */
  6985. __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->current_token, __pyx_n_s_class); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 503, __pyx_L1_error)
  6986. __Pyx_GOTREF(__pyx_t_3);
  6987. __pyx_v_token_class = __pyx_t_3;
  6988. __pyx_t_3 = 0;
  6989. /* "_yaml.pyx":504
  6990. * return True
  6991. * token_class = self.current_token.__class__
  6992. * for choice in choices: # <<<<<<<<<<<<<<
  6993. * if token_class is choice:
  6994. * return True
  6995. */
  6996. __pyx_t_3 = __pyx_v_choices; __Pyx_INCREF(__pyx_t_3); __pyx_t_4 = 0;
  6997. for (;;) {
  6998. if (__pyx_t_4 >= PyTuple_GET_SIZE(__pyx_t_3)) break;
  6999. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  7000. __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_5); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 504, __pyx_L1_error)
  7001. #else
  7002. __pyx_t_5 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 504, __pyx_L1_error)
  7003. __Pyx_GOTREF(__pyx_t_5);
  7004. #endif
  7005. __Pyx_XDECREF_SET(__pyx_v_choice, __pyx_t_5);
  7006. __pyx_t_5 = 0;
  7007. /* "_yaml.pyx":505
  7008. * token_class = self.current_token.__class__
  7009. * for choice in choices:
  7010. * if token_class is choice: # <<<<<<<<<<<<<<
  7011. * return True
  7012. * return False
  7013. */
  7014. __pyx_t_2 = (__pyx_v_token_class == __pyx_v_choice);
  7015. __pyx_t_1 = (__pyx_t_2 != 0);
  7016. if (__pyx_t_1) {
  7017. /* "_yaml.pyx":506
  7018. * for choice in choices:
  7019. * if token_class is choice:
  7020. * return True # <<<<<<<<<<<<<<
  7021. * return False
  7022. *
  7023. */
  7024. __Pyx_XDECREF(__pyx_r);
  7025. __Pyx_INCREF(Py_True);
  7026. __pyx_r = Py_True;
  7027. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  7028. goto __pyx_L0;
  7029. /* "_yaml.pyx":505
  7030. * token_class = self.current_token.__class__
  7031. * for choice in choices:
  7032. * if token_class is choice: # <<<<<<<<<<<<<<
  7033. * return True
  7034. * return False
  7035. */
  7036. }
  7037. /* "_yaml.pyx":504
  7038. * return True
  7039. * token_class = self.current_token.__class__
  7040. * for choice in choices: # <<<<<<<<<<<<<<
  7041. * if token_class is choice:
  7042. * return True
  7043. */
  7044. }
  7045. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  7046. /* "_yaml.pyx":507
  7047. * if token_class is choice:
  7048. * return True
  7049. * return False # <<<<<<<<<<<<<<
  7050. *
  7051. * def raw_parse(self):
  7052. */
  7053. __Pyx_XDECREF(__pyx_r);
  7054. __Pyx_INCREF(Py_False);
  7055. __pyx_r = Py_False;
  7056. goto __pyx_L0;
  7057. /* "_yaml.pyx":496
  7058. * return self.current_token
  7059. *
  7060. * def check_token(self, *choices): # <<<<<<<<<<<<<<
  7061. * if self.current_token is None:
  7062. * self.current_token = self._scan()
  7063. */
  7064. /* function exit code */
  7065. __pyx_L1_error:;
  7066. __Pyx_XDECREF(__pyx_t_3);
  7067. __Pyx_XDECREF(__pyx_t_5);
  7068. __Pyx_AddTraceback("_yaml.CParser.check_token", __pyx_clineno, __pyx_lineno, __pyx_filename);
  7069. __pyx_r = NULL;
  7070. __pyx_L0:;
  7071. __Pyx_XDECREF(__pyx_v_token_class);
  7072. __Pyx_XDECREF(__pyx_v_choice);
  7073. __Pyx_XGIVEREF(__pyx_r);
  7074. __Pyx_RefNannyFinishContext();
  7075. return __pyx_r;
  7076. }
  7077. /* "_yaml.pyx":509
  7078. * return False
  7079. *
  7080. * def raw_parse(self): # <<<<<<<<<<<<<<
  7081. * cdef yaml_event_t event
  7082. * cdef int done
  7083. */
  7084. /* Python wrapper */
  7085. static PyObject *__pyx_pw_5_yaml_7CParser_15raw_parse(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  7086. static PyObject *__pyx_pw_5_yaml_7CParser_15raw_parse(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  7087. PyObject *__pyx_r = 0;
  7088. __Pyx_RefNannyDeclarations
  7089. __Pyx_RefNannySetupContext("raw_parse (wrapper)", 0);
  7090. __pyx_r = __pyx_pf_5_yaml_7CParser_14raw_parse(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self));
  7091. /* function exit code */
  7092. __Pyx_RefNannyFinishContext();
  7093. return __pyx_r;
  7094. }
  7095. static PyObject *__pyx_pf_5_yaml_7CParser_14raw_parse(struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  7096. yaml_event_t __pyx_v_event;
  7097. int __pyx_v_done;
  7098. int __pyx_v_count;
  7099. PyObject *__pyx_v_error = NULL;
  7100. PyObject *__pyx_r = NULL;
  7101. __Pyx_RefNannyDeclarations
  7102. int __pyx_t_1;
  7103. int __pyx_t_2;
  7104. PyObject *__pyx_t_3 = NULL;
  7105. __Pyx_RefNannySetupContext("raw_parse", 0);
  7106. /* "_yaml.pyx":513
  7107. * cdef int done
  7108. * cdef int count
  7109. * count = 0 # <<<<<<<<<<<<<<
  7110. * done = 0
  7111. * while done == 0:
  7112. */
  7113. __pyx_v_count = 0;
  7114. /* "_yaml.pyx":514
  7115. * cdef int count
  7116. * count = 0
  7117. * done = 0 # <<<<<<<<<<<<<<
  7118. * while done == 0:
  7119. * if yaml_parser_parse(&self.parser, &event) == 0:
  7120. */
  7121. __pyx_v_done = 0;
  7122. /* "_yaml.pyx":515
  7123. * count = 0
  7124. * done = 0
  7125. * while done == 0: # <<<<<<<<<<<<<<
  7126. * if yaml_parser_parse(&self.parser, &event) == 0:
  7127. * error = self._parser_error()
  7128. */
  7129. while (1) {
  7130. __pyx_t_1 = ((__pyx_v_done == 0) != 0);
  7131. if (!__pyx_t_1) break;
  7132. /* "_yaml.pyx":516
  7133. * done = 0
  7134. * while done == 0:
  7135. * if yaml_parser_parse(&self.parser, &event) == 0: # <<<<<<<<<<<<<<
  7136. * error = self._parser_error()
  7137. * raise error
  7138. */
  7139. __pyx_t_2 = yaml_parser_parse((&__pyx_v_self->parser), (&__pyx_v_event)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 516, __pyx_L1_error)
  7140. __pyx_t_1 = ((__pyx_t_2 == 0) != 0);
  7141. if (unlikely(__pyx_t_1)) {
  7142. /* "_yaml.pyx":517
  7143. * while done == 0:
  7144. * if yaml_parser_parse(&self.parser, &event) == 0:
  7145. * error = self._parser_error() # <<<<<<<<<<<<<<
  7146. * raise error
  7147. * if event.type == YAML_NO_EVENT:
  7148. */
  7149. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parser_error(__pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 517, __pyx_L1_error)
  7150. __Pyx_GOTREF(__pyx_t_3);
  7151. __pyx_v_error = __pyx_t_3;
  7152. __pyx_t_3 = 0;
  7153. /* "_yaml.pyx":518
  7154. * if yaml_parser_parse(&self.parser, &event) == 0:
  7155. * error = self._parser_error()
  7156. * raise error # <<<<<<<<<<<<<<
  7157. * if event.type == YAML_NO_EVENT:
  7158. * done = 1
  7159. */
  7160. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  7161. __PYX_ERR(0, 518, __pyx_L1_error)
  7162. /* "_yaml.pyx":516
  7163. * done = 0
  7164. * while done == 0:
  7165. * if yaml_parser_parse(&self.parser, &event) == 0: # <<<<<<<<<<<<<<
  7166. * error = self._parser_error()
  7167. * raise error
  7168. */
  7169. }
  7170. /* "_yaml.pyx":519
  7171. * error = self._parser_error()
  7172. * raise error
  7173. * if event.type == YAML_NO_EVENT: # <<<<<<<<<<<<<<
  7174. * done = 1
  7175. * else:
  7176. */
  7177. __pyx_t_1 = ((__pyx_v_event.type == YAML_NO_EVENT) != 0);
  7178. if (__pyx_t_1) {
  7179. /* "_yaml.pyx":520
  7180. * raise error
  7181. * if event.type == YAML_NO_EVENT:
  7182. * done = 1 # <<<<<<<<<<<<<<
  7183. * else:
  7184. * count = count+1
  7185. */
  7186. __pyx_v_done = 1;
  7187. /* "_yaml.pyx":519
  7188. * error = self._parser_error()
  7189. * raise error
  7190. * if event.type == YAML_NO_EVENT: # <<<<<<<<<<<<<<
  7191. * done = 1
  7192. * else:
  7193. */
  7194. goto __pyx_L6;
  7195. }
  7196. /* "_yaml.pyx":522
  7197. * done = 1
  7198. * else:
  7199. * count = count+1 # <<<<<<<<<<<<<<
  7200. * yaml_event_delete(&event)
  7201. * return count
  7202. */
  7203. /*else*/ {
  7204. __pyx_v_count = (__pyx_v_count + 1);
  7205. }
  7206. __pyx_L6:;
  7207. /* "_yaml.pyx":523
  7208. * else:
  7209. * count = count+1
  7210. * yaml_event_delete(&event) # <<<<<<<<<<<<<<
  7211. * return count
  7212. *
  7213. */
  7214. yaml_event_delete((&__pyx_v_event));
  7215. }
  7216. /* "_yaml.pyx":524
  7217. * count = count+1
  7218. * yaml_event_delete(&event)
  7219. * return count # <<<<<<<<<<<<<<
  7220. *
  7221. * cdef object _parse(self):
  7222. */
  7223. __Pyx_XDECREF(__pyx_r);
  7224. __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_count); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 524, __pyx_L1_error)
  7225. __Pyx_GOTREF(__pyx_t_3);
  7226. __pyx_r = __pyx_t_3;
  7227. __pyx_t_3 = 0;
  7228. goto __pyx_L0;
  7229. /* "_yaml.pyx":509
  7230. * return False
  7231. *
  7232. * def raw_parse(self): # <<<<<<<<<<<<<<
  7233. * cdef yaml_event_t event
  7234. * cdef int done
  7235. */
  7236. /* function exit code */
  7237. __pyx_L1_error:;
  7238. __Pyx_XDECREF(__pyx_t_3);
  7239. __Pyx_AddTraceback("_yaml.CParser.raw_parse", __pyx_clineno, __pyx_lineno, __pyx_filename);
  7240. __pyx_r = NULL;
  7241. __pyx_L0:;
  7242. __Pyx_XDECREF(__pyx_v_error);
  7243. __Pyx_XGIVEREF(__pyx_r);
  7244. __Pyx_RefNannyFinishContext();
  7245. return __pyx_r;
  7246. }
  7247. /* "_yaml.pyx":526
  7248. * return count
  7249. *
  7250. * cdef object _parse(self): # <<<<<<<<<<<<<<
  7251. * cdef yaml_event_t event
  7252. * if yaml_parser_parse(&self.parser, &event) == 0:
  7253. */
  7254. static PyObject *__pyx_f_5_yaml_7CParser__parse(struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  7255. yaml_event_t __pyx_v_event;
  7256. PyObject *__pyx_v_error = NULL;
  7257. PyObject *__pyx_v_event_object = NULL;
  7258. PyObject *__pyx_r = NULL;
  7259. __Pyx_RefNannyDeclarations
  7260. int __pyx_t_1;
  7261. int __pyx_t_2;
  7262. PyObject *__pyx_t_3 = NULL;
  7263. __Pyx_RefNannySetupContext("_parse", 0);
  7264. /* "_yaml.pyx":528
  7265. * cdef object _parse(self):
  7266. * cdef yaml_event_t event
  7267. * if yaml_parser_parse(&self.parser, &event) == 0: # <<<<<<<<<<<<<<
  7268. * error = self._parser_error()
  7269. * raise error
  7270. */
  7271. __pyx_t_1 = yaml_parser_parse((&__pyx_v_self->parser), (&__pyx_v_event)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 528, __pyx_L1_error)
  7272. __pyx_t_2 = ((__pyx_t_1 == 0) != 0);
  7273. if (unlikely(__pyx_t_2)) {
  7274. /* "_yaml.pyx":529
  7275. * cdef yaml_event_t event
  7276. * if yaml_parser_parse(&self.parser, &event) == 0:
  7277. * error = self._parser_error() # <<<<<<<<<<<<<<
  7278. * raise error
  7279. * event_object = self._event_to_object(&event)
  7280. */
  7281. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parser_error(__pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 529, __pyx_L1_error)
  7282. __Pyx_GOTREF(__pyx_t_3);
  7283. __pyx_v_error = __pyx_t_3;
  7284. __pyx_t_3 = 0;
  7285. /* "_yaml.pyx":530
  7286. * if yaml_parser_parse(&self.parser, &event) == 0:
  7287. * error = self._parser_error()
  7288. * raise error # <<<<<<<<<<<<<<
  7289. * event_object = self._event_to_object(&event)
  7290. * yaml_event_delete(&event)
  7291. */
  7292. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  7293. __PYX_ERR(0, 530, __pyx_L1_error)
  7294. /* "_yaml.pyx":528
  7295. * cdef object _parse(self):
  7296. * cdef yaml_event_t event
  7297. * if yaml_parser_parse(&self.parser, &event) == 0: # <<<<<<<<<<<<<<
  7298. * error = self._parser_error()
  7299. * raise error
  7300. */
  7301. }
  7302. /* "_yaml.pyx":531
  7303. * error = self._parser_error()
  7304. * raise error
  7305. * event_object = self._event_to_object(&event) # <<<<<<<<<<<<<<
  7306. * yaml_event_delete(&event)
  7307. * return event_object
  7308. */
  7309. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_event_to_object(__pyx_v_self, (&__pyx_v_event)); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 531, __pyx_L1_error)
  7310. __Pyx_GOTREF(__pyx_t_3);
  7311. __pyx_v_event_object = __pyx_t_3;
  7312. __pyx_t_3 = 0;
  7313. /* "_yaml.pyx":532
  7314. * raise error
  7315. * event_object = self._event_to_object(&event)
  7316. * yaml_event_delete(&event) # <<<<<<<<<<<<<<
  7317. * return event_object
  7318. *
  7319. */
  7320. yaml_event_delete((&__pyx_v_event));
  7321. /* "_yaml.pyx":533
  7322. * event_object = self._event_to_object(&event)
  7323. * yaml_event_delete(&event)
  7324. * return event_object # <<<<<<<<<<<<<<
  7325. *
  7326. * cdef object _event_to_object(self, yaml_event_t *event):
  7327. */
  7328. __Pyx_XDECREF(__pyx_r);
  7329. __Pyx_INCREF(__pyx_v_event_object);
  7330. __pyx_r = __pyx_v_event_object;
  7331. goto __pyx_L0;
  7332. /* "_yaml.pyx":526
  7333. * return count
  7334. *
  7335. * cdef object _parse(self): # <<<<<<<<<<<<<<
  7336. * cdef yaml_event_t event
  7337. * if yaml_parser_parse(&self.parser, &event) == 0:
  7338. */
  7339. /* function exit code */
  7340. __pyx_L1_error:;
  7341. __Pyx_XDECREF(__pyx_t_3);
  7342. __Pyx_AddTraceback("_yaml.CParser._parse", __pyx_clineno, __pyx_lineno, __pyx_filename);
  7343. __pyx_r = 0;
  7344. __pyx_L0:;
  7345. __Pyx_XDECREF(__pyx_v_error);
  7346. __Pyx_XDECREF(__pyx_v_event_object);
  7347. __Pyx_XGIVEREF(__pyx_r);
  7348. __Pyx_RefNannyFinishContext();
  7349. return __pyx_r;
  7350. }
  7351. /* "_yaml.pyx":535
  7352. * return event_object
  7353. *
  7354. * cdef object _event_to_object(self, yaml_event_t *event): # <<<<<<<<<<<<<<
  7355. * cdef yaml_tag_directive_t *tag_directive
  7356. * start_mark = Mark(self.stream_name,
  7357. */
  7358. static PyObject *__pyx_f_5_yaml_7CParser__event_to_object(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, yaml_event_t *__pyx_v_event) {
  7359. yaml_tag_directive_t *__pyx_v_tag_directive;
  7360. struct __pyx_obj_5_yaml_Mark *__pyx_v_start_mark = NULL;
  7361. struct __pyx_obj_5_yaml_Mark *__pyx_v_end_mark = NULL;
  7362. PyObject *__pyx_v_encoding = NULL;
  7363. int __pyx_v_explicit;
  7364. PyObject *__pyx_v_version = NULL;
  7365. PyObject *__pyx_v_tags = NULL;
  7366. PyObject *__pyx_v_handle = NULL;
  7367. PyObject *__pyx_v_prefix = NULL;
  7368. PyObject *__pyx_v_anchor = NULL;
  7369. PyObject *__pyx_v_tag = NULL;
  7370. PyObject *__pyx_v_value = NULL;
  7371. int __pyx_v_plain_implicit;
  7372. int __pyx_v_quoted_implicit;
  7373. PyObject *__pyx_v_style = NULL;
  7374. int __pyx_v_implicit;
  7375. PyObject *__pyx_v_flow_style = NULL;
  7376. PyObject *__pyx_r = NULL;
  7377. __Pyx_RefNannyDeclarations
  7378. PyObject *__pyx_t_1 = NULL;
  7379. PyObject *__pyx_t_2 = NULL;
  7380. PyObject *__pyx_t_3 = NULL;
  7381. PyObject *__pyx_t_4 = NULL;
  7382. int __pyx_t_5;
  7383. int __pyx_t_6;
  7384. yaml_tag_directive_t *__pyx_t_7;
  7385. PyObject *__pyx_t_8 = NULL;
  7386. __Pyx_RefNannySetupContext("_event_to_object", 0);
  7387. /* "_yaml.pyx":538
  7388. * cdef yaml_tag_directive_t *tag_directive
  7389. * start_mark = Mark(self.stream_name,
  7390. * event.start_mark.index, # <<<<<<<<<<<<<<
  7391. * event.start_mark.line,
  7392. * event.start_mark.column,
  7393. */
  7394. __pyx_t_1 = __Pyx_PyInt_FromSize_t(__pyx_v_event->start_mark.index); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 538, __pyx_L1_error)
  7395. __Pyx_GOTREF(__pyx_t_1);
  7396. /* "_yaml.pyx":539
  7397. * start_mark = Mark(self.stream_name,
  7398. * event.start_mark.index,
  7399. * event.start_mark.line, # <<<<<<<<<<<<<<
  7400. * event.start_mark.column,
  7401. * None, None)
  7402. */
  7403. __pyx_t_2 = __Pyx_PyInt_FromSize_t(__pyx_v_event->start_mark.line); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 539, __pyx_L1_error)
  7404. __Pyx_GOTREF(__pyx_t_2);
  7405. /* "_yaml.pyx":540
  7406. * event.start_mark.index,
  7407. * event.start_mark.line,
  7408. * event.start_mark.column, # <<<<<<<<<<<<<<
  7409. * None, None)
  7410. * end_mark = Mark(self.stream_name,
  7411. */
  7412. __pyx_t_3 = __Pyx_PyInt_FromSize_t(__pyx_v_event->start_mark.column); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 540, __pyx_L1_error)
  7413. __Pyx_GOTREF(__pyx_t_3);
  7414. /* "_yaml.pyx":537
  7415. * cdef object _event_to_object(self, yaml_event_t *event):
  7416. * cdef yaml_tag_directive_t *tag_directive
  7417. * start_mark = Mark(self.stream_name, # <<<<<<<<<<<<<<
  7418. * event.start_mark.index,
  7419. * event.start_mark.line,
  7420. */
  7421. __pyx_t_4 = PyTuple_New(6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 537, __pyx_L1_error)
  7422. __Pyx_GOTREF(__pyx_t_4);
  7423. __Pyx_INCREF(__pyx_v_self->stream_name);
  7424. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  7425. PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->stream_name);
  7426. __Pyx_GIVEREF(__pyx_t_1);
  7427. PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1);
  7428. __Pyx_GIVEREF(__pyx_t_2);
  7429. PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_2);
  7430. __Pyx_GIVEREF(__pyx_t_3);
  7431. PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_t_3);
  7432. __Pyx_INCREF(Py_None);
  7433. __Pyx_GIVEREF(Py_None);
  7434. PyTuple_SET_ITEM(__pyx_t_4, 4, Py_None);
  7435. __Pyx_INCREF(Py_None);
  7436. __Pyx_GIVEREF(Py_None);
  7437. PyTuple_SET_ITEM(__pyx_t_4, 5, Py_None);
  7438. __pyx_t_1 = 0;
  7439. __pyx_t_2 = 0;
  7440. __pyx_t_3 = 0;
  7441. __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 537, __pyx_L1_error)
  7442. __Pyx_GOTREF(__pyx_t_3);
  7443. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  7444. __pyx_v_start_mark = ((struct __pyx_obj_5_yaml_Mark *)__pyx_t_3);
  7445. __pyx_t_3 = 0;
  7446. /* "_yaml.pyx":543
  7447. * None, None)
  7448. * end_mark = Mark(self.stream_name,
  7449. * event.end_mark.index, # <<<<<<<<<<<<<<
  7450. * event.end_mark.line,
  7451. * event.end_mark.column,
  7452. */
  7453. __pyx_t_3 = __Pyx_PyInt_FromSize_t(__pyx_v_event->end_mark.index); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 543, __pyx_L1_error)
  7454. __Pyx_GOTREF(__pyx_t_3);
  7455. /* "_yaml.pyx":544
  7456. * end_mark = Mark(self.stream_name,
  7457. * event.end_mark.index,
  7458. * event.end_mark.line, # <<<<<<<<<<<<<<
  7459. * event.end_mark.column,
  7460. * None, None)
  7461. */
  7462. __pyx_t_4 = __Pyx_PyInt_FromSize_t(__pyx_v_event->end_mark.line); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 544, __pyx_L1_error)
  7463. __Pyx_GOTREF(__pyx_t_4);
  7464. /* "_yaml.pyx":545
  7465. * event.end_mark.index,
  7466. * event.end_mark.line,
  7467. * event.end_mark.column, # <<<<<<<<<<<<<<
  7468. * None, None)
  7469. * if event.type == YAML_NO_EVENT:
  7470. */
  7471. __pyx_t_2 = __Pyx_PyInt_FromSize_t(__pyx_v_event->end_mark.column); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 545, __pyx_L1_error)
  7472. __Pyx_GOTREF(__pyx_t_2);
  7473. /* "_yaml.pyx":542
  7474. * event.start_mark.column,
  7475. * None, None)
  7476. * end_mark = Mark(self.stream_name, # <<<<<<<<<<<<<<
  7477. * event.end_mark.index,
  7478. * event.end_mark.line,
  7479. */
  7480. __pyx_t_1 = PyTuple_New(6); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 542, __pyx_L1_error)
  7481. __Pyx_GOTREF(__pyx_t_1);
  7482. __Pyx_INCREF(__pyx_v_self->stream_name);
  7483. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  7484. PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_self->stream_name);
  7485. __Pyx_GIVEREF(__pyx_t_3);
  7486. PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3);
  7487. __Pyx_GIVEREF(__pyx_t_4);
  7488. PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_t_4);
  7489. __Pyx_GIVEREF(__pyx_t_2);
  7490. PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_t_2);
  7491. __Pyx_INCREF(Py_None);
  7492. __Pyx_GIVEREF(Py_None);
  7493. PyTuple_SET_ITEM(__pyx_t_1, 4, Py_None);
  7494. __Pyx_INCREF(Py_None);
  7495. __Pyx_GIVEREF(Py_None);
  7496. PyTuple_SET_ITEM(__pyx_t_1, 5, Py_None);
  7497. __pyx_t_3 = 0;
  7498. __pyx_t_4 = 0;
  7499. __pyx_t_2 = 0;
  7500. __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 542, __pyx_L1_error)
  7501. __Pyx_GOTREF(__pyx_t_2);
  7502. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  7503. __pyx_v_end_mark = ((struct __pyx_obj_5_yaml_Mark *)__pyx_t_2);
  7504. __pyx_t_2 = 0;
  7505. /* "_yaml.pyx":547
  7506. * event.end_mark.column,
  7507. * None, None)
  7508. * if event.type == YAML_NO_EVENT: # <<<<<<<<<<<<<<
  7509. * return None
  7510. * elif event.type == YAML_STREAM_START_EVENT:
  7511. */
  7512. switch (__pyx_v_event->type) {
  7513. case YAML_NO_EVENT:
  7514. /* "_yaml.pyx":548
  7515. * None, None)
  7516. * if event.type == YAML_NO_EVENT:
  7517. * return None # <<<<<<<<<<<<<<
  7518. * elif event.type == YAML_STREAM_START_EVENT:
  7519. * encoding = None
  7520. */
  7521. __Pyx_XDECREF(__pyx_r);
  7522. __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  7523. goto __pyx_L0;
  7524. /* "_yaml.pyx":547
  7525. * event.end_mark.column,
  7526. * None, None)
  7527. * if event.type == YAML_NO_EVENT: # <<<<<<<<<<<<<<
  7528. * return None
  7529. * elif event.type == YAML_STREAM_START_EVENT:
  7530. */
  7531. break;
  7532. case YAML_STREAM_START_EVENT:
  7533. /* "_yaml.pyx":550
  7534. * return None
  7535. * elif event.type == YAML_STREAM_START_EVENT:
  7536. * encoding = None # <<<<<<<<<<<<<<
  7537. * if event.data.stream_start.encoding == YAML_UTF8_ENCODING:
  7538. * if self.unicode_source == 0:
  7539. */
  7540. __Pyx_INCREF(Py_None);
  7541. __pyx_v_encoding = ((PyObject*)Py_None);
  7542. /* "_yaml.pyx":551
  7543. * elif event.type == YAML_STREAM_START_EVENT:
  7544. * encoding = None
  7545. * if event.data.stream_start.encoding == YAML_UTF8_ENCODING: # <<<<<<<<<<<<<<
  7546. * if self.unicode_source == 0:
  7547. * encoding = u"utf-8"
  7548. */
  7549. switch (__pyx_v_event->data.stream_start.encoding) {
  7550. case YAML_UTF8_ENCODING:
  7551. /* "_yaml.pyx":552
  7552. * encoding = None
  7553. * if event.data.stream_start.encoding == YAML_UTF8_ENCODING:
  7554. * if self.unicode_source == 0: # <<<<<<<<<<<<<<
  7555. * encoding = u"utf-8"
  7556. * elif event.data.stream_start.encoding == YAML_UTF16LE_ENCODING:
  7557. */
  7558. __pyx_t_5 = ((__pyx_v_self->unicode_source == 0) != 0);
  7559. if (__pyx_t_5) {
  7560. /* "_yaml.pyx":553
  7561. * if event.data.stream_start.encoding == YAML_UTF8_ENCODING:
  7562. * if self.unicode_source == 0:
  7563. * encoding = u"utf-8" # <<<<<<<<<<<<<<
  7564. * elif event.data.stream_start.encoding == YAML_UTF16LE_ENCODING:
  7565. * encoding = u"utf-16-le"
  7566. */
  7567. __Pyx_INCREF(__pyx_kp_u_utf_8);
  7568. __Pyx_DECREF_SET(__pyx_v_encoding, __pyx_kp_u_utf_8);
  7569. /* "_yaml.pyx":552
  7570. * encoding = None
  7571. * if event.data.stream_start.encoding == YAML_UTF8_ENCODING:
  7572. * if self.unicode_source == 0: # <<<<<<<<<<<<<<
  7573. * encoding = u"utf-8"
  7574. * elif event.data.stream_start.encoding == YAML_UTF16LE_ENCODING:
  7575. */
  7576. }
  7577. /* "_yaml.pyx":551
  7578. * elif event.type == YAML_STREAM_START_EVENT:
  7579. * encoding = None
  7580. * if event.data.stream_start.encoding == YAML_UTF8_ENCODING: # <<<<<<<<<<<<<<
  7581. * if self.unicode_source == 0:
  7582. * encoding = u"utf-8"
  7583. */
  7584. break;
  7585. case YAML_UTF16LE_ENCODING:
  7586. /* "_yaml.pyx":555
  7587. * encoding = u"utf-8"
  7588. * elif event.data.stream_start.encoding == YAML_UTF16LE_ENCODING:
  7589. * encoding = u"utf-16-le" # <<<<<<<<<<<<<<
  7590. * elif event.data.stream_start.encoding == YAML_UTF16BE_ENCODING:
  7591. * encoding = u"utf-16-be"
  7592. */
  7593. __Pyx_INCREF(__pyx_kp_u_utf_16_le);
  7594. __Pyx_DECREF_SET(__pyx_v_encoding, __pyx_kp_u_utf_16_le);
  7595. /* "_yaml.pyx":554
  7596. * if self.unicode_source == 0:
  7597. * encoding = u"utf-8"
  7598. * elif event.data.stream_start.encoding == YAML_UTF16LE_ENCODING: # <<<<<<<<<<<<<<
  7599. * encoding = u"utf-16-le"
  7600. * elif event.data.stream_start.encoding == YAML_UTF16BE_ENCODING:
  7601. */
  7602. break;
  7603. case YAML_UTF16BE_ENCODING:
  7604. /* "_yaml.pyx":557
  7605. * encoding = u"utf-16-le"
  7606. * elif event.data.stream_start.encoding == YAML_UTF16BE_ENCODING:
  7607. * encoding = u"utf-16-be" # <<<<<<<<<<<<<<
  7608. * return StreamStartEvent(start_mark, end_mark, encoding)
  7609. * elif event.type == YAML_STREAM_END_EVENT:
  7610. */
  7611. __Pyx_INCREF(__pyx_kp_u_utf_16_be);
  7612. __Pyx_DECREF_SET(__pyx_v_encoding, __pyx_kp_u_utf_16_be);
  7613. /* "_yaml.pyx":556
  7614. * elif event.data.stream_start.encoding == YAML_UTF16LE_ENCODING:
  7615. * encoding = u"utf-16-le"
  7616. * elif event.data.stream_start.encoding == YAML_UTF16BE_ENCODING: # <<<<<<<<<<<<<<
  7617. * encoding = u"utf-16-be"
  7618. * return StreamStartEvent(start_mark, end_mark, encoding)
  7619. */
  7620. break;
  7621. default: break;
  7622. }
  7623. /* "_yaml.pyx":558
  7624. * elif event.data.stream_start.encoding == YAML_UTF16BE_ENCODING:
  7625. * encoding = u"utf-16-be"
  7626. * return StreamStartEvent(start_mark, end_mark, encoding) # <<<<<<<<<<<<<<
  7627. * elif event.type == YAML_STREAM_END_EVENT:
  7628. * return StreamEndEvent(start_mark, end_mark)
  7629. */
  7630. __Pyx_XDECREF(__pyx_r);
  7631. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_StreamStartEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 558, __pyx_L1_error)
  7632. __Pyx_GOTREF(__pyx_t_1);
  7633. __pyx_t_4 = NULL;
  7634. __pyx_t_6 = 0;
  7635. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  7636. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_1);
  7637. if (likely(__pyx_t_4)) {
  7638. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  7639. __Pyx_INCREF(__pyx_t_4);
  7640. __Pyx_INCREF(function);
  7641. __Pyx_DECREF_SET(__pyx_t_1, function);
  7642. __pyx_t_6 = 1;
  7643. }
  7644. }
  7645. #if CYTHON_FAST_PYCALL
  7646. if (PyFunction_Check(__pyx_t_1)) {
  7647. PyObject *__pyx_temp[4] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_v_encoding};
  7648. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 558, __pyx_L1_error)
  7649. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  7650. __Pyx_GOTREF(__pyx_t_2);
  7651. } else
  7652. #endif
  7653. #if CYTHON_FAST_PYCCALL
  7654. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  7655. PyObject *__pyx_temp[4] = {__pyx_t_4, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_v_encoding};
  7656. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 558, __pyx_L1_error)
  7657. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  7658. __Pyx_GOTREF(__pyx_t_2);
  7659. } else
  7660. #endif
  7661. {
  7662. __pyx_t_3 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 558, __pyx_L1_error)
  7663. __Pyx_GOTREF(__pyx_t_3);
  7664. if (__pyx_t_4) {
  7665. __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); __pyx_t_4 = NULL;
  7666. }
  7667. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  7668. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  7669. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  7670. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  7671. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  7672. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  7673. __Pyx_INCREF(__pyx_v_encoding);
  7674. __Pyx_GIVEREF(__pyx_v_encoding);
  7675. PyTuple_SET_ITEM(__pyx_t_3, 2+__pyx_t_6, __pyx_v_encoding);
  7676. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 558, __pyx_L1_error)
  7677. __Pyx_GOTREF(__pyx_t_2);
  7678. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  7679. }
  7680. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  7681. __pyx_r = __pyx_t_2;
  7682. __pyx_t_2 = 0;
  7683. goto __pyx_L0;
  7684. /* "_yaml.pyx":549
  7685. * if event.type == YAML_NO_EVENT:
  7686. * return None
  7687. * elif event.type == YAML_STREAM_START_EVENT: # <<<<<<<<<<<<<<
  7688. * encoding = None
  7689. * if event.data.stream_start.encoding == YAML_UTF8_ENCODING:
  7690. */
  7691. break;
  7692. case YAML_STREAM_END_EVENT:
  7693. /* "_yaml.pyx":560
  7694. * return StreamStartEvent(start_mark, end_mark, encoding)
  7695. * elif event.type == YAML_STREAM_END_EVENT:
  7696. * return StreamEndEvent(start_mark, end_mark) # <<<<<<<<<<<<<<
  7697. * elif event.type == YAML_DOCUMENT_START_EVENT:
  7698. * explicit = False
  7699. */
  7700. __Pyx_XDECREF(__pyx_r);
  7701. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_StreamEndEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 560, __pyx_L1_error)
  7702. __Pyx_GOTREF(__pyx_t_1);
  7703. __pyx_t_3 = NULL;
  7704. __pyx_t_6 = 0;
  7705. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  7706. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  7707. if (likely(__pyx_t_3)) {
  7708. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  7709. __Pyx_INCREF(__pyx_t_3);
  7710. __Pyx_INCREF(function);
  7711. __Pyx_DECREF_SET(__pyx_t_1, function);
  7712. __pyx_t_6 = 1;
  7713. }
  7714. }
  7715. #if CYTHON_FAST_PYCALL
  7716. if (PyFunction_Check(__pyx_t_1)) {
  7717. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  7718. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 560, __pyx_L1_error)
  7719. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  7720. __Pyx_GOTREF(__pyx_t_2);
  7721. } else
  7722. #endif
  7723. #if CYTHON_FAST_PYCCALL
  7724. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  7725. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  7726. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 560, __pyx_L1_error)
  7727. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  7728. __Pyx_GOTREF(__pyx_t_2);
  7729. } else
  7730. #endif
  7731. {
  7732. __pyx_t_4 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 560, __pyx_L1_error)
  7733. __Pyx_GOTREF(__pyx_t_4);
  7734. if (__pyx_t_3) {
  7735. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_3); __pyx_t_3 = NULL;
  7736. }
  7737. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  7738. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  7739. PyTuple_SET_ITEM(__pyx_t_4, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  7740. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  7741. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  7742. PyTuple_SET_ITEM(__pyx_t_4, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  7743. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_4, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 560, __pyx_L1_error)
  7744. __Pyx_GOTREF(__pyx_t_2);
  7745. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  7746. }
  7747. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  7748. __pyx_r = __pyx_t_2;
  7749. __pyx_t_2 = 0;
  7750. goto __pyx_L0;
  7751. /* "_yaml.pyx":559
  7752. * encoding = u"utf-16-be"
  7753. * return StreamStartEvent(start_mark, end_mark, encoding)
  7754. * elif event.type == YAML_STREAM_END_EVENT: # <<<<<<<<<<<<<<
  7755. * return StreamEndEvent(start_mark, end_mark)
  7756. * elif event.type == YAML_DOCUMENT_START_EVENT:
  7757. */
  7758. break;
  7759. case YAML_DOCUMENT_START_EVENT:
  7760. /* "_yaml.pyx":562
  7761. * return StreamEndEvent(start_mark, end_mark)
  7762. * elif event.type == YAML_DOCUMENT_START_EVENT:
  7763. * explicit = False # <<<<<<<<<<<<<<
  7764. * if event.data.document_start.implicit == 0:
  7765. * explicit = True
  7766. */
  7767. __pyx_v_explicit = 0;
  7768. /* "_yaml.pyx":563
  7769. * elif event.type == YAML_DOCUMENT_START_EVENT:
  7770. * explicit = False
  7771. * if event.data.document_start.implicit == 0: # <<<<<<<<<<<<<<
  7772. * explicit = True
  7773. * version = None
  7774. */
  7775. __pyx_t_5 = ((__pyx_v_event->data.document_start.implicit == 0) != 0);
  7776. if (__pyx_t_5) {
  7777. /* "_yaml.pyx":564
  7778. * explicit = False
  7779. * if event.data.document_start.implicit == 0:
  7780. * explicit = True # <<<<<<<<<<<<<<
  7781. * version = None
  7782. * if event.data.document_start.version_directive != NULL:
  7783. */
  7784. __pyx_v_explicit = 1;
  7785. /* "_yaml.pyx":563
  7786. * elif event.type == YAML_DOCUMENT_START_EVENT:
  7787. * explicit = False
  7788. * if event.data.document_start.implicit == 0: # <<<<<<<<<<<<<<
  7789. * explicit = True
  7790. * version = None
  7791. */
  7792. }
  7793. /* "_yaml.pyx":565
  7794. * if event.data.document_start.implicit == 0:
  7795. * explicit = True
  7796. * version = None # <<<<<<<<<<<<<<
  7797. * if event.data.document_start.version_directive != NULL:
  7798. * version = (event.data.document_start.version_directive.major,
  7799. */
  7800. __Pyx_INCREF(Py_None);
  7801. __pyx_v_version = Py_None;
  7802. /* "_yaml.pyx":566
  7803. * explicit = True
  7804. * version = None
  7805. * if event.data.document_start.version_directive != NULL: # <<<<<<<<<<<<<<
  7806. * version = (event.data.document_start.version_directive.major,
  7807. * event.data.document_start.version_directive.minor)
  7808. */
  7809. __pyx_t_5 = ((__pyx_v_event->data.document_start.version_directive != NULL) != 0);
  7810. if (__pyx_t_5) {
  7811. /* "_yaml.pyx":567
  7812. * version = None
  7813. * if event.data.document_start.version_directive != NULL:
  7814. * version = (event.data.document_start.version_directive.major, # <<<<<<<<<<<<<<
  7815. * event.data.document_start.version_directive.minor)
  7816. * tags = None
  7817. */
  7818. __pyx_t_2 = __Pyx_PyInt_From_int(__pyx_v_event->data.document_start.version_directive->major); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 567, __pyx_L1_error)
  7819. __Pyx_GOTREF(__pyx_t_2);
  7820. /* "_yaml.pyx":568
  7821. * if event.data.document_start.version_directive != NULL:
  7822. * version = (event.data.document_start.version_directive.major,
  7823. * event.data.document_start.version_directive.minor) # <<<<<<<<<<<<<<
  7824. * tags = None
  7825. * if event.data.document_start.tag_directives.start != NULL:
  7826. */
  7827. __pyx_t_1 = __Pyx_PyInt_From_int(__pyx_v_event->data.document_start.version_directive->minor); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 568, __pyx_L1_error)
  7828. __Pyx_GOTREF(__pyx_t_1);
  7829. /* "_yaml.pyx":567
  7830. * version = None
  7831. * if event.data.document_start.version_directive != NULL:
  7832. * version = (event.data.document_start.version_directive.major, # <<<<<<<<<<<<<<
  7833. * event.data.document_start.version_directive.minor)
  7834. * tags = None
  7835. */
  7836. __pyx_t_4 = PyTuple_New(2); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 567, __pyx_L1_error)
  7837. __Pyx_GOTREF(__pyx_t_4);
  7838. __Pyx_GIVEREF(__pyx_t_2);
  7839. PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_t_2);
  7840. __Pyx_GIVEREF(__pyx_t_1);
  7841. PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1);
  7842. __pyx_t_2 = 0;
  7843. __pyx_t_1 = 0;
  7844. __Pyx_DECREF_SET(__pyx_v_version, __pyx_t_4);
  7845. __pyx_t_4 = 0;
  7846. /* "_yaml.pyx":566
  7847. * explicit = True
  7848. * version = None
  7849. * if event.data.document_start.version_directive != NULL: # <<<<<<<<<<<<<<
  7850. * version = (event.data.document_start.version_directive.major,
  7851. * event.data.document_start.version_directive.minor)
  7852. */
  7853. }
  7854. /* "_yaml.pyx":569
  7855. * version = (event.data.document_start.version_directive.major,
  7856. * event.data.document_start.version_directive.minor)
  7857. * tags = None # <<<<<<<<<<<<<<
  7858. * if event.data.document_start.tag_directives.start != NULL:
  7859. * tags = {}
  7860. */
  7861. __Pyx_INCREF(Py_None);
  7862. __pyx_v_tags = ((PyObject*)Py_None);
  7863. /* "_yaml.pyx":570
  7864. * event.data.document_start.version_directive.minor)
  7865. * tags = None
  7866. * if event.data.document_start.tag_directives.start != NULL: # <<<<<<<<<<<<<<
  7867. * tags = {}
  7868. * tag_directive = event.data.document_start.tag_directives.start
  7869. */
  7870. __pyx_t_5 = ((__pyx_v_event->data.document_start.tag_directives.start != NULL) != 0);
  7871. if (__pyx_t_5) {
  7872. /* "_yaml.pyx":571
  7873. * tags = None
  7874. * if event.data.document_start.tag_directives.start != NULL:
  7875. * tags = {} # <<<<<<<<<<<<<<
  7876. * tag_directive = event.data.document_start.tag_directives.start
  7877. * while tag_directive != event.data.document_start.tag_directives.end:
  7878. */
  7879. __pyx_t_4 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 571, __pyx_L1_error)
  7880. __Pyx_GOTREF(__pyx_t_4);
  7881. __Pyx_DECREF_SET(__pyx_v_tags, ((PyObject*)__pyx_t_4));
  7882. __pyx_t_4 = 0;
  7883. /* "_yaml.pyx":572
  7884. * if event.data.document_start.tag_directives.start != NULL:
  7885. * tags = {}
  7886. * tag_directive = event.data.document_start.tag_directives.start # <<<<<<<<<<<<<<
  7887. * while tag_directive != event.data.document_start.tag_directives.end:
  7888. * handle = PyUnicode_FromString(tag_directive.handle)
  7889. */
  7890. __pyx_t_7 = __pyx_v_event->data.document_start.tag_directives.start;
  7891. __pyx_v_tag_directive = __pyx_t_7;
  7892. /* "_yaml.pyx":573
  7893. * tags = {}
  7894. * tag_directive = event.data.document_start.tag_directives.start
  7895. * while tag_directive != event.data.document_start.tag_directives.end: # <<<<<<<<<<<<<<
  7896. * handle = PyUnicode_FromString(tag_directive.handle)
  7897. * prefix = PyUnicode_FromString(tag_directive.prefix)
  7898. */
  7899. while (1) {
  7900. __pyx_t_5 = ((__pyx_v_tag_directive != __pyx_v_event->data.document_start.tag_directives.end) != 0);
  7901. if (!__pyx_t_5) break;
  7902. /* "_yaml.pyx":574
  7903. * tag_directive = event.data.document_start.tag_directives.start
  7904. * while tag_directive != event.data.document_start.tag_directives.end:
  7905. * handle = PyUnicode_FromString(tag_directive.handle) # <<<<<<<<<<<<<<
  7906. * prefix = PyUnicode_FromString(tag_directive.prefix)
  7907. * tags[handle] = prefix
  7908. */
  7909. __pyx_t_4 = PyUnicode_FromString(__pyx_v_tag_directive->handle); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 574, __pyx_L1_error)
  7910. __Pyx_GOTREF(__pyx_t_4);
  7911. __Pyx_XDECREF_SET(__pyx_v_handle, __pyx_t_4);
  7912. __pyx_t_4 = 0;
  7913. /* "_yaml.pyx":575
  7914. * while tag_directive != event.data.document_start.tag_directives.end:
  7915. * handle = PyUnicode_FromString(tag_directive.handle)
  7916. * prefix = PyUnicode_FromString(tag_directive.prefix) # <<<<<<<<<<<<<<
  7917. * tags[handle] = prefix
  7918. * tag_directive = tag_directive+1
  7919. */
  7920. __pyx_t_4 = PyUnicode_FromString(__pyx_v_tag_directive->prefix); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 575, __pyx_L1_error)
  7921. __Pyx_GOTREF(__pyx_t_4);
  7922. __Pyx_XDECREF_SET(__pyx_v_prefix, __pyx_t_4);
  7923. __pyx_t_4 = 0;
  7924. /* "_yaml.pyx":576
  7925. * handle = PyUnicode_FromString(tag_directive.handle)
  7926. * prefix = PyUnicode_FromString(tag_directive.prefix)
  7927. * tags[handle] = prefix # <<<<<<<<<<<<<<
  7928. * tag_directive = tag_directive+1
  7929. * return DocumentStartEvent(start_mark, end_mark,
  7930. */
  7931. if (unlikely(PyDict_SetItem(__pyx_v_tags, __pyx_v_handle, __pyx_v_prefix) < 0)) __PYX_ERR(0, 576, __pyx_L1_error)
  7932. /* "_yaml.pyx":577
  7933. * prefix = PyUnicode_FromString(tag_directive.prefix)
  7934. * tags[handle] = prefix
  7935. * tag_directive = tag_directive+1 # <<<<<<<<<<<<<<
  7936. * return DocumentStartEvent(start_mark, end_mark,
  7937. * explicit, version, tags)
  7938. */
  7939. __pyx_v_tag_directive = (__pyx_v_tag_directive + 1);
  7940. }
  7941. /* "_yaml.pyx":570
  7942. * event.data.document_start.version_directive.minor)
  7943. * tags = None
  7944. * if event.data.document_start.tag_directives.start != NULL: # <<<<<<<<<<<<<<
  7945. * tags = {}
  7946. * tag_directive = event.data.document_start.tag_directives.start
  7947. */
  7948. }
  7949. /* "_yaml.pyx":578
  7950. * tags[handle] = prefix
  7951. * tag_directive = tag_directive+1
  7952. * return DocumentStartEvent(start_mark, end_mark, # <<<<<<<<<<<<<<
  7953. * explicit, version, tags)
  7954. * elif event.type == YAML_DOCUMENT_END_EVENT:
  7955. */
  7956. __Pyx_XDECREF(__pyx_r);
  7957. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_DocumentStartEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 578, __pyx_L1_error)
  7958. __Pyx_GOTREF(__pyx_t_1);
  7959. /* "_yaml.pyx":579
  7960. * tag_directive = tag_directive+1
  7961. * return DocumentStartEvent(start_mark, end_mark,
  7962. * explicit, version, tags) # <<<<<<<<<<<<<<
  7963. * elif event.type == YAML_DOCUMENT_END_EVENT:
  7964. * explicit = False
  7965. */
  7966. __pyx_t_2 = __Pyx_PyBool_FromLong(__pyx_v_explicit); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 579, __pyx_L1_error)
  7967. __Pyx_GOTREF(__pyx_t_2);
  7968. __pyx_t_3 = NULL;
  7969. __pyx_t_6 = 0;
  7970. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  7971. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  7972. if (likely(__pyx_t_3)) {
  7973. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  7974. __Pyx_INCREF(__pyx_t_3);
  7975. __Pyx_INCREF(function);
  7976. __Pyx_DECREF_SET(__pyx_t_1, function);
  7977. __pyx_t_6 = 1;
  7978. }
  7979. }
  7980. #if CYTHON_FAST_PYCALL
  7981. if (PyFunction_Check(__pyx_t_1)) {
  7982. PyObject *__pyx_temp[6] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_t_2, __pyx_v_version, __pyx_v_tags};
  7983. __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 5+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 578, __pyx_L1_error)
  7984. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  7985. __Pyx_GOTREF(__pyx_t_4);
  7986. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  7987. } else
  7988. #endif
  7989. #if CYTHON_FAST_PYCCALL
  7990. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  7991. PyObject *__pyx_temp[6] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_t_2, __pyx_v_version, __pyx_v_tags};
  7992. __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 5+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 578, __pyx_L1_error)
  7993. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  7994. __Pyx_GOTREF(__pyx_t_4);
  7995. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  7996. } else
  7997. #endif
  7998. {
  7999. __pyx_t_8 = PyTuple_New(5+__pyx_t_6); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 578, __pyx_L1_error)
  8000. __Pyx_GOTREF(__pyx_t_8);
  8001. if (__pyx_t_3) {
  8002. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_3); __pyx_t_3 = NULL;
  8003. }
  8004. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  8005. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  8006. PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  8007. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  8008. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  8009. PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  8010. __Pyx_GIVEREF(__pyx_t_2);
  8011. PyTuple_SET_ITEM(__pyx_t_8, 2+__pyx_t_6, __pyx_t_2);
  8012. __Pyx_INCREF(__pyx_v_version);
  8013. __Pyx_GIVEREF(__pyx_v_version);
  8014. PyTuple_SET_ITEM(__pyx_t_8, 3+__pyx_t_6, __pyx_v_version);
  8015. __Pyx_INCREF(__pyx_v_tags);
  8016. __Pyx_GIVEREF(__pyx_v_tags);
  8017. PyTuple_SET_ITEM(__pyx_t_8, 4+__pyx_t_6, __pyx_v_tags);
  8018. __pyx_t_2 = 0;
  8019. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_8, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 578, __pyx_L1_error)
  8020. __Pyx_GOTREF(__pyx_t_4);
  8021. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  8022. }
  8023. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  8024. __pyx_r = __pyx_t_4;
  8025. __pyx_t_4 = 0;
  8026. goto __pyx_L0;
  8027. /* "_yaml.pyx":561
  8028. * elif event.type == YAML_STREAM_END_EVENT:
  8029. * return StreamEndEvent(start_mark, end_mark)
  8030. * elif event.type == YAML_DOCUMENT_START_EVENT: # <<<<<<<<<<<<<<
  8031. * explicit = False
  8032. * if event.data.document_start.implicit == 0:
  8033. */
  8034. break;
  8035. case YAML_DOCUMENT_END_EVENT:
  8036. /* "_yaml.pyx":581
  8037. * explicit, version, tags)
  8038. * elif event.type == YAML_DOCUMENT_END_EVENT:
  8039. * explicit = False # <<<<<<<<<<<<<<
  8040. * if event.data.document_end.implicit == 0:
  8041. * explicit = True
  8042. */
  8043. __pyx_v_explicit = 0;
  8044. /* "_yaml.pyx":582
  8045. * elif event.type == YAML_DOCUMENT_END_EVENT:
  8046. * explicit = False
  8047. * if event.data.document_end.implicit == 0: # <<<<<<<<<<<<<<
  8048. * explicit = True
  8049. * return DocumentEndEvent(start_mark, end_mark, explicit)
  8050. */
  8051. __pyx_t_5 = ((__pyx_v_event->data.document_end.implicit == 0) != 0);
  8052. if (__pyx_t_5) {
  8053. /* "_yaml.pyx":583
  8054. * explicit = False
  8055. * if event.data.document_end.implicit == 0:
  8056. * explicit = True # <<<<<<<<<<<<<<
  8057. * return DocumentEndEvent(start_mark, end_mark, explicit)
  8058. * elif event.type == YAML_ALIAS_EVENT:
  8059. */
  8060. __pyx_v_explicit = 1;
  8061. /* "_yaml.pyx":582
  8062. * elif event.type == YAML_DOCUMENT_END_EVENT:
  8063. * explicit = False
  8064. * if event.data.document_end.implicit == 0: # <<<<<<<<<<<<<<
  8065. * explicit = True
  8066. * return DocumentEndEvent(start_mark, end_mark, explicit)
  8067. */
  8068. }
  8069. /* "_yaml.pyx":584
  8070. * if event.data.document_end.implicit == 0:
  8071. * explicit = True
  8072. * return DocumentEndEvent(start_mark, end_mark, explicit) # <<<<<<<<<<<<<<
  8073. * elif event.type == YAML_ALIAS_EVENT:
  8074. * anchor = PyUnicode_FromString(event.data.alias.anchor)
  8075. */
  8076. __Pyx_XDECREF(__pyx_r);
  8077. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_DocumentEndEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 584, __pyx_L1_error)
  8078. __Pyx_GOTREF(__pyx_t_1);
  8079. __pyx_t_8 = __Pyx_PyBool_FromLong(__pyx_v_explicit); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 584, __pyx_L1_error)
  8080. __Pyx_GOTREF(__pyx_t_8);
  8081. __pyx_t_2 = NULL;
  8082. __pyx_t_6 = 0;
  8083. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  8084. __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_1);
  8085. if (likely(__pyx_t_2)) {
  8086. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  8087. __Pyx_INCREF(__pyx_t_2);
  8088. __Pyx_INCREF(function);
  8089. __Pyx_DECREF_SET(__pyx_t_1, function);
  8090. __pyx_t_6 = 1;
  8091. }
  8092. }
  8093. #if CYTHON_FAST_PYCALL
  8094. if (PyFunction_Check(__pyx_t_1)) {
  8095. PyObject *__pyx_temp[4] = {__pyx_t_2, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_t_8};
  8096. __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 584, __pyx_L1_error)
  8097. __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
  8098. __Pyx_GOTREF(__pyx_t_4);
  8099. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  8100. } else
  8101. #endif
  8102. #if CYTHON_FAST_PYCCALL
  8103. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  8104. PyObject *__pyx_temp[4] = {__pyx_t_2, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_t_8};
  8105. __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 584, __pyx_L1_error)
  8106. __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
  8107. __Pyx_GOTREF(__pyx_t_4);
  8108. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  8109. } else
  8110. #endif
  8111. {
  8112. __pyx_t_3 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 584, __pyx_L1_error)
  8113. __Pyx_GOTREF(__pyx_t_3);
  8114. if (__pyx_t_2) {
  8115. __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); __pyx_t_2 = NULL;
  8116. }
  8117. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  8118. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  8119. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  8120. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  8121. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  8122. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  8123. __Pyx_GIVEREF(__pyx_t_8);
  8124. PyTuple_SET_ITEM(__pyx_t_3, 2+__pyx_t_6, __pyx_t_8);
  8125. __pyx_t_8 = 0;
  8126. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 584, __pyx_L1_error)
  8127. __Pyx_GOTREF(__pyx_t_4);
  8128. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  8129. }
  8130. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  8131. __pyx_r = __pyx_t_4;
  8132. __pyx_t_4 = 0;
  8133. goto __pyx_L0;
  8134. /* "_yaml.pyx":580
  8135. * return DocumentStartEvent(start_mark, end_mark,
  8136. * explicit, version, tags)
  8137. * elif event.type == YAML_DOCUMENT_END_EVENT: # <<<<<<<<<<<<<<
  8138. * explicit = False
  8139. * if event.data.document_end.implicit == 0:
  8140. */
  8141. break;
  8142. case YAML_ALIAS_EVENT:
  8143. /* "_yaml.pyx":586
  8144. * return DocumentEndEvent(start_mark, end_mark, explicit)
  8145. * elif event.type == YAML_ALIAS_EVENT:
  8146. * anchor = PyUnicode_FromString(event.data.alias.anchor) # <<<<<<<<<<<<<<
  8147. * return AliasEvent(anchor, start_mark, end_mark)
  8148. * elif event.type == YAML_SCALAR_EVENT:
  8149. */
  8150. __pyx_t_4 = PyUnicode_FromString(__pyx_v_event->data.alias.anchor); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 586, __pyx_L1_error)
  8151. __Pyx_GOTREF(__pyx_t_4);
  8152. __pyx_v_anchor = __pyx_t_4;
  8153. __pyx_t_4 = 0;
  8154. /* "_yaml.pyx":587
  8155. * elif event.type == YAML_ALIAS_EVENT:
  8156. * anchor = PyUnicode_FromString(event.data.alias.anchor)
  8157. * return AliasEvent(anchor, start_mark, end_mark) # <<<<<<<<<<<<<<
  8158. * elif event.type == YAML_SCALAR_EVENT:
  8159. * anchor = None
  8160. */
  8161. __Pyx_XDECREF(__pyx_r);
  8162. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_AliasEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 587, __pyx_L1_error)
  8163. __Pyx_GOTREF(__pyx_t_1);
  8164. __pyx_t_3 = NULL;
  8165. __pyx_t_6 = 0;
  8166. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  8167. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  8168. if (likely(__pyx_t_3)) {
  8169. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  8170. __Pyx_INCREF(__pyx_t_3);
  8171. __Pyx_INCREF(function);
  8172. __Pyx_DECREF_SET(__pyx_t_1, function);
  8173. __pyx_t_6 = 1;
  8174. }
  8175. }
  8176. #if CYTHON_FAST_PYCALL
  8177. if (PyFunction_Check(__pyx_t_1)) {
  8178. PyObject *__pyx_temp[4] = {__pyx_t_3, __pyx_v_anchor, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  8179. __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 587, __pyx_L1_error)
  8180. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  8181. __Pyx_GOTREF(__pyx_t_4);
  8182. } else
  8183. #endif
  8184. #if CYTHON_FAST_PYCCALL
  8185. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  8186. PyObject *__pyx_temp[4] = {__pyx_t_3, __pyx_v_anchor, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  8187. __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 3+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 587, __pyx_L1_error)
  8188. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  8189. __Pyx_GOTREF(__pyx_t_4);
  8190. } else
  8191. #endif
  8192. {
  8193. __pyx_t_8 = PyTuple_New(3+__pyx_t_6); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 587, __pyx_L1_error)
  8194. __Pyx_GOTREF(__pyx_t_8);
  8195. if (__pyx_t_3) {
  8196. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_3); __pyx_t_3 = NULL;
  8197. }
  8198. __Pyx_INCREF(__pyx_v_anchor);
  8199. __Pyx_GIVEREF(__pyx_v_anchor);
  8200. PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_6, __pyx_v_anchor);
  8201. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  8202. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  8203. PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  8204. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  8205. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  8206. PyTuple_SET_ITEM(__pyx_t_8, 2+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  8207. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_8, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 587, __pyx_L1_error)
  8208. __Pyx_GOTREF(__pyx_t_4);
  8209. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  8210. }
  8211. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  8212. __pyx_r = __pyx_t_4;
  8213. __pyx_t_4 = 0;
  8214. goto __pyx_L0;
  8215. /* "_yaml.pyx":585
  8216. * explicit = True
  8217. * return DocumentEndEvent(start_mark, end_mark, explicit)
  8218. * elif event.type == YAML_ALIAS_EVENT: # <<<<<<<<<<<<<<
  8219. * anchor = PyUnicode_FromString(event.data.alias.anchor)
  8220. * return AliasEvent(anchor, start_mark, end_mark)
  8221. */
  8222. break;
  8223. case YAML_SCALAR_EVENT:
  8224. /* "_yaml.pyx":589
  8225. * return AliasEvent(anchor, start_mark, end_mark)
  8226. * elif event.type == YAML_SCALAR_EVENT:
  8227. * anchor = None # <<<<<<<<<<<<<<
  8228. * if event.data.scalar.anchor != NULL:
  8229. * anchor = PyUnicode_FromString(event.data.scalar.anchor)
  8230. */
  8231. __Pyx_INCREF(Py_None);
  8232. __pyx_v_anchor = Py_None;
  8233. /* "_yaml.pyx":590
  8234. * elif event.type == YAML_SCALAR_EVENT:
  8235. * anchor = None
  8236. * if event.data.scalar.anchor != NULL: # <<<<<<<<<<<<<<
  8237. * anchor = PyUnicode_FromString(event.data.scalar.anchor)
  8238. * tag = None
  8239. */
  8240. __pyx_t_5 = ((__pyx_v_event->data.scalar.anchor != NULL) != 0);
  8241. if (__pyx_t_5) {
  8242. /* "_yaml.pyx":591
  8243. * anchor = None
  8244. * if event.data.scalar.anchor != NULL:
  8245. * anchor = PyUnicode_FromString(event.data.scalar.anchor) # <<<<<<<<<<<<<<
  8246. * tag = None
  8247. * if event.data.scalar.tag != NULL:
  8248. */
  8249. __pyx_t_4 = PyUnicode_FromString(__pyx_v_event->data.scalar.anchor); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 591, __pyx_L1_error)
  8250. __Pyx_GOTREF(__pyx_t_4);
  8251. __Pyx_DECREF_SET(__pyx_v_anchor, __pyx_t_4);
  8252. __pyx_t_4 = 0;
  8253. /* "_yaml.pyx":590
  8254. * elif event.type == YAML_SCALAR_EVENT:
  8255. * anchor = None
  8256. * if event.data.scalar.anchor != NULL: # <<<<<<<<<<<<<<
  8257. * anchor = PyUnicode_FromString(event.data.scalar.anchor)
  8258. * tag = None
  8259. */
  8260. }
  8261. /* "_yaml.pyx":592
  8262. * if event.data.scalar.anchor != NULL:
  8263. * anchor = PyUnicode_FromString(event.data.scalar.anchor)
  8264. * tag = None # <<<<<<<<<<<<<<
  8265. * if event.data.scalar.tag != NULL:
  8266. * tag = PyUnicode_FromString(event.data.scalar.tag)
  8267. */
  8268. __Pyx_INCREF(Py_None);
  8269. __pyx_v_tag = Py_None;
  8270. /* "_yaml.pyx":593
  8271. * anchor = PyUnicode_FromString(event.data.scalar.anchor)
  8272. * tag = None
  8273. * if event.data.scalar.tag != NULL: # <<<<<<<<<<<<<<
  8274. * tag = PyUnicode_FromString(event.data.scalar.tag)
  8275. * value = PyUnicode_DecodeUTF8(event.data.scalar.value,
  8276. */
  8277. __pyx_t_5 = ((__pyx_v_event->data.scalar.tag != NULL) != 0);
  8278. if (__pyx_t_5) {
  8279. /* "_yaml.pyx":594
  8280. * tag = None
  8281. * if event.data.scalar.tag != NULL:
  8282. * tag = PyUnicode_FromString(event.data.scalar.tag) # <<<<<<<<<<<<<<
  8283. * value = PyUnicode_DecodeUTF8(event.data.scalar.value,
  8284. * event.data.scalar.length, 'strict')
  8285. */
  8286. __pyx_t_4 = PyUnicode_FromString(__pyx_v_event->data.scalar.tag); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 594, __pyx_L1_error)
  8287. __Pyx_GOTREF(__pyx_t_4);
  8288. __Pyx_DECREF_SET(__pyx_v_tag, __pyx_t_4);
  8289. __pyx_t_4 = 0;
  8290. /* "_yaml.pyx":593
  8291. * anchor = PyUnicode_FromString(event.data.scalar.anchor)
  8292. * tag = None
  8293. * if event.data.scalar.tag != NULL: # <<<<<<<<<<<<<<
  8294. * tag = PyUnicode_FromString(event.data.scalar.tag)
  8295. * value = PyUnicode_DecodeUTF8(event.data.scalar.value,
  8296. */
  8297. }
  8298. /* "_yaml.pyx":595
  8299. * if event.data.scalar.tag != NULL:
  8300. * tag = PyUnicode_FromString(event.data.scalar.tag)
  8301. * value = PyUnicode_DecodeUTF8(event.data.scalar.value, # <<<<<<<<<<<<<<
  8302. * event.data.scalar.length, 'strict')
  8303. * plain_implicit = False
  8304. */
  8305. __pyx_t_4 = PyUnicode_DecodeUTF8(__pyx_v_event->data.scalar.value, __pyx_v_event->data.scalar.length, ((char *)"strict")); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 595, __pyx_L1_error)
  8306. __Pyx_GOTREF(__pyx_t_4);
  8307. __pyx_v_value = __pyx_t_4;
  8308. __pyx_t_4 = 0;
  8309. /* "_yaml.pyx":597
  8310. * value = PyUnicode_DecodeUTF8(event.data.scalar.value,
  8311. * event.data.scalar.length, 'strict')
  8312. * plain_implicit = False # <<<<<<<<<<<<<<
  8313. * if event.data.scalar.plain_implicit == 1:
  8314. * plain_implicit = True
  8315. */
  8316. __pyx_v_plain_implicit = 0;
  8317. /* "_yaml.pyx":598
  8318. * event.data.scalar.length, 'strict')
  8319. * plain_implicit = False
  8320. * if event.data.scalar.plain_implicit == 1: # <<<<<<<<<<<<<<
  8321. * plain_implicit = True
  8322. * quoted_implicit = False
  8323. */
  8324. __pyx_t_5 = ((__pyx_v_event->data.scalar.plain_implicit == 1) != 0);
  8325. if (__pyx_t_5) {
  8326. /* "_yaml.pyx":599
  8327. * plain_implicit = False
  8328. * if event.data.scalar.plain_implicit == 1:
  8329. * plain_implicit = True # <<<<<<<<<<<<<<
  8330. * quoted_implicit = False
  8331. * if event.data.scalar.quoted_implicit == 1:
  8332. */
  8333. __pyx_v_plain_implicit = 1;
  8334. /* "_yaml.pyx":598
  8335. * event.data.scalar.length, 'strict')
  8336. * plain_implicit = False
  8337. * if event.data.scalar.plain_implicit == 1: # <<<<<<<<<<<<<<
  8338. * plain_implicit = True
  8339. * quoted_implicit = False
  8340. */
  8341. }
  8342. /* "_yaml.pyx":600
  8343. * if event.data.scalar.plain_implicit == 1:
  8344. * plain_implicit = True
  8345. * quoted_implicit = False # <<<<<<<<<<<<<<
  8346. * if event.data.scalar.quoted_implicit == 1:
  8347. * quoted_implicit = True
  8348. */
  8349. __pyx_v_quoted_implicit = 0;
  8350. /* "_yaml.pyx":601
  8351. * plain_implicit = True
  8352. * quoted_implicit = False
  8353. * if event.data.scalar.quoted_implicit == 1: # <<<<<<<<<<<<<<
  8354. * quoted_implicit = True
  8355. * style = None
  8356. */
  8357. __pyx_t_5 = ((__pyx_v_event->data.scalar.quoted_implicit == 1) != 0);
  8358. if (__pyx_t_5) {
  8359. /* "_yaml.pyx":602
  8360. * quoted_implicit = False
  8361. * if event.data.scalar.quoted_implicit == 1:
  8362. * quoted_implicit = True # <<<<<<<<<<<<<<
  8363. * style = None
  8364. * if event.data.scalar.style == YAML_PLAIN_SCALAR_STYLE:
  8365. */
  8366. __pyx_v_quoted_implicit = 1;
  8367. /* "_yaml.pyx":601
  8368. * plain_implicit = True
  8369. * quoted_implicit = False
  8370. * if event.data.scalar.quoted_implicit == 1: # <<<<<<<<<<<<<<
  8371. * quoted_implicit = True
  8372. * style = None
  8373. */
  8374. }
  8375. /* "_yaml.pyx":603
  8376. * if event.data.scalar.quoted_implicit == 1:
  8377. * quoted_implicit = True
  8378. * style = None # <<<<<<<<<<<<<<
  8379. * if event.data.scalar.style == YAML_PLAIN_SCALAR_STYLE:
  8380. * style = u''
  8381. */
  8382. __Pyx_INCREF(Py_None);
  8383. __pyx_v_style = ((PyObject*)Py_None);
  8384. /* "_yaml.pyx":604
  8385. * quoted_implicit = True
  8386. * style = None
  8387. * if event.data.scalar.style == YAML_PLAIN_SCALAR_STYLE: # <<<<<<<<<<<<<<
  8388. * style = u''
  8389. * elif event.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE:
  8390. */
  8391. switch (__pyx_v_event->data.scalar.style) {
  8392. case YAML_PLAIN_SCALAR_STYLE:
  8393. /* "_yaml.pyx":605
  8394. * style = None
  8395. * if event.data.scalar.style == YAML_PLAIN_SCALAR_STYLE:
  8396. * style = u'' # <<<<<<<<<<<<<<
  8397. * elif event.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE:
  8398. * style = u'\''
  8399. */
  8400. __Pyx_INCREF(__pyx_kp_u__6);
  8401. __Pyx_DECREF_SET(__pyx_v_style, __pyx_kp_u__6);
  8402. /* "_yaml.pyx":604
  8403. * quoted_implicit = True
  8404. * style = None
  8405. * if event.data.scalar.style == YAML_PLAIN_SCALAR_STYLE: # <<<<<<<<<<<<<<
  8406. * style = u''
  8407. * elif event.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE:
  8408. */
  8409. break;
  8410. case YAML_SINGLE_QUOTED_SCALAR_STYLE:
  8411. /* "_yaml.pyx":607
  8412. * style = u''
  8413. * elif event.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE:
  8414. * style = u'\'' # <<<<<<<<<<<<<<
  8415. * elif event.data.scalar.style == YAML_DOUBLE_QUOTED_SCALAR_STYLE:
  8416. * style = u'"'
  8417. */
  8418. __Pyx_INCREF(__pyx_kp_u__7);
  8419. __Pyx_DECREF_SET(__pyx_v_style, __pyx_kp_u__7);
  8420. /* "_yaml.pyx":606
  8421. * if event.data.scalar.style == YAML_PLAIN_SCALAR_STYLE:
  8422. * style = u''
  8423. * elif event.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE: # <<<<<<<<<<<<<<
  8424. * style = u'\''
  8425. * elif event.data.scalar.style == YAML_DOUBLE_QUOTED_SCALAR_STYLE:
  8426. */
  8427. break;
  8428. case YAML_DOUBLE_QUOTED_SCALAR_STYLE:
  8429. /* "_yaml.pyx":609
  8430. * style = u'\''
  8431. * elif event.data.scalar.style == YAML_DOUBLE_QUOTED_SCALAR_STYLE:
  8432. * style = u'"' # <<<<<<<<<<<<<<
  8433. * elif event.data.scalar.style == YAML_LITERAL_SCALAR_STYLE:
  8434. * style = u'|'
  8435. */
  8436. __Pyx_INCREF(__pyx_kp_u__8);
  8437. __Pyx_DECREF_SET(__pyx_v_style, __pyx_kp_u__8);
  8438. /* "_yaml.pyx":608
  8439. * elif event.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE:
  8440. * style = u'\''
  8441. * elif event.data.scalar.style == YAML_DOUBLE_QUOTED_SCALAR_STYLE: # <<<<<<<<<<<<<<
  8442. * style = u'"'
  8443. * elif event.data.scalar.style == YAML_LITERAL_SCALAR_STYLE:
  8444. */
  8445. break;
  8446. case YAML_LITERAL_SCALAR_STYLE:
  8447. /* "_yaml.pyx":611
  8448. * style = u'"'
  8449. * elif event.data.scalar.style == YAML_LITERAL_SCALAR_STYLE:
  8450. * style = u'|' # <<<<<<<<<<<<<<
  8451. * elif event.data.scalar.style == YAML_FOLDED_SCALAR_STYLE:
  8452. * style = u'>'
  8453. */
  8454. __Pyx_INCREF(__pyx_kp_u__9);
  8455. __Pyx_DECREF_SET(__pyx_v_style, __pyx_kp_u__9);
  8456. /* "_yaml.pyx":610
  8457. * elif event.data.scalar.style == YAML_DOUBLE_QUOTED_SCALAR_STYLE:
  8458. * style = u'"'
  8459. * elif event.data.scalar.style == YAML_LITERAL_SCALAR_STYLE: # <<<<<<<<<<<<<<
  8460. * style = u'|'
  8461. * elif event.data.scalar.style == YAML_FOLDED_SCALAR_STYLE:
  8462. */
  8463. break;
  8464. case YAML_FOLDED_SCALAR_STYLE:
  8465. /* "_yaml.pyx":613
  8466. * style = u'|'
  8467. * elif event.data.scalar.style == YAML_FOLDED_SCALAR_STYLE:
  8468. * style = u'>' # <<<<<<<<<<<<<<
  8469. * return ScalarEvent(anchor, tag,
  8470. * (plain_implicit, quoted_implicit),
  8471. */
  8472. __Pyx_INCREF(__pyx_kp_u__10);
  8473. __Pyx_DECREF_SET(__pyx_v_style, __pyx_kp_u__10);
  8474. /* "_yaml.pyx":612
  8475. * elif event.data.scalar.style == YAML_LITERAL_SCALAR_STYLE:
  8476. * style = u'|'
  8477. * elif event.data.scalar.style == YAML_FOLDED_SCALAR_STYLE: # <<<<<<<<<<<<<<
  8478. * style = u'>'
  8479. * return ScalarEvent(anchor, tag,
  8480. */
  8481. break;
  8482. default: break;
  8483. }
  8484. /* "_yaml.pyx":614
  8485. * elif event.data.scalar.style == YAML_FOLDED_SCALAR_STYLE:
  8486. * style = u'>'
  8487. * return ScalarEvent(anchor, tag, # <<<<<<<<<<<<<<
  8488. * (plain_implicit, quoted_implicit),
  8489. * value, start_mark, end_mark, style)
  8490. */
  8491. __Pyx_XDECREF(__pyx_r);
  8492. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_ScalarEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 614, __pyx_L1_error)
  8493. __Pyx_GOTREF(__pyx_t_1);
  8494. /* "_yaml.pyx":615
  8495. * style = u'>'
  8496. * return ScalarEvent(anchor, tag,
  8497. * (plain_implicit, quoted_implicit), # <<<<<<<<<<<<<<
  8498. * value, start_mark, end_mark, style)
  8499. * elif event.type == YAML_SEQUENCE_START_EVENT:
  8500. */
  8501. __pyx_t_8 = __Pyx_PyBool_FromLong(__pyx_v_plain_implicit); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 615, __pyx_L1_error)
  8502. __Pyx_GOTREF(__pyx_t_8);
  8503. __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_v_quoted_implicit); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 615, __pyx_L1_error)
  8504. __Pyx_GOTREF(__pyx_t_3);
  8505. __pyx_t_2 = PyTuple_New(2); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 615, __pyx_L1_error)
  8506. __Pyx_GOTREF(__pyx_t_2);
  8507. __Pyx_GIVEREF(__pyx_t_8);
  8508. PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_8);
  8509. __Pyx_GIVEREF(__pyx_t_3);
  8510. PyTuple_SET_ITEM(__pyx_t_2, 1, __pyx_t_3);
  8511. __pyx_t_8 = 0;
  8512. __pyx_t_3 = 0;
  8513. /* "_yaml.pyx":616
  8514. * return ScalarEvent(anchor, tag,
  8515. * (plain_implicit, quoted_implicit),
  8516. * value, start_mark, end_mark, style) # <<<<<<<<<<<<<<
  8517. * elif event.type == YAML_SEQUENCE_START_EVENT:
  8518. * anchor = None
  8519. */
  8520. __pyx_t_3 = NULL;
  8521. __pyx_t_6 = 0;
  8522. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  8523. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  8524. if (likely(__pyx_t_3)) {
  8525. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  8526. __Pyx_INCREF(__pyx_t_3);
  8527. __Pyx_INCREF(function);
  8528. __Pyx_DECREF_SET(__pyx_t_1, function);
  8529. __pyx_t_6 = 1;
  8530. }
  8531. }
  8532. #if CYTHON_FAST_PYCALL
  8533. if (PyFunction_Check(__pyx_t_1)) {
  8534. PyObject *__pyx_temp[8] = {__pyx_t_3, __pyx_v_anchor, __pyx_v_tag, __pyx_t_2, __pyx_v_value, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_v_style};
  8535. __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 7+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 614, __pyx_L1_error)
  8536. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  8537. __Pyx_GOTREF(__pyx_t_4);
  8538. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  8539. } else
  8540. #endif
  8541. #if CYTHON_FAST_PYCCALL
  8542. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  8543. PyObject *__pyx_temp[8] = {__pyx_t_3, __pyx_v_anchor, __pyx_v_tag, __pyx_t_2, __pyx_v_value, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_v_style};
  8544. __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 7+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 614, __pyx_L1_error)
  8545. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  8546. __Pyx_GOTREF(__pyx_t_4);
  8547. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  8548. } else
  8549. #endif
  8550. {
  8551. __pyx_t_8 = PyTuple_New(7+__pyx_t_6); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 614, __pyx_L1_error)
  8552. __Pyx_GOTREF(__pyx_t_8);
  8553. if (__pyx_t_3) {
  8554. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_3); __pyx_t_3 = NULL;
  8555. }
  8556. __Pyx_INCREF(__pyx_v_anchor);
  8557. __Pyx_GIVEREF(__pyx_v_anchor);
  8558. PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_6, __pyx_v_anchor);
  8559. __Pyx_INCREF(__pyx_v_tag);
  8560. __Pyx_GIVEREF(__pyx_v_tag);
  8561. PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_6, __pyx_v_tag);
  8562. __Pyx_GIVEREF(__pyx_t_2);
  8563. PyTuple_SET_ITEM(__pyx_t_8, 2+__pyx_t_6, __pyx_t_2);
  8564. __Pyx_INCREF(__pyx_v_value);
  8565. __Pyx_GIVEREF(__pyx_v_value);
  8566. PyTuple_SET_ITEM(__pyx_t_8, 3+__pyx_t_6, __pyx_v_value);
  8567. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  8568. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  8569. PyTuple_SET_ITEM(__pyx_t_8, 4+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  8570. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  8571. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  8572. PyTuple_SET_ITEM(__pyx_t_8, 5+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  8573. __Pyx_INCREF(__pyx_v_style);
  8574. __Pyx_GIVEREF(__pyx_v_style);
  8575. PyTuple_SET_ITEM(__pyx_t_8, 6+__pyx_t_6, __pyx_v_style);
  8576. __pyx_t_2 = 0;
  8577. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_8, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 614, __pyx_L1_error)
  8578. __Pyx_GOTREF(__pyx_t_4);
  8579. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  8580. }
  8581. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  8582. __pyx_r = __pyx_t_4;
  8583. __pyx_t_4 = 0;
  8584. goto __pyx_L0;
  8585. /* "_yaml.pyx":588
  8586. * anchor = PyUnicode_FromString(event.data.alias.anchor)
  8587. * return AliasEvent(anchor, start_mark, end_mark)
  8588. * elif event.type == YAML_SCALAR_EVENT: # <<<<<<<<<<<<<<
  8589. * anchor = None
  8590. * if event.data.scalar.anchor != NULL:
  8591. */
  8592. break;
  8593. case YAML_SEQUENCE_START_EVENT:
  8594. /* "_yaml.pyx":618
  8595. * value, start_mark, end_mark, style)
  8596. * elif event.type == YAML_SEQUENCE_START_EVENT:
  8597. * anchor = None # <<<<<<<<<<<<<<
  8598. * if event.data.sequence_start.anchor != NULL:
  8599. * anchor = PyUnicode_FromString(event.data.sequence_start.anchor)
  8600. */
  8601. __Pyx_INCREF(Py_None);
  8602. __pyx_v_anchor = Py_None;
  8603. /* "_yaml.pyx":619
  8604. * elif event.type == YAML_SEQUENCE_START_EVENT:
  8605. * anchor = None
  8606. * if event.data.sequence_start.anchor != NULL: # <<<<<<<<<<<<<<
  8607. * anchor = PyUnicode_FromString(event.data.sequence_start.anchor)
  8608. * tag = None
  8609. */
  8610. __pyx_t_5 = ((__pyx_v_event->data.sequence_start.anchor != NULL) != 0);
  8611. if (__pyx_t_5) {
  8612. /* "_yaml.pyx":620
  8613. * anchor = None
  8614. * if event.data.sequence_start.anchor != NULL:
  8615. * anchor = PyUnicode_FromString(event.data.sequence_start.anchor) # <<<<<<<<<<<<<<
  8616. * tag = None
  8617. * if event.data.sequence_start.tag != NULL:
  8618. */
  8619. __pyx_t_4 = PyUnicode_FromString(__pyx_v_event->data.sequence_start.anchor); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 620, __pyx_L1_error)
  8620. __Pyx_GOTREF(__pyx_t_4);
  8621. __Pyx_DECREF_SET(__pyx_v_anchor, __pyx_t_4);
  8622. __pyx_t_4 = 0;
  8623. /* "_yaml.pyx":619
  8624. * elif event.type == YAML_SEQUENCE_START_EVENT:
  8625. * anchor = None
  8626. * if event.data.sequence_start.anchor != NULL: # <<<<<<<<<<<<<<
  8627. * anchor = PyUnicode_FromString(event.data.sequence_start.anchor)
  8628. * tag = None
  8629. */
  8630. }
  8631. /* "_yaml.pyx":621
  8632. * if event.data.sequence_start.anchor != NULL:
  8633. * anchor = PyUnicode_FromString(event.data.sequence_start.anchor)
  8634. * tag = None # <<<<<<<<<<<<<<
  8635. * if event.data.sequence_start.tag != NULL:
  8636. * tag = PyUnicode_FromString(event.data.sequence_start.tag)
  8637. */
  8638. __Pyx_INCREF(Py_None);
  8639. __pyx_v_tag = Py_None;
  8640. /* "_yaml.pyx":622
  8641. * anchor = PyUnicode_FromString(event.data.sequence_start.anchor)
  8642. * tag = None
  8643. * if event.data.sequence_start.tag != NULL: # <<<<<<<<<<<<<<
  8644. * tag = PyUnicode_FromString(event.data.sequence_start.tag)
  8645. * implicit = False
  8646. */
  8647. __pyx_t_5 = ((__pyx_v_event->data.sequence_start.tag != NULL) != 0);
  8648. if (__pyx_t_5) {
  8649. /* "_yaml.pyx":623
  8650. * tag = None
  8651. * if event.data.sequence_start.tag != NULL:
  8652. * tag = PyUnicode_FromString(event.data.sequence_start.tag) # <<<<<<<<<<<<<<
  8653. * implicit = False
  8654. * if event.data.sequence_start.implicit == 1:
  8655. */
  8656. __pyx_t_4 = PyUnicode_FromString(__pyx_v_event->data.sequence_start.tag); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 623, __pyx_L1_error)
  8657. __Pyx_GOTREF(__pyx_t_4);
  8658. __Pyx_DECREF_SET(__pyx_v_tag, __pyx_t_4);
  8659. __pyx_t_4 = 0;
  8660. /* "_yaml.pyx":622
  8661. * anchor = PyUnicode_FromString(event.data.sequence_start.anchor)
  8662. * tag = None
  8663. * if event.data.sequence_start.tag != NULL: # <<<<<<<<<<<<<<
  8664. * tag = PyUnicode_FromString(event.data.sequence_start.tag)
  8665. * implicit = False
  8666. */
  8667. }
  8668. /* "_yaml.pyx":624
  8669. * if event.data.sequence_start.tag != NULL:
  8670. * tag = PyUnicode_FromString(event.data.sequence_start.tag)
  8671. * implicit = False # <<<<<<<<<<<<<<
  8672. * if event.data.sequence_start.implicit == 1:
  8673. * implicit = True
  8674. */
  8675. __pyx_v_implicit = 0;
  8676. /* "_yaml.pyx":625
  8677. * tag = PyUnicode_FromString(event.data.sequence_start.tag)
  8678. * implicit = False
  8679. * if event.data.sequence_start.implicit == 1: # <<<<<<<<<<<<<<
  8680. * implicit = True
  8681. * flow_style = None
  8682. */
  8683. __pyx_t_5 = ((__pyx_v_event->data.sequence_start.implicit == 1) != 0);
  8684. if (__pyx_t_5) {
  8685. /* "_yaml.pyx":626
  8686. * implicit = False
  8687. * if event.data.sequence_start.implicit == 1:
  8688. * implicit = True # <<<<<<<<<<<<<<
  8689. * flow_style = None
  8690. * if event.data.sequence_start.style == YAML_FLOW_SEQUENCE_STYLE:
  8691. */
  8692. __pyx_v_implicit = 1;
  8693. /* "_yaml.pyx":625
  8694. * tag = PyUnicode_FromString(event.data.sequence_start.tag)
  8695. * implicit = False
  8696. * if event.data.sequence_start.implicit == 1: # <<<<<<<<<<<<<<
  8697. * implicit = True
  8698. * flow_style = None
  8699. */
  8700. }
  8701. /* "_yaml.pyx":627
  8702. * if event.data.sequence_start.implicit == 1:
  8703. * implicit = True
  8704. * flow_style = None # <<<<<<<<<<<<<<
  8705. * if event.data.sequence_start.style == YAML_FLOW_SEQUENCE_STYLE:
  8706. * flow_style = True
  8707. */
  8708. __Pyx_INCREF(Py_None);
  8709. __pyx_v_flow_style = Py_None;
  8710. /* "_yaml.pyx":628
  8711. * implicit = True
  8712. * flow_style = None
  8713. * if event.data.sequence_start.style == YAML_FLOW_SEQUENCE_STYLE: # <<<<<<<<<<<<<<
  8714. * flow_style = True
  8715. * elif event.data.sequence_start.style == YAML_BLOCK_SEQUENCE_STYLE:
  8716. */
  8717. switch (__pyx_v_event->data.sequence_start.style) {
  8718. case YAML_FLOW_SEQUENCE_STYLE:
  8719. /* "_yaml.pyx":629
  8720. * flow_style = None
  8721. * if event.data.sequence_start.style == YAML_FLOW_SEQUENCE_STYLE:
  8722. * flow_style = True # <<<<<<<<<<<<<<
  8723. * elif event.data.sequence_start.style == YAML_BLOCK_SEQUENCE_STYLE:
  8724. * flow_style = False
  8725. */
  8726. __Pyx_INCREF(Py_True);
  8727. __Pyx_DECREF_SET(__pyx_v_flow_style, Py_True);
  8728. /* "_yaml.pyx":628
  8729. * implicit = True
  8730. * flow_style = None
  8731. * if event.data.sequence_start.style == YAML_FLOW_SEQUENCE_STYLE: # <<<<<<<<<<<<<<
  8732. * flow_style = True
  8733. * elif event.data.sequence_start.style == YAML_BLOCK_SEQUENCE_STYLE:
  8734. */
  8735. break;
  8736. case YAML_BLOCK_SEQUENCE_STYLE:
  8737. /* "_yaml.pyx":631
  8738. * flow_style = True
  8739. * elif event.data.sequence_start.style == YAML_BLOCK_SEQUENCE_STYLE:
  8740. * flow_style = False # <<<<<<<<<<<<<<
  8741. * return SequenceStartEvent(anchor, tag, implicit,
  8742. * start_mark, end_mark, flow_style)
  8743. */
  8744. __Pyx_INCREF(Py_False);
  8745. __Pyx_DECREF_SET(__pyx_v_flow_style, Py_False);
  8746. /* "_yaml.pyx":630
  8747. * if event.data.sequence_start.style == YAML_FLOW_SEQUENCE_STYLE:
  8748. * flow_style = True
  8749. * elif event.data.sequence_start.style == YAML_BLOCK_SEQUENCE_STYLE: # <<<<<<<<<<<<<<
  8750. * flow_style = False
  8751. * return SequenceStartEvent(anchor, tag, implicit,
  8752. */
  8753. break;
  8754. default: break;
  8755. }
  8756. /* "_yaml.pyx":632
  8757. * elif event.data.sequence_start.style == YAML_BLOCK_SEQUENCE_STYLE:
  8758. * flow_style = False
  8759. * return SequenceStartEvent(anchor, tag, implicit, # <<<<<<<<<<<<<<
  8760. * start_mark, end_mark, flow_style)
  8761. * elif event.type == YAML_MAPPING_START_EVENT:
  8762. */
  8763. __Pyx_XDECREF(__pyx_r);
  8764. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_SequenceStartEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 632, __pyx_L1_error)
  8765. __Pyx_GOTREF(__pyx_t_1);
  8766. __pyx_t_8 = __Pyx_PyBool_FromLong(__pyx_v_implicit); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 632, __pyx_L1_error)
  8767. __Pyx_GOTREF(__pyx_t_8);
  8768. /* "_yaml.pyx":633
  8769. * flow_style = False
  8770. * return SequenceStartEvent(anchor, tag, implicit,
  8771. * start_mark, end_mark, flow_style) # <<<<<<<<<<<<<<
  8772. * elif event.type == YAML_MAPPING_START_EVENT:
  8773. * anchor = None
  8774. */
  8775. __pyx_t_2 = NULL;
  8776. __pyx_t_6 = 0;
  8777. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  8778. __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_1);
  8779. if (likely(__pyx_t_2)) {
  8780. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  8781. __Pyx_INCREF(__pyx_t_2);
  8782. __Pyx_INCREF(function);
  8783. __Pyx_DECREF_SET(__pyx_t_1, function);
  8784. __pyx_t_6 = 1;
  8785. }
  8786. }
  8787. #if CYTHON_FAST_PYCALL
  8788. if (PyFunction_Check(__pyx_t_1)) {
  8789. PyObject *__pyx_temp[7] = {__pyx_t_2, __pyx_v_anchor, __pyx_v_tag, __pyx_t_8, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_v_flow_style};
  8790. __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 6+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 632, __pyx_L1_error)
  8791. __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
  8792. __Pyx_GOTREF(__pyx_t_4);
  8793. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  8794. } else
  8795. #endif
  8796. #if CYTHON_FAST_PYCCALL
  8797. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  8798. PyObject *__pyx_temp[7] = {__pyx_t_2, __pyx_v_anchor, __pyx_v_tag, __pyx_t_8, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_v_flow_style};
  8799. __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 6+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 632, __pyx_L1_error)
  8800. __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
  8801. __Pyx_GOTREF(__pyx_t_4);
  8802. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  8803. } else
  8804. #endif
  8805. {
  8806. __pyx_t_3 = PyTuple_New(6+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 632, __pyx_L1_error)
  8807. __Pyx_GOTREF(__pyx_t_3);
  8808. if (__pyx_t_2) {
  8809. __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); __pyx_t_2 = NULL;
  8810. }
  8811. __Pyx_INCREF(__pyx_v_anchor);
  8812. __Pyx_GIVEREF(__pyx_v_anchor);
  8813. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_6, __pyx_v_anchor);
  8814. __Pyx_INCREF(__pyx_v_tag);
  8815. __Pyx_GIVEREF(__pyx_v_tag);
  8816. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_6, __pyx_v_tag);
  8817. __Pyx_GIVEREF(__pyx_t_8);
  8818. PyTuple_SET_ITEM(__pyx_t_3, 2+__pyx_t_6, __pyx_t_8);
  8819. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  8820. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  8821. PyTuple_SET_ITEM(__pyx_t_3, 3+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  8822. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  8823. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  8824. PyTuple_SET_ITEM(__pyx_t_3, 4+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  8825. __Pyx_INCREF(__pyx_v_flow_style);
  8826. __Pyx_GIVEREF(__pyx_v_flow_style);
  8827. PyTuple_SET_ITEM(__pyx_t_3, 5+__pyx_t_6, __pyx_v_flow_style);
  8828. __pyx_t_8 = 0;
  8829. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 632, __pyx_L1_error)
  8830. __Pyx_GOTREF(__pyx_t_4);
  8831. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  8832. }
  8833. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  8834. __pyx_r = __pyx_t_4;
  8835. __pyx_t_4 = 0;
  8836. goto __pyx_L0;
  8837. /* "_yaml.pyx":617
  8838. * (plain_implicit, quoted_implicit),
  8839. * value, start_mark, end_mark, style)
  8840. * elif event.type == YAML_SEQUENCE_START_EVENT: # <<<<<<<<<<<<<<
  8841. * anchor = None
  8842. * if event.data.sequence_start.anchor != NULL:
  8843. */
  8844. break;
  8845. case YAML_MAPPING_START_EVENT:
  8846. /* "_yaml.pyx":635
  8847. * start_mark, end_mark, flow_style)
  8848. * elif event.type == YAML_MAPPING_START_EVENT:
  8849. * anchor = None # <<<<<<<<<<<<<<
  8850. * if event.data.mapping_start.anchor != NULL:
  8851. * anchor = PyUnicode_FromString(event.data.mapping_start.anchor)
  8852. */
  8853. __Pyx_INCREF(Py_None);
  8854. __pyx_v_anchor = Py_None;
  8855. /* "_yaml.pyx":636
  8856. * elif event.type == YAML_MAPPING_START_EVENT:
  8857. * anchor = None
  8858. * if event.data.mapping_start.anchor != NULL: # <<<<<<<<<<<<<<
  8859. * anchor = PyUnicode_FromString(event.data.mapping_start.anchor)
  8860. * tag = None
  8861. */
  8862. __pyx_t_5 = ((__pyx_v_event->data.mapping_start.anchor != NULL) != 0);
  8863. if (__pyx_t_5) {
  8864. /* "_yaml.pyx":637
  8865. * anchor = None
  8866. * if event.data.mapping_start.anchor != NULL:
  8867. * anchor = PyUnicode_FromString(event.data.mapping_start.anchor) # <<<<<<<<<<<<<<
  8868. * tag = None
  8869. * if event.data.mapping_start.tag != NULL:
  8870. */
  8871. __pyx_t_4 = PyUnicode_FromString(__pyx_v_event->data.mapping_start.anchor); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 637, __pyx_L1_error)
  8872. __Pyx_GOTREF(__pyx_t_4);
  8873. __Pyx_DECREF_SET(__pyx_v_anchor, __pyx_t_4);
  8874. __pyx_t_4 = 0;
  8875. /* "_yaml.pyx":636
  8876. * elif event.type == YAML_MAPPING_START_EVENT:
  8877. * anchor = None
  8878. * if event.data.mapping_start.anchor != NULL: # <<<<<<<<<<<<<<
  8879. * anchor = PyUnicode_FromString(event.data.mapping_start.anchor)
  8880. * tag = None
  8881. */
  8882. }
  8883. /* "_yaml.pyx":638
  8884. * if event.data.mapping_start.anchor != NULL:
  8885. * anchor = PyUnicode_FromString(event.data.mapping_start.anchor)
  8886. * tag = None # <<<<<<<<<<<<<<
  8887. * if event.data.mapping_start.tag != NULL:
  8888. * tag = PyUnicode_FromString(event.data.mapping_start.tag)
  8889. */
  8890. __Pyx_INCREF(Py_None);
  8891. __pyx_v_tag = Py_None;
  8892. /* "_yaml.pyx":639
  8893. * anchor = PyUnicode_FromString(event.data.mapping_start.anchor)
  8894. * tag = None
  8895. * if event.data.mapping_start.tag != NULL: # <<<<<<<<<<<<<<
  8896. * tag = PyUnicode_FromString(event.data.mapping_start.tag)
  8897. * implicit = False
  8898. */
  8899. __pyx_t_5 = ((__pyx_v_event->data.mapping_start.tag != NULL) != 0);
  8900. if (__pyx_t_5) {
  8901. /* "_yaml.pyx":640
  8902. * tag = None
  8903. * if event.data.mapping_start.tag != NULL:
  8904. * tag = PyUnicode_FromString(event.data.mapping_start.tag) # <<<<<<<<<<<<<<
  8905. * implicit = False
  8906. * if event.data.mapping_start.implicit == 1:
  8907. */
  8908. __pyx_t_4 = PyUnicode_FromString(__pyx_v_event->data.mapping_start.tag); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 640, __pyx_L1_error)
  8909. __Pyx_GOTREF(__pyx_t_4);
  8910. __Pyx_DECREF_SET(__pyx_v_tag, __pyx_t_4);
  8911. __pyx_t_4 = 0;
  8912. /* "_yaml.pyx":639
  8913. * anchor = PyUnicode_FromString(event.data.mapping_start.anchor)
  8914. * tag = None
  8915. * if event.data.mapping_start.tag != NULL: # <<<<<<<<<<<<<<
  8916. * tag = PyUnicode_FromString(event.data.mapping_start.tag)
  8917. * implicit = False
  8918. */
  8919. }
  8920. /* "_yaml.pyx":641
  8921. * if event.data.mapping_start.tag != NULL:
  8922. * tag = PyUnicode_FromString(event.data.mapping_start.tag)
  8923. * implicit = False # <<<<<<<<<<<<<<
  8924. * if event.data.mapping_start.implicit == 1:
  8925. * implicit = True
  8926. */
  8927. __pyx_v_implicit = 0;
  8928. /* "_yaml.pyx":642
  8929. * tag = PyUnicode_FromString(event.data.mapping_start.tag)
  8930. * implicit = False
  8931. * if event.data.mapping_start.implicit == 1: # <<<<<<<<<<<<<<
  8932. * implicit = True
  8933. * flow_style = None
  8934. */
  8935. __pyx_t_5 = ((__pyx_v_event->data.mapping_start.implicit == 1) != 0);
  8936. if (__pyx_t_5) {
  8937. /* "_yaml.pyx":643
  8938. * implicit = False
  8939. * if event.data.mapping_start.implicit == 1:
  8940. * implicit = True # <<<<<<<<<<<<<<
  8941. * flow_style = None
  8942. * if event.data.mapping_start.style == YAML_FLOW_MAPPING_STYLE:
  8943. */
  8944. __pyx_v_implicit = 1;
  8945. /* "_yaml.pyx":642
  8946. * tag = PyUnicode_FromString(event.data.mapping_start.tag)
  8947. * implicit = False
  8948. * if event.data.mapping_start.implicit == 1: # <<<<<<<<<<<<<<
  8949. * implicit = True
  8950. * flow_style = None
  8951. */
  8952. }
  8953. /* "_yaml.pyx":644
  8954. * if event.data.mapping_start.implicit == 1:
  8955. * implicit = True
  8956. * flow_style = None # <<<<<<<<<<<<<<
  8957. * if event.data.mapping_start.style == YAML_FLOW_MAPPING_STYLE:
  8958. * flow_style = True
  8959. */
  8960. __Pyx_INCREF(Py_None);
  8961. __pyx_v_flow_style = Py_None;
  8962. /* "_yaml.pyx":645
  8963. * implicit = True
  8964. * flow_style = None
  8965. * if event.data.mapping_start.style == YAML_FLOW_MAPPING_STYLE: # <<<<<<<<<<<<<<
  8966. * flow_style = True
  8967. * elif event.data.mapping_start.style == YAML_BLOCK_MAPPING_STYLE:
  8968. */
  8969. switch (__pyx_v_event->data.mapping_start.style) {
  8970. case YAML_FLOW_MAPPING_STYLE:
  8971. /* "_yaml.pyx":646
  8972. * flow_style = None
  8973. * if event.data.mapping_start.style == YAML_FLOW_MAPPING_STYLE:
  8974. * flow_style = True # <<<<<<<<<<<<<<
  8975. * elif event.data.mapping_start.style == YAML_BLOCK_MAPPING_STYLE:
  8976. * flow_style = False
  8977. */
  8978. __Pyx_INCREF(Py_True);
  8979. __Pyx_DECREF_SET(__pyx_v_flow_style, Py_True);
  8980. /* "_yaml.pyx":645
  8981. * implicit = True
  8982. * flow_style = None
  8983. * if event.data.mapping_start.style == YAML_FLOW_MAPPING_STYLE: # <<<<<<<<<<<<<<
  8984. * flow_style = True
  8985. * elif event.data.mapping_start.style == YAML_BLOCK_MAPPING_STYLE:
  8986. */
  8987. break;
  8988. case YAML_BLOCK_MAPPING_STYLE:
  8989. /* "_yaml.pyx":648
  8990. * flow_style = True
  8991. * elif event.data.mapping_start.style == YAML_BLOCK_MAPPING_STYLE:
  8992. * flow_style = False # <<<<<<<<<<<<<<
  8993. * return MappingStartEvent(anchor, tag, implicit,
  8994. * start_mark, end_mark, flow_style)
  8995. */
  8996. __Pyx_INCREF(Py_False);
  8997. __Pyx_DECREF_SET(__pyx_v_flow_style, Py_False);
  8998. /* "_yaml.pyx":647
  8999. * if event.data.mapping_start.style == YAML_FLOW_MAPPING_STYLE:
  9000. * flow_style = True
  9001. * elif event.data.mapping_start.style == YAML_BLOCK_MAPPING_STYLE: # <<<<<<<<<<<<<<
  9002. * flow_style = False
  9003. * return MappingStartEvent(anchor, tag, implicit,
  9004. */
  9005. break;
  9006. default: break;
  9007. }
  9008. /* "_yaml.pyx":649
  9009. * elif event.data.mapping_start.style == YAML_BLOCK_MAPPING_STYLE:
  9010. * flow_style = False
  9011. * return MappingStartEvent(anchor, tag, implicit, # <<<<<<<<<<<<<<
  9012. * start_mark, end_mark, flow_style)
  9013. * elif event.type == YAML_SEQUENCE_END_EVENT:
  9014. */
  9015. __Pyx_XDECREF(__pyx_r);
  9016. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_MappingStartEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 649, __pyx_L1_error)
  9017. __Pyx_GOTREF(__pyx_t_1);
  9018. __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_v_implicit); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 649, __pyx_L1_error)
  9019. __Pyx_GOTREF(__pyx_t_3);
  9020. /* "_yaml.pyx":650
  9021. * flow_style = False
  9022. * return MappingStartEvent(anchor, tag, implicit,
  9023. * start_mark, end_mark, flow_style) # <<<<<<<<<<<<<<
  9024. * elif event.type == YAML_SEQUENCE_END_EVENT:
  9025. * return SequenceEndEvent(start_mark, end_mark)
  9026. */
  9027. __pyx_t_8 = NULL;
  9028. __pyx_t_6 = 0;
  9029. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  9030. __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_1);
  9031. if (likely(__pyx_t_8)) {
  9032. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  9033. __Pyx_INCREF(__pyx_t_8);
  9034. __Pyx_INCREF(function);
  9035. __Pyx_DECREF_SET(__pyx_t_1, function);
  9036. __pyx_t_6 = 1;
  9037. }
  9038. }
  9039. #if CYTHON_FAST_PYCALL
  9040. if (PyFunction_Check(__pyx_t_1)) {
  9041. PyObject *__pyx_temp[7] = {__pyx_t_8, __pyx_v_anchor, __pyx_v_tag, __pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_v_flow_style};
  9042. __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 6+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 649, __pyx_L1_error)
  9043. __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
  9044. __Pyx_GOTREF(__pyx_t_4);
  9045. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  9046. } else
  9047. #endif
  9048. #if CYTHON_FAST_PYCCALL
  9049. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  9050. PyObject *__pyx_temp[7] = {__pyx_t_8, __pyx_v_anchor, __pyx_v_tag, __pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_v_flow_style};
  9051. __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 6+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 649, __pyx_L1_error)
  9052. __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
  9053. __Pyx_GOTREF(__pyx_t_4);
  9054. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  9055. } else
  9056. #endif
  9057. {
  9058. __pyx_t_2 = PyTuple_New(6+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 649, __pyx_L1_error)
  9059. __Pyx_GOTREF(__pyx_t_2);
  9060. if (__pyx_t_8) {
  9061. __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_8); __pyx_t_8 = NULL;
  9062. }
  9063. __Pyx_INCREF(__pyx_v_anchor);
  9064. __Pyx_GIVEREF(__pyx_v_anchor);
  9065. PyTuple_SET_ITEM(__pyx_t_2, 0+__pyx_t_6, __pyx_v_anchor);
  9066. __Pyx_INCREF(__pyx_v_tag);
  9067. __Pyx_GIVEREF(__pyx_v_tag);
  9068. PyTuple_SET_ITEM(__pyx_t_2, 1+__pyx_t_6, __pyx_v_tag);
  9069. __Pyx_GIVEREF(__pyx_t_3);
  9070. PyTuple_SET_ITEM(__pyx_t_2, 2+__pyx_t_6, __pyx_t_3);
  9071. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  9072. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  9073. PyTuple_SET_ITEM(__pyx_t_2, 3+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  9074. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  9075. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  9076. PyTuple_SET_ITEM(__pyx_t_2, 4+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  9077. __Pyx_INCREF(__pyx_v_flow_style);
  9078. __Pyx_GIVEREF(__pyx_v_flow_style);
  9079. PyTuple_SET_ITEM(__pyx_t_2, 5+__pyx_t_6, __pyx_v_flow_style);
  9080. __pyx_t_3 = 0;
  9081. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 649, __pyx_L1_error)
  9082. __Pyx_GOTREF(__pyx_t_4);
  9083. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  9084. }
  9085. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  9086. __pyx_r = __pyx_t_4;
  9087. __pyx_t_4 = 0;
  9088. goto __pyx_L0;
  9089. /* "_yaml.pyx":634
  9090. * return SequenceStartEvent(anchor, tag, implicit,
  9091. * start_mark, end_mark, flow_style)
  9092. * elif event.type == YAML_MAPPING_START_EVENT: # <<<<<<<<<<<<<<
  9093. * anchor = None
  9094. * if event.data.mapping_start.anchor != NULL:
  9095. */
  9096. break;
  9097. case YAML_SEQUENCE_END_EVENT:
  9098. /* "_yaml.pyx":652
  9099. * start_mark, end_mark, flow_style)
  9100. * elif event.type == YAML_SEQUENCE_END_EVENT:
  9101. * return SequenceEndEvent(start_mark, end_mark) # <<<<<<<<<<<<<<
  9102. * elif event.type == YAML_MAPPING_END_EVENT:
  9103. * return MappingEndEvent(start_mark, end_mark)
  9104. */
  9105. __Pyx_XDECREF(__pyx_r);
  9106. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_SequenceEndEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 652, __pyx_L1_error)
  9107. __Pyx_GOTREF(__pyx_t_1);
  9108. __pyx_t_2 = NULL;
  9109. __pyx_t_6 = 0;
  9110. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  9111. __pyx_t_2 = PyMethod_GET_SELF(__pyx_t_1);
  9112. if (likely(__pyx_t_2)) {
  9113. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  9114. __Pyx_INCREF(__pyx_t_2);
  9115. __Pyx_INCREF(function);
  9116. __Pyx_DECREF_SET(__pyx_t_1, function);
  9117. __pyx_t_6 = 1;
  9118. }
  9119. }
  9120. #if CYTHON_FAST_PYCALL
  9121. if (PyFunction_Check(__pyx_t_1)) {
  9122. PyObject *__pyx_temp[3] = {__pyx_t_2, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  9123. __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 652, __pyx_L1_error)
  9124. __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
  9125. __Pyx_GOTREF(__pyx_t_4);
  9126. } else
  9127. #endif
  9128. #if CYTHON_FAST_PYCCALL
  9129. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  9130. PyObject *__pyx_temp[3] = {__pyx_t_2, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  9131. __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 652, __pyx_L1_error)
  9132. __Pyx_XDECREF(__pyx_t_2); __pyx_t_2 = 0;
  9133. __Pyx_GOTREF(__pyx_t_4);
  9134. } else
  9135. #endif
  9136. {
  9137. __pyx_t_3 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 652, __pyx_L1_error)
  9138. __Pyx_GOTREF(__pyx_t_3);
  9139. if (__pyx_t_2) {
  9140. __Pyx_GIVEREF(__pyx_t_2); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_2); __pyx_t_2 = NULL;
  9141. }
  9142. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  9143. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  9144. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  9145. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  9146. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  9147. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  9148. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 652, __pyx_L1_error)
  9149. __Pyx_GOTREF(__pyx_t_4);
  9150. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  9151. }
  9152. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  9153. __pyx_r = __pyx_t_4;
  9154. __pyx_t_4 = 0;
  9155. goto __pyx_L0;
  9156. /* "_yaml.pyx":651
  9157. * return MappingStartEvent(anchor, tag, implicit,
  9158. * start_mark, end_mark, flow_style)
  9159. * elif event.type == YAML_SEQUENCE_END_EVENT: # <<<<<<<<<<<<<<
  9160. * return SequenceEndEvent(start_mark, end_mark)
  9161. * elif event.type == YAML_MAPPING_END_EVENT:
  9162. */
  9163. break;
  9164. case YAML_MAPPING_END_EVENT:
  9165. /* "_yaml.pyx":654
  9166. * return SequenceEndEvent(start_mark, end_mark)
  9167. * elif event.type == YAML_MAPPING_END_EVENT:
  9168. * return MappingEndEvent(start_mark, end_mark) # <<<<<<<<<<<<<<
  9169. * else:
  9170. * if PY_MAJOR_VERSION < 3:
  9171. */
  9172. __Pyx_XDECREF(__pyx_r);
  9173. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_MappingEndEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 654, __pyx_L1_error)
  9174. __Pyx_GOTREF(__pyx_t_1);
  9175. __pyx_t_3 = NULL;
  9176. __pyx_t_6 = 0;
  9177. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  9178. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  9179. if (likely(__pyx_t_3)) {
  9180. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  9181. __Pyx_INCREF(__pyx_t_3);
  9182. __Pyx_INCREF(function);
  9183. __Pyx_DECREF_SET(__pyx_t_1, function);
  9184. __pyx_t_6 = 1;
  9185. }
  9186. }
  9187. #if CYTHON_FAST_PYCALL
  9188. if (PyFunction_Check(__pyx_t_1)) {
  9189. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  9190. __pyx_t_4 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 654, __pyx_L1_error)
  9191. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  9192. __Pyx_GOTREF(__pyx_t_4);
  9193. } else
  9194. #endif
  9195. #if CYTHON_FAST_PYCCALL
  9196. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  9197. PyObject *__pyx_temp[3] = {__pyx_t_3, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark)};
  9198. __pyx_t_4 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_6, 2+__pyx_t_6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 654, __pyx_L1_error)
  9199. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  9200. __Pyx_GOTREF(__pyx_t_4);
  9201. } else
  9202. #endif
  9203. {
  9204. __pyx_t_2 = PyTuple_New(2+__pyx_t_6); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 654, __pyx_L1_error)
  9205. __Pyx_GOTREF(__pyx_t_2);
  9206. if (__pyx_t_3) {
  9207. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_2, 0, __pyx_t_3); __pyx_t_3 = NULL;
  9208. }
  9209. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  9210. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  9211. PyTuple_SET_ITEM(__pyx_t_2, 0+__pyx_t_6, ((PyObject *)__pyx_v_start_mark));
  9212. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  9213. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  9214. PyTuple_SET_ITEM(__pyx_t_2, 1+__pyx_t_6, ((PyObject *)__pyx_v_end_mark));
  9215. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_2, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 654, __pyx_L1_error)
  9216. __Pyx_GOTREF(__pyx_t_4);
  9217. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  9218. }
  9219. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  9220. __pyx_r = __pyx_t_4;
  9221. __pyx_t_4 = 0;
  9222. goto __pyx_L0;
  9223. /* "_yaml.pyx":653
  9224. * elif event.type == YAML_SEQUENCE_END_EVENT:
  9225. * return SequenceEndEvent(start_mark, end_mark)
  9226. * elif event.type == YAML_MAPPING_END_EVENT: # <<<<<<<<<<<<<<
  9227. * return MappingEndEvent(start_mark, end_mark)
  9228. * else:
  9229. */
  9230. break;
  9231. default:
  9232. /* "_yaml.pyx":656
  9233. * return MappingEndEvent(start_mark, end_mark)
  9234. * else:
  9235. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  9236. * raise ValueError("unknown event type")
  9237. * else:
  9238. */
  9239. __pyx_t_5 = ((PY_MAJOR_VERSION < 3) != 0);
  9240. if (unlikely(__pyx_t_5)) {
  9241. /* "_yaml.pyx":657
  9242. * else:
  9243. * if PY_MAJOR_VERSION < 3:
  9244. * raise ValueError("unknown event type") # <<<<<<<<<<<<<<
  9245. * else:
  9246. * raise ValueError(u"unknown event type")
  9247. */
  9248. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__13, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 657, __pyx_L1_error)
  9249. __Pyx_GOTREF(__pyx_t_4);
  9250. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  9251. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  9252. __PYX_ERR(0, 657, __pyx_L1_error)
  9253. /* "_yaml.pyx":656
  9254. * return MappingEndEvent(start_mark, end_mark)
  9255. * else:
  9256. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  9257. * raise ValueError("unknown event type")
  9258. * else:
  9259. */
  9260. }
  9261. /* "_yaml.pyx":659
  9262. * raise ValueError("unknown event type")
  9263. * else:
  9264. * raise ValueError(u"unknown event type") # <<<<<<<<<<<<<<
  9265. *
  9266. * def get_event(self):
  9267. */
  9268. /*else*/ {
  9269. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__14, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 659, __pyx_L1_error)
  9270. __Pyx_GOTREF(__pyx_t_4);
  9271. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  9272. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  9273. __PYX_ERR(0, 659, __pyx_L1_error)
  9274. }
  9275. break;
  9276. }
  9277. /* "_yaml.pyx":535
  9278. * return event_object
  9279. *
  9280. * cdef object _event_to_object(self, yaml_event_t *event): # <<<<<<<<<<<<<<
  9281. * cdef yaml_tag_directive_t *tag_directive
  9282. * start_mark = Mark(self.stream_name,
  9283. */
  9284. /* function exit code */
  9285. __pyx_L1_error:;
  9286. __Pyx_XDECREF(__pyx_t_1);
  9287. __Pyx_XDECREF(__pyx_t_2);
  9288. __Pyx_XDECREF(__pyx_t_3);
  9289. __Pyx_XDECREF(__pyx_t_4);
  9290. __Pyx_XDECREF(__pyx_t_8);
  9291. __Pyx_AddTraceback("_yaml.CParser._event_to_object", __pyx_clineno, __pyx_lineno, __pyx_filename);
  9292. __pyx_r = 0;
  9293. __pyx_L0:;
  9294. __Pyx_XDECREF((PyObject *)__pyx_v_start_mark);
  9295. __Pyx_XDECREF((PyObject *)__pyx_v_end_mark);
  9296. __Pyx_XDECREF(__pyx_v_encoding);
  9297. __Pyx_XDECREF(__pyx_v_version);
  9298. __Pyx_XDECREF(__pyx_v_tags);
  9299. __Pyx_XDECREF(__pyx_v_handle);
  9300. __Pyx_XDECREF(__pyx_v_prefix);
  9301. __Pyx_XDECREF(__pyx_v_anchor);
  9302. __Pyx_XDECREF(__pyx_v_tag);
  9303. __Pyx_XDECREF(__pyx_v_value);
  9304. __Pyx_XDECREF(__pyx_v_style);
  9305. __Pyx_XDECREF(__pyx_v_flow_style);
  9306. __Pyx_XGIVEREF(__pyx_r);
  9307. __Pyx_RefNannyFinishContext();
  9308. return __pyx_r;
  9309. }
  9310. /* "_yaml.pyx":661
  9311. * raise ValueError(u"unknown event type")
  9312. *
  9313. * def get_event(self): # <<<<<<<<<<<<<<
  9314. * if self.current_event is not None:
  9315. * value = self.current_event
  9316. */
  9317. /* Python wrapper */
  9318. static PyObject *__pyx_pw_5_yaml_7CParser_17get_event(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  9319. static PyObject *__pyx_pw_5_yaml_7CParser_17get_event(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  9320. PyObject *__pyx_r = 0;
  9321. __Pyx_RefNannyDeclarations
  9322. __Pyx_RefNannySetupContext("get_event (wrapper)", 0);
  9323. __pyx_r = __pyx_pf_5_yaml_7CParser_16get_event(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self));
  9324. /* function exit code */
  9325. __Pyx_RefNannyFinishContext();
  9326. return __pyx_r;
  9327. }
  9328. static PyObject *__pyx_pf_5_yaml_7CParser_16get_event(struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  9329. PyObject *__pyx_v_value = NULL;
  9330. PyObject *__pyx_r = NULL;
  9331. __Pyx_RefNannyDeclarations
  9332. int __pyx_t_1;
  9333. int __pyx_t_2;
  9334. PyObject *__pyx_t_3 = NULL;
  9335. __Pyx_RefNannySetupContext("get_event", 0);
  9336. /* "_yaml.pyx":662
  9337. *
  9338. * def get_event(self):
  9339. * if self.current_event is not None: # <<<<<<<<<<<<<<
  9340. * value = self.current_event
  9341. * self.current_event = None
  9342. */
  9343. __pyx_t_1 = (__pyx_v_self->current_event != Py_None);
  9344. __pyx_t_2 = (__pyx_t_1 != 0);
  9345. if (__pyx_t_2) {
  9346. /* "_yaml.pyx":663
  9347. * def get_event(self):
  9348. * if self.current_event is not None:
  9349. * value = self.current_event # <<<<<<<<<<<<<<
  9350. * self.current_event = None
  9351. * else:
  9352. */
  9353. __pyx_t_3 = __pyx_v_self->current_event;
  9354. __Pyx_INCREF(__pyx_t_3);
  9355. __pyx_v_value = __pyx_t_3;
  9356. __pyx_t_3 = 0;
  9357. /* "_yaml.pyx":664
  9358. * if self.current_event is not None:
  9359. * value = self.current_event
  9360. * self.current_event = None # <<<<<<<<<<<<<<
  9361. * else:
  9362. * value = self._parse()
  9363. */
  9364. __Pyx_INCREF(Py_None);
  9365. __Pyx_GIVEREF(Py_None);
  9366. __Pyx_GOTREF(__pyx_v_self->current_event);
  9367. __Pyx_DECREF(__pyx_v_self->current_event);
  9368. __pyx_v_self->current_event = Py_None;
  9369. /* "_yaml.pyx":662
  9370. *
  9371. * def get_event(self):
  9372. * if self.current_event is not None: # <<<<<<<<<<<<<<
  9373. * value = self.current_event
  9374. * self.current_event = None
  9375. */
  9376. goto __pyx_L3;
  9377. }
  9378. /* "_yaml.pyx":666
  9379. * self.current_event = None
  9380. * else:
  9381. * value = self._parse() # <<<<<<<<<<<<<<
  9382. * return value
  9383. *
  9384. */
  9385. /*else*/ {
  9386. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parse(__pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 666, __pyx_L1_error)
  9387. __Pyx_GOTREF(__pyx_t_3);
  9388. __pyx_v_value = __pyx_t_3;
  9389. __pyx_t_3 = 0;
  9390. }
  9391. __pyx_L3:;
  9392. /* "_yaml.pyx":667
  9393. * else:
  9394. * value = self._parse()
  9395. * return value # <<<<<<<<<<<<<<
  9396. *
  9397. * def peek_event(self):
  9398. */
  9399. __Pyx_XDECREF(__pyx_r);
  9400. __Pyx_INCREF(__pyx_v_value);
  9401. __pyx_r = __pyx_v_value;
  9402. goto __pyx_L0;
  9403. /* "_yaml.pyx":661
  9404. * raise ValueError(u"unknown event type")
  9405. *
  9406. * def get_event(self): # <<<<<<<<<<<<<<
  9407. * if self.current_event is not None:
  9408. * value = self.current_event
  9409. */
  9410. /* function exit code */
  9411. __pyx_L1_error:;
  9412. __Pyx_XDECREF(__pyx_t_3);
  9413. __Pyx_AddTraceback("_yaml.CParser.get_event", __pyx_clineno, __pyx_lineno, __pyx_filename);
  9414. __pyx_r = NULL;
  9415. __pyx_L0:;
  9416. __Pyx_XDECREF(__pyx_v_value);
  9417. __Pyx_XGIVEREF(__pyx_r);
  9418. __Pyx_RefNannyFinishContext();
  9419. return __pyx_r;
  9420. }
  9421. /* "_yaml.pyx":669
  9422. * return value
  9423. *
  9424. * def peek_event(self): # <<<<<<<<<<<<<<
  9425. * if self.current_event is None:
  9426. * self.current_event = self._parse()
  9427. */
  9428. /* Python wrapper */
  9429. static PyObject *__pyx_pw_5_yaml_7CParser_19peek_event(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  9430. static PyObject *__pyx_pw_5_yaml_7CParser_19peek_event(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  9431. PyObject *__pyx_r = 0;
  9432. __Pyx_RefNannyDeclarations
  9433. __Pyx_RefNannySetupContext("peek_event (wrapper)", 0);
  9434. __pyx_r = __pyx_pf_5_yaml_7CParser_18peek_event(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self));
  9435. /* function exit code */
  9436. __Pyx_RefNannyFinishContext();
  9437. return __pyx_r;
  9438. }
  9439. static PyObject *__pyx_pf_5_yaml_7CParser_18peek_event(struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  9440. PyObject *__pyx_r = NULL;
  9441. __Pyx_RefNannyDeclarations
  9442. int __pyx_t_1;
  9443. int __pyx_t_2;
  9444. PyObject *__pyx_t_3 = NULL;
  9445. __Pyx_RefNannySetupContext("peek_event", 0);
  9446. /* "_yaml.pyx":670
  9447. *
  9448. * def peek_event(self):
  9449. * if self.current_event is None: # <<<<<<<<<<<<<<
  9450. * self.current_event = self._parse()
  9451. * return self.current_event
  9452. */
  9453. __pyx_t_1 = (__pyx_v_self->current_event == Py_None);
  9454. __pyx_t_2 = (__pyx_t_1 != 0);
  9455. if (__pyx_t_2) {
  9456. /* "_yaml.pyx":671
  9457. * def peek_event(self):
  9458. * if self.current_event is None:
  9459. * self.current_event = self._parse() # <<<<<<<<<<<<<<
  9460. * return self.current_event
  9461. *
  9462. */
  9463. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parse(__pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 671, __pyx_L1_error)
  9464. __Pyx_GOTREF(__pyx_t_3);
  9465. __Pyx_GIVEREF(__pyx_t_3);
  9466. __Pyx_GOTREF(__pyx_v_self->current_event);
  9467. __Pyx_DECREF(__pyx_v_self->current_event);
  9468. __pyx_v_self->current_event = __pyx_t_3;
  9469. __pyx_t_3 = 0;
  9470. /* "_yaml.pyx":670
  9471. *
  9472. * def peek_event(self):
  9473. * if self.current_event is None: # <<<<<<<<<<<<<<
  9474. * self.current_event = self._parse()
  9475. * return self.current_event
  9476. */
  9477. }
  9478. /* "_yaml.pyx":672
  9479. * if self.current_event is None:
  9480. * self.current_event = self._parse()
  9481. * return self.current_event # <<<<<<<<<<<<<<
  9482. *
  9483. * def check_event(self, *choices):
  9484. */
  9485. __Pyx_XDECREF(__pyx_r);
  9486. __Pyx_INCREF(__pyx_v_self->current_event);
  9487. __pyx_r = __pyx_v_self->current_event;
  9488. goto __pyx_L0;
  9489. /* "_yaml.pyx":669
  9490. * return value
  9491. *
  9492. * def peek_event(self): # <<<<<<<<<<<<<<
  9493. * if self.current_event is None:
  9494. * self.current_event = self._parse()
  9495. */
  9496. /* function exit code */
  9497. __pyx_L1_error:;
  9498. __Pyx_XDECREF(__pyx_t_3);
  9499. __Pyx_AddTraceback("_yaml.CParser.peek_event", __pyx_clineno, __pyx_lineno, __pyx_filename);
  9500. __pyx_r = NULL;
  9501. __pyx_L0:;
  9502. __Pyx_XGIVEREF(__pyx_r);
  9503. __Pyx_RefNannyFinishContext();
  9504. return __pyx_r;
  9505. }
  9506. /* "_yaml.pyx":674
  9507. * return self.current_event
  9508. *
  9509. * def check_event(self, *choices): # <<<<<<<<<<<<<<
  9510. * if self.current_event is None:
  9511. * self.current_event = self._parse()
  9512. */
  9513. /* Python wrapper */
  9514. static PyObject *__pyx_pw_5_yaml_7CParser_21check_event(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
  9515. static PyObject *__pyx_pw_5_yaml_7CParser_21check_event(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  9516. PyObject *__pyx_v_choices = 0;
  9517. PyObject *__pyx_r = 0;
  9518. __Pyx_RefNannyDeclarations
  9519. __Pyx_RefNannySetupContext("check_event (wrapper)", 0);
  9520. if (unlikely(__pyx_kwds) && unlikely(PyDict_Size(__pyx_kwds) > 0) && unlikely(!__Pyx_CheckKeywordStrings(__pyx_kwds, "check_event", 0))) return NULL;
  9521. __Pyx_INCREF(__pyx_args);
  9522. __pyx_v_choices = __pyx_args;
  9523. __pyx_r = __pyx_pf_5_yaml_7CParser_20check_event(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self), __pyx_v_choices);
  9524. /* function exit code */
  9525. __Pyx_XDECREF(__pyx_v_choices);
  9526. __Pyx_RefNannyFinishContext();
  9527. return __pyx_r;
  9528. }
  9529. static PyObject *__pyx_pf_5_yaml_7CParser_20check_event(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, PyObject *__pyx_v_choices) {
  9530. PyObject *__pyx_v_event_class = NULL;
  9531. PyObject *__pyx_v_choice = NULL;
  9532. PyObject *__pyx_r = NULL;
  9533. __Pyx_RefNannyDeclarations
  9534. int __pyx_t_1;
  9535. int __pyx_t_2;
  9536. PyObject *__pyx_t_3 = NULL;
  9537. Py_ssize_t __pyx_t_4;
  9538. PyObject *__pyx_t_5 = NULL;
  9539. __Pyx_RefNannySetupContext("check_event", 0);
  9540. /* "_yaml.pyx":675
  9541. *
  9542. * def check_event(self, *choices):
  9543. * if self.current_event is None: # <<<<<<<<<<<<<<
  9544. * self.current_event = self._parse()
  9545. * if self.current_event is None:
  9546. */
  9547. __pyx_t_1 = (__pyx_v_self->current_event == Py_None);
  9548. __pyx_t_2 = (__pyx_t_1 != 0);
  9549. if (__pyx_t_2) {
  9550. /* "_yaml.pyx":676
  9551. * def check_event(self, *choices):
  9552. * if self.current_event is None:
  9553. * self.current_event = self._parse() # <<<<<<<<<<<<<<
  9554. * if self.current_event is None:
  9555. * return False
  9556. */
  9557. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parse(__pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 676, __pyx_L1_error)
  9558. __Pyx_GOTREF(__pyx_t_3);
  9559. __Pyx_GIVEREF(__pyx_t_3);
  9560. __Pyx_GOTREF(__pyx_v_self->current_event);
  9561. __Pyx_DECREF(__pyx_v_self->current_event);
  9562. __pyx_v_self->current_event = __pyx_t_3;
  9563. __pyx_t_3 = 0;
  9564. /* "_yaml.pyx":675
  9565. *
  9566. * def check_event(self, *choices):
  9567. * if self.current_event is None: # <<<<<<<<<<<<<<
  9568. * self.current_event = self._parse()
  9569. * if self.current_event is None:
  9570. */
  9571. }
  9572. /* "_yaml.pyx":677
  9573. * if self.current_event is None:
  9574. * self.current_event = self._parse()
  9575. * if self.current_event is None: # <<<<<<<<<<<<<<
  9576. * return False
  9577. * if not choices:
  9578. */
  9579. __pyx_t_2 = (__pyx_v_self->current_event == Py_None);
  9580. __pyx_t_1 = (__pyx_t_2 != 0);
  9581. if (__pyx_t_1) {
  9582. /* "_yaml.pyx":678
  9583. * self.current_event = self._parse()
  9584. * if self.current_event is None:
  9585. * return False # <<<<<<<<<<<<<<
  9586. * if not choices:
  9587. * return True
  9588. */
  9589. __Pyx_XDECREF(__pyx_r);
  9590. __Pyx_INCREF(Py_False);
  9591. __pyx_r = Py_False;
  9592. goto __pyx_L0;
  9593. /* "_yaml.pyx":677
  9594. * if self.current_event is None:
  9595. * self.current_event = self._parse()
  9596. * if self.current_event is None: # <<<<<<<<<<<<<<
  9597. * return False
  9598. * if not choices:
  9599. */
  9600. }
  9601. /* "_yaml.pyx":679
  9602. * if self.current_event is None:
  9603. * return False
  9604. * if not choices: # <<<<<<<<<<<<<<
  9605. * return True
  9606. * event_class = self.current_event.__class__
  9607. */
  9608. __pyx_t_1 = (PyTuple_GET_SIZE(__pyx_v_choices) != 0);
  9609. __pyx_t_2 = ((!__pyx_t_1) != 0);
  9610. if (__pyx_t_2) {
  9611. /* "_yaml.pyx":680
  9612. * return False
  9613. * if not choices:
  9614. * return True # <<<<<<<<<<<<<<
  9615. * event_class = self.current_event.__class__
  9616. * for choice in choices:
  9617. */
  9618. __Pyx_XDECREF(__pyx_r);
  9619. __Pyx_INCREF(Py_True);
  9620. __pyx_r = Py_True;
  9621. goto __pyx_L0;
  9622. /* "_yaml.pyx":679
  9623. * if self.current_event is None:
  9624. * return False
  9625. * if not choices: # <<<<<<<<<<<<<<
  9626. * return True
  9627. * event_class = self.current_event.__class__
  9628. */
  9629. }
  9630. /* "_yaml.pyx":681
  9631. * if not choices:
  9632. * return True
  9633. * event_class = self.current_event.__class__ # <<<<<<<<<<<<<<
  9634. * for choice in choices:
  9635. * if event_class is choice:
  9636. */
  9637. __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_self->current_event, __pyx_n_s_class); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 681, __pyx_L1_error)
  9638. __Pyx_GOTREF(__pyx_t_3);
  9639. __pyx_v_event_class = __pyx_t_3;
  9640. __pyx_t_3 = 0;
  9641. /* "_yaml.pyx":682
  9642. * return True
  9643. * event_class = self.current_event.__class__
  9644. * for choice in choices: # <<<<<<<<<<<<<<
  9645. * if event_class is choice:
  9646. * return True
  9647. */
  9648. __pyx_t_3 = __pyx_v_choices; __Pyx_INCREF(__pyx_t_3); __pyx_t_4 = 0;
  9649. for (;;) {
  9650. if (__pyx_t_4 >= PyTuple_GET_SIZE(__pyx_t_3)) break;
  9651. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  9652. __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_4); __Pyx_INCREF(__pyx_t_5); __pyx_t_4++; if (unlikely(0 < 0)) __PYX_ERR(0, 682, __pyx_L1_error)
  9653. #else
  9654. __pyx_t_5 = PySequence_ITEM(__pyx_t_3, __pyx_t_4); __pyx_t_4++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 682, __pyx_L1_error)
  9655. __Pyx_GOTREF(__pyx_t_5);
  9656. #endif
  9657. __Pyx_XDECREF_SET(__pyx_v_choice, __pyx_t_5);
  9658. __pyx_t_5 = 0;
  9659. /* "_yaml.pyx":683
  9660. * event_class = self.current_event.__class__
  9661. * for choice in choices:
  9662. * if event_class is choice: # <<<<<<<<<<<<<<
  9663. * return True
  9664. * return False
  9665. */
  9666. __pyx_t_2 = (__pyx_v_event_class == __pyx_v_choice);
  9667. __pyx_t_1 = (__pyx_t_2 != 0);
  9668. if (__pyx_t_1) {
  9669. /* "_yaml.pyx":684
  9670. * for choice in choices:
  9671. * if event_class is choice:
  9672. * return True # <<<<<<<<<<<<<<
  9673. * return False
  9674. *
  9675. */
  9676. __Pyx_XDECREF(__pyx_r);
  9677. __Pyx_INCREF(Py_True);
  9678. __pyx_r = Py_True;
  9679. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  9680. goto __pyx_L0;
  9681. /* "_yaml.pyx":683
  9682. * event_class = self.current_event.__class__
  9683. * for choice in choices:
  9684. * if event_class is choice: # <<<<<<<<<<<<<<
  9685. * return True
  9686. * return False
  9687. */
  9688. }
  9689. /* "_yaml.pyx":682
  9690. * return True
  9691. * event_class = self.current_event.__class__
  9692. * for choice in choices: # <<<<<<<<<<<<<<
  9693. * if event_class is choice:
  9694. * return True
  9695. */
  9696. }
  9697. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  9698. /* "_yaml.pyx":685
  9699. * if event_class is choice:
  9700. * return True
  9701. * return False # <<<<<<<<<<<<<<
  9702. *
  9703. * def check_node(self):
  9704. */
  9705. __Pyx_XDECREF(__pyx_r);
  9706. __Pyx_INCREF(Py_False);
  9707. __pyx_r = Py_False;
  9708. goto __pyx_L0;
  9709. /* "_yaml.pyx":674
  9710. * return self.current_event
  9711. *
  9712. * def check_event(self, *choices): # <<<<<<<<<<<<<<
  9713. * if self.current_event is None:
  9714. * self.current_event = self._parse()
  9715. */
  9716. /* function exit code */
  9717. __pyx_L1_error:;
  9718. __Pyx_XDECREF(__pyx_t_3);
  9719. __Pyx_XDECREF(__pyx_t_5);
  9720. __Pyx_AddTraceback("_yaml.CParser.check_event", __pyx_clineno, __pyx_lineno, __pyx_filename);
  9721. __pyx_r = NULL;
  9722. __pyx_L0:;
  9723. __Pyx_XDECREF(__pyx_v_event_class);
  9724. __Pyx_XDECREF(__pyx_v_choice);
  9725. __Pyx_XGIVEREF(__pyx_r);
  9726. __Pyx_RefNannyFinishContext();
  9727. return __pyx_r;
  9728. }
  9729. /* "_yaml.pyx":687
  9730. * return False
  9731. *
  9732. * def check_node(self): # <<<<<<<<<<<<<<
  9733. * self._parse_next_event()
  9734. * if self.parsed_event.type == YAML_STREAM_START_EVENT:
  9735. */
  9736. /* Python wrapper */
  9737. static PyObject *__pyx_pw_5_yaml_7CParser_23check_node(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  9738. static PyObject *__pyx_pw_5_yaml_7CParser_23check_node(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  9739. PyObject *__pyx_r = 0;
  9740. __Pyx_RefNannyDeclarations
  9741. __Pyx_RefNannySetupContext("check_node (wrapper)", 0);
  9742. __pyx_r = __pyx_pf_5_yaml_7CParser_22check_node(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self));
  9743. /* function exit code */
  9744. __Pyx_RefNannyFinishContext();
  9745. return __pyx_r;
  9746. }
  9747. static PyObject *__pyx_pf_5_yaml_7CParser_22check_node(struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  9748. PyObject *__pyx_r = NULL;
  9749. __Pyx_RefNannyDeclarations
  9750. int __pyx_t_1;
  9751. int __pyx_t_2;
  9752. __Pyx_RefNannySetupContext("check_node", 0);
  9753. /* "_yaml.pyx":688
  9754. *
  9755. * def check_node(self):
  9756. * self._parse_next_event() # <<<<<<<<<<<<<<
  9757. * if self.parsed_event.type == YAML_STREAM_START_EVENT:
  9758. * yaml_event_delete(&self.parsed_event)
  9759. */
  9760. __pyx_t_1 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parse_next_event(__pyx_v_self); if (unlikely(__pyx_t_1 == ((int)0))) __PYX_ERR(0, 688, __pyx_L1_error)
  9761. /* "_yaml.pyx":689
  9762. * def check_node(self):
  9763. * self._parse_next_event()
  9764. * if self.parsed_event.type == YAML_STREAM_START_EVENT: # <<<<<<<<<<<<<<
  9765. * yaml_event_delete(&self.parsed_event)
  9766. * self._parse_next_event()
  9767. */
  9768. __pyx_t_2 = ((__pyx_v_self->parsed_event.type == YAML_STREAM_START_EVENT) != 0);
  9769. if (__pyx_t_2) {
  9770. /* "_yaml.pyx":690
  9771. * self._parse_next_event()
  9772. * if self.parsed_event.type == YAML_STREAM_START_EVENT:
  9773. * yaml_event_delete(&self.parsed_event) # <<<<<<<<<<<<<<
  9774. * self._parse_next_event()
  9775. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  9776. */
  9777. yaml_event_delete((&__pyx_v_self->parsed_event));
  9778. /* "_yaml.pyx":691
  9779. * if self.parsed_event.type == YAML_STREAM_START_EVENT:
  9780. * yaml_event_delete(&self.parsed_event)
  9781. * self._parse_next_event() # <<<<<<<<<<<<<<
  9782. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  9783. * return True
  9784. */
  9785. __pyx_t_1 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parse_next_event(__pyx_v_self); if (unlikely(__pyx_t_1 == ((int)0))) __PYX_ERR(0, 691, __pyx_L1_error)
  9786. /* "_yaml.pyx":689
  9787. * def check_node(self):
  9788. * self._parse_next_event()
  9789. * if self.parsed_event.type == YAML_STREAM_START_EVENT: # <<<<<<<<<<<<<<
  9790. * yaml_event_delete(&self.parsed_event)
  9791. * self._parse_next_event()
  9792. */
  9793. }
  9794. /* "_yaml.pyx":692
  9795. * yaml_event_delete(&self.parsed_event)
  9796. * self._parse_next_event()
  9797. * if self.parsed_event.type != YAML_STREAM_END_EVENT: # <<<<<<<<<<<<<<
  9798. * return True
  9799. * return False
  9800. */
  9801. __pyx_t_2 = ((__pyx_v_self->parsed_event.type != YAML_STREAM_END_EVENT) != 0);
  9802. if (__pyx_t_2) {
  9803. /* "_yaml.pyx":693
  9804. * self._parse_next_event()
  9805. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  9806. * return True # <<<<<<<<<<<<<<
  9807. * return False
  9808. *
  9809. */
  9810. __Pyx_XDECREF(__pyx_r);
  9811. __Pyx_INCREF(Py_True);
  9812. __pyx_r = Py_True;
  9813. goto __pyx_L0;
  9814. /* "_yaml.pyx":692
  9815. * yaml_event_delete(&self.parsed_event)
  9816. * self._parse_next_event()
  9817. * if self.parsed_event.type != YAML_STREAM_END_EVENT: # <<<<<<<<<<<<<<
  9818. * return True
  9819. * return False
  9820. */
  9821. }
  9822. /* "_yaml.pyx":694
  9823. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  9824. * return True
  9825. * return False # <<<<<<<<<<<<<<
  9826. *
  9827. * def get_node(self):
  9828. */
  9829. __Pyx_XDECREF(__pyx_r);
  9830. __Pyx_INCREF(Py_False);
  9831. __pyx_r = Py_False;
  9832. goto __pyx_L0;
  9833. /* "_yaml.pyx":687
  9834. * return False
  9835. *
  9836. * def check_node(self): # <<<<<<<<<<<<<<
  9837. * self._parse_next_event()
  9838. * if self.parsed_event.type == YAML_STREAM_START_EVENT:
  9839. */
  9840. /* function exit code */
  9841. __pyx_L1_error:;
  9842. __Pyx_AddTraceback("_yaml.CParser.check_node", __pyx_clineno, __pyx_lineno, __pyx_filename);
  9843. __pyx_r = NULL;
  9844. __pyx_L0:;
  9845. __Pyx_XGIVEREF(__pyx_r);
  9846. __Pyx_RefNannyFinishContext();
  9847. return __pyx_r;
  9848. }
  9849. /* "_yaml.pyx":696
  9850. * return False
  9851. *
  9852. * def get_node(self): # <<<<<<<<<<<<<<
  9853. * self._parse_next_event()
  9854. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  9855. */
  9856. /* Python wrapper */
  9857. static PyObject *__pyx_pw_5_yaml_7CParser_25get_node(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  9858. static PyObject *__pyx_pw_5_yaml_7CParser_25get_node(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  9859. PyObject *__pyx_r = 0;
  9860. __Pyx_RefNannyDeclarations
  9861. __Pyx_RefNannySetupContext("get_node (wrapper)", 0);
  9862. __pyx_r = __pyx_pf_5_yaml_7CParser_24get_node(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self));
  9863. /* function exit code */
  9864. __Pyx_RefNannyFinishContext();
  9865. return __pyx_r;
  9866. }
  9867. static PyObject *__pyx_pf_5_yaml_7CParser_24get_node(struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  9868. PyObject *__pyx_r = NULL;
  9869. __Pyx_RefNannyDeclarations
  9870. int __pyx_t_1;
  9871. int __pyx_t_2;
  9872. PyObject *__pyx_t_3 = NULL;
  9873. __Pyx_RefNannySetupContext("get_node", 0);
  9874. /* "_yaml.pyx":697
  9875. *
  9876. * def get_node(self):
  9877. * self._parse_next_event() # <<<<<<<<<<<<<<
  9878. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  9879. * return self._compose_document()
  9880. */
  9881. __pyx_t_1 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parse_next_event(__pyx_v_self); if (unlikely(__pyx_t_1 == ((int)0))) __PYX_ERR(0, 697, __pyx_L1_error)
  9882. /* "_yaml.pyx":698
  9883. * def get_node(self):
  9884. * self._parse_next_event()
  9885. * if self.parsed_event.type != YAML_STREAM_END_EVENT: # <<<<<<<<<<<<<<
  9886. * return self._compose_document()
  9887. *
  9888. */
  9889. __pyx_t_2 = ((__pyx_v_self->parsed_event.type != YAML_STREAM_END_EVENT) != 0);
  9890. if (__pyx_t_2) {
  9891. /* "_yaml.pyx":699
  9892. * self._parse_next_event()
  9893. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  9894. * return self._compose_document() # <<<<<<<<<<<<<<
  9895. *
  9896. * def get_single_node(self):
  9897. */
  9898. __Pyx_XDECREF(__pyx_r);
  9899. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_compose_document(__pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 699, __pyx_L1_error)
  9900. __Pyx_GOTREF(__pyx_t_3);
  9901. __pyx_r = __pyx_t_3;
  9902. __pyx_t_3 = 0;
  9903. goto __pyx_L0;
  9904. /* "_yaml.pyx":698
  9905. * def get_node(self):
  9906. * self._parse_next_event()
  9907. * if self.parsed_event.type != YAML_STREAM_END_EVENT: # <<<<<<<<<<<<<<
  9908. * return self._compose_document()
  9909. *
  9910. */
  9911. }
  9912. /* "_yaml.pyx":696
  9913. * return False
  9914. *
  9915. * def get_node(self): # <<<<<<<<<<<<<<
  9916. * self._parse_next_event()
  9917. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  9918. */
  9919. /* function exit code */
  9920. __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  9921. goto __pyx_L0;
  9922. __pyx_L1_error:;
  9923. __Pyx_XDECREF(__pyx_t_3);
  9924. __Pyx_AddTraceback("_yaml.CParser.get_node", __pyx_clineno, __pyx_lineno, __pyx_filename);
  9925. __pyx_r = NULL;
  9926. __pyx_L0:;
  9927. __Pyx_XGIVEREF(__pyx_r);
  9928. __Pyx_RefNannyFinishContext();
  9929. return __pyx_r;
  9930. }
  9931. /* "_yaml.pyx":701
  9932. * return self._compose_document()
  9933. *
  9934. * def get_single_node(self): # <<<<<<<<<<<<<<
  9935. * self._parse_next_event()
  9936. * yaml_event_delete(&self.parsed_event)
  9937. */
  9938. /* Python wrapper */
  9939. static PyObject *__pyx_pw_5_yaml_7CParser_27get_single_node(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  9940. static PyObject *__pyx_pw_5_yaml_7CParser_27get_single_node(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  9941. PyObject *__pyx_r = 0;
  9942. __Pyx_RefNannyDeclarations
  9943. __Pyx_RefNannySetupContext("get_single_node (wrapper)", 0);
  9944. __pyx_r = __pyx_pf_5_yaml_7CParser_26get_single_node(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self));
  9945. /* function exit code */
  9946. __Pyx_RefNannyFinishContext();
  9947. return __pyx_r;
  9948. }
  9949. static PyObject *__pyx_pf_5_yaml_7CParser_26get_single_node(struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  9950. PyObject *__pyx_v_document = NULL;
  9951. struct __pyx_obj_5_yaml_Mark *__pyx_v_mark = NULL;
  9952. PyObject *__pyx_r = NULL;
  9953. __Pyx_RefNannyDeclarations
  9954. int __pyx_t_1;
  9955. int __pyx_t_2;
  9956. PyObject *__pyx_t_3 = NULL;
  9957. PyObject *__pyx_t_4 = NULL;
  9958. PyObject *__pyx_t_5 = NULL;
  9959. PyObject *__pyx_t_6 = NULL;
  9960. PyObject *__pyx_t_7 = NULL;
  9961. __Pyx_RefNannySetupContext("get_single_node", 0);
  9962. /* "_yaml.pyx":702
  9963. *
  9964. * def get_single_node(self):
  9965. * self._parse_next_event() # <<<<<<<<<<<<<<
  9966. * yaml_event_delete(&self.parsed_event)
  9967. * self._parse_next_event()
  9968. */
  9969. __pyx_t_1 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parse_next_event(__pyx_v_self); if (unlikely(__pyx_t_1 == ((int)0))) __PYX_ERR(0, 702, __pyx_L1_error)
  9970. /* "_yaml.pyx":703
  9971. * def get_single_node(self):
  9972. * self._parse_next_event()
  9973. * yaml_event_delete(&self.parsed_event) # <<<<<<<<<<<<<<
  9974. * self._parse_next_event()
  9975. * document = None
  9976. */
  9977. yaml_event_delete((&__pyx_v_self->parsed_event));
  9978. /* "_yaml.pyx":704
  9979. * self._parse_next_event()
  9980. * yaml_event_delete(&self.parsed_event)
  9981. * self._parse_next_event() # <<<<<<<<<<<<<<
  9982. * document = None
  9983. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  9984. */
  9985. __pyx_t_1 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parse_next_event(__pyx_v_self); if (unlikely(__pyx_t_1 == ((int)0))) __PYX_ERR(0, 704, __pyx_L1_error)
  9986. /* "_yaml.pyx":705
  9987. * yaml_event_delete(&self.parsed_event)
  9988. * self._parse_next_event()
  9989. * document = None # <<<<<<<<<<<<<<
  9990. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  9991. * document = self._compose_document()
  9992. */
  9993. __Pyx_INCREF(Py_None);
  9994. __pyx_v_document = Py_None;
  9995. /* "_yaml.pyx":706
  9996. * self._parse_next_event()
  9997. * document = None
  9998. * if self.parsed_event.type != YAML_STREAM_END_EVENT: # <<<<<<<<<<<<<<
  9999. * document = self._compose_document()
  10000. * self._parse_next_event()
  10001. */
  10002. __pyx_t_2 = ((__pyx_v_self->parsed_event.type != YAML_STREAM_END_EVENT) != 0);
  10003. if (__pyx_t_2) {
  10004. /* "_yaml.pyx":707
  10005. * document = None
  10006. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  10007. * document = self._compose_document() # <<<<<<<<<<<<<<
  10008. * self._parse_next_event()
  10009. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  10010. */
  10011. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_compose_document(__pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 707, __pyx_L1_error)
  10012. __Pyx_GOTREF(__pyx_t_3);
  10013. __Pyx_DECREF_SET(__pyx_v_document, __pyx_t_3);
  10014. __pyx_t_3 = 0;
  10015. /* "_yaml.pyx":706
  10016. * self._parse_next_event()
  10017. * document = None
  10018. * if self.parsed_event.type != YAML_STREAM_END_EVENT: # <<<<<<<<<<<<<<
  10019. * document = self._compose_document()
  10020. * self._parse_next_event()
  10021. */
  10022. }
  10023. /* "_yaml.pyx":708
  10024. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  10025. * document = self._compose_document()
  10026. * self._parse_next_event() # <<<<<<<<<<<<<<
  10027. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  10028. * mark = Mark(self.stream_name,
  10029. */
  10030. __pyx_t_1 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parse_next_event(__pyx_v_self); if (unlikely(__pyx_t_1 == ((int)0))) __PYX_ERR(0, 708, __pyx_L1_error)
  10031. /* "_yaml.pyx":709
  10032. * document = self._compose_document()
  10033. * self._parse_next_event()
  10034. * if self.parsed_event.type != YAML_STREAM_END_EVENT: # <<<<<<<<<<<<<<
  10035. * mark = Mark(self.stream_name,
  10036. * self.parsed_event.start_mark.index,
  10037. */
  10038. __pyx_t_2 = ((__pyx_v_self->parsed_event.type != YAML_STREAM_END_EVENT) != 0);
  10039. if (__pyx_t_2) {
  10040. /* "_yaml.pyx":711
  10041. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  10042. * mark = Mark(self.stream_name,
  10043. * self.parsed_event.start_mark.index, # <<<<<<<<<<<<<<
  10044. * self.parsed_event.start_mark.line,
  10045. * self.parsed_event.start_mark.column,
  10046. */
  10047. __pyx_t_3 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.index); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 711, __pyx_L1_error)
  10048. __Pyx_GOTREF(__pyx_t_3);
  10049. /* "_yaml.pyx":712
  10050. * mark = Mark(self.stream_name,
  10051. * self.parsed_event.start_mark.index,
  10052. * self.parsed_event.start_mark.line, # <<<<<<<<<<<<<<
  10053. * self.parsed_event.start_mark.column,
  10054. * None, None)
  10055. */
  10056. __pyx_t_4 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.line); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 712, __pyx_L1_error)
  10057. __Pyx_GOTREF(__pyx_t_4);
  10058. /* "_yaml.pyx":713
  10059. * self.parsed_event.start_mark.index,
  10060. * self.parsed_event.start_mark.line,
  10061. * self.parsed_event.start_mark.column, # <<<<<<<<<<<<<<
  10062. * None, None)
  10063. * if PY_MAJOR_VERSION < 3:
  10064. */
  10065. __pyx_t_5 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.column); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 713, __pyx_L1_error)
  10066. __Pyx_GOTREF(__pyx_t_5);
  10067. /* "_yaml.pyx":710
  10068. * self._parse_next_event()
  10069. * if self.parsed_event.type != YAML_STREAM_END_EVENT:
  10070. * mark = Mark(self.stream_name, # <<<<<<<<<<<<<<
  10071. * self.parsed_event.start_mark.index,
  10072. * self.parsed_event.start_mark.line,
  10073. */
  10074. __pyx_t_6 = PyTuple_New(6); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 710, __pyx_L1_error)
  10075. __Pyx_GOTREF(__pyx_t_6);
  10076. __Pyx_INCREF(__pyx_v_self->stream_name);
  10077. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  10078. PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_v_self->stream_name);
  10079. __Pyx_GIVEREF(__pyx_t_3);
  10080. PyTuple_SET_ITEM(__pyx_t_6, 1, __pyx_t_3);
  10081. __Pyx_GIVEREF(__pyx_t_4);
  10082. PyTuple_SET_ITEM(__pyx_t_6, 2, __pyx_t_4);
  10083. __Pyx_GIVEREF(__pyx_t_5);
  10084. PyTuple_SET_ITEM(__pyx_t_6, 3, __pyx_t_5);
  10085. __Pyx_INCREF(Py_None);
  10086. __Pyx_GIVEREF(Py_None);
  10087. PyTuple_SET_ITEM(__pyx_t_6, 4, Py_None);
  10088. __Pyx_INCREF(Py_None);
  10089. __Pyx_GIVEREF(Py_None);
  10090. PyTuple_SET_ITEM(__pyx_t_6, 5, Py_None);
  10091. __pyx_t_3 = 0;
  10092. __pyx_t_4 = 0;
  10093. __pyx_t_5 = 0;
  10094. __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_t_6, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 710, __pyx_L1_error)
  10095. __Pyx_GOTREF(__pyx_t_5);
  10096. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  10097. __pyx_v_mark = ((struct __pyx_obj_5_yaml_Mark *)__pyx_t_5);
  10098. __pyx_t_5 = 0;
  10099. /* "_yaml.pyx":715
  10100. * self.parsed_event.start_mark.column,
  10101. * None, None)
  10102. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  10103. * raise ComposerError("expected a single document in the stream",
  10104. * document.start_mark, "but found another document", mark)
  10105. */
  10106. __pyx_t_2 = ((PY_MAJOR_VERSION < 3) != 0);
  10107. if (unlikely(__pyx_t_2)) {
  10108. /* "_yaml.pyx":716
  10109. * None, None)
  10110. * if PY_MAJOR_VERSION < 3:
  10111. * raise ComposerError("expected a single document in the stream", # <<<<<<<<<<<<<<
  10112. * document.start_mark, "but found another document", mark)
  10113. * else:
  10114. */
  10115. __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_ComposerError); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 716, __pyx_L1_error)
  10116. __Pyx_GOTREF(__pyx_t_6);
  10117. /* "_yaml.pyx":717
  10118. * if PY_MAJOR_VERSION < 3:
  10119. * raise ComposerError("expected a single document in the stream",
  10120. * document.start_mark, "but found another document", mark) # <<<<<<<<<<<<<<
  10121. * else:
  10122. * raise ComposerError(u"expected a single document in the stream",
  10123. */
  10124. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_document, __pyx_n_s_start_mark); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 717, __pyx_L1_error)
  10125. __Pyx_GOTREF(__pyx_t_4);
  10126. __pyx_t_3 = NULL;
  10127. __pyx_t_1 = 0;
  10128. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) {
  10129. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_6);
  10130. if (likely(__pyx_t_3)) {
  10131. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6);
  10132. __Pyx_INCREF(__pyx_t_3);
  10133. __Pyx_INCREF(function);
  10134. __Pyx_DECREF_SET(__pyx_t_6, function);
  10135. __pyx_t_1 = 1;
  10136. }
  10137. }
  10138. #if CYTHON_FAST_PYCALL
  10139. if (PyFunction_Check(__pyx_t_6)) {
  10140. PyObject *__pyx_temp[5] = {__pyx_t_3, __pyx_kp_s_expected_a_single_document_in_th, __pyx_t_4, __pyx_kp_s_but_found_another_document, ((PyObject *)__pyx_v_mark)};
  10141. __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_1, 4+__pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 716, __pyx_L1_error)
  10142. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  10143. __Pyx_GOTREF(__pyx_t_5);
  10144. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  10145. } else
  10146. #endif
  10147. #if CYTHON_FAST_PYCCALL
  10148. if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) {
  10149. PyObject *__pyx_temp[5] = {__pyx_t_3, __pyx_kp_s_expected_a_single_document_in_th, __pyx_t_4, __pyx_kp_s_but_found_another_document, ((PyObject *)__pyx_v_mark)};
  10150. __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_1, 4+__pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 716, __pyx_L1_error)
  10151. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  10152. __Pyx_GOTREF(__pyx_t_5);
  10153. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  10154. } else
  10155. #endif
  10156. {
  10157. __pyx_t_7 = PyTuple_New(4+__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 716, __pyx_L1_error)
  10158. __Pyx_GOTREF(__pyx_t_7);
  10159. if (__pyx_t_3) {
  10160. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_3); __pyx_t_3 = NULL;
  10161. }
  10162. __Pyx_INCREF(__pyx_kp_s_expected_a_single_document_in_th);
  10163. __Pyx_GIVEREF(__pyx_kp_s_expected_a_single_document_in_th);
  10164. PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_1, __pyx_kp_s_expected_a_single_document_in_th);
  10165. __Pyx_GIVEREF(__pyx_t_4);
  10166. PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_1, __pyx_t_4);
  10167. __Pyx_INCREF(__pyx_kp_s_but_found_another_document);
  10168. __Pyx_GIVEREF(__pyx_kp_s_but_found_another_document);
  10169. PyTuple_SET_ITEM(__pyx_t_7, 2+__pyx_t_1, __pyx_kp_s_but_found_another_document);
  10170. __Pyx_INCREF(((PyObject *)__pyx_v_mark));
  10171. __Pyx_GIVEREF(((PyObject *)__pyx_v_mark));
  10172. PyTuple_SET_ITEM(__pyx_t_7, 3+__pyx_t_1, ((PyObject *)__pyx_v_mark));
  10173. __pyx_t_4 = 0;
  10174. __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_7, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 716, __pyx_L1_error)
  10175. __Pyx_GOTREF(__pyx_t_5);
  10176. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  10177. }
  10178. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  10179. __Pyx_Raise(__pyx_t_5, 0, 0, 0);
  10180. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  10181. __PYX_ERR(0, 716, __pyx_L1_error)
  10182. /* "_yaml.pyx":715
  10183. * self.parsed_event.start_mark.column,
  10184. * None, None)
  10185. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  10186. * raise ComposerError("expected a single document in the stream",
  10187. * document.start_mark, "but found another document", mark)
  10188. */
  10189. }
  10190. /* "_yaml.pyx":719
  10191. * document.start_mark, "but found another document", mark)
  10192. * else:
  10193. * raise ComposerError(u"expected a single document in the stream", # <<<<<<<<<<<<<<
  10194. * document.start_mark, u"but found another document", mark)
  10195. * return document
  10196. */
  10197. /*else*/ {
  10198. __Pyx_GetModuleGlobalName(__pyx_t_6, __pyx_n_s_ComposerError); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 719, __pyx_L1_error)
  10199. __Pyx_GOTREF(__pyx_t_6);
  10200. /* "_yaml.pyx":720
  10201. * else:
  10202. * raise ComposerError(u"expected a single document in the stream",
  10203. * document.start_mark, u"but found another document", mark) # <<<<<<<<<<<<<<
  10204. * return document
  10205. *
  10206. */
  10207. __pyx_t_7 = __Pyx_PyObject_GetAttrStr(__pyx_v_document, __pyx_n_s_start_mark); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 720, __pyx_L1_error)
  10208. __Pyx_GOTREF(__pyx_t_7);
  10209. __pyx_t_4 = NULL;
  10210. __pyx_t_1 = 0;
  10211. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_6))) {
  10212. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_6);
  10213. if (likely(__pyx_t_4)) {
  10214. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_6);
  10215. __Pyx_INCREF(__pyx_t_4);
  10216. __Pyx_INCREF(function);
  10217. __Pyx_DECREF_SET(__pyx_t_6, function);
  10218. __pyx_t_1 = 1;
  10219. }
  10220. }
  10221. #if CYTHON_FAST_PYCALL
  10222. if (PyFunction_Check(__pyx_t_6)) {
  10223. PyObject *__pyx_temp[5] = {__pyx_t_4, __pyx_kp_u_expected_a_single_document_in_th, __pyx_t_7, __pyx_kp_u_but_found_another_document, ((PyObject *)__pyx_v_mark)};
  10224. __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_1, 4+__pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 719, __pyx_L1_error)
  10225. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  10226. __Pyx_GOTREF(__pyx_t_5);
  10227. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  10228. } else
  10229. #endif
  10230. #if CYTHON_FAST_PYCCALL
  10231. if (__Pyx_PyFastCFunction_Check(__pyx_t_6)) {
  10232. PyObject *__pyx_temp[5] = {__pyx_t_4, __pyx_kp_u_expected_a_single_document_in_th, __pyx_t_7, __pyx_kp_u_but_found_another_document, ((PyObject *)__pyx_v_mark)};
  10233. __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_6, __pyx_temp+1-__pyx_t_1, 4+__pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 719, __pyx_L1_error)
  10234. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  10235. __Pyx_GOTREF(__pyx_t_5);
  10236. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  10237. } else
  10238. #endif
  10239. {
  10240. __pyx_t_3 = PyTuple_New(4+__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 719, __pyx_L1_error)
  10241. __Pyx_GOTREF(__pyx_t_3);
  10242. if (__pyx_t_4) {
  10243. __Pyx_GIVEREF(__pyx_t_4); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_4); __pyx_t_4 = NULL;
  10244. }
  10245. __Pyx_INCREF(__pyx_kp_u_expected_a_single_document_in_th);
  10246. __Pyx_GIVEREF(__pyx_kp_u_expected_a_single_document_in_th);
  10247. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_1, __pyx_kp_u_expected_a_single_document_in_th);
  10248. __Pyx_GIVEREF(__pyx_t_7);
  10249. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_1, __pyx_t_7);
  10250. __Pyx_INCREF(__pyx_kp_u_but_found_another_document);
  10251. __Pyx_GIVEREF(__pyx_kp_u_but_found_another_document);
  10252. PyTuple_SET_ITEM(__pyx_t_3, 2+__pyx_t_1, __pyx_kp_u_but_found_another_document);
  10253. __Pyx_INCREF(((PyObject *)__pyx_v_mark));
  10254. __Pyx_GIVEREF(((PyObject *)__pyx_v_mark));
  10255. PyTuple_SET_ITEM(__pyx_t_3, 3+__pyx_t_1, ((PyObject *)__pyx_v_mark));
  10256. __pyx_t_7 = 0;
  10257. __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_6, __pyx_t_3, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 719, __pyx_L1_error)
  10258. __Pyx_GOTREF(__pyx_t_5);
  10259. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  10260. }
  10261. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  10262. __Pyx_Raise(__pyx_t_5, 0, 0, 0);
  10263. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  10264. __PYX_ERR(0, 719, __pyx_L1_error)
  10265. }
  10266. /* "_yaml.pyx":709
  10267. * document = self._compose_document()
  10268. * self._parse_next_event()
  10269. * if self.parsed_event.type != YAML_STREAM_END_EVENT: # <<<<<<<<<<<<<<
  10270. * mark = Mark(self.stream_name,
  10271. * self.parsed_event.start_mark.index,
  10272. */
  10273. }
  10274. /* "_yaml.pyx":721
  10275. * raise ComposerError(u"expected a single document in the stream",
  10276. * document.start_mark, u"but found another document", mark)
  10277. * return document # <<<<<<<<<<<<<<
  10278. *
  10279. * cdef object _compose_document(self):
  10280. */
  10281. __Pyx_XDECREF(__pyx_r);
  10282. __Pyx_INCREF(__pyx_v_document);
  10283. __pyx_r = __pyx_v_document;
  10284. goto __pyx_L0;
  10285. /* "_yaml.pyx":701
  10286. * return self._compose_document()
  10287. *
  10288. * def get_single_node(self): # <<<<<<<<<<<<<<
  10289. * self._parse_next_event()
  10290. * yaml_event_delete(&self.parsed_event)
  10291. */
  10292. /* function exit code */
  10293. __pyx_L1_error:;
  10294. __Pyx_XDECREF(__pyx_t_3);
  10295. __Pyx_XDECREF(__pyx_t_4);
  10296. __Pyx_XDECREF(__pyx_t_5);
  10297. __Pyx_XDECREF(__pyx_t_6);
  10298. __Pyx_XDECREF(__pyx_t_7);
  10299. __Pyx_AddTraceback("_yaml.CParser.get_single_node", __pyx_clineno, __pyx_lineno, __pyx_filename);
  10300. __pyx_r = NULL;
  10301. __pyx_L0:;
  10302. __Pyx_XDECREF(__pyx_v_document);
  10303. __Pyx_XDECREF((PyObject *)__pyx_v_mark);
  10304. __Pyx_XGIVEREF(__pyx_r);
  10305. __Pyx_RefNannyFinishContext();
  10306. return __pyx_r;
  10307. }
  10308. /* "_yaml.pyx":723
  10309. * return document
  10310. *
  10311. * cdef object _compose_document(self): # <<<<<<<<<<<<<<
  10312. * yaml_event_delete(&self.parsed_event)
  10313. * node = self._compose_node(None, None)
  10314. */
  10315. static PyObject *__pyx_f_5_yaml_7CParser__compose_document(struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  10316. PyObject *__pyx_v_node = NULL;
  10317. PyObject *__pyx_r = NULL;
  10318. __Pyx_RefNannyDeclarations
  10319. PyObject *__pyx_t_1 = NULL;
  10320. int __pyx_t_2;
  10321. __Pyx_RefNannySetupContext("_compose_document", 0);
  10322. /* "_yaml.pyx":724
  10323. *
  10324. * cdef object _compose_document(self):
  10325. * yaml_event_delete(&self.parsed_event) # <<<<<<<<<<<<<<
  10326. * node = self._compose_node(None, None)
  10327. * self._parse_next_event()
  10328. */
  10329. yaml_event_delete((&__pyx_v_self->parsed_event));
  10330. /* "_yaml.pyx":725
  10331. * cdef object _compose_document(self):
  10332. * yaml_event_delete(&self.parsed_event)
  10333. * node = self._compose_node(None, None) # <<<<<<<<<<<<<<
  10334. * self._parse_next_event()
  10335. * yaml_event_delete(&self.parsed_event)
  10336. */
  10337. __pyx_t_1 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_compose_node(__pyx_v_self, Py_None, Py_None); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 725, __pyx_L1_error)
  10338. __Pyx_GOTREF(__pyx_t_1);
  10339. __pyx_v_node = __pyx_t_1;
  10340. __pyx_t_1 = 0;
  10341. /* "_yaml.pyx":726
  10342. * yaml_event_delete(&self.parsed_event)
  10343. * node = self._compose_node(None, None)
  10344. * self._parse_next_event() # <<<<<<<<<<<<<<
  10345. * yaml_event_delete(&self.parsed_event)
  10346. * self.anchors = {}
  10347. */
  10348. __pyx_t_2 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parse_next_event(__pyx_v_self); if (unlikely(__pyx_t_2 == ((int)0))) __PYX_ERR(0, 726, __pyx_L1_error)
  10349. /* "_yaml.pyx":727
  10350. * node = self._compose_node(None, None)
  10351. * self._parse_next_event()
  10352. * yaml_event_delete(&self.parsed_event) # <<<<<<<<<<<<<<
  10353. * self.anchors = {}
  10354. * return node
  10355. */
  10356. yaml_event_delete((&__pyx_v_self->parsed_event));
  10357. /* "_yaml.pyx":728
  10358. * self._parse_next_event()
  10359. * yaml_event_delete(&self.parsed_event)
  10360. * self.anchors = {} # <<<<<<<<<<<<<<
  10361. * return node
  10362. *
  10363. */
  10364. __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 728, __pyx_L1_error)
  10365. __Pyx_GOTREF(__pyx_t_1);
  10366. __Pyx_GIVEREF(__pyx_t_1);
  10367. __Pyx_GOTREF(__pyx_v_self->anchors);
  10368. __Pyx_DECREF(__pyx_v_self->anchors);
  10369. __pyx_v_self->anchors = __pyx_t_1;
  10370. __pyx_t_1 = 0;
  10371. /* "_yaml.pyx":729
  10372. * yaml_event_delete(&self.parsed_event)
  10373. * self.anchors = {}
  10374. * return node # <<<<<<<<<<<<<<
  10375. *
  10376. * cdef object _compose_node(self, object parent, object index):
  10377. */
  10378. __Pyx_XDECREF(__pyx_r);
  10379. __Pyx_INCREF(__pyx_v_node);
  10380. __pyx_r = __pyx_v_node;
  10381. goto __pyx_L0;
  10382. /* "_yaml.pyx":723
  10383. * return document
  10384. *
  10385. * cdef object _compose_document(self): # <<<<<<<<<<<<<<
  10386. * yaml_event_delete(&self.parsed_event)
  10387. * node = self._compose_node(None, None)
  10388. */
  10389. /* function exit code */
  10390. __pyx_L1_error:;
  10391. __Pyx_XDECREF(__pyx_t_1);
  10392. __Pyx_AddTraceback("_yaml.CParser._compose_document", __pyx_clineno, __pyx_lineno, __pyx_filename);
  10393. __pyx_r = 0;
  10394. __pyx_L0:;
  10395. __Pyx_XDECREF(__pyx_v_node);
  10396. __Pyx_XGIVEREF(__pyx_r);
  10397. __Pyx_RefNannyFinishContext();
  10398. return __pyx_r;
  10399. }
  10400. /* "_yaml.pyx":731
  10401. * return node
  10402. *
  10403. * cdef object _compose_node(self, object parent, object index): # <<<<<<<<<<<<<<
  10404. * self._parse_next_event()
  10405. * if self.parsed_event.type == YAML_ALIAS_EVENT:
  10406. */
  10407. static PyObject *__pyx_f_5_yaml_7CParser__compose_node(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, PyObject *__pyx_v_parent, PyObject *__pyx_v_index) {
  10408. PyObject *__pyx_v_anchor = NULL;
  10409. struct __pyx_obj_5_yaml_Mark *__pyx_v_mark = NULL;
  10410. PyObject *__pyx_v_node = NULL;
  10411. PyObject *__pyx_r = NULL;
  10412. __Pyx_RefNannyDeclarations
  10413. int __pyx_t_1;
  10414. int __pyx_t_2;
  10415. PyObject *__pyx_t_3 = NULL;
  10416. int __pyx_t_4;
  10417. PyObject *__pyx_t_5 = NULL;
  10418. PyObject *__pyx_t_6 = NULL;
  10419. PyObject *__pyx_t_7 = NULL;
  10420. PyObject *__pyx_t_8 = NULL;
  10421. __Pyx_RefNannySetupContext("_compose_node", 0);
  10422. /* "_yaml.pyx":732
  10423. *
  10424. * cdef object _compose_node(self, object parent, object index):
  10425. * self._parse_next_event() # <<<<<<<<<<<<<<
  10426. * if self.parsed_event.type == YAML_ALIAS_EVENT:
  10427. * anchor = PyUnicode_FromString(self.parsed_event.data.alias.anchor)
  10428. */
  10429. __pyx_t_1 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parse_next_event(__pyx_v_self); if (unlikely(__pyx_t_1 == ((int)0))) __PYX_ERR(0, 732, __pyx_L1_error)
  10430. /* "_yaml.pyx":733
  10431. * cdef object _compose_node(self, object parent, object index):
  10432. * self._parse_next_event()
  10433. * if self.parsed_event.type == YAML_ALIAS_EVENT: # <<<<<<<<<<<<<<
  10434. * anchor = PyUnicode_FromString(self.parsed_event.data.alias.anchor)
  10435. * if anchor not in self.anchors:
  10436. */
  10437. __pyx_t_2 = ((__pyx_v_self->parsed_event.type == YAML_ALIAS_EVENT) != 0);
  10438. if (__pyx_t_2) {
  10439. /* "_yaml.pyx":734
  10440. * self._parse_next_event()
  10441. * if self.parsed_event.type == YAML_ALIAS_EVENT:
  10442. * anchor = PyUnicode_FromString(self.parsed_event.data.alias.anchor) # <<<<<<<<<<<<<<
  10443. * if anchor not in self.anchors:
  10444. * mark = Mark(self.stream_name,
  10445. */
  10446. __pyx_t_3 = PyUnicode_FromString(__pyx_v_self->parsed_event.data.alias.anchor); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 734, __pyx_L1_error)
  10447. __Pyx_GOTREF(__pyx_t_3);
  10448. __pyx_v_anchor = __pyx_t_3;
  10449. __pyx_t_3 = 0;
  10450. /* "_yaml.pyx":735
  10451. * if self.parsed_event.type == YAML_ALIAS_EVENT:
  10452. * anchor = PyUnicode_FromString(self.parsed_event.data.alias.anchor)
  10453. * if anchor not in self.anchors: # <<<<<<<<<<<<<<
  10454. * mark = Mark(self.stream_name,
  10455. * self.parsed_event.start_mark.index,
  10456. */
  10457. __pyx_t_2 = (__Pyx_PySequence_ContainsTF(__pyx_v_anchor, __pyx_v_self->anchors, Py_NE)); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 735, __pyx_L1_error)
  10458. __pyx_t_4 = (__pyx_t_2 != 0);
  10459. if (__pyx_t_4) {
  10460. /* "_yaml.pyx":737
  10461. * if anchor not in self.anchors:
  10462. * mark = Mark(self.stream_name,
  10463. * self.parsed_event.start_mark.index, # <<<<<<<<<<<<<<
  10464. * self.parsed_event.start_mark.line,
  10465. * self.parsed_event.start_mark.column,
  10466. */
  10467. __pyx_t_3 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.index); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 737, __pyx_L1_error)
  10468. __Pyx_GOTREF(__pyx_t_3);
  10469. /* "_yaml.pyx":738
  10470. * mark = Mark(self.stream_name,
  10471. * self.parsed_event.start_mark.index,
  10472. * self.parsed_event.start_mark.line, # <<<<<<<<<<<<<<
  10473. * self.parsed_event.start_mark.column,
  10474. * None, None)
  10475. */
  10476. __pyx_t_5 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.line); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 738, __pyx_L1_error)
  10477. __Pyx_GOTREF(__pyx_t_5);
  10478. /* "_yaml.pyx":739
  10479. * self.parsed_event.start_mark.index,
  10480. * self.parsed_event.start_mark.line,
  10481. * self.parsed_event.start_mark.column, # <<<<<<<<<<<<<<
  10482. * None, None)
  10483. * if PY_MAJOR_VERSION < 3:
  10484. */
  10485. __pyx_t_6 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.column); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 739, __pyx_L1_error)
  10486. __Pyx_GOTREF(__pyx_t_6);
  10487. /* "_yaml.pyx":736
  10488. * anchor = PyUnicode_FromString(self.parsed_event.data.alias.anchor)
  10489. * if anchor not in self.anchors:
  10490. * mark = Mark(self.stream_name, # <<<<<<<<<<<<<<
  10491. * self.parsed_event.start_mark.index,
  10492. * self.parsed_event.start_mark.line,
  10493. */
  10494. __pyx_t_7 = PyTuple_New(6); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 736, __pyx_L1_error)
  10495. __Pyx_GOTREF(__pyx_t_7);
  10496. __Pyx_INCREF(__pyx_v_self->stream_name);
  10497. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  10498. PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_v_self->stream_name);
  10499. __Pyx_GIVEREF(__pyx_t_3);
  10500. PyTuple_SET_ITEM(__pyx_t_7, 1, __pyx_t_3);
  10501. __Pyx_GIVEREF(__pyx_t_5);
  10502. PyTuple_SET_ITEM(__pyx_t_7, 2, __pyx_t_5);
  10503. __Pyx_GIVEREF(__pyx_t_6);
  10504. PyTuple_SET_ITEM(__pyx_t_7, 3, __pyx_t_6);
  10505. __Pyx_INCREF(Py_None);
  10506. __Pyx_GIVEREF(Py_None);
  10507. PyTuple_SET_ITEM(__pyx_t_7, 4, Py_None);
  10508. __Pyx_INCREF(Py_None);
  10509. __Pyx_GIVEREF(Py_None);
  10510. PyTuple_SET_ITEM(__pyx_t_7, 5, Py_None);
  10511. __pyx_t_3 = 0;
  10512. __pyx_t_5 = 0;
  10513. __pyx_t_6 = 0;
  10514. __pyx_t_6 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_t_7, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 736, __pyx_L1_error)
  10515. __Pyx_GOTREF(__pyx_t_6);
  10516. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  10517. __pyx_v_mark = ((struct __pyx_obj_5_yaml_Mark *)__pyx_t_6);
  10518. __pyx_t_6 = 0;
  10519. /* "_yaml.pyx":741
  10520. * self.parsed_event.start_mark.column,
  10521. * None, None)
  10522. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  10523. * raise ComposerError(None, None, "found undefined alias", mark)
  10524. * else:
  10525. */
  10526. __pyx_t_4 = ((PY_MAJOR_VERSION < 3) != 0);
  10527. if (unlikely(__pyx_t_4)) {
  10528. /* "_yaml.pyx":742
  10529. * None, None)
  10530. * if PY_MAJOR_VERSION < 3:
  10531. * raise ComposerError(None, None, "found undefined alias", mark) # <<<<<<<<<<<<<<
  10532. * else:
  10533. * raise ComposerError(None, None, u"found undefined alias", mark)
  10534. */
  10535. __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_ComposerError); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 742, __pyx_L1_error)
  10536. __Pyx_GOTREF(__pyx_t_7);
  10537. __pyx_t_5 = NULL;
  10538. __pyx_t_1 = 0;
  10539. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_7))) {
  10540. __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_7);
  10541. if (likely(__pyx_t_5)) {
  10542. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7);
  10543. __Pyx_INCREF(__pyx_t_5);
  10544. __Pyx_INCREF(function);
  10545. __Pyx_DECREF_SET(__pyx_t_7, function);
  10546. __pyx_t_1 = 1;
  10547. }
  10548. }
  10549. #if CYTHON_FAST_PYCALL
  10550. if (PyFunction_Check(__pyx_t_7)) {
  10551. PyObject *__pyx_temp[5] = {__pyx_t_5, Py_None, Py_None, __pyx_kp_s_found_undefined_alias, ((PyObject *)__pyx_v_mark)};
  10552. __pyx_t_6 = __Pyx_PyFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_1, 4+__pyx_t_1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 742, __pyx_L1_error)
  10553. __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
  10554. __Pyx_GOTREF(__pyx_t_6);
  10555. } else
  10556. #endif
  10557. #if CYTHON_FAST_PYCCALL
  10558. if (__Pyx_PyFastCFunction_Check(__pyx_t_7)) {
  10559. PyObject *__pyx_temp[5] = {__pyx_t_5, Py_None, Py_None, __pyx_kp_s_found_undefined_alias, ((PyObject *)__pyx_v_mark)};
  10560. __pyx_t_6 = __Pyx_PyCFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_1, 4+__pyx_t_1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 742, __pyx_L1_error)
  10561. __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
  10562. __Pyx_GOTREF(__pyx_t_6);
  10563. } else
  10564. #endif
  10565. {
  10566. __pyx_t_3 = PyTuple_New(4+__pyx_t_1); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 742, __pyx_L1_error)
  10567. __Pyx_GOTREF(__pyx_t_3);
  10568. if (__pyx_t_5) {
  10569. __Pyx_GIVEREF(__pyx_t_5); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_5); __pyx_t_5 = NULL;
  10570. }
  10571. __Pyx_INCREF(Py_None);
  10572. __Pyx_GIVEREF(Py_None);
  10573. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_1, Py_None);
  10574. __Pyx_INCREF(Py_None);
  10575. __Pyx_GIVEREF(Py_None);
  10576. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_1, Py_None);
  10577. __Pyx_INCREF(__pyx_kp_s_found_undefined_alias);
  10578. __Pyx_GIVEREF(__pyx_kp_s_found_undefined_alias);
  10579. PyTuple_SET_ITEM(__pyx_t_3, 2+__pyx_t_1, __pyx_kp_s_found_undefined_alias);
  10580. __Pyx_INCREF(((PyObject *)__pyx_v_mark));
  10581. __Pyx_GIVEREF(((PyObject *)__pyx_v_mark));
  10582. PyTuple_SET_ITEM(__pyx_t_3, 3+__pyx_t_1, ((PyObject *)__pyx_v_mark));
  10583. __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_3, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 742, __pyx_L1_error)
  10584. __Pyx_GOTREF(__pyx_t_6);
  10585. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  10586. }
  10587. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  10588. __Pyx_Raise(__pyx_t_6, 0, 0, 0);
  10589. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  10590. __PYX_ERR(0, 742, __pyx_L1_error)
  10591. /* "_yaml.pyx":741
  10592. * self.parsed_event.start_mark.column,
  10593. * None, None)
  10594. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  10595. * raise ComposerError(None, None, "found undefined alias", mark)
  10596. * else:
  10597. */
  10598. }
  10599. /* "_yaml.pyx":744
  10600. * raise ComposerError(None, None, "found undefined alias", mark)
  10601. * else:
  10602. * raise ComposerError(None, None, u"found undefined alias", mark) # <<<<<<<<<<<<<<
  10603. * yaml_event_delete(&self.parsed_event)
  10604. * return self.anchors[anchor]
  10605. */
  10606. /*else*/ {
  10607. __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_ComposerError); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 744, __pyx_L1_error)
  10608. __Pyx_GOTREF(__pyx_t_7);
  10609. __pyx_t_3 = NULL;
  10610. __pyx_t_1 = 0;
  10611. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_7))) {
  10612. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_7);
  10613. if (likely(__pyx_t_3)) {
  10614. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_7);
  10615. __Pyx_INCREF(__pyx_t_3);
  10616. __Pyx_INCREF(function);
  10617. __Pyx_DECREF_SET(__pyx_t_7, function);
  10618. __pyx_t_1 = 1;
  10619. }
  10620. }
  10621. #if CYTHON_FAST_PYCALL
  10622. if (PyFunction_Check(__pyx_t_7)) {
  10623. PyObject *__pyx_temp[5] = {__pyx_t_3, Py_None, Py_None, __pyx_kp_u_found_undefined_alias, ((PyObject *)__pyx_v_mark)};
  10624. __pyx_t_6 = __Pyx_PyFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_1, 4+__pyx_t_1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 744, __pyx_L1_error)
  10625. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  10626. __Pyx_GOTREF(__pyx_t_6);
  10627. } else
  10628. #endif
  10629. #if CYTHON_FAST_PYCCALL
  10630. if (__Pyx_PyFastCFunction_Check(__pyx_t_7)) {
  10631. PyObject *__pyx_temp[5] = {__pyx_t_3, Py_None, Py_None, __pyx_kp_u_found_undefined_alias, ((PyObject *)__pyx_v_mark)};
  10632. __pyx_t_6 = __Pyx_PyCFunction_FastCall(__pyx_t_7, __pyx_temp+1-__pyx_t_1, 4+__pyx_t_1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 744, __pyx_L1_error)
  10633. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  10634. __Pyx_GOTREF(__pyx_t_6);
  10635. } else
  10636. #endif
  10637. {
  10638. __pyx_t_5 = PyTuple_New(4+__pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 744, __pyx_L1_error)
  10639. __Pyx_GOTREF(__pyx_t_5);
  10640. if (__pyx_t_3) {
  10641. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_5, 0, __pyx_t_3); __pyx_t_3 = NULL;
  10642. }
  10643. __Pyx_INCREF(Py_None);
  10644. __Pyx_GIVEREF(Py_None);
  10645. PyTuple_SET_ITEM(__pyx_t_5, 0+__pyx_t_1, Py_None);
  10646. __Pyx_INCREF(Py_None);
  10647. __Pyx_GIVEREF(Py_None);
  10648. PyTuple_SET_ITEM(__pyx_t_5, 1+__pyx_t_1, Py_None);
  10649. __Pyx_INCREF(__pyx_kp_u_found_undefined_alias);
  10650. __Pyx_GIVEREF(__pyx_kp_u_found_undefined_alias);
  10651. PyTuple_SET_ITEM(__pyx_t_5, 2+__pyx_t_1, __pyx_kp_u_found_undefined_alias);
  10652. __Pyx_INCREF(((PyObject *)__pyx_v_mark));
  10653. __Pyx_GIVEREF(((PyObject *)__pyx_v_mark));
  10654. PyTuple_SET_ITEM(__pyx_t_5, 3+__pyx_t_1, ((PyObject *)__pyx_v_mark));
  10655. __pyx_t_6 = __Pyx_PyObject_Call(__pyx_t_7, __pyx_t_5, NULL); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 744, __pyx_L1_error)
  10656. __Pyx_GOTREF(__pyx_t_6);
  10657. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  10658. }
  10659. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  10660. __Pyx_Raise(__pyx_t_6, 0, 0, 0);
  10661. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  10662. __PYX_ERR(0, 744, __pyx_L1_error)
  10663. }
  10664. /* "_yaml.pyx":735
  10665. * if self.parsed_event.type == YAML_ALIAS_EVENT:
  10666. * anchor = PyUnicode_FromString(self.parsed_event.data.alias.anchor)
  10667. * if anchor not in self.anchors: # <<<<<<<<<<<<<<
  10668. * mark = Mark(self.stream_name,
  10669. * self.parsed_event.start_mark.index,
  10670. */
  10671. }
  10672. /* "_yaml.pyx":745
  10673. * else:
  10674. * raise ComposerError(None, None, u"found undefined alias", mark)
  10675. * yaml_event_delete(&self.parsed_event) # <<<<<<<<<<<<<<
  10676. * return self.anchors[anchor]
  10677. * anchor = None
  10678. */
  10679. yaml_event_delete((&__pyx_v_self->parsed_event));
  10680. /* "_yaml.pyx":746
  10681. * raise ComposerError(None, None, u"found undefined alias", mark)
  10682. * yaml_event_delete(&self.parsed_event)
  10683. * return self.anchors[anchor] # <<<<<<<<<<<<<<
  10684. * anchor = None
  10685. * if self.parsed_event.type == YAML_SCALAR_EVENT \
  10686. */
  10687. __Pyx_XDECREF(__pyx_r);
  10688. __pyx_t_6 = __Pyx_PyObject_GetItem(__pyx_v_self->anchors, __pyx_v_anchor); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 746, __pyx_L1_error)
  10689. __Pyx_GOTREF(__pyx_t_6);
  10690. __pyx_r = __pyx_t_6;
  10691. __pyx_t_6 = 0;
  10692. goto __pyx_L0;
  10693. /* "_yaml.pyx":733
  10694. * cdef object _compose_node(self, object parent, object index):
  10695. * self._parse_next_event()
  10696. * if self.parsed_event.type == YAML_ALIAS_EVENT: # <<<<<<<<<<<<<<
  10697. * anchor = PyUnicode_FromString(self.parsed_event.data.alias.anchor)
  10698. * if anchor not in self.anchors:
  10699. */
  10700. }
  10701. /* "_yaml.pyx":747
  10702. * yaml_event_delete(&self.parsed_event)
  10703. * return self.anchors[anchor]
  10704. * anchor = None # <<<<<<<<<<<<<<
  10705. * if self.parsed_event.type == YAML_SCALAR_EVENT \
  10706. * and self.parsed_event.data.scalar.anchor != NULL:
  10707. */
  10708. __Pyx_INCREF(Py_None);
  10709. __pyx_v_anchor = Py_None;
  10710. /* "_yaml.pyx":748
  10711. * return self.anchors[anchor]
  10712. * anchor = None
  10713. * if self.parsed_event.type == YAML_SCALAR_EVENT \ # <<<<<<<<<<<<<<
  10714. * and self.parsed_event.data.scalar.anchor != NULL:
  10715. * anchor = PyUnicode_FromString(self.parsed_event.data.scalar.anchor)
  10716. */
  10717. __pyx_t_2 = ((__pyx_v_self->parsed_event.type == YAML_SCALAR_EVENT) != 0);
  10718. if (__pyx_t_2) {
  10719. } else {
  10720. __pyx_t_4 = __pyx_t_2;
  10721. goto __pyx_L7_bool_binop_done;
  10722. }
  10723. /* "_yaml.pyx":749
  10724. * anchor = None
  10725. * if self.parsed_event.type == YAML_SCALAR_EVENT \
  10726. * and self.parsed_event.data.scalar.anchor != NULL: # <<<<<<<<<<<<<<
  10727. * anchor = PyUnicode_FromString(self.parsed_event.data.scalar.anchor)
  10728. * elif self.parsed_event.type == YAML_SEQUENCE_START_EVENT \
  10729. */
  10730. __pyx_t_2 = ((__pyx_v_self->parsed_event.data.scalar.anchor != NULL) != 0);
  10731. __pyx_t_4 = __pyx_t_2;
  10732. __pyx_L7_bool_binop_done:;
  10733. /* "_yaml.pyx":748
  10734. * return self.anchors[anchor]
  10735. * anchor = None
  10736. * if self.parsed_event.type == YAML_SCALAR_EVENT \ # <<<<<<<<<<<<<<
  10737. * and self.parsed_event.data.scalar.anchor != NULL:
  10738. * anchor = PyUnicode_FromString(self.parsed_event.data.scalar.anchor)
  10739. */
  10740. if (__pyx_t_4) {
  10741. /* "_yaml.pyx":750
  10742. * if self.parsed_event.type == YAML_SCALAR_EVENT \
  10743. * and self.parsed_event.data.scalar.anchor != NULL:
  10744. * anchor = PyUnicode_FromString(self.parsed_event.data.scalar.anchor) # <<<<<<<<<<<<<<
  10745. * elif self.parsed_event.type == YAML_SEQUENCE_START_EVENT \
  10746. * and self.parsed_event.data.sequence_start.anchor != NULL:
  10747. */
  10748. __pyx_t_6 = PyUnicode_FromString(__pyx_v_self->parsed_event.data.scalar.anchor); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 750, __pyx_L1_error)
  10749. __Pyx_GOTREF(__pyx_t_6);
  10750. __Pyx_DECREF_SET(__pyx_v_anchor, __pyx_t_6);
  10751. __pyx_t_6 = 0;
  10752. /* "_yaml.pyx":748
  10753. * return self.anchors[anchor]
  10754. * anchor = None
  10755. * if self.parsed_event.type == YAML_SCALAR_EVENT \ # <<<<<<<<<<<<<<
  10756. * and self.parsed_event.data.scalar.anchor != NULL:
  10757. * anchor = PyUnicode_FromString(self.parsed_event.data.scalar.anchor)
  10758. */
  10759. goto __pyx_L6;
  10760. }
  10761. /* "_yaml.pyx":751
  10762. * and self.parsed_event.data.scalar.anchor != NULL:
  10763. * anchor = PyUnicode_FromString(self.parsed_event.data.scalar.anchor)
  10764. * elif self.parsed_event.type == YAML_SEQUENCE_START_EVENT \ # <<<<<<<<<<<<<<
  10765. * and self.parsed_event.data.sequence_start.anchor != NULL:
  10766. * anchor = PyUnicode_FromString(self.parsed_event.data.sequence_start.anchor)
  10767. */
  10768. __pyx_t_2 = ((__pyx_v_self->parsed_event.type == YAML_SEQUENCE_START_EVENT) != 0);
  10769. if (__pyx_t_2) {
  10770. } else {
  10771. __pyx_t_4 = __pyx_t_2;
  10772. goto __pyx_L9_bool_binop_done;
  10773. }
  10774. /* "_yaml.pyx":752
  10775. * anchor = PyUnicode_FromString(self.parsed_event.data.scalar.anchor)
  10776. * elif self.parsed_event.type == YAML_SEQUENCE_START_EVENT \
  10777. * and self.parsed_event.data.sequence_start.anchor != NULL: # <<<<<<<<<<<<<<
  10778. * anchor = PyUnicode_FromString(self.parsed_event.data.sequence_start.anchor)
  10779. * elif self.parsed_event.type == YAML_MAPPING_START_EVENT \
  10780. */
  10781. __pyx_t_2 = ((__pyx_v_self->parsed_event.data.sequence_start.anchor != NULL) != 0);
  10782. __pyx_t_4 = __pyx_t_2;
  10783. __pyx_L9_bool_binop_done:;
  10784. /* "_yaml.pyx":751
  10785. * and self.parsed_event.data.scalar.anchor != NULL:
  10786. * anchor = PyUnicode_FromString(self.parsed_event.data.scalar.anchor)
  10787. * elif self.parsed_event.type == YAML_SEQUENCE_START_EVENT \ # <<<<<<<<<<<<<<
  10788. * and self.parsed_event.data.sequence_start.anchor != NULL:
  10789. * anchor = PyUnicode_FromString(self.parsed_event.data.sequence_start.anchor)
  10790. */
  10791. if (__pyx_t_4) {
  10792. /* "_yaml.pyx":753
  10793. * elif self.parsed_event.type == YAML_SEQUENCE_START_EVENT \
  10794. * and self.parsed_event.data.sequence_start.anchor != NULL:
  10795. * anchor = PyUnicode_FromString(self.parsed_event.data.sequence_start.anchor) # <<<<<<<<<<<<<<
  10796. * elif self.parsed_event.type == YAML_MAPPING_START_EVENT \
  10797. * and self.parsed_event.data.mapping_start.anchor != NULL:
  10798. */
  10799. __pyx_t_6 = PyUnicode_FromString(__pyx_v_self->parsed_event.data.sequence_start.anchor); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 753, __pyx_L1_error)
  10800. __Pyx_GOTREF(__pyx_t_6);
  10801. __Pyx_DECREF_SET(__pyx_v_anchor, __pyx_t_6);
  10802. __pyx_t_6 = 0;
  10803. /* "_yaml.pyx":751
  10804. * and self.parsed_event.data.scalar.anchor != NULL:
  10805. * anchor = PyUnicode_FromString(self.parsed_event.data.scalar.anchor)
  10806. * elif self.parsed_event.type == YAML_SEQUENCE_START_EVENT \ # <<<<<<<<<<<<<<
  10807. * and self.parsed_event.data.sequence_start.anchor != NULL:
  10808. * anchor = PyUnicode_FromString(self.parsed_event.data.sequence_start.anchor)
  10809. */
  10810. goto __pyx_L6;
  10811. }
  10812. /* "_yaml.pyx":754
  10813. * and self.parsed_event.data.sequence_start.anchor != NULL:
  10814. * anchor = PyUnicode_FromString(self.parsed_event.data.sequence_start.anchor)
  10815. * elif self.parsed_event.type == YAML_MAPPING_START_EVENT \ # <<<<<<<<<<<<<<
  10816. * and self.parsed_event.data.mapping_start.anchor != NULL:
  10817. * anchor = PyUnicode_FromString(self.parsed_event.data.mapping_start.anchor)
  10818. */
  10819. __pyx_t_2 = ((__pyx_v_self->parsed_event.type == YAML_MAPPING_START_EVENT) != 0);
  10820. if (__pyx_t_2) {
  10821. } else {
  10822. __pyx_t_4 = __pyx_t_2;
  10823. goto __pyx_L11_bool_binop_done;
  10824. }
  10825. /* "_yaml.pyx":755
  10826. * anchor = PyUnicode_FromString(self.parsed_event.data.sequence_start.anchor)
  10827. * elif self.parsed_event.type == YAML_MAPPING_START_EVENT \
  10828. * and self.parsed_event.data.mapping_start.anchor != NULL: # <<<<<<<<<<<<<<
  10829. * anchor = PyUnicode_FromString(self.parsed_event.data.mapping_start.anchor)
  10830. * if anchor is not None:
  10831. */
  10832. __pyx_t_2 = ((__pyx_v_self->parsed_event.data.mapping_start.anchor != NULL) != 0);
  10833. __pyx_t_4 = __pyx_t_2;
  10834. __pyx_L11_bool_binop_done:;
  10835. /* "_yaml.pyx":754
  10836. * and self.parsed_event.data.sequence_start.anchor != NULL:
  10837. * anchor = PyUnicode_FromString(self.parsed_event.data.sequence_start.anchor)
  10838. * elif self.parsed_event.type == YAML_MAPPING_START_EVENT \ # <<<<<<<<<<<<<<
  10839. * and self.parsed_event.data.mapping_start.anchor != NULL:
  10840. * anchor = PyUnicode_FromString(self.parsed_event.data.mapping_start.anchor)
  10841. */
  10842. if (__pyx_t_4) {
  10843. /* "_yaml.pyx":756
  10844. * elif self.parsed_event.type == YAML_MAPPING_START_EVENT \
  10845. * and self.parsed_event.data.mapping_start.anchor != NULL:
  10846. * anchor = PyUnicode_FromString(self.parsed_event.data.mapping_start.anchor) # <<<<<<<<<<<<<<
  10847. * if anchor is not None:
  10848. * if anchor in self.anchors:
  10849. */
  10850. __pyx_t_6 = PyUnicode_FromString(__pyx_v_self->parsed_event.data.mapping_start.anchor); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 756, __pyx_L1_error)
  10851. __Pyx_GOTREF(__pyx_t_6);
  10852. __Pyx_DECREF_SET(__pyx_v_anchor, __pyx_t_6);
  10853. __pyx_t_6 = 0;
  10854. /* "_yaml.pyx":754
  10855. * and self.parsed_event.data.sequence_start.anchor != NULL:
  10856. * anchor = PyUnicode_FromString(self.parsed_event.data.sequence_start.anchor)
  10857. * elif self.parsed_event.type == YAML_MAPPING_START_EVENT \ # <<<<<<<<<<<<<<
  10858. * and self.parsed_event.data.mapping_start.anchor != NULL:
  10859. * anchor = PyUnicode_FromString(self.parsed_event.data.mapping_start.anchor)
  10860. */
  10861. }
  10862. __pyx_L6:;
  10863. /* "_yaml.pyx":757
  10864. * and self.parsed_event.data.mapping_start.anchor != NULL:
  10865. * anchor = PyUnicode_FromString(self.parsed_event.data.mapping_start.anchor)
  10866. * if anchor is not None: # <<<<<<<<<<<<<<
  10867. * if anchor in self.anchors:
  10868. * mark = Mark(self.stream_name,
  10869. */
  10870. __pyx_t_4 = (__pyx_v_anchor != Py_None);
  10871. __pyx_t_2 = (__pyx_t_4 != 0);
  10872. if (__pyx_t_2) {
  10873. /* "_yaml.pyx":758
  10874. * anchor = PyUnicode_FromString(self.parsed_event.data.mapping_start.anchor)
  10875. * if anchor is not None:
  10876. * if anchor in self.anchors: # <<<<<<<<<<<<<<
  10877. * mark = Mark(self.stream_name,
  10878. * self.parsed_event.start_mark.index,
  10879. */
  10880. __pyx_t_2 = (__Pyx_PySequence_ContainsTF(__pyx_v_anchor, __pyx_v_self->anchors, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 758, __pyx_L1_error)
  10881. __pyx_t_4 = (__pyx_t_2 != 0);
  10882. if (__pyx_t_4) {
  10883. /* "_yaml.pyx":760
  10884. * if anchor in self.anchors:
  10885. * mark = Mark(self.stream_name,
  10886. * self.parsed_event.start_mark.index, # <<<<<<<<<<<<<<
  10887. * self.parsed_event.start_mark.line,
  10888. * self.parsed_event.start_mark.column,
  10889. */
  10890. __pyx_t_6 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.index); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 760, __pyx_L1_error)
  10891. __Pyx_GOTREF(__pyx_t_6);
  10892. /* "_yaml.pyx":761
  10893. * mark = Mark(self.stream_name,
  10894. * self.parsed_event.start_mark.index,
  10895. * self.parsed_event.start_mark.line, # <<<<<<<<<<<<<<
  10896. * self.parsed_event.start_mark.column,
  10897. * None, None)
  10898. */
  10899. __pyx_t_7 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.line); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 761, __pyx_L1_error)
  10900. __Pyx_GOTREF(__pyx_t_7);
  10901. /* "_yaml.pyx":762
  10902. * self.parsed_event.start_mark.index,
  10903. * self.parsed_event.start_mark.line,
  10904. * self.parsed_event.start_mark.column, # <<<<<<<<<<<<<<
  10905. * None, None)
  10906. * if PY_MAJOR_VERSION < 3:
  10907. */
  10908. __pyx_t_5 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.column); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 762, __pyx_L1_error)
  10909. __Pyx_GOTREF(__pyx_t_5);
  10910. /* "_yaml.pyx":759
  10911. * if anchor is not None:
  10912. * if anchor in self.anchors:
  10913. * mark = Mark(self.stream_name, # <<<<<<<<<<<<<<
  10914. * self.parsed_event.start_mark.index,
  10915. * self.parsed_event.start_mark.line,
  10916. */
  10917. __pyx_t_3 = PyTuple_New(6); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 759, __pyx_L1_error)
  10918. __Pyx_GOTREF(__pyx_t_3);
  10919. __Pyx_INCREF(__pyx_v_self->stream_name);
  10920. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  10921. PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_self->stream_name);
  10922. __Pyx_GIVEREF(__pyx_t_6);
  10923. PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_t_6);
  10924. __Pyx_GIVEREF(__pyx_t_7);
  10925. PyTuple_SET_ITEM(__pyx_t_3, 2, __pyx_t_7);
  10926. __Pyx_GIVEREF(__pyx_t_5);
  10927. PyTuple_SET_ITEM(__pyx_t_3, 3, __pyx_t_5);
  10928. __Pyx_INCREF(Py_None);
  10929. __Pyx_GIVEREF(Py_None);
  10930. PyTuple_SET_ITEM(__pyx_t_3, 4, Py_None);
  10931. __Pyx_INCREF(Py_None);
  10932. __Pyx_GIVEREF(Py_None);
  10933. PyTuple_SET_ITEM(__pyx_t_3, 5, Py_None);
  10934. __pyx_t_6 = 0;
  10935. __pyx_t_7 = 0;
  10936. __pyx_t_5 = 0;
  10937. __pyx_t_5 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_t_3, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 759, __pyx_L1_error)
  10938. __Pyx_GOTREF(__pyx_t_5);
  10939. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  10940. __pyx_v_mark = ((struct __pyx_obj_5_yaml_Mark *)__pyx_t_5);
  10941. __pyx_t_5 = 0;
  10942. /* "_yaml.pyx":764
  10943. * self.parsed_event.start_mark.column,
  10944. * None, None)
  10945. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  10946. * raise ComposerError("found duplicate anchor; first occurrence",
  10947. * self.anchors[anchor].start_mark, "second occurrence", mark)
  10948. */
  10949. __pyx_t_4 = ((PY_MAJOR_VERSION < 3) != 0);
  10950. if (unlikely(__pyx_t_4)) {
  10951. /* "_yaml.pyx":765
  10952. * None, None)
  10953. * if PY_MAJOR_VERSION < 3:
  10954. * raise ComposerError("found duplicate anchor; first occurrence", # <<<<<<<<<<<<<<
  10955. * self.anchors[anchor].start_mark, "second occurrence", mark)
  10956. * else:
  10957. */
  10958. __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_ComposerError); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 765, __pyx_L1_error)
  10959. __Pyx_GOTREF(__pyx_t_3);
  10960. /* "_yaml.pyx":766
  10961. * if PY_MAJOR_VERSION < 3:
  10962. * raise ComposerError("found duplicate anchor; first occurrence",
  10963. * self.anchors[anchor].start_mark, "second occurrence", mark) # <<<<<<<<<<<<<<
  10964. * else:
  10965. * raise ComposerError(u"found duplicate anchor; first occurrence",
  10966. */
  10967. __pyx_t_7 = __Pyx_PyObject_GetItem(__pyx_v_self->anchors, __pyx_v_anchor); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 766, __pyx_L1_error)
  10968. __Pyx_GOTREF(__pyx_t_7);
  10969. __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_start_mark); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 766, __pyx_L1_error)
  10970. __Pyx_GOTREF(__pyx_t_6);
  10971. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  10972. __pyx_t_7 = NULL;
  10973. __pyx_t_1 = 0;
  10974. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
  10975. __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_3);
  10976. if (likely(__pyx_t_7)) {
  10977. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
  10978. __Pyx_INCREF(__pyx_t_7);
  10979. __Pyx_INCREF(function);
  10980. __Pyx_DECREF_SET(__pyx_t_3, function);
  10981. __pyx_t_1 = 1;
  10982. }
  10983. }
  10984. #if CYTHON_FAST_PYCALL
  10985. if (PyFunction_Check(__pyx_t_3)) {
  10986. PyObject *__pyx_temp[5] = {__pyx_t_7, __pyx_kp_s_found_duplicate_anchor_first_occ, __pyx_t_6, __pyx_kp_s_second_occurrence, ((PyObject *)__pyx_v_mark)};
  10987. __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_1, 4+__pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 765, __pyx_L1_error)
  10988. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  10989. __Pyx_GOTREF(__pyx_t_5);
  10990. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  10991. } else
  10992. #endif
  10993. #if CYTHON_FAST_PYCCALL
  10994. if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) {
  10995. PyObject *__pyx_temp[5] = {__pyx_t_7, __pyx_kp_s_found_duplicate_anchor_first_occ, __pyx_t_6, __pyx_kp_s_second_occurrence, ((PyObject *)__pyx_v_mark)};
  10996. __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_1, 4+__pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 765, __pyx_L1_error)
  10997. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  10998. __Pyx_GOTREF(__pyx_t_5);
  10999. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  11000. } else
  11001. #endif
  11002. {
  11003. __pyx_t_8 = PyTuple_New(4+__pyx_t_1); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 765, __pyx_L1_error)
  11004. __Pyx_GOTREF(__pyx_t_8);
  11005. if (__pyx_t_7) {
  11006. __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL;
  11007. }
  11008. __Pyx_INCREF(__pyx_kp_s_found_duplicate_anchor_first_occ);
  11009. __Pyx_GIVEREF(__pyx_kp_s_found_duplicate_anchor_first_occ);
  11010. PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_1, __pyx_kp_s_found_duplicate_anchor_first_occ);
  11011. __Pyx_GIVEREF(__pyx_t_6);
  11012. PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_1, __pyx_t_6);
  11013. __Pyx_INCREF(__pyx_kp_s_second_occurrence);
  11014. __Pyx_GIVEREF(__pyx_kp_s_second_occurrence);
  11015. PyTuple_SET_ITEM(__pyx_t_8, 2+__pyx_t_1, __pyx_kp_s_second_occurrence);
  11016. __Pyx_INCREF(((PyObject *)__pyx_v_mark));
  11017. __Pyx_GIVEREF(((PyObject *)__pyx_v_mark));
  11018. PyTuple_SET_ITEM(__pyx_t_8, 3+__pyx_t_1, ((PyObject *)__pyx_v_mark));
  11019. __pyx_t_6 = 0;
  11020. __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_8, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 765, __pyx_L1_error)
  11021. __Pyx_GOTREF(__pyx_t_5);
  11022. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  11023. }
  11024. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  11025. __Pyx_Raise(__pyx_t_5, 0, 0, 0);
  11026. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  11027. __PYX_ERR(0, 765, __pyx_L1_error)
  11028. /* "_yaml.pyx":764
  11029. * self.parsed_event.start_mark.column,
  11030. * None, None)
  11031. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  11032. * raise ComposerError("found duplicate anchor; first occurrence",
  11033. * self.anchors[anchor].start_mark, "second occurrence", mark)
  11034. */
  11035. }
  11036. /* "_yaml.pyx":768
  11037. * self.anchors[anchor].start_mark, "second occurrence", mark)
  11038. * else:
  11039. * raise ComposerError(u"found duplicate anchor; first occurrence", # <<<<<<<<<<<<<<
  11040. * self.anchors[anchor].start_mark, u"second occurrence", mark)
  11041. * self.descend_resolver(parent, index)
  11042. */
  11043. /*else*/ {
  11044. __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_ComposerError); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 768, __pyx_L1_error)
  11045. __Pyx_GOTREF(__pyx_t_3);
  11046. /* "_yaml.pyx":769
  11047. * else:
  11048. * raise ComposerError(u"found duplicate anchor; first occurrence",
  11049. * self.anchors[anchor].start_mark, u"second occurrence", mark) # <<<<<<<<<<<<<<
  11050. * self.descend_resolver(parent, index)
  11051. * if self.parsed_event.type == YAML_SCALAR_EVENT:
  11052. */
  11053. __pyx_t_8 = __Pyx_PyObject_GetItem(__pyx_v_self->anchors, __pyx_v_anchor); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 769, __pyx_L1_error)
  11054. __Pyx_GOTREF(__pyx_t_8);
  11055. __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_t_8, __pyx_n_s_start_mark); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 769, __pyx_L1_error)
  11056. __Pyx_GOTREF(__pyx_t_6);
  11057. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  11058. __pyx_t_8 = NULL;
  11059. __pyx_t_1 = 0;
  11060. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
  11061. __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_3);
  11062. if (likely(__pyx_t_8)) {
  11063. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
  11064. __Pyx_INCREF(__pyx_t_8);
  11065. __Pyx_INCREF(function);
  11066. __Pyx_DECREF_SET(__pyx_t_3, function);
  11067. __pyx_t_1 = 1;
  11068. }
  11069. }
  11070. #if CYTHON_FAST_PYCALL
  11071. if (PyFunction_Check(__pyx_t_3)) {
  11072. PyObject *__pyx_temp[5] = {__pyx_t_8, __pyx_kp_u_found_duplicate_anchor_first_occ, __pyx_t_6, __pyx_kp_u_second_occurrence, ((PyObject *)__pyx_v_mark)};
  11073. __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_1, 4+__pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 768, __pyx_L1_error)
  11074. __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
  11075. __Pyx_GOTREF(__pyx_t_5);
  11076. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  11077. } else
  11078. #endif
  11079. #if CYTHON_FAST_PYCCALL
  11080. if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) {
  11081. PyObject *__pyx_temp[5] = {__pyx_t_8, __pyx_kp_u_found_duplicate_anchor_first_occ, __pyx_t_6, __pyx_kp_u_second_occurrence, ((PyObject *)__pyx_v_mark)};
  11082. __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_1, 4+__pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 768, __pyx_L1_error)
  11083. __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
  11084. __Pyx_GOTREF(__pyx_t_5);
  11085. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  11086. } else
  11087. #endif
  11088. {
  11089. __pyx_t_7 = PyTuple_New(4+__pyx_t_1); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 768, __pyx_L1_error)
  11090. __Pyx_GOTREF(__pyx_t_7);
  11091. if (__pyx_t_8) {
  11092. __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_8); __pyx_t_8 = NULL;
  11093. }
  11094. __Pyx_INCREF(__pyx_kp_u_found_duplicate_anchor_first_occ);
  11095. __Pyx_GIVEREF(__pyx_kp_u_found_duplicate_anchor_first_occ);
  11096. PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_1, __pyx_kp_u_found_duplicate_anchor_first_occ);
  11097. __Pyx_GIVEREF(__pyx_t_6);
  11098. PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_1, __pyx_t_6);
  11099. __Pyx_INCREF(__pyx_kp_u_second_occurrence);
  11100. __Pyx_GIVEREF(__pyx_kp_u_second_occurrence);
  11101. PyTuple_SET_ITEM(__pyx_t_7, 2+__pyx_t_1, __pyx_kp_u_second_occurrence);
  11102. __Pyx_INCREF(((PyObject *)__pyx_v_mark));
  11103. __Pyx_GIVEREF(((PyObject *)__pyx_v_mark));
  11104. PyTuple_SET_ITEM(__pyx_t_7, 3+__pyx_t_1, ((PyObject *)__pyx_v_mark));
  11105. __pyx_t_6 = 0;
  11106. __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_7, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 768, __pyx_L1_error)
  11107. __Pyx_GOTREF(__pyx_t_5);
  11108. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  11109. }
  11110. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  11111. __Pyx_Raise(__pyx_t_5, 0, 0, 0);
  11112. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  11113. __PYX_ERR(0, 768, __pyx_L1_error)
  11114. }
  11115. /* "_yaml.pyx":758
  11116. * anchor = PyUnicode_FromString(self.parsed_event.data.mapping_start.anchor)
  11117. * if anchor is not None:
  11118. * if anchor in self.anchors: # <<<<<<<<<<<<<<
  11119. * mark = Mark(self.stream_name,
  11120. * self.parsed_event.start_mark.index,
  11121. */
  11122. }
  11123. /* "_yaml.pyx":757
  11124. * and self.parsed_event.data.mapping_start.anchor != NULL:
  11125. * anchor = PyUnicode_FromString(self.parsed_event.data.mapping_start.anchor)
  11126. * if anchor is not None: # <<<<<<<<<<<<<<
  11127. * if anchor in self.anchors:
  11128. * mark = Mark(self.stream_name,
  11129. */
  11130. }
  11131. /* "_yaml.pyx":770
  11132. * raise ComposerError(u"found duplicate anchor; first occurrence",
  11133. * self.anchors[anchor].start_mark, u"second occurrence", mark)
  11134. * self.descend_resolver(parent, index) # <<<<<<<<<<<<<<
  11135. * if self.parsed_event.type == YAML_SCALAR_EVENT:
  11136. * node = self._compose_scalar_node(anchor)
  11137. */
  11138. __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_descend_resolver); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 770, __pyx_L1_error)
  11139. __Pyx_GOTREF(__pyx_t_3);
  11140. __pyx_t_7 = NULL;
  11141. __pyx_t_1 = 0;
  11142. if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) {
  11143. __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_3);
  11144. if (likely(__pyx_t_7)) {
  11145. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
  11146. __Pyx_INCREF(__pyx_t_7);
  11147. __Pyx_INCREF(function);
  11148. __Pyx_DECREF_SET(__pyx_t_3, function);
  11149. __pyx_t_1 = 1;
  11150. }
  11151. }
  11152. #if CYTHON_FAST_PYCALL
  11153. if (PyFunction_Check(__pyx_t_3)) {
  11154. PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_v_parent, __pyx_v_index};
  11155. __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_1, 2+__pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 770, __pyx_L1_error)
  11156. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  11157. __Pyx_GOTREF(__pyx_t_5);
  11158. } else
  11159. #endif
  11160. #if CYTHON_FAST_PYCCALL
  11161. if (__Pyx_PyFastCFunction_Check(__pyx_t_3)) {
  11162. PyObject *__pyx_temp[3] = {__pyx_t_7, __pyx_v_parent, __pyx_v_index};
  11163. __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_3, __pyx_temp+1-__pyx_t_1, 2+__pyx_t_1); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 770, __pyx_L1_error)
  11164. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  11165. __Pyx_GOTREF(__pyx_t_5);
  11166. } else
  11167. #endif
  11168. {
  11169. __pyx_t_6 = PyTuple_New(2+__pyx_t_1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 770, __pyx_L1_error)
  11170. __Pyx_GOTREF(__pyx_t_6);
  11171. if (__pyx_t_7) {
  11172. __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_6, 0, __pyx_t_7); __pyx_t_7 = NULL;
  11173. }
  11174. __Pyx_INCREF(__pyx_v_parent);
  11175. __Pyx_GIVEREF(__pyx_v_parent);
  11176. PyTuple_SET_ITEM(__pyx_t_6, 0+__pyx_t_1, __pyx_v_parent);
  11177. __Pyx_INCREF(__pyx_v_index);
  11178. __Pyx_GIVEREF(__pyx_v_index);
  11179. PyTuple_SET_ITEM(__pyx_t_6, 1+__pyx_t_1, __pyx_v_index);
  11180. __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_3, __pyx_t_6, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 770, __pyx_L1_error)
  11181. __Pyx_GOTREF(__pyx_t_5);
  11182. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  11183. }
  11184. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  11185. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  11186. /* "_yaml.pyx":771
  11187. * self.anchors[anchor].start_mark, u"second occurrence", mark)
  11188. * self.descend_resolver(parent, index)
  11189. * if self.parsed_event.type == YAML_SCALAR_EVENT: # <<<<<<<<<<<<<<
  11190. * node = self._compose_scalar_node(anchor)
  11191. * elif self.parsed_event.type == YAML_SEQUENCE_START_EVENT:
  11192. */
  11193. switch (__pyx_v_self->parsed_event.type) {
  11194. case YAML_SCALAR_EVENT:
  11195. /* "_yaml.pyx":772
  11196. * self.descend_resolver(parent, index)
  11197. * if self.parsed_event.type == YAML_SCALAR_EVENT:
  11198. * node = self._compose_scalar_node(anchor) # <<<<<<<<<<<<<<
  11199. * elif self.parsed_event.type == YAML_SEQUENCE_START_EVENT:
  11200. * node = self._compose_sequence_node(anchor)
  11201. */
  11202. __pyx_t_5 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_compose_scalar_node(__pyx_v_self, __pyx_v_anchor); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 772, __pyx_L1_error)
  11203. __Pyx_GOTREF(__pyx_t_5);
  11204. __pyx_v_node = __pyx_t_5;
  11205. __pyx_t_5 = 0;
  11206. /* "_yaml.pyx":771
  11207. * self.anchors[anchor].start_mark, u"second occurrence", mark)
  11208. * self.descend_resolver(parent, index)
  11209. * if self.parsed_event.type == YAML_SCALAR_EVENT: # <<<<<<<<<<<<<<
  11210. * node = self._compose_scalar_node(anchor)
  11211. * elif self.parsed_event.type == YAML_SEQUENCE_START_EVENT:
  11212. */
  11213. break;
  11214. case YAML_SEQUENCE_START_EVENT:
  11215. /* "_yaml.pyx":774
  11216. * node = self._compose_scalar_node(anchor)
  11217. * elif self.parsed_event.type == YAML_SEQUENCE_START_EVENT:
  11218. * node = self._compose_sequence_node(anchor) # <<<<<<<<<<<<<<
  11219. * elif self.parsed_event.type == YAML_MAPPING_START_EVENT:
  11220. * node = self._compose_mapping_node(anchor)
  11221. */
  11222. __pyx_t_5 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_compose_sequence_node(__pyx_v_self, __pyx_v_anchor); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 774, __pyx_L1_error)
  11223. __Pyx_GOTREF(__pyx_t_5);
  11224. __pyx_v_node = __pyx_t_5;
  11225. __pyx_t_5 = 0;
  11226. /* "_yaml.pyx":773
  11227. * if self.parsed_event.type == YAML_SCALAR_EVENT:
  11228. * node = self._compose_scalar_node(anchor)
  11229. * elif self.parsed_event.type == YAML_SEQUENCE_START_EVENT: # <<<<<<<<<<<<<<
  11230. * node = self._compose_sequence_node(anchor)
  11231. * elif self.parsed_event.type == YAML_MAPPING_START_EVENT:
  11232. */
  11233. break;
  11234. case YAML_MAPPING_START_EVENT:
  11235. /* "_yaml.pyx":776
  11236. * node = self._compose_sequence_node(anchor)
  11237. * elif self.parsed_event.type == YAML_MAPPING_START_EVENT:
  11238. * node = self._compose_mapping_node(anchor) # <<<<<<<<<<<<<<
  11239. * self.ascend_resolver()
  11240. * return node
  11241. */
  11242. __pyx_t_5 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_compose_mapping_node(__pyx_v_self, __pyx_v_anchor); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 776, __pyx_L1_error)
  11243. __Pyx_GOTREF(__pyx_t_5);
  11244. __pyx_v_node = __pyx_t_5;
  11245. __pyx_t_5 = 0;
  11246. /* "_yaml.pyx":775
  11247. * elif self.parsed_event.type == YAML_SEQUENCE_START_EVENT:
  11248. * node = self._compose_sequence_node(anchor)
  11249. * elif self.parsed_event.type == YAML_MAPPING_START_EVENT: # <<<<<<<<<<<<<<
  11250. * node = self._compose_mapping_node(anchor)
  11251. * self.ascend_resolver()
  11252. */
  11253. break;
  11254. default: break;
  11255. }
  11256. /* "_yaml.pyx":777
  11257. * elif self.parsed_event.type == YAML_MAPPING_START_EVENT:
  11258. * node = self._compose_mapping_node(anchor)
  11259. * self.ascend_resolver() # <<<<<<<<<<<<<<
  11260. * return node
  11261. *
  11262. */
  11263. __pyx_t_3 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_ascend_resolver); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 777, __pyx_L1_error)
  11264. __Pyx_GOTREF(__pyx_t_3);
  11265. __pyx_t_6 = NULL;
  11266. if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) {
  11267. __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_3);
  11268. if (likely(__pyx_t_6)) {
  11269. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
  11270. __Pyx_INCREF(__pyx_t_6);
  11271. __Pyx_INCREF(function);
  11272. __Pyx_DECREF_SET(__pyx_t_3, function);
  11273. }
  11274. }
  11275. __pyx_t_5 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_3);
  11276. __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
  11277. if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 777, __pyx_L1_error)
  11278. __Pyx_GOTREF(__pyx_t_5);
  11279. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  11280. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  11281. /* "_yaml.pyx":778
  11282. * node = self._compose_mapping_node(anchor)
  11283. * self.ascend_resolver()
  11284. * return node # <<<<<<<<<<<<<<
  11285. *
  11286. * cdef _compose_scalar_node(self, object anchor):
  11287. */
  11288. __Pyx_XDECREF(__pyx_r);
  11289. if (unlikely(!__pyx_v_node)) { __Pyx_RaiseUnboundLocalError("node"); __PYX_ERR(0, 778, __pyx_L1_error) }
  11290. __Pyx_INCREF(__pyx_v_node);
  11291. __pyx_r = __pyx_v_node;
  11292. goto __pyx_L0;
  11293. /* "_yaml.pyx":731
  11294. * return node
  11295. *
  11296. * cdef object _compose_node(self, object parent, object index): # <<<<<<<<<<<<<<
  11297. * self._parse_next_event()
  11298. * if self.parsed_event.type == YAML_ALIAS_EVENT:
  11299. */
  11300. /* function exit code */
  11301. __pyx_L1_error:;
  11302. __Pyx_XDECREF(__pyx_t_3);
  11303. __Pyx_XDECREF(__pyx_t_5);
  11304. __Pyx_XDECREF(__pyx_t_6);
  11305. __Pyx_XDECREF(__pyx_t_7);
  11306. __Pyx_XDECREF(__pyx_t_8);
  11307. __Pyx_AddTraceback("_yaml.CParser._compose_node", __pyx_clineno, __pyx_lineno, __pyx_filename);
  11308. __pyx_r = 0;
  11309. __pyx_L0:;
  11310. __Pyx_XDECREF(__pyx_v_anchor);
  11311. __Pyx_XDECREF((PyObject *)__pyx_v_mark);
  11312. __Pyx_XDECREF(__pyx_v_node);
  11313. __Pyx_XGIVEREF(__pyx_r);
  11314. __Pyx_RefNannyFinishContext();
  11315. return __pyx_r;
  11316. }
  11317. /* "_yaml.pyx":780
  11318. * return node
  11319. *
  11320. * cdef _compose_scalar_node(self, object anchor): # <<<<<<<<<<<<<<
  11321. * start_mark = Mark(self.stream_name,
  11322. * self.parsed_event.start_mark.index,
  11323. */
  11324. static PyObject *__pyx_f_5_yaml_7CParser__compose_scalar_node(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, PyObject *__pyx_v_anchor) {
  11325. struct __pyx_obj_5_yaml_Mark *__pyx_v_start_mark = NULL;
  11326. struct __pyx_obj_5_yaml_Mark *__pyx_v_end_mark = NULL;
  11327. PyObject *__pyx_v_value = NULL;
  11328. int __pyx_v_plain_implicit;
  11329. int __pyx_v_quoted_implicit;
  11330. PyObject *__pyx_v_tag = NULL;
  11331. PyObject *__pyx_v_style = NULL;
  11332. PyObject *__pyx_v_node = NULL;
  11333. PyObject *__pyx_r = NULL;
  11334. __Pyx_RefNannyDeclarations
  11335. PyObject *__pyx_t_1 = NULL;
  11336. PyObject *__pyx_t_2 = NULL;
  11337. PyObject *__pyx_t_3 = NULL;
  11338. PyObject *__pyx_t_4 = NULL;
  11339. int __pyx_t_5;
  11340. int __pyx_t_6;
  11341. PyObject *__pyx_t_7 = NULL;
  11342. PyObject *__pyx_t_8 = NULL;
  11343. int __pyx_t_9;
  11344. __Pyx_RefNannySetupContext("_compose_scalar_node", 0);
  11345. /* "_yaml.pyx":782
  11346. * cdef _compose_scalar_node(self, object anchor):
  11347. * start_mark = Mark(self.stream_name,
  11348. * self.parsed_event.start_mark.index, # <<<<<<<<<<<<<<
  11349. * self.parsed_event.start_mark.line,
  11350. * self.parsed_event.start_mark.column,
  11351. */
  11352. __pyx_t_1 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.index); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 782, __pyx_L1_error)
  11353. __Pyx_GOTREF(__pyx_t_1);
  11354. /* "_yaml.pyx":783
  11355. * start_mark = Mark(self.stream_name,
  11356. * self.parsed_event.start_mark.index,
  11357. * self.parsed_event.start_mark.line, # <<<<<<<<<<<<<<
  11358. * self.parsed_event.start_mark.column,
  11359. * None, None)
  11360. */
  11361. __pyx_t_2 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.line); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 783, __pyx_L1_error)
  11362. __Pyx_GOTREF(__pyx_t_2);
  11363. /* "_yaml.pyx":784
  11364. * self.parsed_event.start_mark.index,
  11365. * self.parsed_event.start_mark.line,
  11366. * self.parsed_event.start_mark.column, # <<<<<<<<<<<<<<
  11367. * None, None)
  11368. * end_mark = Mark(self.stream_name,
  11369. */
  11370. __pyx_t_3 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.column); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 784, __pyx_L1_error)
  11371. __Pyx_GOTREF(__pyx_t_3);
  11372. /* "_yaml.pyx":781
  11373. *
  11374. * cdef _compose_scalar_node(self, object anchor):
  11375. * start_mark = Mark(self.stream_name, # <<<<<<<<<<<<<<
  11376. * self.parsed_event.start_mark.index,
  11377. * self.parsed_event.start_mark.line,
  11378. */
  11379. __pyx_t_4 = PyTuple_New(6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 781, __pyx_L1_error)
  11380. __Pyx_GOTREF(__pyx_t_4);
  11381. __Pyx_INCREF(__pyx_v_self->stream_name);
  11382. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  11383. PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->stream_name);
  11384. __Pyx_GIVEREF(__pyx_t_1);
  11385. PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1);
  11386. __Pyx_GIVEREF(__pyx_t_2);
  11387. PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_2);
  11388. __Pyx_GIVEREF(__pyx_t_3);
  11389. PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_t_3);
  11390. __Pyx_INCREF(Py_None);
  11391. __Pyx_GIVEREF(Py_None);
  11392. PyTuple_SET_ITEM(__pyx_t_4, 4, Py_None);
  11393. __Pyx_INCREF(Py_None);
  11394. __Pyx_GIVEREF(Py_None);
  11395. PyTuple_SET_ITEM(__pyx_t_4, 5, Py_None);
  11396. __pyx_t_1 = 0;
  11397. __pyx_t_2 = 0;
  11398. __pyx_t_3 = 0;
  11399. __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 781, __pyx_L1_error)
  11400. __Pyx_GOTREF(__pyx_t_3);
  11401. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  11402. __pyx_v_start_mark = ((struct __pyx_obj_5_yaml_Mark *)__pyx_t_3);
  11403. __pyx_t_3 = 0;
  11404. /* "_yaml.pyx":787
  11405. * None, None)
  11406. * end_mark = Mark(self.stream_name,
  11407. * self.parsed_event.end_mark.index, # <<<<<<<<<<<<<<
  11408. * self.parsed_event.end_mark.line,
  11409. * self.parsed_event.end_mark.column,
  11410. */
  11411. __pyx_t_3 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.end_mark.index); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 787, __pyx_L1_error)
  11412. __Pyx_GOTREF(__pyx_t_3);
  11413. /* "_yaml.pyx":788
  11414. * end_mark = Mark(self.stream_name,
  11415. * self.parsed_event.end_mark.index,
  11416. * self.parsed_event.end_mark.line, # <<<<<<<<<<<<<<
  11417. * self.parsed_event.end_mark.column,
  11418. * None, None)
  11419. */
  11420. __pyx_t_4 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.end_mark.line); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 788, __pyx_L1_error)
  11421. __Pyx_GOTREF(__pyx_t_4);
  11422. /* "_yaml.pyx":789
  11423. * self.parsed_event.end_mark.index,
  11424. * self.parsed_event.end_mark.line,
  11425. * self.parsed_event.end_mark.column, # <<<<<<<<<<<<<<
  11426. * None, None)
  11427. * value = PyUnicode_DecodeUTF8(self.parsed_event.data.scalar.value,
  11428. */
  11429. __pyx_t_2 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.end_mark.column); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 789, __pyx_L1_error)
  11430. __Pyx_GOTREF(__pyx_t_2);
  11431. /* "_yaml.pyx":786
  11432. * self.parsed_event.start_mark.column,
  11433. * None, None)
  11434. * end_mark = Mark(self.stream_name, # <<<<<<<<<<<<<<
  11435. * self.parsed_event.end_mark.index,
  11436. * self.parsed_event.end_mark.line,
  11437. */
  11438. __pyx_t_1 = PyTuple_New(6); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 786, __pyx_L1_error)
  11439. __Pyx_GOTREF(__pyx_t_1);
  11440. __Pyx_INCREF(__pyx_v_self->stream_name);
  11441. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  11442. PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_v_self->stream_name);
  11443. __Pyx_GIVEREF(__pyx_t_3);
  11444. PyTuple_SET_ITEM(__pyx_t_1, 1, __pyx_t_3);
  11445. __Pyx_GIVEREF(__pyx_t_4);
  11446. PyTuple_SET_ITEM(__pyx_t_1, 2, __pyx_t_4);
  11447. __Pyx_GIVEREF(__pyx_t_2);
  11448. PyTuple_SET_ITEM(__pyx_t_1, 3, __pyx_t_2);
  11449. __Pyx_INCREF(Py_None);
  11450. __Pyx_GIVEREF(Py_None);
  11451. PyTuple_SET_ITEM(__pyx_t_1, 4, Py_None);
  11452. __Pyx_INCREF(Py_None);
  11453. __Pyx_GIVEREF(Py_None);
  11454. PyTuple_SET_ITEM(__pyx_t_1, 5, Py_None);
  11455. __pyx_t_3 = 0;
  11456. __pyx_t_4 = 0;
  11457. __pyx_t_2 = 0;
  11458. __pyx_t_2 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_t_1, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 786, __pyx_L1_error)
  11459. __Pyx_GOTREF(__pyx_t_2);
  11460. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  11461. __pyx_v_end_mark = ((struct __pyx_obj_5_yaml_Mark *)__pyx_t_2);
  11462. __pyx_t_2 = 0;
  11463. /* "_yaml.pyx":791
  11464. * self.parsed_event.end_mark.column,
  11465. * None, None)
  11466. * value = PyUnicode_DecodeUTF8(self.parsed_event.data.scalar.value, # <<<<<<<<<<<<<<
  11467. * self.parsed_event.data.scalar.length, 'strict')
  11468. * plain_implicit = False
  11469. */
  11470. __pyx_t_2 = PyUnicode_DecodeUTF8(__pyx_v_self->parsed_event.data.scalar.value, __pyx_v_self->parsed_event.data.scalar.length, ((char *)"strict")); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 791, __pyx_L1_error)
  11471. __Pyx_GOTREF(__pyx_t_2);
  11472. __pyx_v_value = __pyx_t_2;
  11473. __pyx_t_2 = 0;
  11474. /* "_yaml.pyx":793
  11475. * value = PyUnicode_DecodeUTF8(self.parsed_event.data.scalar.value,
  11476. * self.parsed_event.data.scalar.length, 'strict')
  11477. * plain_implicit = False # <<<<<<<<<<<<<<
  11478. * if self.parsed_event.data.scalar.plain_implicit == 1:
  11479. * plain_implicit = True
  11480. */
  11481. __pyx_v_plain_implicit = 0;
  11482. /* "_yaml.pyx":794
  11483. * self.parsed_event.data.scalar.length, 'strict')
  11484. * plain_implicit = False
  11485. * if self.parsed_event.data.scalar.plain_implicit == 1: # <<<<<<<<<<<<<<
  11486. * plain_implicit = True
  11487. * quoted_implicit = False
  11488. */
  11489. __pyx_t_5 = ((__pyx_v_self->parsed_event.data.scalar.plain_implicit == 1) != 0);
  11490. if (__pyx_t_5) {
  11491. /* "_yaml.pyx":795
  11492. * plain_implicit = False
  11493. * if self.parsed_event.data.scalar.plain_implicit == 1:
  11494. * plain_implicit = True # <<<<<<<<<<<<<<
  11495. * quoted_implicit = False
  11496. * if self.parsed_event.data.scalar.quoted_implicit == 1:
  11497. */
  11498. __pyx_v_plain_implicit = 1;
  11499. /* "_yaml.pyx":794
  11500. * self.parsed_event.data.scalar.length, 'strict')
  11501. * plain_implicit = False
  11502. * if self.parsed_event.data.scalar.plain_implicit == 1: # <<<<<<<<<<<<<<
  11503. * plain_implicit = True
  11504. * quoted_implicit = False
  11505. */
  11506. }
  11507. /* "_yaml.pyx":796
  11508. * if self.parsed_event.data.scalar.plain_implicit == 1:
  11509. * plain_implicit = True
  11510. * quoted_implicit = False # <<<<<<<<<<<<<<
  11511. * if self.parsed_event.data.scalar.quoted_implicit == 1:
  11512. * quoted_implicit = True
  11513. */
  11514. __pyx_v_quoted_implicit = 0;
  11515. /* "_yaml.pyx":797
  11516. * plain_implicit = True
  11517. * quoted_implicit = False
  11518. * if self.parsed_event.data.scalar.quoted_implicit == 1: # <<<<<<<<<<<<<<
  11519. * quoted_implicit = True
  11520. * if self.parsed_event.data.scalar.tag == NULL \
  11521. */
  11522. __pyx_t_5 = ((__pyx_v_self->parsed_event.data.scalar.quoted_implicit == 1) != 0);
  11523. if (__pyx_t_5) {
  11524. /* "_yaml.pyx":798
  11525. * quoted_implicit = False
  11526. * if self.parsed_event.data.scalar.quoted_implicit == 1:
  11527. * quoted_implicit = True # <<<<<<<<<<<<<<
  11528. * if self.parsed_event.data.scalar.tag == NULL \
  11529. * or (self.parsed_event.data.scalar.tag[0] == c'!'
  11530. */
  11531. __pyx_v_quoted_implicit = 1;
  11532. /* "_yaml.pyx":797
  11533. * plain_implicit = True
  11534. * quoted_implicit = False
  11535. * if self.parsed_event.data.scalar.quoted_implicit == 1: # <<<<<<<<<<<<<<
  11536. * quoted_implicit = True
  11537. * if self.parsed_event.data.scalar.tag == NULL \
  11538. */
  11539. }
  11540. /* "_yaml.pyx":799
  11541. * if self.parsed_event.data.scalar.quoted_implicit == 1:
  11542. * quoted_implicit = True
  11543. * if self.parsed_event.data.scalar.tag == NULL \ # <<<<<<<<<<<<<<
  11544. * or (self.parsed_event.data.scalar.tag[0] == c'!'
  11545. * and self.parsed_event.data.scalar.tag[1] == c'\0'):
  11546. */
  11547. __pyx_t_6 = ((__pyx_v_self->parsed_event.data.scalar.tag == NULL) != 0);
  11548. if (!__pyx_t_6) {
  11549. } else {
  11550. __pyx_t_5 = __pyx_t_6;
  11551. goto __pyx_L6_bool_binop_done;
  11552. }
  11553. /* "_yaml.pyx":800
  11554. * quoted_implicit = True
  11555. * if self.parsed_event.data.scalar.tag == NULL \
  11556. * or (self.parsed_event.data.scalar.tag[0] == c'!' # <<<<<<<<<<<<<<
  11557. * and self.parsed_event.data.scalar.tag[1] == c'\0'):
  11558. * tag = self.resolve(ScalarNode, value, (plain_implicit, quoted_implicit))
  11559. */
  11560. __pyx_t_6 = (((__pyx_v_self->parsed_event.data.scalar.tag[0]) == '!') != 0);
  11561. if (__pyx_t_6) {
  11562. } else {
  11563. __pyx_t_5 = __pyx_t_6;
  11564. goto __pyx_L6_bool_binop_done;
  11565. }
  11566. /* "_yaml.pyx":801
  11567. * if self.parsed_event.data.scalar.tag == NULL \
  11568. * or (self.parsed_event.data.scalar.tag[0] == c'!'
  11569. * and self.parsed_event.data.scalar.tag[1] == c'\0'): # <<<<<<<<<<<<<<
  11570. * tag = self.resolve(ScalarNode, value, (plain_implicit, quoted_implicit))
  11571. * else:
  11572. */
  11573. __pyx_t_6 = (((__pyx_v_self->parsed_event.data.scalar.tag[1]) == '\x00') != 0);
  11574. __pyx_t_5 = __pyx_t_6;
  11575. __pyx_L6_bool_binop_done:;
  11576. /* "_yaml.pyx":799
  11577. * if self.parsed_event.data.scalar.quoted_implicit == 1:
  11578. * quoted_implicit = True
  11579. * if self.parsed_event.data.scalar.tag == NULL \ # <<<<<<<<<<<<<<
  11580. * or (self.parsed_event.data.scalar.tag[0] == c'!'
  11581. * and self.parsed_event.data.scalar.tag[1] == c'\0'):
  11582. */
  11583. if (__pyx_t_5) {
  11584. /* "_yaml.pyx":802
  11585. * or (self.parsed_event.data.scalar.tag[0] == c'!'
  11586. * and self.parsed_event.data.scalar.tag[1] == c'\0'):
  11587. * tag = self.resolve(ScalarNode, value, (plain_implicit, quoted_implicit)) # <<<<<<<<<<<<<<
  11588. * else:
  11589. * tag = PyUnicode_FromString(self.parsed_event.data.scalar.tag)
  11590. */
  11591. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_resolve); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 802, __pyx_L1_error)
  11592. __Pyx_GOTREF(__pyx_t_1);
  11593. __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_ScalarNode); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 802, __pyx_L1_error)
  11594. __Pyx_GOTREF(__pyx_t_4);
  11595. __pyx_t_3 = __Pyx_PyBool_FromLong(__pyx_v_plain_implicit); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 802, __pyx_L1_error)
  11596. __Pyx_GOTREF(__pyx_t_3);
  11597. __pyx_t_7 = __Pyx_PyBool_FromLong(__pyx_v_quoted_implicit); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 802, __pyx_L1_error)
  11598. __Pyx_GOTREF(__pyx_t_7);
  11599. __pyx_t_8 = PyTuple_New(2); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 802, __pyx_L1_error)
  11600. __Pyx_GOTREF(__pyx_t_8);
  11601. __Pyx_GIVEREF(__pyx_t_3);
  11602. PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_3);
  11603. __Pyx_GIVEREF(__pyx_t_7);
  11604. PyTuple_SET_ITEM(__pyx_t_8, 1, __pyx_t_7);
  11605. __pyx_t_3 = 0;
  11606. __pyx_t_7 = 0;
  11607. __pyx_t_7 = NULL;
  11608. __pyx_t_9 = 0;
  11609. if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) {
  11610. __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_1);
  11611. if (likely(__pyx_t_7)) {
  11612. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  11613. __Pyx_INCREF(__pyx_t_7);
  11614. __Pyx_INCREF(function);
  11615. __Pyx_DECREF_SET(__pyx_t_1, function);
  11616. __pyx_t_9 = 1;
  11617. }
  11618. }
  11619. #if CYTHON_FAST_PYCALL
  11620. if (PyFunction_Check(__pyx_t_1)) {
  11621. PyObject *__pyx_temp[4] = {__pyx_t_7, __pyx_t_4, __pyx_v_value, __pyx_t_8};
  11622. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_9, 3+__pyx_t_9); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 802, __pyx_L1_error)
  11623. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  11624. __Pyx_GOTREF(__pyx_t_2);
  11625. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  11626. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  11627. } else
  11628. #endif
  11629. #if CYTHON_FAST_PYCCALL
  11630. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  11631. PyObject *__pyx_temp[4] = {__pyx_t_7, __pyx_t_4, __pyx_v_value, __pyx_t_8};
  11632. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_9, 3+__pyx_t_9); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 802, __pyx_L1_error)
  11633. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  11634. __Pyx_GOTREF(__pyx_t_2);
  11635. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  11636. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  11637. } else
  11638. #endif
  11639. {
  11640. __pyx_t_3 = PyTuple_New(3+__pyx_t_9); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 802, __pyx_L1_error)
  11641. __Pyx_GOTREF(__pyx_t_3);
  11642. if (__pyx_t_7) {
  11643. __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_t_7); __pyx_t_7 = NULL;
  11644. }
  11645. __Pyx_GIVEREF(__pyx_t_4);
  11646. PyTuple_SET_ITEM(__pyx_t_3, 0+__pyx_t_9, __pyx_t_4);
  11647. __Pyx_INCREF(__pyx_v_value);
  11648. __Pyx_GIVEREF(__pyx_v_value);
  11649. PyTuple_SET_ITEM(__pyx_t_3, 1+__pyx_t_9, __pyx_v_value);
  11650. __Pyx_GIVEREF(__pyx_t_8);
  11651. PyTuple_SET_ITEM(__pyx_t_3, 2+__pyx_t_9, __pyx_t_8);
  11652. __pyx_t_4 = 0;
  11653. __pyx_t_8 = 0;
  11654. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_3, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 802, __pyx_L1_error)
  11655. __Pyx_GOTREF(__pyx_t_2);
  11656. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  11657. }
  11658. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  11659. __pyx_v_tag = __pyx_t_2;
  11660. __pyx_t_2 = 0;
  11661. /* "_yaml.pyx":799
  11662. * if self.parsed_event.data.scalar.quoted_implicit == 1:
  11663. * quoted_implicit = True
  11664. * if self.parsed_event.data.scalar.tag == NULL \ # <<<<<<<<<<<<<<
  11665. * or (self.parsed_event.data.scalar.tag[0] == c'!'
  11666. * and self.parsed_event.data.scalar.tag[1] == c'\0'):
  11667. */
  11668. goto __pyx_L5;
  11669. }
  11670. /* "_yaml.pyx":804
  11671. * tag = self.resolve(ScalarNode, value, (plain_implicit, quoted_implicit))
  11672. * else:
  11673. * tag = PyUnicode_FromString(self.parsed_event.data.scalar.tag) # <<<<<<<<<<<<<<
  11674. * style = None
  11675. * if self.parsed_event.data.scalar.style == YAML_PLAIN_SCALAR_STYLE:
  11676. */
  11677. /*else*/ {
  11678. __pyx_t_2 = PyUnicode_FromString(__pyx_v_self->parsed_event.data.scalar.tag); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 804, __pyx_L1_error)
  11679. __Pyx_GOTREF(__pyx_t_2);
  11680. __pyx_v_tag = __pyx_t_2;
  11681. __pyx_t_2 = 0;
  11682. }
  11683. __pyx_L5:;
  11684. /* "_yaml.pyx":805
  11685. * else:
  11686. * tag = PyUnicode_FromString(self.parsed_event.data.scalar.tag)
  11687. * style = None # <<<<<<<<<<<<<<
  11688. * if self.parsed_event.data.scalar.style == YAML_PLAIN_SCALAR_STYLE:
  11689. * style = u''
  11690. */
  11691. __Pyx_INCREF(Py_None);
  11692. __pyx_v_style = ((PyObject*)Py_None);
  11693. /* "_yaml.pyx":806
  11694. * tag = PyUnicode_FromString(self.parsed_event.data.scalar.tag)
  11695. * style = None
  11696. * if self.parsed_event.data.scalar.style == YAML_PLAIN_SCALAR_STYLE: # <<<<<<<<<<<<<<
  11697. * style = u''
  11698. * elif self.parsed_event.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE:
  11699. */
  11700. switch (__pyx_v_self->parsed_event.data.scalar.style) {
  11701. case YAML_PLAIN_SCALAR_STYLE:
  11702. /* "_yaml.pyx":807
  11703. * style = None
  11704. * if self.parsed_event.data.scalar.style == YAML_PLAIN_SCALAR_STYLE:
  11705. * style = u'' # <<<<<<<<<<<<<<
  11706. * elif self.parsed_event.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE:
  11707. * style = u'\''
  11708. */
  11709. __Pyx_INCREF(__pyx_kp_u__6);
  11710. __Pyx_DECREF_SET(__pyx_v_style, __pyx_kp_u__6);
  11711. /* "_yaml.pyx":806
  11712. * tag = PyUnicode_FromString(self.parsed_event.data.scalar.tag)
  11713. * style = None
  11714. * if self.parsed_event.data.scalar.style == YAML_PLAIN_SCALAR_STYLE: # <<<<<<<<<<<<<<
  11715. * style = u''
  11716. * elif self.parsed_event.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE:
  11717. */
  11718. break;
  11719. case YAML_SINGLE_QUOTED_SCALAR_STYLE:
  11720. /* "_yaml.pyx":809
  11721. * style = u''
  11722. * elif self.parsed_event.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE:
  11723. * style = u'\'' # <<<<<<<<<<<<<<
  11724. * elif self.parsed_event.data.scalar.style == YAML_DOUBLE_QUOTED_SCALAR_STYLE:
  11725. * style = u'"'
  11726. */
  11727. __Pyx_INCREF(__pyx_kp_u__7);
  11728. __Pyx_DECREF_SET(__pyx_v_style, __pyx_kp_u__7);
  11729. /* "_yaml.pyx":808
  11730. * if self.parsed_event.data.scalar.style == YAML_PLAIN_SCALAR_STYLE:
  11731. * style = u''
  11732. * elif self.parsed_event.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE: # <<<<<<<<<<<<<<
  11733. * style = u'\''
  11734. * elif self.parsed_event.data.scalar.style == YAML_DOUBLE_QUOTED_SCALAR_STYLE:
  11735. */
  11736. break;
  11737. case YAML_DOUBLE_QUOTED_SCALAR_STYLE:
  11738. /* "_yaml.pyx":811
  11739. * style = u'\''
  11740. * elif self.parsed_event.data.scalar.style == YAML_DOUBLE_QUOTED_SCALAR_STYLE:
  11741. * style = u'"' # <<<<<<<<<<<<<<
  11742. * elif self.parsed_event.data.scalar.style == YAML_LITERAL_SCALAR_STYLE:
  11743. * style = u'|'
  11744. */
  11745. __Pyx_INCREF(__pyx_kp_u__8);
  11746. __Pyx_DECREF_SET(__pyx_v_style, __pyx_kp_u__8);
  11747. /* "_yaml.pyx":810
  11748. * elif self.parsed_event.data.scalar.style == YAML_SINGLE_QUOTED_SCALAR_STYLE:
  11749. * style = u'\''
  11750. * elif self.parsed_event.data.scalar.style == YAML_DOUBLE_QUOTED_SCALAR_STYLE: # <<<<<<<<<<<<<<
  11751. * style = u'"'
  11752. * elif self.parsed_event.data.scalar.style == YAML_LITERAL_SCALAR_STYLE:
  11753. */
  11754. break;
  11755. case YAML_LITERAL_SCALAR_STYLE:
  11756. /* "_yaml.pyx":813
  11757. * style = u'"'
  11758. * elif self.parsed_event.data.scalar.style == YAML_LITERAL_SCALAR_STYLE:
  11759. * style = u'|' # <<<<<<<<<<<<<<
  11760. * elif self.parsed_event.data.scalar.style == YAML_FOLDED_SCALAR_STYLE:
  11761. * style = u'>'
  11762. */
  11763. __Pyx_INCREF(__pyx_kp_u__9);
  11764. __Pyx_DECREF_SET(__pyx_v_style, __pyx_kp_u__9);
  11765. /* "_yaml.pyx":812
  11766. * elif self.parsed_event.data.scalar.style == YAML_DOUBLE_QUOTED_SCALAR_STYLE:
  11767. * style = u'"'
  11768. * elif self.parsed_event.data.scalar.style == YAML_LITERAL_SCALAR_STYLE: # <<<<<<<<<<<<<<
  11769. * style = u'|'
  11770. * elif self.parsed_event.data.scalar.style == YAML_FOLDED_SCALAR_STYLE:
  11771. */
  11772. break;
  11773. case YAML_FOLDED_SCALAR_STYLE:
  11774. /* "_yaml.pyx":815
  11775. * style = u'|'
  11776. * elif self.parsed_event.data.scalar.style == YAML_FOLDED_SCALAR_STYLE:
  11777. * style = u'>' # <<<<<<<<<<<<<<
  11778. * node = ScalarNode(tag, value, start_mark, end_mark, style)
  11779. * if anchor is not None:
  11780. */
  11781. __Pyx_INCREF(__pyx_kp_u__10);
  11782. __Pyx_DECREF_SET(__pyx_v_style, __pyx_kp_u__10);
  11783. /* "_yaml.pyx":814
  11784. * elif self.parsed_event.data.scalar.style == YAML_LITERAL_SCALAR_STYLE:
  11785. * style = u'|'
  11786. * elif self.parsed_event.data.scalar.style == YAML_FOLDED_SCALAR_STYLE: # <<<<<<<<<<<<<<
  11787. * style = u'>'
  11788. * node = ScalarNode(tag, value, start_mark, end_mark, style)
  11789. */
  11790. break;
  11791. default: break;
  11792. }
  11793. /* "_yaml.pyx":816
  11794. * elif self.parsed_event.data.scalar.style == YAML_FOLDED_SCALAR_STYLE:
  11795. * style = u'>'
  11796. * node = ScalarNode(tag, value, start_mark, end_mark, style) # <<<<<<<<<<<<<<
  11797. * if anchor is not None:
  11798. * self.anchors[anchor] = node
  11799. */
  11800. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_ScalarNode); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 816, __pyx_L1_error)
  11801. __Pyx_GOTREF(__pyx_t_1);
  11802. __pyx_t_3 = NULL;
  11803. __pyx_t_9 = 0;
  11804. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_1))) {
  11805. __pyx_t_3 = PyMethod_GET_SELF(__pyx_t_1);
  11806. if (likely(__pyx_t_3)) {
  11807. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  11808. __Pyx_INCREF(__pyx_t_3);
  11809. __Pyx_INCREF(function);
  11810. __Pyx_DECREF_SET(__pyx_t_1, function);
  11811. __pyx_t_9 = 1;
  11812. }
  11813. }
  11814. #if CYTHON_FAST_PYCALL
  11815. if (PyFunction_Check(__pyx_t_1)) {
  11816. PyObject *__pyx_temp[6] = {__pyx_t_3, __pyx_v_tag, __pyx_v_value, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_v_style};
  11817. __pyx_t_2 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_9, 5+__pyx_t_9); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 816, __pyx_L1_error)
  11818. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  11819. __Pyx_GOTREF(__pyx_t_2);
  11820. } else
  11821. #endif
  11822. #if CYTHON_FAST_PYCCALL
  11823. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  11824. PyObject *__pyx_temp[6] = {__pyx_t_3, __pyx_v_tag, __pyx_v_value, ((PyObject *)__pyx_v_start_mark), ((PyObject *)__pyx_v_end_mark), __pyx_v_style};
  11825. __pyx_t_2 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_9, 5+__pyx_t_9); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 816, __pyx_L1_error)
  11826. __Pyx_XDECREF(__pyx_t_3); __pyx_t_3 = 0;
  11827. __Pyx_GOTREF(__pyx_t_2);
  11828. } else
  11829. #endif
  11830. {
  11831. __pyx_t_8 = PyTuple_New(5+__pyx_t_9); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 816, __pyx_L1_error)
  11832. __Pyx_GOTREF(__pyx_t_8);
  11833. if (__pyx_t_3) {
  11834. __Pyx_GIVEREF(__pyx_t_3); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_3); __pyx_t_3 = NULL;
  11835. }
  11836. __Pyx_INCREF(__pyx_v_tag);
  11837. __Pyx_GIVEREF(__pyx_v_tag);
  11838. PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_9, __pyx_v_tag);
  11839. __Pyx_INCREF(__pyx_v_value);
  11840. __Pyx_GIVEREF(__pyx_v_value);
  11841. PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_9, __pyx_v_value);
  11842. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  11843. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  11844. PyTuple_SET_ITEM(__pyx_t_8, 2+__pyx_t_9, ((PyObject *)__pyx_v_start_mark));
  11845. __Pyx_INCREF(((PyObject *)__pyx_v_end_mark));
  11846. __Pyx_GIVEREF(((PyObject *)__pyx_v_end_mark));
  11847. PyTuple_SET_ITEM(__pyx_t_8, 3+__pyx_t_9, ((PyObject *)__pyx_v_end_mark));
  11848. __Pyx_INCREF(__pyx_v_style);
  11849. __Pyx_GIVEREF(__pyx_v_style);
  11850. PyTuple_SET_ITEM(__pyx_t_8, 4+__pyx_t_9, __pyx_v_style);
  11851. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_8, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 816, __pyx_L1_error)
  11852. __Pyx_GOTREF(__pyx_t_2);
  11853. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  11854. }
  11855. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  11856. __pyx_v_node = __pyx_t_2;
  11857. __pyx_t_2 = 0;
  11858. /* "_yaml.pyx":817
  11859. * style = u'>'
  11860. * node = ScalarNode(tag, value, start_mark, end_mark, style)
  11861. * if anchor is not None: # <<<<<<<<<<<<<<
  11862. * self.anchors[anchor] = node
  11863. * yaml_event_delete(&self.parsed_event)
  11864. */
  11865. __pyx_t_5 = (__pyx_v_anchor != Py_None);
  11866. __pyx_t_6 = (__pyx_t_5 != 0);
  11867. if (__pyx_t_6) {
  11868. /* "_yaml.pyx":818
  11869. * node = ScalarNode(tag, value, start_mark, end_mark, style)
  11870. * if anchor is not None:
  11871. * self.anchors[anchor] = node # <<<<<<<<<<<<<<
  11872. * yaml_event_delete(&self.parsed_event)
  11873. * return node
  11874. */
  11875. if (unlikely(PyObject_SetItem(__pyx_v_self->anchors, __pyx_v_anchor, __pyx_v_node) < 0)) __PYX_ERR(0, 818, __pyx_L1_error)
  11876. /* "_yaml.pyx":817
  11877. * style = u'>'
  11878. * node = ScalarNode(tag, value, start_mark, end_mark, style)
  11879. * if anchor is not None: # <<<<<<<<<<<<<<
  11880. * self.anchors[anchor] = node
  11881. * yaml_event_delete(&self.parsed_event)
  11882. */
  11883. }
  11884. /* "_yaml.pyx":819
  11885. * if anchor is not None:
  11886. * self.anchors[anchor] = node
  11887. * yaml_event_delete(&self.parsed_event) # <<<<<<<<<<<<<<
  11888. * return node
  11889. *
  11890. */
  11891. yaml_event_delete((&__pyx_v_self->parsed_event));
  11892. /* "_yaml.pyx":820
  11893. * self.anchors[anchor] = node
  11894. * yaml_event_delete(&self.parsed_event)
  11895. * return node # <<<<<<<<<<<<<<
  11896. *
  11897. * cdef _compose_sequence_node(self, object anchor):
  11898. */
  11899. __Pyx_XDECREF(__pyx_r);
  11900. __Pyx_INCREF(__pyx_v_node);
  11901. __pyx_r = __pyx_v_node;
  11902. goto __pyx_L0;
  11903. /* "_yaml.pyx":780
  11904. * return node
  11905. *
  11906. * cdef _compose_scalar_node(self, object anchor): # <<<<<<<<<<<<<<
  11907. * start_mark = Mark(self.stream_name,
  11908. * self.parsed_event.start_mark.index,
  11909. */
  11910. /* function exit code */
  11911. __pyx_L1_error:;
  11912. __Pyx_XDECREF(__pyx_t_1);
  11913. __Pyx_XDECREF(__pyx_t_2);
  11914. __Pyx_XDECREF(__pyx_t_3);
  11915. __Pyx_XDECREF(__pyx_t_4);
  11916. __Pyx_XDECREF(__pyx_t_7);
  11917. __Pyx_XDECREF(__pyx_t_8);
  11918. __Pyx_AddTraceback("_yaml.CParser._compose_scalar_node", __pyx_clineno, __pyx_lineno, __pyx_filename);
  11919. __pyx_r = 0;
  11920. __pyx_L0:;
  11921. __Pyx_XDECREF((PyObject *)__pyx_v_start_mark);
  11922. __Pyx_XDECREF((PyObject *)__pyx_v_end_mark);
  11923. __Pyx_XDECREF(__pyx_v_value);
  11924. __Pyx_XDECREF(__pyx_v_tag);
  11925. __Pyx_XDECREF(__pyx_v_style);
  11926. __Pyx_XDECREF(__pyx_v_node);
  11927. __Pyx_XGIVEREF(__pyx_r);
  11928. __Pyx_RefNannyFinishContext();
  11929. return __pyx_r;
  11930. }
  11931. /* "_yaml.pyx":822
  11932. * return node
  11933. *
  11934. * cdef _compose_sequence_node(self, object anchor): # <<<<<<<<<<<<<<
  11935. * cdef int index
  11936. * start_mark = Mark(self.stream_name,
  11937. */
  11938. static PyObject *__pyx_f_5_yaml_7CParser__compose_sequence_node(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, PyObject *__pyx_v_anchor) {
  11939. int __pyx_v_index;
  11940. struct __pyx_obj_5_yaml_Mark *__pyx_v_start_mark = NULL;
  11941. int __pyx_v_implicit;
  11942. PyObject *__pyx_v_tag = NULL;
  11943. PyObject *__pyx_v_flow_style = NULL;
  11944. PyObject *__pyx_v_value = NULL;
  11945. PyObject *__pyx_v_node = NULL;
  11946. PyObject *__pyx_r = NULL;
  11947. __Pyx_RefNannyDeclarations
  11948. PyObject *__pyx_t_1 = NULL;
  11949. PyObject *__pyx_t_2 = NULL;
  11950. PyObject *__pyx_t_3 = NULL;
  11951. PyObject *__pyx_t_4 = NULL;
  11952. int __pyx_t_5;
  11953. int __pyx_t_6;
  11954. PyObject *__pyx_t_7 = NULL;
  11955. int __pyx_t_8;
  11956. PyObject *__pyx_t_9 = NULL;
  11957. int __pyx_t_10;
  11958. __Pyx_RefNannySetupContext("_compose_sequence_node", 0);
  11959. /* "_yaml.pyx":825
  11960. * cdef int index
  11961. * start_mark = Mark(self.stream_name,
  11962. * self.parsed_event.start_mark.index, # <<<<<<<<<<<<<<
  11963. * self.parsed_event.start_mark.line,
  11964. * self.parsed_event.start_mark.column,
  11965. */
  11966. __pyx_t_1 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.index); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 825, __pyx_L1_error)
  11967. __Pyx_GOTREF(__pyx_t_1);
  11968. /* "_yaml.pyx":826
  11969. * start_mark = Mark(self.stream_name,
  11970. * self.parsed_event.start_mark.index,
  11971. * self.parsed_event.start_mark.line, # <<<<<<<<<<<<<<
  11972. * self.parsed_event.start_mark.column,
  11973. * None, None)
  11974. */
  11975. __pyx_t_2 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.line); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 826, __pyx_L1_error)
  11976. __Pyx_GOTREF(__pyx_t_2);
  11977. /* "_yaml.pyx":827
  11978. * self.parsed_event.start_mark.index,
  11979. * self.parsed_event.start_mark.line,
  11980. * self.parsed_event.start_mark.column, # <<<<<<<<<<<<<<
  11981. * None, None)
  11982. * implicit = False
  11983. */
  11984. __pyx_t_3 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.column); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 827, __pyx_L1_error)
  11985. __Pyx_GOTREF(__pyx_t_3);
  11986. /* "_yaml.pyx":824
  11987. * cdef _compose_sequence_node(self, object anchor):
  11988. * cdef int index
  11989. * start_mark = Mark(self.stream_name, # <<<<<<<<<<<<<<
  11990. * self.parsed_event.start_mark.index,
  11991. * self.parsed_event.start_mark.line,
  11992. */
  11993. __pyx_t_4 = PyTuple_New(6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 824, __pyx_L1_error)
  11994. __Pyx_GOTREF(__pyx_t_4);
  11995. __Pyx_INCREF(__pyx_v_self->stream_name);
  11996. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  11997. PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->stream_name);
  11998. __Pyx_GIVEREF(__pyx_t_1);
  11999. PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1);
  12000. __Pyx_GIVEREF(__pyx_t_2);
  12001. PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_2);
  12002. __Pyx_GIVEREF(__pyx_t_3);
  12003. PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_t_3);
  12004. __Pyx_INCREF(Py_None);
  12005. __Pyx_GIVEREF(Py_None);
  12006. PyTuple_SET_ITEM(__pyx_t_4, 4, Py_None);
  12007. __Pyx_INCREF(Py_None);
  12008. __Pyx_GIVEREF(Py_None);
  12009. PyTuple_SET_ITEM(__pyx_t_4, 5, Py_None);
  12010. __pyx_t_1 = 0;
  12011. __pyx_t_2 = 0;
  12012. __pyx_t_3 = 0;
  12013. __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 824, __pyx_L1_error)
  12014. __Pyx_GOTREF(__pyx_t_3);
  12015. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  12016. __pyx_v_start_mark = ((struct __pyx_obj_5_yaml_Mark *)__pyx_t_3);
  12017. __pyx_t_3 = 0;
  12018. /* "_yaml.pyx":829
  12019. * self.parsed_event.start_mark.column,
  12020. * None, None)
  12021. * implicit = False # <<<<<<<<<<<<<<
  12022. * if self.parsed_event.data.sequence_start.implicit == 1:
  12023. * implicit = True
  12024. */
  12025. __pyx_v_implicit = 0;
  12026. /* "_yaml.pyx":830
  12027. * None, None)
  12028. * implicit = False
  12029. * if self.parsed_event.data.sequence_start.implicit == 1: # <<<<<<<<<<<<<<
  12030. * implicit = True
  12031. * if self.parsed_event.data.sequence_start.tag == NULL \
  12032. */
  12033. __pyx_t_5 = ((__pyx_v_self->parsed_event.data.sequence_start.implicit == 1) != 0);
  12034. if (__pyx_t_5) {
  12035. /* "_yaml.pyx":831
  12036. * implicit = False
  12037. * if self.parsed_event.data.sequence_start.implicit == 1:
  12038. * implicit = True # <<<<<<<<<<<<<<
  12039. * if self.parsed_event.data.sequence_start.tag == NULL \
  12040. * or (self.parsed_event.data.sequence_start.tag[0] == c'!'
  12041. */
  12042. __pyx_v_implicit = 1;
  12043. /* "_yaml.pyx":830
  12044. * None, None)
  12045. * implicit = False
  12046. * if self.parsed_event.data.sequence_start.implicit == 1: # <<<<<<<<<<<<<<
  12047. * implicit = True
  12048. * if self.parsed_event.data.sequence_start.tag == NULL \
  12049. */
  12050. }
  12051. /* "_yaml.pyx":832
  12052. * if self.parsed_event.data.sequence_start.implicit == 1:
  12053. * implicit = True
  12054. * if self.parsed_event.data.sequence_start.tag == NULL \ # <<<<<<<<<<<<<<
  12055. * or (self.parsed_event.data.sequence_start.tag[0] == c'!'
  12056. * and self.parsed_event.data.sequence_start.tag[1] == c'\0'):
  12057. */
  12058. __pyx_t_6 = ((__pyx_v_self->parsed_event.data.sequence_start.tag == NULL) != 0);
  12059. if (!__pyx_t_6) {
  12060. } else {
  12061. __pyx_t_5 = __pyx_t_6;
  12062. goto __pyx_L5_bool_binop_done;
  12063. }
  12064. /* "_yaml.pyx":833
  12065. * implicit = True
  12066. * if self.parsed_event.data.sequence_start.tag == NULL \
  12067. * or (self.parsed_event.data.sequence_start.tag[0] == c'!' # <<<<<<<<<<<<<<
  12068. * and self.parsed_event.data.sequence_start.tag[1] == c'\0'):
  12069. * tag = self.resolve(SequenceNode, None, implicit)
  12070. */
  12071. __pyx_t_6 = (((__pyx_v_self->parsed_event.data.sequence_start.tag[0]) == '!') != 0);
  12072. if (__pyx_t_6) {
  12073. } else {
  12074. __pyx_t_5 = __pyx_t_6;
  12075. goto __pyx_L5_bool_binop_done;
  12076. }
  12077. /* "_yaml.pyx":834
  12078. * if self.parsed_event.data.sequence_start.tag == NULL \
  12079. * or (self.parsed_event.data.sequence_start.tag[0] == c'!'
  12080. * and self.parsed_event.data.sequence_start.tag[1] == c'\0'): # <<<<<<<<<<<<<<
  12081. * tag = self.resolve(SequenceNode, None, implicit)
  12082. * else:
  12083. */
  12084. __pyx_t_6 = (((__pyx_v_self->parsed_event.data.sequence_start.tag[1]) == '\x00') != 0);
  12085. __pyx_t_5 = __pyx_t_6;
  12086. __pyx_L5_bool_binop_done:;
  12087. /* "_yaml.pyx":832
  12088. * if self.parsed_event.data.sequence_start.implicit == 1:
  12089. * implicit = True
  12090. * if self.parsed_event.data.sequence_start.tag == NULL \ # <<<<<<<<<<<<<<
  12091. * or (self.parsed_event.data.sequence_start.tag[0] == c'!'
  12092. * and self.parsed_event.data.sequence_start.tag[1] == c'\0'):
  12093. */
  12094. if (__pyx_t_5) {
  12095. /* "_yaml.pyx":835
  12096. * or (self.parsed_event.data.sequence_start.tag[0] == c'!'
  12097. * and self.parsed_event.data.sequence_start.tag[1] == c'\0'):
  12098. * tag = self.resolve(SequenceNode, None, implicit) # <<<<<<<<<<<<<<
  12099. * else:
  12100. * tag = PyUnicode_FromString(self.parsed_event.data.sequence_start.tag)
  12101. */
  12102. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_resolve); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 835, __pyx_L1_error)
  12103. __Pyx_GOTREF(__pyx_t_4);
  12104. __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_SequenceNode); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 835, __pyx_L1_error)
  12105. __Pyx_GOTREF(__pyx_t_2);
  12106. __pyx_t_1 = __Pyx_PyBool_FromLong(__pyx_v_implicit); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 835, __pyx_L1_error)
  12107. __Pyx_GOTREF(__pyx_t_1);
  12108. __pyx_t_7 = NULL;
  12109. __pyx_t_8 = 0;
  12110. if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) {
  12111. __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4);
  12112. if (likely(__pyx_t_7)) {
  12113. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4);
  12114. __Pyx_INCREF(__pyx_t_7);
  12115. __Pyx_INCREF(function);
  12116. __Pyx_DECREF_SET(__pyx_t_4, function);
  12117. __pyx_t_8 = 1;
  12118. }
  12119. }
  12120. #if CYTHON_FAST_PYCALL
  12121. if (PyFunction_Check(__pyx_t_4)) {
  12122. PyObject *__pyx_temp[4] = {__pyx_t_7, __pyx_t_2, Py_None, __pyx_t_1};
  12123. __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_8, 3+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 835, __pyx_L1_error)
  12124. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  12125. __Pyx_GOTREF(__pyx_t_3);
  12126. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  12127. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  12128. } else
  12129. #endif
  12130. #if CYTHON_FAST_PYCCALL
  12131. if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) {
  12132. PyObject *__pyx_temp[4] = {__pyx_t_7, __pyx_t_2, Py_None, __pyx_t_1};
  12133. __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_8, 3+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 835, __pyx_L1_error)
  12134. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  12135. __Pyx_GOTREF(__pyx_t_3);
  12136. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  12137. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  12138. } else
  12139. #endif
  12140. {
  12141. __pyx_t_9 = PyTuple_New(3+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 835, __pyx_L1_error)
  12142. __Pyx_GOTREF(__pyx_t_9);
  12143. if (__pyx_t_7) {
  12144. __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_7); __pyx_t_7 = NULL;
  12145. }
  12146. __Pyx_GIVEREF(__pyx_t_2);
  12147. PyTuple_SET_ITEM(__pyx_t_9, 0+__pyx_t_8, __pyx_t_2);
  12148. __Pyx_INCREF(Py_None);
  12149. __Pyx_GIVEREF(Py_None);
  12150. PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_8, Py_None);
  12151. __Pyx_GIVEREF(__pyx_t_1);
  12152. PyTuple_SET_ITEM(__pyx_t_9, 2+__pyx_t_8, __pyx_t_1);
  12153. __pyx_t_2 = 0;
  12154. __pyx_t_1 = 0;
  12155. __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_9, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 835, __pyx_L1_error)
  12156. __Pyx_GOTREF(__pyx_t_3);
  12157. __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
  12158. }
  12159. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  12160. __pyx_v_tag = __pyx_t_3;
  12161. __pyx_t_3 = 0;
  12162. /* "_yaml.pyx":832
  12163. * if self.parsed_event.data.sequence_start.implicit == 1:
  12164. * implicit = True
  12165. * if self.parsed_event.data.sequence_start.tag == NULL \ # <<<<<<<<<<<<<<
  12166. * or (self.parsed_event.data.sequence_start.tag[0] == c'!'
  12167. * and self.parsed_event.data.sequence_start.tag[1] == c'\0'):
  12168. */
  12169. goto __pyx_L4;
  12170. }
  12171. /* "_yaml.pyx":837
  12172. * tag = self.resolve(SequenceNode, None, implicit)
  12173. * else:
  12174. * tag = PyUnicode_FromString(self.parsed_event.data.sequence_start.tag) # <<<<<<<<<<<<<<
  12175. * flow_style = None
  12176. * if self.parsed_event.data.sequence_start.style == YAML_FLOW_SEQUENCE_STYLE:
  12177. */
  12178. /*else*/ {
  12179. __pyx_t_3 = PyUnicode_FromString(__pyx_v_self->parsed_event.data.sequence_start.tag); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 837, __pyx_L1_error)
  12180. __Pyx_GOTREF(__pyx_t_3);
  12181. __pyx_v_tag = __pyx_t_3;
  12182. __pyx_t_3 = 0;
  12183. }
  12184. __pyx_L4:;
  12185. /* "_yaml.pyx":838
  12186. * else:
  12187. * tag = PyUnicode_FromString(self.parsed_event.data.sequence_start.tag)
  12188. * flow_style = None # <<<<<<<<<<<<<<
  12189. * if self.parsed_event.data.sequence_start.style == YAML_FLOW_SEQUENCE_STYLE:
  12190. * flow_style = True
  12191. */
  12192. __Pyx_INCREF(Py_None);
  12193. __pyx_v_flow_style = Py_None;
  12194. /* "_yaml.pyx":839
  12195. * tag = PyUnicode_FromString(self.parsed_event.data.sequence_start.tag)
  12196. * flow_style = None
  12197. * if self.parsed_event.data.sequence_start.style == YAML_FLOW_SEQUENCE_STYLE: # <<<<<<<<<<<<<<
  12198. * flow_style = True
  12199. * elif self.parsed_event.data.sequence_start.style == YAML_BLOCK_SEQUENCE_STYLE:
  12200. */
  12201. switch (__pyx_v_self->parsed_event.data.sequence_start.style) {
  12202. case YAML_FLOW_SEQUENCE_STYLE:
  12203. /* "_yaml.pyx":840
  12204. * flow_style = None
  12205. * if self.parsed_event.data.sequence_start.style == YAML_FLOW_SEQUENCE_STYLE:
  12206. * flow_style = True # <<<<<<<<<<<<<<
  12207. * elif self.parsed_event.data.sequence_start.style == YAML_BLOCK_SEQUENCE_STYLE:
  12208. * flow_style = False
  12209. */
  12210. __Pyx_INCREF(Py_True);
  12211. __Pyx_DECREF_SET(__pyx_v_flow_style, Py_True);
  12212. /* "_yaml.pyx":839
  12213. * tag = PyUnicode_FromString(self.parsed_event.data.sequence_start.tag)
  12214. * flow_style = None
  12215. * if self.parsed_event.data.sequence_start.style == YAML_FLOW_SEQUENCE_STYLE: # <<<<<<<<<<<<<<
  12216. * flow_style = True
  12217. * elif self.parsed_event.data.sequence_start.style == YAML_BLOCK_SEQUENCE_STYLE:
  12218. */
  12219. break;
  12220. case YAML_BLOCK_SEQUENCE_STYLE:
  12221. /* "_yaml.pyx":842
  12222. * flow_style = True
  12223. * elif self.parsed_event.data.sequence_start.style == YAML_BLOCK_SEQUENCE_STYLE:
  12224. * flow_style = False # <<<<<<<<<<<<<<
  12225. * value = []
  12226. * node = SequenceNode(tag, value, start_mark, None, flow_style)
  12227. */
  12228. __Pyx_INCREF(Py_False);
  12229. __Pyx_DECREF_SET(__pyx_v_flow_style, Py_False);
  12230. /* "_yaml.pyx":841
  12231. * if self.parsed_event.data.sequence_start.style == YAML_FLOW_SEQUENCE_STYLE:
  12232. * flow_style = True
  12233. * elif self.parsed_event.data.sequence_start.style == YAML_BLOCK_SEQUENCE_STYLE: # <<<<<<<<<<<<<<
  12234. * flow_style = False
  12235. * value = []
  12236. */
  12237. break;
  12238. default: break;
  12239. }
  12240. /* "_yaml.pyx":843
  12241. * elif self.parsed_event.data.sequence_start.style == YAML_BLOCK_SEQUENCE_STYLE:
  12242. * flow_style = False
  12243. * value = [] # <<<<<<<<<<<<<<
  12244. * node = SequenceNode(tag, value, start_mark, None, flow_style)
  12245. * if anchor is not None:
  12246. */
  12247. __pyx_t_3 = PyList_New(0); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 843, __pyx_L1_error)
  12248. __Pyx_GOTREF(__pyx_t_3);
  12249. __pyx_v_value = ((PyObject*)__pyx_t_3);
  12250. __pyx_t_3 = 0;
  12251. /* "_yaml.pyx":844
  12252. * flow_style = False
  12253. * value = []
  12254. * node = SequenceNode(tag, value, start_mark, None, flow_style) # <<<<<<<<<<<<<<
  12255. * if anchor is not None:
  12256. * self.anchors[anchor] = node
  12257. */
  12258. __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_SequenceNode); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 844, __pyx_L1_error)
  12259. __Pyx_GOTREF(__pyx_t_4);
  12260. __pyx_t_9 = NULL;
  12261. __pyx_t_8 = 0;
  12262. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) {
  12263. __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_4);
  12264. if (likely(__pyx_t_9)) {
  12265. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4);
  12266. __Pyx_INCREF(__pyx_t_9);
  12267. __Pyx_INCREF(function);
  12268. __Pyx_DECREF_SET(__pyx_t_4, function);
  12269. __pyx_t_8 = 1;
  12270. }
  12271. }
  12272. #if CYTHON_FAST_PYCALL
  12273. if (PyFunction_Check(__pyx_t_4)) {
  12274. PyObject *__pyx_temp[6] = {__pyx_t_9, __pyx_v_tag, __pyx_v_value, ((PyObject *)__pyx_v_start_mark), Py_None, __pyx_v_flow_style};
  12275. __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_8, 5+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 844, __pyx_L1_error)
  12276. __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
  12277. __Pyx_GOTREF(__pyx_t_3);
  12278. } else
  12279. #endif
  12280. #if CYTHON_FAST_PYCCALL
  12281. if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) {
  12282. PyObject *__pyx_temp[6] = {__pyx_t_9, __pyx_v_tag, __pyx_v_value, ((PyObject *)__pyx_v_start_mark), Py_None, __pyx_v_flow_style};
  12283. __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_8, 5+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 844, __pyx_L1_error)
  12284. __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
  12285. __Pyx_GOTREF(__pyx_t_3);
  12286. } else
  12287. #endif
  12288. {
  12289. __pyx_t_1 = PyTuple_New(5+__pyx_t_8); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 844, __pyx_L1_error)
  12290. __Pyx_GOTREF(__pyx_t_1);
  12291. if (__pyx_t_9) {
  12292. __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_9); __pyx_t_9 = NULL;
  12293. }
  12294. __Pyx_INCREF(__pyx_v_tag);
  12295. __Pyx_GIVEREF(__pyx_v_tag);
  12296. PyTuple_SET_ITEM(__pyx_t_1, 0+__pyx_t_8, __pyx_v_tag);
  12297. __Pyx_INCREF(__pyx_v_value);
  12298. __Pyx_GIVEREF(__pyx_v_value);
  12299. PyTuple_SET_ITEM(__pyx_t_1, 1+__pyx_t_8, __pyx_v_value);
  12300. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  12301. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  12302. PyTuple_SET_ITEM(__pyx_t_1, 2+__pyx_t_8, ((PyObject *)__pyx_v_start_mark));
  12303. __Pyx_INCREF(Py_None);
  12304. __Pyx_GIVEREF(Py_None);
  12305. PyTuple_SET_ITEM(__pyx_t_1, 3+__pyx_t_8, Py_None);
  12306. __Pyx_INCREF(__pyx_v_flow_style);
  12307. __Pyx_GIVEREF(__pyx_v_flow_style);
  12308. PyTuple_SET_ITEM(__pyx_t_1, 4+__pyx_t_8, __pyx_v_flow_style);
  12309. __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_1, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 844, __pyx_L1_error)
  12310. __Pyx_GOTREF(__pyx_t_3);
  12311. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  12312. }
  12313. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  12314. __pyx_v_node = __pyx_t_3;
  12315. __pyx_t_3 = 0;
  12316. /* "_yaml.pyx":845
  12317. * value = []
  12318. * node = SequenceNode(tag, value, start_mark, None, flow_style)
  12319. * if anchor is not None: # <<<<<<<<<<<<<<
  12320. * self.anchors[anchor] = node
  12321. * yaml_event_delete(&self.parsed_event)
  12322. */
  12323. __pyx_t_5 = (__pyx_v_anchor != Py_None);
  12324. __pyx_t_6 = (__pyx_t_5 != 0);
  12325. if (__pyx_t_6) {
  12326. /* "_yaml.pyx":846
  12327. * node = SequenceNode(tag, value, start_mark, None, flow_style)
  12328. * if anchor is not None:
  12329. * self.anchors[anchor] = node # <<<<<<<<<<<<<<
  12330. * yaml_event_delete(&self.parsed_event)
  12331. * index = 0
  12332. */
  12333. if (unlikely(PyObject_SetItem(__pyx_v_self->anchors, __pyx_v_anchor, __pyx_v_node) < 0)) __PYX_ERR(0, 846, __pyx_L1_error)
  12334. /* "_yaml.pyx":845
  12335. * value = []
  12336. * node = SequenceNode(tag, value, start_mark, None, flow_style)
  12337. * if anchor is not None: # <<<<<<<<<<<<<<
  12338. * self.anchors[anchor] = node
  12339. * yaml_event_delete(&self.parsed_event)
  12340. */
  12341. }
  12342. /* "_yaml.pyx":847
  12343. * if anchor is not None:
  12344. * self.anchors[anchor] = node
  12345. * yaml_event_delete(&self.parsed_event) # <<<<<<<<<<<<<<
  12346. * index = 0
  12347. * self._parse_next_event()
  12348. */
  12349. yaml_event_delete((&__pyx_v_self->parsed_event));
  12350. /* "_yaml.pyx":848
  12351. * self.anchors[anchor] = node
  12352. * yaml_event_delete(&self.parsed_event)
  12353. * index = 0 # <<<<<<<<<<<<<<
  12354. * self._parse_next_event()
  12355. * while self.parsed_event.type != YAML_SEQUENCE_END_EVENT:
  12356. */
  12357. __pyx_v_index = 0;
  12358. /* "_yaml.pyx":849
  12359. * yaml_event_delete(&self.parsed_event)
  12360. * index = 0
  12361. * self._parse_next_event() # <<<<<<<<<<<<<<
  12362. * while self.parsed_event.type != YAML_SEQUENCE_END_EVENT:
  12363. * value.append(self._compose_node(node, index))
  12364. */
  12365. __pyx_t_8 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parse_next_event(__pyx_v_self); if (unlikely(__pyx_t_8 == ((int)0))) __PYX_ERR(0, 849, __pyx_L1_error)
  12366. /* "_yaml.pyx":850
  12367. * index = 0
  12368. * self._parse_next_event()
  12369. * while self.parsed_event.type != YAML_SEQUENCE_END_EVENT: # <<<<<<<<<<<<<<
  12370. * value.append(self._compose_node(node, index))
  12371. * index = index+1
  12372. */
  12373. while (1) {
  12374. __pyx_t_6 = ((__pyx_v_self->parsed_event.type != YAML_SEQUENCE_END_EVENT) != 0);
  12375. if (!__pyx_t_6) break;
  12376. /* "_yaml.pyx":851
  12377. * self._parse_next_event()
  12378. * while self.parsed_event.type != YAML_SEQUENCE_END_EVENT:
  12379. * value.append(self._compose_node(node, index)) # <<<<<<<<<<<<<<
  12380. * index = index+1
  12381. * self._parse_next_event()
  12382. */
  12383. __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_index); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 851, __pyx_L1_error)
  12384. __Pyx_GOTREF(__pyx_t_3);
  12385. __pyx_t_4 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_compose_node(__pyx_v_self, __pyx_v_node, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 851, __pyx_L1_error)
  12386. __Pyx_GOTREF(__pyx_t_4);
  12387. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  12388. __pyx_t_10 = __Pyx_PyList_Append(__pyx_v_value, __pyx_t_4); if (unlikely(__pyx_t_10 == ((int)-1))) __PYX_ERR(0, 851, __pyx_L1_error)
  12389. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  12390. /* "_yaml.pyx":852
  12391. * while self.parsed_event.type != YAML_SEQUENCE_END_EVENT:
  12392. * value.append(self._compose_node(node, index))
  12393. * index = index+1 # <<<<<<<<<<<<<<
  12394. * self._parse_next_event()
  12395. * node.end_mark = Mark(self.stream_name,
  12396. */
  12397. __pyx_v_index = (__pyx_v_index + 1);
  12398. /* "_yaml.pyx":853
  12399. * value.append(self._compose_node(node, index))
  12400. * index = index+1
  12401. * self._parse_next_event() # <<<<<<<<<<<<<<
  12402. * node.end_mark = Mark(self.stream_name,
  12403. * self.parsed_event.end_mark.index,
  12404. */
  12405. __pyx_t_8 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parse_next_event(__pyx_v_self); if (unlikely(__pyx_t_8 == ((int)0))) __PYX_ERR(0, 853, __pyx_L1_error)
  12406. }
  12407. /* "_yaml.pyx":855
  12408. * self._parse_next_event()
  12409. * node.end_mark = Mark(self.stream_name,
  12410. * self.parsed_event.end_mark.index, # <<<<<<<<<<<<<<
  12411. * self.parsed_event.end_mark.line,
  12412. * self.parsed_event.end_mark.column,
  12413. */
  12414. __pyx_t_4 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.end_mark.index); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 855, __pyx_L1_error)
  12415. __Pyx_GOTREF(__pyx_t_4);
  12416. /* "_yaml.pyx":856
  12417. * node.end_mark = Mark(self.stream_name,
  12418. * self.parsed_event.end_mark.index,
  12419. * self.parsed_event.end_mark.line, # <<<<<<<<<<<<<<
  12420. * self.parsed_event.end_mark.column,
  12421. * None, None)
  12422. */
  12423. __pyx_t_3 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.end_mark.line); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 856, __pyx_L1_error)
  12424. __Pyx_GOTREF(__pyx_t_3);
  12425. /* "_yaml.pyx":857
  12426. * self.parsed_event.end_mark.index,
  12427. * self.parsed_event.end_mark.line,
  12428. * self.parsed_event.end_mark.column, # <<<<<<<<<<<<<<
  12429. * None, None)
  12430. * yaml_event_delete(&self.parsed_event)
  12431. */
  12432. __pyx_t_1 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.end_mark.column); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 857, __pyx_L1_error)
  12433. __Pyx_GOTREF(__pyx_t_1);
  12434. /* "_yaml.pyx":854
  12435. * index = index+1
  12436. * self._parse_next_event()
  12437. * node.end_mark = Mark(self.stream_name, # <<<<<<<<<<<<<<
  12438. * self.parsed_event.end_mark.index,
  12439. * self.parsed_event.end_mark.line,
  12440. */
  12441. __pyx_t_9 = PyTuple_New(6); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 854, __pyx_L1_error)
  12442. __Pyx_GOTREF(__pyx_t_9);
  12443. __Pyx_INCREF(__pyx_v_self->stream_name);
  12444. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  12445. PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_v_self->stream_name);
  12446. __Pyx_GIVEREF(__pyx_t_4);
  12447. PyTuple_SET_ITEM(__pyx_t_9, 1, __pyx_t_4);
  12448. __Pyx_GIVEREF(__pyx_t_3);
  12449. PyTuple_SET_ITEM(__pyx_t_9, 2, __pyx_t_3);
  12450. __Pyx_GIVEREF(__pyx_t_1);
  12451. PyTuple_SET_ITEM(__pyx_t_9, 3, __pyx_t_1);
  12452. __Pyx_INCREF(Py_None);
  12453. __Pyx_GIVEREF(Py_None);
  12454. PyTuple_SET_ITEM(__pyx_t_9, 4, Py_None);
  12455. __Pyx_INCREF(Py_None);
  12456. __Pyx_GIVEREF(Py_None);
  12457. PyTuple_SET_ITEM(__pyx_t_9, 5, Py_None);
  12458. __pyx_t_4 = 0;
  12459. __pyx_t_3 = 0;
  12460. __pyx_t_1 = 0;
  12461. __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_t_9, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 854, __pyx_L1_error)
  12462. __Pyx_GOTREF(__pyx_t_1);
  12463. __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
  12464. if (__Pyx_PyObject_SetAttrStr(__pyx_v_node, __pyx_n_s_end_mark, __pyx_t_1) < 0) __PYX_ERR(0, 854, __pyx_L1_error)
  12465. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  12466. /* "_yaml.pyx":859
  12467. * self.parsed_event.end_mark.column,
  12468. * None, None)
  12469. * yaml_event_delete(&self.parsed_event) # <<<<<<<<<<<<<<
  12470. * return node
  12471. *
  12472. */
  12473. yaml_event_delete((&__pyx_v_self->parsed_event));
  12474. /* "_yaml.pyx":860
  12475. * None, None)
  12476. * yaml_event_delete(&self.parsed_event)
  12477. * return node # <<<<<<<<<<<<<<
  12478. *
  12479. * cdef _compose_mapping_node(self, object anchor):
  12480. */
  12481. __Pyx_XDECREF(__pyx_r);
  12482. __Pyx_INCREF(__pyx_v_node);
  12483. __pyx_r = __pyx_v_node;
  12484. goto __pyx_L0;
  12485. /* "_yaml.pyx":822
  12486. * return node
  12487. *
  12488. * cdef _compose_sequence_node(self, object anchor): # <<<<<<<<<<<<<<
  12489. * cdef int index
  12490. * start_mark = Mark(self.stream_name,
  12491. */
  12492. /* function exit code */
  12493. __pyx_L1_error:;
  12494. __Pyx_XDECREF(__pyx_t_1);
  12495. __Pyx_XDECREF(__pyx_t_2);
  12496. __Pyx_XDECREF(__pyx_t_3);
  12497. __Pyx_XDECREF(__pyx_t_4);
  12498. __Pyx_XDECREF(__pyx_t_7);
  12499. __Pyx_XDECREF(__pyx_t_9);
  12500. __Pyx_AddTraceback("_yaml.CParser._compose_sequence_node", __pyx_clineno, __pyx_lineno, __pyx_filename);
  12501. __pyx_r = 0;
  12502. __pyx_L0:;
  12503. __Pyx_XDECREF((PyObject *)__pyx_v_start_mark);
  12504. __Pyx_XDECREF(__pyx_v_tag);
  12505. __Pyx_XDECREF(__pyx_v_flow_style);
  12506. __Pyx_XDECREF(__pyx_v_value);
  12507. __Pyx_XDECREF(__pyx_v_node);
  12508. __Pyx_XGIVEREF(__pyx_r);
  12509. __Pyx_RefNannyFinishContext();
  12510. return __pyx_r;
  12511. }
  12512. /* "_yaml.pyx":862
  12513. * return node
  12514. *
  12515. * cdef _compose_mapping_node(self, object anchor): # <<<<<<<<<<<<<<
  12516. * start_mark = Mark(self.stream_name,
  12517. * self.parsed_event.start_mark.index,
  12518. */
  12519. static PyObject *__pyx_f_5_yaml_7CParser__compose_mapping_node(struct __pyx_obj_5_yaml_CParser *__pyx_v_self, PyObject *__pyx_v_anchor) {
  12520. struct __pyx_obj_5_yaml_Mark *__pyx_v_start_mark = NULL;
  12521. int __pyx_v_implicit;
  12522. PyObject *__pyx_v_tag = NULL;
  12523. PyObject *__pyx_v_flow_style = NULL;
  12524. PyObject *__pyx_v_value = NULL;
  12525. PyObject *__pyx_v_node = NULL;
  12526. PyObject *__pyx_v_item_key = NULL;
  12527. PyObject *__pyx_v_item_value = NULL;
  12528. PyObject *__pyx_r = NULL;
  12529. __Pyx_RefNannyDeclarations
  12530. PyObject *__pyx_t_1 = NULL;
  12531. PyObject *__pyx_t_2 = NULL;
  12532. PyObject *__pyx_t_3 = NULL;
  12533. PyObject *__pyx_t_4 = NULL;
  12534. int __pyx_t_5;
  12535. int __pyx_t_6;
  12536. PyObject *__pyx_t_7 = NULL;
  12537. int __pyx_t_8;
  12538. PyObject *__pyx_t_9 = NULL;
  12539. int __pyx_t_10;
  12540. __Pyx_RefNannySetupContext("_compose_mapping_node", 0);
  12541. /* "_yaml.pyx":864
  12542. * cdef _compose_mapping_node(self, object anchor):
  12543. * start_mark = Mark(self.stream_name,
  12544. * self.parsed_event.start_mark.index, # <<<<<<<<<<<<<<
  12545. * self.parsed_event.start_mark.line,
  12546. * self.parsed_event.start_mark.column,
  12547. */
  12548. __pyx_t_1 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.index); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 864, __pyx_L1_error)
  12549. __Pyx_GOTREF(__pyx_t_1);
  12550. /* "_yaml.pyx":865
  12551. * start_mark = Mark(self.stream_name,
  12552. * self.parsed_event.start_mark.index,
  12553. * self.parsed_event.start_mark.line, # <<<<<<<<<<<<<<
  12554. * self.parsed_event.start_mark.column,
  12555. * None, None)
  12556. */
  12557. __pyx_t_2 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.line); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 865, __pyx_L1_error)
  12558. __Pyx_GOTREF(__pyx_t_2);
  12559. /* "_yaml.pyx":866
  12560. * self.parsed_event.start_mark.index,
  12561. * self.parsed_event.start_mark.line,
  12562. * self.parsed_event.start_mark.column, # <<<<<<<<<<<<<<
  12563. * None, None)
  12564. * implicit = False
  12565. */
  12566. __pyx_t_3 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.start_mark.column); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 866, __pyx_L1_error)
  12567. __Pyx_GOTREF(__pyx_t_3);
  12568. /* "_yaml.pyx":863
  12569. *
  12570. * cdef _compose_mapping_node(self, object anchor):
  12571. * start_mark = Mark(self.stream_name, # <<<<<<<<<<<<<<
  12572. * self.parsed_event.start_mark.index,
  12573. * self.parsed_event.start_mark.line,
  12574. */
  12575. __pyx_t_4 = PyTuple_New(6); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 863, __pyx_L1_error)
  12576. __Pyx_GOTREF(__pyx_t_4);
  12577. __Pyx_INCREF(__pyx_v_self->stream_name);
  12578. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  12579. PyTuple_SET_ITEM(__pyx_t_4, 0, __pyx_v_self->stream_name);
  12580. __Pyx_GIVEREF(__pyx_t_1);
  12581. PyTuple_SET_ITEM(__pyx_t_4, 1, __pyx_t_1);
  12582. __Pyx_GIVEREF(__pyx_t_2);
  12583. PyTuple_SET_ITEM(__pyx_t_4, 2, __pyx_t_2);
  12584. __Pyx_GIVEREF(__pyx_t_3);
  12585. PyTuple_SET_ITEM(__pyx_t_4, 3, __pyx_t_3);
  12586. __Pyx_INCREF(Py_None);
  12587. __Pyx_GIVEREF(Py_None);
  12588. PyTuple_SET_ITEM(__pyx_t_4, 4, Py_None);
  12589. __Pyx_INCREF(Py_None);
  12590. __Pyx_GIVEREF(Py_None);
  12591. PyTuple_SET_ITEM(__pyx_t_4, 5, Py_None);
  12592. __pyx_t_1 = 0;
  12593. __pyx_t_2 = 0;
  12594. __pyx_t_3 = 0;
  12595. __pyx_t_3 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_t_4, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 863, __pyx_L1_error)
  12596. __Pyx_GOTREF(__pyx_t_3);
  12597. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  12598. __pyx_v_start_mark = ((struct __pyx_obj_5_yaml_Mark *)__pyx_t_3);
  12599. __pyx_t_3 = 0;
  12600. /* "_yaml.pyx":868
  12601. * self.parsed_event.start_mark.column,
  12602. * None, None)
  12603. * implicit = False # <<<<<<<<<<<<<<
  12604. * if self.parsed_event.data.mapping_start.implicit == 1:
  12605. * implicit = True
  12606. */
  12607. __pyx_v_implicit = 0;
  12608. /* "_yaml.pyx":869
  12609. * None, None)
  12610. * implicit = False
  12611. * if self.parsed_event.data.mapping_start.implicit == 1: # <<<<<<<<<<<<<<
  12612. * implicit = True
  12613. * if self.parsed_event.data.mapping_start.tag == NULL \
  12614. */
  12615. __pyx_t_5 = ((__pyx_v_self->parsed_event.data.mapping_start.implicit == 1) != 0);
  12616. if (__pyx_t_5) {
  12617. /* "_yaml.pyx":870
  12618. * implicit = False
  12619. * if self.parsed_event.data.mapping_start.implicit == 1:
  12620. * implicit = True # <<<<<<<<<<<<<<
  12621. * if self.parsed_event.data.mapping_start.tag == NULL \
  12622. * or (self.parsed_event.data.mapping_start.tag[0] == c'!'
  12623. */
  12624. __pyx_v_implicit = 1;
  12625. /* "_yaml.pyx":869
  12626. * None, None)
  12627. * implicit = False
  12628. * if self.parsed_event.data.mapping_start.implicit == 1: # <<<<<<<<<<<<<<
  12629. * implicit = True
  12630. * if self.parsed_event.data.mapping_start.tag == NULL \
  12631. */
  12632. }
  12633. /* "_yaml.pyx":871
  12634. * if self.parsed_event.data.mapping_start.implicit == 1:
  12635. * implicit = True
  12636. * if self.parsed_event.data.mapping_start.tag == NULL \ # <<<<<<<<<<<<<<
  12637. * or (self.parsed_event.data.mapping_start.tag[0] == c'!'
  12638. * and self.parsed_event.data.mapping_start.tag[1] == c'\0'):
  12639. */
  12640. __pyx_t_6 = ((__pyx_v_self->parsed_event.data.mapping_start.tag == NULL) != 0);
  12641. if (!__pyx_t_6) {
  12642. } else {
  12643. __pyx_t_5 = __pyx_t_6;
  12644. goto __pyx_L5_bool_binop_done;
  12645. }
  12646. /* "_yaml.pyx":872
  12647. * implicit = True
  12648. * if self.parsed_event.data.mapping_start.tag == NULL \
  12649. * or (self.parsed_event.data.mapping_start.tag[0] == c'!' # <<<<<<<<<<<<<<
  12650. * and self.parsed_event.data.mapping_start.tag[1] == c'\0'):
  12651. * tag = self.resolve(MappingNode, None, implicit)
  12652. */
  12653. __pyx_t_6 = (((__pyx_v_self->parsed_event.data.mapping_start.tag[0]) == '!') != 0);
  12654. if (__pyx_t_6) {
  12655. } else {
  12656. __pyx_t_5 = __pyx_t_6;
  12657. goto __pyx_L5_bool_binop_done;
  12658. }
  12659. /* "_yaml.pyx":873
  12660. * if self.parsed_event.data.mapping_start.tag == NULL \
  12661. * or (self.parsed_event.data.mapping_start.tag[0] == c'!'
  12662. * and self.parsed_event.data.mapping_start.tag[1] == c'\0'): # <<<<<<<<<<<<<<
  12663. * tag = self.resolve(MappingNode, None, implicit)
  12664. * else:
  12665. */
  12666. __pyx_t_6 = (((__pyx_v_self->parsed_event.data.mapping_start.tag[1]) == '\x00') != 0);
  12667. __pyx_t_5 = __pyx_t_6;
  12668. __pyx_L5_bool_binop_done:;
  12669. /* "_yaml.pyx":871
  12670. * if self.parsed_event.data.mapping_start.implicit == 1:
  12671. * implicit = True
  12672. * if self.parsed_event.data.mapping_start.tag == NULL \ # <<<<<<<<<<<<<<
  12673. * or (self.parsed_event.data.mapping_start.tag[0] == c'!'
  12674. * and self.parsed_event.data.mapping_start.tag[1] == c'\0'):
  12675. */
  12676. if (__pyx_t_5) {
  12677. /* "_yaml.pyx":874
  12678. * or (self.parsed_event.data.mapping_start.tag[0] == c'!'
  12679. * and self.parsed_event.data.mapping_start.tag[1] == c'\0'):
  12680. * tag = self.resolve(MappingNode, None, implicit) # <<<<<<<<<<<<<<
  12681. * else:
  12682. * tag = PyUnicode_FromString(self.parsed_event.data.mapping_start.tag)
  12683. */
  12684. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_resolve); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 874, __pyx_L1_error)
  12685. __Pyx_GOTREF(__pyx_t_4);
  12686. __Pyx_GetModuleGlobalName(__pyx_t_2, __pyx_n_s_MappingNode); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 874, __pyx_L1_error)
  12687. __Pyx_GOTREF(__pyx_t_2);
  12688. __pyx_t_1 = __Pyx_PyBool_FromLong(__pyx_v_implicit); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 874, __pyx_L1_error)
  12689. __Pyx_GOTREF(__pyx_t_1);
  12690. __pyx_t_7 = NULL;
  12691. __pyx_t_8 = 0;
  12692. if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) {
  12693. __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_4);
  12694. if (likely(__pyx_t_7)) {
  12695. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4);
  12696. __Pyx_INCREF(__pyx_t_7);
  12697. __Pyx_INCREF(function);
  12698. __Pyx_DECREF_SET(__pyx_t_4, function);
  12699. __pyx_t_8 = 1;
  12700. }
  12701. }
  12702. #if CYTHON_FAST_PYCALL
  12703. if (PyFunction_Check(__pyx_t_4)) {
  12704. PyObject *__pyx_temp[4] = {__pyx_t_7, __pyx_t_2, Py_None, __pyx_t_1};
  12705. __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_8, 3+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 874, __pyx_L1_error)
  12706. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  12707. __Pyx_GOTREF(__pyx_t_3);
  12708. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  12709. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  12710. } else
  12711. #endif
  12712. #if CYTHON_FAST_PYCCALL
  12713. if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) {
  12714. PyObject *__pyx_temp[4] = {__pyx_t_7, __pyx_t_2, Py_None, __pyx_t_1};
  12715. __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_8, 3+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 874, __pyx_L1_error)
  12716. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  12717. __Pyx_GOTREF(__pyx_t_3);
  12718. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  12719. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  12720. } else
  12721. #endif
  12722. {
  12723. __pyx_t_9 = PyTuple_New(3+__pyx_t_8); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 874, __pyx_L1_error)
  12724. __Pyx_GOTREF(__pyx_t_9);
  12725. if (__pyx_t_7) {
  12726. __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_7); __pyx_t_7 = NULL;
  12727. }
  12728. __Pyx_GIVEREF(__pyx_t_2);
  12729. PyTuple_SET_ITEM(__pyx_t_9, 0+__pyx_t_8, __pyx_t_2);
  12730. __Pyx_INCREF(Py_None);
  12731. __Pyx_GIVEREF(Py_None);
  12732. PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_8, Py_None);
  12733. __Pyx_GIVEREF(__pyx_t_1);
  12734. PyTuple_SET_ITEM(__pyx_t_9, 2+__pyx_t_8, __pyx_t_1);
  12735. __pyx_t_2 = 0;
  12736. __pyx_t_1 = 0;
  12737. __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_9, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 874, __pyx_L1_error)
  12738. __Pyx_GOTREF(__pyx_t_3);
  12739. __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
  12740. }
  12741. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  12742. __pyx_v_tag = __pyx_t_3;
  12743. __pyx_t_3 = 0;
  12744. /* "_yaml.pyx":871
  12745. * if self.parsed_event.data.mapping_start.implicit == 1:
  12746. * implicit = True
  12747. * if self.parsed_event.data.mapping_start.tag == NULL \ # <<<<<<<<<<<<<<
  12748. * or (self.parsed_event.data.mapping_start.tag[0] == c'!'
  12749. * and self.parsed_event.data.mapping_start.tag[1] == c'\0'):
  12750. */
  12751. goto __pyx_L4;
  12752. }
  12753. /* "_yaml.pyx":876
  12754. * tag = self.resolve(MappingNode, None, implicit)
  12755. * else:
  12756. * tag = PyUnicode_FromString(self.parsed_event.data.mapping_start.tag) # <<<<<<<<<<<<<<
  12757. * flow_style = None
  12758. * if self.parsed_event.data.mapping_start.style == YAML_FLOW_MAPPING_STYLE:
  12759. */
  12760. /*else*/ {
  12761. __pyx_t_3 = PyUnicode_FromString(__pyx_v_self->parsed_event.data.mapping_start.tag); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 876, __pyx_L1_error)
  12762. __Pyx_GOTREF(__pyx_t_3);
  12763. __pyx_v_tag = __pyx_t_3;
  12764. __pyx_t_3 = 0;
  12765. }
  12766. __pyx_L4:;
  12767. /* "_yaml.pyx":877
  12768. * else:
  12769. * tag = PyUnicode_FromString(self.parsed_event.data.mapping_start.tag)
  12770. * flow_style = None # <<<<<<<<<<<<<<
  12771. * if self.parsed_event.data.mapping_start.style == YAML_FLOW_MAPPING_STYLE:
  12772. * flow_style = True
  12773. */
  12774. __Pyx_INCREF(Py_None);
  12775. __pyx_v_flow_style = Py_None;
  12776. /* "_yaml.pyx":878
  12777. * tag = PyUnicode_FromString(self.parsed_event.data.mapping_start.tag)
  12778. * flow_style = None
  12779. * if self.parsed_event.data.mapping_start.style == YAML_FLOW_MAPPING_STYLE: # <<<<<<<<<<<<<<
  12780. * flow_style = True
  12781. * elif self.parsed_event.data.mapping_start.style == YAML_BLOCK_MAPPING_STYLE:
  12782. */
  12783. switch (__pyx_v_self->parsed_event.data.mapping_start.style) {
  12784. case YAML_FLOW_MAPPING_STYLE:
  12785. /* "_yaml.pyx":879
  12786. * flow_style = None
  12787. * if self.parsed_event.data.mapping_start.style == YAML_FLOW_MAPPING_STYLE:
  12788. * flow_style = True # <<<<<<<<<<<<<<
  12789. * elif self.parsed_event.data.mapping_start.style == YAML_BLOCK_MAPPING_STYLE:
  12790. * flow_style = False
  12791. */
  12792. __Pyx_INCREF(Py_True);
  12793. __Pyx_DECREF_SET(__pyx_v_flow_style, Py_True);
  12794. /* "_yaml.pyx":878
  12795. * tag = PyUnicode_FromString(self.parsed_event.data.mapping_start.tag)
  12796. * flow_style = None
  12797. * if self.parsed_event.data.mapping_start.style == YAML_FLOW_MAPPING_STYLE: # <<<<<<<<<<<<<<
  12798. * flow_style = True
  12799. * elif self.parsed_event.data.mapping_start.style == YAML_BLOCK_MAPPING_STYLE:
  12800. */
  12801. break;
  12802. case YAML_BLOCK_MAPPING_STYLE:
  12803. /* "_yaml.pyx":881
  12804. * flow_style = True
  12805. * elif self.parsed_event.data.mapping_start.style == YAML_BLOCK_MAPPING_STYLE:
  12806. * flow_style = False # <<<<<<<<<<<<<<
  12807. * value = []
  12808. * node = MappingNode(tag, value, start_mark, None, flow_style)
  12809. */
  12810. __Pyx_INCREF(Py_False);
  12811. __Pyx_DECREF_SET(__pyx_v_flow_style, Py_False);
  12812. /* "_yaml.pyx":880
  12813. * if self.parsed_event.data.mapping_start.style == YAML_FLOW_MAPPING_STYLE:
  12814. * flow_style = True
  12815. * elif self.parsed_event.data.mapping_start.style == YAML_BLOCK_MAPPING_STYLE: # <<<<<<<<<<<<<<
  12816. * flow_style = False
  12817. * value = []
  12818. */
  12819. break;
  12820. default: break;
  12821. }
  12822. /* "_yaml.pyx":882
  12823. * elif self.parsed_event.data.mapping_start.style == YAML_BLOCK_MAPPING_STYLE:
  12824. * flow_style = False
  12825. * value = [] # <<<<<<<<<<<<<<
  12826. * node = MappingNode(tag, value, start_mark, None, flow_style)
  12827. * if anchor is not None:
  12828. */
  12829. __pyx_t_3 = PyList_New(0); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 882, __pyx_L1_error)
  12830. __Pyx_GOTREF(__pyx_t_3);
  12831. __pyx_v_value = ((PyObject*)__pyx_t_3);
  12832. __pyx_t_3 = 0;
  12833. /* "_yaml.pyx":883
  12834. * flow_style = False
  12835. * value = []
  12836. * node = MappingNode(tag, value, start_mark, None, flow_style) # <<<<<<<<<<<<<<
  12837. * if anchor is not None:
  12838. * self.anchors[anchor] = node
  12839. */
  12840. __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_MappingNode); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 883, __pyx_L1_error)
  12841. __Pyx_GOTREF(__pyx_t_4);
  12842. __pyx_t_9 = NULL;
  12843. __pyx_t_8 = 0;
  12844. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_4))) {
  12845. __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_4);
  12846. if (likely(__pyx_t_9)) {
  12847. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4);
  12848. __Pyx_INCREF(__pyx_t_9);
  12849. __Pyx_INCREF(function);
  12850. __Pyx_DECREF_SET(__pyx_t_4, function);
  12851. __pyx_t_8 = 1;
  12852. }
  12853. }
  12854. #if CYTHON_FAST_PYCALL
  12855. if (PyFunction_Check(__pyx_t_4)) {
  12856. PyObject *__pyx_temp[6] = {__pyx_t_9, __pyx_v_tag, __pyx_v_value, ((PyObject *)__pyx_v_start_mark), Py_None, __pyx_v_flow_style};
  12857. __pyx_t_3 = __Pyx_PyFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_8, 5+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 883, __pyx_L1_error)
  12858. __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
  12859. __Pyx_GOTREF(__pyx_t_3);
  12860. } else
  12861. #endif
  12862. #if CYTHON_FAST_PYCCALL
  12863. if (__Pyx_PyFastCFunction_Check(__pyx_t_4)) {
  12864. PyObject *__pyx_temp[6] = {__pyx_t_9, __pyx_v_tag, __pyx_v_value, ((PyObject *)__pyx_v_start_mark), Py_None, __pyx_v_flow_style};
  12865. __pyx_t_3 = __Pyx_PyCFunction_FastCall(__pyx_t_4, __pyx_temp+1-__pyx_t_8, 5+__pyx_t_8); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 883, __pyx_L1_error)
  12866. __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
  12867. __Pyx_GOTREF(__pyx_t_3);
  12868. } else
  12869. #endif
  12870. {
  12871. __pyx_t_1 = PyTuple_New(5+__pyx_t_8); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 883, __pyx_L1_error)
  12872. __Pyx_GOTREF(__pyx_t_1);
  12873. if (__pyx_t_9) {
  12874. __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_1, 0, __pyx_t_9); __pyx_t_9 = NULL;
  12875. }
  12876. __Pyx_INCREF(__pyx_v_tag);
  12877. __Pyx_GIVEREF(__pyx_v_tag);
  12878. PyTuple_SET_ITEM(__pyx_t_1, 0+__pyx_t_8, __pyx_v_tag);
  12879. __Pyx_INCREF(__pyx_v_value);
  12880. __Pyx_GIVEREF(__pyx_v_value);
  12881. PyTuple_SET_ITEM(__pyx_t_1, 1+__pyx_t_8, __pyx_v_value);
  12882. __Pyx_INCREF(((PyObject *)__pyx_v_start_mark));
  12883. __Pyx_GIVEREF(((PyObject *)__pyx_v_start_mark));
  12884. PyTuple_SET_ITEM(__pyx_t_1, 2+__pyx_t_8, ((PyObject *)__pyx_v_start_mark));
  12885. __Pyx_INCREF(Py_None);
  12886. __Pyx_GIVEREF(Py_None);
  12887. PyTuple_SET_ITEM(__pyx_t_1, 3+__pyx_t_8, Py_None);
  12888. __Pyx_INCREF(__pyx_v_flow_style);
  12889. __Pyx_GIVEREF(__pyx_v_flow_style);
  12890. PyTuple_SET_ITEM(__pyx_t_1, 4+__pyx_t_8, __pyx_v_flow_style);
  12891. __pyx_t_3 = __Pyx_PyObject_Call(__pyx_t_4, __pyx_t_1, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 883, __pyx_L1_error)
  12892. __Pyx_GOTREF(__pyx_t_3);
  12893. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  12894. }
  12895. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  12896. __pyx_v_node = __pyx_t_3;
  12897. __pyx_t_3 = 0;
  12898. /* "_yaml.pyx":884
  12899. * value = []
  12900. * node = MappingNode(tag, value, start_mark, None, flow_style)
  12901. * if anchor is not None: # <<<<<<<<<<<<<<
  12902. * self.anchors[anchor] = node
  12903. * yaml_event_delete(&self.parsed_event)
  12904. */
  12905. __pyx_t_5 = (__pyx_v_anchor != Py_None);
  12906. __pyx_t_6 = (__pyx_t_5 != 0);
  12907. if (__pyx_t_6) {
  12908. /* "_yaml.pyx":885
  12909. * node = MappingNode(tag, value, start_mark, None, flow_style)
  12910. * if anchor is not None:
  12911. * self.anchors[anchor] = node # <<<<<<<<<<<<<<
  12912. * yaml_event_delete(&self.parsed_event)
  12913. * self._parse_next_event()
  12914. */
  12915. if (unlikely(PyObject_SetItem(__pyx_v_self->anchors, __pyx_v_anchor, __pyx_v_node) < 0)) __PYX_ERR(0, 885, __pyx_L1_error)
  12916. /* "_yaml.pyx":884
  12917. * value = []
  12918. * node = MappingNode(tag, value, start_mark, None, flow_style)
  12919. * if anchor is not None: # <<<<<<<<<<<<<<
  12920. * self.anchors[anchor] = node
  12921. * yaml_event_delete(&self.parsed_event)
  12922. */
  12923. }
  12924. /* "_yaml.pyx":886
  12925. * if anchor is not None:
  12926. * self.anchors[anchor] = node
  12927. * yaml_event_delete(&self.parsed_event) # <<<<<<<<<<<<<<
  12928. * self._parse_next_event()
  12929. * while self.parsed_event.type != YAML_MAPPING_END_EVENT:
  12930. */
  12931. yaml_event_delete((&__pyx_v_self->parsed_event));
  12932. /* "_yaml.pyx":887
  12933. * self.anchors[anchor] = node
  12934. * yaml_event_delete(&self.parsed_event)
  12935. * self._parse_next_event() # <<<<<<<<<<<<<<
  12936. * while self.parsed_event.type != YAML_MAPPING_END_EVENT:
  12937. * item_key = self._compose_node(node, None)
  12938. */
  12939. __pyx_t_8 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parse_next_event(__pyx_v_self); if (unlikely(__pyx_t_8 == ((int)0))) __PYX_ERR(0, 887, __pyx_L1_error)
  12940. /* "_yaml.pyx":888
  12941. * yaml_event_delete(&self.parsed_event)
  12942. * self._parse_next_event()
  12943. * while self.parsed_event.type != YAML_MAPPING_END_EVENT: # <<<<<<<<<<<<<<
  12944. * item_key = self._compose_node(node, None)
  12945. * item_value = self._compose_node(node, item_key)
  12946. */
  12947. while (1) {
  12948. __pyx_t_6 = ((__pyx_v_self->parsed_event.type != YAML_MAPPING_END_EVENT) != 0);
  12949. if (!__pyx_t_6) break;
  12950. /* "_yaml.pyx":889
  12951. * self._parse_next_event()
  12952. * while self.parsed_event.type != YAML_MAPPING_END_EVENT:
  12953. * item_key = self._compose_node(node, None) # <<<<<<<<<<<<<<
  12954. * item_value = self._compose_node(node, item_key)
  12955. * value.append((item_key, item_value))
  12956. */
  12957. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_compose_node(__pyx_v_self, __pyx_v_node, Py_None); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 889, __pyx_L1_error)
  12958. __Pyx_GOTREF(__pyx_t_3);
  12959. __Pyx_XDECREF_SET(__pyx_v_item_key, __pyx_t_3);
  12960. __pyx_t_3 = 0;
  12961. /* "_yaml.pyx":890
  12962. * while self.parsed_event.type != YAML_MAPPING_END_EVENT:
  12963. * item_key = self._compose_node(node, None)
  12964. * item_value = self._compose_node(node, item_key) # <<<<<<<<<<<<<<
  12965. * value.append((item_key, item_value))
  12966. * self._parse_next_event()
  12967. */
  12968. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_compose_node(__pyx_v_self, __pyx_v_node, __pyx_v_item_key); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 890, __pyx_L1_error)
  12969. __Pyx_GOTREF(__pyx_t_3);
  12970. __Pyx_XDECREF_SET(__pyx_v_item_value, __pyx_t_3);
  12971. __pyx_t_3 = 0;
  12972. /* "_yaml.pyx":891
  12973. * item_key = self._compose_node(node, None)
  12974. * item_value = self._compose_node(node, item_key)
  12975. * value.append((item_key, item_value)) # <<<<<<<<<<<<<<
  12976. * self._parse_next_event()
  12977. * node.end_mark = Mark(self.stream_name,
  12978. */
  12979. __pyx_t_3 = PyTuple_New(2); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 891, __pyx_L1_error)
  12980. __Pyx_GOTREF(__pyx_t_3);
  12981. __Pyx_INCREF(__pyx_v_item_key);
  12982. __Pyx_GIVEREF(__pyx_v_item_key);
  12983. PyTuple_SET_ITEM(__pyx_t_3, 0, __pyx_v_item_key);
  12984. __Pyx_INCREF(__pyx_v_item_value);
  12985. __Pyx_GIVEREF(__pyx_v_item_value);
  12986. PyTuple_SET_ITEM(__pyx_t_3, 1, __pyx_v_item_value);
  12987. __pyx_t_10 = __Pyx_PyList_Append(__pyx_v_value, __pyx_t_3); if (unlikely(__pyx_t_10 == ((int)-1))) __PYX_ERR(0, 891, __pyx_L1_error)
  12988. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  12989. /* "_yaml.pyx":892
  12990. * item_value = self._compose_node(node, item_key)
  12991. * value.append((item_key, item_value))
  12992. * self._parse_next_event() # <<<<<<<<<<<<<<
  12993. * node.end_mark = Mark(self.stream_name,
  12994. * self.parsed_event.end_mark.index,
  12995. */
  12996. __pyx_t_8 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parse_next_event(__pyx_v_self); if (unlikely(__pyx_t_8 == ((int)0))) __PYX_ERR(0, 892, __pyx_L1_error)
  12997. }
  12998. /* "_yaml.pyx":894
  12999. * self._parse_next_event()
  13000. * node.end_mark = Mark(self.stream_name,
  13001. * self.parsed_event.end_mark.index, # <<<<<<<<<<<<<<
  13002. * self.parsed_event.end_mark.line,
  13003. * self.parsed_event.end_mark.column,
  13004. */
  13005. __pyx_t_3 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.end_mark.index); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 894, __pyx_L1_error)
  13006. __Pyx_GOTREF(__pyx_t_3);
  13007. /* "_yaml.pyx":895
  13008. * node.end_mark = Mark(self.stream_name,
  13009. * self.parsed_event.end_mark.index,
  13010. * self.parsed_event.end_mark.line, # <<<<<<<<<<<<<<
  13011. * self.parsed_event.end_mark.column,
  13012. * None, None)
  13013. */
  13014. __pyx_t_4 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.end_mark.line); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 895, __pyx_L1_error)
  13015. __Pyx_GOTREF(__pyx_t_4);
  13016. /* "_yaml.pyx":896
  13017. * self.parsed_event.end_mark.index,
  13018. * self.parsed_event.end_mark.line,
  13019. * self.parsed_event.end_mark.column, # <<<<<<<<<<<<<<
  13020. * None, None)
  13021. * yaml_event_delete(&self.parsed_event)
  13022. */
  13023. __pyx_t_1 = __Pyx_PyInt_FromSize_t(__pyx_v_self->parsed_event.end_mark.column); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 896, __pyx_L1_error)
  13024. __Pyx_GOTREF(__pyx_t_1);
  13025. /* "_yaml.pyx":893
  13026. * value.append((item_key, item_value))
  13027. * self._parse_next_event()
  13028. * node.end_mark = Mark(self.stream_name, # <<<<<<<<<<<<<<
  13029. * self.parsed_event.end_mark.index,
  13030. * self.parsed_event.end_mark.line,
  13031. */
  13032. __pyx_t_9 = PyTuple_New(6); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 893, __pyx_L1_error)
  13033. __Pyx_GOTREF(__pyx_t_9);
  13034. __Pyx_INCREF(__pyx_v_self->stream_name);
  13035. __Pyx_GIVEREF(__pyx_v_self->stream_name);
  13036. PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_v_self->stream_name);
  13037. __Pyx_GIVEREF(__pyx_t_3);
  13038. PyTuple_SET_ITEM(__pyx_t_9, 1, __pyx_t_3);
  13039. __Pyx_GIVEREF(__pyx_t_4);
  13040. PyTuple_SET_ITEM(__pyx_t_9, 2, __pyx_t_4);
  13041. __Pyx_GIVEREF(__pyx_t_1);
  13042. PyTuple_SET_ITEM(__pyx_t_9, 3, __pyx_t_1);
  13043. __Pyx_INCREF(Py_None);
  13044. __Pyx_GIVEREF(Py_None);
  13045. PyTuple_SET_ITEM(__pyx_t_9, 4, Py_None);
  13046. __Pyx_INCREF(Py_None);
  13047. __Pyx_GIVEREF(Py_None);
  13048. PyTuple_SET_ITEM(__pyx_t_9, 5, Py_None);
  13049. __pyx_t_3 = 0;
  13050. __pyx_t_4 = 0;
  13051. __pyx_t_1 = 0;
  13052. __pyx_t_1 = __Pyx_PyObject_Call(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_t_9, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 893, __pyx_L1_error)
  13053. __Pyx_GOTREF(__pyx_t_1);
  13054. __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
  13055. if (__Pyx_PyObject_SetAttrStr(__pyx_v_node, __pyx_n_s_end_mark, __pyx_t_1) < 0) __PYX_ERR(0, 893, __pyx_L1_error)
  13056. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  13057. /* "_yaml.pyx":898
  13058. * self.parsed_event.end_mark.column,
  13059. * None, None)
  13060. * yaml_event_delete(&self.parsed_event) # <<<<<<<<<<<<<<
  13061. * return node
  13062. *
  13063. */
  13064. yaml_event_delete((&__pyx_v_self->parsed_event));
  13065. /* "_yaml.pyx":899
  13066. * None, None)
  13067. * yaml_event_delete(&self.parsed_event)
  13068. * return node # <<<<<<<<<<<<<<
  13069. *
  13070. * cdef int _parse_next_event(self) except 0:
  13071. */
  13072. __Pyx_XDECREF(__pyx_r);
  13073. __Pyx_INCREF(__pyx_v_node);
  13074. __pyx_r = __pyx_v_node;
  13075. goto __pyx_L0;
  13076. /* "_yaml.pyx":862
  13077. * return node
  13078. *
  13079. * cdef _compose_mapping_node(self, object anchor): # <<<<<<<<<<<<<<
  13080. * start_mark = Mark(self.stream_name,
  13081. * self.parsed_event.start_mark.index,
  13082. */
  13083. /* function exit code */
  13084. __pyx_L1_error:;
  13085. __Pyx_XDECREF(__pyx_t_1);
  13086. __Pyx_XDECREF(__pyx_t_2);
  13087. __Pyx_XDECREF(__pyx_t_3);
  13088. __Pyx_XDECREF(__pyx_t_4);
  13089. __Pyx_XDECREF(__pyx_t_7);
  13090. __Pyx_XDECREF(__pyx_t_9);
  13091. __Pyx_AddTraceback("_yaml.CParser._compose_mapping_node", __pyx_clineno, __pyx_lineno, __pyx_filename);
  13092. __pyx_r = 0;
  13093. __pyx_L0:;
  13094. __Pyx_XDECREF((PyObject *)__pyx_v_start_mark);
  13095. __Pyx_XDECREF(__pyx_v_tag);
  13096. __Pyx_XDECREF(__pyx_v_flow_style);
  13097. __Pyx_XDECREF(__pyx_v_value);
  13098. __Pyx_XDECREF(__pyx_v_node);
  13099. __Pyx_XDECREF(__pyx_v_item_key);
  13100. __Pyx_XDECREF(__pyx_v_item_value);
  13101. __Pyx_XGIVEREF(__pyx_r);
  13102. __Pyx_RefNannyFinishContext();
  13103. return __pyx_r;
  13104. }
  13105. /* "_yaml.pyx":901
  13106. * return node
  13107. *
  13108. * cdef int _parse_next_event(self) except 0: # <<<<<<<<<<<<<<
  13109. * if self.parsed_event.type == YAML_NO_EVENT:
  13110. * if yaml_parser_parse(&self.parser, &self.parsed_event) == 0:
  13111. */
  13112. static int __pyx_f_5_yaml_7CParser__parse_next_event(struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  13113. PyObject *__pyx_v_error = NULL;
  13114. int __pyx_r;
  13115. __Pyx_RefNannyDeclarations
  13116. int __pyx_t_1;
  13117. int __pyx_t_2;
  13118. PyObject *__pyx_t_3 = NULL;
  13119. __Pyx_RefNannySetupContext("_parse_next_event", 0);
  13120. /* "_yaml.pyx":902
  13121. *
  13122. * cdef int _parse_next_event(self) except 0:
  13123. * if self.parsed_event.type == YAML_NO_EVENT: # <<<<<<<<<<<<<<
  13124. * if yaml_parser_parse(&self.parser, &self.parsed_event) == 0:
  13125. * error = self._parser_error()
  13126. */
  13127. __pyx_t_1 = ((__pyx_v_self->parsed_event.type == YAML_NO_EVENT) != 0);
  13128. if (__pyx_t_1) {
  13129. /* "_yaml.pyx":903
  13130. * cdef int _parse_next_event(self) except 0:
  13131. * if self.parsed_event.type == YAML_NO_EVENT:
  13132. * if yaml_parser_parse(&self.parser, &self.parsed_event) == 0: # <<<<<<<<<<<<<<
  13133. * error = self._parser_error()
  13134. * raise error
  13135. */
  13136. __pyx_t_2 = yaml_parser_parse((&__pyx_v_self->parser), (&__pyx_v_self->parsed_event)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 903, __pyx_L1_error)
  13137. __pyx_t_1 = ((__pyx_t_2 == 0) != 0);
  13138. if (unlikely(__pyx_t_1)) {
  13139. /* "_yaml.pyx":904
  13140. * if self.parsed_event.type == YAML_NO_EVENT:
  13141. * if yaml_parser_parse(&self.parser, &self.parsed_event) == 0:
  13142. * error = self._parser_error() # <<<<<<<<<<<<<<
  13143. * raise error
  13144. * return 1
  13145. */
  13146. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CParser *)__pyx_v_self->__pyx_vtab)->_parser_error(__pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 904, __pyx_L1_error)
  13147. __Pyx_GOTREF(__pyx_t_3);
  13148. __pyx_v_error = __pyx_t_3;
  13149. __pyx_t_3 = 0;
  13150. /* "_yaml.pyx":905
  13151. * if yaml_parser_parse(&self.parser, &self.parsed_event) == 0:
  13152. * error = self._parser_error()
  13153. * raise error # <<<<<<<<<<<<<<
  13154. * return 1
  13155. *
  13156. */
  13157. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  13158. __PYX_ERR(0, 905, __pyx_L1_error)
  13159. /* "_yaml.pyx":903
  13160. * cdef int _parse_next_event(self) except 0:
  13161. * if self.parsed_event.type == YAML_NO_EVENT:
  13162. * if yaml_parser_parse(&self.parser, &self.parsed_event) == 0: # <<<<<<<<<<<<<<
  13163. * error = self._parser_error()
  13164. * raise error
  13165. */
  13166. }
  13167. /* "_yaml.pyx":902
  13168. *
  13169. * cdef int _parse_next_event(self) except 0:
  13170. * if self.parsed_event.type == YAML_NO_EVENT: # <<<<<<<<<<<<<<
  13171. * if yaml_parser_parse(&self.parser, &self.parsed_event) == 0:
  13172. * error = self._parser_error()
  13173. */
  13174. }
  13175. /* "_yaml.pyx":906
  13176. * error = self._parser_error()
  13177. * raise error
  13178. * return 1 # <<<<<<<<<<<<<<
  13179. *
  13180. * cdef int input_handler(void *data, char *buffer, size_t size, size_t *read) except 0:
  13181. */
  13182. __pyx_r = 1;
  13183. goto __pyx_L0;
  13184. /* "_yaml.pyx":901
  13185. * return node
  13186. *
  13187. * cdef int _parse_next_event(self) except 0: # <<<<<<<<<<<<<<
  13188. * if self.parsed_event.type == YAML_NO_EVENT:
  13189. * if yaml_parser_parse(&self.parser, &self.parsed_event) == 0:
  13190. */
  13191. /* function exit code */
  13192. __pyx_L1_error:;
  13193. __Pyx_XDECREF(__pyx_t_3);
  13194. __Pyx_AddTraceback("_yaml.CParser._parse_next_event", __pyx_clineno, __pyx_lineno, __pyx_filename);
  13195. __pyx_r = 0;
  13196. __pyx_L0:;
  13197. __Pyx_XDECREF(__pyx_v_error);
  13198. __Pyx_RefNannyFinishContext();
  13199. return __pyx_r;
  13200. }
  13201. /* "(tree fragment)":1
  13202. * def __reduce_cython__(self): # <<<<<<<<<<<<<<
  13203. * raise TypeError("self.parsed_event cannot be converted to a Python object for pickling")
  13204. * def __setstate_cython__(self, __pyx_state):
  13205. */
  13206. /* Python wrapper */
  13207. static PyObject *__pyx_pw_5_yaml_7CParser_29__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  13208. static PyObject *__pyx_pw_5_yaml_7CParser_29__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  13209. PyObject *__pyx_r = 0;
  13210. __Pyx_RefNannyDeclarations
  13211. __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0);
  13212. __pyx_r = __pyx_pf_5_yaml_7CParser_28__reduce_cython__(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self));
  13213. /* function exit code */
  13214. __Pyx_RefNannyFinishContext();
  13215. return __pyx_r;
  13216. }
  13217. static PyObject *__pyx_pf_5_yaml_7CParser_28__reduce_cython__(CYTHON_UNUSED struct __pyx_obj_5_yaml_CParser *__pyx_v_self) {
  13218. PyObject *__pyx_r = NULL;
  13219. __Pyx_RefNannyDeclarations
  13220. PyObject *__pyx_t_1 = NULL;
  13221. __Pyx_RefNannySetupContext("__reduce_cython__", 0);
  13222. /* "(tree fragment)":2
  13223. * def __reduce_cython__(self):
  13224. * raise TypeError("self.parsed_event cannot be converted to a Python object for pickling") # <<<<<<<<<<<<<<
  13225. * def __setstate_cython__(self, __pyx_state):
  13226. * raise TypeError("self.parsed_event cannot be converted to a Python object for pickling")
  13227. */
  13228. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__15, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2, __pyx_L1_error)
  13229. __Pyx_GOTREF(__pyx_t_1);
  13230. __Pyx_Raise(__pyx_t_1, 0, 0, 0);
  13231. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  13232. __PYX_ERR(1, 2, __pyx_L1_error)
  13233. /* "(tree fragment)":1
  13234. * def __reduce_cython__(self): # <<<<<<<<<<<<<<
  13235. * raise TypeError("self.parsed_event cannot be converted to a Python object for pickling")
  13236. * def __setstate_cython__(self, __pyx_state):
  13237. */
  13238. /* function exit code */
  13239. __pyx_L1_error:;
  13240. __Pyx_XDECREF(__pyx_t_1);
  13241. __Pyx_AddTraceback("_yaml.CParser.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  13242. __pyx_r = NULL;
  13243. __Pyx_XGIVEREF(__pyx_r);
  13244. __Pyx_RefNannyFinishContext();
  13245. return __pyx_r;
  13246. }
  13247. /* "(tree fragment)":3
  13248. * def __reduce_cython__(self):
  13249. * raise TypeError("self.parsed_event cannot be converted to a Python object for pickling")
  13250. * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<<
  13251. * raise TypeError("self.parsed_event cannot be converted to a Python object for pickling")
  13252. */
  13253. /* Python wrapper */
  13254. static PyObject *__pyx_pw_5_yaml_7CParser_31__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/
  13255. static PyObject *__pyx_pw_5_yaml_7CParser_31__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
  13256. PyObject *__pyx_r = 0;
  13257. __Pyx_RefNannyDeclarations
  13258. __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0);
  13259. __pyx_r = __pyx_pf_5_yaml_7CParser_30__setstate_cython__(((struct __pyx_obj_5_yaml_CParser *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state));
  13260. /* function exit code */
  13261. __Pyx_RefNannyFinishContext();
  13262. return __pyx_r;
  13263. }
  13264. static PyObject *__pyx_pf_5_yaml_7CParser_30__setstate_cython__(CYTHON_UNUSED struct __pyx_obj_5_yaml_CParser *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state) {
  13265. PyObject *__pyx_r = NULL;
  13266. __Pyx_RefNannyDeclarations
  13267. PyObject *__pyx_t_1 = NULL;
  13268. __Pyx_RefNannySetupContext("__setstate_cython__", 0);
  13269. /* "(tree fragment)":4
  13270. * raise TypeError("self.parsed_event cannot be converted to a Python object for pickling")
  13271. * def __setstate_cython__(self, __pyx_state):
  13272. * raise TypeError("self.parsed_event cannot be converted to a Python object for pickling") # <<<<<<<<<<<<<<
  13273. */
  13274. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__16, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 4, __pyx_L1_error)
  13275. __Pyx_GOTREF(__pyx_t_1);
  13276. __Pyx_Raise(__pyx_t_1, 0, 0, 0);
  13277. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  13278. __PYX_ERR(1, 4, __pyx_L1_error)
  13279. /* "(tree fragment)":3
  13280. * def __reduce_cython__(self):
  13281. * raise TypeError("self.parsed_event cannot be converted to a Python object for pickling")
  13282. * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<<
  13283. * raise TypeError("self.parsed_event cannot be converted to a Python object for pickling")
  13284. */
  13285. /* function exit code */
  13286. __pyx_L1_error:;
  13287. __Pyx_XDECREF(__pyx_t_1);
  13288. __Pyx_AddTraceback("_yaml.CParser.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  13289. __pyx_r = NULL;
  13290. __Pyx_XGIVEREF(__pyx_r);
  13291. __Pyx_RefNannyFinishContext();
  13292. return __pyx_r;
  13293. }
  13294. /* "_yaml.pyx":908
  13295. * return 1
  13296. *
  13297. * cdef int input_handler(void *data, char *buffer, size_t size, size_t *read) except 0: # <<<<<<<<<<<<<<
  13298. * cdef CParser parser
  13299. * parser = <CParser>data
  13300. */
  13301. static int __pyx_f_5_yaml_input_handler(void *__pyx_v_data, char *__pyx_v_buffer, size_t __pyx_v_size, size_t *__pyx_v_read) {
  13302. struct __pyx_obj_5_yaml_CParser *__pyx_v_parser = 0;
  13303. PyObject *__pyx_v_value = NULL;
  13304. int __pyx_r;
  13305. __Pyx_RefNannyDeclarations
  13306. PyObject *__pyx_t_1 = NULL;
  13307. int __pyx_t_2;
  13308. int __pyx_t_3;
  13309. PyObject *__pyx_t_4 = NULL;
  13310. PyObject *__pyx_t_5 = NULL;
  13311. PyObject *__pyx_t_6 = NULL;
  13312. __Pyx_RefNannySetupContext("input_handler", 0);
  13313. /* "_yaml.pyx":910
  13314. * cdef int input_handler(void *data, char *buffer, size_t size, size_t *read) except 0:
  13315. * cdef CParser parser
  13316. * parser = <CParser>data # <<<<<<<<<<<<<<
  13317. * if parser.stream_cache is None:
  13318. * value = parser.stream.read(size)
  13319. */
  13320. __pyx_t_1 = ((PyObject *)__pyx_v_data);
  13321. __Pyx_INCREF(__pyx_t_1);
  13322. __pyx_v_parser = ((struct __pyx_obj_5_yaml_CParser *)__pyx_t_1);
  13323. __pyx_t_1 = 0;
  13324. /* "_yaml.pyx":911
  13325. * cdef CParser parser
  13326. * parser = <CParser>data
  13327. * if parser.stream_cache is None: # <<<<<<<<<<<<<<
  13328. * value = parser.stream.read(size)
  13329. * if PyUnicode_CheckExact(value) != 0:
  13330. */
  13331. __pyx_t_2 = (__pyx_v_parser->stream_cache == Py_None);
  13332. __pyx_t_3 = (__pyx_t_2 != 0);
  13333. if (__pyx_t_3) {
  13334. /* "_yaml.pyx":912
  13335. * parser = <CParser>data
  13336. * if parser.stream_cache is None:
  13337. * value = parser.stream.read(size) # <<<<<<<<<<<<<<
  13338. * if PyUnicode_CheckExact(value) != 0:
  13339. * value = PyUnicode_AsUTF8String(value)
  13340. */
  13341. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_parser->stream, __pyx_n_s_read); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 912, __pyx_L1_error)
  13342. __Pyx_GOTREF(__pyx_t_4);
  13343. __pyx_t_5 = __Pyx_PyInt_FromSize_t(__pyx_v_size); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 912, __pyx_L1_error)
  13344. __Pyx_GOTREF(__pyx_t_5);
  13345. __pyx_t_6 = NULL;
  13346. if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_4))) {
  13347. __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_4);
  13348. if (likely(__pyx_t_6)) {
  13349. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_4);
  13350. __Pyx_INCREF(__pyx_t_6);
  13351. __Pyx_INCREF(function);
  13352. __Pyx_DECREF_SET(__pyx_t_4, function);
  13353. }
  13354. }
  13355. __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_4, __pyx_t_6, __pyx_t_5) : __Pyx_PyObject_CallOneArg(__pyx_t_4, __pyx_t_5);
  13356. __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
  13357. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  13358. if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 912, __pyx_L1_error)
  13359. __Pyx_GOTREF(__pyx_t_1);
  13360. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  13361. __pyx_v_value = __pyx_t_1;
  13362. __pyx_t_1 = 0;
  13363. /* "_yaml.pyx":913
  13364. * if parser.stream_cache is None:
  13365. * value = parser.stream.read(size)
  13366. * if PyUnicode_CheckExact(value) != 0: # <<<<<<<<<<<<<<
  13367. * value = PyUnicode_AsUTF8String(value)
  13368. * parser.unicode_source = 1
  13369. */
  13370. __pyx_t_3 = ((PyUnicode_CheckExact(__pyx_v_value) != 0) != 0);
  13371. if (__pyx_t_3) {
  13372. /* "_yaml.pyx":914
  13373. * value = parser.stream.read(size)
  13374. * if PyUnicode_CheckExact(value) != 0:
  13375. * value = PyUnicode_AsUTF8String(value) # <<<<<<<<<<<<<<
  13376. * parser.unicode_source = 1
  13377. * if PyString_CheckExact(value) == 0:
  13378. */
  13379. __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_value); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 914, __pyx_L1_error)
  13380. __Pyx_GOTREF(__pyx_t_1);
  13381. __Pyx_DECREF_SET(__pyx_v_value, __pyx_t_1);
  13382. __pyx_t_1 = 0;
  13383. /* "_yaml.pyx":915
  13384. * if PyUnicode_CheckExact(value) != 0:
  13385. * value = PyUnicode_AsUTF8String(value)
  13386. * parser.unicode_source = 1 # <<<<<<<<<<<<<<
  13387. * if PyString_CheckExact(value) == 0:
  13388. * if PY_MAJOR_VERSION < 3:
  13389. */
  13390. __pyx_v_parser->unicode_source = 1;
  13391. /* "_yaml.pyx":913
  13392. * if parser.stream_cache is None:
  13393. * value = parser.stream.read(size)
  13394. * if PyUnicode_CheckExact(value) != 0: # <<<<<<<<<<<<<<
  13395. * value = PyUnicode_AsUTF8String(value)
  13396. * parser.unicode_source = 1
  13397. */
  13398. }
  13399. /* "_yaml.pyx":916
  13400. * value = PyUnicode_AsUTF8String(value)
  13401. * parser.unicode_source = 1
  13402. * if PyString_CheckExact(value) == 0: # <<<<<<<<<<<<<<
  13403. * if PY_MAJOR_VERSION < 3:
  13404. * raise TypeError("a string value is expected")
  13405. */
  13406. __pyx_t_3 = ((PyString_CheckExact(__pyx_v_value) == 0) != 0);
  13407. if (__pyx_t_3) {
  13408. /* "_yaml.pyx":917
  13409. * parser.unicode_source = 1
  13410. * if PyString_CheckExact(value) == 0:
  13411. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  13412. * raise TypeError("a string value is expected")
  13413. * else:
  13414. */
  13415. __pyx_t_3 = ((PY_MAJOR_VERSION < 3) != 0);
  13416. if (unlikely(__pyx_t_3)) {
  13417. /* "_yaml.pyx":918
  13418. * if PyString_CheckExact(value) == 0:
  13419. * if PY_MAJOR_VERSION < 3:
  13420. * raise TypeError("a string value is expected") # <<<<<<<<<<<<<<
  13421. * else:
  13422. * raise TypeError(u"a string value is expected")
  13423. */
  13424. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__17, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 918, __pyx_L1_error)
  13425. __Pyx_GOTREF(__pyx_t_1);
  13426. __Pyx_Raise(__pyx_t_1, 0, 0, 0);
  13427. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  13428. __PYX_ERR(0, 918, __pyx_L1_error)
  13429. /* "_yaml.pyx":917
  13430. * parser.unicode_source = 1
  13431. * if PyString_CheckExact(value) == 0:
  13432. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  13433. * raise TypeError("a string value is expected")
  13434. * else:
  13435. */
  13436. }
  13437. /* "_yaml.pyx":920
  13438. * raise TypeError("a string value is expected")
  13439. * else:
  13440. * raise TypeError(u"a string value is expected") # <<<<<<<<<<<<<<
  13441. * parser.stream_cache = value
  13442. * parser.stream_cache_pos = 0
  13443. */
  13444. /*else*/ {
  13445. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__18, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 920, __pyx_L1_error)
  13446. __Pyx_GOTREF(__pyx_t_1);
  13447. __Pyx_Raise(__pyx_t_1, 0, 0, 0);
  13448. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  13449. __PYX_ERR(0, 920, __pyx_L1_error)
  13450. }
  13451. /* "_yaml.pyx":916
  13452. * value = PyUnicode_AsUTF8String(value)
  13453. * parser.unicode_source = 1
  13454. * if PyString_CheckExact(value) == 0: # <<<<<<<<<<<<<<
  13455. * if PY_MAJOR_VERSION < 3:
  13456. * raise TypeError("a string value is expected")
  13457. */
  13458. }
  13459. /* "_yaml.pyx":921
  13460. * else:
  13461. * raise TypeError(u"a string value is expected")
  13462. * parser.stream_cache = value # <<<<<<<<<<<<<<
  13463. * parser.stream_cache_pos = 0
  13464. * parser.stream_cache_len = PyString_GET_SIZE(value)
  13465. */
  13466. __Pyx_INCREF(__pyx_v_value);
  13467. __Pyx_GIVEREF(__pyx_v_value);
  13468. __Pyx_GOTREF(__pyx_v_parser->stream_cache);
  13469. __Pyx_DECREF(__pyx_v_parser->stream_cache);
  13470. __pyx_v_parser->stream_cache = __pyx_v_value;
  13471. /* "_yaml.pyx":922
  13472. * raise TypeError(u"a string value is expected")
  13473. * parser.stream_cache = value
  13474. * parser.stream_cache_pos = 0 # <<<<<<<<<<<<<<
  13475. * parser.stream_cache_len = PyString_GET_SIZE(value)
  13476. * if (parser.stream_cache_len - parser.stream_cache_pos) < size:
  13477. */
  13478. __pyx_v_parser->stream_cache_pos = 0;
  13479. /* "_yaml.pyx":923
  13480. * parser.stream_cache = value
  13481. * parser.stream_cache_pos = 0
  13482. * parser.stream_cache_len = PyString_GET_SIZE(value) # <<<<<<<<<<<<<<
  13483. * if (parser.stream_cache_len - parser.stream_cache_pos) < size:
  13484. * size = parser.stream_cache_len - parser.stream_cache_pos
  13485. */
  13486. __pyx_v_parser->stream_cache_len = PyString_GET_SIZE(__pyx_v_value);
  13487. /* "_yaml.pyx":911
  13488. * cdef CParser parser
  13489. * parser = <CParser>data
  13490. * if parser.stream_cache is None: # <<<<<<<<<<<<<<
  13491. * value = parser.stream.read(size)
  13492. * if PyUnicode_CheckExact(value) != 0:
  13493. */
  13494. }
  13495. /* "_yaml.pyx":924
  13496. * parser.stream_cache_pos = 0
  13497. * parser.stream_cache_len = PyString_GET_SIZE(value)
  13498. * if (parser.stream_cache_len - parser.stream_cache_pos) < size: # <<<<<<<<<<<<<<
  13499. * size = parser.stream_cache_len - parser.stream_cache_pos
  13500. * if size > 0:
  13501. */
  13502. __pyx_t_3 = (((__pyx_v_parser->stream_cache_len - __pyx_v_parser->stream_cache_pos) < __pyx_v_size) != 0);
  13503. if (__pyx_t_3) {
  13504. /* "_yaml.pyx":925
  13505. * parser.stream_cache_len = PyString_GET_SIZE(value)
  13506. * if (parser.stream_cache_len - parser.stream_cache_pos) < size:
  13507. * size = parser.stream_cache_len - parser.stream_cache_pos # <<<<<<<<<<<<<<
  13508. * if size > 0:
  13509. * memcpy(buffer, PyString_AS_STRING(parser.stream_cache)
  13510. */
  13511. __pyx_v_size = (__pyx_v_parser->stream_cache_len - __pyx_v_parser->stream_cache_pos);
  13512. /* "_yaml.pyx":924
  13513. * parser.stream_cache_pos = 0
  13514. * parser.stream_cache_len = PyString_GET_SIZE(value)
  13515. * if (parser.stream_cache_len - parser.stream_cache_pos) < size: # <<<<<<<<<<<<<<
  13516. * size = parser.stream_cache_len - parser.stream_cache_pos
  13517. * if size > 0:
  13518. */
  13519. }
  13520. /* "_yaml.pyx":926
  13521. * if (parser.stream_cache_len - parser.stream_cache_pos) < size:
  13522. * size = parser.stream_cache_len - parser.stream_cache_pos
  13523. * if size > 0: # <<<<<<<<<<<<<<
  13524. * memcpy(buffer, PyString_AS_STRING(parser.stream_cache)
  13525. * + parser.stream_cache_pos, size)
  13526. */
  13527. __pyx_t_3 = ((__pyx_v_size > 0) != 0);
  13528. if (__pyx_t_3) {
  13529. /* "_yaml.pyx":927
  13530. * size = parser.stream_cache_len - parser.stream_cache_pos
  13531. * if size > 0:
  13532. * memcpy(buffer, PyString_AS_STRING(parser.stream_cache) # <<<<<<<<<<<<<<
  13533. * + parser.stream_cache_pos, size)
  13534. * read[0] = size
  13535. */
  13536. __pyx_t_1 = __pyx_v_parser->stream_cache;
  13537. __Pyx_INCREF(__pyx_t_1);
  13538. /* "_yaml.pyx":928
  13539. * if size > 0:
  13540. * memcpy(buffer, PyString_AS_STRING(parser.stream_cache)
  13541. * + parser.stream_cache_pos, size) # <<<<<<<<<<<<<<
  13542. * read[0] = size
  13543. * parser.stream_cache_pos += size
  13544. */
  13545. memcpy(__pyx_v_buffer, (PyString_AS_STRING(__pyx_t_1) + __pyx_v_parser->stream_cache_pos), __pyx_v_size);
  13546. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  13547. /* "_yaml.pyx":926
  13548. * if (parser.stream_cache_len - parser.stream_cache_pos) < size:
  13549. * size = parser.stream_cache_len - parser.stream_cache_pos
  13550. * if size > 0: # <<<<<<<<<<<<<<
  13551. * memcpy(buffer, PyString_AS_STRING(parser.stream_cache)
  13552. * + parser.stream_cache_pos, size)
  13553. */
  13554. }
  13555. /* "_yaml.pyx":929
  13556. * memcpy(buffer, PyString_AS_STRING(parser.stream_cache)
  13557. * + parser.stream_cache_pos, size)
  13558. * read[0] = size # <<<<<<<<<<<<<<
  13559. * parser.stream_cache_pos += size
  13560. * if parser.stream_cache_pos == parser.stream_cache_len:
  13561. */
  13562. (__pyx_v_read[0]) = __pyx_v_size;
  13563. /* "_yaml.pyx":930
  13564. * + parser.stream_cache_pos, size)
  13565. * read[0] = size
  13566. * parser.stream_cache_pos += size # <<<<<<<<<<<<<<
  13567. * if parser.stream_cache_pos == parser.stream_cache_len:
  13568. * parser.stream_cache = None
  13569. */
  13570. __pyx_v_parser->stream_cache_pos = (__pyx_v_parser->stream_cache_pos + __pyx_v_size);
  13571. /* "_yaml.pyx":931
  13572. * read[0] = size
  13573. * parser.stream_cache_pos += size
  13574. * if parser.stream_cache_pos == parser.stream_cache_len: # <<<<<<<<<<<<<<
  13575. * parser.stream_cache = None
  13576. * return 1
  13577. */
  13578. __pyx_t_3 = ((__pyx_v_parser->stream_cache_pos == __pyx_v_parser->stream_cache_len) != 0);
  13579. if (__pyx_t_3) {
  13580. /* "_yaml.pyx":932
  13581. * parser.stream_cache_pos += size
  13582. * if parser.stream_cache_pos == parser.stream_cache_len:
  13583. * parser.stream_cache = None # <<<<<<<<<<<<<<
  13584. * return 1
  13585. *
  13586. */
  13587. __Pyx_INCREF(Py_None);
  13588. __Pyx_GIVEREF(Py_None);
  13589. __Pyx_GOTREF(__pyx_v_parser->stream_cache);
  13590. __Pyx_DECREF(__pyx_v_parser->stream_cache);
  13591. __pyx_v_parser->stream_cache = Py_None;
  13592. /* "_yaml.pyx":931
  13593. * read[0] = size
  13594. * parser.stream_cache_pos += size
  13595. * if parser.stream_cache_pos == parser.stream_cache_len: # <<<<<<<<<<<<<<
  13596. * parser.stream_cache = None
  13597. * return 1
  13598. */
  13599. }
  13600. /* "_yaml.pyx":933
  13601. * if parser.stream_cache_pos == parser.stream_cache_len:
  13602. * parser.stream_cache = None
  13603. * return 1 # <<<<<<<<<<<<<<
  13604. *
  13605. * cdef class CEmitter:
  13606. */
  13607. __pyx_r = 1;
  13608. goto __pyx_L0;
  13609. /* "_yaml.pyx":908
  13610. * return 1
  13611. *
  13612. * cdef int input_handler(void *data, char *buffer, size_t size, size_t *read) except 0: # <<<<<<<<<<<<<<
  13613. * cdef CParser parser
  13614. * parser = <CParser>data
  13615. */
  13616. /* function exit code */
  13617. __pyx_L1_error:;
  13618. __Pyx_XDECREF(__pyx_t_1);
  13619. __Pyx_XDECREF(__pyx_t_4);
  13620. __Pyx_XDECREF(__pyx_t_5);
  13621. __Pyx_XDECREF(__pyx_t_6);
  13622. __Pyx_AddTraceback("_yaml.input_handler", __pyx_clineno, __pyx_lineno, __pyx_filename);
  13623. __pyx_r = 0;
  13624. __pyx_L0:;
  13625. __Pyx_XDECREF((PyObject *)__pyx_v_parser);
  13626. __Pyx_XDECREF(__pyx_v_value);
  13627. __Pyx_RefNannyFinishContext();
  13628. return __pyx_r;
  13629. }
  13630. /* "_yaml.pyx":953
  13631. * cdef object use_encoding
  13632. *
  13633. * def __init__(self, stream, canonical=None, indent=None, width=None, # <<<<<<<<<<<<<<
  13634. * allow_unicode=None, line_break=None, encoding=None,
  13635. * explicit_start=None, explicit_end=None, version=None, tags=None):
  13636. */
  13637. /* Python wrapper */
  13638. static int __pyx_pw_5_yaml_8CEmitter_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
  13639. static int __pyx_pw_5_yaml_8CEmitter_1__init__(PyObject *__pyx_v_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  13640. PyObject *__pyx_v_stream = 0;
  13641. PyObject *__pyx_v_canonical = 0;
  13642. PyObject *__pyx_v_indent = 0;
  13643. PyObject *__pyx_v_width = 0;
  13644. PyObject *__pyx_v_allow_unicode = 0;
  13645. PyObject *__pyx_v_line_break = 0;
  13646. PyObject *__pyx_v_encoding = 0;
  13647. PyObject *__pyx_v_explicit_start = 0;
  13648. PyObject *__pyx_v_explicit_end = 0;
  13649. PyObject *__pyx_v_version = 0;
  13650. PyObject *__pyx_v_tags = 0;
  13651. int __pyx_r;
  13652. __Pyx_RefNannyDeclarations
  13653. __Pyx_RefNannySetupContext("__init__ (wrapper)", 0);
  13654. {
  13655. static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_stream,&__pyx_n_s_canonical,&__pyx_n_s_indent,&__pyx_n_s_width,&__pyx_n_s_allow_unicode,&__pyx_n_s_line_break,&__pyx_n_s_encoding,&__pyx_n_s_explicit_start,&__pyx_n_s_explicit_end,&__pyx_n_s_version,&__pyx_n_s_tags,0};
  13656. PyObject* values[11] = {0,0,0,0,0,0,0,0,0,0,0};
  13657. values[1] = ((PyObject *)Py_None);
  13658. values[2] = ((PyObject *)Py_None);
  13659. values[3] = ((PyObject *)Py_None);
  13660. /* "_yaml.pyx":954
  13661. *
  13662. * def __init__(self, stream, canonical=None, indent=None, width=None,
  13663. * allow_unicode=None, line_break=None, encoding=None, # <<<<<<<<<<<<<<
  13664. * explicit_start=None, explicit_end=None, version=None, tags=None):
  13665. * if yaml_emitter_initialize(&self.emitter) == 0:
  13666. */
  13667. values[4] = ((PyObject *)Py_None);
  13668. values[5] = ((PyObject *)Py_None);
  13669. values[6] = ((PyObject *)Py_None);
  13670. /* "_yaml.pyx":955
  13671. * def __init__(self, stream, canonical=None, indent=None, width=None,
  13672. * allow_unicode=None, line_break=None, encoding=None,
  13673. * explicit_start=None, explicit_end=None, version=None, tags=None): # <<<<<<<<<<<<<<
  13674. * if yaml_emitter_initialize(&self.emitter) == 0:
  13675. * raise MemoryError
  13676. */
  13677. values[7] = ((PyObject *)Py_None);
  13678. values[8] = ((PyObject *)Py_None);
  13679. values[9] = ((PyObject *)Py_None);
  13680. values[10] = ((PyObject *)Py_None);
  13681. if (unlikely(__pyx_kwds)) {
  13682. Py_ssize_t kw_args;
  13683. const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
  13684. switch (pos_args) {
  13685. case 11: values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
  13686. CYTHON_FALLTHROUGH;
  13687. case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
  13688. CYTHON_FALLTHROUGH;
  13689. case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
  13690. CYTHON_FALLTHROUGH;
  13691. case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
  13692. CYTHON_FALLTHROUGH;
  13693. case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
  13694. CYTHON_FALLTHROUGH;
  13695. case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
  13696. CYTHON_FALLTHROUGH;
  13697. case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
  13698. CYTHON_FALLTHROUGH;
  13699. case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
  13700. CYTHON_FALLTHROUGH;
  13701. case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
  13702. CYTHON_FALLTHROUGH;
  13703. case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
  13704. CYTHON_FALLTHROUGH;
  13705. case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
  13706. CYTHON_FALLTHROUGH;
  13707. case 0: break;
  13708. default: goto __pyx_L5_argtuple_error;
  13709. }
  13710. kw_args = PyDict_Size(__pyx_kwds);
  13711. switch (pos_args) {
  13712. case 0:
  13713. if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_stream)) != 0)) kw_args--;
  13714. else goto __pyx_L5_argtuple_error;
  13715. CYTHON_FALLTHROUGH;
  13716. case 1:
  13717. if (kw_args > 0) {
  13718. PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_canonical);
  13719. if (value) { values[1] = value; kw_args--; }
  13720. }
  13721. CYTHON_FALLTHROUGH;
  13722. case 2:
  13723. if (kw_args > 0) {
  13724. PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_indent);
  13725. if (value) { values[2] = value; kw_args--; }
  13726. }
  13727. CYTHON_FALLTHROUGH;
  13728. case 3:
  13729. if (kw_args > 0) {
  13730. PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_width);
  13731. if (value) { values[3] = value; kw_args--; }
  13732. }
  13733. CYTHON_FALLTHROUGH;
  13734. case 4:
  13735. if (kw_args > 0) {
  13736. PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_allow_unicode);
  13737. if (value) { values[4] = value; kw_args--; }
  13738. }
  13739. CYTHON_FALLTHROUGH;
  13740. case 5:
  13741. if (kw_args > 0) {
  13742. PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_line_break);
  13743. if (value) { values[5] = value; kw_args--; }
  13744. }
  13745. CYTHON_FALLTHROUGH;
  13746. case 6:
  13747. if (kw_args > 0) {
  13748. PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_encoding);
  13749. if (value) { values[6] = value; kw_args--; }
  13750. }
  13751. CYTHON_FALLTHROUGH;
  13752. case 7:
  13753. if (kw_args > 0) {
  13754. PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_explicit_start);
  13755. if (value) { values[7] = value; kw_args--; }
  13756. }
  13757. CYTHON_FALLTHROUGH;
  13758. case 8:
  13759. if (kw_args > 0) {
  13760. PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_explicit_end);
  13761. if (value) { values[8] = value; kw_args--; }
  13762. }
  13763. CYTHON_FALLTHROUGH;
  13764. case 9:
  13765. if (kw_args > 0) {
  13766. PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_version);
  13767. if (value) { values[9] = value; kw_args--; }
  13768. }
  13769. CYTHON_FALLTHROUGH;
  13770. case 10:
  13771. if (kw_args > 0) {
  13772. PyObject* value = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_tags);
  13773. if (value) { values[10] = value; kw_args--; }
  13774. }
  13775. }
  13776. if (unlikely(kw_args > 0)) {
  13777. if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__init__") < 0)) __PYX_ERR(0, 953, __pyx_L3_error)
  13778. }
  13779. } else {
  13780. switch (PyTuple_GET_SIZE(__pyx_args)) {
  13781. case 11: values[10] = PyTuple_GET_ITEM(__pyx_args, 10);
  13782. CYTHON_FALLTHROUGH;
  13783. case 10: values[9] = PyTuple_GET_ITEM(__pyx_args, 9);
  13784. CYTHON_FALLTHROUGH;
  13785. case 9: values[8] = PyTuple_GET_ITEM(__pyx_args, 8);
  13786. CYTHON_FALLTHROUGH;
  13787. case 8: values[7] = PyTuple_GET_ITEM(__pyx_args, 7);
  13788. CYTHON_FALLTHROUGH;
  13789. case 7: values[6] = PyTuple_GET_ITEM(__pyx_args, 6);
  13790. CYTHON_FALLTHROUGH;
  13791. case 6: values[5] = PyTuple_GET_ITEM(__pyx_args, 5);
  13792. CYTHON_FALLTHROUGH;
  13793. case 5: values[4] = PyTuple_GET_ITEM(__pyx_args, 4);
  13794. CYTHON_FALLTHROUGH;
  13795. case 4: values[3] = PyTuple_GET_ITEM(__pyx_args, 3);
  13796. CYTHON_FALLTHROUGH;
  13797. case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
  13798. CYTHON_FALLTHROUGH;
  13799. case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
  13800. CYTHON_FALLTHROUGH;
  13801. case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
  13802. break;
  13803. default: goto __pyx_L5_argtuple_error;
  13804. }
  13805. }
  13806. __pyx_v_stream = values[0];
  13807. __pyx_v_canonical = values[1];
  13808. __pyx_v_indent = values[2];
  13809. __pyx_v_width = values[3];
  13810. __pyx_v_allow_unicode = values[4];
  13811. __pyx_v_line_break = values[5];
  13812. __pyx_v_encoding = values[6];
  13813. __pyx_v_explicit_start = values[7];
  13814. __pyx_v_explicit_end = values[8];
  13815. __pyx_v_version = values[9];
  13816. __pyx_v_tags = values[10];
  13817. }
  13818. goto __pyx_L4_argument_unpacking_done;
  13819. __pyx_L5_argtuple_error:;
  13820. __Pyx_RaiseArgtupleInvalid("__init__", 0, 1, 11, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(0, 953, __pyx_L3_error)
  13821. __pyx_L3_error:;
  13822. __Pyx_AddTraceback("_yaml.CEmitter.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  13823. __Pyx_RefNannyFinishContext();
  13824. return -1;
  13825. __pyx_L4_argument_unpacking_done:;
  13826. __pyx_r = __pyx_pf_5_yaml_8CEmitter___init__(((struct __pyx_obj_5_yaml_CEmitter *)__pyx_v_self), __pyx_v_stream, __pyx_v_canonical, __pyx_v_indent, __pyx_v_width, __pyx_v_allow_unicode, __pyx_v_line_break, __pyx_v_encoding, __pyx_v_explicit_start, __pyx_v_explicit_end, __pyx_v_version, __pyx_v_tags);
  13827. /* "_yaml.pyx":953
  13828. * cdef object use_encoding
  13829. *
  13830. * def __init__(self, stream, canonical=None, indent=None, width=None, # <<<<<<<<<<<<<<
  13831. * allow_unicode=None, line_break=None, encoding=None,
  13832. * explicit_start=None, explicit_end=None, version=None, tags=None):
  13833. */
  13834. /* function exit code */
  13835. __Pyx_RefNannyFinishContext();
  13836. return __pyx_r;
  13837. }
  13838. static int __pyx_pf_5_yaml_8CEmitter___init__(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self, PyObject *__pyx_v_stream, PyObject *__pyx_v_canonical, PyObject *__pyx_v_indent, PyObject *__pyx_v_width, PyObject *__pyx_v_allow_unicode, PyObject *__pyx_v_line_break, PyObject *__pyx_v_encoding, PyObject *__pyx_v_explicit_start, PyObject *__pyx_v_explicit_end, PyObject *__pyx_v_version, PyObject *__pyx_v_tags) {
  13839. int __pyx_r;
  13840. __Pyx_RefNannyDeclarations
  13841. int __pyx_t_1;
  13842. PyObject *__pyx_t_2 = NULL;
  13843. int __pyx_t_3;
  13844. int __pyx_t_4;
  13845. __Pyx_RefNannySetupContext("__init__", 0);
  13846. /* "_yaml.pyx":956
  13847. * allow_unicode=None, line_break=None, encoding=None,
  13848. * explicit_start=None, explicit_end=None, version=None, tags=None):
  13849. * if yaml_emitter_initialize(&self.emitter) == 0: # <<<<<<<<<<<<<<
  13850. * raise MemoryError
  13851. * self.stream = stream
  13852. */
  13853. __pyx_t_1 = ((yaml_emitter_initialize((&__pyx_v_self->emitter)) == 0) != 0);
  13854. if (unlikely(__pyx_t_1)) {
  13855. /* "_yaml.pyx":957
  13856. * explicit_start=None, explicit_end=None, version=None, tags=None):
  13857. * if yaml_emitter_initialize(&self.emitter) == 0:
  13858. * raise MemoryError # <<<<<<<<<<<<<<
  13859. * self.stream = stream
  13860. * self.dump_unicode = 0
  13861. */
  13862. PyErr_NoMemory(); __PYX_ERR(0, 957, __pyx_L1_error)
  13863. /* "_yaml.pyx":956
  13864. * allow_unicode=None, line_break=None, encoding=None,
  13865. * explicit_start=None, explicit_end=None, version=None, tags=None):
  13866. * if yaml_emitter_initialize(&self.emitter) == 0: # <<<<<<<<<<<<<<
  13867. * raise MemoryError
  13868. * self.stream = stream
  13869. */
  13870. }
  13871. /* "_yaml.pyx":958
  13872. * if yaml_emitter_initialize(&self.emitter) == 0:
  13873. * raise MemoryError
  13874. * self.stream = stream # <<<<<<<<<<<<<<
  13875. * self.dump_unicode = 0
  13876. * if PY_MAJOR_VERSION < 3:
  13877. */
  13878. __Pyx_INCREF(__pyx_v_stream);
  13879. __Pyx_GIVEREF(__pyx_v_stream);
  13880. __Pyx_GOTREF(__pyx_v_self->stream);
  13881. __Pyx_DECREF(__pyx_v_self->stream);
  13882. __pyx_v_self->stream = __pyx_v_stream;
  13883. /* "_yaml.pyx":959
  13884. * raise MemoryError
  13885. * self.stream = stream
  13886. * self.dump_unicode = 0 # <<<<<<<<<<<<<<
  13887. * if PY_MAJOR_VERSION < 3:
  13888. * if getattr3(stream, 'encoding', None):
  13889. */
  13890. __pyx_v_self->dump_unicode = 0;
  13891. /* "_yaml.pyx":960
  13892. * self.stream = stream
  13893. * self.dump_unicode = 0
  13894. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  13895. * if getattr3(stream, 'encoding', None):
  13896. * self.dump_unicode = 1
  13897. */
  13898. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  13899. if (__pyx_t_1) {
  13900. /* "_yaml.pyx":961
  13901. * self.dump_unicode = 0
  13902. * if PY_MAJOR_VERSION < 3:
  13903. * if getattr3(stream, 'encoding', None): # <<<<<<<<<<<<<<
  13904. * self.dump_unicode = 1
  13905. * else:
  13906. */
  13907. __pyx_t_2 = __Pyx_GetAttr3(__pyx_v_stream, __pyx_n_s_encoding, Py_None); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 961, __pyx_L1_error)
  13908. __Pyx_GOTREF(__pyx_t_2);
  13909. __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_t_2); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 961, __pyx_L1_error)
  13910. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  13911. if (__pyx_t_1) {
  13912. /* "_yaml.pyx":962
  13913. * if PY_MAJOR_VERSION < 3:
  13914. * if getattr3(stream, 'encoding', None):
  13915. * self.dump_unicode = 1 # <<<<<<<<<<<<<<
  13916. * else:
  13917. * if hasattr(stream, u'encoding'):
  13918. */
  13919. __pyx_v_self->dump_unicode = 1;
  13920. /* "_yaml.pyx":961
  13921. * self.dump_unicode = 0
  13922. * if PY_MAJOR_VERSION < 3:
  13923. * if getattr3(stream, 'encoding', None): # <<<<<<<<<<<<<<
  13924. * self.dump_unicode = 1
  13925. * else:
  13926. */
  13927. }
  13928. /* "_yaml.pyx":960
  13929. * self.stream = stream
  13930. * self.dump_unicode = 0
  13931. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  13932. * if getattr3(stream, 'encoding', None):
  13933. * self.dump_unicode = 1
  13934. */
  13935. goto __pyx_L4;
  13936. }
  13937. /* "_yaml.pyx":964
  13938. * self.dump_unicode = 1
  13939. * else:
  13940. * if hasattr(stream, u'encoding'): # <<<<<<<<<<<<<<
  13941. * self.dump_unicode = 1
  13942. * self.use_encoding = encoding
  13943. */
  13944. /*else*/ {
  13945. __pyx_t_1 = __Pyx_HasAttr(__pyx_v_stream, __pyx_n_u_encoding); if (unlikely(__pyx_t_1 == ((int)-1))) __PYX_ERR(0, 964, __pyx_L1_error)
  13946. __pyx_t_3 = (__pyx_t_1 != 0);
  13947. if (__pyx_t_3) {
  13948. /* "_yaml.pyx":965
  13949. * else:
  13950. * if hasattr(stream, u'encoding'):
  13951. * self.dump_unicode = 1 # <<<<<<<<<<<<<<
  13952. * self.use_encoding = encoding
  13953. * yaml_emitter_set_output(&self.emitter, output_handler, <void *>self)
  13954. */
  13955. __pyx_v_self->dump_unicode = 1;
  13956. /* "_yaml.pyx":964
  13957. * self.dump_unicode = 1
  13958. * else:
  13959. * if hasattr(stream, u'encoding'): # <<<<<<<<<<<<<<
  13960. * self.dump_unicode = 1
  13961. * self.use_encoding = encoding
  13962. */
  13963. }
  13964. }
  13965. __pyx_L4:;
  13966. /* "_yaml.pyx":966
  13967. * if hasattr(stream, u'encoding'):
  13968. * self.dump_unicode = 1
  13969. * self.use_encoding = encoding # <<<<<<<<<<<<<<
  13970. * yaml_emitter_set_output(&self.emitter, output_handler, <void *>self)
  13971. * if canonical:
  13972. */
  13973. __Pyx_INCREF(__pyx_v_encoding);
  13974. __Pyx_GIVEREF(__pyx_v_encoding);
  13975. __Pyx_GOTREF(__pyx_v_self->use_encoding);
  13976. __Pyx_DECREF(__pyx_v_self->use_encoding);
  13977. __pyx_v_self->use_encoding = __pyx_v_encoding;
  13978. /* "_yaml.pyx":967
  13979. * self.dump_unicode = 1
  13980. * self.use_encoding = encoding
  13981. * yaml_emitter_set_output(&self.emitter, output_handler, <void *>self) # <<<<<<<<<<<<<<
  13982. * if canonical:
  13983. * yaml_emitter_set_canonical(&self.emitter, 1)
  13984. */
  13985. yaml_emitter_set_output((&__pyx_v_self->emitter), __pyx_f_5_yaml_output_handler, ((void *)__pyx_v_self));
  13986. /* "_yaml.pyx":968
  13987. * self.use_encoding = encoding
  13988. * yaml_emitter_set_output(&self.emitter, output_handler, <void *>self)
  13989. * if canonical: # <<<<<<<<<<<<<<
  13990. * yaml_emitter_set_canonical(&self.emitter, 1)
  13991. * if indent is not None:
  13992. */
  13993. __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_canonical); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 968, __pyx_L1_error)
  13994. if (__pyx_t_3) {
  13995. /* "_yaml.pyx":969
  13996. * yaml_emitter_set_output(&self.emitter, output_handler, <void *>self)
  13997. * if canonical:
  13998. * yaml_emitter_set_canonical(&self.emitter, 1) # <<<<<<<<<<<<<<
  13999. * if indent is not None:
  14000. * yaml_emitter_set_indent(&self.emitter, indent)
  14001. */
  14002. yaml_emitter_set_canonical((&__pyx_v_self->emitter), 1);
  14003. /* "_yaml.pyx":968
  14004. * self.use_encoding = encoding
  14005. * yaml_emitter_set_output(&self.emitter, output_handler, <void *>self)
  14006. * if canonical: # <<<<<<<<<<<<<<
  14007. * yaml_emitter_set_canonical(&self.emitter, 1)
  14008. * if indent is not None:
  14009. */
  14010. }
  14011. /* "_yaml.pyx":970
  14012. * if canonical:
  14013. * yaml_emitter_set_canonical(&self.emitter, 1)
  14014. * if indent is not None: # <<<<<<<<<<<<<<
  14015. * yaml_emitter_set_indent(&self.emitter, indent)
  14016. * if width is not None:
  14017. */
  14018. __pyx_t_3 = (__pyx_v_indent != Py_None);
  14019. __pyx_t_1 = (__pyx_t_3 != 0);
  14020. if (__pyx_t_1) {
  14021. /* "_yaml.pyx":971
  14022. * yaml_emitter_set_canonical(&self.emitter, 1)
  14023. * if indent is not None:
  14024. * yaml_emitter_set_indent(&self.emitter, indent) # <<<<<<<<<<<<<<
  14025. * if width is not None:
  14026. * yaml_emitter_set_width(&self.emitter, width)
  14027. */
  14028. __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_v_indent); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 971, __pyx_L1_error)
  14029. yaml_emitter_set_indent((&__pyx_v_self->emitter), __pyx_t_4);
  14030. /* "_yaml.pyx":970
  14031. * if canonical:
  14032. * yaml_emitter_set_canonical(&self.emitter, 1)
  14033. * if indent is not None: # <<<<<<<<<<<<<<
  14034. * yaml_emitter_set_indent(&self.emitter, indent)
  14035. * if width is not None:
  14036. */
  14037. }
  14038. /* "_yaml.pyx":972
  14039. * if indent is not None:
  14040. * yaml_emitter_set_indent(&self.emitter, indent)
  14041. * if width is not None: # <<<<<<<<<<<<<<
  14042. * yaml_emitter_set_width(&self.emitter, width)
  14043. * if allow_unicode:
  14044. */
  14045. __pyx_t_1 = (__pyx_v_width != Py_None);
  14046. __pyx_t_3 = (__pyx_t_1 != 0);
  14047. if (__pyx_t_3) {
  14048. /* "_yaml.pyx":973
  14049. * yaml_emitter_set_indent(&self.emitter, indent)
  14050. * if width is not None:
  14051. * yaml_emitter_set_width(&self.emitter, width) # <<<<<<<<<<<<<<
  14052. * if allow_unicode:
  14053. * yaml_emitter_set_unicode(&self.emitter, 1)
  14054. */
  14055. __pyx_t_4 = __Pyx_PyInt_As_int(__pyx_v_width); if (unlikely((__pyx_t_4 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 973, __pyx_L1_error)
  14056. yaml_emitter_set_width((&__pyx_v_self->emitter), __pyx_t_4);
  14057. /* "_yaml.pyx":972
  14058. * if indent is not None:
  14059. * yaml_emitter_set_indent(&self.emitter, indent)
  14060. * if width is not None: # <<<<<<<<<<<<<<
  14061. * yaml_emitter_set_width(&self.emitter, width)
  14062. * if allow_unicode:
  14063. */
  14064. }
  14065. /* "_yaml.pyx":974
  14066. * if width is not None:
  14067. * yaml_emitter_set_width(&self.emitter, width)
  14068. * if allow_unicode: # <<<<<<<<<<<<<<
  14069. * yaml_emitter_set_unicode(&self.emitter, 1)
  14070. * if line_break is not None:
  14071. */
  14072. __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_v_allow_unicode); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 974, __pyx_L1_error)
  14073. if (__pyx_t_3) {
  14074. /* "_yaml.pyx":975
  14075. * yaml_emitter_set_width(&self.emitter, width)
  14076. * if allow_unicode:
  14077. * yaml_emitter_set_unicode(&self.emitter, 1) # <<<<<<<<<<<<<<
  14078. * if line_break is not None:
  14079. * if line_break == '\r':
  14080. */
  14081. yaml_emitter_set_unicode((&__pyx_v_self->emitter), 1);
  14082. /* "_yaml.pyx":974
  14083. * if width is not None:
  14084. * yaml_emitter_set_width(&self.emitter, width)
  14085. * if allow_unicode: # <<<<<<<<<<<<<<
  14086. * yaml_emitter_set_unicode(&self.emitter, 1)
  14087. * if line_break is not None:
  14088. */
  14089. }
  14090. /* "_yaml.pyx":976
  14091. * if allow_unicode:
  14092. * yaml_emitter_set_unicode(&self.emitter, 1)
  14093. * if line_break is not None: # <<<<<<<<<<<<<<
  14094. * if line_break == '\r':
  14095. * yaml_emitter_set_break(&self.emitter, YAML_CR_BREAK)
  14096. */
  14097. __pyx_t_3 = (__pyx_v_line_break != Py_None);
  14098. __pyx_t_1 = (__pyx_t_3 != 0);
  14099. if (__pyx_t_1) {
  14100. /* "_yaml.pyx":977
  14101. * yaml_emitter_set_unicode(&self.emitter, 1)
  14102. * if line_break is not None:
  14103. * if line_break == '\r': # <<<<<<<<<<<<<<
  14104. * yaml_emitter_set_break(&self.emitter, YAML_CR_BREAK)
  14105. * elif line_break == '\n':
  14106. */
  14107. __pyx_t_1 = (__Pyx_PyString_Equals(__pyx_v_line_break, __pyx_kp_s__19, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 977, __pyx_L1_error)
  14108. if (__pyx_t_1) {
  14109. /* "_yaml.pyx":978
  14110. * if line_break is not None:
  14111. * if line_break == '\r':
  14112. * yaml_emitter_set_break(&self.emitter, YAML_CR_BREAK) # <<<<<<<<<<<<<<
  14113. * elif line_break == '\n':
  14114. * yaml_emitter_set_break(&self.emitter, YAML_LN_BREAK)
  14115. */
  14116. yaml_emitter_set_break((&__pyx_v_self->emitter), YAML_CR_BREAK);
  14117. /* "_yaml.pyx":977
  14118. * yaml_emitter_set_unicode(&self.emitter, 1)
  14119. * if line_break is not None:
  14120. * if line_break == '\r': # <<<<<<<<<<<<<<
  14121. * yaml_emitter_set_break(&self.emitter, YAML_CR_BREAK)
  14122. * elif line_break == '\n':
  14123. */
  14124. goto __pyx_L12;
  14125. }
  14126. /* "_yaml.pyx":979
  14127. * if line_break == '\r':
  14128. * yaml_emitter_set_break(&self.emitter, YAML_CR_BREAK)
  14129. * elif line_break == '\n': # <<<<<<<<<<<<<<
  14130. * yaml_emitter_set_break(&self.emitter, YAML_LN_BREAK)
  14131. * elif line_break == '\r\n':
  14132. */
  14133. __pyx_t_1 = (__Pyx_PyString_Equals(__pyx_v_line_break, __pyx_kp_s__20, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 979, __pyx_L1_error)
  14134. if (__pyx_t_1) {
  14135. /* "_yaml.pyx":980
  14136. * yaml_emitter_set_break(&self.emitter, YAML_CR_BREAK)
  14137. * elif line_break == '\n':
  14138. * yaml_emitter_set_break(&self.emitter, YAML_LN_BREAK) # <<<<<<<<<<<<<<
  14139. * elif line_break == '\r\n':
  14140. * yaml_emitter_set_break(&self.emitter, YAML_CRLN_BREAK)
  14141. */
  14142. yaml_emitter_set_break((&__pyx_v_self->emitter), YAML_LN_BREAK);
  14143. /* "_yaml.pyx":979
  14144. * if line_break == '\r':
  14145. * yaml_emitter_set_break(&self.emitter, YAML_CR_BREAK)
  14146. * elif line_break == '\n': # <<<<<<<<<<<<<<
  14147. * yaml_emitter_set_break(&self.emitter, YAML_LN_BREAK)
  14148. * elif line_break == '\r\n':
  14149. */
  14150. goto __pyx_L12;
  14151. }
  14152. /* "_yaml.pyx":981
  14153. * elif line_break == '\n':
  14154. * yaml_emitter_set_break(&self.emitter, YAML_LN_BREAK)
  14155. * elif line_break == '\r\n': # <<<<<<<<<<<<<<
  14156. * yaml_emitter_set_break(&self.emitter, YAML_CRLN_BREAK)
  14157. * self.document_start_implicit = 1
  14158. */
  14159. __pyx_t_1 = (__Pyx_PyString_Equals(__pyx_v_line_break, __pyx_kp_s__21, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 981, __pyx_L1_error)
  14160. if (__pyx_t_1) {
  14161. /* "_yaml.pyx":982
  14162. * yaml_emitter_set_break(&self.emitter, YAML_LN_BREAK)
  14163. * elif line_break == '\r\n':
  14164. * yaml_emitter_set_break(&self.emitter, YAML_CRLN_BREAK) # <<<<<<<<<<<<<<
  14165. * self.document_start_implicit = 1
  14166. * if explicit_start:
  14167. */
  14168. yaml_emitter_set_break((&__pyx_v_self->emitter), YAML_CRLN_BREAK);
  14169. /* "_yaml.pyx":981
  14170. * elif line_break == '\n':
  14171. * yaml_emitter_set_break(&self.emitter, YAML_LN_BREAK)
  14172. * elif line_break == '\r\n': # <<<<<<<<<<<<<<
  14173. * yaml_emitter_set_break(&self.emitter, YAML_CRLN_BREAK)
  14174. * self.document_start_implicit = 1
  14175. */
  14176. }
  14177. __pyx_L12:;
  14178. /* "_yaml.pyx":976
  14179. * if allow_unicode:
  14180. * yaml_emitter_set_unicode(&self.emitter, 1)
  14181. * if line_break is not None: # <<<<<<<<<<<<<<
  14182. * if line_break == '\r':
  14183. * yaml_emitter_set_break(&self.emitter, YAML_CR_BREAK)
  14184. */
  14185. }
  14186. /* "_yaml.pyx":983
  14187. * elif line_break == '\r\n':
  14188. * yaml_emitter_set_break(&self.emitter, YAML_CRLN_BREAK)
  14189. * self.document_start_implicit = 1 # <<<<<<<<<<<<<<
  14190. * if explicit_start:
  14191. * self.document_start_implicit = 0
  14192. */
  14193. __pyx_v_self->document_start_implicit = 1;
  14194. /* "_yaml.pyx":984
  14195. * yaml_emitter_set_break(&self.emitter, YAML_CRLN_BREAK)
  14196. * self.document_start_implicit = 1
  14197. * if explicit_start: # <<<<<<<<<<<<<<
  14198. * self.document_start_implicit = 0
  14199. * self.document_end_implicit = 1
  14200. */
  14201. __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_explicit_start); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 984, __pyx_L1_error)
  14202. if (__pyx_t_1) {
  14203. /* "_yaml.pyx":985
  14204. * self.document_start_implicit = 1
  14205. * if explicit_start:
  14206. * self.document_start_implicit = 0 # <<<<<<<<<<<<<<
  14207. * self.document_end_implicit = 1
  14208. * if explicit_end:
  14209. */
  14210. __pyx_v_self->document_start_implicit = 0;
  14211. /* "_yaml.pyx":984
  14212. * yaml_emitter_set_break(&self.emitter, YAML_CRLN_BREAK)
  14213. * self.document_start_implicit = 1
  14214. * if explicit_start: # <<<<<<<<<<<<<<
  14215. * self.document_start_implicit = 0
  14216. * self.document_end_implicit = 1
  14217. */
  14218. }
  14219. /* "_yaml.pyx":986
  14220. * if explicit_start:
  14221. * self.document_start_implicit = 0
  14222. * self.document_end_implicit = 1 # <<<<<<<<<<<<<<
  14223. * if explicit_end:
  14224. * self.document_end_implicit = 0
  14225. */
  14226. __pyx_v_self->document_end_implicit = 1;
  14227. /* "_yaml.pyx":987
  14228. * self.document_start_implicit = 0
  14229. * self.document_end_implicit = 1
  14230. * if explicit_end: # <<<<<<<<<<<<<<
  14231. * self.document_end_implicit = 0
  14232. * self.use_version = version
  14233. */
  14234. __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_explicit_end); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 987, __pyx_L1_error)
  14235. if (__pyx_t_1) {
  14236. /* "_yaml.pyx":988
  14237. * self.document_end_implicit = 1
  14238. * if explicit_end:
  14239. * self.document_end_implicit = 0 # <<<<<<<<<<<<<<
  14240. * self.use_version = version
  14241. * self.use_tags = tags
  14242. */
  14243. __pyx_v_self->document_end_implicit = 0;
  14244. /* "_yaml.pyx":987
  14245. * self.document_start_implicit = 0
  14246. * self.document_end_implicit = 1
  14247. * if explicit_end: # <<<<<<<<<<<<<<
  14248. * self.document_end_implicit = 0
  14249. * self.use_version = version
  14250. */
  14251. }
  14252. /* "_yaml.pyx":989
  14253. * if explicit_end:
  14254. * self.document_end_implicit = 0
  14255. * self.use_version = version # <<<<<<<<<<<<<<
  14256. * self.use_tags = tags
  14257. * self.serialized_nodes = {}
  14258. */
  14259. __Pyx_INCREF(__pyx_v_version);
  14260. __Pyx_GIVEREF(__pyx_v_version);
  14261. __Pyx_GOTREF(__pyx_v_self->use_version);
  14262. __Pyx_DECREF(__pyx_v_self->use_version);
  14263. __pyx_v_self->use_version = __pyx_v_version;
  14264. /* "_yaml.pyx":990
  14265. * self.document_end_implicit = 0
  14266. * self.use_version = version
  14267. * self.use_tags = tags # <<<<<<<<<<<<<<
  14268. * self.serialized_nodes = {}
  14269. * self.anchors = {}
  14270. */
  14271. __Pyx_INCREF(__pyx_v_tags);
  14272. __Pyx_GIVEREF(__pyx_v_tags);
  14273. __Pyx_GOTREF(__pyx_v_self->use_tags);
  14274. __Pyx_DECREF(__pyx_v_self->use_tags);
  14275. __pyx_v_self->use_tags = __pyx_v_tags;
  14276. /* "_yaml.pyx":991
  14277. * self.use_version = version
  14278. * self.use_tags = tags
  14279. * self.serialized_nodes = {} # <<<<<<<<<<<<<<
  14280. * self.anchors = {}
  14281. * self.last_alias_id = 0
  14282. */
  14283. __pyx_t_2 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 991, __pyx_L1_error)
  14284. __Pyx_GOTREF(__pyx_t_2);
  14285. __Pyx_GIVEREF(__pyx_t_2);
  14286. __Pyx_GOTREF(__pyx_v_self->serialized_nodes);
  14287. __Pyx_DECREF(__pyx_v_self->serialized_nodes);
  14288. __pyx_v_self->serialized_nodes = __pyx_t_2;
  14289. __pyx_t_2 = 0;
  14290. /* "_yaml.pyx":992
  14291. * self.use_tags = tags
  14292. * self.serialized_nodes = {}
  14293. * self.anchors = {} # <<<<<<<<<<<<<<
  14294. * self.last_alias_id = 0
  14295. * self.closed = -1
  14296. */
  14297. __pyx_t_2 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 992, __pyx_L1_error)
  14298. __Pyx_GOTREF(__pyx_t_2);
  14299. __Pyx_GIVEREF(__pyx_t_2);
  14300. __Pyx_GOTREF(__pyx_v_self->anchors);
  14301. __Pyx_DECREF(__pyx_v_self->anchors);
  14302. __pyx_v_self->anchors = __pyx_t_2;
  14303. __pyx_t_2 = 0;
  14304. /* "_yaml.pyx":993
  14305. * self.serialized_nodes = {}
  14306. * self.anchors = {}
  14307. * self.last_alias_id = 0 # <<<<<<<<<<<<<<
  14308. * self.closed = -1
  14309. *
  14310. */
  14311. __pyx_v_self->last_alias_id = 0;
  14312. /* "_yaml.pyx":994
  14313. * self.anchors = {}
  14314. * self.last_alias_id = 0
  14315. * self.closed = -1 # <<<<<<<<<<<<<<
  14316. *
  14317. * def __dealloc__(self):
  14318. */
  14319. __pyx_v_self->closed = -1;
  14320. /* "_yaml.pyx":953
  14321. * cdef object use_encoding
  14322. *
  14323. * def __init__(self, stream, canonical=None, indent=None, width=None, # <<<<<<<<<<<<<<
  14324. * allow_unicode=None, line_break=None, encoding=None,
  14325. * explicit_start=None, explicit_end=None, version=None, tags=None):
  14326. */
  14327. /* function exit code */
  14328. __pyx_r = 0;
  14329. goto __pyx_L0;
  14330. __pyx_L1_error:;
  14331. __Pyx_XDECREF(__pyx_t_2);
  14332. __Pyx_AddTraceback("_yaml.CEmitter.__init__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  14333. __pyx_r = -1;
  14334. __pyx_L0:;
  14335. __Pyx_RefNannyFinishContext();
  14336. return __pyx_r;
  14337. }
  14338. /* "_yaml.pyx":996
  14339. * self.closed = -1
  14340. *
  14341. * def __dealloc__(self): # <<<<<<<<<<<<<<
  14342. * yaml_emitter_delete(&self.emitter)
  14343. *
  14344. */
  14345. /* Python wrapper */
  14346. static void __pyx_pw_5_yaml_8CEmitter_3__dealloc__(PyObject *__pyx_v_self); /*proto*/
  14347. static void __pyx_pw_5_yaml_8CEmitter_3__dealloc__(PyObject *__pyx_v_self) {
  14348. __Pyx_RefNannyDeclarations
  14349. __Pyx_RefNannySetupContext("__dealloc__ (wrapper)", 0);
  14350. __pyx_pf_5_yaml_8CEmitter_2__dealloc__(((struct __pyx_obj_5_yaml_CEmitter *)__pyx_v_self));
  14351. /* function exit code */
  14352. __Pyx_RefNannyFinishContext();
  14353. }
  14354. static void __pyx_pf_5_yaml_8CEmitter_2__dealloc__(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self) {
  14355. __Pyx_RefNannyDeclarations
  14356. __Pyx_RefNannySetupContext("__dealloc__", 0);
  14357. /* "_yaml.pyx":997
  14358. *
  14359. * def __dealloc__(self):
  14360. * yaml_emitter_delete(&self.emitter) # <<<<<<<<<<<<<<
  14361. *
  14362. * def dispose(self):
  14363. */
  14364. yaml_emitter_delete((&__pyx_v_self->emitter));
  14365. /* "_yaml.pyx":996
  14366. * self.closed = -1
  14367. *
  14368. * def __dealloc__(self): # <<<<<<<<<<<<<<
  14369. * yaml_emitter_delete(&self.emitter)
  14370. *
  14371. */
  14372. /* function exit code */
  14373. __Pyx_RefNannyFinishContext();
  14374. }
  14375. /* "_yaml.pyx":999
  14376. * yaml_emitter_delete(&self.emitter)
  14377. *
  14378. * def dispose(self): # <<<<<<<<<<<<<<
  14379. * pass
  14380. *
  14381. */
  14382. /* Python wrapper */
  14383. static PyObject *__pyx_pw_5_yaml_8CEmitter_5dispose(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  14384. static PyObject *__pyx_pw_5_yaml_8CEmitter_5dispose(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  14385. PyObject *__pyx_r = 0;
  14386. __Pyx_RefNannyDeclarations
  14387. __Pyx_RefNannySetupContext("dispose (wrapper)", 0);
  14388. __pyx_r = __pyx_pf_5_yaml_8CEmitter_4dispose(((struct __pyx_obj_5_yaml_CEmitter *)__pyx_v_self));
  14389. /* function exit code */
  14390. __Pyx_RefNannyFinishContext();
  14391. return __pyx_r;
  14392. }
  14393. static PyObject *__pyx_pf_5_yaml_8CEmitter_4dispose(CYTHON_UNUSED struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self) {
  14394. PyObject *__pyx_r = NULL;
  14395. __Pyx_RefNannyDeclarations
  14396. __Pyx_RefNannySetupContext("dispose", 0);
  14397. /* function exit code */
  14398. __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  14399. __Pyx_XGIVEREF(__pyx_r);
  14400. __Pyx_RefNannyFinishContext();
  14401. return __pyx_r;
  14402. }
  14403. /* "_yaml.pyx":1002
  14404. * pass
  14405. *
  14406. * cdef object _emitter_error(self): # <<<<<<<<<<<<<<
  14407. * if self.emitter.error == YAML_MEMORY_ERROR:
  14408. * return MemoryError
  14409. */
  14410. static PyObject *__pyx_f_5_yaml_8CEmitter__emitter_error(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self) {
  14411. PyObject *__pyx_v_problem = NULL;
  14412. PyObject *__pyx_r = NULL;
  14413. __Pyx_RefNannyDeclarations
  14414. int __pyx_t_1;
  14415. PyObject *__pyx_t_2 = NULL;
  14416. PyObject *__pyx_t_3 = NULL;
  14417. PyObject *__pyx_t_4 = NULL;
  14418. __Pyx_RefNannySetupContext("_emitter_error", 0);
  14419. /* "_yaml.pyx":1003
  14420. *
  14421. * cdef object _emitter_error(self):
  14422. * if self.emitter.error == YAML_MEMORY_ERROR: # <<<<<<<<<<<<<<
  14423. * return MemoryError
  14424. * elif self.emitter.error == YAML_EMITTER_ERROR:
  14425. */
  14426. switch (__pyx_v_self->emitter.error) {
  14427. case YAML_MEMORY_ERROR:
  14428. /* "_yaml.pyx":1004
  14429. * cdef object _emitter_error(self):
  14430. * if self.emitter.error == YAML_MEMORY_ERROR:
  14431. * return MemoryError # <<<<<<<<<<<<<<
  14432. * elif self.emitter.error == YAML_EMITTER_ERROR:
  14433. * if PY_MAJOR_VERSION < 3:
  14434. */
  14435. __Pyx_XDECREF(__pyx_r);
  14436. __Pyx_INCREF(__pyx_builtin_MemoryError);
  14437. __pyx_r = __pyx_builtin_MemoryError;
  14438. goto __pyx_L0;
  14439. /* "_yaml.pyx":1003
  14440. *
  14441. * cdef object _emitter_error(self):
  14442. * if self.emitter.error == YAML_MEMORY_ERROR: # <<<<<<<<<<<<<<
  14443. * return MemoryError
  14444. * elif self.emitter.error == YAML_EMITTER_ERROR:
  14445. */
  14446. break;
  14447. case YAML_EMITTER_ERROR:
  14448. /* "_yaml.pyx":1006
  14449. * return MemoryError
  14450. * elif self.emitter.error == YAML_EMITTER_ERROR:
  14451. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  14452. * problem = self.emitter.problem
  14453. * else:
  14454. */
  14455. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  14456. if (__pyx_t_1) {
  14457. /* "_yaml.pyx":1007
  14458. * elif self.emitter.error == YAML_EMITTER_ERROR:
  14459. * if PY_MAJOR_VERSION < 3:
  14460. * problem = self.emitter.problem # <<<<<<<<<<<<<<
  14461. * else:
  14462. * problem = PyUnicode_FromString(self.emitter.problem)
  14463. */
  14464. __pyx_t_2 = __Pyx_PyBytes_FromString(__pyx_v_self->emitter.problem); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1007, __pyx_L1_error)
  14465. __Pyx_GOTREF(__pyx_t_2);
  14466. __pyx_v_problem = __pyx_t_2;
  14467. __pyx_t_2 = 0;
  14468. /* "_yaml.pyx":1006
  14469. * return MemoryError
  14470. * elif self.emitter.error == YAML_EMITTER_ERROR:
  14471. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  14472. * problem = self.emitter.problem
  14473. * else:
  14474. */
  14475. goto __pyx_L3;
  14476. }
  14477. /* "_yaml.pyx":1009
  14478. * problem = self.emitter.problem
  14479. * else:
  14480. * problem = PyUnicode_FromString(self.emitter.problem) # <<<<<<<<<<<<<<
  14481. * return EmitterError(problem)
  14482. * if PY_MAJOR_VERSION < 3:
  14483. */
  14484. /*else*/ {
  14485. __pyx_t_2 = PyUnicode_FromString(__pyx_v_self->emitter.problem); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1009, __pyx_L1_error)
  14486. __Pyx_GOTREF(__pyx_t_2);
  14487. __pyx_v_problem = __pyx_t_2;
  14488. __pyx_t_2 = 0;
  14489. }
  14490. __pyx_L3:;
  14491. /* "_yaml.pyx":1010
  14492. * else:
  14493. * problem = PyUnicode_FromString(self.emitter.problem)
  14494. * return EmitterError(problem) # <<<<<<<<<<<<<<
  14495. * if PY_MAJOR_VERSION < 3:
  14496. * raise ValueError("no emitter error")
  14497. */
  14498. __Pyx_XDECREF(__pyx_r);
  14499. __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_EmitterError); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1010, __pyx_L1_error)
  14500. __Pyx_GOTREF(__pyx_t_3);
  14501. __pyx_t_4 = NULL;
  14502. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
  14503. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
  14504. if (likely(__pyx_t_4)) {
  14505. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
  14506. __Pyx_INCREF(__pyx_t_4);
  14507. __Pyx_INCREF(function);
  14508. __Pyx_DECREF_SET(__pyx_t_3, function);
  14509. }
  14510. }
  14511. __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_v_problem) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_problem);
  14512. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  14513. if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1010, __pyx_L1_error)
  14514. __Pyx_GOTREF(__pyx_t_2);
  14515. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  14516. __pyx_r = __pyx_t_2;
  14517. __pyx_t_2 = 0;
  14518. goto __pyx_L0;
  14519. /* "_yaml.pyx":1005
  14520. * if self.emitter.error == YAML_MEMORY_ERROR:
  14521. * return MemoryError
  14522. * elif self.emitter.error == YAML_EMITTER_ERROR: # <<<<<<<<<<<<<<
  14523. * if PY_MAJOR_VERSION < 3:
  14524. * problem = self.emitter.problem
  14525. */
  14526. break;
  14527. default: break;
  14528. }
  14529. /* "_yaml.pyx":1011
  14530. * problem = PyUnicode_FromString(self.emitter.problem)
  14531. * return EmitterError(problem)
  14532. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  14533. * raise ValueError("no emitter error")
  14534. * else:
  14535. */
  14536. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  14537. if (unlikely(__pyx_t_1)) {
  14538. /* "_yaml.pyx":1012
  14539. * return EmitterError(problem)
  14540. * if PY_MAJOR_VERSION < 3:
  14541. * raise ValueError("no emitter error") # <<<<<<<<<<<<<<
  14542. * else:
  14543. * raise ValueError(u"no emitter error")
  14544. */
  14545. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__22, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1012, __pyx_L1_error)
  14546. __Pyx_GOTREF(__pyx_t_2);
  14547. __Pyx_Raise(__pyx_t_2, 0, 0, 0);
  14548. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  14549. __PYX_ERR(0, 1012, __pyx_L1_error)
  14550. /* "_yaml.pyx":1011
  14551. * problem = PyUnicode_FromString(self.emitter.problem)
  14552. * return EmitterError(problem)
  14553. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  14554. * raise ValueError("no emitter error")
  14555. * else:
  14556. */
  14557. }
  14558. /* "_yaml.pyx":1014
  14559. * raise ValueError("no emitter error")
  14560. * else:
  14561. * raise ValueError(u"no emitter error") # <<<<<<<<<<<<<<
  14562. *
  14563. * cdef int _object_to_event(self, object event_object, yaml_event_t *event) except 0:
  14564. */
  14565. /*else*/ {
  14566. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__23, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1014, __pyx_L1_error)
  14567. __Pyx_GOTREF(__pyx_t_2);
  14568. __Pyx_Raise(__pyx_t_2, 0, 0, 0);
  14569. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  14570. __PYX_ERR(0, 1014, __pyx_L1_error)
  14571. }
  14572. /* "_yaml.pyx":1002
  14573. * pass
  14574. *
  14575. * cdef object _emitter_error(self): # <<<<<<<<<<<<<<
  14576. * if self.emitter.error == YAML_MEMORY_ERROR:
  14577. * return MemoryError
  14578. */
  14579. /* function exit code */
  14580. __pyx_L1_error:;
  14581. __Pyx_XDECREF(__pyx_t_2);
  14582. __Pyx_XDECREF(__pyx_t_3);
  14583. __Pyx_XDECREF(__pyx_t_4);
  14584. __Pyx_AddTraceback("_yaml.CEmitter._emitter_error", __pyx_clineno, __pyx_lineno, __pyx_filename);
  14585. __pyx_r = 0;
  14586. __pyx_L0:;
  14587. __Pyx_XDECREF(__pyx_v_problem);
  14588. __Pyx_XGIVEREF(__pyx_r);
  14589. __Pyx_RefNannyFinishContext();
  14590. return __pyx_r;
  14591. }
  14592. /* "_yaml.pyx":1016
  14593. * raise ValueError(u"no emitter error")
  14594. *
  14595. * cdef int _object_to_event(self, object event_object, yaml_event_t *event) except 0: # <<<<<<<<<<<<<<
  14596. * cdef yaml_encoding_t encoding
  14597. * cdef yaml_version_directive_t version_directive_value
  14598. */
  14599. static int __pyx_f_5_yaml_8CEmitter__object_to_event(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self, PyObject *__pyx_v_event_object, yaml_event_t *__pyx_v_event) {
  14600. yaml_encoding_t __pyx_v_encoding;
  14601. yaml_version_directive_t __pyx_v_version_directive_value;
  14602. yaml_version_directive_t *__pyx_v_version_directive;
  14603. yaml_tag_directive_t __pyx_v_tag_directives_value[0x80];
  14604. yaml_tag_directive_t *__pyx_v_tag_directives_start;
  14605. yaml_tag_directive_t *__pyx_v_tag_directives_end;
  14606. int __pyx_v_implicit;
  14607. int __pyx_v_plain_implicit;
  14608. int __pyx_v_quoted_implicit;
  14609. char *__pyx_v_anchor;
  14610. char *__pyx_v_tag;
  14611. char *__pyx_v_value;
  14612. int __pyx_v_length;
  14613. yaml_scalar_style_t __pyx_v_scalar_style;
  14614. yaml_sequence_style_t __pyx_v_sequence_style;
  14615. yaml_mapping_style_t __pyx_v_mapping_style;
  14616. PyObject *__pyx_v_event_class = NULL;
  14617. PyObject *__pyx_v_cache = NULL;
  14618. PyObject *__pyx_v_handle = NULL;
  14619. PyObject *__pyx_v_prefix = NULL;
  14620. PyObject *__pyx_v_anchor_object = NULL;
  14621. PyObject *__pyx_v_tag_object = NULL;
  14622. PyObject *__pyx_v_value_object = NULL;
  14623. PyObject *__pyx_v_style_object = NULL;
  14624. int __pyx_r;
  14625. __Pyx_RefNannyDeclarations
  14626. PyObject *__pyx_t_1 = NULL;
  14627. int __pyx_t_2;
  14628. int __pyx_t_3;
  14629. PyObject *__pyx_t_4 = NULL;
  14630. int __pyx_t_5;
  14631. Py_ssize_t __pyx_t_6;
  14632. PyObject *(*__pyx_t_7)(PyObject *);
  14633. PyObject *__pyx_t_8 = NULL;
  14634. int __pyx_t_9;
  14635. __Pyx_RefNannySetupContext("_object_to_event", 0);
  14636. /* "_yaml.pyx":1033
  14637. * cdef yaml_sequence_style_t sequence_style
  14638. * cdef yaml_mapping_style_t mapping_style
  14639. * event_class = event_object.__class__ # <<<<<<<<<<<<<<
  14640. * if event_class is StreamStartEvent:
  14641. * encoding = YAML_UTF8_ENCODING
  14642. */
  14643. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1033, __pyx_L1_error)
  14644. __Pyx_GOTREF(__pyx_t_1);
  14645. __pyx_v_event_class = __pyx_t_1;
  14646. __pyx_t_1 = 0;
  14647. /* "_yaml.pyx":1034
  14648. * cdef yaml_mapping_style_t mapping_style
  14649. * event_class = event_object.__class__
  14650. * if event_class is StreamStartEvent: # <<<<<<<<<<<<<<
  14651. * encoding = YAML_UTF8_ENCODING
  14652. * if event_object.encoding == u'utf-16-le' or event_object.encoding == 'utf-16-le':
  14653. */
  14654. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_StreamStartEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1034, __pyx_L1_error)
  14655. __Pyx_GOTREF(__pyx_t_1);
  14656. __pyx_t_2 = (__pyx_v_event_class == __pyx_t_1);
  14657. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  14658. __pyx_t_3 = (__pyx_t_2 != 0);
  14659. if (__pyx_t_3) {
  14660. /* "_yaml.pyx":1035
  14661. * event_class = event_object.__class__
  14662. * if event_class is StreamStartEvent:
  14663. * encoding = YAML_UTF8_ENCODING # <<<<<<<<<<<<<<
  14664. * if event_object.encoding == u'utf-16-le' or event_object.encoding == 'utf-16-le':
  14665. * encoding = YAML_UTF16LE_ENCODING
  14666. */
  14667. __pyx_v_encoding = YAML_UTF8_ENCODING;
  14668. /* "_yaml.pyx":1036
  14669. * if event_class is StreamStartEvent:
  14670. * encoding = YAML_UTF8_ENCODING
  14671. * if event_object.encoding == u'utf-16-le' or event_object.encoding == 'utf-16-le': # <<<<<<<<<<<<<<
  14672. * encoding = YAML_UTF16LE_ENCODING
  14673. * elif event_object.encoding == u'utf-16-be' or event_object.encoding == 'utf-16-be':
  14674. */
  14675. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_encoding); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1036, __pyx_L1_error)
  14676. __Pyx_GOTREF(__pyx_t_1);
  14677. __pyx_t_2 = (__Pyx_PyUnicode_Equals(__pyx_t_1, __pyx_kp_u_utf_16_le, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 1036, __pyx_L1_error)
  14678. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  14679. if (!__pyx_t_2) {
  14680. } else {
  14681. __pyx_t_3 = __pyx_t_2;
  14682. goto __pyx_L5_bool_binop_done;
  14683. }
  14684. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_encoding); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1036, __pyx_L1_error)
  14685. __Pyx_GOTREF(__pyx_t_1);
  14686. __pyx_t_2 = (__Pyx_PyString_Equals(__pyx_t_1, __pyx_kp_s_utf_16_le, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 1036, __pyx_L1_error)
  14687. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  14688. __pyx_t_3 = __pyx_t_2;
  14689. __pyx_L5_bool_binop_done:;
  14690. if (__pyx_t_3) {
  14691. /* "_yaml.pyx":1037
  14692. * encoding = YAML_UTF8_ENCODING
  14693. * if event_object.encoding == u'utf-16-le' or event_object.encoding == 'utf-16-le':
  14694. * encoding = YAML_UTF16LE_ENCODING # <<<<<<<<<<<<<<
  14695. * elif event_object.encoding == u'utf-16-be' or event_object.encoding == 'utf-16-be':
  14696. * encoding = YAML_UTF16BE_ENCODING
  14697. */
  14698. __pyx_v_encoding = YAML_UTF16LE_ENCODING;
  14699. /* "_yaml.pyx":1036
  14700. * if event_class is StreamStartEvent:
  14701. * encoding = YAML_UTF8_ENCODING
  14702. * if event_object.encoding == u'utf-16-le' or event_object.encoding == 'utf-16-le': # <<<<<<<<<<<<<<
  14703. * encoding = YAML_UTF16LE_ENCODING
  14704. * elif event_object.encoding == u'utf-16-be' or event_object.encoding == 'utf-16-be':
  14705. */
  14706. goto __pyx_L4;
  14707. }
  14708. /* "_yaml.pyx":1038
  14709. * if event_object.encoding == u'utf-16-le' or event_object.encoding == 'utf-16-le':
  14710. * encoding = YAML_UTF16LE_ENCODING
  14711. * elif event_object.encoding == u'utf-16-be' or event_object.encoding == 'utf-16-be': # <<<<<<<<<<<<<<
  14712. * encoding = YAML_UTF16BE_ENCODING
  14713. * if event_object.encoding is None:
  14714. */
  14715. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_encoding); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1038, __pyx_L1_error)
  14716. __Pyx_GOTREF(__pyx_t_1);
  14717. __pyx_t_2 = (__Pyx_PyUnicode_Equals(__pyx_t_1, __pyx_kp_u_utf_16_be, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 1038, __pyx_L1_error)
  14718. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  14719. if (!__pyx_t_2) {
  14720. } else {
  14721. __pyx_t_3 = __pyx_t_2;
  14722. goto __pyx_L7_bool_binop_done;
  14723. }
  14724. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_encoding); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1038, __pyx_L1_error)
  14725. __Pyx_GOTREF(__pyx_t_1);
  14726. __pyx_t_2 = (__Pyx_PyString_Equals(__pyx_t_1, __pyx_kp_s_utf_16_be, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 1038, __pyx_L1_error)
  14727. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  14728. __pyx_t_3 = __pyx_t_2;
  14729. __pyx_L7_bool_binop_done:;
  14730. if (__pyx_t_3) {
  14731. /* "_yaml.pyx":1039
  14732. * encoding = YAML_UTF16LE_ENCODING
  14733. * elif event_object.encoding == u'utf-16-be' or event_object.encoding == 'utf-16-be':
  14734. * encoding = YAML_UTF16BE_ENCODING # <<<<<<<<<<<<<<
  14735. * if event_object.encoding is None:
  14736. * self.dump_unicode = 1
  14737. */
  14738. __pyx_v_encoding = YAML_UTF16BE_ENCODING;
  14739. /* "_yaml.pyx":1038
  14740. * if event_object.encoding == u'utf-16-le' or event_object.encoding == 'utf-16-le':
  14741. * encoding = YAML_UTF16LE_ENCODING
  14742. * elif event_object.encoding == u'utf-16-be' or event_object.encoding == 'utf-16-be': # <<<<<<<<<<<<<<
  14743. * encoding = YAML_UTF16BE_ENCODING
  14744. * if event_object.encoding is None:
  14745. */
  14746. }
  14747. __pyx_L4:;
  14748. /* "_yaml.pyx":1040
  14749. * elif event_object.encoding == u'utf-16-be' or event_object.encoding == 'utf-16-be':
  14750. * encoding = YAML_UTF16BE_ENCODING
  14751. * if event_object.encoding is None: # <<<<<<<<<<<<<<
  14752. * self.dump_unicode = 1
  14753. * if self.dump_unicode == 1:
  14754. */
  14755. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_encoding); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1040, __pyx_L1_error)
  14756. __Pyx_GOTREF(__pyx_t_1);
  14757. __pyx_t_3 = (__pyx_t_1 == Py_None);
  14758. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  14759. __pyx_t_2 = (__pyx_t_3 != 0);
  14760. if (__pyx_t_2) {
  14761. /* "_yaml.pyx":1041
  14762. * encoding = YAML_UTF16BE_ENCODING
  14763. * if event_object.encoding is None:
  14764. * self.dump_unicode = 1 # <<<<<<<<<<<<<<
  14765. * if self.dump_unicode == 1:
  14766. * encoding = YAML_UTF8_ENCODING
  14767. */
  14768. __pyx_v_self->dump_unicode = 1;
  14769. /* "_yaml.pyx":1040
  14770. * elif event_object.encoding == u'utf-16-be' or event_object.encoding == 'utf-16-be':
  14771. * encoding = YAML_UTF16BE_ENCODING
  14772. * if event_object.encoding is None: # <<<<<<<<<<<<<<
  14773. * self.dump_unicode = 1
  14774. * if self.dump_unicode == 1:
  14775. */
  14776. }
  14777. /* "_yaml.pyx":1042
  14778. * if event_object.encoding is None:
  14779. * self.dump_unicode = 1
  14780. * if self.dump_unicode == 1: # <<<<<<<<<<<<<<
  14781. * encoding = YAML_UTF8_ENCODING
  14782. * yaml_stream_start_event_initialize(event, encoding)
  14783. */
  14784. __pyx_t_2 = ((__pyx_v_self->dump_unicode == 1) != 0);
  14785. if (__pyx_t_2) {
  14786. /* "_yaml.pyx":1043
  14787. * self.dump_unicode = 1
  14788. * if self.dump_unicode == 1:
  14789. * encoding = YAML_UTF8_ENCODING # <<<<<<<<<<<<<<
  14790. * yaml_stream_start_event_initialize(event, encoding)
  14791. * elif event_class is StreamEndEvent:
  14792. */
  14793. __pyx_v_encoding = YAML_UTF8_ENCODING;
  14794. /* "_yaml.pyx":1042
  14795. * if event_object.encoding is None:
  14796. * self.dump_unicode = 1
  14797. * if self.dump_unicode == 1: # <<<<<<<<<<<<<<
  14798. * encoding = YAML_UTF8_ENCODING
  14799. * yaml_stream_start_event_initialize(event, encoding)
  14800. */
  14801. }
  14802. /* "_yaml.pyx":1044
  14803. * if self.dump_unicode == 1:
  14804. * encoding = YAML_UTF8_ENCODING
  14805. * yaml_stream_start_event_initialize(event, encoding) # <<<<<<<<<<<<<<
  14806. * elif event_class is StreamEndEvent:
  14807. * yaml_stream_end_event_initialize(event)
  14808. */
  14809. (void)(yaml_stream_start_event_initialize(__pyx_v_event, __pyx_v_encoding));
  14810. /* "_yaml.pyx":1034
  14811. * cdef yaml_mapping_style_t mapping_style
  14812. * event_class = event_object.__class__
  14813. * if event_class is StreamStartEvent: # <<<<<<<<<<<<<<
  14814. * encoding = YAML_UTF8_ENCODING
  14815. * if event_object.encoding == u'utf-16-le' or event_object.encoding == 'utf-16-le':
  14816. */
  14817. goto __pyx_L3;
  14818. }
  14819. /* "_yaml.pyx":1045
  14820. * encoding = YAML_UTF8_ENCODING
  14821. * yaml_stream_start_event_initialize(event, encoding)
  14822. * elif event_class is StreamEndEvent: # <<<<<<<<<<<<<<
  14823. * yaml_stream_end_event_initialize(event)
  14824. * elif event_class is DocumentStartEvent:
  14825. */
  14826. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_StreamEndEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1045, __pyx_L1_error)
  14827. __Pyx_GOTREF(__pyx_t_1);
  14828. __pyx_t_2 = (__pyx_v_event_class == __pyx_t_1);
  14829. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  14830. __pyx_t_3 = (__pyx_t_2 != 0);
  14831. if (__pyx_t_3) {
  14832. /* "_yaml.pyx":1046
  14833. * yaml_stream_start_event_initialize(event, encoding)
  14834. * elif event_class is StreamEndEvent:
  14835. * yaml_stream_end_event_initialize(event) # <<<<<<<<<<<<<<
  14836. * elif event_class is DocumentStartEvent:
  14837. * version_directive = NULL
  14838. */
  14839. (void)(yaml_stream_end_event_initialize(__pyx_v_event));
  14840. /* "_yaml.pyx":1045
  14841. * encoding = YAML_UTF8_ENCODING
  14842. * yaml_stream_start_event_initialize(event, encoding)
  14843. * elif event_class is StreamEndEvent: # <<<<<<<<<<<<<<
  14844. * yaml_stream_end_event_initialize(event)
  14845. * elif event_class is DocumentStartEvent:
  14846. */
  14847. goto __pyx_L3;
  14848. }
  14849. /* "_yaml.pyx":1047
  14850. * elif event_class is StreamEndEvent:
  14851. * yaml_stream_end_event_initialize(event)
  14852. * elif event_class is DocumentStartEvent: # <<<<<<<<<<<<<<
  14853. * version_directive = NULL
  14854. * if event_object.version:
  14855. */
  14856. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_DocumentStartEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1047, __pyx_L1_error)
  14857. __Pyx_GOTREF(__pyx_t_1);
  14858. __pyx_t_3 = (__pyx_v_event_class == __pyx_t_1);
  14859. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  14860. __pyx_t_2 = (__pyx_t_3 != 0);
  14861. if (__pyx_t_2) {
  14862. /* "_yaml.pyx":1048
  14863. * yaml_stream_end_event_initialize(event)
  14864. * elif event_class is DocumentStartEvent:
  14865. * version_directive = NULL # <<<<<<<<<<<<<<
  14866. * if event_object.version:
  14867. * version_directive_value.major = event_object.version[0]
  14868. */
  14869. __pyx_v_version_directive = NULL;
  14870. /* "_yaml.pyx":1049
  14871. * elif event_class is DocumentStartEvent:
  14872. * version_directive = NULL
  14873. * if event_object.version: # <<<<<<<<<<<<<<
  14874. * version_directive_value.major = event_object.version[0]
  14875. * version_directive_value.minor = event_object.version[1]
  14876. */
  14877. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_version); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1049, __pyx_L1_error)
  14878. __Pyx_GOTREF(__pyx_t_1);
  14879. __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 1049, __pyx_L1_error)
  14880. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  14881. if (__pyx_t_2) {
  14882. /* "_yaml.pyx":1050
  14883. * version_directive = NULL
  14884. * if event_object.version:
  14885. * version_directive_value.major = event_object.version[0] # <<<<<<<<<<<<<<
  14886. * version_directive_value.minor = event_object.version[1]
  14887. * version_directive = &version_directive_value
  14888. */
  14889. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_version); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1050, __pyx_L1_error)
  14890. __Pyx_GOTREF(__pyx_t_1);
  14891. __pyx_t_4 = __Pyx_GetItemInt(__pyx_t_1, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1050, __pyx_L1_error)
  14892. __Pyx_GOTREF(__pyx_t_4);
  14893. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  14894. __pyx_t_5 = __Pyx_PyInt_As_int(__pyx_t_4); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 1050, __pyx_L1_error)
  14895. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  14896. __pyx_v_version_directive_value.major = __pyx_t_5;
  14897. /* "_yaml.pyx":1051
  14898. * if event_object.version:
  14899. * version_directive_value.major = event_object.version[0]
  14900. * version_directive_value.minor = event_object.version[1] # <<<<<<<<<<<<<<
  14901. * version_directive = &version_directive_value
  14902. * tag_directives_start = NULL
  14903. */
  14904. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_version); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1051, __pyx_L1_error)
  14905. __Pyx_GOTREF(__pyx_t_4);
  14906. __pyx_t_1 = __Pyx_GetItemInt(__pyx_t_4, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1051, __pyx_L1_error)
  14907. __Pyx_GOTREF(__pyx_t_1);
  14908. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  14909. __pyx_t_5 = __Pyx_PyInt_As_int(__pyx_t_1); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 1051, __pyx_L1_error)
  14910. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  14911. __pyx_v_version_directive_value.minor = __pyx_t_5;
  14912. /* "_yaml.pyx":1052
  14913. * version_directive_value.major = event_object.version[0]
  14914. * version_directive_value.minor = event_object.version[1]
  14915. * version_directive = &version_directive_value # <<<<<<<<<<<<<<
  14916. * tag_directives_start = NULL
  14917. * tag_directives_end = NULL
  14918. */
  14919. __pyx_v_version_directive = (&__pyx_v_version_directive_value);
  14920. /* "_yaml.pyx":1049
  14921. * elif event_class is DocumentStartEvent:
  14922. * version_directive = NULL
  14923. * if event_object.version: # <<<<<<<<<<<<<<
  14924. * version_directive_value.major = event_object.version[0]
  14925. * version_directive_value.minor = event_object.version[1]
  14926. */
  14927. }
  14928. /* "_yaml.pyx":1053
  14929. * version_directive_value.minor = event_object.version[1]
  14930. * version_directive = &version_directive_value
  14931. * tag_directives_start = NULL # <<<<<<<<<<<<<<
  14932. * tag_directives_end = NULL
  14933. * if event_object.tags:
  14934. */
  14935. __pyx_v_tag_directives_start = NULL;
  14936. /* "_yaml.pyx":1054
  14937. * version_directive = &version_directive_value
  14938. * tag_directives_start = NULL
  14939. * tag_directives_end = NULL # <<<<<<<<<<<<<<
  14940. * if event_object.tags:
  14941. * if len(event_object.tags) > 128:
  14942. */
  14943. __pyx_v_tag_directives_end = NULL;
  14944. /* "_yaml.pyx":1055
  14945. * tag_directives_start = NULL
  14946. * tag_directives_end = NULL
  14947. * if event_object.tags: # <<<<<<<<<<<<<<
  14948. * if len(event_object.tags) > 128:
  14949. * if PY_MAJOR_VERSION < 3:
  14950. */
  14951. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_tags); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1055, __pyx_L1_error)
  14952. __Pyx_GOTREF(__pyx_t_1);
  14953. __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 1055, __pyx_L1_error)
  14954. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  14955. if (__pyx_t_2) {
  14956. /* "_yaml.pyx":1056
  14957. * tag_directives_end = NULL
  14958. * if event_object.tags:
  14959. * if len(event_object.tags) > 128: # <<<<<<<<<<<<<<
  14960. * if PY_MAJOR_VERSION < 3:
  14961. * raise ValueError("too many tags")
  14962. */
  14963. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_tags); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1056, __pyx_L1_error)
  14964. __Pyx_GOTREF(__pyx_t_1);
  14965. __pyx_t_6 = PyObject_Length(__pyx_t_1); if (unlikely(__pyx_t_6 == ((Py_ssize_t)-1))) __PYX_ERR(0, 1056, __pyx_L1_error)
  14966. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  14967. __pyx_t_2 = ((__pyx_t_6 > 0x80) != 0);
  14968. if (__pyx_t_2) {
  14969. /* "_yaml.pyx":1057
  14970. * if event_object.tags:
  14971. * if len(event_object.tags) > 128:
  14972. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  14973. * raise ValueError("too many tags")
  14974. * else:
  14975. */
  14976. __pyx_t_2 = ((PY_MAJOR_VERSION < 3) != 0);
  14977. if (unlikely(__pyx_t_2)) {
  14978. /* "_yaml.pyx":1058
  14979. * if len(event_object.tags) > 128:
  14980. * if PY_MAJOR_VERSION < 3:
  14981. * raise ValueError("too many tags") # <<<<<<<<<<<<<<
  14982. * else:
  14983. * raise ValueError(u"too many tags")
  14984. */
  14985. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__24, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1058, __pyx_L1_error)
  14986. __Pyx_GOTREF(__pyx_t_1);
  14987. __Pyx_Raise(__pyx_t_1, 0, 0, 0);
  14988. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  14989. __PYX_ERR(0, 1058, __pyx_L1_error)
  14990. /* "_yaml.pyx":1057
  14991. * if event_object.tags:
  14992. * if len(event_object.tags) > 128:
  14993. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  14994. * raise ValueError("too many tags")
  14995. * else:
  14996. */
  14997. }
  14998. /* "_yaml.pyx":1060
  14999. * raise ValueError("too many tags")
  15000. * else:
  15001. * raise ValueError(u"too many tags") # <<<<<<<<<<<<<<
  15002. * tag_directives_start = tag_directives_value
  15003. * tag_directives_end = tag_directives_value
  15004. */
  15005. /*else*/ {
  15006. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__25, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1060, __pyx_L1_error)
  15007. __Pyx_GOTREF(__pyx_t_1);
  15008. __Pyx_Raise(__pyx_t_1, 0, 0, 0);
  15009. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  15010. __PYX_ERR(0, 1060, __pyx_L1_error)
  15011. }
  15012. /* "_yaml.pyx":1056
  15013. * tag_directives_end = NULL
  15014. * if event_object.tags:
  15015. * if len(event_object.tags) > 128: # <<<<<<<<<<<<<<
  15016. * if PY_MAJOR_VERSION < 3:
  15017. * raise ValueError("too many tags")
  15018. */
  15019. }
  15020. /* "_yaml.pyx":1061
  15021. * else:
  15022. * raise ValueError(u"too many tags")
  15023. * tag_directives_start = tag_directives_value # <<<<<<<<<<<<<<
  15024. * tag_directives_end = tag_directives_value
  15025. * cache = []
  15026. */
  15027. __pyx_v_tag_directives_start = __pyx_v_tag_directives_value;
  15028. /* "_yaml.pyx":1062
  15029. * raise ValueError(u"too many tags")
  15030. * tag_directives_start = tag_directives_value
  15031. * tag_directives_end = tag_directives_value # <<<<<<<<<<<<<<
  15032. * cache = []
  15033. * for handle in event_object.tags:
  15034. */
  15035. __pyx_v_tag_directives_end = __pyx_v_tag_directives_value;
  15036. /* "_yaml.pyx":1063
  15037. * tag_directives_start = tag_directives_value
  15038. * tag_directives_end = tag_directives_value
  15039. * cache = [] # <<<<<<<<<<<<<<
  15040. * for handle in event_object.tags:
  15041. * prefix = event_object.tags[handle]
  15042. */
  15043. __pyx_t_1 = PyList_New(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1063, __pyx_L1_error)
  15044. __Pyx_GOTREF(__pyx_t_1);
  15045. __pyx_v_cache = ((PyObject*)__pyx_t_1);
  15046. __pyx_t_1 = 0;
  15047. /* "_yaml.pyx":1064
  15048. * tag_directives_end = tag_directives_value
  15049. * cache = []
  15050. * for handle in event_object.tags: # <<<<<<<<<<<<<<
  15051. * prefix = event_object.tags[handle]
  15052. * if PyUnicode_CheckExact(handle):
  15053. */
  15054. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_tags); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1064, __pyx_L1_error)
  15055. __Pyx_GOTREF(__pyx_t_1);
  15056. if (likely(PyList_CheckExact(__pyx_t_1)) || PyTuple_CheckExact(__pyx_t_1)) {
  15057. __pyx_t_4 = __pyx_t_1; __Pyx_INCREF(__pyx_t_4); __pyx_t_6 = 0;
  15058. __pyx_t_7 = NULL;
  15059. } else {
  15060. __pyx_t_6 = -1; __pyx_t_4 = PyObject_GetIter(__pyx_t_1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1064, __pyx_L1_error)
  15061. __Pyx_GOTREF(__pyx_t_4);
  15062. __pyx_t_7 = Py_TYPE(__pyx_t_4)->tp_iternext; if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 1064, __pyx_L1_error)
  15063. }
  15064. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  15065. for (;;) {
  15066. if (likely(!__pyx_t_7)) {
  15067. if (likely(PyList_CheckExact(__pyx_t_4))) {
  15068. if (__pyx_t_6 >= PyList_GET_SIZE(__pyx_t_4)) break;
  15069. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  15070. __pyx_t_1 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_6); __Pyx_INCREF(__pyx_t_1); __pyx_t_6++; if (unlikely(0 < 0)) __PYX_ERR(0, 1064, __pyx_L1_error)
  15071. #else
  15072. __pyx_t_1 = PySequence_ITEM(__pyx_t_4, __pyx_t_6); __pyx_t_6++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1064, __pyx_L1_error)
  15073. __Pyx_GOTREF(__pyx_t_1);
  15074. #endif
  15075. } else {
  15076. if (__pyx_t_6 >= PyTuple_GET_SIZE(__pyx_t_4)) break;
  15077. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  15078. __pyx_t_1 = PyTuple_GET_ITEM(__pyx_t_4, __pyx_t_6); __Pyx_INCREF(__pyx_t_1); __pyx_t_6++; if (unlikely(0 < 0)) __PYX_ERR(0, 1064, __pyx_L1_error)
  15079. #else
  15080. __pyx_t_1 = PySequence_ITEM(__pyx_t_4, __pyx_t_6); __pyx_t_6++; if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1064, __pyx_L1_error)
  15081. __Pyx_GOTREF(__pyx_t_1);
  15082. #endif
  15083. }
  15084. } else {
  15085. __pyx_t_1 = __pyx_t_7(__pyx_t_4);
  15086. if (unlikely(!__pyx_t_1)) {
  15087. PyObject* exc_type = PyErr_Occurred();
  15088. if (exc_type) {
  15089. if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
  15090. else __PYX_ERR(0, 1064, __pyx_L1_error)
  15091. }
  15092. break;
  15093. }
  15094. __Pyx_GOTREF(__pyx_t_1);
  15095. }
  15096. __Pyx_XDECREF_SET(__pyx_v_handle, __pyx_t_1);
  15097. __pyx_t_1 = 0;
  15098. /* "_yaml.pyx":1065
  15099. * cache = []
  15100. * for handle in event_object.tags:
  15101. * prefix = event_object.tags[handle] # <<<<<<<<<<<<<<
  15102. * if PyUnicode_CheckExact(handle):
  15103. * handle = PyUnicode_AsUTF8String(handle)
  15104. */
  15105. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_tags); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1065, __pyx_L1_error)
  15106. __Pyx_GOTREF(__pyx_t_1);
  15107. __pyx_t_8 = __Pyx_PyObject_GetItem(__pyx_t_1, __pyx_v_handle); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 1065, __pyx_L1_error)
  15108. __Pyx_GOTREF(__pyx_t_8);
  15109. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  15110. __Pyx_XDECREF_SET(__pyx_v_prefix, __pyx_t_8);
  15111. __pyx_t_8 = 0;
  15112. /* "_yaml.pyx":1066
  15113. * for handle in event_object.tags:
  15114. * prefix = event_object.tags[handle]
  15115. * if PyUnicode_CheckExact(handle): # <<<<<<<<<<<<<<
  15116. * handle = PyUnicode_AsUTF8String(handle)
  15117. * cache.append(handle)
  15118. */
  15119. __pyx_t_2 = (PyUnicode_CheckExact(__pyx_v_handle) != 0);
  15120. if (__pyx_t_2) {
  15121. /* "_yaml.pyx":1067
  15122. * prefix = event_object.tags[handle]
  15123. * if PyUnicode_CheckExact(handle):
  15124. * handle = PyUnicode_AsUTF8String(handle) # <<<<<<<<<<<<<<
  15125. * cache.append(handle)
  15126. * if not PyString_CheckExact(handle):
  15127. */
  15128. __pyx_t_8 = PyUnicode_AsUTF8String(__pyx_v_handle); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 1067, __pyx_L1_error)
  15129. __Pyx_GOTREF(__pyx_t_8);
  15130. __Pyx_DECREF_SET(__pyx_v_handle, __pyx_t_8);
  15131. __pyx_t_8 = 0;
  15132. /* "_yaml.pyx":1068
  15133. * if PyUnicode_CheckExact(handle):
  15134. * handle = PyUnicode_AsUTF8String(handle)
  15135. * cache.append(handle) # <<<<<<<<<<<<<<
  15136. * if not PyString_CheckExact(handle):
  15137. * if PY_MAJOR_VERSION < 3:
  15138. */
  15139. __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_cache, __pyx_v_handle); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 1068, __pyx_L1_error)
  15140. /* "_yaml.pyx":1066
  15141. * for handle in event_object.tags:
  15142. * prefix = event_object.tags[handle]
  15143. * if PyUnicode_CheckExact(handle): # <<<<<<<<<<<<<<
  15144. * handle = PyUnicode_AsUTF8String(handle)
  15145. * cache.append(handle)
  15146. */
  15147. }
  15148. /* "_yaml.pyx":1069
  15149. * handle = PyUnicode_AsUTF8String(handle)
  15150. * cache.append(handle)
  15151. * if not PyString_CheckExact(handle): # <<<<<<<<<<<<<<
  15152. * if PY_MAJOR_VERSION < 3:
  15153. * raise TypeError("tag handle must be a string")
  15154. */
  15155. __pyx_t_2 = ((!(PyString_CheckExact(__pyx_v_handle) != 0)) != 0);
  15156. if (__pyx_t_2) {
  15157. /* "_yaml.pyx":1070
  15158. * cache.append(handle)
  15159. * if not PyString_CheckExact(handle):
  15160. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  15161. * raise TypeError("tag handle must be a string")
  15162. * else:
  15163. */
  15164. __pyx_t_2 = ((PY_MAJOR_VERSION < 3) != 0);
  15165. if (unlikely(__pyx_t_2)) {
  15166. /* "_yaml.pyx":1071
  15167. * if not PyString_CheckExact(handle):
  15168. * if PY_MAJOR_VERSION < 3:
  15169. * raise TypeError("tag handle must be a string") # <<<<<<<<<<<<<<
  15170. * else:
  15171. * raise TypeError(u"tag handle must be a string")
  15172. */
  15173. __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__26, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 1071, __pyx_L1_error)
  15174. __Pyx_GOTREF(__pyx_t_8);
  15175. __Pyx_Raise(__pyx_t_8, 0, 0, 0);
  15176. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  15177. __PYX_ERR(0, 1071, __pyx_L1_error)
  15178. /* "_yaml.pyx":1070
  15179. * cache.append(handle)
  15180. * if not PyString_CheckExact(handle):
  15181. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  15182. * raise TypeError("tag handle must be a string")
  15183. * else:
  15184. */
  15185. }
  15186. /* "_yaml.pyx":1073
  15187. * raise TypeError("tag handle must be a string")
  15188. * else:
  15189. * raise TypeError(u"tag handle must be a string") # <<<<<<<<<<<<<<
  15190. * tag_directives_end.handle = PyString_AS_STRING(handle)
  15191. * if PyUnicode_CheckExact(prefix):
  15192. */
  15193. /*else*/ {
  15194. __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__27, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 1073, __pyx_L1_error)
  15195. __Pyx_GOTREF(__pyx_t_8);
  15196. __Pyx_Raise(__pyx_t_8, 0, 0, 0);
  15197. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  15198. __PYX_ERR(0, 1073, __pyx_L1_error)
  15199. }
  15200. /* "_yaml.pyx":1069
  15201. * handle = PyUnicode_AsUTF8String(handle)
  15202. * cache.append(handle)
  15203. * if not PyString_CheckExact(handle): # <<<<<<<<<<<<<<
  15204. * if PY_MAJOR_VERSION < 3:
  15205. * raise TypeError("tag handle must be a string")
  15206. */
  15207. }
  15208. /* "_yaml.pyx":1074
  15209. * else:
  15210. * raise TypeError(u"tag handle must be a string")
  15211. * tag_directives_end.handle = PyString_AS_STRING(handle) # <<<<<<<<<<<<<<
  15212. * if PyUnicode_CheckExact(prefix):
  15213. * prefix = PyUnicode_AsUTF8String(prefix)
  15214. */
  15215. __pyx_v_tag_directives_end->handle = PyString_AS_STRING(__pyx_v_handle);
  15216. /* "_yaml.pyx":1075
  15217. * raise TypeError(u"tag handle must be a string")
  15218. * tag_directives_end.handle = PyString_AS_STRING(handle)
  15219. * if PyUnicode_CheckExact(prefix): # <<<<<<<<<<<<<<
  15220. * prefix = PyUnicode_AsUTF8String(prefix)
  15221. * cache.append(prefix)
  15222. */
  15223. __pyx_t_2 = (PyUnicode_CheckExact(__pyx_v_prefix) != 0);
  15224. if (__pyx_t_2) {
  15225. /* "_yaml.pyx":1076
  15226. * tag_directives_end.handle = PyString_AS_STRING(handle)
  15227. * if PyUnicode_CheckExact(prefix):
  15228. * prefix = PyUnicode_AsUTF8String(prefix) # <<<<<<<<<<<<<<
  15229. * cache.append(prefix)
  15230. * if not PyString_CheckExact(prefix):
  15231. */
  15232. __pyx_t_8 = PyUnicode_AsUTF8String(__pyx_v_prefix); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 1076, __pyx_L1_error)
  15233. __Pyx_GOTREF(__pyx_t_8);
  15234. __Pyx_DECREF_SET(__pyx_v_prefix, __pyx_t_8);
  15235. __pyx_t_8 = 0;
  15236. /* "_yaml.pyx":1077
  15237. * if PyUnicode_CheckExact(prefix):
  15238. * prefix = PyUnicode_AsUTF8String(prefix)
  15239. * cache.append(prefix) # <<<<<<<<<<<<<<
  15240. * if not PyString_CheckExact(prefix):
  15241. * if PY_MAJOR_VERSION < 3:
  15242. */
  15243. __pyx_t_9 = __Pyx_PyList_Append(__pyx_v_cache, __pyx_v_prefix); if (unlikely(__pyx_t_9 == ((int)-1))) __PYX_ERR(0, 1077, __pyx_L1_error)
  15244. /* "_yaml.pyx":1075
  15245. * raise TypeError(u"tag handle must be a string")
  15246. * tag_directives_end.handle = PyString_AS_STRING(handle)
  15247. * if PyUnicode_CheckExact(prefix): # <<<<<<<<<<<<<<
  15248. * prefix = PyUnicode_AsUTF8String(prefix)
  15249. * cache.append(prefix)
  15250. */
  15251. }
  15252. /* "_yaml.pyx":1078
  15253. * prefix = PyUnicode_AsUTF8String(prefix)
  15254. * cache.append(prefix)
  15255. * if not PyString_CheckExact(prefix): # <<<<<<<<<<<<<<
  15256. * if PY_MAJOR_VERSION < 3:
  15257. * raise TypeError("tag prefix must be a string")
  15258. */
  15259. __pyx_t_2 = ((!(PyString_CheckExact(__pyx_v_prefix) != 0)) != 0);
  15260. if (__pyx_t_2) {
  15261. /* "_yaml.pyx":1079
  15262. * cache.append(prefix)
  15263. * if not PyString_CheckExact(prefix):
  15264. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  15265. * raise TypeError("tag prefix must be a string")
  15266. * else:
  15267. */
  15268. __pyx_t_2 = ((PY_MAJOR_VERSION < 3) != 0);
  15269. if (unlikely(__pyx_t_2)) {
  15270. /* "_yaml.pyx":1080
  15271. * if not PyString_CheckExact(prefix):
  15272. * if PY_MAJOR_VERSION < 3:
  15273. * raise TypeError("tag prefix must be a string") # <<<<<<<<<<<<<<
  15274. * else:
  15275. * raise TypeError(u"tag prefix must be a string")
  15276. */
  15277. __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__28, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 1080, __pyx_L1_error)
  15278. __Pyx_GOTREF(__pyx_t_8);
  15279. __Pyx_Raise(__pyx_t_8, 0, 0, 0);
  15280. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  15281. __PYX_ERR(0, 1080, __pyx_L1_error)
  15282. /* "_yaml.pyx":1079
  15283. * cache.append(prefix)
  15284. * if not PyString_CheckExact(prefix):
  15285. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  15286. * raise TypeError("tag prefix must be a string")
  15287. * else:
  15288. */
  15289. }
  15290. /* "_yaml.pyx":1082
  15291. * raise TypeError("tag prefix must be a string")
  15292. * else:
  15293. * raise TypeError(u"tag prefix must be a string") # <<<<<<<<<<<<<<
  15294. * tag_directives_end.prefix = PyString_AS_STRING(prefix)
  15295. * tag_directives_end = tag_directives_end+1
  15296. */
  15297. /*else*/ {
  15298. __pyx_t_8 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__29, NULL); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 1082, __pyx_L1_error)
  15299. __Pyx_GOTREF(__pyx_t_8);
  15300. __Pyx_Raise(__pyx_t_8, 0, 0, 0);
  15301. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  15302. __PYX_ERR(0, 1082, __pyx_L1_error)
  15303. }
  15304. /* "_yaml.pyx":1078
  15305. * prefix = PyUnicode_AsUTF8String(prefix)
  15306. * cache.append(prefix)
  15307. * if not PyString_CheckExact(prefix): # <<<<<<<<<<<<<<
  15308. * if PY_MAJOR_VERSION < 3:
  15309. * raise TypeError("tag prefix must be a string")
  15310. */
  15311. }
  15312. /* "_yaml.pyx":1083
  15313. * else:
  15314. * raise TypeError(u"tag prefix must be a string")
  15315. * tag_directives_end.prefix = PyString_AS_STRING(prefix) # <<<<<<<<<<<<<<
  15316. * tag_directives_end = tag_directives_end+1
  15317. * implicit = 1
  15318. */
  15319. __pyx_v_tag_directives_end->prefix = PyString_AS_STRING(__pyx_v_prefix);
  15320. /* "_yaml.pyx":1084
  15321. * raise TypeError(u"tag prefix must be a string")
  15322. * tag_directives_end.prefix = PyString_AS_STRING(prefix)
  15323. * tag_directives_end = tag_directives_end+1 # <<<<<<<<<<<<<<
  15324. * implicit = 1
  15325. * if event_object.explicit:
  15326. */
  15327. __pyx_v_tag_directives_end = (__pyx_v_tag_directives_end + 1);
  15328. /* "_yaml.pyx":1064
  15329. * tag_directives_end = tag_directives_value
  15330. * cache = []
  15331. * for handle in event_object.tags: # <<<<<<<<<<<<<<
  15332. * prefix = event_object.tags[handle]
  15333. * if PyUnicode_CheckExact(handle):
  15334. */
  15335. }
  15336. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  15337. /* "_yaml.pyx":1055
  15338. * tag_directives_start = NULL
  15339. * tag_directives_end = NULL
  15340. * if event_object.tags: # <<<<<<<<<<<<<<
  15341. * if len(event_object.tags) > 128:
  15342. * if PY_MAJOR_VERSION < 3:
  15343. */
  15344. }
  15345. /* "_yaml.pyx":1085
  15346. * tag_directives_end.prefix = PyString_AS_STRING(prefix)
  15347. * tag_directives_end = tag_directives_end+1
  15348. * implicit = 1 # <<<<<<<<<<<<<<
  15349. * if event_object.explicit:
  15350. * implicit = 0
  15351. */
  15352. __pyx_v_implicit = 1;
  15353. /* "_yaml.pyx":1086
  15354. * tag_directives_end = tag_directives_end+1
  15355. * implicit = 1
  15356. * if event_object.explicit: # <<<<<<<<<<<<<<
  15357. * implicit = 0
  15358. * if yaml_document_start_event_initialize(event, version_directive,
  15359. */
  15360. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_explicit); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1086, __pyx_L1_error)
  15361. __Pyx_GOTREF(__pyx_t_4);
  15362. __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 1086, __pyx_L1_error)
  15363. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  15364. if (__pyx_t_2) {
  15365. /* "_yaml.pyx":1087
  15366. * implicit = 1
  15367. * if event_object.explicit:
  15368. * implicit = 0 # <<<<<<<<<<<<<<
  15369. * if yaml_document_start_event_initialize(event, version_directive,
  15370. * tag_directives_start, tag_directives_end, implicit) == 0:
  15371. */
  15372. __pyx_v_implicit = 0;
  15373. /* "_yaml.pyx":1086
  15374. * tag_directives_end = tag_directives_end+1
  15375. * implicit = 1
  15376. * if event_object.explicit: # <<<<<<<<<<<<<<
  15377. * implicit = 0
  15378. * if yaml_document_start_event_initialize(event, version_directive,
  15379. */
  15380. }
  15381. /* "_yaml.pyx":1089
  15382. * implicit = 0
  15383. * if yaml_document_start_event_initialize(event, version_directive,
  15384. * tag_directives_start, tag_directives_end, implicit) == 0: # <<<<<<<<<<<<<<
  15385. * raise MemoryError
  15386. * elif event_class is DocumentEndEvent:
  15387. */
  15388. __pyx_t_2 = ((yaml_document_start_event_initialize(__pyx_v_event, __pyx_v_version_directive, __pyx_v_tag_directives_start, __pyx_v_tag_directives_end, __pyx_v_implicit) == 0) != 0);
  15389. /* "_yaml.pyx":1088
  15390. * if event_object.explicit:
  15391. * implicit = 0
  15392. * if yaml_document_start_event_initialize(event, version_directive, # <<<<<<<<<<<<<<
  15393. * tag_directives_start, tag_directives_end, implicit) == 0:
  15394. * raise MemoryError
  15395. */
  15396. if (unlikely(__pyx_t_2)) {
  15397. /* "_yaml.pyx":1090
  15398. * if yaml_document_start_event_initialize(event, version_directive,
  15399. * tag_directives_start, tag_directives_end, implicit) == 0:
  15400. * raise MemoryError # <<<<<<<<<<<<<<
  15401. * elif event_class is DocumentEndEvent:
  15402. * implicit = 1
  15403. */
  15404. PyErr_NoMemory(); __PYX_ERR(0, 1090, __pyx_L1_error)
  15405. /* "_yaml.pyx":1088
  15406. * if event_object.explicit:
  15407. * implicit = 0
  15408. * if yaml_document_start_event_initialize(event, version_directive, # <<<<<<<<<<<<<<
  15409. * tag_directives_start, tag_directives_end, implicit) == 0:
  15410. * raise MemoryError
  15411. */
  15412. }
  15413. /* "_yaml.pyx":1047
  15414. * elif event_class is StreamEndEvent:
  15415. * yaml_stream_end_event_initialize(event)
  15416. * elif event_class is DocumentStartEvent: # <<<<<<<<<<<<<<
  15417. * version_directive = NULL
  15418. * if event_object.version:
  15419. */
  15420. goto __pyx_L3;
  15421. }
  15422. /* "_yaml.pyx":1091
  15423. * tag_directives_start, tag_directives_end, implicit) == 0:
  15424. * raise MemoryError
  15425. * elif event_class is DocumentEndEvent: # <<<<<<<<<<<<<<
  15426. * implicit = 1
  15427. * if event_object.explicit:
  15428. */
  15429. __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_DocumentEndEvent); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1091, __pyx_L1_error)
  15430. __Pyx_GOTREF(__pyx_t_4);
  15431. __pyx_t_2 = (__pyx_v_event_class == __pyx_t_4);
  15432. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  15433. __pyx_t_3 = (__pyx_t_2 != 0);
  15434. if (__pyx_t_3) {
  15435. /* "_yaml.pyx":1092
  15436. * raise MemoryError
  15437. * elif event_class is DocumentEndEvent:
  15438. * implicit = 1 # <<<<<<<<<<<<<<
  15439. * if event_object.explicit:
  15440. * implicit = 0
  15441. */
  15442. __pyx_v_implicit = 1;
  15443. /* "_yaml.pyx":1093
  15444. * elif event_class is DocumentEndEvent:
  15445. * implicit = 1
  15446. * if event_object.explicit: # <<<<<<<<<<<<<<
  15447. * implicit = 0
  15448. * yaml_document_end_event_initialize(event, implicit)
  15449. */
  15450. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_explicit); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1093, __pyx_L1_error)
  15451. __Pyx_GOTREF(__pyx_t_4);
  15452. __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1093, __pyx_L1_error)
  15453. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  15454. if (__pyx_t_3) {
  15455. /* "_yaml.pyx":1094
  15456. * implicit = 1
  15457. * if event_object.explicit:
  15458. * implicit = 0 # <<<<<<<<<<<<<<
  15459. * yaml_document_end_event_initialize(event, implicit)
  15460. * elif event_class is AliasEvent:
  15461. */
  15462. __pyx_v_implicit = 0;
  15463. /* "_yaml.pyx":1093
  15464. * elif event_class is DocumentEndEvent:
  15465. * implicit = 1
  15466. * if event_object.explicit: # <<<<<<<<<<<<<<
  15467. * implicit = 0
  15468. * yaml_document_end_event_initialize(event, implicit)
  15469. */
  15470. }
  15471. /* "_yaml.pyx":1095
  15472. * if event_object.explicit:
  15473. * implicit = 0
  15474. * yaml_document_end_event_initialize(event, implicit) # <<<<<<<<<<<<<<
  15475. * elif event_class is AliasEvent:
  15476. * anchor = NULL
  15477. */
  15478. (void)(yaml_document_end_event_initialize(__pyx_v_event, __pyx_v_implicit));
  15479. /* "_yaml.pyx":1091
  15480. * tag_directives_start, tag_directives_end, implicit) == 0:
  15481. * raise MemoryError
  15482. * elif event_class is DocumentEndEvent: # <<<<<<<<<<<<<<
  15483. * implicit = 1
  15484. * if event_object.explicit:
  15485. */
  15486. goto __pyx_L3;
  15487. }
  15488. /* "_yaml.pyx":1096
  15489. * implicit = 0
  15490. * yaml_document_end_event_initialize(event, implicit)
  15491. * elif event_class is AliasEvent: # <<<<<<<<<<<<<<
  15492. * anchor = NULL
  15493. * anchor_object = event_object.anchor
  15494. */
  15495. __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_AliasEvent); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1096, __pyx_L1_error)
  15496. __Pyx_GOTREF(__pyx_t_4);
  15497. __pyx_t_3 = (__pyx_v_event_class == __pyx_t_4);
  15498. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  15499. __pyx_t_2 = (__pyx_t_3 != 0);
  15500. if (__pyx_t_2) {
  15501. /* "_yaml.pyx":1097
  15502. * yaml_document_end_event_initialize(event, implicit)
  15503. * elif event_class is AliasEvent:
  15504. * anchor = NULL # <<<<<<<<<<<<<<
  15505. * anchor_object = event_object.anchor
  15506. * if PyUnicode_CheckExact(anchor_object):
  15507. */
  15508. __pyx_v_anchor = NULL;
  15509. /* "_yaml.pyx":1098
  15510. * elif event_class is AliasEvent:
  15511. * anchor = NULL
  15512. * anchor_object = event_object.anchor # <<<<<<<<<<<<<<
  15513. * if PyUnicode_CheckExact(anchor_object):
  15514. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  15515. */
  15516. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_anchor); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1098, __pyx_L1_error)
  15517. __Pyx_GOTREF(__pyx_t_4);
  15518. __pyx_v_anchor_object = __pyx_t_4;
  15519. __pyx_t_4 = 0;
  15520. /* "_yaml.pyx":1099
  15521. * anchor = NULL
  15522. * anchor_object = event_object.anchor
  15523. * if PyUnicode_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  15524. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  15525. * if not PyString_CheckExact(anchor_object):
  15526. */
  15527. __pyx_t_2 = (PyUnicode_CheckExact(__pyx_v_anchor_object) != 0);
  15528. if (__pyx_t_2) {
  15529. /* "_yaml.pyx":1100
  15530. * anchor_object = event_object.anchor
  15531. * if PyUnicode_CheckExact(anchor_object):
  15532. * anchor_object = PyUnicode_AsUTF8String(anchor_object) # <<<<<<<<<<<<<<
  15533. * if not PyString_CheckExact(anchor_object):
  15534. * if PY_MAJOR_VERSION < 3:
  15535. */
  15536. __pyx_t_4 = PyUnicode_AsUTF8String(__pyx_v_anchor_object); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1100, __pyx_L1_error)
  15537. __Pyx_GOTREF(__pyx_t_4);
  15538. __Pyx_DECREF_SET(__pyx_v_anchor_object, __pyx_t_4);
  15539. __pyx_t_4 = 0;
  15540. /* "_yaml.pyx":1099
  15541. * anchor = NULL
  15542. * anchor_object = event_object.anchor
  15543. * if PyUnicode_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  15544. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  15545. * if not PyString_CheckExact(anchor_object):
  15546. */
  15547. }
  15548. /* "_yaml.pyx":1101
  15549. * if PyUnicode_CheckExact(anchor_object):
  15550. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  15551. * if not PyString_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  15552. * if PY_MAJOR_VERSION < 3:
  15553. * raise TypeError("anchor must be a string")
  15554. */
  15555. __pyx_t_2 = ((!(PyString_CheckExact(__pyx_v_anchor_object) != 0)) != 0);
  15556. if (__pyx_t_2) {
  15557. /* "_yaml.pyx":1102
  15558. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  15559. * if not PyString_CheckExact(anchor_object):
  15560. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  15561. * raise TypeError("anchor must be a string")
  15562. * else:
  15563. */
  15564. __pyx_t_2 = ((PY_MAJOR_VERSION < 3) != 0);
  15565. if (unlikely(__pyx_t_2)) {
  15566. /* "_yaml.pyx":1103
  15567. * if not PyString_CheckExact(anchor_object):
  15568. * if PY_MAJOR_VERSION < 3:
  15569. * raise TypeError("anchor must be a string") # <<<<<<<<<<<<<<
  15570. * else:
  15571. * raise TypeError(u"anchor must be a string")
  15572. */
  15573. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__30, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1103, __pyx_L1_error)
  15574. __Pyx_GOTREF(__pyx_t_4);
  15575. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  15576. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  15577. __PYX_ERR(0, 1103, __pyx_L1_error)
  15578. /* "_yaml.pyx":1102
  15579. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  15580. * if not PyString_CheckExact(anchor_object):
  15581. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  15582. * raise TypeError("anchor must be a string")
  15583. * else:
  15584. */
  15585. }
  15586. /* "_yaml.pyx":1105
  15587. * raise TypeError("anchor must be a string")
  15588. * else:
  15589. * raise TypeError(u"anchor must be a string") # <<<<<<<<<<<<<<
  15590. * anchor = PyString_AS_STRING(anchor_object)
  15591. * if yaml_alias_event_initialize(event, anchor) == 0:
  15592. */
  15593. /*else*/ {
  15594. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__31, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1105, __pyx_L1_error)
  15595. __Pyx_GOTREF(__pyx_t_4);
  15596. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  15597. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  15598. __PYX_ERR(0, 1105, __pyx_L1_error)
  15599. }
  15600. /* "_yaml.pyx":1101
  15601. * if PyUnicode_CheckExact(anchor_object):
  15602. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  15603. * if not PyString_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  15604. * if PY_MAJOR_VERSION < 3:
  15605. * raise TypeError("anchor must be a string")
  15606. */
  15607. }
  15608. /* "_yaml.pyx":1106
  15609. * else:
  15610. * raise TypeError(u"anchor must be a string")
  15611. * anchor = PyString_AS_STRING(anchor_object) # <<<<<<<<<<<<<<
  15612. * if yaml_alias_event_initialize(event, anchor) == 0:
  15613. * raise MemoryError
  15614. */
  15615. __pyx_v_anchor = PyString_AS_STRING(__pyx_v_anchor_object);
  15616. /* "_yaml.pyx":1107
  15617. * raise TypeError(u"anchor must be a string")
  15618. * anchor = PyString_AS_STRING(anchor_object)
  15619. * if yaml_alias_event_initialize(event, anchor) == 0: # <<<<<<<<<<<<<<
  15620. * raise MemoryError
  15621. * elif event_class is ScalarEvent:
  15622. */
  15623. __pyx_t_2 = ((yaml_alias_event_initialize(__pyx_v_event, __pyx_v_anchor) == 0) != 0);
  15624. if (unlikely(__pyx_t_2)) {
  15625. /* "_yaml.pyx":1108
  15626. * anchor = PyString_AS_STRING(anchor_object)
  15627. * if yaml_alias_event_initialize(event, anchor) == 0:
  15628. * raise MemoryError # <<<<<<<<<<<<<<
  15629. * elif event_class is ScalarEvent:
  15630. * anchor = NULL
  15631. */
  15632. PyErr_NoMemory(); __PYX_ERR(0, 1108, __pyx_L1_error)
  15633. /* "_yaml.pyx":1107
  15634. * raise TypeError(u"anchor must be a string")
  15635. * anchor = PyString_AS_STRING(anchor_object)
  15636. * if yaml_alias_event_initialize(event, anchor) == 0: # <<<<<<<<<<<<<<
  15637. * raise MemoryError
  15638. * elif event_class is ScalarEvent:
  15639. */
  15640. }
  15641. /* "_yaml.pyx":1096
  15642. * implicit = 0
  15643. * yaml_document_end_event_initialize(event, implicit)
  15644. * elif event_class is AliasEvent: # <<<<<<<<<<<<<<
  15645. * anchor = NULL
  15646. * anchor_object = event_object.anchor
  15647. */
  15648. goto __pyx_L3;
  15649. }
  15650. /* "_yaml.pyx":1109
  15651. * if yaml_alias_event_initialize(event, anchor) == 0:
  15652. * raise MemoryError
  15653. * elif event_class is ScalarEvent: # <<<<<<<<<<<<<<
  15654. * anchor = NULL
  15655. * anchor_object = event_object.anchor
  15656. */
  15657. __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_ScalarEvent); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1109, __pyx_L1_error)
  15658. __Pyx_GOTREF(__pyx_t_4);
  15659. __pyx_t_2 = (__pyx_v_event_class == __pyx_t_4);
  15660. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  15661. __pyx_t_3 = (__pyx_t_2 != 0);
  15662. if (__pyx_t_3) {
  15663. /* "_yaml.pyx":1110
  15664. * raise MemoryError
  15665. * elif event_class is ScalarEvent:
  15666. * anchor = NULL # <<<<<<<<<<<<<<
  15667. * anchor_object = event_object.anchor
  15668. * if anchor_object is not None:
  15669. */
  15670. __pyx_v_anchor = NULL;
  15671. /* "_yaml.pyx":1111
  15672. * elif event_class is ScalarEvent:
  15673. * anchor = NULL
  15674. * anchor_object = event_object.anchor # <<<<<<<<<<<<<<
  15675. * if anchor_object is not None:
  15676. * if PyUnicode_CheckExact(anchor_object):
  15677. */
  15678. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_anchor); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1111, __pyx_L1_error)
  15679. __Pyx_GOTREF(__pyx_t_4);
  15680. __pyx_v_anchor_object = __pyx_t_4;
  15681. __pyx_t_4 = 0;
  15682. /* "_yaml.pyx":1112
  15683. * anchor = NULL
  15684. * anchor_object = event_object.anchor
  15685. * if anchor_object is not None: # <<<<<<<<<<<<<<
  15686. * if PyUnicode_CheckExact(anchor_object):
  15687. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  15688. */
  15689. __pyx_t_3 = (__pyx_v_anchor_object != Py_None);
  15690. __pyx_t_2 = (__pyx_t_3 != 0);
  15691. if (__pyx_t_2) {
  15692. /* "_yaml.pyx":1113
  15693. * anchor_object = event_object.anchor
  15694. * if anchor_object is not None:
  15695. * if PyUnicode_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  15696. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  15697. * if not PyString_CheckExact(anchor_object):
  15698. */
  15699. __pyx_t_2 = (PyUnicode_CheckExact(__pyx_v_anchor_object) != 0);
  15700. if (__pyx_t_2) {
  15701. /* "_yaml.pyx":1114
  15702. * if anchor_object is not None:
  15703. * if PyUnicode_CheckExact(anchor_object):
  15704. * anchor_object = PyUnicode_AsUTF8String(anchor_object) # <<<<<<<<<<<<<<
  15705. * if not PyString_CheckExact(anchor_object):
  15706. * if PY_MAJOR_VERSION < 3:
  15707. */
  15708. __pyx_t_4 = PyUnicode_AsUTF8String(__pyx_v_anchor_object); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1114, __pyx_L1_error)
  15709. __Pyx_GOTREF(__pyx_t_4);
  15710. __Pyx_DECREF_SET(__pyx_v_anchor_object, __pyx_t_4);
  15711. __pyx_t_4 = 0;
  15712. /* "_yaml.pyx":1113
  15713. * anchor_object = event_object.anchor
  15714. * if anchor_object is not None:
  15715. * if PyUnicode_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  15716. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  15717. * if not PyString_CheckExact(anchor_object):
  15718. */
  15719. }
  15720. /* "_yaml.pyx":1115
  15721. * if PyUnicode_CheckExact(anchor_object):
  15722. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  15723. * if not PyString_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  15724. * if PY_MAJOR_VERSION < 3:
  15725. * raise TypeError("anchor must be a string")
  15726. */
  15727. __pyx_t_2 = ((!(PyString_CheckExact(__pyx_v_anchor_object) != 0)) != 0);
  15728. if (__pyx_t_2) {
  15729. /* "_yaml.pyx":1116
  15730. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  15731. * if not PyString_CheckExact(anchor_object):
  15732. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  15733. * raise TypeError("anchor must be a string")
  15734. * else:
  15735. */
  15736. __pyx_t_2 = ((PY_MAJOR_VERSION < 3) != 0);
  15737. if (unlikely(__pyx_t_2)) {
  15738. /* "_yaml.pyx":1117
  15739. * if not PyString_CheckExact(anchor_object):
  15740. * if PY_MAJOR_VERSION < 3:
  15741. * raise TypeError("anchor must be a string") # <<<<<<<<<<<<<<
  15742. * else:
  15743. * raise TypeError(u"anchor must be a string")
  15744. */
  15745. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__30, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1117, __pyx_L1_error)
  15746. __Pyx_GOTREF(__pyx_t_4);
  15747. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  15748. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  15749. __PYX_ERR(0, 1117, __pyx_L1_error)
  15750. /* "_yaml.pyx":1116
  15751. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  15752. * if not PyString_CheckExact(anchor_object):
  15753. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  15754. * raise TypeError("anchor must be a string")
  15755. * else:
  15756. */
  15757. }
  15758. /* "_yaml.pyx":1119
  15759. * raise TypeError("anchor must be a string")
  15760. * else:
  15761. * raise TypeError(u"anchor must be a string") # <<<<<<<<<<<<<<
  15762. * anchor = PyString_AS_STRING(anchor_object)
  15763. * tag = NULL
  15764. */
  15765. /*else*/ {
  15766. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__31, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1119, __pyx_L1_error)
  15767. __Pyx_GOTREF(__pyx_t_4);
  15768. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  15769. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  15770. __PYX_ERR(0, 1119, __pyx_L1_error)
  15771. }
  15772. /* "_yaml.pyx":1115
  15773. * if PyUnicode_CheckExact(anchor_object):
  15774. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  15775. * if not PyString_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  15776. * if PY_MAJOR_VERSION < 3:
  15777. * raise TypeError("anchor must be a string")
  15778. */
  15779. }
  15780. /* "_yaml.pyx":1120
  15781. * else:
  15782. * raise TypeError(u"anchor must be a string")
  15783. * anchor = PyString_AS_STRING(anchor_object) # <<<<<<<<<<<<<<
  15784. * tag = NULL
  15785. * tag_object = event_object.tag
  15786. */
  15787. __pyx_v_anchor = PyString_AS_STRING(__pyx_v_anchor_object);
  15788. /* "_yaml.pyx":1112
  15789. * anchor = NULL
  15790. * anchor_object = event_object.anchor
  15791. * if anchor_object is not None: # <<<<<<<<<<<<<<
  15792. * if PyUnicode_CheckExact(anchor_object):
  15793. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  15794. */
  15795. }
  15796. /* "_yaml.pyx":1121
  15797. * raise TypeError(u"anchor must be a string")
  15798. * anchor = PyString_AS_STRING(anchor_object)
  15799. * tag = NULL # <<<<<<<<<<<<<<
  15800. * tag_object = event_object.tag
  15801. * if tag_object is not None:
  15802. */
  15803. __pyx_v_tag = NULL;
  15804. /* "_yaml.pyx":1122
  15805. * anchor = PyString_AS_STRING(anchor_object)
  15806. * tag = NULL
  15807. * tag_object = event_object.tag # <<<<<<<<<<<<<<
  15808. * if tag_object is not None:
  15809. * if PyUnicode_CheckExact(tag_object):
  15810. */
  15811. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_tag); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1122, __pyx_L1_error)
  15812. __Pyx_GOTREF(__pyx_t_4);
  15813. __pyx_v_tag_object = __pyx_t_4;
  15814. __pyx_t_4 = 0;
  15815. /* "_yaml.pyx":1123
  15816. * tag = NULL
  15817. * tag_object = event_object.tag
  15818. * if tag_object is not None: # <<<<<<<<<<<<<<
  15819. * if PyUnicode_CheckExact(tag_object):
  15820. * tag_object = PyUnicode_AsUTF8String(tag_object)
  15821. */
  15822. __pyx_t_2 = (__pyx_v_tag_object != Py_None);
  15823. __pyx_t_3 = (__pyx_t_2 != 0);
  15824. if (__pyx_t_3) {
  15825. /* "_yaml.pyx":1124
  15826. * tag_object = event_object.tag
  15827. * if tag_object is not None:
  15828. * if PyUnicode_CheckExact(tag_object): # <<<<<<<<<<<<<<
  15829. * tag_object = PyUnicode_AsUTF8String(tag_object)
  15830. * if not PyString_CheckExact(tag_object):
  15831. */
  15832. __pyx_t_3 = (PyUnicode_CheckExact(__pyx_v_tag_object) != 0);
  15833. if (__pyx_t_3) {
  15834. /* "_yaml.pyx":1125
  15835. * if tag_object is not None:
  15836. * if PyUnicode_CheckExact(tag_object):
  15837. * tag_object = PyUnicode_AsUTF8String(tag_object) # <<<<<<<<<<<<<<
  15838. * if not PyString_CheckExact(tag_object):
  15839. * if PY_MAJOR_VERSION < 3:
  15840. */
  15841. __pyx_t_4 = PyUnicode_AsUTF8String(__pyx_v_tag_object); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1125, __pyx_L1_error)
  15842. __Pyx_GOTREF(__pyx_t_4);
  15843. __Pyx_DECREF_SET(__pyx_v_tag_object, __pyx_t_4);
  15844. __pyx_t_4 = 0;
  15845. /* "_yaml.pyx":1124
  15846. * tag_object = event_object.tag
  15847. * if tag_object is not None:
  15848. * if PyUnicode_CheckExact(tag_object): # <<<<<<<<<<<<<<
  15849. * tag_object = PyUnicode_AsUTF8String(tag_object)
  15850. * if not PyString_CheckExact(tag_object):
  15851. */
  15852. }
  15853. /* "_yaml.pyx":1126
  15854. * if PyUnicode_CheckExact(tag_object):
  15855. * tag_object = PyUnicode_AsUTF8String(tag_object)
  15856. * if not PyString_CheckExact(tag_object): # <<<<<<<<<<<<<<
  15857. * if PY_MAJOR_VERSION < 3:
  15858. * raise TypeError("tag must be a string")
  15859. */
  15860. __pyx_t_3 = ((!(PyString_CheckExact(__pyx_v_tag_object) != 0)) != 0);
  15861. if (__pyx_t_3) {
  15862. /* "_yaml.pyx":1127
  15863. * tag_object = PyUnicode_AsUTF8String(tag_object)
  15864. * if not PyString_CheckExact(tag_object):
  15865. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  15866. * raise TypeError("tag must be a string")
  15867. * else:
  15868. */
  15869. __pyx_t_3 = ((PY_MAJOR_VERSION < 3) != 0);
  15870. if (unlikely(__pyx_t_3)) {
  15871. /* "_yaml.pyx":1128
  15872. * if not PyString_CheckExact(tag_object):
  15873. * if PY_MAJOR_VERSION < 3:
  15874. * raise TypeError("tag must be a string") # <<<<<<<<<<<<<<
  15875. * else:
  15876. * raise TypeError(u"tag must be a string")
  15877. */
  15878. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__32, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1128, __pyx_L1_error)
  15879. __Pyx_GOTREF(__pyx_t_4);
  15880. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  15881. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  15882. __PYX_ERR(0, 1128, __pyx_L1_error)
  15883. /* "_yaml.pyx":1127
  15884. * tag_object = PyUnicode_AsUTF8String(tag_object)
  15885. * if not PyString_CheckExact(tag_object):
  15886. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  15887. * raise TypeError("tag must be a string")
  15888. * else:
  15889. */
  15890. }
  15891. /* "_yaml.pyx":1130
  15892. * raise TypeError("tag must be a string")
  15893. * else:
  15894. * raise TypeError(u"tag must be a string") # <<<<<<<<<<<<<<
  15895. * tag = PyString_AS_STRING(tag_object)
  15896. * value_object = event_object.value
  15897. */
  15898. /*else*/ {
  15899. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__33, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1130, __pyx_L1_error)
  15900. __Pyx_GOTREF(__pyx_t_4);
  15901. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  15902. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  15903. __PYX_ERR(0, 1130, __pyx_L1_error)
  15904. }
  15905. /* "_yaml.pyx":1126
  15906. * if PyUnicode_CheckExact(tag_object):
  15907. * tag_object = PyUnicode_AsUTF8String(tag_object)
  15908. * if not PyString_CheckExact(tag_object): # <<<<<<<<<<<<<<
  15909. * if PY_MAJOR_VERSION < 3:
  15910. * raise TypeError("tag must be a string")
  15911. */
  15912. }
  15913. /* "_yaml.pyx":1131
  15914. * else:
  15915. * raise TypeError(u"tag must be a string")
  15916. * tag = PyString_AS_STRING(tag_object) # <<<<<<<<<<<<<<
  15917. * value_object = event_object.value
  15918. * if PyUnicode_CheckExact(value_object):
  15919. */
  15920. __pyx_v_tag = PyString_AS_STRING(__pyx_v_tag_object);
  15921. /* "_yaml.pyx":1123
  15922. * tag = NULL
  15923. * tag_object = event_object.tag
  15924. * if tag_object is not None: # <<<<<<<<<<<<<<
  15925. * if PyUnicode_CheckExact(tag_object):
  15926. * tag_object = PyUnicode_AsUTF8String(tag_object)
  15927. */
  15928. }
  15929. /* "_yaml.pyx":1132
  15930. * raise TypeError(u"tag must be a string")
  15931. * tag = PyString_AS_STRING(tag_object)
  15932. * value_object = event_object.value # <<<<<<<<<<<<<<
  15933. * if PyUnicode_CheckExact(value_object):
  15934. * value_object = PyUnicode_AsUTF8String(value_object)
  15935. */
  15936. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_value); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1132, __pyx_L1_error)
  15937. __Pyx_GOTREF(__pyx_t_4);
  15938. __pyx_v_value_object = __pyx_t_4;
  15939. __pyx_t_4 = 0;
  15940. /* "_yaml.pyx":1133
  15941. * tag = PyString_AS_STRING(tag_object)
  15942. * value_object = event_object.value
  15943. * if PyUnicode_CheckExact(value_object): # <<<<<<<<<<<<<<
  15944. * value_object = PyUnicode_AsUTF8String(value_object)
  15945. * if not PyString_CheckExact(value_object):
  15946. */
  15947. __pyx_t_3 = (PyUnicode_CheckExact(__pyx_v_value_object) != 0);
  15948. if (__pyx_t_3) {
  15949. /* "_yaml.pyx":1134
  15950. * value_object = event_object.value
  15951. * if PyUnicode_CheckExact(value_object):
  15952. * value_object = PyUnicode_AsUTF8String(value_object) # <<<<<<<<<<<<<<
  15953. * if not PyString_CheckExact(value_object):
  15954. * if PY_MAJOR_VERSION < 3:
  15955. */
  15956. __pyx_t_4 = PyUnicode_AsUTF8String(__pyx_v_value_object); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1134, __pyx_L1_error)
  15957. __Pyx_GOTREF(__pyx_t_4);
  15958. __Pyx_DECREF_SET(__pyx_v_value_object, __pyx_t_4);
  15959. __pyx_t_4 = 0;
  15960. /* "_yaml.pyx":1133
  15961. * tag = PyString_AS_STRING(tag_object)
  15962. * value_object = event_object.value
  15963. * if PyUnicode_CheckExact(value_object): # <<<<<<<<<<<<<<
  15964. * value_object = PyUnicode_AsUTF8String(value_object)
  15965. * if not PyString_CheckExact(value_object):
  15966. */
  15967. }
  15968. /* "_yaml.pyx":1135
  15969. * if PyUnicode_CheckExact(value_object):
  15970. * value_object = PyUnicode_AsUTF8String(value_object)
  15971. * if not PyString_CheckExact(value_object): # <<<<<<<<<<<<<<
  15972. * if PY_MAJOR_VERSION < 3:
  15973. * raise TypeError("value must be a string")
  15974. */
  15975. __pyx_t_3 = ((!(PyString_CheckExact(__pyx_v_value_object) != 0)) != 0);
  15976. if (__pyx_t_3) {
  15977. /* "_yaml.pyx":1136
  15978. * value_object = PyUnicode_AsUTF8String(value_object)
  15979. * if not PyString_CheckExact(value_object):
  15980. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  15981. * raise TypeError("value must be a string")
  15982. * else:
  15983. */
  15984. __pyx_t_3 = ((PY_MAJOR_VERSION < 3) != 0);
  15985. if (unlikely(__pyx_t_3)) {
  15986. /* "_yaml.pyx":1137
  15987. * if not PyString_CheckExact(value_object):
  15988. * if PY_MAJOR_VERSION < 3:
  15989. * raise TypeError("value must be a string") # <<<<<<<<<<<<<<
  15990. * else:
  15991. * raise TypeError(u"value must be a string")
  15992. */
  15993. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__34, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1137, __pyx_L1_error)
  15994. __Pyx_GOTREF(__pyx_t_4);
  15995. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  15996. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  15997. __PYX_ERR(0, 1137, __pyx_L1_error)
  15998. /* "_yaml.pyx":1136
  15999. * value_object = PyUnicode_AsUTF8String(value_object)
  16000. * if not PyString_CheckExact(value_object):
  16001. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  16002. * raise TypeError("value must be a string")
  16003. * else:
  16004. */
  16005. }
  16006. /* "_yaml.pyx":1139
  16007. * raise TypeError("value must be a string")
  16008. * else:
  16009. * raise TypeError(u"value must be a string") # <<<<<<<<<<<<<<
  16010. * value = PyString_AS_STRING(value_object)
  16011. * length = PyString_GET_SIZE(value_object)
  16012. */
  16013. /*else*/ {
  16014. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__35, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1139, __pyx_L1_error)
  16015. __Pyx_GOTREF(__pyx_t_4);
  16016. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  16017. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16018. __PYX_ERR(0, 1139, __pyx_L1_error)
  16019. }
  16020. /* "_yaml.pyx":1135
  16021. * if PyUnicode_CheckExact(value_object):
  16022. * value_object = PyUnicode_AsUTF8String(value_object)
  16023. * if not PyString_CheckExact(value_object): # <<<<<<<<<<<<<<
  16024. * if PY_MAJOR_VERSION < 3:
  16025. * raise TypeError("value must be a string")
  16026. */
  16027. }
  16028. /* "_yaml.pyx":1140
  16029. * else:
  16030. * raise TypeError(u"value must be a string")
  16031. * value = PyString_AS_STRING(value_object) # <<<<<<<<<<<<<<
  16032. * length = PyString_GET_SIZE(value_object)
  16033. * plain_implicit = 0
  16034. */
  16035. __pyx_v_value = PyString_AS_STRING(__pyx_v_value_object);
  16036. /* "_yaml.pyx":1141
  16037. * raise TypeError(u"value must be a string")
  16038. * value = PyString_AS_STRING(value_object)
  16039. * length = PyString_GET_SIZE(value_object) # <<<<<<<<<<<<<<
  16040. * plain_implicit = 0
  16041. * quoted_implicit = 0
  16042. */
  16043. __pyx_v_length = PyString_GET_SIZE(__pyx_v_value_object);
  16044. /* "_yaml.pyx":1142
  16045. * value = PyString_AS_STRING(value_object)
  16046. * length = PyString_GET_SIZE(value_object)
  16047. * plain_implicit = 0 # <<<<<<<<<<<<<<
  16048. * quoted_implicit = 0
  16049. * if event_object.implicit is not None:
  16050. */
  16051. __pyx_v_plain_implicit = 0;
  16052. /* "_yaml.pyx":1143
  16053. * length = PyString_GET_SIZE(value_object)
  16054. * plain_implicit = 0
  16055. * quoted_implicit = 0 # <<<<<<<<<<<<<<
  16056. * if event_object.implicit is not None:
  16057. * plain_implicit = event_object.implicit[0]
  16058. */
  16059. __pyx_v_quoted_implicit = 0;
  16060. /* "_yaml.pyx":1144
  16061. * plain_implicit = 0
  16062. * quoted_implicit = 0
  16063. * if event_object.implicit is not None: # <<<<<<<<<<<<<<
  16064. * plain_implicit = event_object.implicit[0]
  16065. * quoted_implicit = event_object.implicit[1]
  16066. */
  16067. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_implicit); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1144, __pyx_L1_error)
  16068. __Pyx_GOTREF(__pyx_t_4);
  16069. __pyx_t_3 = (__pyx_t_4 != Py_None);
  16070. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16071. __pyx_t_2 = (__pyx_t_3 != 0);
  16072. if (__pyx_t_2) {
  16073. /* "_yaml.pyx":1145
  16074. * quoted_implicit = 0
  16075. * if event_object.implicit is not None:
  16076. * plain_implicit = event_object.implicit[0] # <<<<<<<<<<<<<<
  16077. * quoted_implicit = event_object.implicit[1]
  16078. * style_object = event_object.style
  16079. */
  16080. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_implicit); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1145, __pyx_L1_error)
  16081. __Pyx_GOTREF(__pyx_t_4);
  16082. __pyx_t_8 = __Pyx_GetItemInt(__pyx_t_4, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 1145, __pyx_L1_error)
  16083. __Pyx_GOTREF(__pyx_t_8);
  16084. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16085. __pyx_t_5 = __Pyx_PyInt_As_int(__pyx_t_8); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 1145, __pyx_L1_error)
  16086. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  16087. __pyx_v_plain_implicit = __pyx_t_5;
  16088. /* "_yaml.pyx":1146
  16089. * if event_object.implicit is not None:
  16090. * plain_implicit = event_object.implicit[0]
  16091. * quoted_implicit = event_object.implicit[1] # <<<<<<<<<<<<<<
  16092. * style_object = event_object.style
  16093. * scalar_style = YAML_PLAIN_SCALAR_STYLE
  16094. */
  16095. __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_implicit); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 1146, __pyx_L1_error)
  16096. __Pyx_GOTREF(__pyx_t_8);
  16097. __pyx_t_4 = __Pyx_GetItemInt(__pyx_t_8, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1146, __pyx_L1_error)
  16098. __Pyx_GOTREF(__pyx_t_4);
  16099. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  16100. __pyx_t_5 = __Pyx_PyInt_As_int(__pyx_t_4); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 1146, __pyx_L1_error)
  16101. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16102. __pyx_v_quoted_implicit = __pyx_t_5;
  16103. /* "_yaml.pyx":1144
  16104. * plain_implicit = 0
  16105. * quoted_implicit = 0
  16106. * if event_object.implicit is not None: # <<<<<<<<<<<<<<
  16107. * plain_implicit = event_object.implicit[0]
  16108. * quoted_implicit = event_object.implicit[1]
  16109. */
  16110. }
  16111. /* "_yaml.pyx":1147
  16112. * plain_implicit = event_object.implicit[0]
  16113. * quoted_implicit = event_object.implicit[1]
  16114. * style_object = event_object.style # <<<<<<<<<<<<<<
  16115. * scalar_style = YAML_PLAIN_SCALAR_STYLE
  16116. * if style_object == "'" or style_object == u"'":
  16117. */
  16118. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_style); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1147, __pyx_L1_error)
  16119. __Pyx_GOTREF(__pyx_t_4);
  16120. __pyx_v_style_object = __pyx_t_4;
  16121. __pyx_t_4 = 0;
  16122. /* "_yaml.pyx":1148
  16123. * quoted_implicit = event_object.implicit[1]
  16124. * style_object = event_object.style
  16125. * scalar_style = YAML_PLAIN_SCALAR_STYLE # <<<<<<<<<<<<<<
  16126. * if style_object == "'" or style_object == u"'":
  16127. * scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE
  16128. */
  16129. __pyx_v_scalar_style = YAML_PLAIN_SCALAR_STYLE;
  16130. /* "_yaml.pyx":1149
  16131. * style_object = event_object.style
  16132. * scalar_style = YAML_PLAIN_SCALAR_STYLE
  16133. * if style_object == "'" or style_object == u"'": # <<<<<<<<<<<<<<
  16134. * scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE
  16135. * elif style_object == "\"" or style_object == u"\"":
  16136. */
  16137. __pyx_t_3 = (__Pyx_PyString_Equals(__pyx_v_style_object, __pyx_kp_s__7, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1149, __pyx_L1_error)
  16138. if (!__pyx_t_3) {
  16139. } else {
  16140. __pyx_t_2 = __pyx_t_3;
  16141. goto __pyx_L43_bool_binop_done;
  16142. }
  16143. __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_style_object, __pyx_kp_u__7, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1149, __pyx_L1_error)
  16144. __pyx_t_2 = __pyx_t_3;
  16145. __pyx_L43_bool_binop_done:;
  16146. if (__pyx_t_2) {
  16147. /* "_yaml.pyx":1150
  16148. * scalar_style = YAML_PLAIN_SCALAR_STYLE
  16149. * if style_object == "'" or style_object == u"'":
  16150. * scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE # <<<<<<<<<<<<<<
  16151. * elif style_object == "\"" or style_object == u"\"":
  16152. * scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE
  16153. */
  16154. __pyx_v_scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE;
  16155. /* "_yaml.pyx":1149
  16156. * style_object = event_object.style
  16157. * scalar_style = YAML_PLAIN_SCALAR_STYLE
  16158. * if style_object == "'" or style_object == u"'": # <<<<<<<<<<<<<<
  16159. * scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE
  16160. * elif style_object == "\"" or style_object == u"\"":
  16161. */
  16162. goto __pyx_L42;
  16163. }
  16164. /* "_yaml.pyx":1151
  16165. * if style_object == "'" or style_object == u"'":
  16166. * scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE
  16167. * elif style_object == "\"" or style_object == u"\"": # <<<<<<<<<<<<<<
  16168. * scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE
  16169. * elif style_object == "|" or style_object == u"|":
  16170. */
  16171. __pyx_t_3 = (__Pyx_PyString_Equals(__pyx_v_style_object, __pyx_kp_s__8, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1151, __pyx_L1_error)
  16172. if (!__pyx_t_3) {
  16173. } else {
  16174. __pyx_t_2 = __pyx_t_3;
  16175. goto __pyx_L45_bool_binop_done;
  16176. }
  16177. __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_style_object, __pyx_kp_u__8, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1151, __pyx_L1_error)
  16178. __pyx_t_2 = __pyx_t_3;
  16179. __pyx_L45_bool_binop_done:;
  16180. if (__pyx_t_2) {
  16181. /* "_yaml.pyx":1152
  16182. * scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE
  16183. * elif style_object == "\"" or style_object == u"\"":
  16184. * scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE # <<<<<<<<<<<<<<
  16185. * elif style_object == "|" or style_object == u"|":
  16186. * scalar_style = YAML_LITERAL_SCALAR_STYLE
  16187. */
  16188. __pyx_v_scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE;
  16189. /* "_yaml.pyx":1151
  16190. * if style_object == "'" or style_object == u"'":
  16191. * scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE
  16192. * elif style_object == "\"" or style_object == u"\"": # <<<<<<<<<<<<<<
  16193. * scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE
  16194. * elif style_object == "|" or style_object == u"|":
  16195. */
  16196. goto __pyx_L42;
  16197. }
  16198. /* "_yaml.pyx":1153
  16199. * elif style_object == "\"" or style_object == u"\"":
  16200. * scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE
  16201. * elif style_object == "|" or style_object == u"|": # <<<<<<<<<<<<<<
  16202. * scalar_style = YAML_LITERAL_SCALAR_STYLE
  16203. * elif style_object == ">" or style_object == u">":
  16204. */
  16205. __pyx_t_3 = (__Pyx_PyString_Equals(__pyx_v_style_object, __pyx_kp_s__9, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1153, __pyx_L1_error)
  16206. if (!__pyx_t_3) {
  16207. } else {
  16208. __pyx_t_2 = __pyx_t_3;
  16209. goto __pyx_L47_bool_binop_done;
  16210. }
  16211. __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_style_object, __pyx_kp_u__9, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1153, __pyx_L1_error)
  16212. __pyx_t_2 = __pyx_t_3;
  16213. __pyx_L47_bool_binop_done:;
  16214. if (__pyx_t_2) {
  16215. /* "_yaml.pyx":1154
  16216. * scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE
  16217. * elif style_object == "|" or style_object == u"|":
  16218. * scalar_style = YAML_LITERAL_SCALAR_STYLE # <<<<<<<<<<<<<<
  16219. * elif style_object == ">" or style_object == u">":
  16220. * scalar_style = YAML_FOLDED_SCALAR_STYLE
  16221. */
  16222. __pyx_v_scalar_style = YAML_LITERAL_SCALAR_STYLE;
  16223. /* "_yaml.pyx":1153
  16224. * elif style_object == "\"" or style_object == u"\"":
  16225. * scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE
  16226. * elif style_object == "|" or style_object == u"|": # <<<<<<<<<<<<<<
  16227. * scalar_style = YAML_LITERAL_SCALAR_STYLE
  16228. * elif style_object == ">" or style_object == u">":
  16229. */
  16230. goto __pyx_L42;
  16231. }
  16232. /* "_yaml.pyx":1155
  16233. * elif style_object == "|" or style_object == u"|":
  16234. * scalar_style = YAML_LITERAL_SCALAR_STYLE
  16235. * elif style_object == ">" or style_object == u">": # <<<<<<<<<<<<<<
  16236. * scalar_style = YAML_FOLDED_SCALAR_STYLE
  16237. * if yaml_scalar_event_initialize(event, anchor, tag, value, length,
  16238. */
  16239. __pyx_t_3 = (__Pyx_PyString_Equals(__pyx_v_style_object, __pyx_kp_s__10, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1155, __pyx_L1_error)
  16240. if (!__pyx_t_3) {
  16241. } else {
  16242. __pyx_t_2 = __pyx_t_3;
  16243. goto __pyx_L49_bool_binop_done;
  16244. }
  16245. __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_style_object, __pyx_kp_u__10, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1155, __pyx_L1_error)
  16246. __pyx_t_2 = __pyx_t_3;
  16247. __pyx_L49_bool_binop_done:;
  16248. if (__pyx_t_2) {
  16249. /* "_yaml.pyx":1156
  16250. * scalar_style = YAML_LITERAL_SCALAR_STYLE
  16251. * elif style_object == ">" or style_object == u">":
  16252. * scalar_style = YAML_FOLDED_SCALAR_STYLE # <<<<<<<<<<<<<<
  16253. * if yaml_scalar_event_initialize(event, anchor, tag, value, length,
  16254. * plain_implicit, quoted_implicit, scalar_style) == 0:
  16255. */
  16256. __pyx_v_scalar_style = YAML_FOLDED_SCALAR_STYLE;
  16257. /* "_yaml.pyx":1155
  16258. * elif style_object == "|" or style_object == u"|":
  16259. * scalar_style = YAML_LITERAL_SCALAR_STYLE
  16260. * elif style_object == ">" or style_object == u">": # <<<<<<<<<<<<<<
  16261. * scalar_style = YAML_FOLDED_SCALAR_STYLE
  16262. * if yaml_scalar_event_initialize(event, anchor, tag, value, length,
  16263. */
  16264. }
  16265. __pyx_L42:;
  16266. /* "_yaml.pyx":1158
  16267. * scalar_style = YAML_FOLDED_SCALAR_STYLE
  16268. * if yaml_scalar_event_initialize(event, anchor, tag, value, length,
  16269. * plain_implicit, quoted_implicit, scalar_style) == 0: # <<<<<<<<<<<<<<
  16270. * raise MemoryError
  16271. * elif event_class is SequenceStartEvent:
  16272. */
  16273. __pyx_t_2 = ((yaml_scalar_event_initialize(__pyx_v_event, __pyx_v_anchor, __pyx_v_tag, __pyx_v_value, __pyx_v_length, __pyx_v_plain_implicit, __pyx_v_quoted_implicit, __pyx_v_scalar_style) == 0) != 0);
  16274. /* "_yaml.pyx":1157
  16275. * elif style_object == ">" or style_object == u">":
  16276. * scalar_style = YAML_FOLDED_SCALAR_STYLE
  16277. * if yaml_scalar_event_initialize(event, anchor, tag, value, length, # <<<<<<<<<<<<<<
  16278. * plain_implicit, quoted_implicit, scalar_style) == 0:
  16279. * raise MemoryError
  16280. */
  16281. if (unlikely(__pyx_t_2)) {
  16282. /* "_yaml.pyx":1159
  16283. * if yaml_scalar_event_initialize(event, anchor, tag, value, length,
  16284. * plain_implicit, quoted_implicit, scalar_style) == 0:
  16285. * raise MemoryError # <<<<<<<<<<<<<<
  16286. * elif event_class is SequenceStartEvent:
  16287. * anchor = NULL
  16288. */
  16289. PyErr_NoMemory(); __PYX_ERR(0, 1159, __pyx_L1_error)
  16290. /* "_yaml.pyx":1157
  16291. * elif style_object == ">" or style_object == u">":
  16292. * scalar_style = YAML_FOLDED_SCALAR_STYLE
  16293. * if yaml_scalar_event_initialize(event, anchor, tag, value, length, # <<<<<<<<<<<<<<
  16294. * plain_implicit, quoted_implicit, scalar_style) == 0:
  16295. * raise MemoryError
  16296. */
  16297. }
  16298. /* "_yaml.pyx":1109
  16299. * if yaml_alias_event_initialize(event, anchor) == 0:
  16300. * raise MemoryError
  16301. * elif event_class is ScalarEvent: # <<<<<<<<<<<<<<
  16302. * anchor = NULL
  16303. * anchor_object = event_object.anchor
  16304. */
  16305. goto __pyx_L3;
  16306. }
  16307. /* "_yaml.pyx":1160
  16308. * plain_implicit, quoted_implicit, scalar_style) == 0:
  16309. * raise MemoryError
  16310. * elif event_class is SequenceStartEvent: # <<<<<<<<<<<<<<
  16311. * anchor = NULL
  16312. * anchor_object = event_object.anchor
  16313. */
  16314. __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_SequenceStartEvent); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1160, __pyx_L1_error)
  16315. __Pyx_GOTREF(__pyx_t_4);
  16316. __pyx_t_2 = (__pyx_v_event_class == __pyx_t_4);
  16317. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16318. __pyx_t_3 = (__pyx_t_2 != 0);
  16319. if (__pyx_t_3) {
  16320. /* "_yaml.pyx":1161
  16321. * raise MemoryError
  16322. * elif event_class is SequenceStartEvent:
  16323. * anchor = NULL # <<<<<<<<<<<<<<
  16324. * anchor_object = event_object.anchor
  16325. * if anchor_object is not None:
  16326. */
  16327. __pyx_v_anchor = NULL;
  16328. /* "_yaml.pyx":1162
  16329. * elif event_class is SequenceStartEvent:
  16330. * anchor = NULL
  16331. * anchor_object = event_object.anchor # <<<<<<<<<<<<<<
  16332. * if anchor_object is not None:
  16333. * if PyUnicode_CheckExact(anchor_object):
  16334. */
  16335. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_anchor); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1162, __pyx_L1_error)
  16336. __Pyx_GOTREF(__pyx_t_4);
  16337. __pyx_v_anchor_object = __pyx_t_4;
  16338. __pyx_t_4 = 0;
  16339. /* "_yaml.pyx":1163
  16340. * anchor = NULL
  16341. * anchor_object = event_object.anchor
  16342. * if anchor_object is not None: # <<<<<<<<<<<<<<
  16343. * if PyUnicode_CheckExact(anchor_object):
  16344. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16345. */
  16346. __pyx_t_3 = (__pyx_v_anchor_object != Py_None);
  16347. __pyx_t_2 = (__pyx_t_3 != 0);
  16348. if (__pyx_t_2) {
  16349. /* "_yaml.pyx":1164
  16350. * anchor_object = event_object.anchor
  16351. * if anchor_object is not None:
  16352. * if PyUnicode_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  16353. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16354. * if not PyString_CheckExact(anchor_object):
  16355. */
  16356. __pyx_t_2 = (PyUnicode_CheckExact(__pyx_v_anchor_object) != 0);
  16357. if (__pyx_t_2) {
  16358. /* "_yaml.pyx":1165
  16359. * if anchor_object is not None:
  16360. * if PyUnicode_CheckExact(anchor_object):
  16361. * anchor_object = PyUnicode_AsUTF8String(anchor_object) # <<<<<<<<<<<<<<
  16362. * if not PyString_CheckExact(anchor_object):
  16363. * if PY_MAJOR_VERSION < 3:
  16364. */
  16365. __pyx_t_4 = PyUnicode_AsUTF8String(__pyx_v_anchor_object); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1165, __pyx_L1_error)
  16366. __Pyx_GOTREF(__pyx_t_4);
  16367. __Pyx_DECREF_SET(__pyx_v_anchor_object, __pyx_t_4);
  16368. __pyx_t_4 = 0;
  16369. /* "_yaml.pyx":1164
  16370. * anchor_object = event_object.anchor
  16371. * if anchor_object is not None:
  16372. * if PyUnicode_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  16373. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16374. * if not PyString_CheckExact(anchor_object):
  16375. */
  16376. }
  16377. /* "_yaml.pyx":1166
  16378. * if PyUnicode_CheckExact(anchor_object):
  16379. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16380. * if not PyString_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  16381. * if PY_MAJOR_VERSION < 3:
  16382. * raise TypeError("anchor must be a string")
  16383. */
  16384. __pyx_t_2 = ((!(PyString_CheckExact(__pyx_v_anchor_object) != 0)) != 0);
  16385. if (__pyx_t_2) {
  16386. /* "_yaml.pyx":1167
  16387. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16388. * if not PyString_CheckExact(anchor_object):
  16389. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  16390. * raise TypeError("anchor must be a string")
  16391. * else:
  16392. */
  16393. __pyx_t_2 = ((PY_MAJOR_VERSION < 3) != 0);
  16394. if (unlikely(__pyx_t_2)) {
  16395. /* "_yaml.pyx":1168
  16396. * if not PyString_CheckExact(anchor_object):
  16397. * if PY_MAJOR_VERSION < 3:
  16398. * raise TypeError("anchor must be a string") # <<<<<<<<<<<<<<
  16399. * else:
  16400. * raise TypeError(u"anchor must be a string")
  16401. */
  16402. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__30, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1168, __pyx_L1_error)
  16403. __Pyx_GOTREF(__pyx_t_4);
  16404. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  16405. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16406. __PYX_ERR(0, 1168, __pyx_L1_error)
  16407. /* "_yaml.pyx":1167
  16408. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16409. * if not PyString_CheckExact(anchor_object):
  16410. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  16411. * raise TypeError("anchor must be a string")
  16412. * else:
  16413. */
  16414. }
  16415. /* "_yaml.pyx":1170
  16416. * raise TypeError("anchor must be a string")
  16417. * else:
  16418. * raise TypeError(u"anchor must be a string") # <<<<<<<<<<<<<<
  16419. * anchor = PyString_AS_STRING(anchor_object)
  16420. * tag = NULL
  16421. */
  16422. /*else*/ {
  16423. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__31, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1170, __pyx_L1_error)
  16424. __Pyx_GOTREF(__pyx_t_4);
  16425. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  16426. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16427. __PYX_ERR(0, 1170, __pyx_L1_error)
  16428. }
  16429. /* "_yaml.pyx":1166
  16430. * if PyUnicode_CheckExact(anchor_object):
  16431. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16432. * if not PyString_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  16433. * if PY_MAJOR_VERSION < 3:
  16434. * raise TypeError("anchor must be a string")
  16435. */
  16436. }
  16437. /* "_yaml.pyx":1171
  16438. * else:
  16439. * raise TypeError(u"anchor must be a string")
  16440. * anchor = PyString_AS_STRING(anchor_object) # <<<<<<<<<<<<<<
  16441. * tag = NULL
  16442. * tag_object = event_object.tag
  16443. */
  16444. __pyx_v_anchor = PyString_AS_STRING(__pyx_v_anchor_object);
  16445. /* "_yaml.pyx":1163
  16446. * anchor = NULL
  16447. * anchor_object = event_object.anchor
  16448. * if anchor_object is not None: # <<<<<<<<<<<<<<
  16449. * if PyUnicode_CheckExact(anchor_object):
  16450. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16451. */
  16452. }
  16453. /* "_yaml.pyx":1172
  16454. * raise TypeError(u"anchor must be a string")
  16455. * anchor = PyString_AS_STRING(anchor_object)
  16456. * tag = NULL # <<<<<<<<<<<<<<
  16457. * tag_object = event_object.tag
  16458. * if tag_object is not None:
  16459. */
  16460. __pyx_v_tag = NULL;
  16461. /* "_yaml.pyx":1173
  16462. * anchor = PyString_AS_STRING(anchor_object)
  16463. * tag = NULL
  16464. * tag_object = event_object.tag # <<<<<<<<<<<<<<
  16465. * if tag_object is not None:
  16466. * if PyUnicode_CheckExact(tag_object):
  16467. */
  16468. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_tag); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1173, __pyx_L1_error)
  16469. __Pyx_GOTREF(__pyx_t_4);
  16470. __pyx_v_tag_object = __pyx_t_4;
  16471. __pyx_t_4 = 0;
  16472. /* "_yaml.pyx":1174
  16473. * tag = NULL
  16474. * tag_object = event_object.tag
  16475. * if tag_object is not None: # <<<<<<<<<<<<<<
  16476. * if PyUnicode_CheckExact(tag_object):
  16477. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16478. */
  16479. __pyx_t_2 = (__pyx_v_tag_object != Py_None);
  16480. __pyx_t_3 = (__pyx_t_2 != 0);
  16481. if (__pyx_t_3) {
  16482. /* "_yaml.pyx":1175
  16483. * tag_object = event_object.tag
  16484. * if tag_object is not None:
  16485. * if PyUnicode_CheckExact(tag_object): # <<<<<<<<<<<<<<
  16486. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16487. * if not PyString_CheckExact(tag_object):
  16488. */
  16489. __pyx_t_3 = (PyUnicode_CheckExact(__pyx_v_tag_object) != 0);
  16490. if (__pyx_t_3) {
  16491. /* "_yaml.pyx":1176
  16492. * if tag_object is not None:
  16493. * if PyUnicode_CheckExact(tag_object):
  16494. * tag_object = PyUnicode_AsUTF8String(tag_object) # <<<<<<<<<<<<<<
  16495. * if not PyString_CheckExact(tag_object):
  16496. * if PY_MAJOR_VERSION < 3:
  16497. */
  16498. __pyx_t_4 = PyUnicode_AsUTF8String(__pyx_v_tag_object); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1176, __pyx_L1_error)
  16499. __Pyx_GOTREF(__pyx_t_4);
  16500. __Pyx_DECREF_SET(__pyx_v_tag_object, __pyx_t_4);
  16501. __pyx_t_4 = 0;
  16502. /* "_yaml.pyx":1175
  16503. * tag_object = event_object.tag
  16504. * if tag_object is not None:
  16505. * if PyUnicode_CheckExact(tag_object): # <<<<<<<<<<<<<<
  16506. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16507. * if not PyString_CheckExact(tag_object):
  16508. */
  16509. }
  16510. /* "_yaml.pyx":1177
  16511. * if PyUnicode_CheckExact(tag_object):
  16512. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16513. * if not PyString_CheckExact(tag_object): # <<<<<<<<<<<<<<
  16514. * if PY_MAJOR_VERSION < 3:
  16515. * raise TypeError("tag must be a string")
  16516. */
  16517. __pyx_t_3 = ((!(PyString_CheckExact(__pyx_v_tag_object) != 0)) != 0);
  16518. if (__pyx_t_3) {
  16519. /* "_yaml.pyx":1178
  16520. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16521. * if not PyString_CheckExact(tag_object):
  16522. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  16523. * raise TypeError("tag must be a string")
  16524. * else:
  16525. */
  16526. __pyx_t_3 = ((PY_MAJOR_VERSION < 3) != 0);
  16527. if (unlikely(__pyx_t_3)) {
  16528. /* "_yaml.pyx":1179
  16529. * if not PyString_CheckExact(tag_object):
  16530. * if PY_MAJOR_VERSION < 3:
  16531. * raise TypeError("tag must be a string") # <<<<<<<<<<<<<<
  16532. * else:
  16533. * raise TypeError(u"tag must be a string")
  16534. */
  16535. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__32, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1179, __pyx_L1_error)
  16536. __Pyx_GOTREF(__pyx_t_4);
  16537. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  16538. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16539. __PYX_ERR(0, 1179, __pyx_L1_error)
  16540. /* "_yaml.pyx":1178
  16541. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16542. * if not PyString_CheckExact(tag_object):
  16543. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  16544. * raise TypeError("tag must be a string")
  16545. * else:
  16546. */
  16547. }
  16548. /* "_yaml.pyx":1181
  16549. * raise TypeError("tag must be a string")
  16550. * else:
  16551. * raise TypeError(u"tag must be a string") # <<<<<<<<<<<<<<
  16552. * tag = PyString_AS_STRING(tag_object)
  16553. * implicit = 0
  16554. */
  16555. /*else*/ {
  16556. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__33, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1181, __pyx_L1_error)
  16557. __Pyx_GOTREF(__pyx_t_4);
  16558. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  16559. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16560. __PYX_ERR(0, 1181, __pyx_L1_error)
  16561. }
  16562. /* "_yaml.pyx":1177
  16563. * if PyUnicode_CheckExact(tag_object):
  16564. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16565. * if not PyString_CheckExact(tag_object): # <<<<<<<<<<<<<<
  16566. * if PY_MAJOR_VERSION < 3:
  16567. * raise TypeError("tag must be a string")
  16568. */
  16569. }
  16570. /* "_yaml.pyx":1182
  16571. * else:
  16572. * raise TypeError(u"tag must be a string")
  16573. * tag = PyString_AS_STRING(tag_object) # <<<<<<<<<<<<<<
  16574. * implicit = 0
  16575. * if event_object.implicit:
  16576. */
  16577. __pyx_v_tag = PyString_AS_STRING(__pyx_v_tag_object);
  16578. /* "_yaml.pyx":1174
  16579. * tag = NULL
  16580. * tag_object = event_object.tag
  16581. * if tag_object is not None: # <<<<<<<<<<<<<<
  16582. * if PyUnicode_CheckExact(tag_object):
  16583. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16584. */
  16585. }
  16586. /* "_yaml.pyx":1183
  16587. * raise TypeError(u"tag must be a string")
  16588. * tag = PyString_AS_STRING(tag_object)
  16589. * implicit = 0 # <<<<<<<<<<<<<<
  16590. * if event_object.implicit:
  16591. * implicit = 1
  16592. */
  16593. __pyx_v_implicit = 0;
  16594. /* "_yaml.pyx":1184
  16595. * tag = PyString_AS_STRING(tag_object)
  16596. * implicit = 0
  16597. * if event_object.implicit: # <<<<<<<<<<<<<<
  16598. * implicit = 1
  16599. * sequence_style = YAML_BLOCK_SEQUENCE_STYLE
  16600. */
  16601. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_implicit); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1184, __pyx_L1_error)
  16602. __Pyx_GOTREF(__pyx_t_4);
  16603. __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1184, __pyx_L1_error)
  16604. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16605. if (__pyx_t_3) {
  16606. /* "_yaml.pyx":1185
  16607. * implicit = 0
  16608. * if event_object.implicit:
  16609. * implicit = 1 # <<<<<<<<<<<<<<
  16610. * sequence_style = YAML_BLOCK_SEQUENCE_STYLE
  16611. * if event_object.flow_style:
  16612. */
  16613. __pyx_v_implicit = 1;
  16614. /* "_yaml.pyx":1184
  16615. * tag = PyString_AS_STRING(tag_object)
  16616. * implicit = 0
  16617. * if event_object.implicit: # <<<<<<<<<<<<<<
  16618. * implicit = 1
  16619. * sequence_style = YAML_BLOCK_SEQUENCE_STYLE
  16620. */
  16621. }
  16622. /* "_yaml.pyx":1186
  16623. * if event_object.implicit:
  16624. * implicit = 1
  16625. * sequence_style = YAML_BLOCK_SEQUENCE_STYLE # <<<<<<<<<<<<<<
  16626. * if event_object.flow_style:
  16627. * sequence_style = YAML_FLOW_SEQUENCE_STYLE
  16628. */
  16629. __pyx_v_sequence_style = YAML_BLOCK_SEQUENCE_STYLE;
  16630. /* "_yaml.pyx":1187
  16631. * implicit = 1
  16632. * sequence_style = YAML_BLOCK_SEQUENCE_STYLE
  16633. * if event_object.flow_style: # <<<<<<<<<<<<<<
  16634. * sequence_style = YAML_FLOW_SEQUENCE_STYLE
  16635. * if yaml_sequence_start_event_initialize(event, anchor, tag,
  16636. */
  16637. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_flow_style); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1187, __pyx_L1_error)
  16638. __Pyx_GOTREF(__pyx_t_4);
  16639. __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1187, __pyx_L1_error)
  16640. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16641. if (__pyx_t_3) {
  16642. /* "_yaml.pyx":1188
  16643. * sequence_style = YAML_BLOCK_SEQUENCE_STYLE
  16644. * if event_object.flow_style:
  16645. * sequence_style = YAML_FLOW_SEQUENCE_STYLE # <<<<<<<<<<<<<<
  16646. * if yaml_sequence_start_event_initialize(event, anchor, tag,
  16647. * implicit, sequence_style) == 0:
  16648. */
  16649. __pyx_v_sequence_style = YAML_FLOW_SEQUENCE_STYLE;
  16650. /* "_yaml.pyx":1187
  16651. * implicit = 1
  16652. * sequence_style = YAML_BLOCK_SEQUENCE_STYLE
  16653. * if event_object.flow_style: # <<<<<<<<<<<<<<
  16654. * sequence_style = YAML_FLOW_SEQUENCE_STYLE
  16655. * if yaml_sequence_start_event_initialize(event, anchor, tag,
  16656. */
  16657. }
  16658. /* "_yaml.pyx":1190
  16659. * sequence_style = YAML_FLOW_SEQUENCE_STYLE
  16660. * if yaml_sequence_start_event_initialize(event, anchor, tag,
  16661. * implicit, sequence_style) == 0: # <<<<<<<<<<<<<<
  16662. * raise MemoryError
  16663. * elif event_class is MappingStartEvent:
  16664. */
  16665. __pyx_t_3 = ((yaml_sequence_start_event_initialize(__pyx_v_event, __pyx_v_anchor, __pyx_v_tag, __pyx_v_implicit, __pyx_v_sequence_style) == 0) != 0);
  16666. /* "_yaml.pyx":1189
  16667. * if event_object.flow_style:
  16668. * sequence_style = YAML_FLOW_SEQUENCE_STYLE
  16669. * if yaml_sequence_start_event_initialize(event, anchor, tag, # <<<<<<<<<<<<<<
  16670. * implicit, sequence_style) == 0:
  16671. * raise MemoryError
  16672. */
  16673. if (unlikely(__pyx_t_3)) {
  16674. /* "_yaml.pyx":1191
  16675. * if yaml_sequence_start_event_initialize(event, anchor, tag,
  16676. * implicit, sequence_style) == 0:
  16677. * raise MemoryError # <<<<<<<<<<<<<<
  16678. * elif event_class is MappingStartEvent:
  16679. * anchor = NULL
  16680. */
  16681. PyErr_NoMemory(); __PYX_ERR(0, 1191, __pyx_L1_error)
  16682. /* "_yaml.pyx":1189
  16683. * if event_object.flow_style:
  16684. * sequence_style = YAML_FLOW_SEQUENCE_STYLE
  16685. * if yaml_sequence_start_event_initialize(event, anchor, tag, # <<<<<<<<<<<<<<
  16686. * implicit, sequence_style) == 0:
  16687. * raise MemoryError
  16688. */
  16689. }
  16690. /* "_yaml.pyx":1160
  16691. * plain_implicit, quoted_implicit, scalar_style) == 0:
  16692. * raise MemoryError
  16693. * elif event_class is SequenceStartEvent: # <<<<<<<<<<<<<<
  16694. * anchor = NULL
  16695. * anchor_object = event_object.anchor
  16696. */
  16697. goto __pyx_L3;
  16698. }
  16699. /* "_yaml.pyx":1192
  16700. * implicit, sequence_style) == 0:
  16701. * raise MemoryError
  16702. * elif event_class is MappingStartEvent: # <<<<<<<<<<<<<<
  16703. * anchor = NULL
  16704. * anchor_object = event_object.anchor
  16705. */
  16706. __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_MappingStartEvent); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1192, __pyx_L1_error)
  16707. __Pyx_GOTREF(__pyx_t_4);
  16708. __pyx_t_3 = (__pyx_v_event_class == __pyx_t_4);
  16709. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16710. __pyx_t_2 = (__pyx_t_3 != 0);
  16711. if (__pyx_t_2) {
  16712. /* "_yaml.pyx":1193
  16713. * raise MemoryError
  16714. * elif event_class is MappingStartEvent:
  16715. * anchor = NULL # <<<<<<<<<<<<<<
  16716. * anchor_object = event_object.anchor
  16717. * if anchor_object is not None:
  16718. */
  16719. __pyx_v_anchor = NULL;
  16720. /* "_yaml.pyx":1194
  16721. * elif event_class is MappingStartEvent:
  16722. * anchor = NULL
  16723. * anchor_object = event_object.anchor # <<<<<<<<<<<<<<
  16724. * if anchor_object is not None:
  16725. * if PyUnicode_CheckExact(anchor_object):
  16726. */
  16727. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_anchor); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1194, __pyx_L1_error)
  16728. __Pyx_GOTREF(__pyx_t_4);
  16729. __pyx_v_anchor_object = __pyx_t_4;
  16730. __pyx_t_4 = 0;
  16731. /* "_yaml.pyx":1195
  16732. * anchor = NULL
  16733. * anchor_object = event_object.anchor
  16734. * if anchor_object is not None: # <<<<<<<<<<<<<<
  16735. * if PyUnicode_CheckExact(anchor_object):
  16736. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16737. */
  16738. __pyx_t_2 = (__pyx_v_anchor_object != Py_None);
  16739. __pyx_t_3 = (__pyx_t_2 != 0);
  16740. if (__pyx_t_3) {
  16741. /* "_yaml.pyx":1196
  16742. * anchor_object = event_object.anchor
  16743. * if anchor_object is not None:
  16744. * if PyUnicode_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  16745. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16746. * if not PyString_CheckExact(anchor_object):
  16747. */
  16748. __pyx_t_3 = (PyUnicode_CheckExact(__pyx_v_anchor_object) != 0);
  16749. if (__pyx_t_3) {
  16750. /* "_yaml.pyx":1197
  16751. * if anchor_object is not None:
  16752. * if PyUnicode_CheckExact(anchor_object):
  16753. * anchor_object = PyUnicode_AsUTF8String(anchor_object) # <<<<<<<<<<<<<<
  16754. * if not PyString_CheckExact(anchor_object):
  16755. * if PY_MAJOR_VERSION < 3:
  16756. */
  16757. __pyx_t_4 = PyUnicode_AsUTF8String(__pyx_v_anchor_object); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1197, __pyx_L1_error)
  16758. __Pyx_GOTREF(__pyx_t_4);
  16759. __Pyx_DECREF_SET(__pyx_v_anchor_object, __pyx_t_4);
  16760. __pyx_t_4 = 0;
  16761. /* "_yaml.pyx":1196
  16762. * anchor_object = event_object.anchor
  16763. * if anchor_object is not None:
  16764. * if PyUnicode_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  16765. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16766. * if not PyString_CheckExact(anchor_object):
  16767. */
  16768. }
  16769. /* "_yaml.pyx":1198
  16770. * if PyUnicode_CheckExact(anchor_object):
  16771. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16772. * if not PyString_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  16773. * if PY_MAJOR_VERSION < 3:
  16774. * raise TypeError("anchor must be a string")
  16775. */
  16776. __pyx_t_3 = ((!(PyString_CheckExact(__pyx_v_anchor_object) != 0)) != 0);
  16777. if (__pyx_t_3) {
  16778. /* "_yaml.pyx":1199
  16779. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16780. * if not PyString_CheckExact(anchor_object):
  16781. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  16782. * raise TypeError("anchor must be a string")
  16783. * else:
  16784. */
  16785. __pyx_t_3 = ((PY_MAJOR_VERSION < 3) != 0);
  16786. if (unlikely(__pyx_t_3)) {
  16787. /* "_yaml.pyx":1200
  16788. * if not PyString_CheckExact(anchor_object):
  16789. * if PY_MAJOR_VERSION < 3:
  16790. * raise TypeError("anchor must be a string") # <<<<<<<<<<<<<<
  16791. * else:
  16792. * raise TypeError(u"anchor must be a string")
  16793. */
  16794. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__30, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1200, __pyx_L1_error)
  16795. __Pyx_GOTREF(__pyx_t_4);
  16796. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  16797. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16798. __PYX_ERR(0, 1200, __pyx_L1_error)
  16799. /* "_yaml.pyx":1199
  16800. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16801. * if not PyString_CheckExact(anchor_object):
  16802. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  16803. * raise TypeError("anchor must be a string")
  16804. * else:
  16805. */
  16806. }
  16807. /* "_yaml.pyx":1202
  16808. * raise TypeError("anchor must be a string")
  16809. * else:
  16810. * raise TypeError(u"anchor must be a string") # <<<<<<<<<<<<<<
  16811. * anchor = PyString_AS_STRING(anchor_object)
  16812. * tag = NULL
  16813. */
  16814. /*else*/ {
  16815. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__31, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1202, __pyx_L1_error)
  16816. __Pyx_GOTREF(__pyx_t_4);
  16817. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  16818. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16819. __PYX_ERR(0, 1202, __pyx_L1_error)
  16820. }
  16821. /* "_yaml.pyx":1198
  16822. * if PyUnicode_CheckExact(anchor_object):
  16823. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16824. * if not PyString_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  16825. * if PY_MAJOR_VERSION < 3:
  16826. * raise TypeError("anchor must be a string")
  16827. */
  16828. }
  16829. /* "_yaml.pyx":1203
  16830. * else:
  16831. * raise TypeError(u"anchor must be a string")
  16832. * anchor = PyString_AS_STRING(anchor_object) # <<<<<<<<<<<<<<
  16833. * tag = NULL
  16834. * tag_object = event_object.tag
  16835. */
  16836. __pyx_v_anchor = PyString_AS_STRING(__pyx_v_anchor_object);
  16837. /* "_yaml.pyx":1195
  16838. * anchor = NULL
  16839. * anchor_object = event_object.anchor
  16840. * if anchor_object is not None: # <<<<<<<<<<<<<<
  16841. * if PyUnicode_CheckExact(anchor_object):
  16842. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  16843. */
  16844. }
  16845. /* "_yaml.pyx":1204
  16846. * raise TypeError(u"anchor must be a string")
  16847. * anchor = PyString_AS_STRING(anchor_object)
  16848. * tag = NULL # <<<<<<<<<<<<<<
  16849. * tag_object = event_object.tag
  16850. * if tag_object is not None:
  16851. */
  16852. __pyx_v_tag = NULL;
  16853. /* "_yaml.pyx":1205
  16854. * anchor = PyString_AS_STRING(anchor_object)
  16855. * tag = NULL
  16856. * tag_object = event_object.tag # <<<<<<<<<<<<<<
  16857. * if tag_object is not None:
  16858. * if PyUnicode_CheckExact(tag_object):
  16859. */
  16860. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_tag); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1205, __pyx_L1_error)
  16861. __Pyx_GOTREF(__pyx_t_4);
  16862. __pyx_v_tag_object = __pyx_t_4;
  16863. __pyx_t_4 = 0;
  16864. /* "_yaml.pyx":1206
  16865. * tag = NULL
  16866. * tag_object = event_object.tag
  16867. * if tag_object is not None: # <<<<<<<<<<<<<<
  16868. * if PyUnicode_CheckExact(tag_object):
  16869. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16870. */
  16871. __pyx_t_3 = (__pyx_v_tag_object != Py_None);
  16872. __pyx_t_2 = (__pyx_t_3 != 0);
  16873. if (__pyx_t_2) {
  16874. /* "_yaml.pyx":1207
  16875. * tag_object = event_object.tag
  16876. * if tag_object is not None:
  16877. * if PyUnicode_CheckExact(tag_object): # <<<<<<<<<<<<<<
  16878. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16879. * if not PyString_CheckExact(tag_object):
  16880. */
  16881. __pyx_t_2 = (PyUnicode_CheckExact(__pyx_v_tag_object) != 0);
  16882. if (__pyx_t_2) {
  16883. /* "_yaml.pyx":1208
  16884. * if tag_object is not None:
  16885. * if PyUnicode_CheckExact(tag_object):
  16886. * tag_object = PyUnicode_AsUTF8String(tag_object) # <<<<<<<<<<<<<<
  16887. * if not PyString_CheckExact(tag_object):
  16888. * if PY_MAJOR_VERSION < 3:
  16889. */
  16890. __pyx_t_4 = PyUnicode_AsUTF8String(__pyx_v_tag_object); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1208, __pyx_L1_error)
  16891. __Pyx_GOTREF(__pyx_t_4);
  16892. __Pyx_DECREF_SET(__pyx_v_tag_object, __pyx_t_4);
  16893. __pyx_t_4 = 0;
  16894. /* "_yaml.pyx":1207
  16895. * tag_object = event_object.tag
  16896. * if tag_object is not None:
  16897. * if PyUnicode_CheckExact(tag_object): # <<<<<<<<<<<<<<
  16898. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16899. * if not PyString_CheckExact(tag_object):
  16900. */
  16901. }
  16902. /* "_yaml.pyx":1209
  16903. * if PyUnicode_CheckExact(tag_object):
  16904. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16905. * if not PyString_CheckExact(tag_object): # <<<<<<<<<<<<<<
  16906. * if PY_MAJOR_VERSION < 3:
  16907. * raise TypeError("tag must be a string")
  16908. */
  16909. __pyx_t_2 = ((!(PyString_CheckExact(__pyx_v_tag_object) != 0)) != 0);
  16910. if (__pyx_t_2) {
  16911. /* "_yaml.pyx":1210
  16912. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16913. * if not PyString_CheckExact(tag_object):
  16914. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  16915. * raise TypeError("tag must be a string")
  16916. * else:
  16917. */
  16918. __pyx_t_2 = ((PY_MAJOR_VERSION < 3) != 0);
  16919. if (unlikely(__pyx_t_2)) {
  16920. /* "_yaml.pyx":1211
  16921. * if not PyString_CheckExact(tag_object):
  16922. * if PY_MAJOR_VERSION < 3:
  16923. * raise TypeError("tag must be a string") # <<<<<<<<<<<<<<
  16924. * else:
  16925. * raise TypeError(u"tag must be a string")
  16926. */
  16927. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__32, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1211, __pyx_L1_error)
  16928. __Pyx_GOTREF(__pyx_t_4);
  16929. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  16930. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16931. __PYX_ERR(0, 1211, __pyx_L1_error)
  16932. /* "_yaml.pyx":1210
  16933. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16934. * if not PyString_CheckExact(tag_object):
  16935. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  16936. * raise TypeError("tag must be a string")
  16937. * else:
  16938. */
  16939. }
  16940. /* "_yaml.pyx":1213
  16941. * raise TypeError("tag must be a string")
  16942. * else:
  16943. * raise TypeError(u"tag must be a string") # <<<<<<<<<<<<<<
  16944. * tag = PyString_AS_STRING(tag_object)
  16945. * implicit = 0
  16946. */
  16947. /*else*/ {
  16948. __pyx_t_4 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__33, NULL); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1213, __pyx_L1_error)
  16949. __Pyx_GOTREF(__pyx_t_4);
  16950. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  16951. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16952. __PYX_ERR(0, 1213, __pyx_L1_error)
  16953. }
  16954. /* "_yaml.pyx":1209
  16955. * if PyUnicode_CheckExact(tag_object):
  16956. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16957. * if not PyString_CheckExact(tag_object): # <<<<<<<<<<<<<<
  16958. * if PY_MAJOR_VERSION < 3:
  16959. * raise TypeError("tag must be a string")
  16960. */
  16961. }
  16962. /* "_yaml.pyx":1214
  16963. * else:
  16964. * raise TypeError(u"tag must be a string")
  16965. * tag = PyString_AS_STRING(tag_object) # <<<<<<<<<<<<<<
  16966. * implicit = 0
  16967. * if event_object.implicit:
  16968. */
  16969. __pyx_v_tag = PyString_AS_STRING(__pyx_v_tag_object);
  16970. /* "_yaml.pyx":1206
  16971. * tag = NULL
  16972. * tag_object = event_object.tag
  16973. * if tag_object is not None: # <<<<<<<<<<<<<<
  16974. * if PyUnicode_CheckExact(tag_object):
  16975. * tag_object = PyUnicode_AsUTF8String(tag_object)
  16976. */
  16977. }
  16978. /* "_yaml.pyx":1215
  16979. * raise TypeError(u"tag must be a string")
  16980. * tag = PyString_AS_STRING(tag_object)
  16981. * implicit = 0 # <<<<<<<<<<<<<<
  16982. * if event_object.implicit:
  16983. * implicit = 1
  16984. */
  16985. __pyx_v_implicit = 0;
  16986. /* "_yaml.pyx":1216
  16987. * tag = PyString_AS_STRING(tag_object)
  16988. * implicit = 0
  16989. * if event_object.implicit: # <<<<<<<<<<<<<<
  16990. * implicit = 1
  16991. * mapping_style = YAML_BLOCK_MAPPING_STYLE
  16992. */
  16993. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_implicit); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1216, __pyx_L1_error)
  16994. __Pyx_GOTREF(__pyx_t_4);
  16995. __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 1216, __pyx_L1_error)
  16996. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  16997. if (__pyx_t_2) {
  16998. /* "_yaml.pyx":1217
  16999. * implicit = 0
  17000. * if event_object.implicit:
  17001. * implicit = 1 # <<<<<<<<<<<<<<
  17002. * mapping_style = YAML_BLOCK_MAPPING_STYLE
  17003. * if event_object.flow_style:
  17004. */
  17005. __pyx_v_implicit = 1;
  17006. /* "_yaml.pyx":1216
  17007. * tag = PyString_AS_STRING(tag_object)
  17008. * implicit = 0
  17009. * if event_object.implicit: # <<<<<<<<<<<<<<
  17010. * implicit = 1
  17011. * mapping_style = YAML_BLOCK_MAPPING_STYLE
  17012. */
  17013. }
  17014. /* "_yaml.pyx":1218
  17015. * if event_object.implicit:
  17016. * implicit = 1
  17017. * mapping_style = YAML_BLOCK_MAPPING_STYLE # <<<<<<<<<<<<<<
  17018. * if event_object.flow_style:
  17019. * mapping_style = YAML_FLOW_MAPPING_STYLE
  17020. */
  17021. __pyx_v_mapping_style = YAML_BLOCK_MAPPING_STYLE;
  17022. /* "_yaml.pyx":1219
  17023. * implicit = 1
  17024. * mapping_style = YAML_BLOCK_MAPPING_STYLE
  17025. * if event_object.flow_style: # <<<<<<<<<<<<<<
  17026. * mapping_style = YAML_FLOW_MAPPING_STYLE
  17027. * if yaml_mapping_start_event_initialize(event, anchor, tag,
  17028. */
  17029. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_event_object, __pyx_n_s_flow_style); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1219, __pyx_L1_error)
  17030. __Pyx_GOTREF(__pyx_t_4);
  17031. __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_4); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 1219, __pyx_L1_error)
  17032. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  17033. if (__pyx_t_2) {
  17034. /* "_yaml.pyx":1220
  17035. * mapping_style = YAML_BLOCK_MAPPING_STYLE
  17036. * if event_object.flow_style:
  17037. * mapping_style = YAML_FLOW_MAPPING_STYLE # <<<<<<<<<<<<<<
  17038. * if yaml_mapping_start_event_initialize(event, anchor, tag,
  17039. * implicit, mapping_style) == 0:
  17040. */
  17041. __pyx_v_mapping_style = YAML_FLOW_MAPPING_STYLE;
  17042. /* "_yaml.pyx":1219
  17043. * implicit = 1
  17044. * mapping_style = YAML_BLOCK_MAPPING_STYLE
  17045. * if event_object.flow_style: # <<<<<<<<<<<<<<
  17046. * mapping_style = YAML_FLOW_MAPPING_STYLE
  17047. * if yaml_mapping_start_event_initialize(event, anchor, tag,
  17048. */
  17049. }
  17050. /* "_yaml.pyx":1222
  17051. * mapping_style = YAML_FLOW_MAPPING_STYLE
  17052. * if yaml_mapping_start_event_initialize(event, anchor, tag,
  17053. * implicit, mapping_style) == 0: # <<<<<<<<<<<<<<
  17054. * raise MemoryError
  17055. * elif event_class is SequenceEndEvent:
  17056. */
  17057. __pyx_t_2 = ((yaml_mapping_start_event_initialize(__pyx_v_event, __pyx_v_anchor, __pyx_v_tag, __pyx_v_implicit, __pyx_v_mapping_style) == 0) != 0);
  17058. /* "_yaml.pyx":1221
  17059. * if event_object.flow_style:
  17060. * mapping_style = YAML_FLOW_MAPPING_STYLE
  17061. * if yaml_mapping_start_event_initialize(event, anchor, tag, # <<<<<<<<<<<<<<
  17062. * implicit, mapping_style) == 0:
  17063. * raise MemoryError
  17064. */
  17065. if (unlikely(__pyx_t_2)) {
  17066. /* "_yaml.pyx":1223
  17067. * if yaml_mapping_start_event_initialize(event, anchor, tag,
  17068. * implicit, mapping_style) == 0:
  17069. * raise MemoryError # <<<<<<<<<<<<<<
  17070. * elif event_class is SequenceEndEvent:
  17071. * yaml_sequence_end_event_initialize(event)
  17072. */
  17073. PyErr_NoMemory(); __PYX_ERR(0, 1223, __pyx_L1_error)
  17074. /* "_yaml.pyx":1221
  17075. * if event_object.flow_style:
  17076. * mapping_style = YAML_FLOW_MAPPING_STYLE
  17077. * if yaml_mapping_start_event_initialize(event, anchor, tag, # <<<<<<<<<<<<<<
  17078. * implicit, mapping_style) == 0:
  17079. * raise MemoryError
  17080. */
  17081. }
  17082. /* "_yaml.pyx":1192
  17083. * implicit, sequence_style) == 0:
  17084. * raise MemoryError
  17085. * elif event_class is MappingStartEvent: # <<<<<<<<<<<<<<
  17086. * anchor = NULL
  17087. * anchor_object = event_object.anchor
  17088. */
  17089. goto __pyx_L3;
  17090. }
  17091. /* "_yaml.pyx":1224
  17092. * implicit, mapping_style) == 0:
  17093. * raise MemoryError
  17094. * elif event_class is SequenceEndEvent: # <<<<<<<<<<<<<<
  17095. * yaml_sequence_end_event_initialize(event)
  17096. * elif event_class is MappingEndEvent:
  17097. */
  17098. __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_SequenceEndEvent); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1224, __pyx_L1_error)
  17099. __Pyx_GOTREF(__pyx_t_4);
  17100. __pyx_t_2 = (__pyx_v_event_class == __pyx_t_4);
  17101. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  17102. __pyx_t_3 = (__pyx_t_2 != 0);
  17103. if (__pyx_t_3) {
  17104. /* "_yaml.pyx":1225
  17105. * raise MemoryError
  17106. * elif event_class is SequenceEndEvent:
  17107. * yaml_sequence_end_event_initialize(event) # <<<<<<<<<<<<<<
  17108. * elif event_class is MappingEndEvent:
  17109. * yaml_mapping_end_event_initialize(event)
  17110. */
  17111. (void)(yaml_sequence_end_event_initialize(__pyx_v_event));
  17112. /* "_yaml.pyx":1224
  17113. * implicit, mapping_style) == 0:
  17114. * raise MemoryError
  17115. * elif event_class is SequenceEndEvent: # <<<<<<<<<<<<<<
  17116. * yaml_sequence_end_event_initialize(event)
  17117. * elif event_class is MappingEndEvent:
  17118. */
  17119. goto __pyx_L3;
  17120. }
  17121. /* "_yaml.pyx":1226
  17122. * elif event_class is SequenceEndEvent:
  17123. * yaml_sequence_end_event_initialize(event)
  17124. * elif event_class is MappingEndEvent: # <<<<<<<<<<<<<<
  17125. * yaml_mapping_end_event_initialize(event)
  17126. * else:
  17127. */
  17128. __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_MappingEndEvent); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1226, __pyx_L1_error)
  17129. __Pyx_GOTREF(__pyx_t_4);
  17130. __pyx_t_3 = (__pyx_v_event_class == __pyx_t_4);
  17131. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  17132. __pyx_t_2 = (__pyx_t_3 != 0);
  17133. if (__pyx_t_2) {
  17134. /* "_yaml.pyx":1227
  17135. * yaml_sequence_end_event_initialize(event)
  17136. * elif event_class is MappingEndEvent:
  17137. * yaml_mapping_end_event_initialize(event) # <<<<<<<<<<<<<<
  17138. * else:
  17139. * if PY_MAJOR_VERSION < 3:
  17140. */
  17141. (void)(yaml_mapping_end_event_initialize(__pyx_v_event));
  17142. /* "_yaml.pyx":1226
  17143. * elif event_class is SequenceEndEvent:
  17144. * yaml_sequence_end_event_initialize(event)
  17145. * elif event_class is MappingEndEvent: # <<<<<<<<<<<<<<
  17146. * yaml_mapping_end_event_initialize(event)
  17147. * else:
  17148. */
  17149. goto __pyx_L3;
  17150. }
  17151. /* "_yaml.pyx":1229
  17152. * yaml_mapping_end_event_initialize(event)
  17153. * else:
  17154. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  17155. * raise TypeError("invalid event %s" % event_object)
  17156. * else:
  17157. */
  17158. /*else*/ {
  17159. __pyx_t_2 = ((PY_MAJOR_VERSION < 3) != 0);
  17160. if (unlikely(__pyx_t_2)) {
  17161. /* "_yaml.pyx":1230
  17162. * else:
  17163. * if PY_MAJOR_VERSION < 3:
  17164. * raise TypeError("invalid event %s" % event_object) # <<<<<<<<<<<<<<
  17165. * else:
  17166. * raise TypeError(u"invalid event %s" % event_object)
  17167. */
  17168. __pyx_t_4 = __Pyx_PyString_FormatSafe(__pyx_kp_s_invalid_event_s, __pyx_v_event_object); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1230, __pyx_L1_error)
  17169. __Pyx_GOTREF(__pyx_t_4);
  17170. __pyx_t_8 = __Pyx_PyObject_CallOneArg(__pyx_builtin_TypeError, __pyx_t_4); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 1230, __pyx_L1_error)
  17171. __Pyx_GOTREF(__pyx_t_8);
  17172. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  17173. __Pyx_Raise(__pyx_t_8, 0, 0, 0);
  17174. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  17175. __PYX_ERR(0, 1230, __pyx_L1_error)
  17176. /* "_yaml.pyx":1229
  17177. * yaml_mapping_end_event_initialize(event)
  17178. * else:
  17179. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  17180. * raise TypeError("invalid event %s" % event_object)
  17181. * else:
  17182. */
  17183. }
  17184. /* "_yaml.pyx":1232
  17185. * raise TypeError("invalid event %s" % event_object)
  17186. * else:
  17187. * raise TypeError(u"invalid event %s" % event_object) # <<<<<<<<<<<<<<
  17188. * return 1
  17189. *
  17190. */
  17191. /*else*/ {
  17192. __pyx_t_8 = __Pyx_PyUnicode_FormatSafe(__pyx_kp_u_invalid_event_s, __pyx_v_event_object); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 1232, __pyx_L1_error)
  17193. __Pyx_GOTREF(__pyx_t_8);
  17194. __pyx_t_4 = __Pyx_PyObject_CallOneArg(__pyx_builtin_TypeError, __pyx_t_8); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1232, __pyx_L1_error)
  17195. __Pyx_GOTREF(__pyx_t_4);
  17196. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  17197. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  17198. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  17199. __PYX_ERR(0, 1232, __pyx_L1_error)
  17200. }
  17201. }
  17202. __pyx_L3:;
  17203. /* "_yaml.pyx":1233
  17204. * else:
  17205. * raise TypeError(u"invalid event %s" % event_object)
  17206. * return 1 # <<<<<<<<<<<<<<
  17207. *
  17208. * def emit(self, event_object):
  17209. */
  17210. __pyx_r = 1;
  17211. goto __pyx_L0;
  17212. /* "_yaml.pyx":1016
  17213. * raise ValueError(u"no emitter error")
  17214. *
  17215. * cdef int _object_to_event(self, object event_object, yaml_event_t *event) except 0: # <<<<<<<<<<<<<<
  17216. * cdef yaml_encoding_t encoding
  17217. * cdef yaml_version_directive_t version_directive_value
  17218. */
  17219. /* function exit code */
  17220. __pyx_L1_error:;
  17221. __Pyx_XDECREF(__pyx_t_1);
  17222. __Pyx_XDECREF(__pyx_t_4);
  17223. __Pyx_XDECREF(__pyx_t_8);
  17224. __Pyx_AddTraceback("_yaml.CEmitter._object_to_event", __pyx_clineno, __pyx_lineno, __pyx_filename);
  17225. __pyx_r = 0;
  17226. __pyx_L0:;
  17227. __Pyx_XDECREF(__pyx_v_event_class);
  17228. __Pyx_XDECREF(__pyx_v_cache);
  17229. __Pyx_XDECREF(__pyx_v_handle);
  17230. __Pyx_XDECREF(__pyx_v_prefix);
  17231. __Pyx_XDECREF(__pyx_v_anchor_object);
  17232. __Pyx_XDECREF(__pyx_v_tag_object);
  17233. __Pyx_XDECREF(__pyx_v_value_object);
  17234. __Pyx_XDECREF(__pyx_v_style_object);
  17235. __Pyx_RefNannyFinishContext();
  17236. return __pyx_r;
  17237. }
  17238. /* "_yaml.pyx":1235
  17239. * return 1
  17240. *
  17241. * def emit(self, event_object): # <<<<<<<<<<<<<<
  17242. * cdef yaml_event_t event
  17243. * self._object_to_event(event_object, &event)
  17244. */
  17245. /* Python wrapper */
  17246. static PyObject *__pyx_pw_5_yaml_8CEmitter_7emit(PyObject *__pyx_v_self, PyObject *__pyx_v_event_object); /*proto*/
  17247. static PyObject *__pyx_pw_5_yaml_8CEmitter_7emit(PyObject *__pyx_v_self, PyObject *__pyx_v_event_object) {
  17248. PyObject *__pyx_r = 0;
  17249. __Pyx_RefNannyDeclarations
  17250. __Pyx_RefNannySetupContext("emit (wrapper)", 0);
  17251. __pyx_r = __pyx_pf_5_yaml_8CEmitter_6emit(((struct __pyx_obj_5_yaml_CEmitter *)__pyx_v_self), ((PyObject *)__pyx_v_event_object));
  17252. /* function exit code */
  17253. __Pyx_RefNannyFinishContext();
  17254. return __pyx_r;
  17255. }
  17256. static PyObject *__pyx_pf_5_yaml_8CEmitter_6emit(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self, PyObject *__pyx_v_event_object) {
  17257. yaml_event_t __pyx_v_event;
  17258. PyObject *__pyx_v_error = NULL;
  17259. PyObject *__pyx_r = NULL;
  17260. __Pyx_RefNannyDeclarations
  17261. int __pyx_t_1;
  17262. int __pyx_t_2;
  17263. PyObject *__pyx_t_3 = NULL;
  17264. __Pyx_RefNannySetupContext("emit", 0);
  17265. /* "_yaml.pyx":1237
  17266. * def emit(self, event_object):
  17267. * cdef yaml_event_t event
  17268. * self._object_to_event(event_object, &event) # <<<<<<<<<<<<<<
  17269. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  17270. * error = self._emitter_error()
  17271. */
  17272. __pyx_t_1 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_object_to_event(__pyx_v_self, __pyx_v_event_object, (&__pyx_v_event)); if (unlikely(__pyx_t_1 == ((int)0))) __PYX_ERR(0, 1237, __pyx_L1_error)
  17273. /* "_yaml.pyx":1238
  17274. * cdef yaml_event_t event
  17275. * self._object_to_event(event_object, &event)
  17276. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  17277. * error = self._emitter_error()
  17278. * raise error
  17279. */
  17280. __pyx_t_1 = yaml_emitter_emit((&__pyx_v_self->emitter), (&__pyx_v_event)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 1238, __pyx_L1_error)
  17281. __pyx_t_2 = ((__pyx_t_1 == 0) != 0);
  17282. if (unlikely(__pyx_t_2)) {
  17283. /* "_yaml.pyx":1239
  17284. * self._object_to_event(event_object, &event)
  17285. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  17286. * error = self._emitter_error() # <<<<<<<<<<<<<<
  17287. * raise error
  17288. *
  17289. */
  17290. __pyx_t_3 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_emitter_error(__pyx_v_self); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1239, __pyx_L1_error)
  17291. __Pyx_GOTREF(__pyx_t_3);
  17292. __pyx_v_error = __pyx_t_3;
  17293. __pyx_t_3 = 0;
  17294. /* "_yaml.pyx":1240
  17295. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  17296. * error = self._emitter_error()
  17297. * raise error # <<<<<<<<<<<<<<
  17298. *
  17299. * def open(self):
  17300. */
  17301. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  17302. __PYX_ERR(0, 1240, __pyx_L1_error)
  17303. /* "_yaml.pyx":1238
  17304. * cdef yaml_event_t event
  17305. * self._object_to_event(event_object, &event)
  17306. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  17307. * error = self._emitter_error()
  17308. * raise error
  17309. */
  17310. }
  17311. /* "_yaml.pyx":1235
  17312. * return 1
  17313. *
  17314. * def emit(self, event_object): # <<<<<<<<<<<<<<
  17315. * cdef yaml_event_t event
  17316. * self._object_to_event(event_object, &event)
  17317. */
  17318. /* function exit code */
  17319. __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  17320. goto __pyx_L0;
  17321. __pyx_L1_error:;
  17322. __Pyx_XDECREF(__pyx_t_3);
  17323. __Pyx_AddTraceback("_yaml.CEmitter.emit", __pyx_clineno, __pyx_lineno, __pyx_filename);
  17324. __pyx_r = NULL;
  17325. __pyx_L0:;
  17326. __Pyx_XDECREF(__pyx_v_error);
  17327. __Pyx_XGIVEREF(__pyx_r);
  17328. __Pyx_RefNannyFinishContext();
  17329. return __pyx_r;
  17330. }
  17331. /* "_yaml.pyx":1242
  17332. * raise error
  17333. *
  17334. * def open(self): # <<<<<<<<<<<<<<
  17335. * cdef yaml_event_t event
  17336. * cdef yaml_encoding_t encoding
  17337. */
  17338. /* Python wrapper */
  17339. static PyObject *__pyx_pw_5_yaml_8CEmitter_9open(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  17340. static PyObject *__pyx_pw_5_yaml_8CEmitter_9open(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  17341. PyObject *__pyx_r = 0;
  17342. __Pyx_RefNannyDeclarations
  17343. __Pyx_RefNannySetupContext("open (wrapper)", 0);
  17344. __pyx_r = __pyx_pf_5_yaml_8CEmitter_8open(((struct __pyx_obj_5_yaml_CEmitter *)__pyx_v_self));
  17345. /* function exit code */
  17346. __Pyx_RefNannyFinishContext();
  17347. return __pyx_r;
  17348. }
  17349. static PyObject *__pyx_pf_5_yaml_8CEmitter_8open(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self) {
  17350. yaml_event_t __pyx_v_event;
  17351. yaml_encoding_t __pyx_v_encoding;
  17352. PyObject *__pyx_v_error = NULL;
  17353. PyObject *__pyx_r = NULL;
  17354. __Pyx_RefNannyDeclarations
  17355. int __pyx_t_1;
  17356. int __pyx_t_2;
  17357. int __pyx_t_3;
  17358. PyObject *__pyx_t_4 = NULL;
  17359. PyObject *__pyx_t_5 = NULL;
  17360. PyObject *__pyx_t_6 = NULL;
  17361. __Pyx_RefNannySetupContext("open", 0);
  17362. /* "_yaml.pyx":1245
  17363. * cdef yaml_event_t event
  17364. * cdef yaml_encoding_t encoding
  17365. * if self.closed == -1: # <<<<<<<<<<<<<<
  17366. * if self.use_encoding == u'utf-16-le' or self.use_encoding == 'utf-16-le':
  17367. * encoding = YAML_UTF16LE_ENCODING
  17368. */
  17369. switch (__pyx_v_self->closed) {
  17370. case -1L:
  17371. /* "_yaml.pyx":1246
  17372. * cdef yaml_encoding_t encoding
  17373. * if self.closed == -1:
  17374. * if self.use_encoding == u'utf-16-le' or self.use_encoding == 'utf-16-le': # <<<<<<<<<<<<<<
  17375. * encoding = YAML_UTF16LE_ENCODING
  17376. * elif self.use_encoding == u'utf-16-be' or self.use_encoding == 'utf-16-be':
  17377. */
  17378. __pyx_t_2 = (__Pyx_PyUnicode_Equals(__pyx_v_self->use_encoding, __pyx_kp_u_utf_16_le, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 1246, __pyx_L1_error)
  17379. if (!__pyx_t_2) {
  17380. } else {
  17381. __pyx_t_1 = __pyx_t_2;
  17382. goto __pyx_L4_bool_binop_done;
  17383. }
  17384. __pyx_t_2 = (__Pyx_PyString_Equals(__pyx_v_self->use_encoding, __pyx_kp_s_utf_16_le, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 1246, __pyx_L1_error)
  17385. __pyx_t_1 = __pyx_t_2;
  17386. __pyx_L4_bool_binop_done:;
  17387. if (__pyx_t_1) {
  17388. /* "_yaml.pyx":1247
  17389. * if self.closed == -1:
  17390. * if self.use_encoding == u'utf-16-le' or self.use_encoding == 'utf-16-le':
  17391. * encoding = YAML_UTF16LE_ENCODING # <<<<<<<<<<<<<<
  17392. * elif self.use_encoding == u'utf-16-be' or self.use_encoding == 'utf-16-be':
  17393. * encoding = YAML_UTF16BE_ENCODING
  17394. */
  17395. __pyx_v_encoding = YAML_UTF16LE_ENCODING;
  17396. /* "_yaml.pyx":1246
  17397. * cdef yaml_encoding_t encoding
  17398. * if self.closed == -1:
  17399. * if self.use_encoding == u'utf-16-le' or self.use_encoding == 'utf-16-le': # <<<<<<<<<<<<<<
  17400. * encoding = YAML_UTF16LE_ENCODING
  17401. * elif self.use_encoding == u'utf-16-be' or self.use_encoding == 'utf-16-be':
  17402. */
  17403. goto __pyx_L3;
  17404. }
  17405. /* "_yaml.pyx":1248
  17406. * if self.use_encoding == u'utf-16-le' or self.use_encoding == 'utf-16-le':
  17407. * encoding = YAML_UTF16LE_ENCODING
  17408. * elif self.use_encoding == u'utf-16-be' or self.use_encoding == 'utf-16-be': # <<<<<<<<<<<<<<
  17409. * encoding = YAML_UTF16BE_ENCODING
  17410. * else:
  17411. */
  17412. __pyx_t_2 = (__Pyx_PyUnicode_Equals(__pyx_v_self->use_encoding, __pyx_kp_u_utf_16_be, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 1248, __pyx_L1_error)
  17413. if (!__pyx_t_2) {
  17414. } else {
  17415. __pyx_t_1 = __pyx_t_2;
  17416. goto __pyx_L6_bool_binop_done;
  17417. }
  17418. __pyx_t_2 = (__Pyx_PyString_Equals(__pyx_v_self->use_encoding, __pyx_kp_s_utf_16_be, Py_EQ)); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 1248, __pyx_L1_error)
  17419. __pyx_t_1 = __pyx_t_2;
  17420. __pyx_L6_bool_binop_done:;
  17421. if (__pyx_t_1) {
  17422. /* "_yaml.pyx":1249
  17423. * encoding = YAML_UTF16LE_ENCODING
  17424. * elif self.use_encoding == u'utf-16-be' or self.use_encoding == 'utf-16-be':
  17425. * encoding = YAML_UTF16BE_ENCODING # <<<<<<<<<<<<<<
  17426. * else:
  17427. * encoding = YAML_UTF8_ENCODING
  17428. */
  17429. __pyx_v_encoding = YAML_UTF16BE_ENCODING;
  17430. /* "_yaml.pyx":1248
  17431. * if self.use_encoding == u'utf-16-le' or self.use_encoding == 'utf-16-le':
  17432. * encoding = YAML_UTF16LE_ENCODING
  17433. * elif self.use_encoding == u'utf-16-be' or self.use_encoding == 'utf-16-be': # <<<<<<<<<<<<<<
  17434. * encoding = YAML_UTF16BE_ENCODING
  17435. * else:
  17436. */
  17437. goto __pyx_L3;
  17438. }
  17439. /* "_yaml.pyx":1251
  17440. * encoding = YAML_UTF16BE_ENCODING
  17441. * else:
  17442. * encoding = YAML_UTF8_ENCODING # <<<<<<<<<<<<<<
  17443. * if self.use_encoding is None:
  17444. * self.dump_unicode = 1
  17445. */
  17446. /*else*/ {
  17447. __pyx_v_encoding = YAML_UTF8_ENCODING;
  17448. }
  17449. __pyx_L3:;
  17450. /* "_yaml.pyx":1252
  17451. * else:
  17452. * encoding = YAML_UTF8_ENCODING
  17453. * if self.use_encoding is None: # <<<<<<<<<<<<<<
  17454. * self.dump_unicode = 1
  17455. * if self.dump_unicode == 1:
  17456. */
  17457. __pyx_t_1 = (__pyx_v_self->use_encoding == Py_None);
  17458. __pyx_t_2 = (__pyx_t_1 != 0);
  17459. if (__pyx_t_2) {
  17460. /* "_yaml.pyx":1253
  17461. * encoding = YAML_UTF8_ENCODING
  17462. * if self.use_encoding is None:
  17463. * self.dump_unicode = 1 # <<<<<<<<<<<<<<
  17464. * if self.dump_unicode == 1:
  17465. * encoding = YAML_UTF8_ENCODING
  17466. */
  17467. __pyx_v_self->dump_unicode = 1;
  17468. /* "_yaml.pyx":1252
  17469. * else:
  17470. * encoding = YAML_UTF8_ENCODING
  17471. * if self.use_encoding is None: # <<<<<<<<<<<<<<
  17472. * self.dump_unicode = 1
  17473. * if self.dump_unicode == 1:
  17474. */
  17475. }
  17476. /* "_yaml.pyx":1254
  17477. * if self.use_encoding is None:
  17478. * self.dump_unicode = 1
  17479. * if self.dump_unicode == 1: # <<<<<<<<<<<<<<
  17480. * encoding = YAML_UTF8_ENCODING
  17481. * yaml_stream_start_event_initialize(&event, encoding)
  17482. */
  17483. __pyx_t_2 = ((__pyx_v_self->dump_unicode == 1) != 0);
  17484. if (__pyx_t_2) {
  17485. /* "_yaml.pyx":1255
  17486. * self.dump_unicode = 1
  17487. * if self.dump_unicode == 1:
  17488. * encoding = YAML_UTF8_ENCODING # <<<<<<<<<<<<<<
  17489. * yaml_stream_start_event_initialize(&event, encoding)
  17490. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  17491. */
  17492. __pyx_v_encoding = YAML_UTF8_ENCODING;
  17493. /* "_yaml.pyx":1254
  17494. * if self.use_encoding is None:
  17495. * self.dump_unicode = 1
  17496. * if self.dump_unicode == 1: # <<<<<<<<<<<<<<
  17497. * encoding = YAML_UTF8_ENCODING
  17498. * yaml_stream_start_event_initialize(&event, encoding)
  17499. */
  17500. }
  17501. /* "_yaml.pyx":1256
  17502. * if self.dump_unicode == 1:
  17503. * encoding = YAML_UTF8_ENCODING
  17504. * yaml_stream_start_event_initialize(&event, encoding) # <<<<<<<<<<<<<<
  17505. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  17506. * error = self._emitter_error()
  17507. */
  17508. (void)(yaml_stream_start_event_initialize((&__pyx_v_event), __pyx_v_encoding));
  17509. /* "_yaml.pyx":1257
  17510. * encoding = YAML_UTF8_ENCODING
  17511. * yaml_stream_start_event_initialize(&event, encoding)
  17512. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  17513. * error = self._emitter_error()
  17514. * raise error
  17515. */
  17516. __pyx_t_3 = yaml_emitter_emit((&__pyx_v_self->emitter), (&__pyx_v_event)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 1257, __pyx_L1_error)
  17517. __pyx_t_2 = ((__pyx_t_3 == 0) != 0);
  17518. if (unlikely(__pyx_t_2)) {
  17519. /* "_yaml.pyx":1258
  17520. * yaml_stream_start_event_initialize(&event, encoding)
  17521. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  17522. * error = self._emitter_error() # <<<<<<<<<<<<<<
  17523. * raise error
  17524. * self.closed = 0
  17525. */
  17526. __pyx_t_4 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_emitter_error(__pyx_v_self); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1258, __pyx_L1_error)
  17527. __Pyx_GOTREF(__pyx_t_4);
  17528. __pyx_v_error = __pyx_t_4;
  17529. __pyx_t_4 = 0;
  17530. /* "_yaml.pyx":1259
  17531. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  17532. * error = self._emitter_error()
  17533. * raise error # <<<<<<<<<<<<<<
  17534. * self.closed = 0
  17535. * elif self.closed == 1:
  17536. */
  17537. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  17538. __PYX_ERR(0, 1259, __pyx_L1_error)
  17539. /* "_yaml.pyx":1257
  17540. * encoding = YAML_UTF8_ENCODING
  17541. * yaml_stream_start_event_initialize(&event, encoding)
  17542. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  17543. * error = self._emitter_error()
  17544. * raise error
  17545. */
  17546. }
  17547. /* "_yaml.pyx":1260
  17548. * error = self._emitter_error()
  17549. * raise error
  17550. * self.closed = 0 # <<<<<<<<<<<<<<
  17551. * elif self.closed == 1:
  17552. * if PY_MAJOR_VERSION < 3:
  17553. */
  17554. __pyx_v_self->closed = 0;
  17555. /* "_yaml.pyx":1245
  17556. * cdef yaml_event_t event
  17557. * cdef yaml_encoding_t encoding
  17558. * if self.closed == -1: # <<<<<<<<<<<<<<
  17559. * if self.use_encoding == u'utf-16-le' or self.use_encoding == 'utf-16-le':
  17560. * encoding = YAML_UTF16LE_ENCODING
  17561. */
  17562. break;
  17563. case 1:
  17564. /* "_yaml.pyx":1262
  17565. * self.closed = 0
  17566. * elif self.closed == 1:
  17567. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  17568. * raise SerializerError("serializer is closed")
  17569. * else:
  17570. */
  17571. __pyx_t_2 = ((PY_MAJOR_VERSION < 3) != 0);
  17572. if (unlikely(__pyx_t_2)) {
  17573. /* "_yaml.pyx":1263
  17574. * elif self.closed == 1:
  17575. * if PY_MAJOR_VERSION < 3:
  17576. * raise SerializerError("serializer is closed") # <<<<<<<<<<<<<<
  17577. * else:
  17578. * raise SerializerError(u"serializer is closed")
  17579. */
  17580. __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_SerializerError); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1263, __pyx_L1_error)
  17581. __Pyx_GOTREF(__pyx_t_5);
  17582. __pyx_t_6 = NULL;
  17583. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) {
  17584. __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5);
  17585. if (likely(__pyx_t_6)) {
  17586. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5);
  17587. __Pyx_INCREF(__pyx_t_6);
  17588. __Pyx_INCREF(function);
  17589. __Pyx_DECREF_SET(__pyx_t_5, function);
  17590. }
  17591. }
  17592. __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_6, __pyx_kp_s_serializer_is_closed) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_kp_s_serializer_is_closed);
  17593. __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
  17594. if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1263, __pyx_L1_error)
  17595. __Pyx_GOTREF(__pyx_t_4);
  17596. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  17597. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  17598. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  17599. __PYX_ERR(0, 1263, __pyx_L1_error)
  17600. /* "_yaml.pyx":1262
  17601. * self.closed = 0
  17602. * elif self.closed == 1:
  17603. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  17604. * raise SerializerError("serializer is closed")
  17605. * else:
  17606. */
  17607. }
  17608. /* "_yaml.pyx":1265
  17609. * raise SerializerError("serializer is closed")
  17610. * else:
  17611. * raise SerializerError(u"serializer is closed") # <<<<<<<<<<<<<<
  17612. * else:
  17613. * if PY_MAJOR_VERSION < 3:
  17614. */
  17615. /*else*/ {
  17616. __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_SerializerError); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1265, __pyx_L1_error)
  17617. __Pyx_GOTREF(__pyx_t_5);
  17618. __pyx_t_6 = NULL;
  17619. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) {
  17620. __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5);
  17621. if (likely(__pyx_t_6)) {
  17622. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5);
  17623. __Pyx_INCREF(__pyx_t_6);
  17624. __Pyx_INCREF(function);
  17625. __Pyx_DECREF_SET(__pyx_t_5, function);
  17626. }
  17627. }
  17628. __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_6, __pyx_kp_u_serializer_is_closed) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_kp_u_serializer_is_closed);
  17629. __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
  17630. if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1265, __pyx_L1_error)
  17631. __Pyx_GOTREF(__pyx_t_4);
  17632. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  17633. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  17634. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  17635. __PYX_ERR(0, 1265, __pyx_L1_error)
  17636. }
  17637. /* "_yaml.pyx":1261
  17638. * raise error
  17639. * self.closed = 0
  17640. * elif self.closed == 1: # <<<<<<<<<<<<<<
  17641. * if PY_MAJOR_VERSION < 3:
  17642. * raise SerializerError("serializer is closed")
  17643. */
  17644. break;
  17645. default:
  17646. /* "_yaml.pyx":1267
  17647. * raise SerializerError(u"serializer is closed")
  17648. * else:
  17649. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  17650. * raise SerializerError("serializer is already opened")
  17651. * else:
  17652. */
  17653. __pyx_t_2 = ((PY_MAJOR_VERSION < 3) != 0);
  17654. if (unlikely(__pyx_t_2)) {
  17655. /* "_yaml.pyx":1268
  17656. * else:
  17657. * if PY_MAJOR_VERSION < 3:
  17658. * raise SerializerError("serializer is already opened") # <<<<<<<<<<<<<<
  17659. * else:
  17660. * raise SerializerError(u"serializer is already opened")
  17661. */
  17662. __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_SerializerError); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1268, __pyx_L1_error)
  17663. __Pyx_GOTREF(__pyx_t_5);
  17664. __pyx_t_6 = NULL;
  17665. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) {
  17666. __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5);
  17667. if (likely(__pyx_t_6)) {
  17668. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5);
  17669. __Pyx_INCREF(__pyx_t_6);
  17670. __Pyx_INCREF(function);
  17671. __Pyx_DECREF_SET(__pyx_t_5, function);
  17672. }
  17673. }
  17674. __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_6, __pyx_kp_s_serializer_is_already_opened) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_kp_s_serializer_is_already_opened);
  17675. __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
  17676. if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1268, __pyx_L1_error)
  17677. __Pyx_GOTREF(__pyx_t_4);
  17678. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  17679. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  17680. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  17681. __PYX_ERR(0, 1268, __pyx_L1_error)
  17682. /* "_yaml.pyx":1267
  17683. * raise SerializerError(u"serializer is closed")
  17684. * else:
  17685. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  17686. * raise SerializerError("serializer is already opened")
  17687. * else:
  17688. */
  17689. }
  17690. /* "_yaml.pyx":1270
  17691. * raise SerializerError("serializer is already opened")
  17692. * else:
  17693. * raise SerializerError(u"serializer is already opened") # <<<<<<<<<<<<<<
  17694. *
  17695. * def close(self):
  17696. */
  17697. /*else*/ {
  17698. __Pyx_GetModuleGlobalName(__pyx_t_5, __pyx_n_s_SerializerError); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1270, __pyx_L1_error)
  17699. __Pyx_GOTREF(__pyx_t_5);
  17700. __pyx_t_6 = NULL;
  17701. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_5))) {
  17702. __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5);
  17703. if (likely(__pyx_t_6)) {
  17704. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5);
  17705. __Pyx_INCREF(__pyx_t_6);
  17706. __Pyx_INCREF(function);
  17707. __Pyx_DECREF_SET(__pyx_t_5, function);
  17708. }
  17709. }
  17710. __pyx_t_4 = (__pyx_t_6) ? __Pyx_PyObject_Call2Args(__pyx_t_5, __pyx_t_6, __pyx_kp_u_serializer_is_already_opened) : __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_kp_u_serializer_is_already_opened);
  17711. __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
  17712. if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1270, __pyx_L1_error)
  17713. __Pyx_GOTREF(__pyx_t_4);
  17714. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  17715. __Pyx_Raise(__pyx_t_4, 0, 0, 0);
  17716. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  17717. __PYX_ERR(0, 1270, __pyx_L1_error)
  17718. }
  17719. break;
  17720. }
  17721. /* "_yaml.pyx":1242
  17722. * raise error
  17723. *
  17724. * def open(self): # <<<<<<<<<<<<<<
  17725. * cdef yaml_event_t event
  17726. * cdef yaml_encoding_t encoding
  17727. */
  17728. /* function exit code */
  17729. __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  17730. goto __pyx_L0;
  17731. __pyx_L1_error:;
  17732. __Pyx_XDECREF(__pyx_t_4);
  17733. __Pyx_XDECREF(__pyx_t_5);
  17734. __Pyx_XDECREF(__pyx_t_6);
  17735. __Pyx_AddTraceback("_yaml.CEmitter.open", __pyx_clineno, __pyx_lineno, __pyx_filename);
  17736. __pyx_r = NULL;
  17737. __pyx_L0:;
  17738. __Pyx_XDECREF(__pyx_v_error);
  17739. __Pyx_XGIVEREF(__pyx_r);
  17740. __Pyx_RefNannyFinishContext();
  17741. return __pyx_r;
  17742. }
  17743. /* "_yaml.pyx":1272
  17744. * raise SerializerError(u"serializer is already opened")
  17745. *
  17746. * def close(self): # <<<<<<<<<<<<<<
  17747. * cdef yaml_event_t event
  17748. * if self.closed == -1:
  17749. */
  17750. /* Python wrapper */
  17751. static PyObject *__pyx_pw_5_yaml_8CEmitter_11close(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  17752. static PyObject *__pyx_pw_5_yaml_8CEmitter_11close(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  17753. PyObject *__pyx_r = 0;
  17754. __Pyx_RefNannyDeclarations
  17755. __Pyx_RefNannySetupContext("close (wrapper)", 0);
  17756. __pyx_r = __pyx_pf_5_yaml_8CEmitter_10close(((struct __pyx_obj_5_yaml_CEmitter *)__pyx_v_self));
  17757. /* function exit code */
  17758. __Pyx_RefNannyFinishContext();
  17759. return __pyx_r;
  17760. }
  17761. static PyObject *__pyx_pf_5_yaml_8CEmitter_10close(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self) {
  17762. yaml_event_t __pyx_v_event;
  17763. PyObject *__pyx_v_error = NULL;
  17764. PyObject *__pyx_r = NULL;
  17765. __Pyx_RefNannyDeclarations
  17766. int __pyx_t_1;
  17767. PyObject *__pyx_t_2 = NULL;
  17768. PyObject *__pyx_t_3 = NULL;
  17769. PyObject *__pyx_t_4 = NULL;
  17770. int __pyx_t_5;
  17771. __Pyx_RefNannySetupContext("close", 0);
  17772. /* "_yaml.pyx":1274
  17773. * def close(self):
  17774. * cdef yaml_event_t event
  17775. * if self.closed == -1: # <<<<<<<<<<<<<<
  17776. * if PY_MAJOR_VERSION < 3:
  17777. * raise SerializerError("serializer is not opened")
  17778. */
  17779. switch (__pyx_v_self->closed) {
  17780. case -1L:
  17781. /* "_yaml.pyx":1275
  17782. * cdef yaml_event_t event
  17783. * if self.closed == -1:
  17784. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  17785. * raise SerializerError("serializer is not opened")
  17786. * else:
  17787. */
  17788. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  17789. if (unlikely(__pyx_t_1)) {
  17790. /* "_yaml.pyx":1276
  17791. * if self.closed == -1:
  17792. * if PY_MAJOR_VERSION < 3:
  17793. * raise SerializerError("serializer is not opened") # <<<<<<<<<<<<<<
  17794. * else:
  17795. * raise SerializerError(u"serializer is not opened")
  17796. */
  17797. __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_SerializerError); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1276, __pyx_L1_error)
  17798. __Pyx_GOTREF(__pyx_t_3);
  17799. __pyx_t_4 = NULL;
  17800. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
  17801. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
  17802. if (likely(__pyx_t_4)) {
  17803. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
  17804. __Pyx_INCREF(__pyx_t_4);
  17805. __Pyx_INCREF(function);
  17806. __Pyx_DECREF_SET(__pyx_t_3, function);
  17807. }
  17808. }
  17809. __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_kp_s_serializer_is_not_opened) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_kp_s_serializer_is_not_opened);
  17810. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  17811. if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1276, __pyx_L1_error)
  17812. __Pyx_GOTREF(__pyx_t_2);
  17813. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  17814. __Pyx_Raise(__pyx_t_2, 0, 0, 0);
  17815. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  17816. __PYX_ERR(0, 1276, __pyx_L1_error)
  17817. /* "_yaml.pyx":1275
  17818. * cdef yaml_event_t event
  17819. * if self.closed == -1:
  17820. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  17821. * raise SerializerError("serializer is not opened")
  17822. * else:
  17823. */
  17824. }
  17825. /* "_yaml.pyx":1278
  17826. * raise SerializerError("serializer is not opened")
  17827. * else:
  17828. * raise SerializerError(u"serializer is not opened") # <<<<<<<<<<<<<<
  17829. * elif self.closed == 0:
  17830. * yaml_stream_end_event_initialize(&event)
  17831. */
  17832. /*else*/ {
  17833. __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_SerializerError); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1278, __pyx_L1_error)
  17834. __Pyx_GOTREF(__pyx_t_3);
  17835. __pyx_t_4 = NULL;
  17836. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
  17837. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
  17838. if (likely(__pyx_t_4)) {
  17839. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
  17840. __Pyx_INCREF(__pyx_t_4);
  17841. __Pyx_INCREF(function);
  17842. __Pyx_DECREF_SET(__pyx_t_3, function);
  17843. }
  17844. }
  17845. __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_kp_u_serializer_is_not_opened) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_kp_u_serializer_is_not_opened);
  17846. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  17847. if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1278, __pyx_L1_error)
  17848. __Pyx_GOTREF(__pyx_t_2);
  17849. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  17850. __Pyx_Raise(__pyx_t_2, 0, 0, 0);
  17851. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  17852. __PYX_ERR(0, 1278, __pyx_L1_error)
  17853. }
  17854. /* "_yaml.pyx":1274
  17855. * def close(self):
  17856. * cdef yaml_event_t event
  17857. * if self.closed == -1: # <<<<<<<<<<<<<<
  17858. * if PY_MAJOR_VERSION < 3:
  17859. * raise SerializerError("serializer is not opened")
  17860. */
  17861. break;
  17862. case 0:
  17863. /* "_yaml.pyx":1280
  17864. * raise SerializerError(u"serializer is not opened")
  17865. * elif self.closed == 0:
  17866. * yaml_stream_end_event_initialize(&event) # <<<<<<<<<<<<<<
  17867. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  17868. * error = self._emitter_error()
  17869. */
  17870. (void)(yaml_stream_end_event_initialize((&__pyx_v_event)));
  17871. /* "_yaml.pyx":1281
  17872. * elif self.closed == 0:
  17873. * yaml_stream_end_event_initialize(&event)
  17874. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  17875. * error = self._emitter_error()
  17876. * raise error
  17877. */
  17878. __pyx_t_5 = yaml_emitter_emit((&__pyx_v_self->emitter), (&__pyx_v_event)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 1281, __pyx_L1_error)
  17879. __pyx_t_1 = ((__pyx_t_5 == 0) != 0);
  17880. if (unlikely(__pyx_t_1)) {
  17881. /* "_yaml.pyx":1282
  17882. * yaml_stream_end_event_initialize(&event)
  17883. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  17884. * error = self._emitter_error() # <<<<<<<<<<<<<<
  17885. * raise error
  17886. * self.closed = 1
  17887. */
  17888. __pyx_t_2 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_emitter_error(__pyx_v_self); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1282, __pyx_L1_error)
  17889. __Pyx_GOTREF(__pyx_t_2);
  17890. __pyx_v_error = __pyx_t_2;
  17891. __pyx_t_2 = 0;
  17892. /* "_yaml.pyx":1283
  17893. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  17894. * error = self._emitter_error()
  17895. * raise error # <<<<<<<<<<<<<<
  17896. * self.closed = 1
  17897. *
  17898. */
  17899. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  17900. __PYX_ERR(0, 1283, __pyx_L1_error)
  17901. /* "_yaml.pyx":1281
  17902. * elif self.closed == 0:
  17903. * yaml_stream_end_event_initialize(&event)
  17904. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  17905. * error = self._emitter_error()
  17906. * raise error
  17907. */
  17908. }
  17909. /* "_yaml.pyx":1284
  17910. * error = self._emitter_error()
  17911. * raise error
  17912. * self.closed = 1 # <<<<<<<<<<<<<<
  17913. *
  17914. * def serialize(self, node):
  17915. */
  17916. __pyx_v_self->closed = 1;
  17917. /* "_yaml.pyx":1279
  17918. * else:
  17919. * raise SerializerError(u"serializer is not opened")
  17920. * elif self.closed == 0: # <<<<<<<<<<<<<<
  17921. * yaml_stream_end_event_initialize(&event)
  17922. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  17923. */
  17924. break;
  17925. default: break;
  17926. }
  17927. /* "_yaml.pyx":1272
  17928. * raise SerializerError(u"serializer is already opened")
  17929. *
  17930. * def close(self): # <<<<<<<<<<<<<<
  17931. * cdef yaml_event_t event
  17932. * if self.closed == -1:
  17933. */
  17934. /* function exit code */
  17935. __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  17936. goto __pyx_L0;
  17937. __pyx_L1_error:;
  17938. __Pyx_XDECREF(__pyx_t_2);
  17939. __Pyx_XDECREF(__pyx_t_3);
  17940. __Pyx_XDECREF(__pyx_t_4);
  17941. __Pyx_AddTraceback("_yaml.CEmitter.close", __pyx_clineno, __pyx_lineno, __pyx_filename);
  17942. __pyx_r = NULL;
  17943. __pyx_L0:;
  17944. __Pyx_XDECREF(__pyx_v_error);
  17945. __Pyx_XGIVEREF(__pyx_r);
  17946. __Pyx_RefNannyFinishContext();
  17947. return __pyx_r;
  17948. }
  17949. /* "_yaml.pyx":1286
  17950. * self.closed = 1
  17951. *
  17952. * def serialize(self, node): # <<<<<<<<<<<<<<
  17953. * cdef yaml_event_t event
  17954. * cdef yaml_version_directive_t version_directive_value
  17955. */
  17956. /* Python wrapper */
  17957. static PyObject *__pyx_pw_5_yaml_8CEmitter_13serialize(PyObject *__pyx_v_self, PyObject *__pyx_v_node); /*proto*/
  17958. static PyObject *__pyx_pw_5_yaml_8CEmitter_13serialize(PyObject *__pyx_v_self, PyObject *__pyx_v_node) {
  17959. PyObject *__pyx_r = 0;
  17960. __Pyx_RefNannyDeclarations
  17961. __Pyx_RefNannySetupContext("serialize (wrapper)", 0);
  17962. __pyx_r = __pyx_pf_5_yaml_8CEmitter_12serialize(((struct __pyx_obj_5_yaml_CEmitter *)__pyx_v_self), ((PyObject *)__pyx_v_node));
  17963. /* function exit code */
  17964. __Pyx_RefNannyFinishContext();
  17965. return __pyx_r;
  17966. }
  17967. static PyObject *__pyx_pf_5_yaml_8CEmitter_12serialize(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self, PyObject *__pyx_v_node) {
  17968. yaml_event_t __pyx_v_event;
  17969. yaml_version_directive_t __pyx_v_version_directive_value;
  17970. yaml_version_directive_t *__pyx_v_version_directive;
  17971. yaml_tag_directive_t __pyx_v_tag_directives_value[0x80];
  17972. yaml_tag_directive_t *__pyx_v_tag_directives_start;
  17973. yaml_tag_directive_t *__pyx_v_tag_directives_end;
  17974. PyObject *__pyx_v_cache = NULL;
  17975. PyObject *__pyx_v_handle = NULL;
  17976. PyObject *__pyx_v_prefix = NULL;
  17977. PyObject *__pyx_v_error = NULL;
  17978. PyObject *__pyx_r = NULL;
  17979. __Pyx_RefNannyDeclarations
  17980. int __pyx_t_1;
  17981. PyObject *__pyx_t_2 = NULL;
  17982. PyObject *__pyx_t_3 = NULL;
  17983. PyObject *__pyx_t_4 = NULL;
  17984. int __pyx_t_5;
  17985. Py_ssize_t __pyx_t_6;
  17986. PyObject *(*__pyx_t_7)(PyObject *);
  17987. int __pyx_t_8;
  17988. __Pyx_RefNannySetupContext("serialize", 0);
  17989. /* "_yaml.pyx":1293
  17990. * cdef yaml_tag_directive_t *tag_directives_start
  17991. * cdef yaml_tag_directive_t *tag_directives_end
  17992. * if self.closed == -1: # <<<<<<<<<<<<<<
  17993. * if PY_MAJOR_VERSION < 3:
  17994. * raise SerializerError("serializer is not opened")
  17995. */
  17996. switch (__pyx_v_self->closed) {
  17997. case -1L:
  17998. /* "_yaml.pyx":1294
  17999. * cdef yaml_tag_directive_t *tag_directives_end
  18000. * if self.closed == -1:
  18001. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  18002. * raise SerializerError("serializer is not opened")
  18003. * else:
  18004. */
  18005. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  18006. if (unlikely(__pyx_t_1)) {
  18007. /* "_yaml.pyx":1295
  18008. * if self.closed == -1:
  18009. * if PY_MAJOR_VERSION < 3:
  18010. * raise SerializerError("serializer is not opened") # <<<<<<<<<<<<<<
  18011. * else:
  18012. * raise SerializerError(u"serializer is not opened")
  18013. */
  18014. __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_SerializerError); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1295, __pyx_L1_error)
  18015. __Pyx_GOTREF(__pyx_t_3);
  18016. __pyx_t_4 = NULL;
  18017. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
  18018. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
  18019. if (likely(__pyx_t_4)) {
  18020. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
  18021. __Pyx_INCREF(__pyx_t_4);
  18022. __Pyx_INCREF(function);
  18023. __Pyx_DECREF_SET(__pyx_t_3, function);
  18024. }
  18025. }
  18026. __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_kp_s_serializer_is_not_opened) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_kp_s_serializer_is_not_opened);
  18027. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  18028. if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1295, __pyx_L1_error)
  18029. __Pyx_GOTREF(__pyx_t_2);
  18030. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  18031. __Pyx_Raise(__pyx_t_2, 0, 0, 0);
  18032. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  18033. __PYX_ERR(0, 1295, __pyx_L1_error)
  18034. /* "_yaml.pyx":1294
  18035. * cdef yaml_tag_directive_t *tag_directives_end
  18036. * if self.closed == -1:
  18037. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  18038. * raise SerializerError("serializer is not opened")
  18039. * else:
  18040. */
  18041. }
  18042. /* "_yaml.pyx":1297
  18043. * raise SerializerError("serializer is not opened")
  18044. * else:
  18045. * raise SerializerError(u"serializer is not opened") # <<<<<<<<<<<<<<
  18046. * elif self.closed == 1:
  18047. * if PY_MAJOR_VERSION < 3:
  18048. */
  18049. /*else*/ {
  18050. __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_SerializerError); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1297, __pyx_L1_error)
  18051. __Pyx_GOTREF(__pyx_t_3);
  18052. __pyx_t_4 = NULL;
  18053. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
  18054. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
  18055. if (likely(__pyx_t_4)) {
  18056. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
  18057. __Pyx_INCREF(__pyx_t_4);
  18058. __Pyx_INCREF(function);
  18059. __Pyx_DECREF_SET(__pyx_t_3, function);
  18060. }
  18061. }
  18062. __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_kp_u_serializer_is_not_opened) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_kp_u_serializer_is_not_opened);
  18063. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  18064. if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1297, __pyx_L1_error)
  18065. __Pyx_GOTREF(__pyx_t_2);
  18066. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  18067. __Pyx_Raise(__pyx_t_2, 0, 0, 0);
  18068. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  18069. __PYX_ERR(0, 1297, __pyx_L1_error)
  18070. }
  18071. /* "_yaml.pyx":1293
  18072. * cdef yaml_tag_directive_t *tag_directives_start
  18073. * cdef yaml_tag_directive_t *tag_directives_end
  18074. * if self.closed == -1: # <<<<<<<<<<<<<<
  18075. * if PY_MAJOR_VERSION < 3:
  18076. * raise SerializerError("serializer is not opened")
  18077. */
  18078. break;
  18079. case 1:
  18080. /* "_yaml.pyx":1299
  18081. * raise SerializerError(u"serializer is not opened")
  18082. * elif self.closed == 1:
  18083. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  18084. * raise SerializerError("serializer is closed")
  18085. * else:
  18086. */
  18087. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  18088. if (unlikely(__pyx_t_1)) {
  18089. /* "_yaml.pyx":1300
  18090. * elif self.closed == 1:
  18091. * if PY_MAJOR_VERSION < 3:
  18092. * raise SerializerError("serializer is closed") # <<<<<<<<<<<<<<
  18093. * else:
  18094. * raise SerializerError(u"serializer is closed")
  18095. */
  18096. __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_SerializerError); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1300, __pyx_L1_error)
  18097. __Pyx_GOTREF(__pyx_t_3);
  18098. __pyx_t_4 = NULL;
  18099. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
  18100. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
  18101. if (likely(__pyx_t_4)) {
  18102. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
  18103. __Pyx_INCREF(__pyx_t_4);
  18104. __Pyx_INCREF(function);
  18105. __Pyx_DECREF_SET(__pyx_t_3, function);
  18106. }
  18107. }
  18108. __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_kp_s_serializer_is_closed) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_kp_s_serializer_is_closed);
  18109. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  18110. if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1300, __pyx_L1_error)
  18111. __Pyx_GOTREF(__pyx_t_2);
  18112. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  18113. __Pyx_Raise(__pyx_t_2, 0, 0, 0);
  18114. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  18115. __PYX_ERR(0, 1300, __pyx_L1_error)
  18116. /* "_yaml.pyx":1299
  18117. * raise SerializerError(u"serializer is not opened")
  18118. * elif self.closed == 1:
  18119. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  18120. * raise SerializerError("serializer is closed")
  18121. * else:
  18122. */
  18123. }
  18124. /* "_yaml.pyx":1302
  18125. * raise SerializerError("serializer is closed")
  18126. * else:
  18127. * raise SerializerError(u"serializer is closed") # <<<<<<<<<<<<<<
  18128. * cache = []
  18129. * version_directive = NULL
  18130. */
  18131. /*else*/ {
  18132. __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_SerializerError); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1302, __pyx_L1_error)
  18133. __Pyx_GOTREF(__pyx_t_3);
  18134. __pyx_t_4 = NULL;
  18135. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_3))) {
  18136. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
  18137. if (likely(__pyx_t_4)) {
  18138. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
  18139. __Pyx_INCREF(__pyx_t_4);
  18140. __Pyx_INCREF(function);
  18141. __Pyx_DECREF_SET(__pyx_t_3, function);
  18142. }
  18143. }
  18144. __pyx_t_2 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_kp_u_serializer_is_closed) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_kp_u_serializer_is_closed);
  18145. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  18146. if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1302, __pyx_L1_error)
  18147. __Pyx_GOTREF(__pyx_t_2);
  18148. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  18149. __Pyx_Raise(__pyx_t_2, 0, 0, 0);
  18150. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  18151. __PYX_ERR(0, 1302, __pyx_L1_error)
  18152. }
  18153. /* "_yaml.pyx":1298
  18154. * else:
  18155. * raise SerializerError(u"serializer is not opened")
  18156. * elif self.closed == 1: # <<<<<<<<<<<<<<
  18157. * if PY_MAJOR_VERSION < 3:
  18158. * raise SerializerError("serializer is closed")
  18159. */
  18160. break;
  18161. default: break;
  18162. }
  18163. /* "_yaml.pyx":1303
  18164. * else:
  18165. * raise SerializerError(u"serializer is closed")
  18166. * cache = [] # <<<<<<<<<<<<<<
  18167. * version_directive = NULL
  18168. * if self.use_version:
  18169. */
  18170. __pyx_t_2 = PyList_New(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1303, __pyx_L1_error)
  18171. __Pyx_GOTREF(__pyx_t_2);
  18172. __pyx_v_cache = ((PyObject*)__pyx_t_2);
  18173. __pyx_t_2 = 0;
  18174. /* "_yaml.pyx":1304
  18175. * raise SerializerError(u"serializer is closed")
  18176. * cache = []
  18177. * version_directive = NULL # <<<<<<<<<<<<<<
  18178. * if self.use_version:
  18179. * version_directive_value.major = self.use_version[0]
  18180. */
  18181. __pyx_v_version_directive = NULL;
  18182. /* "_yaml.pyx":1305
  18183. * cache = []
  18184. * version_directive = NULL
  18185. * if self.use_version: # <<<<<<<<<<<<<<
  18186. * version_directive_value.major = self.use_version[0]
  18187. * version_directive_value.minor = self.use_version[1]
  18188. */
  18189. __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_self->use_version); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 1305, __pyx_L1_error)
  18190. if (__pyx_t_1) {
  18191. /* "_yaml.pyx":1306
  18192. * version_directive = NULL
  18193. * if self.use_version:
  18194. * version_directive_value.major = self.use_version[0] # <<<<<<<<<<<<<<
  18195. * version_directive_value.minor = self.use_version[1]
  18196. * version_directive = &version_directive_value
  18197. */
  18198. __pyx_t_2 = __Pyx_GetItemInt(__pyx_v_self->use_version, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1306, __pyx_L1_error)
  18199. __Pyx_GOTREF(__pyx_t_2);
  18200. __pyx_t_5 = __Pyx_PyInt_As_int(__pyx_t_2); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 1306, __pyx_L1_error)
  18201. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  18202. __pyx_v_version_directive_value.major = __pyx_t_5;
  18203. /* "_yaml.pyx":1307
  18204. * if self.use_version:
  18205. * version_directive_value.major = self.use_version[0]
  18206. * version_directive_value.minor = self.use_version[1] # <<<<<<<<<<<<<<
  18207. * version_directive = &version_directive_value
  18208. * tag_directives_start = NULL
  18209. */
  18210. __pyx_t_2 = __Pyx_GetItemInt(__pyx_v_self->use_version, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1307, __pyx_L1_error)
  18211. __Pyx_GOTREF(__pyx_t_2);
  18212. __pyx_t_5 = __Pyx_PyInt_As_int(__pyx_t_2); if (unlikely((__pyx_t_5 == (int)-1) && PyErr_Occurred())) __PYX_ERR(0, 1307, __pyx_L1_error)
  18213. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  18214. __pyx_v_version_directive_value.minor = __pyx_t_5;
  18215. /* "_yaml.pyx":1308
  18216. * version_directive_value.major = self.use_version[0]
  18217. * version_directive_value.minor = self.use_version[1]
  18218. * version_directive = &version_directive_value # <<<<<<<<<<<<<<
  18219. * tag_directives_start = NULL
  18220. * tag_directives_end = NULL
  18221. */
  18222. __pyx_v_version_directive = (&__pyx_v_version_directive_value);
  18223. /* "_yaml.pyx":1305
  18224. * cache = []
  18225. * version_directive = NULL
  18226. * if self.use_version: # <<<<<<<<<<<<<<
  18227. * version_directive_value.major = self.use_version[0]
  18228. * version_directive_value.minor = self.use_version[1]
  18229. */
  18230. }
  18231. /* "_yaml.pyx":1309
  18232. * version_directive_value.minor = self.use_version[1]
  18233. * version_directive = &version_directive_value
  18234. * tag_directives_start = NULL # <<<<<<<<<<<<<<
  18235. * tag_directives_end = NULL
  18236. * if self.use_tags:
  18237. */
  18238. __pyx_v_tag_directives_start = NULL;
  18239. /* "_yaml.pyx":1310
  18240. * version_directive = &version_directive_value
  18241. * tag_directives_start = NULL
  18242. * tag_directives_end = NULL # <<<<<<<<<<<<<<
  18243. * if self.use_tags:
  18244. * if len(self.use_tags) > 128:
  18245. */
  18246. __pyx_v_tag_directives_end = NULL;
  18247. /* "_yaml.pyx":1311
  18248. * tag_directives_start = NULL
  18249. * tag_directives_end = NULL
  18250. * if self.use_tags: # <<<<<<<<<<<<<<
  18251. * if len(self.use_tags) > 128:
  18252. * if PY_MAJOR_VERSION < 3:
  18253. */
  18254. __pyx_t_1 = __Pyx_PyObject_IsTrue(__pyx_v_self->use_tags); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 1311, __pyx_L1_error)
  18255. if (__pyx_t_1) {
  18256. /* "_yaml.pyx":1312
  18257. * tag_directives_end = NULL
  18258. * if self.use_tags:
  18259. * if len(self.use_tags) > 128: # <<<<<<<<<<<<<<
  18260. * if PY_MAJOR_VERSION < 3:
  18261. * raise ValueError("too many tags")
  18262. */
  18263. __pyx_t_2 = __pyx_v_self->use_tags;
  18264. __Pyx_INCREF(__pyx_t_2);
  18265. __pyx_t_6 = PyObject_Length(__pyx_t_2); if (unlikely(__pyx_t_6 == ((Py_ssize_t)-1))) __PYX_ERR(0, 1312, __pyx_L1_error)
  18266. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  18267. __pyx_t_1 = ((__pyx_t_6 > 0x80) != 0);
  18268. if (__pyx_t_1) {
  18269. /* "_yaml.pyx":1313
  18270. * if self.use_tags:
  18271. * if len(self.use_tags) > 128:
  18272. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  18273. * raise ValueError("too many tags")
  18274. * else:
  18275. */
  18276. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  18277. if (unlikely(__pyx_t_1)) {
  18278. /* "_yaml.pyx":1314
  18279. * if len(self.use_tags) > 128:
  18280. * if PY_MAJOR_VERSION < 3:
  18281. * raise ValueError("too many tags") # <<<<<<<<<<<<<<
  18282. * else:
  18283. * raise ValueError(u"too many tags")
  18284. */
  18285. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__24, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1314, __pyx_L1_error)
  18286. __Pyx_GOTREF(__pyx_t_2);
  18287. __Pyx_Raise(__pyx_t_2, 0, 0, 0);
  18288. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  18289. __PYX_ERR(0, 1314, __pyx_L1_error)
  18290. /* "_yaml.pyx":1313
  18291. * if self.use_tags:
  18292. * if len(self.use_tags) > 128:
  18293. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  18294. * raise ValueError("too many tags")
  18295. * else:
  18296. */
  18297. }
  18298. /* "_yaml.pyx":1316
  18299. * raise ValueError("too many tags")
  18300. * else:
  18301. * raise ValueError(u"too many tags") # <<<<<<<<<<<<<<
  18302. * tag_directives_start = tag_directives_value
  18303. * tag_directives_end = tag_directives_value
  18304. */
  18305. /*else*/ {
  18306. __pyx_t_2 = __Pyx_PyObject_Call(__pyx_builtin_ValueError, __pyx_tuple__25, NULL); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1316, __pyx_L1_error)
  18307. __Pyx_GOTREF(__pyx_t_2);
  18308. __Pyx_Raise(__pyx_t_2, 0, 0, 0);
  18309. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  18310. __PYX_ERR(0, 1316, __pyx_L1_error)
  18311. }
  18312. /* "_yaml.pyx":1312
  18313. * tag_directives_end = NULL
  18314. * if self.use_tags:
  18315. * if len(self.use_tags) > 128: # <<<<<<<<<<<<<<
  18316. * if PY_MAJOR_VERSION < 3:
  18317. * raise ValueError("too many tags")
  18318. */
  18319. }
  18320. /* "_yaml.pyx":1317
  18321. * else:
  18322. * raise ValueError(u"too many tags")
  18323. * tag_directives_start = tag_directives_value # <<<<<<<<<<<<<<
  18324. * tag_directives_end = tag_directives_value
  18325. * for handle in self.use_tags:
  18326. */
  18327. __pyx_v_tag_directives_start = __pyx_v_tag_directives_value;
  18328. /* "_yaml.pyx":1318
  18329. * raise ValueError(u"too many tags")
  18330. * tag_directives_start = tag_directives_value
  18331. * tag_directives_end = tag_directives_value # <<<<<<<<<<<<<<
  18332. * for handle in self.use_tags:
  18333. * prefix = self.use_tags[handle]
  18334. */
  18335. __pyx_v_tag_directives_end = __pyx_v_tag_directives_value;
  18336. /* "_yaml.pyx":1319
  18337. * tag_directives_start = tag_directives_value
  18338. * tag_directives_end = tag_directives_value
  18339. * for handle in self.use_tags: # <<<<<<<<<<<<<<
  18340. * prefix = self.use_tags[handle]
  18341. * if PyUnicode_CheckExact(handle):
  18342. */
  18343. if (likely(PyList_CheckExact(__pyx_v_self->use_tags)) || PyTuple_CheckExact(__pyx_v_self->use_tags)) {
  18344. __pyx_t_2 = __pyx_v_self->use_tags; __Pyx_INCREF(__pyx_t_2); __pyx_t_6 = 0;
  18345. __pyx_t_7 = NULL;
  18346. } else {
  18347. __pyx_t_6 = -1; __pyx_t_2 = PyObject_GetIter(__pyx_v_self->use_tags); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1319, __pyx_L1_error)
  18348. __Pyx_GOTREF(__pyx_t_2);
  18349. __pyx_t_7 = Py_TYPE(__pyx_t_2)->tp_iternext; if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 1319, __pyx_L1_error)
  18350. }
  18351. for (;;) {
  18352. if (likely(!__pyx_t_7)) {
  18353. if (likely(PyList_CheckExact(__pyx_t_2))) {
  18354. if (__pyx_t_6 >= PyList_GET_SIZE(__pyx_t_2)) break;
  18355. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  18356. __pyx_t_3 = PyList_GET_ITEM(__pyx_t_2, __pyx_t_6); __Pyx_INCREF(__pyx_t_3); __pyx_t_6++; if (unlikely(0 < 0)) __PYX_ERR(0, 1319, __pyx_L1_error)
  18357. #else
  18358. __pyx_t_3 = PySequence_ITEM(__pyx_t_2, __pyx_t_6); __pyx_t_6++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1319, __pyx_L1_error)
  18359. __Pyx_GOTREF(__pyx_t_3);
  18360. #endif
  18361. } else {
  18362. if (__pyx_t_6 >= PyTuple_GET_SIZE(__pyx_t_2)) break;
  18363. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  18364. __pyx_t_3 = PyTuple_GET_ITEM(__pyx_t_2, __pyx_t_6); __Pyx_INCREF(__pyx_t_3); __pyx_t_6++; if (unlikely(0 < 0)) __PYX_ERR(0, 1319, __pyx_L1_error)
  18365. #else
  18366. __pyx_t_3 = PySequence_ITEM(__pyx_t_2, __pyx_t_6); __pyx_t_6++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1319, __pyx_L1_error)
  18367. __Pyx_GOTREF(__pyx_t_3);
  18368. #endif
  18369. }
  18370. } else {
  18371. __pyx_t_3 = __pyx_t_7(__pyx_t_2);
  18372. if (unlikely(!__pyx_t_3)) {
  18373. PyObject* exc_type = PyErr_Occurred();
  18374. if (exc_type) {
  18375. if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
  18376. else __PYX_ERR(0, 1319, __pyx_L1_error)
  18377. }
  18378. break;
  18379. }
  18380. __Pyx_GOTREF(__pyx_t_3);
  18381. }
  18382. __Pyx_XDECREF_SET(__pyx_v_handle, __pyx_t_3);
  18383. __pyx_t_3 = 0;
  18384. /* "_yaml.pyx":1320
  18385. * tag_directives_end = tag_directives_value
  18386. * for handle in self.use_tags:
  18387. * prefix = self.use_tags[handle] # <<<<<<<<<<<<<<
  18388. * if PyUnicode_CheckExact(handle):
  18389. * handle = PyUnicode_AsUTF8String(handle)
  18390. */
  18391. __pyx_t_3 = __Pyx_PyObject_GetItem(__pyx_v_self->use_tags, __pyx_v_handle); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1320, __pyx_L1_error)
  18392. __Pyx_GOTREF(__pyx_t_3);
  18393. __Pyx_XDECREF_SET(__pyx_v_prefix, __pyx_t_3);
  18394. __pyx_t_3 = 0;
  18395. /* "_yaml.pyx":1321
  18396. * for handle in self.use_tags:
  18397. * prefix = self.use_tags[handle]
  18398. * if PyUnicode_CheckExact(handle): # <<<<<<<<<<<<<<
  18399. * handle = PyUnicode_AsUTF8String(handle)
  18400. * cache.append(handle)
  18401. */
  18402. __pyx_t_1 = (PyUnicode_CheckExact(__pyx_v_handle) != 0);
  18403. if (__pyx_t_1) {
  18404. /* "_yaml.pyx":1322
  18405. * prefix = self.use_tags[handle]
  18406. * if PyUnicode_CheckExact(handle):
  18407. * handle = PyUnicode_AsUTF8String(handle) # <<<<<<<<<<<<<<
  18408. * cache.append(handle)
  18409. * if not PyString_CheckExact(handle):
  18410. */
  18411. __pyx_t_3 = PyUnicode_AsUTF8String(__pyx_v_handle); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1322, __pyx_L1_error)
  18412. __Pyx_GOTREF(__pyx_t_3);
  18413. __Pyx_DECREF_SET(__pyx_v_handle, __pyx_t_3);
  18414. __pyx_t_3 = 0;
  18415. /* "_yaml.pyx":1323
  18416. * if PyUnicode_CheckExact(handle):
  18417. * handle = PyUnicode_AsUTF8String(handle)
  18418. * cache.append(handle) # <<<<<<<<<<<<<<
  18419. * if not PyString_CheckExact(handle):
  18420. * if PY_MAJOR_VERSION < 3:
  18421. */
  18422. __pyx_t_8 = __Pyx_PyList_Append(__pyx_v_cache, __pyx_v_handle); if (unlikely(__pyx_t_8 == ((int)-1))) __PYX_ERR(0, 1323, __pyx_L1_error)
  18423. /* "_yaml.pyx":1321
  18424. * for handle in self.use_tags:
  18425. * prefix = self.use_tags[handle]
  18426. * if PyUnicode_CheckExact(handle): # <<<<<<<<<<<<<<
  18427. * handle = PyUnicode_AsUTF8String(handle)
  18428. * cache.append(handle)
  18429. */
  18430. }
  18431. /* "_yaml.pyx":1324
  18432. * handle = PyUnicode_AsUTF8String(handle)
  18433. * cache.append(handle)
  18434. * if not PyString_CheckExact(handle): # <<<<<<<<<<<<<<
  18435. * if PY_MAJOR_VERSION < 3:
  18436. * raise TypeError("tag handle must be a string")
  18437. */
  18438. __pyx_t_1 = ((!(PyString_CheckExact(__pyx_v_handle) != 0)) != 0);
  18439. if (__pyx_t_1) {
  18440. /* "_yaml.pyx":1325
  18441. * cache.append(handle)
  18442. * if not PyString_CheckExact(handle):
  18443. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  18444. * raise TypeError("tag handle must be a string")
  18445. * else:
  18446. */
  18447. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  18448. if (unlikely(__pyx_t_1)) {
  18449. /* "_yaml.pyx":1326
  18450. * if not PyString_CheckExact(handle):
  18451. * if PY_MAJOR_VERSION < 3:
  18452. * raise TypeError("tag handle must be a string") # <<<<<<<<<<<<<<
  18453. * else:
  18454. * raise TypeError(u"tag handle must be a string")
  18455. */
  18456. __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__26, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1326, __pyx_L1_error)
  18457. __Pyx_GOTREF(__pyx_t_3);
  18458. __Pyx_Raise(__pyx_t_3, 0, 0, 0);
  18459. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  18460. __PYX_ERR(0, 1326, __pyx_L1_error)
  18461. /* "_yaml.pyx":1325
  18462. * cache.append(handle)
  18463. * if not PyString_CheckExact(handle):
  18464. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  18465. * raise TypeError("tag handle must be a string")
  18466. * else:
  18467. */
  18468. }
  18469. /* "_yaml.pyx":1328
  18470. * raise TypeError("tag handle must be a string")
  18471. * else:
  18472. * raise TypeError(u"tag handle must be a string") # <<<<<<<<<<<<<<
  18473. * tag_directives_end.handle = PyString_AS_STRING(handle)
  18474. * if PyUnicode_CheckExact(prefix):
  18475. */
  18476. /*else*/ {
  18477. __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__27, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1328, __pyx_L1_error)
  18478. __Pyx_GOTREF(__pyx_t_3);
  18479. __Pyx_Raise(__pyx_t_3, 0, 0, 0);
  18480. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  18481. __PYX_ERR(0, 1328, __pyx_L1_error)
  18482. }
  18483. /* "_yaml.pyx":1324
  18484. * handle = PyUnicode_AsUTF8String(handle)
  18485. * cache.append(handle)
  18486. * if not PyString_CheckExact(handle): # <<<<<<<<<<<<<<
  18487. * if PY_MAJOR_VERSION < 3:
  18488. * raise TypeError("tag handle must be a string")
  18489. */
  18490. }
  18491. /* "_yaml.pyx":1329
  18492. * else:
  18493. * raise TypeError(u"tag handle must be a string")
  18494. * tag_directives_end.handle = PyString_AS_STRING(handle) # <<<<<<<<<<<<<<
  18495. * if PyUnicode_CheckExact(prefix):
  18496. * prefix = PyUnicode_AsUTF8String(prefix)
  18497. */
  18498. __pyx_v_tag_directives_end->handle = PyString_AS_STRING(__pyx_v_handle);
  18499. /* "_yaml.pyx":1330
  18500. * raise TypeError(u"tag handle must be a string")
  18501. * tag_directives_end.handle = PyString_AS_STRING(handle)
  18502. * if PyUnicode_CheckExact(prefix): # <<<<<<<<<<<<<<
  18503. * prefix = PyUnicode_AsUTF8String(prefix)
  18504. * cache.append(prefix)
  18505. */
  18506. __pyx_t_1 = (PyUnicode_CheckExact(__pyx_v_prefix) != 0);
  18507. if (__pyx_t_1) {
  18508. /* "_yaml.pyx":1331
  18509. * tag_directives_end.handle = PyString_AS_STRING(handle)
  18510. * if PyUnicode_CheckExact(prefix):
  18511. * prefix = PyUnicode_AsUTF8String(prefix) # <<<<<<<<<<<<<<
  18512. * cache.append(prefix)
  18513. * if not PyString_CheckExact(prefix):
  18514. */
  18515. __pyx_t_3 = PyUnicode_AsUTF8String(__pyx_v_prefix); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1331, __pyx_L1_error)
  18516. __Pyx_GOTREF(__pyx_t_3);
  18517. __Pyx_DECREF_SET(__pyx_v_prefix, __pyx_t_3);
  18518. __pyx_t_3 = 0;
  18519. /* "_yaml.pyx":1332
  18520. * if PyUnicode_CheckExact(prefix):
  18521. * prefix = PyUnicode_AsUTF8String(prefix)
  18522. * cache.append(prefix) # <<<<<<<<<<<<<<
  18523. * if not PyString_CheckExact(prefix):
  18524. * if PY_MAJOR_VERSION < 3:
  18525. */
  18526. __pyx_t_8 = __Pyx_PyList_Append(__pyx_v_cache, __pyx_v_prefix); if (unlikely(__pyx_t_8 == ((int)-1))) __PYX_ERR(0, 1332, __pyx_L1_error)
  18527. /* "_yaml.pyx":1330
  18528. * raise TypeError(u"tag handle must be a string")
  18529. * tag_directives_end.handle = PyString_AS_STRING(handle)
  18530. * if PyUnicode_CheckExact(prefix): # <<<<<<<<<<<<<<
  18531. * prefix = PyUnicode_AsUTF8String(prefix)
  18532. * cache.append(prefix)
  18533. */
  18534. }
  18535. /* "_yaml.pyx":1333
  18536. * prefix = PyUnicode_AsUTF8String(prefix)
  18537. * cache.append(prefix)
  18538. * if not PyString_CheckExact(prefix): # <<<<<<<<<<<<<<
  18539. * if PY_MAJOR_VERSION < 3:
  18540. * raise TypeError("tag prefix must be a string")
  18541. */
  18542. __pyx_t_1 = ((!(PyString_CheckExact(__pyx_v_prefix) != 0)) != 0);
  18543. if (__pyx_t_1) {
  18544. /* "_yaml.pyx":1334
  18545. * cache.append(prefix)
  18546. * if not PyString_CheckExact(prefix):
  18547. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  18548. * raise TypeError("tag prefix must be a string")
  18549. * else:
  18550. */
  18551. __pyx_t_1 = ((PY_MAJOR_VERSION < 3) != 0);
  18552. if (unlikely(__pyx_t_1)) {
  18553. /* "_yaml.pyx":1335
  18554. * if not PyString_CheckExact(prefix):
  18555. * if PY_MAJOR_VERSION < 3:
  18556. * raise TypeError("tag prefix must be a string") # <<<<<<<<<<<<<<
  18557. * else:
  18558. * raise TypeError(u"tag prefix must be a string")
  18559. */
  18560. __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__28, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1335, __pyx_L1_error)
  18561. __Pyx_GOTREF(__pyx_t_3);
  18562. __Pyx_Raise(__pyx_t_3, 0, 0, 0);
  18563. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  18564. __PYX_ERR(0, 1335, __pyx_L1_error)
  18565. /* "_yaml.pyx":1334
  18566. * cache.append(prefix)
  18567. * if not PyString_CheckExact(prefix):
  18568. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  18569. * raise TypeError("tag prefix must be a string")
  18570. * else:
  18571. */
  18572. }
  18573. /* "_yaml.pyx":1337
  18574. * raise TypeError("tag prefix must be a string")
  18575. * else:
  18576. * raise TypeError(u"tag prefix must be a string") # <<<<<<<<<<<<<<
  18577. * tag_directives_end.prefix = PyString_AS_STRING(prefix)
  18578. * tag_directives_end = tag_directives_end+1
  18579. */
  18580. /*else*/ {
  18581. __pyx_t_3 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__29, NULL); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1337, __pyx_L1_error)
  18582. __Pyx_GOTREF(__pyx_t_3);
  18583. __Pyx_Raise(__pyx_t_3, 0, 0, 0);
  18584. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  18585. __PYX_ERR(0, 1337, __pyx_L1_error)
  18586. }
  18587. /* "_yaml.pyx":1333
  18588. * prefix = PyUnicode_AsUTF8String(prefix)
  18589. * cache.append(prefix)
  18590. * if not PyString_CheckExact(prefix): # <<<<<<<<<<<<<<
  18591. * if PY_MAJOR_VERSION < 3:
  18592. * raise TypeError("tag prefix must be a string")
  18593. */
  18594. }
  18595. /* "_yaml.pyx":1338
  18596. * else:
  18597. * raise TypeError(u"tag prefix must be a string")
  18598. * tag_directives_end.prefix = PyString_AS_STRING(prefix) # <<<<<<<<<<<<<<
  18599. * tag_directives_end = tag_directives_end+1
  18600. * if yaml_document_start_event_initialize(&event, version_directive,
  18601. */
  18602. __pyx_v_tag_directives_end->prefix = PyString_AS_STRING(__pyx_v_prefix);
  18603. /* "_yaml.pyx":1339
  18604. * raise TypeError(u"tag prefix must be a string")
  18605. * tag_directives_end.prefix = PyString_AS_STRING(prefix)
  18606. * tag_directives_end = tag_directives_end+1 # <<<<<<<<<<<<<<
  18607. * if yaml_document_start_event_initialize(&event, version_directive,
  18608. * tag_directives_start, tag_directives_end,
  18609. */
  18610. __pyx_v_tag_directives_end = (__pyx_v_tag_directives_end + 1);
  18611. /* "_yaml.pyx":1319
  18612. * tag_directives_start = tag_directives_value
  18613. * tag_directives_end = tag_directives_value
  18614. * for handle in self.use_tags: # <<<<<<<<<<<<<<
  18615. * prefix = self.use_tags[handle]
  18616. * if PyUnicode_CheckExact(handle):
  18617. */
  18618. }
  18619. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  18620. /* "_yaml.pyx":1311
  18621. * tag_directives_start = NULL
  18622. * tag_directives_end = NULL
  18623. * if self.use_tags: # <<<<<<<<<<<<<<
  18624. * if len(self.use_tags) > 128:
  18625. * if PY_MAJOR_VERSION < 3:
  18626. */
  18627. }
  18628. /* "_yaml.pyx":1342
  18629. * if yaml_document_start_event_initialize(&event, version_directive,
  18630. * tag_directives_start, tag_directives_end,
  18631. * self.document_start_implicit) == 0: # <<<<<<<<<<<<<<
  18632. * raise MemoryError
  18633. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  18634. */
  18635. __pyx_t_1 = ((yaml_document_start_event_initialize((&__pyx_v_event), __pyx_v_version_directive, __pyx_v_tag_directives_start, __pyx_v_tag_directives_end, __pyx_v_self->document_start_implicit) == 0) != 0);
  18636. /* "_yaml.pyx":1340
  18637. * tag_directives_end.prefix = PyString_AS_STRING(prefix)
  18638. * tag_directives_end = tag_directives_end+1
  18639. * if yaml_document_start_event_initialize(&event, version_directive, # <<<<<<<<<<<<<<
  18640. * tag_directives_start, tag_directives_end,
  18641. * self.document_start_implicit) == 0:
  18642. */
  18643. if (unlikely(__pyx_t_1)) {
  18644. /* "_yaml.pyx":1343
  18645. * tag_directives_start, tag_directives_end,
  18646. * self.document_start_implicit) == 0:
  18647. * raise MemoryError # <<<<<<<<<<<<<<
  18648. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  18649. * error = self._emitter_error()
  18650. */
  18651. PyErr_NoMemory(); __PYX_ERR(0, 1343, __pyx_L1_error)
  18652. /* "_yaml.pyx":1340
  18653. * tag_directives_end.prefix = PyString_AS_STRING(prefix)
  18654. * tag_directives_end = tag_directives_end+1
  18655. * if yaml_document_start_event_initialize(&event, version_directive, # <<<<<<<<<<<<<<
  18656. * tag_directives_start, tag_directives_end,
  18657. * self.document_start_implicit) == 0:
  18658. */
  18659. }
  18660. /* "_yaml.pyx":1344
  18661. * self.document_start_implicit) == 0:
  18662. * raise MemoryError
  18663. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  18664. * error = self._emitter_error()
  18665. * raise error
  18666. */
  18667. __pyx_t_5 = yaml_emitter_emit((&__pyx_v_self->emitter), (&__pyx_v_event)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 1344, __pyx_L1_error)
  18668. __pyx_t_1 = ((__pyx_t_5 == 0) != 0);
  18669. if (unlikely(__pyx_t_1)) {
  18670. /* "_yaml.pyx":1345
  18671. * raise MemoryError
  18672. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  18673. * error = self._emitter_error() # <<<<<<<<<<<<<<
  18674. * raise error
  18675. * self._anchor_node(node)
  18676. */
  18677. __pyx_t_2 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_emitter_error(__pyx_v_self); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1345, __pyx_L1_error)
  18678. __Pyx_GOTREF(__pyx_t_2);
  18679. __pyx_v_error = __pyx_t_2;
  18680. __pyx_t_2 = 0;
  18681. /* "_yaml.pyx":1346
  18682. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  18683. * error = self._emitter_error()
  18684. * raise error # <<<<<<<<<<<<<<
  18685. * self._anchor_node(node)
  18686. * self._serialize_node(node, None, None)
  18687. */
  18688. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  18689. __PYX_ERR(0, 1346, __pyx_L1_error)
  18690. /* "_yaml.pyx":1344
  18691. * self.document_start_implicit) == 0:
  18692. * raise MemoryError
  18693. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  18694. * error = self._emitter_error()
  18695. * raise error
  18696. */
  18697. }
  18698. /* "_yaml.pyx":1347
  18699. * error = self._emitter_error()
  18700. * raise error
  18701. * self._anchor_node(node) # <<<<<<<<<<<<<<
  18702. * self._serialize_node(node, None, None)
  18703. * yaml_document_end_event_initialize(&event, self.document_end_implicit)
  18704. */
  18705. __pyx_t_5 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_anchor_node(__pyx_v_self, __pyx_v_node); if (unlikely(__pyx_t_5 == ((int)0))) __PYX_ERR(0, 1347, __pyx_L1_error)
  18706. /* "_yaml.pyx":1348
  18707. * raise error
  18708. * self._anchor_node(node)
  18709. * self._serialize_node(node, None, None) # <<<<<<<<<<<<<<
  18710. * yaml_document_end_event_initialize(&event, self.document_end_implicit)
  18711. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  18712. */
  18713. __pyx_t_5 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_serialize_node(__pyx_v_self, __pyx_v_node, Py_None, Py_None); if (unlikely(__pyx_t_5 == ((int)0))) __PYX_ERR(0, 1348, __pyx_L1_error)
  18714. /* "_yaml.pyx":1349
  18715. * self._anchor_node(node)
  18716. * self._serialize_node(node, None, None)
  18717. * yaml_document_end_event_initialize(&event, self.document_end_implicit) # <<<<<<<<<<<<<<
  18718. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  18719. * error = self._emitter_error()
  18720. */
  18721. (void)(yaml_document_end_event_initialize((&__pyx_v_event), __pyx_v_self->document_end_implicit));
  18722. /* "_yaml.pyx":1350
  18723. * self._serialize_node(node, None, None)
  18724. * yaml_document_end_event_initialize(&event, self.document_end_implicit)
  18725. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  18726. * error = self._emitter_error()
  18727. * raise error
  18728. */
  18729. __pyx_t_5 = yaml_emitter_emit((&__pyx_v_self->emitter), (&__pyx_v_event)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 1350, __pyx_L1_error)
  18730. __pyx_t_1 = ((__pyx_t_5 == 0) != 0);
  18731. if (unlikely(__pyx_t_1)) {
  18732. /* "_yaml.pyx":1351
  18733. * yaml_document_end_event_initialize(&event, self.document_end_implicit)
  18734. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  18735. * error = self._emitter_error() # <<<<<<<<<<<<<<
  18736. * raise error
  18737. * self.serialized_nodes = {}
  18738. */
  18739. __pyx_t_2 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_emitter_error(__pyx_v_self); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1351, __pyx_L1_error)
  18740. __Pyx_GOTREF(__pyx_t_2);
  18741. __pyx_v_error = __pyx_t_2;
  18742. __pyx_t_2 = 0;
  18743. /* "_yaml.pyx":1352
  18744. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  18745. * error = self._emitter_error()
  18746. * raise error # <<<<<<<<<<<<<<
  18747. * self.serialized_nodes = {}
  18748. * self.anchors = {}
  18749. */
  18750. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  18751. __PYX_ERR(0, 1352, __pyx_L1_error)
  18752. /* "_yaml.pyx":1350
  18753. * self._serialize_node(node, None, None)
  18754. * yaml_document_end_event_initialize(&event, self.document_end_implicit)
  18755. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  18756. * error = self._emitter_error()
  18757. * raise error
  18758. */
  18759. }
  18760. /* "_yaml.pyx":1353
  18761. * error = self._emitter_error()
  18762. * raise error
  18763. * self.serialized_nodes = {} # <<<<<<<<<<<<<<
  18764. * self.anchors = {}
  18765. * self.last_alias_id = 0
  18766. */
  18767. __pyx_t_2 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1353, __pyx_L1_error)
  18768. __Pyx_GOTREF(__pyx_t_2);
  18769. __Pyx_GIVEREF(__pyx_t_2);
  18770. __Pyx_GOTREF(__pyx_v_self->serialized_nodes);
  18771. __Pyx_DECREF(__pyx_v_self->serialized_nodes);
  18772. __pyx_v_self->serialized_nodes = __pyx_t_2;
  18773. __pyx_t_2 = 0;
  18774. /* "_yaml.pyx":1354
  18775. * raise error
  18776. * self.serialized_nodes = {}
  18777. * self.anchors = {} # <<<<<<<<<<<<<<
  18778. * self.last_alias_id = 0
  18779. *
  18780. */
  18781. __pyx_t_2 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 1354, __pyx_L1_error)
  18782. __Pyx_GOTREF(__pyx_t_2);
  18783. __Pyx_GIVEREF(__pyx_t_2);
  18784. __Pyx_GOTREF(__pyx_v_self->anchors);
  18785. __Pyx_DECREF(__pyx_v_self->anchors);
  18786. __pyx_v_self->anchors = __pyx_t_2;
  18787. __pyx_t_2 = 0;
  18788. /* "_yaml.pyx":1355
  18789. * self.serialized_nodes = {}
  18790. * self.anchors = {}
  18791. * self.last_alias_id = 0 # <<<<<<<<<<<<<<
  18792. *
  18793. * cdef int _anchor_node(self, object node) except 0:
  18794. */
  18795. __pyx_v_self->last_alias_id = 0;
  18796. /* "_yaml.pyx":1286
  18797. * self.closed = 1
  18798. *
  18799. * def serialize(self, node): # <<<<<<<<<<<<<<
  18800. * cdef yaml_event_t event
  18801. * cdef yaml_version_directive_t version_directive_value
  18802. */
  18803. /* function exit code */
  18804. __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  18805. goto __pyx_L0;
  18806. __pyx_L1_error:;
  18807. __Pyx_XDECREF(__pyx_t_2);
  18808. __Pyx_XDECREF(__pyx_t_3);
  18809. __Pyx_XDECREF(__pyx_t_4);
  18810. __Pyx_AddTraceback("_yaml.CEmitter.serialize", __pyx_clineno, __pyx_lineno, __pyx_filename);
  18811. __pyx_r = NULL;
  18812. __pyx_L0:;
  18813. __Pyx_XDECREF(__pyx_v_cache);
  18814. __Pyx_XDECREF(__pyx_v_handle);
  18815. __Pyx_XDECREF(__pyx_v_prefix);
  18816. __Pyx_XDECREF(__pyx_v_error);
  18817. __Pyx_XGIVEREF(__pyx_r);
  18818. __Pyx_RefNannyFinishContext();
  18819. return __pyx_r;
  18820. }
  18821. /* "_yaml.pyx":1357
  18822. * self.last_alias_id = 0
  18823. *
  18824. * cdef int _anchor_node(self, object node) except 0: # <<<<<<<<<<<<<<
  18825. * if node in self.anchors:
  18826. * if self.anchors[node] is None:
  18827. */
  18828. static int __pyx_f_5_yaml_8CEmitter__anchor_node(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self, PyObject *__pyx_v_node) {
  18829. PyObject *__pyx_v_node_class = NULL;
  18830. PyObject *__pyx_v_item = NULL;
  18831. PyObject *__pyx_v_key = NULL;
  18832. PyObject *__pyx_v_value = NULL;
  18833. int __pyx_r;
  18834. __Pyx_RefNannyDeclarations
  18835. int __pyx_t_1;
  18836. int __pyx_t_2;
  18837. PyObject *__pyx_t_3 = NULL;
  18838. PyObject *__pyx_t_4 = NULL;
  18839. Py_ssize_t __pyx_t_5;
  18840. PyObject *(*__pyx_t_6)(PyObject *);
  18841. int __pyx_t_7;
  18842. PyObject *__pyx_t_8 = NULL;
  18843. PyObject *__pyx_t_9 = NULL;
  18844. PyObject *__pyx_t_10 = NULL;
  18845. PyObject *(*__pyx_t_11)(PyObject *);
  18846. __Pyx_RefNannySetupContext("_anchor_node", 0);
  18847. /* "_yaml.pyx":1358
  18848. *
  18849. * cdef int _anchor_node(self, object node) except 0:
  18850. * if node in self.anchors: # <<<<<<<<<<<<<<
  18851. * if self.anchors[node] is None:
  18852. * self.last_alias_id = self.last_alias_id+1
  18853. */
  18854. __pyx_t_1 = (__Pyx_PySequence_ContainsTF(__pyx_v_node, __pyx_v_self->anchors, Py_EQ)); if (unlikely(__pyx_t_1 < 0)) __PYX_ERR(0, 1358, __pyx_L1_error)
  18855. __pyx_t_2 = (__pyx_t_1 != 0);
  18856. if (__pyx_t_2) {
  18857. /* "_yaml.pyx":1359
  18858. * cdef int _anchor_node(self, object node) except 0:
  18859. * if node in self.anchors:
  18860. * if self.anchors[node] is None: # <<<<<<<<<<<<<<
  18861. * self.last_alias_id = self.last_alias_id+1
  18862. * self.anchors[node] = u"id%03d" % self.last_alias_id
  18863. */
  18864. __pyx_t_3 = __Pyx_PyObject_GetItem(__pyx_v_self->anchors, __pyx_v_node); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1359, __pyx_L1_error)
  18865. __Pyx_GOTREF(__pyx_t_3);
  18866. __pyx_t_2 = (__pyx_t_3 == Py_None);
  18867. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  18868. __pyx_t_1 = (__pyx_t_2 != 0);
  18869. if (__pyx_t_1) {
  18870. /* "_yaml.pyx":1360
  18871. * if node in self.anchors:
  18872. * if self.anchors[node] is None:
  18873. * self.last_alias_id = self.last_alias_id+1 # <<<<<<<<<<<<<<
  18874. * self.anchors[node] = u"id%03d" % self.last_alias_id
  18875. * else:
  18876. */
  18877. __pyx_v_self->last_alias_id = (__pyx_v_self->last_alias_id + 1);
  18878. /* "_yaml.pyx":1361
  18879. * if self.anchors[node] is None:
  18880. * self.last_alias_id = self.last_alias_id+1
  18881. * self.anchors[node] = u"id%03d" % self.last_alias_id # <<<<<<<<<<<<<<
  18882. * else:
  18883. * self.anchors[node] = None
  18884. */
  18885. __pyx_t_3 = __Pyx_PyInt_From_int(__pyx_v_self->last_alias_id); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1361, __pyx_L1_error)
  18886. __Pyx_GOTREF(__pyx_t_3);
  18887. __pyx_t_4 = PyUnicode_Format(__pyx_kp_u_id_03d, __pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1361, __pyx_L1_error)
  18888. __Pyx_GOTREF(__pyx_t_4);
  18889. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  18890. if (unlikely(PyObject_SetItem(__pyx_v_self->anchors, __pyx_v_node, __pyx_t_4) < 0)) __PYX_ERR(0, 1361, __pyx_L1_error)
  18891. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  18892. /* "_yaml.pyx":1359
  18893. * cdef int _anchor_node(self, object node) except 0:
  18894. * if node in self.anchors:
  18895. * if self.anchors[node] is None: # <<<<<<<<<<<<<<
  18896. * self.last_alias_id = self.last_alias_id+1
  18897. * self.anchors[node] = u"id%03d" % self.last_alias_id
  18898. */
  18899. }
  18900. /* "_yaml.pyx":1358
  18901. *
  18902. * cdef int _anchor_node(self, object node) except 0:
  18903. * if node in self.anchors: # <<<<<<<<<<<<<<
  18904. * if self.anchors[node] is None:
  18905. * self.last_alias_id = self.last_alias_id+1
  18906. */
  18907. goto __pyx_L3;
  18908. }
  18909. /* "_yaml.pyx":1363
  18910. * self.anchors[node] = u"id%03d" % self.last_alias_id
  18911. * else:
  18912. * self.anchors[node] = None # <<<<<<<<<<<<<<
  18913. * node_class = node.__class__
  18914. * if node_class is SequenceNode:
  18915. */
  18916. /*else*/ {
  18917. if (unlikely(PyObject_SetItem(__pyx_v_self->anchors, __pyx_v_node, Py_None) < 0)) __PYX_ERR(0, 1363, __pyx_L1_error)
  18918. /* "_yaml.pyx":1364
  18919. * else:
  18920. * self.anchors[node] = None
  18921. * node_class = node.__class__ # <<<<<<<<<<<<<<
  18922. * if node_class is SequenceNode:
  18923. * for item in node.value:
  18924. */
  18925. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_class); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1364, __pyx_L1_error)
  18926. __Pyx_GOTREF(__pyx_t_4);
  18927. __pyx_v_node_class = __pyx_t_4;
  18928. __pyx_t_4 = 0;
  18929. /* "_yaml.pyx":1365
  18930. * self.anchors[node] = None
  18931. * node_class = node.__class__
  18932. * if node_class is SequenceNode: # <<<<<<<<<<<<<<
  18933. * for item in node.value:
  18934. * self._anchor_node(item)
  18935. */
  18936. __Pyx_GetModuleGlobalName(__pyx_t_4, __pyx_n_s_SequenceNode); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1365, __pyx_L1_error)
  18937. __Pyx_GOTREF(__pyx_t_4);
  18938. __pyx_t_1 = (__pyx_v_node_class == __pyx_t_4);
  18939. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  18940. __pyx_t_2 = (__pyx_t_1 != 0);
  18941. if (__pyx_t_2) {
  18942. /* "_yaml.pyx":1366
  18943. * node_class = node.__class__
  18944. * if node_class is SequenceNode:
  18945. * for item in node.value: # <<<<<<<<<<<<<<
  18946. * self._anchor_node(item)
  18947. * elif node_class is MappingNode:
  18948. */
  18949. __pyx_t_4 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_value); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1366, __pyx_L1_error)
  18950. __Pyx_GOTREF(__pyx_t_4);
  18951. if (likely(PyList_CheckExact(__pyx_t_4)) || PyTuple_CheckExact(__pyx_t_4)) {
  18952. __pyx_t_3 = __pyx_t_4; __Pyx_INCREF(__pyx_t_3); __pyx_t_5 = 0;
  18953. __pyx_t_6 = NULL;
  18954. } else {
  18955. __pyx_t_5 = -1; __pyx_t_3 = PyObject_GetIter(__pyx_t_4); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1366, __pyx_L1_error)
  18956. __Pyx_GOTREF(__pyx_t_3);
  18957. __pyx_t_6 = Py_TYPE(__pyx_t_3)->tp_iternext; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 1366, __pyx_L1_error)
  18958. }
  18959. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  18960. for (;;) {
  18961. if (likely(!__pyx_t_6)) {
  18962. if (likely(PyList_CheckExact(__pyx_t_3))) {
  18963. if (__pyx_t_5 >= PyList_GET_SIZE(__pyx_t_3)) break;
  18964. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  18965. __pyx_t_4 = PyList_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_4); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 1366, __pyx_L1_error)
  18966. #else
  18967. __pyx_t_4 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1366, __pyx_L1_error)
  18968. __Pyx_GOTREF(__pyx_t_4);
  18969. #endif
  18970. } else {
  18971. if (__pyx_t_5 >= PyTuple_GET_SIZE(__pyx_t_3)) break;
  18972. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  18973. __pyx_t_4 = PyTuple_GET_ITEM(__pyx_t_3, __pyx_t_5); __Pyx_INCREF(__pyx_t_4); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 1366, __pyx_L1_error)
  18974. #else
  18975. __pyx_t_4 = PySequence_ITEM(__pyx_t_3, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1366, __pyx_L1_error)
  18976. __Pyx_GOTREF(__pyx_t_4);
  18977. #endif
  18978. }
  18979. } else {
  18980. __pyx_t_4 = __pyx_t_6(__pyx_t_3);
  18981. if (unlikely(!__pyx_t_4)) {
  18982. PyObject* exc_type = PyErr_Occurred();
  18983. if (exc_type) {
  18984. if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
  18985. else __PYX_ERR(0, 1366, __pyx_L1_error)
  18986. }
  18987. break;
  18988. }
  18989. __Pyx_GOTREF(__pyx_t_4);
  18990. }
  18991. __Pyx_XDECREF_SET(__pyx_v_item, __pyx_t_4);
  18992. __pyx_t_4 = 0;
  18993. /* "_yaml.pyx":1367
  18994. * if node_class is SequenceNode:
  18995. * for item in node.value:
  18996. * self._anchor_node(item) # <<<<<<<<<<<<<<
  18997. * elif node_class is MappingNode:
  18998. * for key, value in node.value:
  18999. */
  19000. __pyx_t_7 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_anchor_node(__pyx_v_self, __pyx_v_item); if (unlikely(__pyx_t_7 == ((int)0))) __PYX_ERR(0, 1367, __pyx_L1_error)
  19001. /* "_yaml.pyx":1366
  19002. * node_class = node.__class__
  19003. * if node_class is SequenceNode:
  19004. * for item in node.value: # <<<<<<<<<<<<<<
  19005. * self._anchor_node(item)
  19006. * elif node_class is MappingNode:
  19007. */
  19008. }
  19009. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  19010. /* "_yaml.pyx":1365
  19011. * self.anchors[node] = None
  19012. * node_class = node.__class__
  19013. * if node_class is SequenceNode: # <<<<<<<<<<<<<<
  19014. * for item in node.value:
  19015. * self._anchor_node(item)
  19016. */
  19017. goto __pyx_L5;
  19018. }
  19019. /* "_yaml.pyx":1368
  19020. * for item in node.value:
  19021. * self._anchor_node(item)
  19022. * elif node_class is MappingNode: # <<<<<<<<<<<<<<
  19023. * for key, value in node.value:
  19024. * self._anchor_node(key)
  19025. */
  19026. __Pyx_GetModuleGlobalName(__pyx_t_3, __pyx_n_s_MappingNode); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1368, __pyx_L1_error)
  19027. __Pyx_GOTREF(__pyx_t_3);
  19028. __pyx_t_2 = (__pyx_v_node_class == __pyx_t_3);
  19029. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  19030. __pyx_t_1 = (__pyx_t_2 != 0);
  19031. if (__pyx_t_1) {
  19032. /* "_yaml.pyx":1369
  19033. * self._anchor_node(item)
  19034. * elif node_class is MappingNode:
  19035. * for key, value in node.value: # <<<<<<<<<<<<<<
  19036. * self._anchor_node(key)
  19037. * self._anchor_node(value)
  19038. */
  19039. __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_value); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1369, __pyx_L1_error)
  19040. __Pyx_GOTREF(__pyx_t_3);
  19041. if (likely(PyList_CheckExact(__pyx_t_3)) || PyTuple_CheckExact(__pyx_t_3)) {
  19042. __pyx_t_4 = __pyx_t_3; __Pyx_INCREF(__pyx_t_4); __pyx_t_5 = 0;
  19043. __pyx_t_6 = NULL;
  19044. } else {
  19045. __pyx_t_5 = -1; __pyx_t_4 = PyObject_GetIter(__pyx_t_3); if (unlikely(!__pyx_t_4)) __PYX_ERR(0, 1369, __pyx_L1_error)
  19046. __Pyx_GOTREF(__pyx_t_4);
  19047. __pyx_t_6 = Py_TYPE(__pyx_t_4)->tp_iternext; if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 1369, __pyx_L1_error)
  19048. }
  19049. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  19050. for (;;) {
  19051. if (likely(!__pyx_t_6)) {
  19052. if (likely(PyList_CheckExact(__pyx_t_4))) {
  19053. if (__pyx_t_5 >= PyList_GET_SIZE(__pyx_t_4)) break;
  19054. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  19055. __pyx_t_3 = PyList_GET_ITEM(__pyx_t_4, __pyx_t_5); __Pyx_INCREF(__pyx_t_3); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 1369, __pyx_L1_error)
  19056. #else
  19057. __pyx_t_3 = PySequence_ITEM(__pyx_t_4, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1369, __pyx_L1_error)
  19058. __Pyx_GOTREF(__pyx_t_3);
  19059. #endif
  19060. } else {
  19061. if (__pyx_t_5 >= PyTuple_GET_SIZE(__pyx_t_4)) break;
  19062. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  19063. __pyx_t_3 = PyTuple_GET_ITEM(__pyx_t_4, __pyx_t_5); __Pyx_INCREF(__pyx_t_3); __pyx_t_5++; if (unlikely(0 < 0)) __PYX_ERR(0, 1369, __pyx_L1_error)
  19064. #else
  19065. __pyx_t_3 = PySequence_ITEM(__pyx_t_4, __pyx_t_5); __pyx_t_5++; if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1369, __pyx_L1_error)
  19066. __Pyx_GOTREF(__pyx_t_3);
  19067. #endif
  19068. }
  19069. } else {
  19070. __pyx_t_3 = __pyx_t_6(__pyx_t_4);
  19071. if (unlikely(!__pyx_t_3)) {
  19072. PyObject* exc_type = PyErr_Occurred();
  19073. if (exc_type) {
  19074. if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
  19075. else __PYX_ERR(0, 1369, __pyx_L1_error)
  19076. }
  19077. break;
  19078. }
  19079. __Pyx_GOTREF(__pyx_t_3);
  19080. }
  19081. if ((likely(PyTuple_CheckExact(__pyx_t_3))) || (PyList_CheckExact(__pyx_t_3))) {
  19082. PyObject* sequence = __pyx_t_3;
  19083. Py_ssize_t size = __Pyx_PySequence_SIZE(sequence);
  19084. if (unlikely(size != 2)) {
  19085. if (size > 2) __Pyx_RaiseTooManyValuesError(2);
  19086. else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
  19087. __PYX_ERR(0, 1369, __pyx_L1_error)
  19088. }
  19089. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  19090. if (likely(PyTuple_CheckExact(sequence))) {
  19091. __pyx_t_8 = PyTuple_GET_ITEM(sequence, 0);
  19092. __pyx_t_9 = PyTuple_GET_ITEM(sequence, 1);
  19093. } else {
  19094. __pyx_t_8 = PyList_GET_ITEM(sequence, 0);
  19095. __pyx_t_9 = PyList_GET_ITEM(sequence, 1);
  19096. }
  19097. __Pyx_INCREF(__pyx_t_8);
  19098. __Pyx_INCREF(__pyx_t_9);
  19099. #else
  19100. __pyx_t_8 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 1369, __pyx_L1_error)
  19101. __Pyx_GOTREF(__pyx_t_8);
  19102. __pyx_t_9 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 1369, __pyx_L1_error)
  19103. __Pyx_GOTREF(__pyx_t_9);
  19104. #endif
  19105. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  19106. } else {
  19107. Py_ssize_t index = -1;
  19108. __pyx_t_10 = PyObject_GetIter(__pyx_t_3); if (unlikely(!__pyx_t_10)) __PYX_ERR(0, 1369, __pyx_L1_error)
  19109. __Pyx_GOTREF(__pyx_t_10);
  19110. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  19111. __pyx_t_11 = Py_TYPE(__pyx_t_10)->tp_iternext;
  19112. index = 0; __pyx_t_8 = __pyx_t_11(__pyx_t_10); if (unlikely(!__pyx_t_8)) goto __pyx_L10_unpacking_failed;
  19113. __Pyx_GOTREF(__pyx_t_8);
  19114. index = 1; __pyx_t_9 = __pyx_t_11(__pyx_t_10); if (unlikely(!__pyx_t_9)) goto __pyx_L10_unpacking_failed;
  19115. __Pyx_GOTREF(__pyx_t_9);
  19116. if (__Pyx_IternextUnpackEndCheck(__pyx_t_11(__pyx_t_10), 2) < 0) __PYX_ERR(0, 1369, __pyx_L1_error)
  19117. __pyx_t_11 = NULL;
  19118. __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
  19119. goto __pyx_L11_unpacking_done;
  19120. __pyx_L10_unpacking_failed:;
  19121. __Pyx_DECREF(__pyx_t_10); __pyx_t_10 = 0;
  19122. __pyx_t_11 = NULL;
  19123. if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
  19124. __PYX_ERR(0, 1369, __pyx_L1_error)
  19125. __pyx_L11_unpacking_done:;
  19126. }
  19127. __Pyx_XDECREF_SET(__pyx_v_key, __pyx_t_8);
  19128. __pyx_t_8 = 0;
  19129. __Pyx_XDECREF_SET(__pyx_v_value, __pyx_t_9);
  19130. __pyx_t_9 = 0;
  19131. /* "_yaml.pyx":1370
  19132. * elif node_class is MappingNode:
  19133. * for key, value in node.value:
  19134. * self._anchor_node(key) # <<<<<<<<<<<<<<
  19135. * self._anchor_node(value)
  19136. * return 1
  19137. */
  19138. __pyx_t_7 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_anchor_node(__pyx_v_self, __pyx_v_key); if (unlikely(__pyx_t_7 == ((int)0))) __PYX_ERR(0, 1370, __pyx_L1_error)
  19139. /* "_yaml.pyx":1371
  19140. * for key, value in node.value:
  19141. * self._anchor_node(key)
  19142. * self._anchor_node(value) # <<<<<<<<<<<<<<
  19143. * return 1
  19144. *
  19145. */
  19146. __pyx_t_7 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_anchor_node(__pyx_v_self, __pyx_v_value); if (unlikely(__pyx_t_7 == ((int)0))) __PYX_ERR(0, 1371, __pyx_L1_error)
  19147. /* "_yaml.pyx":1369
  19148. * self._anchor_node(item)
  19149. * elif node_class is MappingNode:
  19150. * for key, value in node.value: # <<<<<<<<<<<<<<
  19151. * self._anchor_node(key)
  19152. * self._anchor_node(value)
  19153. */
  19154. }
  19155. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  19156. /* "_yaml.pyx":1368
  19157. * for item in node.value:
  19158. * self._anchor_node(item)
  19159. * elif node_class is MappingNode: # <<<<<<<<<<<<<<
  19160. * for key, value in node.value:
  19161. * self._anchor_node(key)
  19162. */
  19163. }
  19164. __pyx_L5:;
  19165. }
  19166. __pyx_L3:;
  19167. /* "_yaml.pyx":1372
  19168. * self._anchor_node(key)
  19169. * self._anchor_node(value)
  19170. * return 1 # <<<<<<<<<<<<<<
  19171. *
  19172. * cdef int _serialize_node(self, object node, object parent, object index) except 0:
  19173. */
  19174. __pyx_r = 1;
  19175. goto __pyx_L0;
  19176. /* "_yaml.pyx":1357
  19177. * self.last_alias_id = 0
  19178. *
  19179. * cdef int _anchor_node(self, object node) except 0: # <<<<<<<<<<<<<<
  19180. * if node in self.anchors:
  19181. * if self.anchors[node] is None:
  19182. */
  19183. /* function exit code */
  19184. __pyx_L1_error:;
  19185. __Pyx_XDECREF(__pyx_t_3);
  19186. __Pyx_XDECREF(__pyx_t_4);
  19187. __Pyx_XDECREF(__pyx_t_8);
  19188. __Pyx_XDECREF(__pyx_t_9);
  19189. __Pyx_XDECREF(__pyx_t_10);
  19190. __Pyx_AddTraceback("_yaml.CEmitter._anchor_node", __pyx_clineno, __pyx_lineno, __pyx_filename);
  19191. __pyx_r = 0;
  19192. __pyx_L0:;
  19193. __Pyx_XDECREF(__pyx_v_node_class);
  19194. __Pyx_XDECREF(__pyx_v_item);
  19195. __Pyx_XDECREF(__pyx_v_key);
  19196. __Pyx_XDECREF(__pyx_v_value);
  19197. __Pyx_RefNannyFinishContext();
  19198. return __pyx_r;
  19199. }
  19200. /* "_yaml.pyx":1374
  19201. * return 1
  19202. *
  19203. * cdef int _serialize_node(self, object node, object parent, object index) except 0: # <<<<<<<<<<<<<<
  19204. * cdef yaml_event_t event
  19205. * cdef int implicit
  19206. */
  19207. static int __pyx_f_5_yaml_8CEmitter__serialize_node(struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self, PyObject *__pyx_v_node, PyObject *__pyx_v_parent, PyObject *__pyx_v_index) {
  19208. yaml_event_t __pyx_v_event;
  19209. int __pyx_v_implicit;
  19210. int __pyx_v_plain_implicit;
  19211. int __pyx_v_quoted_implicit;
  19212. char *__pyx_v_anchor;
  19213. char *__pyx_v_tag;
  19214. char *__pyx_v_value;
  19215. int __pyx_v_length;
  19216. int __pyx_v_item_index;
  19217. yaml_scalar_style_t __pyx_v_scalar_style;
  19218. yaml_sequence_style_t __pyx_v_sequence_style;
  19219. yaml_mapping_style_t __pyx_v_mapping_style;
  19220. PyObject *__pyx_v_anchor_object = NULL;
  19221. PyObject *__pyx_v_error = NULL;
  19222. PyObject *__pyx_v_node_class = NULL;
  19223. PyObject *__pyx_v_tag_object = NULL;
  19224. PyObject *__pyx_v_value_object = NULL;
  19225. PyObject *__pyx_v_style_object = NULL;
  19226. PyObject *__pyx_v_item = NULL;
  19227. PyObject *__pyx_v_item_key = NULL;
  19228. PyObject *__pyx_v_item_value = NULL;
  19229. int __pyx_r;
  19230. __Pyx_RefNannyDeclarations
  19231. PyObject *__pyx_t_1 = NULL;
  19232. int __pyx_t_2;
  19233. int __pyx_t_3;
  19234. int __pyx_t_4;
  19235. PyObject *__pyx_t_5 = NULL;
  19236. PyObject *__pyx_t_6 = NULL;
  19237. PyObject *__pyx_t_7 = NULL;
  19238. PyObject *__pyx_t_8 = NULL;
  19239. PyObject *__pyx_t_9 = NULL;
  19240. Py_ssize_t __pyx_t_10;
  19241. PyObject *(*__pyx_t_11)(PyObject *);
  19242. PyObject *(*__pyx_t_12)(PyObject *);
  19243. __Pyx_RefNannySetupContext("_serialize_node", 0);
  19244. /* "_yaml.pyx":1387
  19245. * cdef yaml_sequence_style_t sequence_style
  19246. * cdef yaml_mapping_style_t mapping_style
  19247. * anchor_object = self.anchors[node] # <<<<<<<<<<<<<<
  19248. * anchor = NULL
  19249. * if anchor_object is not None:
  19250. */
  19251. __pyx_t_1 = __Pyx_PyObject_GetItem(__pyx_v_self->anchors, __pyx_v_node); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1387, __pyx_L1_error)
  19252. __Pyx_GOTREF(__pyx_t_1);
  19253. __pyx_v_anchor_object = __pyx_t_1;
  19254. __pyx_t_1 = 0;
  19255. /* "_yaml.pyx":1388
  19256. * cdef yaml_mapping_style_t mapping_style
  19257. * anchor_object = self.anchors[node]
  19258. * anchor = NULL # <<<<<<<<<<<<<<
  19259. * if anchor_object is not None:
  19260. * if PyUnicode_CheckExact(anchor_object):
  19261. */
  19262. __pyx_v_anchor = NULL;
  19263. /* "_yaml.pyx":1389
  19264. * anchor_object = self.anchors[node]
  19265. * anchor = NULL
  19266. * if anchor_object is not None: # <<<<<<<<<<<<<<
  19267. * if PyUnicode_CheckExact(anchor_object):
  19268. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  19269. */
  19270. __pyx_t_2 = (__pyx_v_anchor_object != Py_None);
  19271. __pyx_t_3 = (__pyx_t_2 != 0);
  19272. if (__pyx_t_3) {
  19273. /* "_yaml.pyx":1390
  19274. * anchor = NULL
  19275. * if anchor_object is not None:
  19276. * if PyUnicode_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  19277. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  19278. * if not PyString_CheckExact(anchor_object):
  19279. */
  19280. __pyx_t_3 = (PyUnicode_CheckExact(__pyx_v_anchor_object) != 0);
  19281. if (__pyx_t_3) {
  19282. /* "_yaml.pyx":1391
  19283. * if anchor_object is not None:
  19284. * if PyUnicode_CheckExact(anchor_object):
  19285. * anchor_object = PyUnicode_AsUTF8String(anchor_object) # <<<<<<<<<<<<<<
  19286. * if not PyString_CheckExact(anchor_object):
  19287. * if PY_MAJOR_VERSION < 3:
  19288. */
  19289. __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_anchor_object); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1391, __pyx_L1_error)
  19290. __Pyx_GOTREF(__pyx_t_1);
  19291. __Pyx_DECREF_SET(__pyx_v_anchor_object, __pyx_t_1);
  19292. __pyx_t_1 = 0;
  19293. /* "_yaml.pyx":1390
  19294. * anchor = NULL
  19295. * if anchor_object is not None:
  19296. * if PyUnicode_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  19297. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  19298. * if not PyString_CheckExact(anchor_object):
  19299. */
  19300. }
  19301. /* "_yaml.pyx":1392
  19302. * if PyUnicode_CheckExact(anchor_object):
  19303. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  19304. * if not PyString_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  19305. * if PY_MAJOR_VERSION < 3:
  19306. * raise TypeError("anchor must be a string")
  19307. */
  19308. __pyx_t_3 = ((!(PyString_CheckExact(__pyx_v_anchor_object) != 0)) != 0);
  19309. if (__pyx_t_3) {
  19310. /* "_yaml.pyx":1393
  19311. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  19312. * if not PyString_CheckExact(anchor_object):
  19313. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  19314. * raise TypeError("anchor must be a string")
  19315. * else:
  19316. */
  19317. __pyx_t_3 = ((PY_MAJOR_VERSION < 3) != 0);
  19318. if (unlikely(__pyx_t_3)) {
  19319. /* "_yaml.pyx":1394
  19320. * if not PyString_CheckExact(anchor_object):
  19321. * if PY_MAJOR_VERSION < 3:
  19322. * raise TypeError("anchor must be a string") # <<<<<<<<<<<<<<
  19323. * else:
  19324. * raise TypeError(u"anchor must be a string")
  19325. */
  19326. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__30, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1394, __pyx_L1_error)
  19327. __Pyx_GOTREF(__pyx_t_1);
  19328. __Pyx_Raise(__pyx_t_1, 0, 0, 0);
  19329. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  19330. __PYX_ERR(0, 1394, __pyx_L1_error)
  19331. /* "_yaml.pyx":1393
  19332. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  19333. * if not PyString_CheckExact(anchor_object):
  19334. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  19335. * raise TypeError("anchor must be a string")
  19336. * else:
  19337. */
  19338. }
  19339. /* "_yaml.pyx":1396
  19340. * raise TypeError("anchor must be a string")
  19341. * else:
  19342. * raise TypeError(u"anchor must be a string") # <<<<<<<<<<<<<<
  19343. * anchor = PyString_AS_STRING(anchor_object)
  19344. * if node in self.serialized_nodes:
  19345. */
  19346. /*else*/ {
  19347. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__31, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1396, __pyx_L1_error)
  19348. __Pyx_GOTREF(__pyx_t_1);
  19349. __Pyx_Raise(__pyx_t_1, 0, 0, 0);
  19350. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  19351. __PYX_ERR(0, 1396, __pyx_L1_error)
  19352. }
  19353. /* "_yaml.pyx":1392
  19354. * if PyUnicode_CheckExact(anchor_object):
  19355. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  19356. * if not PyString_CheckExact(anchor_object): # <<<<<<<<<<<<<<
  19357. * if PY_MAJOR_VERSION < 3:
  19358. * raise TypeError("anchor must be a string")
  19359. */
  19360. }
  19361. /* "_yaml.pyx":1397
  19362. * else:
  19363. * raise TypeError(u"anchor must be a string")
  19364. * anchor = PyString_AS_STRING(anchor_object) # <<<<<<<<<<<<<<
  19365. * if node in self.serialized_nodes:
  19366. * if yaml_alias_event_initialize(&event, anchor) == 0:
  19367. */
  19368. __pyx_v_anchor = PyString_AS_STRING(__pyx_v_anchor_object);
  19369. /* "_yaml.pyx":1389
  19370. * anchor_object = self.anchors[node]
  19371. * anchor = NULL
  19372. * if anchor_object is not None: # <<<<<<<<<<<<<<
  19373. * if PyUnicode_CheckExact(anchor_object):
  19374. * anchor_object = PyUnicode_AsUTF8String(anchor_object)
  19375. */
  19376. }
  19377. /* "_yaml.pyx":1398
  19378. * raise TypeError(u"anchor must be a string")
  19379. * anchor = PyString_AS_STRING(anchor_object)
  19380. * if node in self.serialized_nodes: # <<<<<<<<<<<<<<
  19381. * if yaml_alias_event_initialize(&event, anchor) == 0:
  19382. * raise MemoryError
  19383. */
  19384. __pyx_t_3 = (__Pyx_PySequence_ContainsTF(__pyx_v_node, __pyx_v_self->serialized_nodes, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1398, __pyx_L1_error)
  19385. __pyx_t_2 = (__pyx_t_3 != 0);
  19386. if (__pyx_t_2) {
  19387. /* "_yaml.pyx":1399
  19388. * anchor = PyString_AS_STRING(anchor_object)
  19389. * if node in self.serialized_nodes:
  19390. * if yaml_alias_event_initialize(&event, anchor) == 0: # <<<<<<<<<<<<<<
  19391. * raise MemoryError
  19392. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  19393. */
  19394. __pyx_t_2 = ((yaml_alias_event_initialize((&__pyx_v_event), __pyx_v_anchor) == 0) != 0);
  19395. if (unlikely(__pyx_t_2)) {
  19396. /* "_yaml.pyx":1400
  19397. * if node in self.serialized_nodes:
  19398. * if yaml_alias_event_initialize(&event, anchor) == 0:
  19399. * raise MemoryError # <<<<<<<<<<<<<<
  19400. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  19401. * error = self._emitter_error()
  19402. */
  19403. PyErr_NoMemory(); __PYX_ERR(0, 1400, __pyx_L1_error)
  19404. /* "_yaml.pyx":1399
  19405. * anchor = PyString_AS_STRING(anchor_object)
  19406. * if node in self.serialized_nodes:
  19407. * if yaml_alias_event_initialize(&event, anchor) == 0: # <<<<<<<<<<<<<<
  19408. * raise MemoryError
  19409. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  19410. */
  19411. }
  19412. /* "_yaml.pyx":1401
  19413. * if yaml_alias_event_initialize(&event, anchor) == 0:
  19414. * raise MemoryError
  19415. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  19416. * error = self._emitter_error()
  19417. * raise error
  19418. */
  19419. __pyx_t_4 = yaml_emitter_emit((&__pyx_v_self->emitter), (&__pyx_v_event)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 1401, __pyx_L1_error)
  19420. __pyx_t_2 = ((__pyx_t_4 == 0) != 0);
  19421. if (unlikely(__pyx_t_2)) {
  19422. /* "_yaml.pyx":1402
  19423. * raise MemoryError
  19424. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  19425. * error = self._emitter_error() # <<<<<<<<<<<<<<
  19426. * raise error
  19427. * else:
  19428. */
  19429. __pyx_t_1 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_emitter_error(__pyx_v_self); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1402, __pyx_L1_error)
  19430. __Pyx_GOTREF(__pyx_t_1);
  19431. __pyx_v_error = __pyx_t_1;
  19432. __pyx_t_1 = 0;
  19433. /* "_yaml.pyx":1403
  19434. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  19435. * error = self._emitter_error()
  19436. * raise error # <<<<<<<<<<<<<<
  19437. * else:
  19438. * node_class = node.__class__
  19439. */
  19440. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  19441. __PYX_ERR(0, 1403, __pyx_L1_error)
  19442. /* "_yaml.pyx":1401
  19443. * if yaml_alias_event_initialize(&event, anchor) == 0:
  19444. * raise MemoryError
  19445. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  19446. * error = self._emitter_error()
  19447. * raise error
  19448. */
  19449. }
  19450. /* "_yaml.pyx":1398
  19451. * raise TypeError(u"anchor must be a string")
  19452. * anchor = PyString_AS_STRING(anchor_object)
  19453. * if node in self.serialized_nodes: # <<<<<<<<<<<<<<
  19454. * if yaml_alias_event_initialize(&event, anchor) == 0:
  19455. * raise MemoryError
  19456. */
  19457. goto __pyx_L7;
  19458. }
  19459. /* "_yaml.pyx":1405
  19460. * raise error
  19461. * else:
  19462. * node_class = node.__class__ # <<<<<<<<<<<<<<
  19463. * self.serialized_nodes[node] = True
  19464. * self.descend_resolver(parent, index)
  19465. */
  19466. /*else*/ {
  19467. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_class); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1405, __pyx_L1_error)
  19468. __Pyx_GOTREF(__pyx_t_1);
  19469. __pyx_v_node_class = __pyx_t_1;
  19470. __pyx_t_1 = 0;
  19471. /* "_yaml.pyx":1406
  19472. * else:
  19473. * node_class = node.__class__
  19474. * self.serialized_nodes[node] = True # <<<<<<<<<<<<<<
  19475. * self.descend_resolver(parent, index)
  19476. * if node_class is ScalarNode:
  19477. */
  19478. if (unlikely(PyObject_SetItem(__pyx_v_self->serialized_nodes, __pyx_v_node, Py_True) < 0)) __PYX_ERR(0, 1406, __pyx_L1_error)
  19479. /* "_yaml.pyx":1407
  19480. * node_class = node.__class__
  19481. * self.serialized_nodes[node] = True
  19482. * self.descend_resolver(parent, index) # <<<<<<<<<<<<<<
  19483. * if node_class is ScalarNode:
  19484. * plain_implicit = 0
  19485. */
  19486. __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_descend_resolver); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1407, __pyx_L1_error)
  19487. __Pyx_GOTREF(__pyx_t_5);
  19488. __pyx_t_6 = NULL;
  19489. __pyx_t_4 = 0;
  19490. if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) {
  19491. __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5);
  19492. if (likely(__pyx_t_6)) {
  19493. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5);
  19494. __Pyx_INCREF(__pyx_t_6);
  19495. __Pyx_INCREF(function);
  19496. __Pyx_DECREF_SET(__pyx_t_5, function);
  19497. __pyx_t_4 = 1;
  19498. }
  19499. }
  19500. #if CYTHON_FAST_PYCALL
  19501. if (PyFunction_Check(__pyx_t_5)) {
  19502. PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_v_parent, __pyx_v_index};
  19503. __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_4, 2+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1407, __pyx_L1_error)
  19504. __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
  19505. __Pyx_GOTREF(__pyx_t_1);
  19506. } else
  19507. #endif
  19508. #if CYTHON_FAST_PYCCALL
  19509. if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) {
  19510. PyObject *__pyx_temp[3] = {__pyx_t_6, __pyx_v_parent, __pyx_v_index};
  19511. __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_4, 2+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1407, __pyx_L1_error)
  19512. __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
  19513. __Pyx_GOTREF(__pyx_t_1);
  19514. } else
  19515. #endif
  19516. {
  19517. __pyx_t_7 = PyTuple_New(2+__pyx_t_4); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 1407, __pyx_L1_error)
  19518. __Pyx_GOTREF(__pyx_t_7);
  19519. if (__pyx_t_6) {
  19520. __Pyx_GIVEREF(__pyx_t_6); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_6); __pyx_t_6 = NULL;
  19521. }
  19522. __Pyx_INCREF(__pyx_v_parent);
  19523. __Pyx_GIVEREF(__pyx_v_parent);
  19524. PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_4, __pyx_v_parent);
  19525. __Pyx_INCREF(__pyx_v_index);
  19526. __Pyx_GIVEREF(__pyx_v_index);
  19527. PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_4, __pyx_v_index);
  19528. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1407, __pyx_L1_error)
  19529. __Pyx_GOTREF(__pyx_t_1);
  19530. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  19531. }
  19532. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  19533. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  19534. /* "_yaml.pyx":1408
  19535. * self.serialized_nodes[node] = True
  19536. * self.descend_resolver(parent, index)
  19537. * if node_class is ScalarNode: # <<<<<<<<<<<<<<
  19538. * plain_implicit = 0
  19539. * quoted_implicit = 0
  19540. */
  19541. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_ScalarNode); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1408, __pyx_L1_error)
  19542. __Pyx_GOTREF(__pyx_t_1);
  19543. __pyx_t_2 = (__pyx_v_node_class == __pyx_t_1);
  19544. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  19545. __pyx_t_3 = (__pyx_t_2 != 0);
  19546. if (__pyx_t_3) {
  19547. /* "_yaml.pyx":1409
  19548. * self.descend_resolver(parent, index)
  19549. * if node_class is ScalarNode:
  19550. * plain_implicit = 0 # <<<<<<<<<<<<<<
  19551. * quoted_implicit = 0
  19552. * tag_object = node.tag
  19553. */
  19554. __pyx_v_plain_implicit = 0;
  19555. /* "_yaml.pyx":1410
  19556. * if node_class is ScalarNode:
  19557. * plain_implicit = 0
  19558. * quoted_implicit = 0 # <<<<<<<<<<<<<<
  19559. * tag_object = node.tag
  19560. * if self.resolve(ScalarNode, node.value, (True, False)) == tag_object:
  19561. */
  19562. __pyx_v_quoted_implicit = 0;
  19563. /* "_yaml.pyx":1411
  19564. * plain_implicit = 0
  19565. * quoted_implicit = 0
  19566. * tag_object = node.tag # <<<<<<<<<<<<<<
  19567. * if self.resolve(ScalarNode, node.value, (True, False)) == tag_object:
  19568. * plain_implicit = 1
  19569. */
  19570. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_tag); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1411, __pyx_L1_error)
  19571. __Pyx_GOTREF(__pyx_t_1);
  19572. __pyx_v_tag_object = __pyx_t_1;
  19573. __pyx_t_1 = 0;
  19574. /* "_yaml.pyx":1412
  19575. * quoted_implicit = 0
  19576. * tag_object = node.tag
  19577. * if self.resolve(ScalarNode, node.value, (True, False)) == tag_object: # <<<<<<<<<<<<<<
  19578. * plain_implicit = 1
  19579. * if self.resolve(ScalarNode, node.value, (False, True)) == tag_object:
  19580. */
  19581. __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_resolve); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1412, __pyx_L1_error)
  19582. __Pyx_GOTREF(__pyx_t_5);
  19583. __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_ScalarNode); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 1412, __pyx_L1_error)
  19584. __Pyx_GOTREF(__pyx_t_7);
  19585. __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_value); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 1412, __pyx_L1_error)
  19586. __Pyx_GOTREF(__pyx_t_6);
  19587. __pyx_t_8 = NULL;
  19588. __pyx_t_4 = 0;
  19589. if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) {
  19590. __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_5);
  19591. if (likely(__pyx_t_8)) {
  19592. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5);
  19593. __Pyx_INCREF(__pyx_t_8);
  19594. __Pyx_INCREF(function);
  19595. __Pyx_DECREF_SET(__pyx_t_5, function);
  19596. __pyx_t_4 = 1;
  19597. }
  19598. }
  19599. #if CYTHON_FAST_PYCALL
  19600. if (PyFunction_Check(__pyx_t_5)) {
  19601. PyObject *__pyx_temp[4] = {__pyx_t_8, __pyx_t_7, __pyx_t_6, __pyx_tuple__36};
  19602. __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_4, 3+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1412, __pyx_L1_error)
  19603. __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
  19604. __Pyx_GOTREF(__pyx_t_1);
  19605. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  19606. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  19607. } else
  19608. #endif
  19609. #if CYTHON_FAST_PYCCALL
  19610. if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) {
  19611. PyObject *__pyx_temp[4] = {__pyx_t_8, __pyx_t_7, __pyx_t_6, __pyx_tuple__36};
  19612. __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_4, 3+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1412, __pyx_L1_error)
  19613. __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
  19614. __Pyx_GOTREF(__pyx_t_1);
  19615. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  19616. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  19617. } else
  19618. #endif
  19619. {
  19620. __pyx_t_9 = PyTuple_New(3+__pyx_t_4); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 1412, __pyx_L1_error)
  19621. __Pyx_GOTREF(__pyx_t_9);
  19622. if (__pyx_t_8) {
  19623. __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_8); __pyx_t_8 = NULL;
  19624. }
  19625. __Pyx_GIVEREF(__pyx_t_7);
  19626. PyTuple_SET_ITEM(__pyx_t_9, 0+__pyx_t_4, __pyx_t_7);
  19627. __Pyx_GIVEREF(__pyx_t_6);
  19628. PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_4, __pyx_t_6);
  19629. __Pyx_INCREF(__pyx_tuple__36);
  19630. __Pyx_GIVEREF(__pyx_tuple__36);
  19631. PyTuple_SET_ITEM(__pyx_t_9, 2+__pyx_t_4, __pyx_tuple__36);
  19632. __pyx_t_7 = 0;
  19633. __pyx_t_6 = 0;
  19634. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_9, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1412, __pyx_L1_error)
  19635. __Pyx_GOTREF(__pyx_t_1);
  19636. __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
  19637. }
  19638. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  19639. __pyx_t_5 = PyObject_RichCompare(__pyx_t_1, __pyx_v_tag_object, Py_EQ); __Pyx_XGOTREF(__pyx_t_5); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1412, __pyx_L1_error)
  19640. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  19641. __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1412, __pyx_L1_error)
  19642. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  19643. if (__pyx_t_3) {
  19644. /* "_yaml.pyx":1413
  19645. * tag_object = node.tag
  19646. * if self.resolve(ScalarNode, node.value, (True, False)) == tag_object:
  19647. * plain_implicit = 1 # <<<<<<<<<<<<<<
  19648. * if self.resolve(ScalarNode, node.value, (False, True)) == tag_object:
  19649. * quoted_implicit = 1
  19650. */
  19651. __pyx_v_plain_implicit = 1;
  19652. /* "_yaml.pyx":1412
  19653. * quoted_implicit = 0
  19654. * tag_object = node.tag
  19655. * if self.resolve(ScalarNode, node.value, (True, False)) == tag_object: # <<<<<<<<<<<<<<
  19656. * plain_implicit = 1
  19657. * if self.resolve(ScalarNode, node.value, (False, True)) == tag_object:
  19658. */
  19659. }
  19660. /* "_yaml.pyx":1414
  19661. * if self.resolve(ScalarNode, node.value, (True, False)) == tag_object:
  19662. * plain_implicit = 1
  19663. * if self.resolve(ScalarNode, node.value, (False, True)) == tag_object: # <<<<<<<<<<<<<<
  19664. * quoted_implicit = 1
  19665. * tag = NULL
  19666. */
  19667. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_resolve); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1414, __pyx_L1_error)
  19668. __Pyx_GOTREF(__pyx_t_1);
  19669. __Pyx_GetModuleGlobalName(__pyx_t_9, __pyx_n_s_ScalarNode); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 1414, __pyx_L1_error)
  19670. __Pyx_GOTREF(__pyx_t_9);
  19671. __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_value); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 1414, __pyx_L1_error)
  19672. __Pyx_GOTREF(__pyx_t_6);
  19673. __pyx_t_7 = NULL;
  19674. __pyx_t_4 = 0;
  19675. if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_1))) {
  19676. __pyx_t_7 = PyMethod_GET_SELF(__pyx_t_1);
  19677. if (likely(__pyx_t_7)) {
  19678. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_1);
  19679. __Pyx_INCREF(__pyx_t_7);
  19680. __Pyx_INCREF(function);
  19681. __Pyx_DECREF_SET(__pyx_t_1, function);
  19682. __pyx_t_4 = 1;
  19683. }
  19684. }
  19685. #if CYTHON_FAST_PYCALL
  19686. if (PyFunction_Check(__pyx_t_1)) {
  19687. PyObject *__pyx_temp[4] = {__pyx_t_7, __pyx_t_9, __pyx_t_6, __pyx_tuple__37};
  19688. __pyx_t_5 = __Pyx_PyFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_4, 3+__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1414, __pyx_L1_error)
  19689. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  19690. __Pyx_GOTREF(__pyx_t_5);
  19691. __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
  19692. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  19693. } else
  19694. #endif
  19695. #if CYTHON_FAST_PYCCALL
  19696. if (__Pyx_PyFastCFunction_Check(__pyx_t_1)) {
  19697. PyObject *__pyx_temp[4] = {__pyx_t_7, __pyx_t_9, __pyx_t_6, __pyx_tuple__37};
  19698. __pyx_t_5 = __Pyx_PyCFunction_FastCall(__pyx_t_1, __pyx_temp+1-__pyx_t_4, 3+__pyx_t_4); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1414, __pyx_L1_error)
  19699. __Pyx_XDECREF(__pyx_t_7); __pyx_t_7 = 0;
  19700. __Pyx_GOTREF(__pyx_t_5);
  19701. __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
  19702. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  19703. } else
  19704. #endif
  19705. {
  19706. __pyx_t_8 = PyTuple_New(3+__pyx_t_4); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 1414, __pyx_L1_error)
  19707. __Pyx_GOTREF(__pyx_t_8);
  19708. if (__pyx_t_7) {
  19709. __Pyx_GIVEREF(__pyx_t_7); PyTuple_SET_ITEM(__pyx_t_8, 0, __pyx_t_7); __pyx_t_7 = NULL;
  19710. }
  19711. __Pyx_GIVEREF(__pyx_t_9);
  19712. PyTuple_SET_ITEM(__pyx_t_8, 0+__pyx_t_4, __pyx_t_9);
  19713. __Pyx_GIVEREF(__pyx_t_6);
  19714. PyTuple_SET_ITEM(__pyx_t_8, 1+__pyx_t_4, __pyx_t_6);
  19715. __Pyx_INCREF(__pyx_tuple__37);
  19716. __Pyx_GIVEREF(__pyx_tuple__37);
  19717. PyTuple_SET_ITEM(__pyx_t_8, 2+__pyx_t_4, __pyx_tuple__37);
  19718. __pyx_t_9 = 0;
  19719. __pyx_t_6 = 0;
  19720. __pyx_t_5 = __Pyx_PyObject_Call(__pyx_t_1, __pyx_t_8, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1414, __pyx_L1_error)
  19721. __Pyx_GOTREF(__pyx_t_5);
  19722. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  19723. }
  19724. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  19725. __pyx_t_1 = PyObject_RichCompare(__pyx_t_5, __pyx_v_tag_object, Py_EQ); __Pyx_XGOTREF(__pyx_t_1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1414, __pyx_L1_error)
  19726. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  19727. __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_1); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1414, __pyx_L1_error)
  19728. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  19729. if (__pyx_t_3) {
  19730. /* "_yaml.pyx":1415
  19731. * plain_implicit = 1
  19732. * if self.resolve(ScalarNode, node.value, (False, True)) == tag_object:
  19733. * quoted_implicit = 1 # <<<<<<<<<<<<<<
  19734. * tag = NULL
  19735. * if tag_object is not None:
  19736. */
  19737. __pyx_v_quoted_implicit = 1;
  19738. /* "_yaml.pyx":1414
  19739. * if self.resolve(ScalarNode, node.value, (True, False)) == tag_object:
  19740. * plain_implicit = 1
  19741. * if self.resolve(ScalarNode, node.value, (False, True)) == tag_object: # <<<<<<<<<<<<<<
  19742. * quoted_implicit = 1
  19743. * tag = NULL
  19744. */
  19745. }
  19746. /* "_yaml.pyx":1416
  19747. * if self.resolve(ScalarNode, node.value, (False, True)) == tag_object:
  19748. * quoted_implicit = 1
  19749. * tag = NULL # <<<<<<<<<<<<<<
  19750. * if tag_object is not None:
  19751. * if PyUnicode_CheckExact(tag_object):
  19752. */
  19753. __pyx_v_tag = NULL;
  19754. /* "_yaml.pyx":1417
  19755. * quoted_implicit = 1
  19756. * tag = NULL
  19757. * if tag_object is not None: # <<<<<<<<<<<<<<
  19758. * if PyUnicode_CheckExact(tag_object):
  19759. * tag_object = PyUnicode_AsUTF8String(tag_object)
  19760. */
  19761. __pyx_t_3 = (__pyx_v_tag_object != Py_None);
  19762. __pyx_t_2 = (__pyx_t_3 != 0);
  19763. if (__pyx_t_2) {
  19764. /* "_yaml.pyx":1418
  19765. * tag = NULL
  19766. * if tag_object is not None:
  19767. * if PyUnicode_CheckExact(tag_object): # <<<<<<<<<<<<<<
  19768. * tag_object = PyUnicode_AsUTF8String(tag_object)
  19769. * if not PyString_CheckExact(tag_object):
  19770. */
  19771. __pyx_t_2 = (PyUnicode_CheckExact(__pyx_v_tag_object) != 0);
  19772. if (__pyx_t_2) {
  19773. /* "_yaml.pyx":1419
  19774. * if tag_object is not None:
  19775. * if PyUnicode_CheckExact(tag_object):
  19776. * tag_object = PyUnicode_AsUTF8String(tag_object) # <<<<<<<<<<<<<<
  19777. * if not PyString_CheckExact(tag_object):
  19778. * if PY_MAJOR_VERSION < 3:
  19779. */
  19780. __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_tag_object); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1419, __pyx_L1_error)
  19781. __Pyx_GOTREF(__pyx_t_1);
  19782. __Pyx_DECREF_SET(__pyx_v_tag_object, __pyx_t_1);
  19783. __pyx_t_1 = 0;
  19784. /* "_yaml.pyx":1418
  19785. * tag = NULL
  19786. * if tag_object is not None:
  19787. * if PyUnicode_CheckExact(tag_object): # <<<<<<<<<<<<<<
  19788. * tag_object = PyUnicode_AsUTF8String(tag_object)
  19789. * if not PyString_CheckExact(tag_object):
  19790. */
  19791. }
  19792. /* "_yaml.pyx":1420
  19793. * if PyUnicode_CheckExact(tag_object):
  19794. * tag_object = PyUnicode_AsUTF8String(tag_object)
  19795. * if not PyString_CheckExact(tag_object): # <<<<<<<<<<<<<<
  19796. * if PY_MAJOR_VERSION < 3:
  19797. * raise TypeError("tag must be a string")
  19798. */
  19799. __pyx_t_2 = ((!(PyString_CheckExact(__pyx_v_tag_object) != 0)) != 0);
  19800. if (__pyx_t_2) {
  19801. /* "_yaml.pyx":1421
  19802. * tag_object = PyUnicode_AsUTF8String(tag_object)
  19803. * if not PyString_CheckExact(tag_object):
  19804. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  19805. * raise TypeError("tag must be a string")
  19806. * else:
  19807. */
  19808. __pyx_t_2 = ((PY_MAJOR_VERSION < 3) != 0);
  19809. if (unlikely(__pyx_t_2)) {
  19810. /* "_yaml.pyx":1422
  19811. * if not PyString_CheckExact(tag_object):
  19812. * if PY_MAJOR_VERSION < 3:
  19813. * raise TypeError("tag must be a string") # <<<<<<<<<<<<<<
  19814. * else:
  19815. * raise TypeError(u"tag must be a string")
  19816. */
  19817. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__32, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1422, __pyx_L1_error)
  19818. __Pyx_GOTREF(__pyx_t_1);
  19819. __Pyx_Raise(__pyx_t_1, 0, 0, 0);
  19820. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  19821. __PYX_ERR(0, 1422, __pyx_L1_error)
  19822. /* "_yaml.pyx":1421
  19823. * tag_object = PyUnicode_AsUTF8String(tag_object)
  19824. * if not PyString_CheckExact(tag_object):
  19825. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  19826. * raise TypeError("tag must be a string")
  19827. * else:
  19828. */
  19829. }
  19830. /* "_yaml.pyx":1424
  19831. * raise TypeError("tag must be a string")
  19832. * else:
  19833. * raise TypeError(u"tag must be a string") # <<<<<<<<<<<<<<
  19834. * tag = PyString_AS_STRING(tag_object)
  19835. * value_object = node.value
  19836. */
  19837. /*else*/ {
  19838. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__33, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1424, __pyx_L1_error)
  19839. __Pyx_GOTREF(__pyx_t_1);
  19840. __Pyx_Raise(__pyx_t_1, 0, 0, 0);
  19841. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  19842. __PYX_ERR(0, 1424, __pyx_L1_error)
  19843. }
  19844. /* "_yaml.pyx":1420
  19845. * if PyUnicode_CheckExact(tag_object):
  19846. * tag_object = PyUnicode_AsUTF8String(tag_object)
  19847. * if not PyString_CheckExact(tag_object): # <<<<<<<<<<<<<<
  19848. * if PY_MAJOR_VERSION < 3:
  19849. * raise TypeError("tag must be a string")
  19850. */
  19851. }
  19852. /* "_yaml.pyx":1425
  19853. * else:
  19854. * raise TypeError(u"tag must be a string")
  19855. * tag = PyString_AS_STRING(tag_object) # <<<<<<<<<<<<<<
  19856. * value_object = node.value
  19857. * if PyUnicode_CheckExact(value_object):
  19858. */
  19859. __pyx_v_tag = PyString_AS_STRING(__pyx_v_tag_object);
  19860. /* "_yaml.pyx":1417
  19861. * quoted_implicit = 1
  19862. * tag = NULL
  19863. * if tag_object is not None: # <<<<<<<<<<<<<<
  19864. * if PyUnicode_CheckExact(tag_object):
  19865. * tag_object = PyUnicode_AsUTF8String(tag_object)
  19866. */
  19867. }
  19868. /* "_yaml.pyx":1426
  19869. * raise TypeError(u"tag must be a string")
  19870. * tag = PyString_AS_STRING(tag_object)
  19871. * value_object = node.value # <<<<<<<<<<<<<<
  19872. * if PyUnicode_CheckExact(value_object):
  19873. * value_object = PyUnicode_AsUTF8String(value_object)
  19874. */
  19875. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_value); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1426, __pyx_L1_error)
  19876. __Pyx_GOTREF(__pyx_t_1);
  19877. __pyx_v_value_object = __pyx_t_1;
  19878. __pyx_t_1 = 0;
  19879. /* "_yaml.pyx":1427
  19880. * tag = PyString_AS_STRING(tag_object)
  19881. * value_object = node.value
  19882. * if PyUnicode_CheckExact(value_object): # <<<<<<<<<<<<<<
  19883. * value_object = PyUnicode_AsUTF8String(value_object)
  19884. * if not PyString_CheckExact(value_object):
  19885. */
  19886. __pyx_t_2 = (PyUnicode_CheckExact(__pyx_v_value_object) != 0);
  19887. if (__pyx_t_2) {
  19888. /* "_yaml.pyx":1428
  19889. * value_object = node.value
  19890. * if PyUnicode_CheckExact(value_object):
  19891. * value_object = PyUnicode_AsUTF8String(value_object) # <<<<<<<<<<<<<<
  19892. * if not PyString_CheckExact(value_object):
  19893. * if PY_MAJOR_VERSION < 3:
  19894. */
  19895. __pyx_t_1 = PyUnicode_AsUTF8String(__pyx_v_value_object); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1428, __pyx_L1_error)
  19896. __Pyx_GOTREF(__pyx_t_1);
  19897. __Pyx_DECREF_SET(__pyx_v_value_object, __pyx_t_1);
  19898. __pyx_t_1 = 0;
  19899. /* "_yaml.pyx":1427
  19900. * tag = PyString_AS_STRING(tag_object)
  19901. * value_object = node.value
  19902. * if PyUnicode_CheckExact(value_object): # <<<<<<<<<<<<<<
  19903. * value_object = PyUnicode_AsUTF8String(value_object)
  19904. * if not PyString_CheckExact(value_object):
  19905. */
  19906. }
  19907. /* "_yaml.pyx":1429
  19908. * if PyUnicode_CheckExact(value_object):
  19909. * value_object = PyUnicode_AsUTF8String(value_object)
  19910. * if not PyString_CheckExact(value_object): # <<<<<<<<<<<<<<
  19911. * if PY_MAJOR_VERSION < 3:
  19912. * raise TypeError("value must be a string")
  19913. */
  19914. __pyx_t_2 = ((!(PyString_CheckExact(__pyx_v_value_object) != 0)) != 0);
  19915. if (__pyx_t_2) {
  19916. /* "_yaml.pyx":1430
  19917. * value_object = PyUnicode_AsUTF8String(value_object)
  19918. * if not PyString_CheckExact(value_object):
  19919. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  19920. * raise TypeError("value must be a string")
  19921. * else:
  19922. */
  19923. __pyx_t_2 = ((PY_MAJOR_VERSION < 3) != 0);
  19924. if (unlikely(__pyx_t_2)) {
  19925. /* "_yaml.pyx":1431
  19926. * if not PyString_CheckExact(value_object):
  19927. * if PY_MAJOR_VERSION < 3:
  19928. * raise TypeError("value must be a string") # <<<<<<<<<<<<<<
  19929. * else:
  19930. * raise TypeError(u"value must be a string")
  19931. */
  19932. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__34, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1431, __pyx_L1_error)
  19933. __Pyx_GOTREF(__pyx_t_1);
  19934. __Pyx_Raise(__pyx_t_1, 0, 0, 0);
  19935. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  19936. __PYX_ERR(0, 1431, __pyx_L1_error)
  19937. /* "_yaml.pyx":1430
  19938. * value_object = PyUnicode_AsUTF8String(value_object)
  19939. * if not PyString_CheckExact(value_object):
  19940. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  19941. * raise TypeError("value must be a string")
  19942. * else:
  19943. */
  19944. }
  19945. /* "_yaml.pyx":1433
  19946. * raise TypeError("value must be a string")
  19947. * else:
  19948. * raise TypeError(u"value must be a string") # <<<<<<<<<<<<<<
  19949. * value = PyString_AS_STRING(value_object)
  19950. * length = PyString_GET_SIZE(value_object)
  19951. */
  19952. /*else*/ {
  19953. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__35, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1433, __pyx_L1_error)
  19954. __Pyx_GOTREF(__pyx_t_1);
  19955. __Pyx_Raise(__pyx_t_1, 0, 0, 0);
  19956. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  19957. __PYX_ERR(0, 1433, __pyx_L1_error)
  19958. }
  19959. /* "_yaml.pyx":1429
  19960. * if PyUnicode_CheckExact(value_object):
  19961. * value_object = PyUnicode_AsUTF8String(value_object)
  19962. * if not PyString_CheckExact(value_object): # <<<<<<<<<<<<<<
  19963. * if PY_MAJOR_VERSION < 3:
  19964. * raise TypeError("value must be a string")
  19965. */
  19966. }
  19967. /* "_yaml.pyx":1434
  19968. * else:
  19969. * raise TypeError(u"value must be a string")
  19970. * value = PyString_AS_STRING(value_object) # <<<<<<<<<<<<<<
  19971. * length = PyString_GET_SIZE(value_object)
  19972. * style_object = node.style
  19973. */
  19974. __pyx_v_value = PyString_AS_STRING(__pyx_v_value_object);
  19975. /* "_yaml.pyx":1435
  19976. * raise TypeError(u"value must be a string")
  19977. * value = PyString_AS_STRING(value_object)
  19978. * length = PyString_GET_SIZE(value_object) # <<<<<<<<<<<<<<
  19979. * style_object = node.style
  19980. * scalar_style = YAML_PLAIN_SCALAR_STYLE
  19981. */
  19982. __pyx_v_length = PyString_GET_SIZE(__pyx_v_value_object);
  19983. /* "_yaml.pyx":1436
  19984. * value = PyString_AS_STRING(value_object)
  19985. * length = PyString_GET_SIZE(value_object)
  19986. * style_object = node.style # <<<<<<<<<<<<<<
  19987. * scalar_style = YAML_PLAIN_SCALAR_STYLE
  19988. * if style_object == "'" or style_object == u"'":
  19989. */
  19990. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_style); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1436, __pyx_L1_error)
  19991. __Pyx_GOTREF(__pyx_t_1);
  19992. __pyx_v_style_object = __pyx_t_1;
  19993. __pyx_t_1 = 0;
  19994. /* "_yaml.pyx":1437
  19995. * length = PyString_GET_SIZE(value_object)
  19996. * style_object = node.style
  19997. * scalar_style = YAML_PLAIN_SCALAR_STYLE # <<<<<<<<<<<<<<
  19998. * if style_object == "'" or style_object == u"'":
  19999. * scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE
  20000. */
  20001. __pyx_v_scalar_style = YAML_PLAIN_SCALAR_STYLE;
  20002. /* "_yaml.pyx":1438
  20003. * style_object = node.style
  20004. * scalar_style = YAML_PLAIN_SCALAR_STYLE
  20005. * if style_object == "'" or style_object == u"'": # <<<<<<<<<<<<<<
  20006. * scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE
  20007. * elif style_object == "\"" or style_object == u"\"":
  20008. */
  20009. __pyx_t_3 = (__Pyx_PyString_Equals(__pyx_v_style_object, __pyx_kp_s__7, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1438, __pyx_L1_error)
  20010. if (!__pyx_t_3) {
  20011. } else {
  20012. __pyx_t_2 = __pyx_t_3;
  20013. goto __pyx_L21_bool_binop_done;
  20014. }
  20015. __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_style_object, __pyx_kp_u__7, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1438, __pyx_L1_error)
  20016. __pyx_t_2 = __pyx_t_3;
  20017. __pyx_L21_bool_binop_done:;
  20018. if (__pyx_t_2) {
  20019. /* "_yaml.pyx":1439
  20020. * scalar_style = YAML_PLAIN_SCALAR_STYLE
  20021. * if style_object == "'" or style_object == u"'":
  20022. * scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE # <<<<<<<<<<<<<<
  20023. * elif style_object == "\"" or style_object == u"\"":
  20024. * scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE
  20025. */
  20026. __pyx_v_scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE;
  20027. /* "_yaml.pyx":1438
  20028. * style_object = node.style
  20029. * scalar_style = YAML_PLAIN_SCALAR_STYLE
  20030. * if style_object == "'" or style_object == u"'": # <<<<<<<<<<<<<<
  20031. * scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE
  20032. * elif style_object == "\"" or style_object == u"\"":
  20033. */
  20034. goto __pyx_L20;
  20035. }
  20036. /* "_yaml.pyx":1440
  20037. * if style_object == "'" or style_object == u"'":
  20038. * scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE
  20039. * elif style_object == "\"" or style_object == u"\"": # <<<<<<<<<<<<<<
  20040. * scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE
  20041. * elif style_object == "|" or style_object == u"|":
  20042. */
  20043. __pyx_t_3 = (__Pyx_PyString_Equals(__pyx_v_style_object, __pyx_kp_s__8, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1440, __pyx_L1_error)
  20044. if (!__pyx_t_3) {
  20045. } else {
  20046. __pyx_t_2 = __pyx_t_3;
  20047. goto __pyx_L23_bool_binop_done;
  20048. }
  20049. __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_style_object, __pyx_kp_u__8, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1440, __pyx_L1_error)
  20050. __pyx_t_2 = __pyx_t_3;
  20051. __pyx_L23_bool_binop_done:;
  20052. if (__pyx_t_2) {
  20053. /* "_yaml.pyx":1441
  20054. * scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE
  20055. * elif style_object == "\"" or style_object == u"\"":
  20056. * scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE # <<<<<<<<<<<<<<
  20057. * elif style_object == "|" or style_object == u"|":
  20058. * scalar_style = YAML_LITERAL_SCALAR_STYLE
  20059. */
  20060. __pyx_v_scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE;
  20061. /* "_yaml.pyx":1440
  20062. * if style_object == "'" or style_object == u"'":
  20063. * scalar_style = YAML_SINGLE_QUOTED_SCALAR_STYLE
  20064. * elif style_object == "\"" or style_object == u"\"": # <<<<<<<<<<<<<<
  20065. * scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE
  20066. * elif style_object == "|" or style_object == u"|":
  20067. */
  20068. goto __pyx_L20;
  20069. }
  20070. /* "_yaml.pyx":1442
  20071. * elif style_object == "\"" or style_object == u"\"":
  20072. * scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE
  20073. * elif style_object == "|" or style_object == u"|": # <<<<<<<<<<<<<<
  20074. * scalar_style = YAML_LITERAL_SCALAR_STYLE
  20075. * elif style_object == ">" or style_object == u">":
  20076. */
  20077. __pyx_t_3 = (__Pyx_PyString_Equals(__pyx_v_style_object, __pyx_kp_s__9, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1442, __pyx_L1_error)
  20078. if (!__pyx_t_3) {
  20079. } else {
  20080. __pyx_t_2 = __pyx_t_3;
  20081. goto __pyx_L25_bool_binop_done;
  20082. }
  20083. __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_style_object, __pyx_kp_u__9, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1442, __pyx_L1_error)
  20084. __pyx_t_2 = __pyx_t_3;
  20085. __pyx_L25_bool_binop_done:;
  20086. if (__pyx_t_2) {
  20087. /* "_yaml.pyx":1443
  20088. * scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE
  20089. * elif style_object == "|" or style_object == u"|":
  20090. * scalar_style = YAML_LITERAL_SCALAR_STYLE # <<<<<<<<<<<<<<
  20091. * elif style_object == ">" or style_object == u">":
  20092. * scalar_style = YAML_FOLDED_SCALAR_STYLE
  20093. */
  20094. __pyx_v_scalar_style = YAML_LITERAL_SCALAR_STYLE;
  20095. /* "_yaml.pyx":1442
  20096. * elif style_object == "\"" or style_object == u"\"":
  20097. * scalar_style = YAML_DOUBLE_QUOTED_SCALAR_STYLE
  20098. * elif style_object == "|" or style_object == u"|": # <<<<<<<<<<<<<<
  20099. * scalar_style = YAML_LITERAL_SCALAR_STYLE
  20100. * elif style_object == ">" or style_object == u">":
  20101. */
  20102. goto __pyx_L20;
  20103. }
  20104. /* "_yaml.pyx":1444
  20105. * elif style_object == "|" or style_object == u"|":
  20106. * scalar_style = YAML_LITERAL_SCALAR_STYLE
  20107. * elif style_object == ">" or style_object == u">": # <<<<<<<<<<<<<<
  20108. * scalar_style = YAML_FOLDED_SCALAR_STYLE
  20109. * if yaml_scalar_event_initialize(&event, anchor, tag, value, length,
  20110. */
  20111. __pyx_t_3 = (__Pyx_PyString_Equals(__pyx_v_style_object, __pyx_kp_s__10, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1444, __pyx_L1_error)
  20112. if (!__pyx_t_3) {
  20113. } else {
  20114. __pyx_t_2 = __pyx_t_3;
  20115. goto __pyx_L27_bool_binop_done;
  20116. }
  20117. __pyx_t_3 = (__Pyx_PyUnicode_Equals(__pyx_v_style_object, __pyx_kp_u__10, Py_EQ)); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1444, __pyx_L1_error)
  20118. __pyx_t_2 = __pyx_t_3;
  20119. __pyx_L27_bool_binop_done:;
  20120. if (__pyx_t_2) {
  20121. /* "_yaml.pyx":1445
  20122. * scalar_style = YAML_LITERAL_SCALAR_STYLE
  20123. * elif style_object == ">" or style_object == u">":
  20124. * scalar_style = YAML_FOLDED_SCALAR_STYLE # <<<<<<<<<<<<<<
  20125. * if yaml_scalar_event_initialize(&event, anchor, tag, value, length,
  20126. * plain_implicit, quoted_implicit, scalar_style) == 0:
  20127. */
  20128. __pyx_v_scalar_style = YAML_FOLDED_SCALAR_STYLE;
  20129. /* "_yaml.pyx":1444
  20130. * elif style_object == "|" or style_object == u"|":
  20131. * scalar_style = YAML_LITERAL_SCALAR_STYLE
  20132. * elif style_object == ">" or style_object == u">": # <<<<<<<<<<<<<<
  20133. * scalar_style = YAML_FOLDED_SCALAR_STYLE
  20134. * if yaml_scalar_event_initialize(&event, anchor, tag, value, length,
  20135. */
  20136. }
  20137. __pyx_L20:;
  20138. /* "_yaml.pyx":1447
  20139. * scalar_style = YAML_FOLDED_SCALAR_STYLE
  20140. * if yaml_scalar_event_initialize(&event, anchor, tag, value, length,
  20141. * plain_implicit, quoted_implicit, scalar_style) == 0: # <<<<<<<<<<<<<<
  20142. * raise MemoryError
  20143. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  20144. */
  20145. __pyx_t_2 = ((yaml_scalar_event_initialize((&__pyx_v_event), __pyx_v_anchor, __pyx_v_tag, __pyx_v_value, __pyx_v_length, __pyx_v_plain_implicit, __pyx_v_quoted_implicit, __pyx_v_scalar_style) == 0) != 0);
  20146. /* "_yaml.pyx":1446
  20147. * elif style_object == ">" or style_object == u">":
  20148. * scalar_style = YAML_FOLDED_SCALAR_STYLE
  20149. * if yaml_scalar_event_initialize(&event, anchor, tag, value, length, # <<<<<<<<<<<<<<
  20150. * plain_implicit, quoted_implicit, scalar_style) == 0:
  20151. * raise MemoryError
  20152. */
  20153. if (unlikely(__pyx_t_2)) {
  20154. /* "_yaml.pyx":1448
  20155. * if yaml_scalar_event_initialize(&event, anchor, tag, value, length,
  20156. * plain_implicit, quoted_implicit, scalar_style) == 0:
  20157. * raise MemoryError # <<<<<<<<<<<<<<
  20158. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  20159. * error = self._emitter_error()
  20160. */
  20161. PyErr_NoMemory(); __PYX_ERR(0, 1448, __pyx_L1_error)
  20162. /* "_yaml.pyx":1446
  20163. * elif style_object == ">" or style_object == u">":
  20164. * scalar_style = YAML_FOLDED_SCALAR_STYLE
  20165. * if yaml_scalar_event_initialize(&event, anchor, tag, value, length, # <<<<<<<<<<<<<<
  20166. * plain_implicit, quoted_implicit, scalar_style) == 0:
  20167. * raise MemoryError
  20168. */
  20169. }
  20170. /* "_yaml.pyx":1449
  20171. * plain_implicit, quoted_implicit, scalar_style) == 0:
  20172. * raise MemoryError
  20173. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  20174. * error = self._emitter_error()
  20175. * raise error
  20176. */
  20177. __pyx_t_4 = yaml_emitter_emit((&__pyx_v_self->emitter), (&__pyx_v_event)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 1449, __pyx_L1_error)
  20178. __pyx_t_2 = ((__pyx_t_4 == 0) != 0);
  20179. if (unlikely(__pyx_t_2)) {
  20180. /* "_yaml.pyx":1450
  20181. * raise MemoryError
  20182. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  20183. * error = self._emitter_error() # <<<<<<<<<<<<<<
  20184. * raise error
  20185. * elif node_class is SequenceNode:
  20186. */
  20187. __pyx_t_1 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_emitter_error(__pyx_v_self); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1450, __pyx_L1_error)
  20188. __Pyx_GOTREF(__pyx_t_1);
  20189. __pyx_v_error = __pyx_t_1;
  20190. __pyx_t_1 = 0;
  20191. /* "_yaml.pyx":1451
  20192. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  20193. * error = self._emitter_error()
  20194. * raise error # <<<<<<<<<<<<<<
  20195. * elif node_class is SequenceNode:
  20196. * implicit = 0
  20197. */
  20198. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  20199. __PYX_ERR(0, 1451, __pyx_L1_error)
  20200. /* "_yaml.pyx":1449
  20201. * plain_implicit, quoted_implicit, scalar_style) == 0:
  20202. * raise MemoryError
  20203. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  20204. * error = self._emitter_error()
  20205. * raise error
  20206. */
  20207. }
  20208. /* "_yaml.pyx":1408
  20209. * self.serialized_nodes[node] = True
  20210. * self.descend_resolver(parent, index)
  20211. * if node_class is ScalarNode: # <<<<<<<<<<<<<<
  20212. * plain_implicit = 0
  20213. * quoted_implicit = 0
  20214. */
  20215. goto __pyx_L10;
  20216. }
  20217. /* "_yaml.pyx":1452
  20218. * error = self._emitter_error()
  20219. * raise error
  20220. * elif node_class is SequenceNode: # <<<<<<<<<<<<<<
  20221. * implicit = 0
  20222. * tag_object = node.tag
  20223. */
  20224. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_SequenceNode); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1452, __pyx_L1_error)
  20225. __Pyx_GOTREF(__pyx_t_1);
  20226. __pyx_t_2 = (__pyx_v_node_class == __pyx_t_1);
  20227. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  20228. __pyx_t_3 = (__pyx_t_2 != 0);
  20229. if (__pyx_t_3) {
  20230. /* "_yaml.pyx":1453
  20231. * raise error
  20232. * elif node_class is SequenceNode:
  20233. * implicit = 0 # <<<<<<<<<<<<<<
  20234. * tag_object = node.tag
  20235. * if self.resolve(SequenceNode, node.value, True) == tag_object:
  20236. */
  20237. __pyx_v_implicit = 0;
  20238. /* "_yaml.pyx":1454
  20239. * elif node_class is SequenceNode:
  20240. * implicit = 0
  20241. * tag_object = node.tag # <<<<<<<<<<<<<<
  20242. * if self.resolve(SequenceNode, node.value, True) == tag_object:
  20243. * implicit = 1
  20244. */
  20245. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_tag); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1454, __pyx_L1_error)
  20246. __Pyx_GOTREF(__pyx_t_1);
  20247. __pyx_v_tag_object = __pyx_t_1;
  20248. __pyx_t_1 = 0;
  20249. /* "_yaml.pyx":1455
  20250. * implicit = 0
  20251. * tag_object = node.tag
  20252. * if self.resolve(SequenceNode, node.value, True) == tag_object: # <<<<<<<<<<<<<<
  20253. * implicit = 1
  20254. * tag = NULL
  20255. */
  20256. __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_resolve); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1455, __pyx_L1_error)
  20257. __Pyx_GOTREF(__pyx_t_5);
  20258. __Pyx_GetModuleGlobalName(__pyx_t_8, __pyx_n_s_SequenceNode); if (unlikely(!__pyx_t_8)) __PYX_ERR(0, 1455, __pyx_L1_error)
  20259. __Pyx_GOTREF(__pyx_t_8);
  20260. __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_value); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 1455, __pyx_L1_error)
  20261. __Pyx_GOTREF(__pyx_t_6);
  20262. __pyx_t_9 = NULL;
  20263. __pyx_t_4 = 0;
  20264. if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) {
  20265. __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_5);
  20266. if (likely(__pyx_t_9)) {
  20267. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5);
  20268. __Pyx_INCREF(__pyx_t_9);
  20269. __Pyx_INCREF(function);
  20270. __Pyx_DECREF_SET(__pyx_t_5, function);
  20271. __pyx_t_4 = 1;
  20272. }
  20273. }
  20274. #if CYTHON_FAST_PYCALL
  20275. if (PyFunction_Check(__pyx_t_5)) {
  20276. PyObject *__pyx_temp[4] = {__pyx_t_9, __pyx_t_8, __pyx_t_6, Py_True};
  20277. __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_4, 3+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1455, __pyx_L1_error)
  20278. __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
  20279. __Pyx_GOTREF(__pyx_t_1);
  20280. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  20281. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  20282. } else
  20283. #endif
  20284. #if CYTHON_FAST_PYCCALL
  20285. if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) {
  20286. PyObject *__pyx_temp[4] = {__pyx_t_9, __pyx_t_8, __pyx_t_6, Py_True};
  20287. __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_4, 3+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1455, __pyx_L1_error)
  20288. __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
  20289. __Pyx_GOTREF(__pyx_t_1);
  20290. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  20291. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  20292. } else
  20293. #endif
  20294. {
  20295. __pyx_t_7 = PyTuple_New(3+__pyx_t_4); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 1455, __pyx_L1_error)
  20296. __Pyx_GOTREF(__pyx_t_7);
  20297. if (__pyx_t_9) {
  20298. __Pyx_GIVEREF(__pyx_t_9); PyTuple_SET_ITEM(__pyx_t_7, 0, __pyx_t_9); __pyx_t_9 = NULL;
  20299. }
  20300. __Pyx_GIVEREF(__pyx_t_8);
  20301. PyTuple_SET_ITEM(__pyx_t_7, 0+__pyx_t_4, __pyx_t_8);
  20302. __Pyx_GIVEREF(__pyx_t_6);
  20303. PyTuple_SET_ITEM(__pyx_t_7, 1+__pyx_t_4, __pyx_t_6);
  20304. __Pyx_INCREF(Py_True);
  20305. __Pyx_GIVEREF(Py_True);
  20306. PyTuple_SET_ITEM(__pyx_t_7, 2+__pyx_t_4, Py_True);
  20307. __pyx_t_8 = 0;
  20308. __pyx_t_6 = 0;
  20309. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_7, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1455, __pyx_L1_error)
  20310. __Pyx_GOTREF(__pyx_t_1);
  20311. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  20312. }
  20313. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  20314. __pyx_t_5 = PyObject_RichCompare(__pyx_t_1, __pyx_v_tag_object, Py_EQ); __Pyx_XGOTREF(__pyx_t_5); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1455, __pyx_L1_error)
  20315. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  20316. __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1455, __pyx_L1_error)
  20317. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  20318. if (__pyx_t_3) {
  20319. /* "_yaml.pyx":1456
  20320. * tag_object = node.tag
  20321. * if self.resolve(SequenceNode, node.value, True) == tag_object:
  20322. * implicit = 1 # <<<<<<<<<<<<<<
  20323. * tag = NULL
  20324. * if tag_object is not None:
  20325. */
  20326. __pyx_v_implicit = 1;
  20327. /* "_yaml.pyx":1455
  20328. * implicit = 0
  20329. * tag_object = node.tag
  20330. * if self.resolve(SequenceNode, node.value, True) == tag_object: # <<<<<<<<<<<<<<
  20331. * implicit = 1
  20332. * tag = NULL
  20333. */
  20334. }
  20335. /* "_yaml.pyx":1457
  20336. * if self.resolve(SequenceNode, node.value, True) == tag_object:
  20337. * implicit = 1
  20338. * tag = NULL # <<<<<<<<<<<<<<
  20339. * if tag_object is not None:
  20340. * if PyUnicode_CheckExact(tag_object):
  20341. */
  20342. __pyx_v_tag = NULL;
  20343. /* "_yaml.pyx":1458
  20344. * implicit = 1
  20345. * tag = NULL
  20346. * if tag_object is not None: # <<<<<<<<<<<<<<
  20347. * if PyUnicode_CheckExact(tag_object):
  20348. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20349. */
  20350. __pyx_t_3 = (__pyx_v_tag_object != Py_None);
  20351. __pyx_t_2 = (__pyx_t_3 != 0);
  20352. if (__pyx_t_2) {
  20353. /* "_yaml.pyx":1459
  20354. * tag = NULL
  20355. * if tag_object is not None:
  20356. * if PyUnicode_CheckExact(tag_object): # <<<<<<<<<<<<<<
  20357. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20358. * if not PyString_CheckExact(tag_object):
  20359. */
  20360. __pyx_t_2 = (PyUnicode_CheckExact(__pyx_v_tag_object) != 0);
  20361. if (__pyx_t_2) {
  20362. /* "_yaml.pyx":1460
  20363. * if tag_object is not None:
  20364. * if PyUnicode_CheckExact(tag_object):
  20365. * tag_object = PyUnicode_AsUTF8String(tag_object) # <<<<<<<<<<<<<<
  20366. * if not PyString_CheckExact(tag_object):
  20367. * if PY_MAJOR_VERSION < 3:
  20368. */
  20369. __pyx_t_5 = PyUnicode_AsUTF8String(__pyx_v_tag_object); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1460, __pyx_L1_error)
  20370. __Pyx_GOTREF(__pyx_t_5);
  20371. __Pyx_DECREF_SET(__pyx_v_tag_object, __pyx_t_5);
  20372. __pyx_t_5 = 0;
  20373. /* "_yaml.pyx":1459
  20374. * tag = NULL
  20375. * if tag_object is not None:
  20376. * if PyUnicode_CheckExact(tag_object): # <<<<<<<<<<<<<<
  20377. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20378. * if not PyString_CheckExact(tag_object):
  20379. */
  20380. }
  20381. /* "_yaml.pyx":1461
  20382. * if PyUnicode_CheckExact(tag_object):
  20383. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20384. * if not PyString_CheckExact(tag_object): # <<<<<<<<<<<<<<
  20385. * if PY_MAJOR_VERSION < 3:
  20386. * raise TypeError("tag must be a string")
  20387. */
  20388. __pyx_t_2 = ((!(PyString_CheckExact(__pyx_v_tag_object) != 0)) != 0);
  20389. if (__pyx_t_2) {
  20390. /* "_yaml.pyx":1462
  20391. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20392. * if not PyString_CheckExact(tag_object):
  20393. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  20394. * raise TypeError("tag must be a string")
  20395. * else:
  20396. */
  20397. __pyx_t_2 = ((PY_MAJOR_VERSION < 3) != 0);
  20398. if (unlikely(__pyx_t_2)) {
  20399. /* "_yaml.pyx":1463
  20400. * if not PyString_CheckExact(tag_object):
  20401. * if PY_MAJOR_VERSION < 3:
  20402. * raise TypeError("tag must be a string") # <<<<<<<<<<<<<<
  20403. * else:
  20404. * raise TypeError(u"tag must be a string")
  20405. */
  20406. __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__32, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1463, __pyx_L1_error)
  20407. __Pyx_GOTREF(__pyx_t_5);
  20408. __Pyx_Raise(__pyx_t_5, 0, 0, 0);
  20409. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  20410. __PYX_ERR(0, 1463, __pyx_L1_error)
  20411. /* "_yaml.pyx":1462
  20412. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20413. * if not PyString_CheckExact(tag_object):
  20414. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  20415. * raise TypeError("tag must be a string")
  20416. * else:
  20417. */
  20418. }
  20419. /* "_yaml.pyx":1465
  20420. * raise TypeError("tag must be a string")
  20421. * else:
  20422. * raise TypeError(u"tag must be a string") # <<<<<<<<<<<<<<
  20423. * tag = PyString_AS_STRING(tag_object)
  20424. * sequence_style = YAML_BLOCK_SEQUENCE_STYLE
  20425. */
  20426. /*else*/ {
  20427. __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__33, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1465, __pyx_L1_error)
  20428. __Pyx_GOTREF(__pyx_t_5);
  20429. __Pyx_Raise(__pyx_t_5, 0, 0, 0);
  20430. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  20431. __PYX_ERR(0, 1465, __pyx_L1_error)
  20432. }
  20433. /* "_yaml.pyx":1461
  20434. * if PyUnicode_CheckExact(tag_object):
  20435. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20436. * if not PyString_CheckExact(tag_object): # <<<<<<<<<<<<<<
  20437. * if PY_MAJOR_VERSION < 3:
  20438. * raise TypeError("tag must be a string")
  20439. */
  20440. }
  20441. /* "_yaml.pyx":1466
  20442. * else:
  20443. * raise TypeError(u"tag must be a string")
  20444. * tag = PyString_AS_STRING(tag_object) # <<<<<<<<<<<<<<
  20445. * sequence_style = YAML_BLOCK_SEQUENCE_STYLE
  20446. * if node.flow_style:
  20447. */
  20448. __pyx_v_tag = PyString_AS_STRING(__pyx_v_tag_object);
  20449. /* "_yaml.pyx":1458
  20450. * implicit = 1
  20451. * tag = NULL
  20452. * if tag_object is not None: # <<<<<<<<<<<<<<
  20453. * if PyUnicode_CheckExact(tag_object):
  20454. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20455. */
  20456. }
  20457. /* "_yaml.pyx":1467
  20458. * raise TypeError(u"tag must be a string")
  20459. * tag = PyString_AS_STRING(tag_object)
  20460. * sequence_style = YAML_BLOCK_SEQUENCE_STYLE # <<<<<<<<<<<<<<
  20461. * if node.flow_style:
  20462. * sequence_style = YAML_FLOW_SEQUENCE_STYLE
  20463. */
  20464. __pyx_v_sequence_style = YAML_BLOCK_SEQUENCE_STYLE;
  20465. /* "_yaml.pyx":1468
  20466. * tag = PyString_AS_STRING(tag_object)
  20467. * sequence_style = YAML_BLOCK_SEQUENCE_STYLE
  20468. * if node.flow_style: # <<<<<<<<<<<<<<
  20469. * sequence_style = YAML_FLOW_SEQUENCE_STYLE
  20470. * if yaml_sequence_start_event_initialize(&event, anchor, tag,
  20471. */
  20472. __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_flow_style); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1468, __pyx_L1_error)
  20473. __Pyx_GOTREF(__pyx_t_5);
  20474. __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 1468, __pyx_L1_error)
  20475. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  20476. if (__pyx_t_2) {
  20477. /* "_yaml.pyx":1469
  20478. * sequence_style = YAML_BLOCK_SEQUENCE_STYLE
  20479. * if node.flow_style:
  20480. * sequence_style = YAML_FLOW_SEQUENCE_STYLE # <<<<<<<<<<<<<<
  20481. * if yaml_sequence_start_event_initialize(&event, anchor, tag,
  20482. * implicit, sequence_style) == 0:
  20483. */
  20484. __pyx_v_sequence_style = YAML_FLOW_SEQUENCE_STYLE;
  20485. /* "_yaml.pyx":1468
  20486. * tag = PyString_AS_STRING(tag_object)
  20487. * sequence_style = YAML_BLOCK_SEQUENCE_STYLE
  20488. * if node.flow_style: # <<<<<<<<<<<<<<
  20489. * sequence_style = YAML_FLOW_SEQUENCE_STYLE
  20490. * if yaml_sequence_start_event_initialize(&event, anchor, tag,
  20491. */
  20492. }
  20493. /* "_yaml.pyx":1471
  20494. * sequence_style = YAML_FLOW_SEQUENCE_STYLE
  20495. * if yaml_sequence_start_event_initialize(&event, anchor, tag,
  20496. * implicit, sequence_style) == 0: # <<<<<<<<<<<<<<
  20497. * raise MemoryError
  20498. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  20499. */
  20500. __pyx_t_2 = ((yaml_sequence_start_event_initialize((&__pyx_v_event), __pyx_v_anchor, __pyx_v_tag, __pyx_v_implicit, __pyx_v_sequence_style) == 0) != 0);
  20501. /* "_yaml.pyx":1470
  20502. * if node.flow_style:
  20503. * sequence_style = YAML_FLOW_SEQUENCE_STYLE
  20504. * if yaml_sequence_start_event_initialize(&event, anchor, tag, # <<<<<<<<<<<<<<
  20505. * implicit, sequence_style) == 0:
  20506. * raise MemoryError
  20507. */
  20508. if (unlikely(__pyx_t_2)) {
  20509. /* "_yaml.pyx":1472
  20510. * if yaml_sequence_start_event_initialize(&event, anchor, tag,
  20511. * implicit, sequence_style) == 0:
  20512. * raise MemoryError # <<<<<<<<<<<<<<
  20513. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  20514. * error = self._emitter_error()
  20515. */
  20516. PyErr_NoMemory(); __PYX_ERR(0, 1472, __pyx_L1_error)
  20517. /* "_yaml.pyx":1470
  20518. * if node.flow_style:
  20519. * sequence_style = YAML_FLOW_SEQUENCE_STYLE
  20520. * if yaml_sequence_start_event_initialize(&event, anchor, tag, # <<<<<<<<<<<<<<
  20521. * implicit, sequence_style) == 0:
  20522. * raise MemoryError
  20523. */
  20524. }
  20525. /* "_yaml.pyx":1473
  20526. * implicit, sequence_style) == 0:
  20527. * raise MemoryError
  20528. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  20529. * error = self._emitter_error()
  20530. * raise error
  20531. */
  20532. __pyx_t_4 = yaml_emitter_emit((&__pyx_v_self->emitter), (&__pyx_v_event)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 1473, __pyx_L1_error)
  20533. __pyx_t_2 = ((__pyx_t_4 == 0) != 0);
  20534. if (unlikely(__pyx_t_2)) {
  20535. /* "_yaml.pyx":1474
  20536. * raise MemoryError
  20537. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  20538. * error = self._emitter_error() # <<<<<<<<<<<<<<
  20539. * raise error
  20540. * item_index = 0
  20541. */
  20542. __pyx_t_5 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_emitter_error(__pyx_v_self); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1474, __pyx_L1_error)
  20543. __Pyx_GOTREF(__pyx_t_5);
  20544. __pyx_v_error = __pyx_t_5;
  20545. __pyx_t_5 = 0;
  20546. /* "_yaml.pyx":1475
  20547. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  20548. * error = self._emitter_error()
  20549. * raise error # <<<<<<<<<<<<<<
  20550. * item_index = 0
  20551. * for item in node.value:
  20552. */
  20553. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  20554. __PYX_ERR(0, 1475, __pyx_L1_error)
  20555. /* "_yaml.pyx":1473
  20556. * implicit, sequence_style) == 0:
  20557. * raise MemoryError
  20558. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  20559. * error = self._emitter_error()
  20560. * raise error
  20561. */
  20562. }
  20563. /* "_yaml.pyx":1476
  20564. * error = self._emitter_error()
  20565. * raise error
  20566. * item_index = 0 # <<<<<<<<<<<<<<
  20567. * for item in node.value:
  20568. * self._serialize_node(item, node, item_index)
  20569. */
  20570. __pyx_v_item_index = 0;
  20571. /* "_yaml.pyx":1477
  20572. * raise error
  20573. * item_index = 0
  20574. * for item in node.value: # <<<<<<<<<<<<<<
  20575. * self._serialize_node(item, node, item_index)
  20576. * item_index = item_index+1
  20577. */
  20578. __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_value); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1477, __pyx_L1_error)
  20579. __Pyx_GOTREF(__pyx_t_5);
  20580. if (likely(PyList_CheckExact(__pyx_t_5)) || PyTuple_CheckExact(__pyx_t_5)) {
  20581. __pyx_t_1 = __pyx_t_5; __Pyx_INCREF(__pyx_t_1); __pyx_t_10 = 0;
  20582. __pyx_t_11 = NULL;
  20583. } else {
  20584. __pyx_t_10 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1477, __pyx_L1_error)
  20585. __Pyx_GOTREF(__pyx_t_1);
  20586. __pyx_t_11 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 1477, __pyx_L1_error)
  20587. }
  20588. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  20589. for (;;) {
  20590. if (likely(!__pyx_t_11)) {
  20591. if (likely(PyList_CheckExact(__pyx_t_1))) {
  20592. if (__pyx_t_10 >= PyList_GET_SIZE(__pyx_t_1)) break;
  20593. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  20594. __pyx_t_5 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_10); __Pyx_INCREF(__pyx_t_5); __pyx_t_10++; if (unlikely(0 < 0)) __PYX_ERR(0, 1477, __pyx_L1_error)
  20595. #else
  20596. __pyx_t_5 = PySequence_ITEM(__pyx_t_1, __pyx_t_10); __pyx_t_10++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1477, __pyx_L1_error)
  20597. __Pyx_GOTREF(__pyx_t_5);
  20598. #endif
  20599. } else {
  20600. if (__pyx_t_10 >= PyTuple_GET_SIZE(__pyx_t_1)) break;
  20601. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  20602. __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_10); __Pyx_INCREF(__pyx_t_5); __pyx_t_10++; if (unlikely(0 < 0)) __PYX_ERR(0, 1477, __pyx_L1_error)
  20603. #else
  20604. __pyx_t_5 = PySequence_ITEM(__pyx_t_1, __pyx_t_10); __pyx_t_10++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1477, __pyx_L1_error)
  20605. __Pyx_GOTREF(__pyx_t_5);
  20606. #endif
  20607. }
  20608. } else {
  20609. __pyx_t_5 = __pyx_t_11(__pyx_t_1);
  20610. if (unlikely(!__pyx_t_5)) {
  20611. PyObject* exc_type = PyErr_Occurred();
  20612. if (exc_type) {
  20613. if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
  20614. else __PYX_ERR(0, 1477, __pyx_L1_error)
  20615. }
  20616. break;
  20617. }
  20618. __Pyx_GOTREF(__pyx_t_5);
  20619. }
  20620. __Pyx_XDECREF_SET(__pyx_v_item, __pyx_t_5);
  20621. __pyx_t_5 = 0;
  20622. /* "_yaml.pyx":1478
  20623. * item_index = 0
  20624. * for item in node.value:
  20625. * self._serialize_node(item, node, item_index) # <<<<<<<<<<<<<<
  20626. * item_index = item_index+1
  20627. * yaml_sequence_end_event_initialize(&event)
  20628. */
  20629. __pyx_t_5 = __Pyx_PyInt_From_int(__pyx_v_item_index); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1478, __pyx_L1_error)
  20630. __Pyx_GOTREF(__pyx_t_5);
  20631. __pyx_t_4 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_serialize_node(__pyx_v_self, __pyx_v_item, __pyx_v_node, __pyx_t_5); if (unlikely(__pyx_t_4 == ((int)0))) __PYX_ERR(0, 1478, __pyx_L1_error)
  20632. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  20633. /* "_yaml.pyx":1479
  20634. * for item in node.value:
  20635. * self._serialize_node(item, node, item_index)
  20636. * item_index = item_index+1 # <<<<<<<<<<<<<<
  20637. * yaml_sequence_end_event_initialize(&event)
  20638. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  20639. */
  20640. __pyx_v_item_index = (__pyx_v_item_index + 1);
  20641. /* "_yaml.pyx":1477
  20642. * raise error
  20643. * item_index = 0
  20644. * for item in node.value: # <<<<<<<<<<<<<<
  20645. * self._serialize_node(item, node, item_index)
  20646. * item_index = item_index+1
  20647. */
  20648. }
  20649. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  20650. /* "_yaml.pyx":1480
  20651. * self._serialize_node(item, node, item_index)
  20652. * item_index = item_index+1
  20653. * yaml_sequence_end_event_initialize(&event) # <<<<<<<<<<<<<<
  20654. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  20655. * error = self._emitter_error()
  20656. */
  20657. (void)(yaml_sequence_end_event_initialize((&__pyx_v_event)));
  20658. /* "_yaml.pyx":1481
  20659. * item_index = item_index+1
  20660. * yaml_sequence_end_event_initialize(&event)
  20661. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  20662. * error = self._emitter_error()
  20663. * raise error
  20664. */
  20665. __pyx_t_4 = yaml_emitter_emit((&__pyx_v_self->emitter), (&__pyx_v_event)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 1481, __pyx_L1_error)
  20666. __pyx_t_2 = ((__pyx_t_4 == 0) != 0);
  20667. if (unlikely(__pyx_t_2)) {
  20668. /* "_yaml.pyx":1482
  20669. * yaml_sequence_end_event_initialize(&event)
  20670. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  20671. * error = self._emitter_error() # <<<<<<<<<<<<<<
  20672. * raise error
  20673. * elif node_class is MappingNode:
  20674. */
  20675. __pyx_t_1 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_emitter_error(__pyx_v_self); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1482, __pyx_L1_error)
  20676. __Pyx_GOTREF(__pyx_t_1);
  20677. __pyx_v_error = __pyx_t_1;
  20678. __pyx_t_1 = 0;
  20679. /* "_yaml.pyx":1483
  20680. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  20681. * error = self._emitter_error()
  20682. * raise error # <<<<<<<<<<<<<<
  20683. * elif node_class is MappingNode:
  20684. * implicit = 0
  20685. */
  20686. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  20687. __PYX_ERR(0, 1483, __pyx_L1_error)
  20688. /* "_yaml.pyx":1481
  20689. * item_index = item_index+1
  20690. * yaml_sequence_end_event_initialize(&event)
  20691. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  20692. * error = self._emitter_error()
  20693. * raise error
  20694. */
  20695. }
  20696. /* "_yaml.pyx":1452
  20697. * error = self._emitter_error()
  20698. * raise error
  20699. * elif node_class is SequenceNode: # <<<<<<<<<<<<<<
  20700. * implicit = 0
  20701. * tag_object = node.tag
  20702. */
  20703. goto __pyx_L10;
  20704. }
  20705. /* "_yaml.pyx":1484
  20706. * error = self._emitter_error()
  20707. * raise error
  20708. * elif node_class is MappingNode: # <<<<<<<<<<<<<<
  20709. * implicit = 0
  20710. * tag_object = node.tag
  20711. */
  20712. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_MappingNode); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1484, __pyx_L1_error)
  20713. __Pyx_GOTREF(__pyx_t_1);
  20714. __pyx_t_2 = (__pyx_v_node_class == __pyx_t_1);
  20715. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  20716. __pyx_t_3 = (__pyx_t_2 != 0);
  20717. if (__pyx_t_3) {
  20718. /* "_yaml.pyx":1485
  20719. * raise error
  20720. * elif node_class is MappingNode:
  20721. * implicit = 0 # <<<<<<<<<<<<<<
  20722. * tag_object = node.tag
  20723. * if self.resolve(MappingNode, node.value, True) == tag_object:
  20724. */
  20725. __pyx_v_implicit = 0;
  20726. /* "_yaml.pyx":1486
  20727. * elif node_class is MappingNode:
  20728. * implicit = 0
  20729. * tag_object = node.tag # <<<<<<<<<<<<<<
  20730. * if self.resolve(MappingNode, node.value, True) == tag_object:
  20731. * implicit = 1
  20732. */
  20733. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_tag); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1486, __pyx_L1_error)
  20734. __Pyx_GOTREF(__pyx_t_1);
  20735. __pyx_v_tag_object = __pyx_t_1;
  20736. __pyx_t_1 = 0;
  20737. /* "_yaml.pyx":1487
  20738. * implicit = 0
  20739. * tag_object = node.tag
  20740. * if self.resolve(MappingNode, node.value, True) == tag_object: # <<<<<<<<<<<<<<
  20741. * implicit = 1
  20742. * tag = NULL
  20743. */
  20744. __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_resolve); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1487, __pyx_L1_error)
  20745. __Pyx_GOTREF(__pyx_t_5);
  20746. __Pyx_GetModuleGlobalName(__pyx_t_7, __pyx_n_s_MappingNode); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 1487, __pyx_L1_error)
  20747. __Pyx_GOTREF(__pyx_t_7);
  20748. __pyx_t_6 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_value); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 1487, __pyx_L1_error)
  20749. __Pyx_GOTREF(__pyx_t_6);
  20750. __pyx_t_8 = NULL;
  20751. __pyx_t_4 = 0;
  20752. if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) {
  20753. __pyx_t_8 = PyMethod_GET_SELF(__pyx_t_5);
  20754. if (likely(__pyx_t_8)) {
  20755. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5);
  20756. __Pyx_INCREF(__pyx_t_8);
  20757. __Pyx_INCREF(function);
  20758. __Pyx_DECREF_SET(__pyx_t_5, function);
  20759. __pyx_t_4 = 1;
  20760. }
  20761. }
  20762. #if CYTHON_FAST_PYCALL
  20763. if (PyFunction_Check(__pyx_t_5)) {
  20764. PyObject *__pyx_temp[4] = {__pyx_t_8, __pyx_t_7, __pyx_t_6, Py_True};
  20765. __pyx_t_1 = __Pyx_PyFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_4, 3+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1487, __pyx_L1_error)
  20766. __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
  20767. __Pyx_GOTREF(__pyx_t_1);
  20768. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  20769. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  20770. } else
  20771. #endif
  20772. #if CYTHON_FAST_PYCCALL
  20773. if (__Pyx_PyFastCFunction_Check(__pyx_t_5)) {
  20774. PyObject *__pyx_temp[4] = {__pyx_t_8, __pyx_t_7, __pyx_t_6, Py_True};
  20775. __pyx_t_1 = __Pyx_PyCFunction_FastCall(__pyx_t_5, __pyx_temp+1-__pyx_t_4, 3+__pyx_t_4); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1487, __pyx_L1_error)
  20776. __Pyx_XDECREF(__pyx_t_8); __pyx_t_8 = 0;
  20777. __Pyx_GOTREF(__pyx_t_1);
  20778. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  20779. __Pyx_DECREF(__pyx_t_6); __pyx_t_6 = 0;
  20780. } else
  20781. #endif
  20782. {
  20783. __pyx_t_9 = PyTuple_New(3+__pyx_t_4); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 1487, __pyx_L1_error)
  20784. __Pyx_GOTREF(__pyx_t_9);
  20785. if (__pyx_t_8) {
  20786. __Pyx_GIVEREF(__pyx_t_8); PyTuple_SET_ITEM(__pyx_t_9, 0, __pyx_t_8); __pyx_t_8 = NULL;
  20787. }
  20788. __Pyx_GIVEREF(__pyx_t_7);
  20789. PyTuple_SET_ITEM(__pyx_t_9, 0+__pyx_t_4, __pyx_t_7);
  20790. __Pyx_GIVEREF(__pyx_t_6);
  20791. PyTuple_SET_ITEM(__pyx_t_9, 1+__pyx_t_4, __pyx_t_6);
  20792. __Pyx_INCREF(Py_True);
  20793. __Pyx_GIVEREF(Py_True);
  20794. PyTuple_SET_ITEM(__pyx_t_9, 2+__pyx_t_4, Py_True);
  20795. __pyx_t_7 = 0;
  20796. __pyx_t_6 = 0;
  20797. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_t_5, __pyx_t_9, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1487, __pyx_L1_error)
  20798. __Pyx_GOTREF(__pyx_t_1);
  20799. __Pyx_DECREF(__pyx_t_9); __pyx_t_9 = 0;
  20800. }
  20801. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  20802. __pyx_t_5 = PyObject_RichCompare(__pyx_t_1, __pyx_v_tag_object, Py_EQ); __Pyx_XGOTREF(__pyx_t_5); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1487, __pyx_L1_error)
  20803. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  20804. __pyx_t_3 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_3 < 0)) __PYX_ERR(0, 1487, __pyx_L1_error)
  20805. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  20806. if (__pyx_t_3) {
  20807. /* "_yaml.pyx":1488
  20808. * tag_object = node.tag
  20809. * if self.resolve(MappingNode, node.value, True) == tag_object:
  20810. * implicit = 1 # <<<<<<<<<<<<<<
  20811. * tag = NULL
  20812. * if tag_object is not None:
  20813. */
  20814. __pyx_v_implicit = 1;
  20815. /* "_yaml.pyx":1487
  20816. * implicit = 0
  20817. * tag_object = node.tag
  20818. * if self.resolve(MappingNode, node.value, True) == tag_object: # <<<<<<<<<<<<<<
  20819. * implicit = 1
  20820. * tag = NULL
  20821. */
  20822. }
  20823. /* "_yaml.pyx":1489
  20824. * if self.resolve(MappingNode, node.value, True) == tag_object:
  20825. * implicit = 1
  20826. * tag = NULL # <<<<<<<<<<<<<<
  20827. * if tag_object is not None:
  20828. * if PyUnicode_CheckExact(tag_object):
  20829. */
  20830. __pyx_v_tag = NULL;
  20831. /* "_yaml.pyx":1490
  20832. * implicit = 1
  20833. * tag = NULL
  20834. * if tag_object is not None: # <<<<<<<<<<<<<<
  20835. * if PyUnicode_CheckExact(tag_object):
  20836. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20837. */
  20838. __pyx_t_3 = (__pyx_v_tag_object != Py_None);
  20839. __pyx_t_2 = (__pyx_t_3 != 0);
  20840. if (__pyx_t_2) {
  20841. /* "_yaml.pyx":1491
  20842. * tag = NULL
  20843. * if tag_object is not None:
  20844. * if PyUnicode_CheckExact(tag_object): # <<<<<<<<<<<<<<
  20845. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20846. * if not PyString_CheckExact(tag_object):
  20847. */
  20848. __pyx_t_2 = (PyUnicode_CheckExact(__pyx_v_tag_object) != 0);
  20849. if (__pyx_t_2) {
  20850. /* "_yaml.pyx":1492
  20851. * if tag_object is not None:
  20852. * if PyUnicode_CheckExact(tag_object):
  20853. * tag_object = PyUnicode_AsUTF8String(tag_object) # <<<<<<<<<<<<<<
  20854. * if not PyString_CheckExact(tag_object):
  20855. * if PY_MAJOR_VERSION < 3:
  20856. */
  20857. __pyx_t_5 = PyUnicode_AsUTF8String(__pyx_v_tag_object); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1492, __pyx_L1_error)
  20858. __Pyx_GOTREF(__pyx_t_5);
  20859. __Pyx_DECREF_SET(__pyx_v_tag_object, __pyx_t_5);
  20860. __pyx_t_5 = 0;
  20861. /* "_yaml.pyx":1491
  20862. * tag = NULL
  20863. * if tag_object is not None:
  20864. * if PyUnicode_CheckExact(tag_object): # <<<<<<<<<<<<<<
  20865. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20866. * if not PyString_CheckExact(tag_object):
  20867. */
  20868. }
  20869. /* "_yaml.pyx":1493
  20870. * if PyUnicode_CheckExact(tag_object):
  20871. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20872. * if not PyString_CheckExact(tag_object): # <<<<<<<<<<<<<<
  20873. * if PY_MAJOR_VERSION < 3:
  20874. * raise TypeError("tag must be a string")
  20875. */
  20876. __pyx_t_2 = ((!(PyString_CheckExact(__pyx_v_tag_object) != 0)) != 0);
  20877. if (__pyx_t_2) {
  20878. /* "_yaml.pyx":1494
  20879. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20880. * if not PyString_CheckExact(tag_object):
  20881. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  20882. * raise TypeError("tag must be a string")
  20883. * else:
  20884. */
  20885. __pyx_t_2 = ((PY_MAJOR_VERSION < 3) != 0);
  20886. if (unlikely(__pyx_t_2)) {
  20887. /* "_yaml.pyx":1495
  20888. * if not PyString_CheckExact(tag_object):
  20889. * if PY_MAJOR_VERSION < 3:
  20890. * raise TypeError("tag must be a string") # <<<<<<<<<<<<<<
  20891. * else:
  20892. * raise TypeError(u"tag must be a string")
  20893. */
  20894. __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__32, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1495, __pyx_L1_error)
  20895. __Pyx_GOTREF(__pyx_t_5);
  20896. __Pyx_Raise(__pyx_t_5, 0, 0, 0);
  20897. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  20898. __PYX_ERR(0, 1495, __pyx_L1_error)
  20899. /* "_yaml.pyx":1494
  20900. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20901. * if not PyString_CheckExact(tag_object):
  20902. * if PY_MAJOR_VERSION < 3: # <<<<<<<<<<<<<<
  20903. * raise TypeError("tag must be a string")
  20904. * else:
  20905. */
  20906. }
  20907. /* "_yaml.pyx":1497
  20908. * raise TypeError("tag must be a string")
  20909. * else:
  20910. * raise TypeError(u"tag must be a string") # <<<<<<<<<<<<<<
  20911. * tag = PyString_AS_STRING(tag_object)
  20912. * mapping_style = YAML_BLOCK_MAPPING_STYLE
  20913. */
  20914. /*else*/ {
  20915. __pyx_t_5 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__33, NULL); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1497, __pyx_L1_error)
  20916. __Pyx_GOTREF(__pyx_t_5);
  20917. __Pyx_Raise(__pyx_t_5, 0, 0, 0);
  20918. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  20919. __PYX_ERR(0, 1497, __pyx_L1_error)
  20920. }
  20921. /* "_yaml.pyx":1493
  20922. * if PyUnicode_CheckExact(tag_object):
  20923. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20924. * if not PyString_CheckExact(tag_object): # <<<<<<<<<<<<<<
  20925. * if PY_MAJOR_VERSION < 3:
  20926. * raise TypeError("tag must be a string")
  20927. */
  20928. }
  20929. /* "_yaml.pyx":1498
  20930. * else:
  20931. * raise TypeError(u"tag must be a string")
  20932. * tag = PyString_AS_STRING(tag_object) # <<<<<<<<<<<<<<
  20933. * mapping_style = YAML_BLOCK_MAPPING_STYLE
  20934. * if node.flow_style:
  20935. */
  20936. __pyx_v_tag = PyString_AS_STRING(__pyx_v_tag_object);
  20937. /* "_yaml.pyx":1490
  20938. * implicit = 1
  20939. * tag = NULL
  20940. * if tag_object is not None: # <<<<<<<<<<<<<<
  20941. * if PyUnicode_CheckExact(tag_object):
  20942. * tag_object = PyUnicode_AsUTF8String(tag_object)
  20943. */
  20944. }
  20945. /* "_yaml.pyx":1499
  20946. * raise TypeError(u"tag must be a string")
  20947. * tag = PyString_AS_STRING(tag_object)
  20948. * mapping_style = YAML_BLOCK_MAPPING_STYLE # <<<<<<<<<<<<<<
  20949. * if node.flow_style:
  20950. * mapping_style = YAML_FLOW_MAPPING_STYLE
  20951. */
  20952. __pyx_v_mapping_style = YAML_BLOCK_MAPPING_STYLE;
  20953. /* "_yaml.pyx":1500
  20954. * tag = PyString_AS_STRING(tag_object)
  20955. * mapping_style = YAML_BLOCK_MAPPING_STYLE
  20956. * if node.flow_style: # <<<<<<<<<<<<<<
  20957. * mapping_style = YAML_FLOW_MAPPING_STYLE
  20958. * if yaml_mapping_start_event_initialize(&event, anchor, tag,
  20959. */
  20960. __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_flow_style); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1500, __pyx_L1_error)
  20961. __Pyx_GOTREF(__pyx_t_5);
  20962. __pyx_t_2 = __Pyx_PyObject_IsTrue(__pyx_t_5); if (unlikely(__pyx_t_2 < 0)) __PYX_ERR(0, 1500, __pyx_L1_error)
  20963. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  20964. if (__pyx_t_2) {
  20965. /* "_yaml.pyx":1501
  20966. * mapping_style = YAML_BLOCK_MAPPING_STYLE
  20967. * if node.flow_style:
  20968. * mapping_style = YAML_FLOW_MAPPING_STYLE # <<<<<<<<<<<<<<
  20969. * if yaml_mapping_start_event_initialize(&event, anchor, tag,
  20970. * implicit, mapping_style) == 0:
  20971. */
  20972. __pyx_v_mapping_style = YAML_FLOW_MAPPING_STYLE;
  20973. /* "_yaml.pyx":1500
  20974. * tag = PyString_AS_STRING(tag_object)
  20975. * mapping_style = YAML_BLOCK_MAPPING_STYLE
  20976. * if node.flow_style: # <<<<<<<<<<<<<<
  20977. * mapping_style = YAML_FLOW_MAPPING_STYLE
  20978. * if yaml_mapping_start_event_initialize(&event, anchor, tag,
  20979. */
  20980. }
  20981. /* "_yaml.pyx":1503
  20982. * mapping_style = YAML_FLOW_MAPPING_STYLE
  20983. * if yaml_mapping_start_event_initialize(&event, anchor, tag,
  20984. * implicit, mapping_style) == 0: # <<<<<<<<<<<<<<
  20985. * raise MemoryError
  20986. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  20987. */
  20988. __pyx_t_2 = ((yaml_mapping_start_event_initialize((&__pyx_v_event), __pyx_v_anchor, __pyx_v_tag, __pyx_v_implicit, __pyx_v_mapping_style) == 0) != 0);
  20989. /* "_yaml.pyx":1502
  20990. * if node.flow_style:
  20991. * mapping_style = YAML_FLOW_MAPPING_STYLE
  20992. * if yaml_mapping_start_event_initialize(&event, anchor, tag, # <<<<<<<<<<<<<<
  20993. * implicit, mapping_style) == 0:
  20994. * raise MemoryError
  20995. */
  20996. if (unlikely(__pyx_t_2)) {
  20997. /* "_yaml.pyx":1504
  20998. * if yaml_mapping_start_event_initialize(&event, anchor, tag,
  20999. * implicit, mapping_style) == 0:
  21000. * raise MemoryError # <<<<<<<<<<<<<<
  21001. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  21002. * error = self._emitter_error()
  21003. */
  21004. PyErr_NoMemory(); __PYX_ERR(0, 1504, __pyx_L1_error)
  21005. /* "_yaml.pyx":1502
  21006. * if node.flow_style:
  21007. * mapping_style = YAML_FLOW_MAPPING_STYLE
  21008. * if yaml_mapping_start_event_initialize(&event, anchor, tag, # <<<<<<<<<<<<<<
  21009. * implicit, mapping_style) == 0:
  21010. * raise MemoryError
  21011. */
  21012. }
  21013. /* "_yaml.pyx":1505
  21014. * implicit, mapping_style) == 0:
  21015. * raise MemoryError
  21016. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  21017. * error = self._emitter_error()
  21018. * raise error
  21019. */
  21020. __pyx_t_4 = yaml_emitter_emit((&__pyx_v_self->emitter), (&__pyx_v_event)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 1505, __pyx_L1_error)
  21021. __pyx_t_2 = ((__pyx_t_4 == 0) != 0);
  21022. if (unlikely(__pyx_t_2)) {
  21023. /* "_yaml.pyx":1506
  21024. * raise MemoryError
  21025. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  21026. * error = self._emitter_error() # <<<<<<<<<<<<<<
  21027. * raise error
  21028. * for item_key, item_value in node.value:
  21029. */
  21030. __pyx_t_5 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_emitter_error(__pyx_v_self); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1506, __pyx_L1_error)
  21031. __Pyx_GOTREF(__pyx_t_5);
  21032. __pyx_v_error = __pyx_t_5;
  21033. __pyx_t_5 = 0;
  21034. /* "_yaml.pyx":1507
  21035. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  21036. * error = self._emitter_error()
  21037. * raise error # <<<<<<<<<<<<<<
  21038. * for item_key, item_value in node.value:
  21039. * self._serialize_node(item_key, node, None)
  21040. */
  21041. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  21042. __PYX_ERR(0, 1507, __pyx_L1_error)
  21043. /* "_yaml.pyx":1505
  21044. * implicit, mapping_style) == 0:
  21045. * raise MemoryError
  21046. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  21047. * error = self._emitter_error()
  21048. * raise error
  21049. */
  21050. }
  21051. /* "_yaml.pyx":1508
  21052. * error = self._emitter_error()
  21053. * raise error
  21054. * for item_key, item_value in node.value: # <<<<<<<<<<<<<<
  21055. * self._serialize_node(item_key, node, None)
  21056. * self._serialize_node(item_value, node, item_key)
  21057. */
  21058. __pyx_t_5 = __Pyx_PyObject_GetAttrStr(__pyx_v_node, __pyx_n_s_value); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1508, __pyx_L1_error)
  21059. __Pyx_GOTREF(__pyx_t_5);
  21060. if (likely(PyList_CheckExact(__pyx_t_5)) || PyTuple_CheckExact(__pyx_t_5)) {
  21061. __pyx_t_1 = __pyx_t_5; __Pyx_INCREF(__pyx_t_1); __pyx_t_10 = 0;
  21062. __pyx_t_11 = NULL;
  21063. } else {
  21064. __pyx_t_10 = -1; __pyx_t_1 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1508, __pyx_L1_error)
  21065. __Pyx_GOTREF(__pyx_t_1);
  21066. __pyx_t_11 = Py_TYPE(__pyx_t_1)->tp_iternext; if (unlikely(!__pyx_t_11)) __PYX_ERR(0, 1508, __pyx_L1_error)
  21067. }
  21068. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  21069. for (;;) {
  21070. if (likely(!__pyx_t_11)) {
  21071. if (likely(PyList_CheckExact(__pyx_t_1))) {
  21072. if (__pyx_t_10 >= PyList_GET_SIZE(__pyx_t_1)) break;
  21073. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  21074. __pyx_t_5 = PyList_GET_ITEM(__pyx_t_1, __pyx_t_10); __Pyx_INCREF(__pyx_t_5); __pyx_t_10++; if (unlikely(0 < 0)) __PYX_ERR(0, 1508, __pyx_L1_error)
  21075. #else
  21076. __pyx_t_5 = PySequence_ITEM(__pyx_t_1, __pyx_t_10); __pyx_t_10++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1508, __pyx_L1_error)
  21077. __Pyx_GOTREF(__pyx_t_5);
  21078. #endif
  21079. } else {
  21080. if (__pyx_t_10 >= PyTuple_GET_SIZE(__pyx_t_1)) break;
  21081. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  21082. __pyx_t_5 = PyTuple_GET_ITEM(__pyx_t_1, __pyx_t_10); __Pyx_INCREF(__pyx_t_5); __pyx_t_10++; if (unlikely(0 < 0)) __PYX_ERR(0, 1508, __pyx_L1_error)
  21083. #else
  21084. __pyx_t_5 = PySequence_ITEM(__pyx_t_1, __pyx_t_10); __pyx_t_10++; if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1508, __pyx_L1_error)
  21085. __Pyx_GOTREF(__pyx_t_5);
  21086. #endif
  21087. }
  21088. } else {
  21089. __pyx_t_5 = __pyx_t_11(__pyx_t_1);
  21090. if (unlikely(!__pyx_t_5)) {
  21091. PyObject* exc_type = PyErr_Occurred();
  21092. if (exc_type) {
  21093. if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) PyErr_Clear();
  21094. else __PYX_ERR(0, 1508, __pyx_L1_error)
  21095. }
  21096. break;
  21097. }
  21098. __Pyx_GOTREF(__pyx_t_5);
  21099. }
  21100. if ((likely(PyTuple_CheckExact(__pyx_t_5))) || (PyList_CheckExact(__pyx_t_5))) {
  21101. PyObject* sequence = __pyx_t_5;
  21102. Py_ssize_t size = __Pyx_PySequence_SIZE(sequence);
  21103. if (unlikely(size != 2)) {
  21104. if (size > 2) __Pyx_RaiseTooManyValuesError(2);
  21105. else if (size >= 0) __Pyx_RaiseNeedMoreValuesError(size);
  21106. __PYX_ERR(0, 1508, __pyx_L1_error)
  21107. }
  21108. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  21109. if (likely(PyTuple_CheckExact(sequence))) {
  21110. __pyx_t_9 = PyTuple_GET_ITEM(sequence, 0);
  21111. __pyx_t_6 = PyTuple_GET_ITEM(sequence, 1);
  21112. } else {
  21113. __pyx_t_9 = PyList_GET_ITEM(sequence, 0);
  21114. __pyx_t_6 = PyList_GET_ITEM(sequence, 1);
  21115. }
  21116. __Pyx_INCREF(__pyx_t_9);
  21117. __Pyx_INCREF(__pyx_t_6);
  21118. #else
  21119. __pyx_t_9 = PySequence_ITEM(sequence, 0); if (unlikely(!__pyx_t_9)) __PYX_ERR(0, 1508, __pyx_L1_error)
  21120. __Pyx_GOTREF(__pyx_t_9);
  21121. __pyx_t_6 = PySequence_ITEM(sequence, 1); if (unlikely(!__pyx_t_6)) __PYX_ERR(0, 1508, __pyx_L1_error)
  21122. __Pyx_GOTREF(__pyx_t_6);
  21123. #endif
  21124. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  21125. } else {
  21126. Py_ssize_t index = -1;
  21127. __pyx_t_7 = PyObject_GetIter(__pyx_t_5); if (unlikely(!__pyx_t_7)) __PYX_ERR(0, 1508, __pyx_L1_error)
  21128. __Pyx_GOTREF(__pyx_t_7);
  21129. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  21130. __pyx_t_12 = Py_TYPE(__pyx_t_7)->tp_iternext;
  21131. index = 0; __pyx_t_9 = __pyx_t_12(__pyx_t_7); if (unlikely(!__pyx_t_9)) goto __pyx_L52_unpacking_failed;
  21132. __Pyx_GOTREF(__pyx_t_9);
  21133. index = 1; __pyx_t_6 = __pyx_t_12(__pyx_t_7); if (unlikely(!__pyx_t_6)) goto __pyx_L52_unpacking_failed;
  21134. __Pyx_GOTREF(__pyx_t_6);
  21135. if (__Pyx_IternextUnpackEndCheck(__pyx_t_12(__pyx_t_7), 2) < 0) __PYX_ERR(0, 1508, __pyx_L1_error)
  21136. __pyx_t_12 = NULL;
  21137. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  21138. goto __pyx_L53_unpacking_done;
  21139. __pyx_L52_unpacking_failed:;
  21140. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  21141. __pyx_t_12 = NULL;
  21142. if (__Pyx_IterFinish() == 0) __Pyx_RaiseNeedMoreValuesError(index);
  21143. __PYX_ERR(0, 1508, __pyx_L1_error)
  21144. __pyx_L53_unpacking_done:;
  21145. }
  21146. __Pyx_XDECREF_SET(__pyx_v_item_key, __pyx_t_9);
  21147. __pyx_t_9 = 0;
  21148. __Pyx_XDECREF_SET(__pyx_v_item_value, __pyx_t_6);
  21149. __pyx_t_6 = 0;
  21150. /* "_yaml.pyx":1509
  21151. * raise error
  21152. * for item_key, item_value in node.value:
  21153. * self._serialize_node(item_key, node, None) # <<<<<<<<<<<<<<
  21154. * self._serialize_node(item_value, node, item_key)
  21155. * yaml_mapping_end_event_initialize(&event)
  21156. */
  21157. __pyx_t_4 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_serialize_node(__pyx_v_self, __pyx_v_item_key, __pyx_v_node, Py_None); if (unlikely(__pyx_t_4 == ((int)0))) __PYX_ERR(0, 1509, __pyx_L1_error)
  21158. /* "_yaml.pyx":1510
  21159. * for item_key, item_value in node.value:
  21160. * self._serialize_node(item_key, node, None)
  21161. * self._serialize_node(item_value, node, item_key) # <<<<<<<<<<<<<<
  21162. * yaml_mapping_end_event_initialize(&event)
  21163. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  21164. */
  21165. __pyx_t_4 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_serialize_node(__pyx_v_self, __pyx_v_item_value, __pyx_v_node, __pyx_v_item_key); if (unlikely(__pyx_t_4 == ((int)0))) __PYX_ERR(0, 1510, __pyx_L1_error)
  21166. /* "_yaml.pyx":1508
  21167. * error = self._emitter_error()
  21168. * raise error
  21169. * for item_key, item_value in node.value: # <<<<<<<<<<<<<<
  21170. * self._serialize_node(item_key, node, None)
  21171. * self._serialize_node(item_value, node, item_key)
  21172. */
  21173. }
  21174. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  21175. /* "_yaml.pyx":1511
  21176. * self._serialize_node(item_key, node, None)
  21177. * self._serialize_node(item_value, node, item_key)
  21178. * yaml_mapping_end_event_initialize(&event) # <<<<<<<<<<<<<<
  21179. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  21180. * error = self._emitter_error()
  21181. */
  21182. (void)(yaml_mapping_end_event_initialize((&__pyx_v_event)));
  21183. /* "_yaml.pyx":1512
  21184. * self._serialize_node(item_value, node, item_key)
  21185. * yaml_mapping_end_event_initialize(&event)
  21186. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  21187. * error = self._emitter_error()
  21188. * raise error
  21189. */
  21190. __pyx_t_4 = yaml_emitter_emit((&__pyx_v_self->emitter), (&__pyx_v_event)); if (unlikely(PyErr_Occurred())) __PYX_ERR(0, 1512, __pyx_L1_error)
  21191. __pyx_t_2 = ((__pyx_t_4 == 0) != 0);
  21192. if (unlikely(__pyx_t_2)) {
  21193. /* "_yaml.pyx":1513
  21194. * yaml_mapping_end_event_initialize(&event)
  21195. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  21196. * error = self._emitter_error() # <<<<<<<<<<<<<<
  21197. * raise error
  21198. * self.ascend_resolver()
  21199. */
  21200. __pyx_t_1 = ((struct __pyx_vtabstruct_5_yaml_CEmitter *)__pyx_v_self->__pyx_vtab)->_emitter_error(__pyx_v_self); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1513, __pyx_L1_error)
  21201. __Pyx_GOTREF(__pyx_t_1);
  21202. __pyx_v_error = __pyx_t_1;
  21203. __pyx_t_1 = 0;
  21204. /* "_yaml.pyx":1514
  21205. * if yaml_emitter_emit(&self.emitter, &event) == 0:
  21206. * error = self._emitter_error()
  21207. * raise error # <<<<<<<<<<<<<<
  21208. * self.ascend_resolver()
  21209. * return 1
  21210. */
  21211. __Pyx_Raise(__pyx_v_error, 0, 0, 0);
  21212. __PYX_ERR(0, 1514, __pyx_L1_error)
  21213. /* "_yaml.pyx":1512
  21214. * self._serialize_node(item_value, node, item_key)
  21215. * yaml_mapping_end_event_initialize(&event)
  21216. * if yaml_emitter_emit(&self.emitter, &event) == 0: # <<<<<<<<<<<<<<
  21217. * error = self._emitter_error()
  21218. * raise error
  21219. */
  21220. }
  21221. /* "_yaml.pyx":1484
  21222. * error = self._emitter_error()
  21223. * raise error
  21224. * elif node_class is MappingNode: # <<<<<<<<<<<<<<
  21225. * implicit = 0
  21226. * tag_object = node.tag
  21227. */
  21228. }
  21229. __pyx_L10:;
  21230. /* "_yaml.pyx":1515
  21231. * error = self._emitter_error()
  21232. * raise error
  21233. * self.ascend_resolver() # <<<<<<<<<<<<<<
  21234. * return 1
  21235. *
  21236. */
  21237. __pyx_t_5 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v_self), __pyx_n_s_ascend_resolver); if (unlikely(!__pyx_t_5)) __PYX_ERR(0, 1515, __pyx_L1_error)
  21238. __Pyx_GOTREF(__pyx_t_5);
  21239. __pyx_t_6 = NULL;
  21240. if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_5))) {
  21241. __pyx_t_6 = PyMethod_GET_SELF(__pyx_t_5);
  21242. if (likely(__pyx_t_6)) {
  21243. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_5);
  21244. __Pyx_INCREF(__pyx_t_6);
  21245. __Pyx_INCREF(function);
  21246. __Pyx_DECREF_SET(__pyx_t_5, function);
  21247. }
  21248. }
  21249. __pyx_t_1 = (__pyx_t_6) ? __Pyx_PyObject_CallOneArg(__pyx_t_5, __pyx_t_6) : __Pyx_PyObject_CallNoArg(__pyx_t_5);
  21250. __Pyx_XDECREF(__pyx_t_6); __pyx_t_6 = 0;
  21251. if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1515, __pyx_L1_error)
  21252. __Pyx_GOTREF(__pyx_t_1);
  21253. __Pyx_DECREF(__pyx_t_5); __pyx_t_5 = 0;
  21254. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  21255. }
  21256. __pyx_L7:;
  21257. /* "_yaml.pyx":1516
  21258. * raise error
  21259. * self.ascend_resolver()
  21260. * return 1 # <<<<<<<<<<<<<<
  21261. *
  21262. * cdef int output_handler(void *data, char *buffer, size_t size) except 0:
  21263. */
  21264. __pyx_r = 1;
  21265. goto __pyx_L0;
  21266. /* "_yaml.pyx":1374
  21267. * return 1
  21268. *
  21269. * cdef int _serialize_node(self, object node, object parent, object index) except 0: # <<<<<<<<<<<<<<
  21270. * cdef yaml_event_t event
  21271. * cdef int implicit
  21272. */
  21273. /* function exit code */
  21274. __pyx_L1_error:;
  21275. __Pyx_XDECREF(__pyx_t_1);
  21276. __Pyx_XDECREF(__pyx_t_5);
  21277. __Pyx_XDECREF(__pyx_t_6);
  21278. __Pyx_XDECREF(__pyx_t_7);
  21279. __Pyx_XDECREF(__pyx_t_8);
  21280. __Pyx_XDECREF(__pyx_t_9);
  21281. __Pyx_AddTraceback("_yaml.CEmitter._serialize_node", __pyx_clineno, __pyx_lineno, __pyx_filename);
  21282. __pyx_r = 0;
  21283. __pyx_L0:;
  21284. __Pyx_XDECREF(__pyx_v_anchor_object);
  21285. __Pyx_XDECREF(__pyx_v_error);
  21286. __Pyx_XDECREF(__pyx_v_node_class);
  21287. __Pyx_XDECREF(__pyx_v_tag_object);
  21288. __Pyx_XDECREF(__pyx_v_value_object);
  21289. __Pyx_XDECREF(__pyx_v_style_object);
  21290. __Pyx_XDECREF(__pyx_v_item);
  21291. __Pyx_XDECREF(__pyx_v_item_key);
  21292. __Pyx_XDECREF(__pyx_v_item_value);
  21293. __Pyx_RefNannyFinishContext();
  21294. return __pyx_r;
  21295. }
  21296. /* "(tree fragment)":1
  21297. * def __reduce_cython__(self): # <<<<<<<<<<<<<<
  21298. * raise TypeError("Pickling of struct members such as self.emitter must be explicitly requested with @auto_pickle(True)")
  21299. * def __setstate_cython__(self, __pyx_state):
  21300. */
  21301. /* Python wrapper */
  21302. static PyObject *__pyx_pw_5_yaml_8CEmitter_15__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused); /*proto*/
  21303. static PyObject *__pyx_pw_5_yaml_8CEmitter_15__reduce_cython__(PyObject *__pyx_v_self, CYTHON_UNUSED PyObject *unused) {
  21304. PyObject *__pyx_r = 0;
  21305. __Pyx_RefNannyDeclarations
  21306. __Pyx_RefNannySetupContext("__reduce_cython__ (wrapper)", 0);
  21307. __pyx_r = __pyx_pf_5_yaml_8CEmitter_14__reduce_cython__(((struct __pyx_obj_5_yaml_CEmitter *)__pyx_v_self));
  21308. /* function exit code */
  21309. __Pyx_RefNannyFinishContext();
  21310. return __pyx_r;
  21311. }
  21312. static PyObject *__pyx_pf_5_yaml_8CEmitter_14__reduce_cython__(CYTHON_UNUSED struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self) {
  21313. PyObject *__pyx_r = NULL;
  21314. __Pyx_RefNannyDeclarations
  21315. PyObject *__pyx_t_1 = NULL;
  21316. __Pyx_RefNannySetupContext("__reduce_cython__", 0);
  21317. /* "(tree fragment)":2
  21318. * def __reduce_cython__(self):
  21319. * raise TypeError("Pickling of struct members such as self.emitter must be explicitly requested with @auto_pickle(True)") # <<<<<<<<<<<<<<
  21320. * def __setstate_cython__(self, __pyx_state):
  21321. * raise TypeError("Pickling of struct members such as self.emitter must be explicitly requested with @auto_pickle(True)")
  21322. */
  21323. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__38, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 2, __pyx_L1_error)
  21324. __Pyx_GOTREF(__pyx_t_1);
  21325. __Pyx_Raise(__pyx_t_1, 0, 0, 0);
  21326. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  21327. __PYX_ERR(1, 2, __pyx_L1_error)
  21328. /* "(tree fragment)":1
  21329. * def __reduce_cython__(self): # <<<<<<<<<<<<<<
  21330. * raise TypeError("Pickling of struct members such as self.emitter must be explicitly requested with @auto_pickle(True)")
  21331. * def __setstate_cython__(self, __pyx_state):
  21332. */
  21333. /* function exit code */
  21334. __pyx_L1_error:;
  21335. __Pyx_XDECREF(__pyx_t_1);
  21336. __Pyx_AddTraceback("_yaml.CEmitter.__reduce_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  21337. __pyx_r = NULL;
  21338. __Pyx_XGIVEREF(__pyx_r);
  21339. __Pyx_RefNannyFinishContext();
  21340. return __pyx_r;
  21341. }
  21342. /* "(tree fragment)":3
  21343. * def __reduce_cython__(self):
  21344. * raise TypeError("Pickling of struct members such as self.emitter must be explicitly requested with @auto_pickle(True)")
  21345. * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<<
  21346. * raise TypeError("Pickling of struct members such as self.emitter must be explicitly requested with @auto_pickle(True)")
  21347. */
  21348. /* Python wrapper */
  21349. static PyObject *__pyx_pw_5_yaml_8CEmitter_17__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state); /*proto*/
  21350. static PyObject *__pyx_pw_5_yaml_8CEmitter_17__setstate_cython__(PyObject *__pyx_v_self, PyObject *__pyx_v___pyx_state) {
  21351. PyObject *__pyx_r = 0;
  21352. __Pyx_RefNannyDeclarations
  21353. __Pyx_RefNannySetupContext("__setstate_cython__ (wrapper)", 0);
  21354. __pyx_r = __pyx_pf_5_yaml_8CEmitter_16__setstate_cython__(((struct __pyx_obj_5_yaml_CEmitter *)__pyx_v_self), ((PyObject *)__pyx_v___pyx_state));
  21355. /* function exit code */
  21356. __Pyx_RefNannyFinishContext();
  21357. return __pyx_r;
  21358. }
  21359. static PyObject *__pyx_pf_5_yaml_8CEmitter_16__setstate_cython__(CYTHON_UNUSED struct __pyx_obj_5_yaml_CEmitter *__pyx_v_self, CYTHON_UNUSED PyObject *__pyx_v___pyx_state) {
  21360. PyObject *__pyx_r = NULL;
  21361. __Pyx_RefNannyDeclarations
  21362. PyObject *__pyx_t_1 = NULL;
  21363. __Pyx_RefNannySetupContext("__setstate_cython__", 0);
  21364. /* "(tree fragment)":4
  21365. * raise TypeError("Pickling of struct members such as self.emitter must be explicitly requested with @auto_pickle(True)")
  21366. * def __setstate_cython__(self, __pyx_state):
  21367. * raise TypeError("Pickling of struct members such as self.emitter must be explicitly requested with @auto_pickle(True)") # <<<<<<<<<<<<<<
  21368. */
  21369. __pyx_t_1 = __Pyx_PyObject_Call(__pyx_builtin_TypeError, __pyx_tuple__39, NULL); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 4, __pyx_L1_error)
  21370. __Pyx_GOTREF(__pyx_t_1);
  21371. __Pyx_Raise(__pyx_t_1, 0, 0, 0);
  21372. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  21373. __PYX_ERR(1, 4, __pyx_L1_error)
  21374. /* "(tree fragment)":3
  21375. * def __reduce_cython__(self):
  21376. * raise TypeError("Pickling of struct members such as self.emitter must be explicitly requested with @auto_pickle(True)")
  21377. * def __setstate_cython__(self, __pyx_state): # <<<<<<<<<<<<<<
  21378. * raise TypeError("Pickling of struct members such as self.emitter must be explicitly requested with @auto_pickle(True)")
  21379. */
  21380. /* function exit code */
  21381. __pyx_L1_error:;
  21382. __Pyx_XDECREF(__pyx_t_1);
  21383. __Pyx_AddTraceback("_yaml.CEmitter.__setstate_cython__", __pyx_clineno, __pyx_lineno, __pyx_filename);
  21384. __pyx_r = NULL;
  21385. __Pyx_XGIVEREF(__pyx_r);
  21386. __Pyx_RefNannyFinishContext();
  21387. return __pyx_r;
  21388. }
  21389. /* "_yaml.pyx":1518
  21390. * return 1
  21391. *
  21392. * cdef int output_handler(void *data, char *buffer, size_t size) except 0: # <<<<<<<<<<<<<<
  21393. * cdef CEmitter emitter
  21394. * emitter = <CEmitter>data
  21395. */
  21396. static int __pyx_f_5_yaml_output_handler(void *__pyx_v_data, char *__pyx_v_buffer, size_t __pyx_v_size) {
  21397. struct __pyx_obj_5_yaml_CEmitter *__pyx_v_emitter = 0;
  21398. PyObject *__pyx_v_value = NULL;
  21399. int __pyx_r;
  21400. __Pyx_RefNannyDeclarations
  21401. PyObject *__pyx_t_1 = NULL;
  21402. int __pyx_t_2;
  21403. PyObject *__pyx_t_3 = NULL;
  21404. PyObject *__pyx_t_4 = NULL;
  21405. __Pyx_RefNannySetupContext("output_handler", 0);
  21406. /* "_yaml.pyx":1520
  21407. * cdef int output_handler(void *data, char *buffer, size_t size) except 0:
  21408. * cdef CEmitter emitter
  21409. * emitter = <CEmitter>data # <<<<<<<<<<<<<<
  21410. * if emitter.dump_unicode == 0:
  21411. * value = PyString_FromStringAndSize(buffer, size)
  21412. */
  21413. __pyx_t_1 = ((PyObject *)__pyx_v_data);
  21414. __Pyx_INCREF(__pyx_t_1);
  21415. __pyx_v_emitter = ((struct __pyx_obj_5_yaml_CEmitter *)__pyx_t_1);
  21416. __pyx_t_1 = 0;
  21417. /* "_yaml.pyx":1521
  21418. * cdef CEmitter emitter
  21419. * emitter = <CEmitter>data
  21420. * if emitter.dump_unicode == 0: # <<<<<<<<<<<<<<
  21421. * value = PyString_FromStringAndSize(buffer, size)
  21422. * else:
  21423. */
  21424. __pyx_t_2 = ((__pyx_v_emitter->dump_unicode == 0) != 0);
  21425. if (__pyx_t_2) {
  21426. /* "_yaml.pyx":1522
  21427. * emitter = <CEmitter>data
  21428. * if emitter.dump_unicode == 0:
  21429. * value = PyString_FromStringAndSize(buffer, size) # <<<<<<<<<<<<<<
  21430. * else:
  21431. * value = PyUnicode_DecodeUTF8(buffer, size, 'strict')
  21432. */
  21433. __pyx_t_1 = PyString_FromStringAndSize(__pyx_v_buffer, __pyx_v_size); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1522, __pyx_L1_error)
  21434. __Pyx_GOTREF(__pyx_t_1);
  21435. __pyx_v_value = __pyx_t_1;
  21436. __pyx_t_1 = 0;
  21437. /* "_yaml.pyx":1521
  21438. * cdef CEmitter emitter
  21439. * emitter = <CEmitter>data
  21440. * if emitter.dump_unicode == 0: # <<<<<<<<<<<<<<
  21441. * value = PyString_FromStringAndSize(buffer, size)
  21442. * else:
  21443. */
  21444. goto __pyx_L3;
  21445. }
  21446. /* "_yaml.pyx":1524
  21447. * value = PyString_FromStringAndSize(buffer, size)
  21448. * else:
  21449. * value = PyUnicode_DecodeUTF8(buffer, size, 'strict') # <<<<<<<<<<<<<<
  21450. * emitter.stream.write(value)
  21451. * return 1
  21452. */
  21453. /*else*/ {
  21454. __pyx_t_1 = PyUnicode_DecodeUTF8(__pyx_v_buffer, __pyx_v_size, ((char *)"strict")); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1524, __pyx_L1_error)
  21455. __Pyx_GOTREF(__pyx_t_1);
  21456. __pyx_v_value = __pyx_t_1;
  21457. __pyx_t_1 = 0;
  21458. }
  21459. __pyx_L3:;
  21460. /* "_yaml.pyx":1525
  21461. * else:
  21462. * value = PyUnicode_DecodeUTF8(buffer, size, 'strict')
  21463. * emitter.stream.write(value) # <<<<<<<<<<<<<<
  21464. * return 1
  21465. *
  21466. */
  21467. __pyx_t_3 = __Pyx_PyObject_GetAttrStr(__pyx_v_emitter->stream, __pyx_n_s_write); if (unlikely(!__pyx_t_3)) __PYX_ERR(0, 1525, __pyx_L1_error)
  21468. __Pyx_GOTREF(__pyx_t_3);
  21469. __pyx_t_4 = NULL;
  21470. if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_3))) {
  21471. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_3);
  21472. if (likely(__pyx_t_4)) {
  21473. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_3);
  21474. __Pyx_INCREF(__pyx_t_4);
  21475. __Pyx_INCREF(function);
  21476. __Pyx_DECREF_SET(__pyx_t_3, function);
  21477. }
  21478. }
  21479. __pyx_t_1 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_3, __pyx_t_4, __pyx_v_value) : __Pyx_PyObject_CallOneArg(__pyx_t_3, __pyx_v_value);
  21480. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  21481. if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 1525, __pyx_L1_error)
  21482. __Pyx_GOTREF(__pyx_t_1);
  21483. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  21484. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  21485. /* "_yaml.pyx":1526
  21486. * value = PyUnicode_DecodeUTF8(buffer, size, 'strict')
  21487. * emitter.stream.write(value)
  21488. * return 1 # <<<<<<<<<<<<<<
  21489. *
  21490. */
  21491. __pyx_r = 1;
  21492. goto __pyx_L0;
  21493. /* "_yaml.pyx":1518
  21494. * return 1
  21495. *
  21496. * cdef int output_handler(void *data, char *buffer, size_t size) except 0: # <<<<<<<<<<<<<<
  21497. * cdef CEmitter emitter
  21498. * emitter = <CEmitter>data
  21499. */
  21500. /* function exit code */
  21501. __pyx_L1_error:;
  21502. __Pyx_XDECREF(__pyx_t_1);
  21503. __Pyx_XDECREF(__pyx_t_3);
  21504. __Pyx_XDECREF(__pyx_t_4);
  21505. __Pyx_AddTraceback("_yaml.output_handler", __pyx_clineno, __pyx_lineno, __pyx_filename);
  21506. __pyx_r = 0;
  21507. __pyx_L0:;
  21508. __Pyx_XDECREF((PyObject *)__pyx_v_emitter);
  21509. __Pyx_XDECREF(__pyx_v_value);
  21510. __Pyx_RefNannyFinishContext();
  21511. return __pyx_r;
  21512. }
  21513. /* "(tree fragment)":1
  21514. * def __pyx_unpickle_Mark(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<<
  21515. * cdef object __pyx_PickleError
  21516. * cdef object __pyx_result
  21517. */
  21518. /* Python wrapper */
  21519. static PyObject *__pyx_pw_5_yaml_5__pyx_unpickle_Mark(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds); /*proto*/
  21520. static PyMethodDef __pyx_mdef_5_yaml_5__pyx_unpickle_Mark = {"__pyx_unpickle_Mark", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_5_yaml_5__pyx_unpickle_Mark, METH_VARARGS|METH_KEYWORDS, 0};
  21521. static PyObject *__pyx_pw_5_yaml_5__pyx_unpickle_Mark(PyObject *__pyx_self, PyObject *__pyx_args, PyObject *__pyx_kwds) {
  21522. PyObject *__pyx_v___pyx_type = 0;
  21523. long __pyx_v___pyx_checksum;
  21524. PyObject *__pyx_v___pyx_state = 0;
  21525. PyObject *__pyx_r = 0;
  21526. __Pyx_RefNannyDeclarations
  21527. __Pyx_RefNannySetupContext("__pyx_unpickle_Mark (wrapper)", 0);
  21528. {
  21529. static PyObject **__pyx_pyargnames[] = {&__pyx_n_s_pyx_type,&__pyx_n_s_pyx_checksum,&__pyx_n_s_pyx_state,0};
  21530. PyObject* values[3] = {0,0,0};
  21531. if (unlikely(__pyx_kwds)) {
  21532. Py_ssize_t kw_args;
  21533. const Py_ssize_t pos_args = PyTuple_GET_SIZE(__pyx_args);
  21534. switch (pos_args) {
  21535. case 3: values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
  21536. CYTHON_FALLTHROUGH;
  21537. case 2: values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
  21538. CYTHON_FALLTHROUGH;
  21539. case 1: values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
  21540. CYTHON_FALLTHROUGH;
  21541. case 0: break;
  21542. default: goto __pyx_L5_argtuple_error;
  21543. }
  21544. kw_args = PyDict_Size(__pyx_kwds);
  21545. switch (pos_args) {
  21546. case 0:
  21547. if (likely((values[0] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_type)) != 0)) kw_args--;
  21548. else goto __pyx_L5_argtuple_error;
  21549. CYTHON_FALLTHROUGH;
  21550. case 1:
  21551. if (likely((values[1] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_checksum)) != 0)) kw_args--;
  21552. else {
  21553. __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Mark", 1, 3, 3, 1); __PYX_ERR(1, 1, __pyx_L3_error)
  21554. }
  21555. CYTHON_FALLTHROUGH;
  21556. case 2:
  21557. if (likely((values[2] = __Pyx_PyDict_GetItemStr(__pyx_kwds, __pyx_n_s_pyx_state)) != 0)) kw_args--;
  21558. else {
  21559. __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Mark", 1, 3, 3, 2); __PYX_ERR(1, 1, __pyx_L3_error)
  21560. }
  21561. }
  21562. if (unlikely(kw_args > 0)) {
  21563. if (unlikely(__Pyx_ParseOptionalKeywords(__pyx_kwds, __pyx_pyargnames, 0, values, pos_args, "__pyx_unpickle_Mark") < 0)) __PYX_ERR(1, 1, __pyx_L3_error)
  21564. }
  21565. } else if (PyTuple_GET_SIZE(__pyx_args) != 3) {
  21566. goto __pyx_L5_argtuple_error;
  21567. } else {
  21568. values[0] = PyTuple_GET_ITEM(__pyx_args, 0);
  21569. values[1] = PyTuple_GET_ITEM(__pyx_args, 1);
  21570. values[2] = PyTuple_GET_ITEM(__pyx_args, 2);
  21571. }
  21572. __pyx_v___pyx_type = values[0];
  21573. __pyx_v___pyx_checksum = __Pyx_PyInt_As_long(values[1]); if (unlikely((__pyx_v___pyx_checksum == (long)-1) && PyErr_Occurred())) __PYX_ERR(1, 1, __pyx_L3_error)
  21574. __pyx_v___pyx_state = values[2];
  21575. }
  21576. goto __pyx_L4_argument_unpacking_done;
  21577. __pyx_L5_argtuple_error:;
  21578. __Pyx_RaiseArgtupleInvalid("__pyx_unpickle_Mark", 1, 3, 3, PyTuple_GET_SIZE(__pyx_args)); __PYX_ERR(1, 1, __pyx_L3_error)
  21579. __pyx_L3_error:;
  21580. __Pyx_AddTraceback("_yaml.__pyx_unpickle_Mark", __pyx_clineno, __pyx_lineno, __pyx_filename);
  21581. __Pyx_RefNannyFinishContext();
  21582. return NULL;
  21583. __pyx_L4_argument_unpacking_done:;
  21584. __pyx_r = __pyx_pf_5_yaml_4__pyx_unpickle_Mark(__pyx_self, __pyx_v___pyx_type, __pyx_v___pyx_checksum, __pyx_v___pyx_state);
  21585. /* function exit code */
  21586. __Pyx_RefNannyFinishContext();
  21587. return __pyx_r;
  21588. }
  21589. static PyObject *__pyx_pf_5_yaml_4__pyx_unpickle_Mark(CYTHON_UNUSED PyObject *__pyx_self, PyObject *__pyx_v___pyx_type, long __pyx_v___pyx_checksum, PyObject *__pyx_v___pyx_state) {
  21590. PyObject *__pyx_v___pyx_PickleError = 0;
  21591. PyObject *__pyx_v___pyx_result = 0;
  21592. PyObject *__pyx_r = NULL;
  21593. __Pyx_RefNannyDeclarations
  21594. int __pyx_t_1;
  21595. PyObject *__pyx_t_2 = NULL;
  21596. PyObject *__pyx_t_3 = NULL;
  21597. PyObject *__pyx_t_4 = NULL;
  21598. PyObject *__pyx_t_5 = NULL;
  21599. int __pyx_t_6;
  21600. __Pyx_RefNannySetupContext("__pyx_unpickle_Mark", 0);
  21601. /* "(tree fragment)":4
  21602. * cdef object __pyx_PickleError
  21603. * cdef object __pyx_result
  21604. * if __pyx_checksum != 0x3fa45b6: # <<<<<<<<<<<<<<
  21605. * from pickle import PickleError as __pyx_PickleError
  21606. * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3fa45b6 = (buffer, column, index, line, name, pointer))" % __pyx_checksum)
  21607. */
  21608. __pyx_t_1 = ((__pyx_v___pyx_checksum != 0x3fa45b6) != 0);
  21609. if (__pyx_t_1) {
  21610. /* "(tree fragment)":5
  21611. * cdef object __pyx_result
  21612. * if __pyx_checksum != 0x3fa45b6:
  21613. * from pickle import PickleError as __pyx_PickleError # <<<<<<<<<<<<<<
  21614. * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3fa45b6 = (buffer, column, index, line, name, pointer))" % __pyx_checksum)
  21615. * __pyx_result = Mark.__new__(__pyx_type)
  21616. */
  21617. __pyx_t_2 = PyList_New(1); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 5, __pyx_L1_error)
  21618. __Pyx_GOTREF(__pyx_t_2);
  21619. __Pyx_INCREF(__pyx_n_s_PickleError);
  21620. __Pyx_GIVEREF(__pyx_n_s_PickleError);
  21621. PyList_SET_ITEM(__pyx_t_2, 0, __pyx_n_s_PickleError);
  21622. __pyx_t_3 = __Pyx_Import(__pyx_n_s_pickle, __pyx_t_2, -1); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 5, __pyx_L1_error)
  21623. __Pyx_GOTREF(__pyx_t_3);
  21624. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  21625. __pyx_t_2 = __Pyx_ImportFrom(__pyx_t_3, __pyx_n_s_PickleError); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 5, __pyx_L1_error)
  21626. __Pyx_GOTREF(__pyx_t_2);
  21627. __Pyx_INCREF(__pyx_t_2);
  21628. __pyx_v___pyx_PickleError = __pyx_t_2;
  21629. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  21630. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  21631. /* "(tree fragment)":6
  21632. * if __pyx_checksum != 0x3fa45b6:
  21633. * from pickle import PickleError as __pyx_PickleError
  21634. * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3fa45b6 = (buffer, column, index, line, name, pointer))" % __pyx_checksum) # <<<<<<<<<<<<<<
  21635. * __pyx_result = Mark.__new__(__pyx_type)
  21636. * if __pyx_state is not None:
  21637. */
  21638. __pyx_t_2 = __Pyx_PyInt_From_long(__pyx_v___pyx_checksum); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 6, __pyx_L1_error)
  21639. __Pyx_GOTREF(__pyx_t_2);
  21640. __pyx_t_4 = __Pyx_PyString_Format(__pyx_kp_s_Incompatible_checksums_s_vs_0x3f, __pyx_t_2); if (unlikely(!__pyx_t_4)) __PYX_ERR(1, 6, __pyx_L1_error)
  21641. __Pyx_GOTREF(__pyx_t_4);
  21642. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  21643. __Pyx_INCREF(__pyx_v___pyx_PickleError);
  21644. __pyx_t_2 = __pyx_v___pyx_PickleError; __pyx_t_5 = NULL;
  21645. if (CYTHON_UNPACK_METHODS && unlikely(PyMethod_Check(__pyx_t_2))) {
  21646. __pyx_t_5 = PyMethod_GET_SELF(__pyx_t_2);
  21647. if (likely(__pyx_t_5)) {
  21648. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
  21649. __Pyx_INCREF(__pyx_t_5);
  21650. __Pyx_INCREF(function);
  21651. __Pyx_DECREF_SET(__pyx_t_2, function);
  21652. }
  21653. }
  21654. __pyx_t_3 = (__pyx_t_5) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_5, __pyx_t_4) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_t_4);
  21655. __Pyx_XDECREF(__pyx_t_5); __pyx_t_5 = 0;
  21656. __Pyx_DECREF(__pyx_t_4); __pyx_t_4 = 0;
  21657. if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 6, __pyx_L1_error)
  21658. __Pyx_GOTREF(__pyx_t_3);
  21659. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  21660. __Pyx_Raise(__pyx_t_3, 0, 0, 0);
  21661. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  21662. __PYX_ERR(1, 6, __pyx_L1_error)
  21663. /* "(tree fragment)":4
  21664. * cdef object __pyx_PickleError
  21665. * cdef object __pyx_result
  21666. * if __pyx_checksum != 0x3fa45b6: # <<<<<<<<<<<<<<
  21667. * from pickle import PickleError as __pyx_PickleError
  21668. * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3fa45b6 = (buffer, column, index, line, name, pointer))" % __pyx_checksum)
  21669. */
  21670. }
  21671. /* "(tree fragment)":7
  21672. * from pickle import PickleError as __pyx_PickleError
  21673. * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3fa45b6 = (buffer, column, index, line, name, pointer))" % __pyx_checksum)
  21674. * __pyx_result = Mark.__new__(__pyx_type) # <<<<<<<<<<<<<<
  21675. * if __pyx_state is not None:
  21676. * __pyx_unpickle_Mark__set_state(<Mark> __pyx_result, __pyx_state)
  21677. */
  21678. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_ptype_5_yaml_Mark), __pyx_n_s_new); if (unlikely(!__pyx_t_2)) __PYX_ERR(1, 7, __pyx_L1_error)
  21679. __Pyx_GOTREF(__pyx_t_2);
  21680. __pyx_t_4 = NULL;
  21681. if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_2))) {
  21682. __pyx_t_4 = PyMethod_GET_SELF(__pyx_t_2);
  21683. if (likely(__pyx_t_4)) {
  21684. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_2);
  21685. __Pyx_INCREF(__pyx_t_4);
  21686. __Pyx_INCREF(function);
  21687. __Pyx_DECREF_SET(__pyx_t_2, function);
  21688. }
  21689. }
  21690. __pyx_t_3 = (__pyx_t_4) ? __Pyx_PyObject_Call2Args(__pyx_t_2, __pyx_t_4, __pyx_v___pyx_type) : __Pyx_PyObject_CallOneArg(__pyx_t_2, __pyx_v___pyx_type);
  21691. __Pyx_XDECREF(__pyx_t_4); __pyx_t_4 = 0;
  21692. if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 7, __pyx_L1_error)
  21693. __Pyx_GOTREF(__pyx_t_3);
  21694. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  21695. __pyx_v___pyx_result = __pyx_t_3;
  21696. __pyx_t_3 = 0;
  21697. /* "(tree fragment)":8
  21698. * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3fa45b6 = (buffer, column, index, line, name, pointer))" % __pyx_checksum)
  21699. * __pyx_result = Mark.__new__(__pyx_type)
  21700. * if __pyx_state is not None: # <<<<<<<<<<<<<<
  21701. * __pyx_unpickle_Mark__set_state(<Mark> __pyx_result, __pyx_state)
  21702. * return __pyx_result
  21703. */
  21704. __pyx_t_1 = (__pyx_v___pyx_state != Py_None);
  21705. __pyx_t_6 = (__pyx_t_1 != 0);
  21706. if (__pyx_t_6) {
  21707. /* "(tree fragment)":9
  21708. * __pyx_result = Mark.__new__(__pyx_type)
  21709. * if __pyx_state is not None:
  21710. * __pyx_unpickle_Mark__set_state(<Mark> __pyx_result, __pyx_state) # <<<<<<<<<<<<<<
  21711. * return __pyx_result
  21712. * cdef __pyx_unpickle_Mark__set_state(Mark __pyx_result, tuple __pyx_state):
  21713. */
  21714. if (!(likely(PyTuple_CheckExact(__pyx_v___pyx_state))||((__pyx_v___pyx_state) == Py_None)||(PyErr_Format(PyExc_TypeError, "Expected %.16s, got %.200s", "tuple", Py_TYPE(__pyx_v___pyx_state)->tp_name), 0))) __PYX_ERR(1, 9, __pyx_L1_error)
  21715. __pyx_t_3 = __pyx_f_5_yaml___pyx_unpickle_Mark__set_state(((struct __pyx_obj_5_yaml_Mark *)__pyx_v___pyx_result), ((PyObject*)__pyx_v___pyx_state)); if (unlikely(!__pyx_t_3)) __PYX_ERR(1, 9, __pyx_L1_error)
  21716. __Pyx_GOTREF(__pyx_t_3);
  21717. __Pyx_DECREF(__pyx_t_3); __pyx_t_3 = 0;
  21718. /* "(tree fragment)":8
  21719. * raise __pyx_PickleError("Incompatible checksums (%s vs 0x3fa45b6 = (buffer, column, index, line, name, pointer))" % __pyx_checksum)
  21720. * __pyx_result = Mark.__new__(__pyx_type)
  21721. * if __pyx_state is not None: # <<<<<<<<<<<<<<
  21722. * __pyx_unpickle_Mark__set_state(<Mark> __pyx_result, __pyx_state)
  21723. * return __pyx_result
  21724. */
  21725. }
  21726. /* "(tree fragment)":10
  21727. * if __pyx_state is not None:
  21728. * __pyx_unpickle_Mark__set_state(<Mark> __pyx_result, __pyx_state)
  21729. * return __pyx_result # <<<<<<<<<<<<<<
  21730. * cdef __pyx_unpickle_Mark__set_state(Mark __pyx_result, tuple __pyx_state):
  21731. * __pyx_result.buffer = __pyx_state[0]; __pyx_result.column = __pyx_state[1]; __pyx_result.index = __pyx_state[2]; __pyx_result.line = __pyx_state[3]; __pyx_result.name = __pyx_state[4]; __pyx_result.pointer = __pyx_state[5]
  21732. */
  21733. __Pyx_XDECREF(__pyx_r);
  21734. __Pyx_INCREF(__pyx_v___pyx_result);
  21735. __pyx_r = __pyx_v___pyx_result;
  21736. goto __pyx_L0;
  21737. /* "(tree fragment)":1
  21738. * def __pyx_unpickle_Mark(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<<
  21739. * cdef object __pyx_PickleError
  21740. * cdef object __pyx_result
  21741. */
  21742. /* function exit code */
  21743. __pyx_L1_error:;
  21744. __Pyx_XDECREF(__pyx_t_2);
  21745. __Pyx_XDECREF(__pyx_t_3);
  21746. __Pyx_XDECREF(__pyx_t_4);
  21747. __Pyx_XDECREF(__pyx_t_5);
  21748. __Pyx_AddTraceback("_yaml.__pyx_unpickle_Mark", __pyx_clineno, __pyx_lineno, __pyx_filename);
  21749. __pyx_r = NULL;
  21750. __pyx_L0:;
  21751. __Pyx_XDECREF(__pyx_v___pyx_PickleError);
  21752. __Pyx_XDECREF(__pyx_v___pyx_result);
  21753. __Pyx_XGIVEREF(__pyx_r);
  21754. __Pyx_RefNannyFinishContext();
  21755. return __pyx_r;
  21756. }
  21757. /* "(tree fragment)":11
  21758. * __pyx_unpickle_Mark__set_state(<Mark> __pyx_result, __pyx_state)
  21759. * return __pyx_result
  21760. * cdef __pyx_unpickle_Mark__set_state(Mark __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<<
  21761. * __pyx_result.buffer = __pyx_state[0]; __pyx_result.column = __pyx_state[1]; __pyx_result.index = __pyx_state[2]; __pyx_result.line = __pyx_state[3]; __pyx_result.name = __pyx_state[4]; __pyx_result.pointer = __pyx_state[5]
  21762. * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'):
  21763. */
  21764. static PyObject *__pyx_f_5_yaml___pyx_unpickle_Mark__set_state(struct __pyx_obj_5_yaml_Mark *__pyx_v___pyx_result, PyObject *__pyx_v___pyx_state) {
  21765. PyObject *__pyx_r = NULL;
  21766. __Pyx_RefNannyDeclarations
  21767. PyObject *__pyx_t_1 = NULL;
  21768. size_t __pyx_t_2;
  21769. int __pyx_t_3;
  21770. Py_ssize_t __pyx_t_4;
  21771. int __pyx_t_5;
  21772. int __pyx_t_6;
  21773. PyObject *__pyx_t_7 = NULL;
  21774. PyObject *__pyx_t_8 = NULL;
  21775. PyObject *__pyx_t_9 = NULL;
  21776. __Pyx_RefNannySetupContext("__pyx_unpickle_Mark__set_state", 0);
  21777. /* "(tree fragment)":12
  21778. * return __pyx_result
  21779. * cdef __pyx_unpickle_Mark__set_state(Mark __pyx_result, tuple __pyx_state):
  21780. * __pyx_result.buffer = __pyx_state[0]; __pyx_result.column = __pyx_state[1]; __pyx_result.index = __pyx_state[2]; __pyx_result.line = __pyx_state[3]; __pyx_result.name = __pyx_state[4]; __pyx_result.pointer = __pyx_state[5] # <<<<<<<<<<<<<<
  21781. * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'):
  21782. * __pyx_result.__dict__.update(__pyx_state[6])
  21783. */
  21784. if (unlikely(__pyx_v___pyx_state == Py_None)) {
  21785. PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
  21786. __PYX_ERR(1, 12, __pyx_L1_error)
  21787. }
  21788. __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 0, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
  21789. __Pyx_GOTREF(__pyx_t_1);
  21790. __Pyx_GIVEREF(__pyx_t_1);
  21791. __Pyx_GOTREF(__pyx_v___pyx_result->buffer);
  21792. __Pyx_DECREF(__pyx_v___pyx_result->buffer);
  21793. __pyx_v___pyx_result->buffer = __pyx_t_1;
  21794. __pyx_t_1 = 0;
  21795. if (unlikely(__pyx_v___pyx_state == Py_None)) {
  21796. PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
  21797. __PYX_ERR(1, 12, __pyx_L1_error)
  21798. }
  21799. __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 1, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
  21800. __Pyx_GOTREF(__pyx_t_1);
  21801. __pyx_t_2 = __Pyx_PyInt_As_size_t(__pyx_t_1); if (unlikely((__pyx_t_2 == (size_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 12, __pyx_L1_error)
  21802. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  21803. __pyx_v___pyx_result->column = __pyx_t_2;
  21804. if (unlikely(__pyx_v___pyx_state == Py_None)) {
  21805. PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
  21806. __PYX_ERR(1, 12, __pyx_L1_error)
  21807. }
  21808. __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 2, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
  21809. __Pyx_GOTREF(__pyx_t_1);
  21810. __pyx_t_2 = __Pyx_PyInt_As_size_t(__pyx_t_1); if (unlikely((__pyx_t_2 == (size_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 12, __pyx_L1_error)
  21811. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  21812. __pyx_v___pyx_result->index = __pyx_t_2;
  21813. if (unlikely(__pyx_v___pyx_state == Py_None)) {
  21814. PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
  21815. __PYX_ERR(1, 12, __pyx_L1_error)
  21816. }
  21817. __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 3, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
  21818. __Pyx_GOTREF(__pyx_t_1);
  21819. __pyx_t_2 = __Pyx_PyInt_As_size_t(__pyx_t_1); if (unlikely((__pyx_t_2 == (size_t)-1) && PyErr_Occurred())) __PYX_ERR(1, 12, __pyx_L1_error)
  21820. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  21821. __pyx_v___pyx_result->line = __pyx_t_2;
  21822. if (unlikely(__pyx_v___pyx_state == Py_None)) {
  21823. PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
  21824. __PYX_ERR(1, 12, __pyx_L1_error)
  21825. }
  21826. __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 4, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
  21827. __Pyx_GOTREF(__pyx_t_1);
  21828. __Pyx_GIVEREF(__pyx_t_1);
  21829. __Pyx_GOTREF(__pyx_v___pyx_result->name);
  21830. __Pyx_DECREF(__pyx_v___pyx_result->name);
  21831. __pyx_v___pyx_result->name = __pyx_t_1;
  21832. __pyx_t_1 = 0;
  21833. if (unlikely(__pyx_v___pyx_state == Py_None)) {
  21834. PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
  21835. __PYX_ERR(1, 12, __pyx_L1_error)
  21836. }
  21837. __pyx_t_1 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 5, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 12, __pyx_L1_error)
  21838. __Pyx_GOTREF(__pyx_t_1);
  21839. __Pyx_GIVEREF(__pyx_t_1);
  21840. __Pyx_GOTREF(__pyx_v___pyx_result->pointer);
  21841. __Pyx_DECREF(__pyx_v___pyx_result->pointer);
  21842. __pyx_v___pyx_result->pointer = __pyx_t_1;
  21843. __pyx_t_1 = 0;
  21844. /* "(tree fragment)":13
  21845. * cdef __pyx_unpickle_Mark__set_state(Mark __pyx_result, tuple __pyx_state):
  21846. * __pyx_result.buffer = __pyx_state[0]; __pyx_result.column = __pyx_state[1]; __pyx_result.index = __pyx_state[2]; __pyx_result.line = __pyx_state[3]; __pyx_result.name = __pyx_state[4]; __pyx_result.pointer = __pyx_state[5]
  21847. * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<<
  21848. * __pyx_result.__dict__.update(__pyx_state[6])
  21849. */
  21850. if (unlikely(__pyx_v___pyx_state == Py_None)) {
  21851. PyErr_SetString(PyExc_TypeError, "object of type 'NoneType' has no len()");
  21852. __PYX_ERR(1, 13, __pyx_L1_error)
  21853. }
  21854. __pyx_t_4 = PyTuple_GET_SIZE(__pyx_v___pyx_state); if (unlikely(__pyx_t_4 == ((Py_ssize_t)-1))) __PYX_ERR(1, 13, __pyx_L1_error)
  21855. __pyx_t_5 = ((__pyx_t_4 > 6) != 0);
  21856. if (__pyx_t_5) {
  21857. } else {
  21858. __pyx_t_3 = __pyx_t_5;
  21859. goto __pyx_L4_bool_binop_done;
  21860. }
  21861. __pyx_t_5 = __Pyx_HasAttr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(__pyx_t_5 == ((int)-1))) __PYX_ERR(1, 13, __pyx_L1_error)
  21862. __pyx_t_6 = (__pyx_t_5 != 0);
  21863. __pyx_t_3 = __pyx_t_6;
  21864. __pyx_L4_bool_binop_done:;
  21865. if (__pyx_t_3) {
  21866. /* "(tree fragment)":14
  21867. * __pyx_result.buffer = __pyx_state[0]; __pyx_result.column = __pyx_state[1]; __pyx_result.index = __pyx_state[2]; __pyx_result.line = __pyx_state[3]; __pyx_result.name = __pyx_state[4]; __pyx_result.pointer = __pyx_state[5]
  21868. * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'):
  21869. * __pyx_result.__dict__.update(__pyx_state[6]) # <<<<<<<<<<<<<<
  21870. */
  21871. __pyx_t_7 = __Pyx_PyObject_GetAttrStr(((PyObject *)__pyx_v___pyx_result), __pyx_n_s_dict); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 14, __pyx_L1_error)
  21872. __Pyx_GOTREF(__pyx_t_7);
  21873. __pyx_t_8 = __Pyx_PyObject_GetAttrStr(__pyx_t_7, __pyx_n_s_update); if (unlikely(!__pyx_t_8)) __PYX_ERR(1, 14, __pyx_L1_error)
  21874. __Pyx_GOTREF(__pyx_t_8);
  21875. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  21876. if (unlikely(__pyx_v___pyx_state == Py_None)) {
  21877. PyErr_SetString(PyExc_TypeError, "'NoneType' object is not subscriptable");
  21878. __PYX_ERR(1, 14, __pyx_L1_error)
  21879. }
  21880. __pyx_t_7 = __Pyx_GetItemInt_Tuple(__pyx_v___pyx_state, 6, long, 1, __Pyx_PyInt_From_long, 0, 0, 1); if (unlikely(!__pyx_t_7)) __PYX_ERR(1, 14, __pyx_L1_error)
  21881. __Pyx_GOTREF(__pyx_t_7);
  21882. __pyx_t_9 = NULL;
  21883. if (CYTHON_UNPACK_METHODS && likely(PyMethod_Check(__pyx_t_8))) {
  21884. __pyx_t_9 = PyMethod_GET_SELF(__pyx_t_8);
  21885. if (likely(__pyx_t_9)) {
  21886. PyObject* function = PyMethod_GET_FUNCTION(__pyx_t_8);
  21887. __Pyx_INCREF(__pyx_t_9);
  21888. __Pyx_INCREF(function);
  21889. __Pyx_DECREF_SET(__pyx_t_8, function);
  21890. }
  21891. }
  21892. __pyx_t_1 = (__pyx_t_9) ? __Pyx_PyObject_Call2Args(__pyx_t_8, __pyx_t_9, __pyx_t_7) : __Pyx_PyObject_CallOneArg(__pyx_t_8, __pyx_t_7);
  21893. __Pyx_XDECREF(__pyx_t_9); __pyx_t_9 = 0;
  21894. __Pyx_DECREF(__pyx_t_7); __pyx_t_7 = 0;
  21895. if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 14, __pyx_L1_error)
  21896. __Pyx_GOTREF(__pyx_t_1);
  21897. __Pyx_DECREF(__pyx_t_8); __pyx_t_8 = 0;
  21898. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  21899. /* "(tree fragment)":13
  21900. * cdef __pyx_unpickle_Mark__set_state(Mark __pyx_result, tuple __pyx_state):
  21901. * __pyx_result.buffer = __pyx_state[0]; __pyx_result.column = __pyx_state[1]; __pyx_result.index = __pyx_state[2]; __pyx_result.line = __pyx_state[3]; __pyx_result.name = __pyx_state[4]; __pyx_result.pointer = __pyx_state[5]
  21902. * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'): # <<<<<<<<<<<<<<
  21903. * __pyx_result.__dict__.update(__pyx_state[6])
  21904. */
  21905. }
  21906. /* "(tree fragment)":11
  21907. * __pyx_unpickle_Mark__set_state(<Mark> __pyx_result, __pyx_state)
  21908. * return __pyx_result
  21909. * cdef __pyx_unpickle_Mark__set_state(Mark __pyx_result, tuple __pyx_state): # <<<<<<<<<<<<<<
  21910. * __pyx_result.buffer = __pyx_state[0]; __pyx_result.column = __pyx_state[1]; __pyx_result.index = __pyx_state[2]; __pyx_result.line = __pyx_state[3]; __pyx_result.name = __pyx_state[4]; __pyx_result.pointer = __pyx_state[5]
  21911. * if len(__pyx_state) > 6 and hasattr(__pyx_result, '__dict__'):
  21912. */
  21913. /* function exit code */
  21914. __pyx_r = Py_None; __Pyx_INCREF(Py_None);
  21915. goto __pyx_L0;
  21916. __pyx_L1_error:;
  21917. __Pyx_XDECREF(__pyx_t_1);
  21918. __Pyx_XDECREF(__pyx_t_7);
  21919. __Pyx_XDECREF(__pyx_t_8);
  21920. __Pyx_XDECREF(__pyx_t_9);
  21921. __Pyx_AddTraceback("_yaml.__pyx_unpickle_Mark__set_state", __pyx_clineno, __pyx_lineno, __pyx_filename);
  21922. __pyx_r = 0;
  21923. __pyx_L0:;
  21924. __Pyx_XGIVEREF(__pyx_r);
  21925. __Pyx_RefNannyFinishContext();
  21926. return __pyx_r;
  21927. }
  21928. static PyObject *__pyx_tp_new_5_yaml_Mark(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) {
  21929. struct __pyx_obj_5_yaml_Mark *p;
  21930. PyObject *o;
  21931. if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) {
  21932. o = (*t->tp_alloc)(t, 0);
  21933. } else {
  21934. o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
  21935. }
  21936. if (unlikely(!o)) return 0;
  21937. p = ((struct __pyx_obj_5_yaml_Mark *)o);
  21938. p->name = Py_None; Py_INCREF(Py_None);
  21939. p->buffer = Py_None; Py_INCREF(Py_None);
  21940. p->pointer = Py_None; Py_INCREF(Py_None);
  21941. return o;
  21942. }
  21943. static void __pyx_tp_dealloc_5_yaml_Mark(PyObject *o) {
  21944. struct __pyx_obj_5_yaml_Mark *p = (struct __pyx_obj_5_yaml_Mark *)o;
  21945. #if CYTHON_USE_TP_FINALIZE
  21946. if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) {
  21947. if (PyObject_CallFinalizerFromDealloc(o)) return;
  21948. }
  21949. #endif
  21950. PyObject_GC_UnTrack(o);
  21951. Py_CLEAR(p->name);
  21952. Py_CLEAR(p->buffer);
  21953. Py_CLEAR(p->pointer);
  21954. (*Py_TYPE(o)->tp_free)(o);
  21955. }
  21956. static int __pyx_tp_traverse_5_yaml_Mark(PyObject *o, visitproc v, void *a) {
  21957. int e;
  21958. struct __pyx_obj_5_yaml_Mark *p = (struct __pyx_obj_5_yaml_Mark *)o;
  21959. if (p->name) {
  21960. e = (*v)(p->name, a); if (e) return e;
  21961. }
  21962. if (p->buffer) {
  21963. e = (*v)(p->buffer, a); if (e) return e;
  21964. }
  21965. if (p->pointer) {
  21966. e = (*v)(p->pointer, a); if (e) return e;
  21967. }
  21968. return 0;
  21969. }
  21970. static int __pyx_tp_clear_5_yaml_Mark(PyObject *o) {
  21971. PyObject* tmp;
  21972. struct __pyx_obj_5_yaml_Mark *p = (struct __pyx_obj_5_yaml_Mark *)o;
  21973. tmp = ((PyObject*)p->name);
  21974. p->name = Py_None; Py_INCREF(Py_None);
  21975. Py_XDECREF(tmp);
  21976. tmp = ((PyObject*)p->buffer);
  21977. p->buffer = Py_None; Py_INCREF(Py_None);
  21978. Py_XDECREF(tmp);
  21979. tmp = ((PyObject*)p->pointer);
  21980. p->pointer = Py_None; Py_INCREF(Py_None);
  21981. Py_XDECREF(tmp);
  21982. return 0;
  21983. }
  21984. static PyObject *__pyx_getprop_5_yaml_4Mark_name(PyObject *o, CYTHON_UNUSED void *x) {
  21985. return __pyx_pw_5_yaml_4Mark_4name_1__get__(o);
  21986. }
  21987. static PyObject *__pyx_getprop_5_yaml_4Mark_index(PyObject *o, CYTHON_UNUSED void *x) {
  21988. return __pyx_pw_5_yaml_4Mark_5index_1__get__(o);
  21989. }
  21990. static PyObject *__pyx_getprop_5_yaml_4Mark_line(PyObject *o, CYTHON_UNUSED void *x) {
  21991. return __pyx_pw_5_yaml_4Mark_4line_1__get__(o);
  21992. }
  21993. static PyObject *__pyx_getprop_5_yaml_4Mark_column(PyObject *o, CYTHON_UNUSED void *x) {
  21994. return __pyx_pw_5_yaml_4Mark_6column_1__get__(o);
  21995. }
  21996. static PyObject *__pyx_getprop_5_yaml_4Mark_buffer(PyObject *o, CYTHON_UNUSED void *x) {
  21997. return __pyx_pw_5_yaml_4Mark_6buffer_1__get__(o);
  21998. }
  21999. static PyObject *__pyx_getprop_5_yaml_4Mark_pointer(PyObject *o, CYTHON_UNUSED void *x) {
  22000. return __pyx_pw_5_yaml_4Mark_7pointer_1__get__(o);
  22001. }
  22002. static PyMethodDef __pyx_methods_5_yaml_Mark[] = {
  22003. {"get_snippet", (PyCFunction)__pyx_pw_5_yaml_4Mark_3get_snippet, METH_NOARGS, 0},
  22004. {"__reduce_cython__", (PyCFunction)__pyx_pw_5_yaml_4Mark_7__reduce_cython__, METH_NOARGS, 0},
  22005. {"__setstate_cython__", (PyCFunction)__pyx_pw_5_yaml_4Mark_9__setstate_cython__, METH_O, 0},
  22006. {0, 0, 0, 0}
  22007. };
  22008. static struct PyGetSetDef __pyx_getsets_5_yaml_Mark[] = {
  22009. {(char *)"name", __pyx_getprop_5_yaml_4Mark_name, 0, (char *)0, 0},
  22010. {(char *)"index", __pyx_getprop_5_yaml_4Mark_index, 0, (char *)0, 0},
  22011. {(char *)"line", __pyx_getprop_5_yaml_4Mark_line, 0, (char *)0, 0},
  22012. {(char *)"column", __pyx_getprop_5_yaml_4Mark_column, 0, (char *)0, 0},
  22013. {(char *)"buffer", __pyx_getprop_5_yaml_4Mark_buffer, 0, (char *)0, 0},
  22014. {(char *)"pointer", __pyx_getprop_5_yaml_4Mark_pointer, 0, (char *)0, 0},
  22015. {0, 0, 0, 0, 0}
  22016. };
  22017. static PyTypeObject __pyx_type_5_yaml_Mark = {
  22018. PyVarObject_HEAD_INIT(0, 0)
  22019. "_yaml.Mark", /*tp_name*/
  22020. sizeof(struct __pyx_obj_5_yaml_Mark), /*tp_basicsize*/
  22021. 0, /*tp_itemsize*/
  22022. __pyx_tp_dealloc_5_yaml_Mark, /*tp_dealloc*/
  22023. #if PY_VERSION_HEX < 0x030800b4
  22024. 0, /*tp_print*/
  22025. #endif
  22026. #if PY_VERSION_HEX >= 0x030800b4
  22027. 0, /*tp_vectorcall_offset*/
  22028. #endif
  22029. 0, /*tp_getattr*/
  22030. 0, /*tp_setattr*/
  22031. #if PY_MAJOR_VERSION < 3
  22032. 0, /*tp_compare*/
  22033. #endif
  22034. #if PY_MAJOR_VERSION >= 3
  22035. 0, /*tp_as_async*/
  22036. #endif
  22037. 0, /*tp_repr*/
  22038. 0, /*tp_as_number*/
  22039. 0, /*tp_as_sequence*/
  22040. 0, /*tp_as_mapping*/
  22041. 0, /*tp_hash*/
  22042. 0, /*tp_call*/
  22043. __pyx_pw_5_yaml_4Mark_5__str__, /*tp_str*/
  22044. 0, /*tp_getattro*/
  22045. 0, /*tp_setattro*/
  22046. 0, /*tp_as_buffer*/
  22047. Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  22048. 0, /*tp_doc*/
  22049. __pyx_tp_traverse_5_yaml_Mark, /*tp_traverse*/
  22050. __pyx_tp_clear_5_yaml_Mark, /*tp_clear*/
  22051. 0, /*tp_richcompare*/
  22052. 0, /*tp_weaklistoffset*/
  22053. 0, /*tp_iter*/
  22054. 0, /*tp_iternext*/
  22055. __pyx_methods_5_yaml_Mark, /*tp_methods*/
  22056. 0, /*tp_members*/
  22057. __pyx_getsets_5_yaml_Mark, /*tp_getset*/
  22058. 0, /*tp_base*/
  22059. 0, /*tp_dict*/
  22060. 0, /*tp_descr_get*/
  22061. 0, /*tp_descr_set*/
  22062. 0, /*tp_dictoffset*/
  22063. __pyx_pw_5_yaml_4Mark_1__init__, /*tp_init*/
  22064. 0, /*tp_alloc*/
  22065. __pyx_tp_new_5_yaml_Mark, /*tp_new*/
  22066. 0, /*tp_free*/
  22067. 0, /*tp_is_gc*/
  22068. 0, /*tp_bases*/
  22069. 0, /*tp_mro*/
  22070. 0, /*tp_cache*/
  22071. 0, /*tp_subclasses*/
  22072. 0, /*tp_weaklist*/
  22073. 0, /*tp_del*/
  22074. 0, /*tp_version_tag*/
  22075. #if PY_VERSION_HEX >= 0x030400a1
  22076. 0, /*tp_finalize*/
  22077. #endif
  22078. #if PY_VERSION_HEX >= 0x030800b1
  22079. 0, /*tp_vectorcall*/
  22080. #endif
  22081. #if PY_VERSION_HEX >= 0x030800b4 && PY_VERSION_HEX < 0x03090000
  22082. 0, /*tp_print*/
  22083. #endif
  22084. };
  22085. static struct __pyx_vtabstruct_5_yaml_CParser __pyx_vtable_5_yaml_CParser;
  22086. static PyObject *__pyx_tp_new_5_yaml_CParser(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) {
  22087. struct __pyx_obj_5_yaml_CParser *p;
  22088. PyObject *o;
  22089. if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) {
  22090. o = (*t->tp_alloc)(t, 0);
  22091. } else {
  22092. o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
  22093. }
  22094. if (unlikely(!o)) return 0;
  22095. p = ((struct __pyx_obj_5_yaml_CParser *)o);
  22096. p->__pyx_vtab = __pyx_vtabptr_5_yaml_CParser;
  22097. p->stream = Py_None; Py_INCREF(Py_None);
  22098. p->stream_name = Py_None; Py_INCREF(Py_None);
  22099. p->current_token = Py_None; Py_INCREF(Py_None);
  22100. p->current_event = Py_None; Py_INCREF(Py_None);
  22101. p->anchors = Py_None; Py_INCREF(Py_None);
  22102. p->stream_cache = Py_None; Py_INCREF(Py_None);
  22103. return o;
  22104. }
  22105. static void __pyx_tp_dealloc_5_yaml_CParser(PyObject *o) {
  22106. struct __pyx_obj_5_yaml_CParser *p = (struct __pyx_obj_5_yaml_CParser *)o;
  22107. #if CYTHON_USE_TP_FINALIZE
  22108. if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) {
  22109. if (PyObject_CallFinalizerFromDealloc(o)) return;
  22110. }
  22111. #endif
  22112. PyObject_GC_UnTrack(o);
  22113. {
  22114. PyObject *etype, *eval, *etb;
  22115. PyErr_Fetch(&etype, &eval, &etb);
  22116. ++Py_REFCNT(o);
  22117. __pyx_pw_5_yaml_7CParser_3__dealloc__(o);
  22118. --Py_REFCNT(o);
  22119. PyErr_Restore(etype, eval, etb);
  22120. }
  22121. Py_CLEAR(p->stream);
  22122. Py_CLEAR(p->stream_name);
  22123. Py_CLEAR(p->current_token);
  22124. Py_CLEAR(p->current_event);
  22125. Py_CLEAR(p->anchors);
  22126. Py_CLEAR(p->stream_cache);
  22127. (*Py_TYPE(o)->tp_free)(o);
  22128. }
  22129. static int __pyx_tp_traverse_5_yaml_CParser(PyObject *o, visitproc v, void *a) {
  22130. int e;
  22131. struct __pyx_obj_5_yaml_CParser *p = (struct __pyx_obj_5_yaml_CParser *)o;
  22132. if (p->stream) {
  22133. e = (*v)(p->stream, a); if (e) return e;
  22134. }
  22135. if (p->stream_name) {
  22136. e = (*v)(p->stream_name, a); if (e) return e;
  22137. }
  22138. if (p->current_token) {
  22139. e = (*v)(p->current_token, a); if (e) return e;
  22140. }
  22141. if (p->current_event) {
  22142. e = (*v)(p->current_event, a); if (e) return e;
  22143. }
  22144. if (p->anchors) {
  22145. e = (*v)(p->anchors, a); if (e) return e;
  22146. }
  22147. if (p->stream_cache) {
  22148. e = (*v)(p->stream_cache, a); if (e) return e;
  22149. }
  22150. return 0;
  22151. }
  22152. static int __pyx_tp_clear_5_yaml_CParser(PyObject *o) {
  22153. PyObject* tmp;
  22154. struct __pyx_obj_5_yaml_CParser *p = (struct __pyx_obj_5_yaml_CParser *)o;
  22155. tmp = ((PyObject*)p->stream);
  22156. p->stream = Py_None; Py_INCREF(Py_None);
  22157. Py_XDECREF(tmp);
  22158. tmp = ((PyObject*)p->stream_name);
  22159. p->stream_name = Py_None; Py_INCREF(Py_None);
  22160. Py_XDECREF(tmp);
  22161. tmp = ((PyObject*)p->current_token);
  22162. p->current_token = Py_None; Py_INCREF(Py_None);
  22163. Py_XDECREF(tmp);
  22164. tmp = ((PyObject*)p->current_event);
  22165. p->current_event = Py_None; Py_INCREF(Py_None);
  22166. Py_XDECREF(tmp);
  22167. tmp = ((PyObject*)p->anchors);
  22168. p->anchors = Py_None; Py_INCREF(Py_None);
  22169. Py_XDECREF(tmp);
  22170. tmp = ((PyObject*)p->stream_cache);
  22171. p->stream_cache = Py_None; Py_INCREF(Py_None);
  22172. Py_XDECREF(tmp);
  22173. return 0;
  22174. }
  22175. static PyMethodDef __pyx_methods_5_yaml_CParser[] = {
  22176. {"dispose", (PyCFunction)__pyx_pw_5_yaml_7CParser_5dispose, METH_NOARGS, 0},
  22177. {"raw_scan", (PyCFunction)__pyx_pw_5_yaml_7CParser_7raw_scan, METH_NOARGS, 0},
  22178. {"get_token", (PyCFunction)__pyx_pw_5_yaml_7CParser_9get_token, METH_NOARGS, 0},
  22179. {"peek_token", (PyCFunction)__pyx_pw_5_yaml_7CParser_11peek_token, METH_NOARGS, 0},
  22180. {"check_token", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_5_yaml_7CParser_13check_token, METH_VARARGS|METH_KEYWORDS, 0},
  22181. {"raw_parse", (PyCFunction)__pyx_pw_5_yaml_7CParser_15raw_parse, METH_NOARGS, 0},
  22182. {"get_event", (PyCFunction)__pyx_pw_5_yaml_7CParser_17get_event, METH_NOARGS, 0},
  22183. {"peek_event", (PyCFunction)__pyx_pw_5_yaml_7CParser_19peek_event, METH_NOARGS, 0},
  22184. {"check_event", (PyCFunction)(void*)(PyCFunctionWithKeywords)__pyx_pw_5_yaml_7CParser_21check_event, METH_VARARGS|METH_KEYWORDS, 0},
  22185. {"check_node", (PyCFunction)__pyx_pw_5_yaml_7CParser_23check_node, METH_NOARGS, 0},
  22186. {"get_node", (PyCFunction)__pyx_pw_5_yaml_7CParser_25get_node, METH_NOARGS, 0},
  22187. {"get_single_node", (PyCFunction)__pyx_pw_5_yaml_7CParser_27get_single_node, METH_NOARGS, 0},
  22188. {"__reduce_cython__", (PyCFunction)__pyx_pw_5_yaml_7CParser_29__reduce_cython__, METH_NOARGS, 0},
  22189. {"__setstate_cython__", (PyCFunction)__pyx_pw_5_yaml_7CParser_31__setstate_cython__, METH_O, 0},
  22190. {0, 0, 0, 0}
  22191. };
  22192. static PyTypeObject __pyx_type_5_yaml_CParser = {
  22193. PyVarObject_HEAD_INIT(0, 0)
  22194. "_yaml.CParser", /*tp_name*/
  22195. sizeof(struct __pyx_obj_5_yaml_CParser), /*tp_basicsize*/
  22196. 0, /*tp_itemsize*/
  22197. __pyx_tp_dealloc_5_yaml_CParser, /*tp_dealloc*/
  22198. #if PY_VERSION_HEX < 0x030800b4
  22199. 0, /*tp_print*/
  22200. #endif
  22201. #if PY_VERSION_HEX >= 0x030800b4
  22202. 0, /*tp_vectorcall_offset*/
  22203. #endif
  22204. 0, /*tp_getattr*/
  22205. 0, /*tp_setattr*/
  22206. #if PY_MAJOR_VERSION < 3
  22207. 0, /*tp_compare*/
  22208. #endif
  22209. #if PY_MAJOR_VERSION >= 3
  22210. 0, /*tp_as_async*/
  22211. #endif
  22212. 0, /*tp_repr*/
  22213. 0, /*tp_as_number*/
  22214. 0, /*tp_as_sequence*/
  22215. 0, /*tp_as_mapping*/
  22216. 0, /*tp_hash*/
  22217. 0, /*tp_call*/
  22218. 0, /*tp_str*/
  22219. 0, /*tp_getattro*/
  22220. 0, /*tp_setattro*/
  22221. 0, /*tp_as_buffer*/
  22222. Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  22223. 0, /*tp_doc*/
  22224. __pyx_tp_traverse_5_yaml_CParser, /*tp_traverse*/
  22225. __pyx_tp_clear_5_yaml_CParser, /*tp_clear*/
  22226. 0, /*tp_richcompare*/
  22227. 0, /*tp_weaklistoffset*/
  22228. 0, /*tp_iter*/
  22229. 0, /*tp_iternext*/
  22230. __pyx_methods_5_yaml_CParser, /*tp_methods*/
  22231. 0, /*tp_members*/
  22232. 0, /*tp_getset*/
  22233. 0, /*tp_base*/
  22234. 0, /*tp_dict*/
  22235. 0, /*tp_descr_get*/
  22236. 0, /*tp_descr_set*/
  22237. 0, /*tp_dictoffset*/
  22238. __pyx_pw_5_yaml_7CParser_1__init__, /*tp_init*/
  22239. 0, /*tp_alloc*/
  22240. __pyx_tp_new_5_yaml_CParser, /*tp_new*/
  22241. 0, /*tp_free*/
  22242. 0, /*tp_is_gc*/
  22243. 0, /*tp_bases*/
  22244. 0, /*tp_mro*/
  22245. 0, /*tp_cache*/
  22246. 0, /*tp_subclasses*/
  22247. 0, /*tp_weaklist*/
  22248. 0, /*tp_del*/
  22249. 0, /*tp_version_tag*/
  22250. #if PY_VERSION_HEX >= 0x030400a1
  22251. 0, /*tp_finalize*/
  22252. #endif
  22253. #if PY_VERSION_HEX >= 0x030800b1
  22254. 0, /*tp_vectorcall*/
  22255. #endif
  22256. #if PY_VERSION_HEX >= 0x030800b4 && PY_VERSION_HEX < 0x03090000
  22257. 0, /*tp_print*/
  22258. #endif
  22259. };
  22260. static struct __pyx_vtabstruct_5_yaml_CEmitter __pyx_vtable_5_yaml_CEmitter;
  22261. static PyObject *__pyx_tp_new_5_yaml_CEmitter(PyTypeObject *t, CYTHON_UNUSED PyObject *a, CYTHON_UNUSED PyObject *k) {
  22262. struct __pyx_obj_5_yaml_CEmitter *p;
  22263. PyObject *o;
  22264. if (likely((t->tp_flags & Py_TPFLAGS_IS_ABSTRACT) == 0)) {
  22265. o = (*t->tp_alloc)(t, 0);
  22266. } else {
  22267. o = (PyObject *) PyBaseObject_Type.tp_new(t, __pyx_empty_tuple, 0);
  22268. }
  22269. if (unlikely(!o)) return 0;
  22270. p = ((struct __pyx_obj_5_yaml_CEmitter *)o);
  22271. p->__pyx_vtab = __pyx_vtabptr_5_yaml_CEmitter;
  22272. p->stream = Py_None; Py_INCREF(Py_None);
  22273. p->use_version = Py_None; Py_INCREF(Py_None);
  22274. p->use_tags = Py_None; Py_INCREF(Py_None);
  22275. p->serialized_nodes = Py_None; Py_INCREF(Py_None);
  22276. p->anchors = Py_None; Py_INCREF(Py_None);
  22277. p->use_encoding = Py_None; Py_INCREF(Py_None);
  22278. return o;
  22279. }
  22280. static void __pyx_tp_dealloc_5_yaml_CEmitter(PyObject *o) {
  22281. struct __pyx_obj_5_yaml_CEmitter *p = (struct __pyx_obj_5_yaml_CEmitter *)o;
  22282. #if CYTHON_USE_TP_FINALIZE
  22283. if (unlikely(PyType_HasFeature(Py_TYPE(o), Py_TPFLAGS_HAVE_FINALIZE) && Py_TYPE(o)->tp_finalize) && !_PyGC_FINALIZED(o)) {
  22284. if (PyObject_CallFinalizerFromDealloc(o)) return;
  22285. }
  22286. #endif
  22287. PyObject_GC_UnTrack(o);
  22288. {
  22289. PyObject *etype, *eval, *etb;
  22290. PyErr_Fetch(&etype, &eval, &etb);
  22291. ++Py_REFCNT(o);
  22292. __pyx_pw_5_yaml_8CEmitter_3__dealloc__(o);
  22293. --Py_REFCNT(o);
  22294. PyErr_Restore(etype, eval, etb);
  22295. }
  22296. Py_CLEAR(p->stream);
  22297. Py_CLEAR(p->use_version);
  22298. Py_CLEAR(p->use_tags);
  22299. Py_CLEAR(p->serialized_nodes);
  22300. Py_CLEAR(p->anchors);
  22301. Py_CLEAR(p->use_encoding);
  22302. (*Py_TYPE(o)->tp_free)(o);
  22303. }
  22304. static int __pyx_tp_traverse_5_yaml_CEmitter(PyObject *o, visitproc v, void *a) {
  22305. int e;
  22306. struct __pyx_obj_5_yaml_CEmitter *p = (struct __pyx_obj_5_yaml_CEmitter *)o;
  22307. if (p->stream) {
  22308. e = (*v)(p->stream, a); if (e) return e;
  22309. }
  22310. if (p->use_version) {
  22311. e = (*v)(p->use_version, a); if (e) return e;
  22312. }
  22313. if (p->use_tags) {
  22314. e = (*v)(p->use_tags, a); if (e) return e;
  22315. }
  22316. if (p->serialized_nodes) {
  22317. e = (*v)(p->serialized_nodes, a); if (e) return e;
  22318. }
  22319. if (p->anchors) {
  22320. e = (*v)(p->anchors, a); if (e) return e;
  22321. }
  22322. if (p->use_encoding) {
  22323. e = (*v)(p->use_encoding, a); if (e) return e;
  22324. }
  22325. return 0;
  22326. }
  22327. static int __pyx_tp_clear_5_yaml_CEmitter(PyObject *o) {
  22328. PyObject* tmp;
  22329. struct __pyx_obj_5_yaml_CEmitter *p = (struct __pyx_obj_5_yaml_CEmitter *)o;
  22330. tmp = ((PyObject*)p->stream);
  22331. p->stream = Py_None; Py_INCREF(Py_None);
  22332. Py_XDECREF(tmp);
  22333. tmp = ((PyObject*)p->use_version);
  22334. p->use_version = Py_None; Py_INCREF(Py_None);
  22335. Py_XDECREF(tmp);
  22336. tmp = ((PyObject*)p->use_tags);
  22337. p->use_tags = Py_None; Py_INCREF(Py_None);
  22338. Py_XDECREF(tmp);
  22339. tmp = ((PyObject*)p->serialized_nodes);
  22340. p->serialized_nodes = Py_None; Py_INCREF(Py_None);
  22341. Py_XDECREF(tmp);
  22342. tmp = ((PyObject*)p->anchors);
  22343. p->anchors = Py_None; Py_INCREF(Py_None);
  22344. Py_XDECREF(tmp);
  22345. tmp = ((PyObject*)p->use_encoding);
  22346. p->use_encoding = Py_None; Py_INCREF(Py_None);
  22347. Py_XDECREF(tmp);
  22348. return 0;
  22349. }
  22350. static PyMethodDef __pyx_methods_5_yaml_CEmitter[] = {
  22351. {"dispose", (PyCFunction)__pyx_pw_5_yaml_8CEmitter_5dispose, METH_NOARGS, 0},
  22352. {"emit", (PyCFunction)__pyx_pw_5_yaml_8CEmitter_7emit, METH_O, 0},
  22353. {"open", (PyCFunction)__pyx_pw_5_yaml_8CEmitter_9open, METH_NOARGS, 0},
  22354. {"close", (PyCFunction)__pyx_pw_5_yaml_8CEmitter_11close, METH_NOARGS, 0},
  22355. {"serialize", (PyCFunction)__pyx_pw_5_yaml_8CEmitter_13serialize, METH_O, 0},
  22356. {"__reduce_cython__", (PyCFunction)__pyx_pw_5_yaml_8CEmitter_15__reduce_cython__, METH_NOARGS, 0},
  22357. {"__setstate_cython__", (PyCFunction)__pyx_pw_5_yaml_8CEmitter_17__setstate_cython__, METH_O, 0},
  22358. {0, 0, 0, 0}
  22359. };
  22360. static PyTypeObject __pyx_type_5_yaml_CEmitter = {
  22361. PyVarObject_HEAD_INIT(0, 0)
  22362. "_yaml.CEmitter", /*tp_name*/
  22363. sizeof(struct __pyx_obj_5_yaml_CEmitter), /*tp_basicsize*/
  22364. 0, /*tp_itemsize*/
  22365. __pyx_tp_dealloc_5_yaml_CEmitter, /*tp_dealloc*/
  22366. #if PY_VERSION_HEX < 0x030800b4
  22367. 0, /*tp_print*/
  22368. #endif
  22369. #if PY_VERSION_HEX >= 0x030800b4
  22370. 0, /*tp_vectorcall_offset*/
  22371. #endif
  22372. 0, /*tp_getattr*/
  22373. 0, /*tp_setattr*/
  22374. #if PY_MAJOR_VERSION < 3
  22375. 0, /*tp_compare*/
  22376. #endif
  22377. #if PY_MAJOR_VERSION >= 3
  22378. 0, /*tp_as_async*/
  22379. #endif
  22380. 0, /*tp_repr*/
  22381. 0, /*tp_as_number*/
  22382. 0, /*tp_as_sequence*/
  22383. 0, /*tp_as_mapping*/
  22384. 0, /*tp_hash*/
  22385. 0, /*tp_call*/
  22386. 0, /*tp_str*/
  22387. 0, /*tp_getattro*/
  22388. 0, /*tp_setattro*/
  22389. 0, /*tp_as_buffer*/
  22390. Py_TPFLAGS_DEFAULT|Py_TPFLAGS_HAVE_VERSION_TAG|Py_TPFLAGS_CHECKTYPES|Py_TPFLAGS_HAVE_NEWBUFFER|Py_TPFLAGS_BASETYPE|Py_TPFLAGS_HAVE_GC, /*tp_flags*/
  22391. 0, /*tp_doc*/
  22392. __pyx_tp_traverse_5_yaml_CEmitter, /*tp_traverse*/
  22393. __pyx_tp_clear_5_yaml_CEmitter, /*tp_clear*/
  22394. 0, /*tp_richcompare*/
  22395. 0, /*tp_weaklistoffset*/
  22396. 0, /*tp_iter*/
  22397. 0, /*tp_iternext*/
  22398. __pyx_methods_5_yaml_CEmitter, /*tp_methods*/
  22399. 0, /*tp_members*/
  22400. 0, /*tp_getset*/
  22401. 0, /*tp_base*/
  22402. 0, /*tp_dict*/
  22403. 0, /*tp_descr_get*/
  22404. 0, /*tp_descr_set*/
  22405. 0, /*tp_dictoffset*/
  22406. __pyx_pw_5_yaml_8CEmitter_1__init__, /*tp_init*/
  22407. 0, /*tp_alloc*/
  22408. __pyx_tp_new_5_yaml_CEmitter, /*tp_new*/
  22409. 0, /*tp_free*/
  22410. 0, /*tp_is_gc*/
  22411. 0, /*tp_bases*/
  22412. 0, /*tp_mro*/
  22413. 0, /*tp_cache*/
  22414. 0, /*tp_subclasses*/
  22415. 0, /*tp_weaklist*/
  22416. 0, /*tp_del*/
  22417. 0, /*tp_version_tag*/
  22418. #if PY_VERSION_HEX >= 0x030400a1
  22419. 0, /*tp_finalize*/
  22420. #endif
  22421. #if PY_VERSION_HEX >= 0x030800b1
  22422. 0, /*tp_vectorcall*/
  22423. #endif
  22424. #if PY_VERSION_HEX >= 0x030800b4 && PY_VERSION_HEX < 0x03090000
  22425. 0, /*tp_print*/
  22426. #endif
  22427. };
  22428. static PyMethodDef __pyx_methods[] = {
  22429. {0, 0, 0, 0}
  22430. };
  22431. #if PY_MAJOR_VERSION >= 3
  22432. #if CYTHON_PEP489_MULTI_PHASE_INIT
  22433. static PyObject* __pyx_pymod_create(PyObject *spec, PyModuleDef *def); /*proto*/
  22434. static int __pyx_pymod_exec__yaml(PyObject* module); /*proto*/
  22435. static PyModuleDef_Slot __pyx_moduledef_slots[] = {
  22436. {Py_mod_create, (void*)__pyx_pymod_create},
  22437. {Py_mod_exec, (void*)__pyx_pymod_exec__yaml},
  22438. {0, NULL}
  22439. };
  22440. #endif
  22441. static struct PyModuleDef __pyx_moduledef = {
  22442. PyModuleDef_HEAD_INIT,
  22443. "_yaml",
  22444. 0, /* m_doc */
  22445. #if CYTHON_PEP489_MULTI_PHASE_INIT
  22446. 0, /* m_size */
  22447. #else
  22448. -1, /* m_size */
  22449. #endif
  22450. __pyx_methods /* m_methods */,
  22451. #if CYTHON_PEP489_MULTI_PHASE_INIT
  22452. __pyx_moduledef_slots, /* m_slots */
  22453. #else
  22454. NULL, /* m_reload */
  22455. #endif
  22456. NULL, /* m_traverse */
  22457. NULL, /* m_clear */
  22458. NULL /* m_free */
  22459. };
  22460. #endif
  22461. #ifndef CYTHON_SMALL_CODE
  22462. #if defined(__clang__)
  22463. #define CYTHON_SMALL_CODE
  22464. #elif defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3))
  22465. #define CYTHON_SMALL_CODE __attribute__((cold))
  22466. #else
  22467. #define CYTHON_SMALL_CODE
  22468. #endif
  22469. #endif
  22470. static __Pyx_StringTabEntry __pyx_string_tab[] = {
  22471. {&__pyx_n_s_AliasEvent, __pyx_k_AliasEvent, sizeof(__pyx_k_AliasEvent), 0, 0, 1, 1},
  22472. {&__pyx_n_s_AliasToken, __pyx_k_AliasToken, sizeof(__pyx_k_AliasToken), 0, 0, 1, 1},
  22473. {&__pyx_n_s_AnchorToken, __pyx_k_AnchorToken, sizeof(__pyx_k_AnchorToken), 0, 0, 1, 1},
  22474. {&__pyx_n_s_AttributeError, __pyx_k_AttributeError, sizeof(__pyx_k_AttributeError), 0, 0, 1, 1},
  22475. {&__pyx_n_s_BlockEndToken, __pyx_k_BlockEndToken, sizeof(__pyx_k_BlockEndToken), 0, 0, 1, 1},
  22476. {&__pyx_n_s_BlockEntryToken, __pyx_k_BlockEntryToken, sizeof(__pyx_k_BlockEntryToken), 0, 0, 1, 1},
  22477. {&__pyx_n_s_BlockMappingStartToken, __pyx_k_BlockMappingStartToken, sizeof(__pyx_k_BlockMappingStartToken), 0, 0, 1, 1},
  22478. {&__pyx_n_s_BlockSequenceStartToken, __pyx_k_BlockSequenceStartToken, sizeof(__pyx_k_BlockSequenceStartToken), 0, 0, 1, 1},
  22479. {&__pyx_n_s_CEmitter, __pyx_k_CEmitter, sizeof(__pyx_k_CEmitter), 0, 0, 1, 1},
  22480. {&__pyx_n_s_CParser, __pyx_k_CParser, sizeof(__pyx_k_CParser), 0, 0, 1, 1},
  22481. {&__pyx_n_s_ComposerError, __pyx_k_ComposerError, sizeof(__pyx_k_ComposerError), 0, 0, 1, 1},
  22482. {&__pyx_n_s_ConstructorError, __pyx_k_ConstructorError, sizeof(__pyx_k_ConstructorError), 0, 0, 1, 1},
  22483. {&__pyx_n_s_DirectiveToken, __pyx_k_DirectiveToken, sizeof(__pyx_k_DirectiveToken), 0, 0, 1, 1},
  22484. {&__pyx_n_s_DocumentEndEvent, __pyx_k_DocumentEndEvent, sizeof(__pyx_k_DocumentEndEvent), 0, 0, 1, 1},
  22485. {&__pyx_n_s_DocumentEndToken, __pyx_k_DocumentEndToken, sizeof(__pyx_k_DocumentEndToken), 0, 0, 1, 1},
  22486. {&__pyx_n_s_DocumentStartEvent, __pyx_k_DocumentStartEvent, sizeof(__pyx_k_DocumentStartEvent), 0, 0, 1, 1},
  22487. {&__pyx_n_s_DocumentStartToken, __pyx_k_DocumentStartToken, sizeof(__pyx_k_DocumentStartToken), 0, 0, 1, 1},
  22488. {&__pyx_n_s_EmitterError, __pyx_k_EmitterError, sizeof(__pyx_k_EmitterError), 0, 0, 1, 1},
  22489. {&__pyx_n_s_FlowEntryToken, __pyx_k_FlowEntryToken, sizeof(__pyx_k_FlowEntryToken), 0, 0, 1, 1},
  22490. {&__pyx_n_s_FlowMappingEndToken, __pyx_k_FlowMappingEndToken, sizeof(__pyx_k_FlowMappingEndToken), 0, 0, 1, 1},
  22491. {&__pyx_n_s_FlowMappingStartToken, __pyx_k_FlowMappingStartToken, sizeof(__pyx_k_FlowMappingStartToken), 0, 0, 1, 1},
  22492. {&__pyx_n_s_FlowSequenceEndToken, __pyx_k_FlowSequenceEndToken, sizeof(__pyx_k_FlowSequenceEndToken), 0, 0, 1, 1},
  22493. {&__pyx_n_s_FlowSequenceStartToken, __pyx_k_FlowSequenceStartToken, sizeof(__pyx_k_FlowSequenceStartToken), 0, 0, 1, 1},
  22494. {&__pyx_kp_s_Incompatible_checksums_s_vs_0x3f, __pyx_k_Incompatible_checksums_s_vs_0x3f, sizeof(__pyx_k_Incompatible_checksums_s_vs_0x3f), 0, 0, 1, 0},
  22495. {&__pyx_n_s_KeyToken, __pyx_k_KeyToken, sizeof(__pyx_k_KeyToken), 0, 0, 1, 1},
  22496. {&__pyx_n_s_MappingEndEvent, __pyx_k_MappingEndEvent, sizeof(__pyx_k_MappingEndEvent), 0, 0, 1, 1},
  22497. {&__pyx_n_s_MappingNode, __pyx_k_MappingNode, sizeof(__pyx_k_MappingNode), 0, 0, 1, 1},
  22498. {&__pyx_n_s_MappingStartEvent, __pyx_k_MappingStartEvent, sizeof(__pyx_k_MappingStartEvent), 0, 0, 1, 1},
  22499. {&__pyx_n_s_Mark, __pyx_k_Mark, sizeof(__pyx_k_Mark), 0, 0, 1, 1},
  22500. {&__pyx_n_s_MemoryError, __pyx_k_MemoryError, sizeof(__pyx_k_MemoryError), 0, 0, 1, 1},
  22501. {&__pyx_n_s_ParserError, __pyx_k_ParserError, sizeof(__pyx_k_ParserError), 0, 0, 1, 1},
  22502. {&__pyx_n_s_PickleError, __pyx_k_PickleError, sizeof(__pyx_k_PickleError), 0, 0, 1, 1},
  22503. {&__pyx_kp_s_Pickling_of_struct_members_such, __pyx_k_Pickling_of_struct_members_such, sizeof(__pyx_k_Pickling_of_struct_members_such), 0, 0, 1, 0},
  22504. {&__pyx_n_s_ReaderError, __pyx_k_ReaderError, sizeof(__pyx_k_ReaderError), 0, 0, 1, 1},
  22505. {&__pyx_n_s_RepresenterError, __pyx_k_RepresenterError, sizeof(__pyx_k_RepresenterError), 0, 0, 1, 1},
  22506. {&__pyx_n_s_ScalarEvent, __pyx_k_ScalarEvent, sizeof(__pyx_k_ScalarEvent), 0, 0, 1, 1},
  22507. {&__pyx_n_s_ScalarNode, __pyx_k_ScalarNode, sizeof(__pyx_k_ScalarNode), 0, 0, 1, 1},
  22508. {&__pyx_n_s_ScalarToken, __pyx_k_ScalarToken, sizeof(__pyx_k_ScalarToken), 0, 0, 1, 1},
  22509. {&__pyx_n_s_ScannerError, __pyx_k_ScannerError, sizeof(__pyx_k_ScannerError), 0, 0, 1, 1},
  22510. {&__pyx_n_s_SequenceEndEvent, __pyx_k_SequenceEndEvent, sizeof(__pyx_k_SequenceEndEvent), 0, 0, 1, 1},
  22511. {&__pyx_n_s_SequenceNode, __pyx_k_SequenceNode, sizeof(__pyx_k_SequenceNode), 0, 0, 1, 1},
  22512. {&__pyx_n_s_SequenceStartEvent, __pyx_k_SequenceStartEvent, sizeof(__pyx_k_SequenceStartEvent), 0, 0, 1, 1},
  22513. {&__pyx_n_s_SerializerError, __pyx_k_SerializerError, sizeof(__pyx_k_SerializerError), 0, 0, 1, 1},
  22514. {&__pyx_n_s_StreamEndEvent, __pyx_k_StreamEndEvent, sizeof(__pyx_k_StreamEndEvent), 0, 0, 1, 1},
  22515. {&__pyx_n_s_StreamEndToken, __pyx_k_StreamEndToken, sizeof(__pyx_k_StreamEndToken), 0, 0, 1, 1},
  22516. {&__pyx_n_s_StreamStartEvent, __pyx_k_StreamStartEvent, sizeof(__pyx_k_StreamStartEvent), 0, 0, 1, 1},
  22517. {&__pyx_n_s_StreamStartToken, __pyx_k_StreamStartToken, sizeof(__pyx_k_StreamStartToken), 0, 0, 1, 1},
  22518. {&__pyx_n_u_TAG, __pyx_k_TAG, sizeof(__pyx_k_TAG), 0, 1, 0, 1},
  22519. {&__pyx_n_s_TagToken, __pyx_k_TagToken, sizeof(__pyx_k_TagToken), 0, 0, 1, 1},
  22520. {&__pyx_n_s_TypeError, __pyx_k_TypeError, sizeof(__pyx_k_TypeError), 0, 0, 1, 1},
  22521. {&__pyx_n_s_ValueError, __pyx_k_ValueError, sizeof(__pyx_k_ValueError), 0, 0, 1, 1},
  22522. {&__pyx_n_s_ValueToken, __pyx_k_ValueToken, sizeof(__pyx_k_ValueToken), 0, 0, 1, 1},
  22523. {&__pyx_n_u_YAML, __pyx_k_YAML, sizeof(__pyx_k_YAML), 0, 1, 0, 1},
  22524. {&__pyx_n_s_YAMLError, __pyx_k_YAMLError, sizeof(__pyx_k_YAMLError), 0, 0, 1, 1},
  22525. {&__pyx_kp_s__10, __pyx_k__10, sizeof(__pyx_k__10), 0, 0, 1, 0},
  22526. {&__pyx_kp_u__10, __pyx_k__10, sizeof(__pyx_k__10), 0, 1, 0, 0},
  22527. {&__pyx_kp_s__19, __pyx_k__19, sizeof(__pyx_k__19), 0, 0, 1, 0},
  22528. {&__pyx_kp_s__20, __pyx_k__20, sizeof(__pyx_k__20), 0, 0, 1, 0},
  22529. {&__pyx_kp_s__21, __pyx_k__21, sizeof(__pyx_k__21), 0, 0, 1, 0},
  22530. {&__pyx_kp_s__3, __pyx_k__3, sizeof(__pyx_k__3), 0, 0, 1, 0},
  22531. {&__pyx_kp_u__3, __pyx_k__3, sizeof(__pyx_k__3), 0, 1, 0, 0},
  22532. {&__pyx_kp_u__6, __pyx_k__6, sizeof(__pyx_k__6), 0, 1, 0, 0},
  22533. {&__pyx_kp_s__7, __pyx_k__7, sizeof(__pyx_k__7), 0, 0, 1, 0},
  22534. {&__pyx_kp_u__7, __pyx_k__7, sizeof(__pyx_k__7), 0, 1, 0, 0},
  22535. {&__pyx_kp_s__8, __pyx_k__8, sizeof(__pyx_k__8), 0, 0, 1, 0},
  22536. {&__pyx_kp_u__8, __pyx_k__8, sizeof(__pyx_k__8), 0, 1, 0, 0},
  22537. {&__pyx_kp_s__9, __pyx_k__9, sizeof(__pyx_k__9), 0, 0, 1, 0},
  22538. {&__pyx_kp_u__9, __pyx_k__9, sizeof(__pyx_k__9), 0, 1, 0, 0},
  22539. {&__pyx_kp_s_a_string_or_stream_input_is_requ, __pyx_k_a_string_or_stream_input_is_requ, sizeof(__pyx_k_a_string_or_stream_input_is_requ), 0, 0, 1, 0},
  22540. {&__pyx_kp_u_a_string_or_stream_input_is_requ, __pyx_k_a_string_or_stream_input_is_requ, sizeof(__pyx_k_a_string_or_stream_input_is_requ), 0, 1, 0, 0},
  22541. {&__pyx_kp_s_a_string_value_is_expected, __pyx_k_a_string_value_is_expected, sizeof(__pyx_k_a_string_value_is_expected), 0, 0, 1, 0},
  22542. {&__pyx_kp_u_a_string_value_is_expected, __pyx_k_a_string_value_is_expected, sizeof(__pyx_k_a_string_value_is_expected), 0, 1, 0, 0},
  22543. {&__pyx_n_s_allow_unicode, __pyx_k_allow_unicode, sizeof(__pyx_k_allow_unicode), 0, 0, 1, 1},
  22544. {&__pyx_n_s_anchor, __pyx_k_anchor, sizeof(__pyx_k_anchor), 0, 0, 1, 1},
  22545. {&__pyx_kp_s_anchor_must_be_a_string, __pyx_k_anchor_must_be_a_string, sizeof(__pyx_k_anchor_must_be_a_string), 0, 0, 1, 0},
  22546. {&__pyx_kp_u_anchor_must_be_a_string, __pyx_k_anchor_must_be_a_string, sizeof(__pyx_k_anchor_must_be_a_string), 0, 1, 0, 0},
  22547. {&__pyx_n_s_ascend_resolver, __pyx_k_ascend_resolver, sizeof(__pyx_k_ascend_resolver), 0, 0, 1, 1},
  22548. {&__pyx_n_s_buffer, __pyx_k_buffer, sizeof(__pyx_k_buffer), 0, 0, 1, 1},
  22549. {&__pyx_kp_s_but_found_another_document, __pyx_k_but_found_another_document, sizeof(__pyx_k_but_found_another_document), 0, 0, 1, 0},
  22550. {&__pyx_kp_u_but_found_another_document, __pyx_k_but_found_another_document, sizeof(__pyx_k_but_found_another_document), 0, 1, 0, 0},
  22551. {&__pyx_kp_s_byte_string, __pyx_k_byte_string, sizeof(__pyx_k_byte_string), 0, 0, 1, 0},
  22552. {&__pyx_kp_u_byte_string, __pyx_k_byte_string, sizeof(__pyx_k_byte_string), 0, 1, 0, 0},
  22553. {&__pyx_n_s_canonical, __pyx_k_canonical, sizeof(__pyx_k_canonical), 0, 0, 1, 1},
  22554. {&__pyx_n_s_class, __pyx_k_class, sizeof(__pyx_k_class), 0, 0, 1, 1},
  22555. {&__pyx_n_s_cline_in_traceback, __pyx_k_cline_in_traceback, sizeof(__pyx_k_cline_in_traceback), 0, 0, 1, 1},
  22556. {&__pyx_n_s_column, __pyx_k_column, sizeof(__pyx_k_column), 0, 0, 1, 1},
  22557. {&__pyx_n_s_composer, __pyx_k_composer, sizeof(__pyx_k_composer), 0, 0, 1, 1},
  22558. {&__pyx_n_s_constructor, __pyx_k_constructor, sizeof(__pyx_k_constructor), 0, 0, 1, 1},
  22559. {&__pyx_n_s_descend_resolver, __pyx_k_descend_resolver, sizeof(__pyx_k_descend_resolver), 0, 0, 1, 1},
  22560. {&__pyx_n_s_dict, __pyx_k_dict, sizeof(__pyx_k_dict), 0, 0, 1, 1},
  22561. {&__pyx_n_s_emitter, __pyx_k_emitter, sizeof(__pyx_k_emitter), 0, 0, 1, 1},
  22562. {&__pyx_n_s_encoding, __pyx_k_encoding, sizeof(__pyx_k_encoding), 0, 0, 1, 1},
  22563. {&__pyx_n_u_encoding, __pyx_k_encoding, sizeof(__pyx_k_encoding), 0, 1, 0, 1},
  22564. {&__pyx_n_s_end_mark, __pyx_k_end_mark, sizeof(__pyx_k_end_mark), 0, 0, 1, 1},
  22565. {&__pyx_n_s_error, __pyx_k_error, sizeof(__pyx_k_error), 0, 0, 1, 1},
  22566. {&__pyx_n_s_events, __pyx_k_events, sizeof(__pyx_k_events), 0, 0, 1, 1},
  22567. {&__pyx_kp_s_expected_a_single_document_in_th, __pyx_k_expected_a_single_document_in_th, sizeof(__pyx_k_expected_a_single_document_in_th), 0, 0, 1, 0},
  22568. {&__pyx_kp_u_expected_a_single_document_in_th, __pyx_k_expected_a_single_document_in_th, sizeof(__pyx_k_expected_a_single_document_in_th), 0, 1, 0, 0},
  22569. {&__pyx_n_s_explicit, __pyx_k_explicit, sizeof(__pyx_k_explicit), 0, 0, 1, 1},
  22570. {&__pyx_n_s_explicit_end, __pyx_k_explicit_end, sizeof(__pyx_k_explicit_end), 0, 0, 1, 1},
  22571. {&__pyx_n_s_explicit_start, __pyx_k_explicit_start, sizeof(__pyx_k_explicit_start), 0, 0, 1, 1},
  22572. {&__pyx_kp_s_ext__yaml_pyx, __pyx_k_ext__yaml_pyx, sizeof(__pyx_k_ext__yaml_pyx), 0, 0, 1, 0},
  22573. {&__pyx_kp_s_file, __pyx_k_file, sizeof(__pyx_k_file), 0, 0, 1, 0},
  22574. {&__pyx_kp_u_file, __pyx_k_file, sizeof(__pyx_k_file), 0, 1, 0, 0},
  22575. {&__pyx_n_s_flow_style, __pyx_k_flow_style, sizeof(__pyx_k_flow_style), 0, 0, 1, 1},
  22576. {&__pyx_kp_s_found_duplicate_anchor_first_occ, __pyx_k_found_duplicate_anchor_first_occ, sizeof(__pyx_k_found_duplicate_anchor_first_occ), 0, 0, 1, 0},
  22577. {&__pyx_kp_u_found_duplicate_anchor_first_occ, __pyx_k_found_duplicate_anchor_first_occ, sizeof(__pyx_k_found_duplicate_anchor_first_occ), 0, 1, 0, 0},
  22578. {&__pyx_kp_s_found_undefined_alias, __pyx_k_found_undefined_alias, sizeof(__pyx_k_found_undefined_alias), 0, 0, 1, 0},
  22579. {&__pyx_kp_u_found_undefined_alias, __pyx_k_found_undefined_alias, sizeof(__pyx_k_found_undefined_alias), 0, 1, 0, 0},
  22580. {&__pyx_n_s_get_version, __pyx_k_get_version, sizeof(__pyx_k_get_version), 0, 0, 1, 1},
  22581. {&__pyx_n_s_get_version_string, __pyx_k_get_version_string, sizeof(__pyx_k_get_version_string), 0, 0, 1, 1},
  22582. {&__pyx_n_s_getstate, __pyx_k_getstate, sizeof(__pyx_k_getstate), 0, 0, 1, 1},
  22583. {&__pyx_kp_u_id_03d, __pyx_k_id_03d, sizeof(__pyx_k_id_03d), 0, 1, 0, 0},
  22584. {&__pyx_n_s_implicit, __pyx_k_implicit, sizeof(__pyx_k_implicit), 0, 0, 1, 1},
  22585. {&__pyx_n_s_import, __pyx_k_import, sizeof(__pyx_k_import), 0, 0, 1, 1},
  22586. {&__pyx_kp_s_in_s_line_d_column_d, __pyx_k_in_s_line_d_column_d, sizeof(__pyx_k_in_s_line_d_column_d), 0, 0, 1, 0},
  22587. {&__pyx_n_s_indent, __pyx_k_indent, sizeof(__pyx_k_indent), 0, 0, 1, 1},
  22588. {&__pyx_n_s_index, __pyx_k_index, sizeof(__pyx_k_index), 0, 0, 1, 1},
  22589. {&__pyx_kp_s_invalid_event_s, __pyx_k_invalid_event_s, sizeof(__pyx_k_invalid_event_s), 0, 0, 1, 0},
  22590. {&__pyx_kp_u_invalid_event_s, __pyx_k_invalid_event_s, sizeof(__pyx_k_invalid_event_s), 0, 1, 0, 0},
  22591. {&__pyx_n_s_line, __pyx_k_line, sizeof(__pyx_k_line), 0, 0, 1, 1},
  22592. {&__pyx_n_s_line_break, __pyx_k_line_break, sizeof(__pyx_k_line_break), 0, 0, 1, 1},
  22593. {&__pyx_n_s_main, __pyx_k_main, sizeof(__pyx_k_main), 0, 0, 1, 1},
  22594. {&__pyx_n_s_major, __pyx_k_major, sizeof(__pyx_k_major), 0, 0, 1, 1},
  22595. {&__pyx_n_s_minor, __pyx_k_minor, sizeof(__pyx_k_minor), 0, 0, 1, 1},
  22596. {&__pyx_n_s_name, __pyx_k_name, sizeof(__pyx_k_name), 0, 0, 1, 1},
  22597. {&__pyx_n_s_name_2, __pyx_k_name_2, sizeof(__pyx_k_name_2), 0, 0, 1, 1},
  22598. {&__pyx_n_s_new, __pyx_k_new, sizeof(__pyx_k_new), 0, 0, 1, 1},
  22599. {&__pyx_kp_s_no_emitter_error, __pyx_k_no_emitter_error, sizeof(__pyx_k_no_emitter_error), 0, 0, 1, 0},
  22600. {&__pyx_kp_u_no_emitter_error, __pyx_k_no_emitter_error, sizeof(__pyx_k_no_emitter_error), 0, 1, 0, 0},
  22601. {&__pyx_kp_s_no_parser_error, __pyx_k_no_parser_error, sizeof(__pyx_k_no_parser_error), 0, 0, 1, 0},
  22602. {&__pyx_kp_u_no_parser_error, __pyx_k_no_parser_error, sizeof(__pyx_k_no_parser_error), 0, 1, 0, 0},
  22603. {&__pyx_n_s_nodes, __pyx_k_nodes, sizeof(__pyx_k_nodes), 0, 0, 1, 1},
  22604. {&__pyx_n_s_parser, __pyx_k_parser, sizeof(__pyx_k_parser), 0, 0, 1, 1},
  22605. {&__pyx_n_s_patch, __pyx_k_patch, sizeof(__pyx_k_patch), 0, 0, 1, 1},
  22606. {&__pyx_n_s_pickle, __pyx_k_pickle, sizeof(__pyx_k_pickle), 0, 0, 1, 1},
  22607. {&__pyx_n_s_pointer, __pyx_k_pointer, sizeof(__pyx_k_pointer), 0, 0, 1, 1},
  22608. {&__pyx_n_s_pyx_PickleError, __pyx_k_pyx_PickleError, sizeof(__pyx_k_pyx_PickleError), 0, 0, 1, 1},
  22609. {&__pyx_n_s_pyx_checksum, __pyx_k_pyx_checksum, sizeof(__pyx_k_pyx_checksum), 0, 0, 1, 1},
  22610. {&__pyx_n_s_pyx_result, __pyx_k_pyx_result, sizeof(__pyx_k_pyx_result), 0, 0, 1, 1},
  22611. {&__pyx_n_s_pyx_state, __pyx_k_pyx_state, sizeof(__pyx_k_pyx_state), 0, 0, 1, 1},
  22612. {&__pyx_n_s_pyx_type, __pyx_k_pyx_type, sizeof(__pyx_k_pyx_type), 0, 0, 1, 1},
  22613. {&__pyx_n_s_pyx_unpickle_Mark, __pyx_k_pyx_unpickle_Mark, sizeof(__pyx_k_pyx_unpickle_Mark), 0, 0, 1, 1},
  22614. {&__pyx_n_s_pyx_vtable, __pyx_k_pyx_vtable, sizeof(__pyx_k_pyx_vtable), 0, 0, 1, 1},
  22615. {&__pyx_n_s_read, __pyx_k_read, sizeof(__pyx_k_read), 0, 0, 1, 1},
  22616. {&__pyx_n_s_reader, __pyx_k_reader, sizeof(__pyx_k_reader), 0, 0, 1, 1},
  22617. {&__pyx_n_s_reduce, __pyx_k_reduce, sizeof(__pyx_k_reduce), 0, 0, 1, 1},
  22618. {&__pyx_n_s_reduce_cython, __pyx_k_reduce_cython, sizeof(__pyx_k_reduce_cython), 0, 0, 1, 1},
  22619. {&__pyx_n_s_reduce_ex, __pyx_k_reduce_ex, sizeof(__pyx_k_reduce_ex), 0, 0, 1, 1},
  22620. {&__pyx_n_s_representer, __pyx_k_representer, sizeof(__pyx_k_representer), 0, 0, 1, 1},
  22621. {&__pyx_n_s_resolve, __pyx_k_resolve, sizeof(__pyx_k_resolve), 0, 0, 1, 1},
  22622. {&__pyx_n_s_scanner, __pyx_k_scanner, sizeof(__pyx_k_scanner), 0, 0, 1, 1},
  22623. {&__pyx_kp_s_second_occurrence, __pyx_k_second_occurrence, sizeof(__pyx_k_second_occurrence), 0, 0, 1, 0},
  22624. {&__pyx_kp_u_second_occurrence, __pyx_k_second_occurrence, sizeof(__pyx_k_second_occurrence), 0, 1, 0, 0},
  22625. {&__pyx_kp_s_self_parsed_event_cannot_be_conv, __pyx_k_self_parsed_event_cannot_be_conv, sizeof(__pyx_k_self_parsed_event_cannot_be_conv), 0, 0, 1, 0},
  22626. {&__pyx_n_s_serializer, __pyx_k_serializer, sizeof(__pyx_k_serializer), 0, 0, 1, 1},
  22627. {&__pyx_kp_s_serializer_is_already_opened, __pyx_k_serializer_is_already_opened, sizeof(__pyx_k_serializer_is_already_opened), 0, 0, 1, 0},
  22628. {&__pyx_kp_u_serializer_is_already_opened, __pyx_k_serializer_is_already_opened, sizeof(__pyx_k_serializer_is_already_opened), 0, 1, 0, 0},
  22629. {&__pyx_kp_s_serializer_is_closed, __pyx_k_serializer_is_closed, sizeof(__pyx_k_serializer_is_closed), 0, 0, 1, 0},
  22630. {&__pyx_kp_u_serializer_is_closed, __pyx_k_serializer_is_closed, sizeof(__pyx_k_serializer_is_closed), 0, 1, 0, 0},
  22631. {&__pyx_kp_s_serializer_is_not_opened, __pyx_k_serializer_is_not_opened, sizeof(__pyx_k_serializer_is_not_opened), 0, 0, 1, 0},
  22632. {&__pyx_kp_u_serializer_is_not_opened, __pyx_k_serializer_is_not_opened, sizeof(__pyx_k_serializer_is_not_opened), 0, 1, 0, 0},
  22633. {&__pyx_n_s_setstate, __pyx_k_setstate, sizeof(__pyx_k_setstate), 0, 0, 1, 1},
  22634. {&__pyx_n_s_setstate_cython, __pyx_k_setstate_cython, sizeof(__pyx_k_setstate_cython), 0, 0, 1, 1},
  22635. {&__pyx_n_s_start_mark, __pyx_k_start_mark, sizeof(__pyx_k_start_mark), 0, 0, 1, 1},
  22636. {&__pyx_n_s_stream, __pyx_k_stream, sizeof(__pyx_k_stream), 0, 0, 1, 1},
  22637. {&__pyx_kp_s_stringsource, __pyx_k_stringsource, sizeof(__pyx_k_stringsource), 0, 0, 1, 0},
  22638. {&__pyx_n_s_style, __pyx_k_style, sizeof(__pyx_k_style), 0, 0, 1, 1},
  22639. {&__pyx_n_s_tag, __pyx_k_tag, sizeof(__pyx_k_tag), 0, 0, 1, 1},
  22640. {&__pyx_kp_s_tag_handle_must_be_a_string, __pyx_k_tag_handle_must_be_a_string, sizeof(__pyx_k_tag_handle_must_be_a_string), 0, 0, 1, 0},
  22641. {&__pyx_kp_u_tag_handle_must_be_a_string, __pyx_k_tag_handle_must_be_a_string, sizeof(__pyx_k_tag_handle_must_be_a_string), 0, 1, 0, 0},
  22642. {&__pyx_kp_s_tag_must_be_a_string, __pyx_k_tag_must_be_a_string, sizeof(__pyx_k_tag_must_be_a_string), 0, 0, 1, 0},
  22643. {&__pyx_kp_u_tag_must_be_a_string, __pyx_k_tag_must_be_a_string, sizeof(__pyx_k_tag_must_be_a_string), 0, 1, 0, 0},
  22644. {&__pyx_kp_s_tag_prefix_must_be_a_string, __pyx_k_tag_prefix_must_be_a_string, sizeof(__pyx_k_tag_prefix_must_be_a_string), 0, 0, 1, 0},
  22645. {&__pyx_kp_u_tag_prefix_must_be_a_string, __pyx_k_tag_prefix_must_be_a_string, sizeof(__pyx_k_tag_prefix_must_be_a_string), 0, 1, 0, 0},
  22646. {&__pyx_n_s_tags, __pyx_k_tags, sizeof(__pyx_k_tags), 0, 0, 1, 1},
  22647. {&__pyx_n_s_test, __pyx_k_test, sizeof(__pyx_k_test), 0, 0, 1, 1},
  22648. {&__pyx_n_s_tokens, __pyx_k_tokens, sizeof(__pyx_k_tokens), 0, 0, 1, 1},
  22649. {&__pyx_kp_s_too_many_tags, __pyx_k_too_many_tags, sizeof(__pyx_k_too_many_tags), 0, 0, 1, 0},
  22650. {&__pyx_kp_u_too_many_tags, __pyx_k_too_many_tags, sizeof(__pyx_k_too_many_tags), 0, 1, 0, 0},
  22651. {&__pyx_kp_s_unicode_string, __pyx_k_unicode_string, sizeof(__pyx_k_unicode_string), 0, 0, 1, 0},
  22652. {&__pyx_kp_u_unicode_string, __pyx_k_unicode_string, sizeof(__pyx_k_unicode_string), 0, 1, 0, 0},
  22653. {&__pyx_kp_s_unknown_event_type, __pyx_k_unknown_event_type, sizeof(__pyx_k_unknown_event_type), 0, 0, 1, 0},
  22654. {&__pyx_kp_u_unknown_event_type, __pyx_k_unknown_event_type, sizeof(__pyx_k_unknown_event_type), 0, 1, 0, 0},
  22655. {&__pyx_kp_s_unknown_token_type, __pyx_k_unknown_token_type, sizeof(__pyx_k_unknown_token_type), 0, 0, 1, 0},
  22656. {&__pyx_kp_u_unknown_token_type, __pyx_k_unknown_token_type, sizeof(__pyx_k_unknown_token_type), 0, 1, 0, 0},
  22657. {&__pyx_n_s_update, __pyx_k_update, sizeof(__pyx_k_update), 0, 0, 1, 1},
  22658. {&__pyx_kp_s_utf_16_be, __pyx_k_utf_16_be, sizeof(__pyx_k_utf_16_be), 0, 0, 1, 0},
  22659. {&__pyx_kp_u_utf_16_be, __pyx_k_utf_16_be, sizeof(__pyx_k_utf_16_be), 0, 1, 0, 0},
  22660. {&__pyx_kp_s_utf_16_le, __pyx_k_utf_16_le, sizeof(__pyx_k_utf_16_le), 0, 0, 1, 0},
  22661. {&__pyx_kp_u_utf_16_le, __pyx_k_utf_16_le, sizeof(__pyx_k_utf_16_le), 0, 1, 0, 0},
  22662. {&__pyx_kp_u_utf_8, __pyx_k_utf_8, sizeof(__pyx_k_utf_8), 0, 1, 0, 0},
  22663. {&__pyx_n_s_value, __pyx_k_value, sizeof(__pyx_k_value), 0, 0, 1, 1},
  22664. {&__pyx_kp_s_value_must_be_a_string, __pyx_k_value_must_be_a_string, sizeof(__pyx_k_value_must_be_a_string), 0, 0, 1, 0},
  22665. {&__pyx_kp_u_value_must_be_a_string, __pyx_k_value_must_be_a_string, sizeof(__pyx_k_value_must_be_a_string), 0, 1, 0, 0},
  22666. {&__pyx_n_s_version, __pyx_k_version, sizeof(__pyx_k_version), 0, 0, 1, 1},
  22667. {&__pyx_n_s_width, __pyx_k_width, sizeof(__pyx_k_width), 0, 0, 1, 1},
  22668. {&__pyx_n_s_write, __pyx_k_write, sizeof(__pyx_k_write), 0, 0, 1, 1},
  22669. {&__pyx_n_s_yaml, __pyx_k_yaml, sizeof(__pyx_k_yaml), 0, 0, 1, 1},
  22670. {&__pyx_n_s_yaml_2, __pyx_k_yaml_2, sizeof(__pyx_k_yaml_2), 0, 0, 1, 1},
  22671. {0, 0, 0, 0, 0, 0, 0}
  22672. };
  22673. static CYTHON_SMALL_CODE int __Pyx_InitCachedBuiltins(void) {
  22674. __pyx_builtin_MemoryError = __Pyx_GetBuiltinName(__pyx_n_s_MemoryError); if (!__pyx_builtin_MemoryError) __PYX_ERR(0, 265, __pyx_L1_error)
  22675. __pyx_builtin_AttributeError = __Pyx_GetBuiltinName(__pyx_n_s_AttributeError); if (!__pyx_builtin_AttributeError) __PYX_ERR(0, 270, __pyx_L1_error)
  22676. __pyx_builtin_TypeError = __Pyx_GetBuiltinName(__pyx_n_s_TypeError); if (!__pyx_builtin_TypeError) __PYX_ERR(0, 301, __pyx_L1_error)
  22677. __pyx_builtin_ValueError = __Pyx_GetBuiltinName(__pyx_n_s_ValueError); if (!__pyx_builtin_ValueError) __PYX_ERR(0, 356, __pyx_L1_error)
  22678. return 0;
  22679. __pyx_L1_error:;
  22680. return -1;
  22681. }
  22682. static CYTHON_SMALL_CODE int __Pyx_InitCachedConstants(void) {
  22683. __Pyx_RefNannyDeclarations
  22684. __Pyx_RefNannySetupContext("__Pyx_InitCachedConstants", 0);
  22685. /* "_yaml.pyx":301
  22686. * if PyString_CheckExact(stream) == 0:
  22687. * if PY_MAJOR_VERSION < 3:
  22688. * raise TypeError("a string or stream input is required") # <<<<<<<<<<<<<<
  22689. * else:
  22690. * raise TypeError(u"a string or stream input is required")
  22691. */
  22692. __pyx_tuple_ = PyTuple_Pack(1, __pyx_kp_s_a_string_or_stream_input_is_requ); if (unlikely(!__pyx_tuple_)) __PYX_ERR(0, 301, __pyx_L1_error)
  22693. __Pyx_GOTREF(__pyx_tuple_);
  22694. __Pyx_GIVEREF(__pyx_tuple_);
  22695. /* "_yaml.pyx":303
  22696. * raise TypeError("a string or stream input is required")
  22697. * else:
  22698. * raise TypeError(u"a string or stream input is required") # <<<<<<<<<<<<<<
  22699. * self.stream = stream
  22700. * yaml_parser_set_input_string(&self.parser, PyString_AS_STRING(stream), PyString_GET_SIZE(stream))
  22701. */
  22702. __pyx_tuple__2 = PyTuple_Pack(1, __pyx_kp_u_a_string_or_stream_input_is_requ); if (unlikely(!__pyx_tuple__2)) __PYX_ERR(0, 303, __pyx_L1_error)
  22703. __Pyx_GOTREF(__pyx_tuple__2);
  22704. __Pyx_GIVEREF(__pyx_tuple__2);
  22705. /* "_yaml.pyx":356
  22706. * return ParserError(context, context_mark, problem, problem_mark)
  22707. * if PY_MAJOR_VERSION < 3:
  22708. * raise ValueError("no parser error") # <<<<<<<<<<<<<<
  22709. * else:
  22710. * raise ValueError(u"no parser error")
  22711. */
  22712. __pyx_tuple__4 = PyTuple_Pack(1, __pyx_kp_s_no_parser_error); if (unlikely(!__pyx_tuple__4)) __PYX_ERR(0, 356, __pyx_L1_error)
  22713. __Pyx_GOTREF(__pyx_tuple__4);
  22714. __Pyx_GIVEREF(__pyx_tuple__4);
  22715. /* "_yaml.pyx":358
  22716. * raise ValueError("no parser error")
  22717. * else:
  22718. * raise ValueError(u"no parser error") # <<<<<<<<<<<<<<
  22719. *
  22720. * def raw_scan(self):
  22721. */
  22722. __pyx_tuple__5 = PyTuple_Pack(1, __pyx_kp_u_no_parser_error); if (unlikely(!__pyx_tuple__5)) __PYX_ERR(0, 358, __pyx_L1_error)
  22723. __Pyx_GOTREF(__pyx_tuple__5);
  22724. __Pyx_GIVEREF(__pyx_tuple__5);
  22725. /* "_yaml.pyx":479
  22726. * else:
  22727. * if PY_MAJOR_VERSION < 3:
  22728. * raise ValueError("unknown token type") # <<<<<<<<<<<<<<
  22729. * else:
  22730. * raise ValueError(u"unknown token type")
  22731. */
  22732. __pyx_tuple__11 = PyTuple_Pack(1, __pyx_kp_s_unknown_token_type); if (unlikely(!__pyx_tuple__11)) __PYX_ERR(0, 479, __pyx_L1_error)
  22733. __Pyx_GOTREF(__pyx_tuple__11);
  22734. __Pyx_GIVEREF(__pyx_tuple__11);
  22735. /* "_yaml.pyx":481
  22736. * raise ValueError("unknown token type")
  22737. * else:
  22738. * raise ValueError(u"unknown token type") # <<<<<<<<<<<<<<
  22739. *
  22740. * def get_token(self):
  22741. */
  22742. __pyx_tuple__12 = PyTuple_Pack(1, __pyx_kp_u_unknown_token_type); if (unlikely(!__pyx_tuple__12)) __PYX_ERR(0, 481, __pyx_L1_error)
  22743. __Pyx_GOTREF(__pyx_tuple__12);
  22744. __Pyx_GIVEREF(__pyx_tuple__12);
  22745. /* "_yaml.pyx":657
  22746. * else:
  22747. * if PY_MAJOR_VERSION < 3:
  22748. * raise ValueError("unknown event type") # <<<<<<<<<<<<<<
  22749. * else:
  22750. * raise ValueError(u"unknown event type")
  22751. */
  22752. __pyx_tuple__13 = PyTuple_Pack(1, __pyx_kp_s_unknown_event_type); if (unlikely(!__pyx_tuple__13)) __PYX_ERR(0, 657, __pyx_L1_error)
  22753. __Pyx_GOTREF(__pyx_tuple__13);
  22754. __Pyx_GIVEREF(__pyx_tuple__13);
  22755. /* "_yaml.pyx":659
  22756. * raise ValueError("unknown event type")
  22757. * else:
  22758. * raise ValueError(u"unknown event type") # <<<<<<<<<<<<<<
  22759. *
  22760. * def get_event(self):
  22761. */
  22762. __pyx_tuple__14 = PyTuple_Pack(1, __pyx_kp_u_unknown_event_type); if (unlikely(!__pyx_tuple__14)) __PYX_ERR(0, 659, __pyx_L1_error)
  22763. __Pyx_GOTREF(__pyx_tuple__14);
  22764. __Pyx_GIVEREF(__pyx_tuple__14);
  22765. /* "(tree fragment)":2
  22766. * def __reduce_cython__(self):
  22767. * raise TypeError("self.parsed_event cannot be converted to a Python object for pickling") # <<<<<<<<<<<<<<
  22768. * def __setstate_cython__(self, __pyx_state):
  22769. * raise TypeError("self.parsed_event cannot be converted to a Python object for pickling")
  22770. */
  22771. __pyx_tuple__15 = PyTuple_Pack(1, __pyx_kp_s_self_parsed_event_cannot_be_conv); if (unlikely(!__pyx_tuple__15)) __PYX_ERR(1, 2, __pyx_L1_error)
  22772. __Pyx_GOTREF(__pyx_tuple__15);
  22773. __Pyx_GIVEREF(__pyx_tuple__15);
  22774. /* "(tree fragment)":4
  22775. * raise TypeError("self.parsed_event cannot be converted to a Python object for pickling")
  22776. * def __setstate_cython__(self, __pyx_state):
  22777. * raise TypeError("self.parsed_event cannot be converted to a Python object for pickling") # <<<<<<<<<<<<<<
  22778. */
  22779. __pyx_tuple__16 = PyTuple_Pack(1, __pyx_kp_s_self_parsed_event_cannot_be_conv); if (unlikely(!__pyx_tuple__16)) __PYX_ERR(1, 4, __pyx_L1_error)
  22780. __Pyx_GOTREF(__pyx_tuple__16);
  22781. __Pyx_GIVEREF(__pyx_tuple__16);
  22782. /* "_yaml.pyx":918
  22783. * if PyString_CheckExact(value) == 0:
  22784. * if PY_MAJOR_VERSION < 3:
  22785. * raise TypeError("a string value is expected") # <<<<<<<<<<<<<<
  22786. * else:
  22787. * raise TypeError(u"a string value is expected")
  22788. */
  22789. __pyx_tuple__17 = PyTuple_Pack(1, __pyx_kp_s_a_string_value_is_expected); if (unlikely(!__pyx_tuple__17)) __PYX_ERR(0, 918, __pyx_L1_error)
  22790. __Pyx_GOTREF(__pyx_tuple__17);
  22791. __Pyx_GIVEREF(__pyx_tuple__17);
  22792. /* "_yaml.pyx":920
  22793. * raise TypeError("a string value is expected")
  22794. * else:
  22795. * raise TypeError(u"a string value is expected") # <<<<<<<<<<<<<<
  22796. * parser.stream_cache = value
  22797. * parser.stream_cache_pos = 0
  22798. */
  22799. __pyx_tuple__18 = PyTuple_Pack(1, __pyx_kp_u_a_string_value_is_expected); if (unlikely(!__pyx_tuple__18)) __PYX_ERR(0, 920, __pyx_L1_error)
  22800. __Pyx_GOTREF(__pyx_tuple__18);
  22801. __Pyx_GIVEREF(__pyx_tuple__18);
  22802. /* "_yaml.pyx":1012
  22803. * return EmitterError(problem)
  22804. * if PY_MAJOR_VERSION < 3:
  22805. * raise ValueError("no emitter error") # <<<<<<<<<<<<<<
  22806. * else:
  22807. * raise ValueError(u"no emitter error")
  22808. */
  22809. __pyx_tuple__22 = PyTuple_Pack(1, __pyx_kp_s_no_emitter_error); if (unlikely(!__pyx_tuple__22)) __PYX_ERR(0, 1012, __pyx_L1_error)
  22810. __Pyx_GOTREF(__pyx_tuple__22);
  22811. __Pyx_GIVEREF(__pyx_tuple__22);
  22812. /* "_yaml.pyx":1014
  22813. * raise ValueError("no emitter error")
  22814. * else:
  22815. * raise ValueError(u"no emitter error") # <<<<<<<<<<<<<<
  22816. *
  22817. * cdef int _object_to_event(self, object event_object, yaml_event_t *event) except 0:
  22818. */
  22819. __pyx_tuple__23 = PyTuple_Pack(1, __pyx_kp_u_no_emitter_error); if (unlikely(!__pyx_tuple__23)) __PYX_ERR(0, 1014, __pyx_L1_error)
  22820. __Pyx_GOTREF(__pyx_tuple__23);
  22821. __Pyx_GIVEREF(__pyx_tuple__23);
  22822. /* "_yaml.pyx":1058
  22823. * if len(event_object.tags) > 128:
  22824. * if PY_MAJOR_VERSION < 3:
  22825. * raise ValueError("too many tags") # <<<<<<<<<<<<<<
  22826. * else:
  22827. * raise ValueError(u"too many tags")
  22828. */
  22829. __pyx_tuple__24 = PyTuple_Pack(1, __pyx_kp_s_too_many_tags); if (unlikely(!__pyx_tuple__24)) __PYX_ERR(0, 1058, __pyx_L1_error)
  22830. __Pyx_GOTREF(__pyx_tuple__24);
  22831. __Pyx_GIVEREF(__pyx_tuple__24);
  22832. /* "_yaml.pyx":1060
  22833. * raise ValueError("too many tags")
  22834. * else:
  22835. * raise ValueError(u"too many tags") # <<<<<<<<<<<<<<
  22836. * tag_directives_start = tag_directives_value
  22837. * tag_directives_end = tag_directives_value
  22838. */
  22839. __pyx_tuple__25 = PyTuple_Pack(1, __pyx_kp_u_too_many_tags); if (unlikely(!__pyx_tuple__25)) __PYX_ERR(0, 1060, __pyx_L1_error)
  22840. __Pyx_GOTREF(__pyx_tuple__25);
  22841. __Pyx_GIVEREF(__pyx_tuple__25);
  22842. /* "_yaml.pyx":1071
  22843. * if not PyString_CheckExact(handle):
  22844. * if PY_MAJOR_VERSION < 3:
  22845. * raise TypeError("tag handle must be a string") # <<<<<<<<<<<<<<
  22846. * else:
  22847. * raise TypeError(u"tag handle must be a string")
  22848. */
  22849. __pyx_tuple__26 = PyTuple_Pack(1, __pyx_kp_s_tag_handle_must_be_a_string); if (unlikely(!__pyx_tuple__26)) __PYX_ERR(0, 1071, __pyx_L1_error)
  22850. __Pyx_GOTREF(__pyx_tuple__26);
  22851. __Pyx_GIVEREF(__pyx_tuple__26);
  22852. /* "_yaml.pyx":1073
  22853. * raise TypeError("tag handle must be a string")
  22854. * else:
  22855. * raise TypeError(u"tag handle must be a string") # <<<<<<<<<<<<<<
  22856. * tag_directives_end.handle = PyString_AS_STRING(handle)
  22857. * if PyUnicode_CheckExact(prefix):
  22858. */
  22859. __pyx_tuple__27 = PyTuple_Pack(1, __pyx_kp_u_tag_handle_must_be_a_string); if (unlikely(!__pyx_tuple__27)) __PYX_ERR(0, 1073, __pyx_L1_error)
  22860. __Pyx_GOTREF(__pyx_tuple__27);
  22861. __Pyx_GIVEREF(__pyx_tuple__27);
  22862. /* "_yaml.pyx":1080
  22863. * if not PyString_CheckExact(prefix):
  22864. * if PY_MAJOR_VERSION < 3:
  22865. * raise TypeError("tag prefix must be a string") # <<<<<<<<<<<<<<
  22866. * else:
  22867. * raise TypeError(u"tag prefix must be a string")
  22868. */
  22869. __pyx_tuple__28 = PyTuple_Pack(1, __pyx_kp_s_tag_prefix_must_be_a_string); if (unlikely(!__pyx_tuple__28)) __PYX_ERR(0, 1080, __pyx_L1_error)
  22870. __Pyx_GOTREF(__pyx_tuple__28);
  22871. __Pyx_GIVEREF(__pyx_tuple__28);
  22872. /* "_yaml.pyx":1082
  22873. * raise TypeError("tag prefix must be a string")
  22874. * else:
  22875. * raise TypeError(u"tag prefix must be a string") # <<<<<<<<<<<<<<
  22876. * tag_directives_end.prefix = PyString_AS_STRING(prefix)
  22877. * tag_directives_end = tag_directives_end+1
  22878. */
  22879. __pyx_tuple__29 = PyTuple_Pack(1, __pyx_kp_u_tag_prefix_must_be_a_string); if (unlikely(!__pyx_tuple__29)) __PYX_ERR(0, 1082, __pyx_L1_error)
  22880. __Pyx_GOTREF(__pyx_tuple__29);
  22881. __Pyx_GIVEREF(__pyx_tuple__29);
  22882. /* "_yaml.pyx":1103
  22883. * if not PyString_CheckExact(anchor_object):
  22884. * if PY_MAJOR_VERSION < 3:
  22885. * raise TypeError("anchor must be a string") # <<<<<<<<<<<<<<
  22886. * else:
  22887. * raise TypeError(u"anchor must be a string")
  22888. */
  22889. __pyx_tuple__30 = PyTuple_Pack(1, __pyx_kp_s_anchor_must_be_a_string); if (unlikely(!__pyx_tuple__30)) __PYX_ERR(0, 1103, __pyx_L1_error)
  22890. __Pyx_GOTREF(__pyx_tuple__30);
  22891. __Pyx_GIVEREF(__pyx_tuple__30);
  22892. /* "_yaml.pyx":1105
  22893. * raise TypeError("anchor must be a string")
  22894. * else:
  22895. * raise TypeError(u"anchor must be a string") # <<<<<<<<<<<<<<
  22896. * anchor = PyString_AS_STRING(anchor_object)
  22897. * if yaml_alias_event_initialize(event, anchor) == 0:
  22898. */
  22899. __pyx_tuple__31 = PyTuple_Pack(1, __pyx_kp_u_anchor_must_be_a_string); if (unlikely(!__pyx_tuple__31)) __PYX_ERR(0, 1105, __pyx_L1_error)
  22900. __Pyx_GOTREF(__pyx_tuple__31);
  22901. __Pyx_GIVEREF(__pyx_tuple__31);
  22902. /* "_yaml.pyx":1128
  22903. * if not PyString_CheckExact(tag_object):
  22904. * if PY_MAJOR_VERSION < 3:
  22905. * raise TypeError("tag must be a string") # <<<<<<<<<<<<<<
  22906. * else:
  22907. * raise TypeError(u"tag must be a string")
  22908. */
  22909. __pyx_tuple__32 = PyTuple_Pack(1, __pyx_kp_s_tag_must_be_a_string); if (unlikely(!__pyx_tuple__32)) __PYX_ERR(0, 1128, __pyx_L1_error)
  22910. __Pyx_GOTREF(__pyx_tuple__32);
  22911. __Pyx_GIVEREF(__pyx_tuple__32);
  22912. /* "_yaml.pyx":1130
  22913. * raise TypeError("tag must be a string")
  22914. * else:
  22915. * raise TypeError(u"tag must be a string") # <<<<<<<<<<<<<<
  22916. * tag = PyString_AS_STRING(tag_object)
  22917. * value_object = event_object.value
  22918. */
  22919. __pyx_tuple__33 = PyTuple_Pack(1, __pyx_kp_u_tag_must_be_a_string); if (unlikely(!__pyx_tuple__33)) __PYX_ERR(0, 1130, __pyx_L1_error)
  22920. __Pyx_GOTREF(__pyx_tuple__33);
  22921. __Pyx_GIVEREF(__pyx_tuple__33);
  22922. /* "_yaml.pyx":1137
  22923. * if not PyString_CheckExact(value_object):
  22924. * if PY_MAJOR_VERSION < 3:
  22925. * raise TypeError("value must be a string") # <<<<<<<<<<<<<<
  22926. * else:
  22927. * raise TypeError(u"value must be a string")
  22928. */
  22929. __pyx_tuple__34 = PyTuple_Pack(1, __pyx_kp_s_value_must_be_a_string); if (unlikely(!__pyx_tuple__34)) __PYX_ERR(0, 1137, __pyx_L1_error)
  22930. __Pyx_GOTREF(__pyx_tuple__34);
  22931. __Pyx_GIVEREF(__pyx_tuple__34);
  22932. /* "_yaml.pyx":1139
  22933. * raise TypeError("value must be a string")
  22934. * else:
  22935. * raise TypeError(u"value must be a string") # <<<<<<<<<<<<<<
  22936. * value = PyString_AS_STRING(value_object)
  22937. * length = PyString_GET_SIZE(value_object)
  22938. */
  22939. __pyx_tuple__35 = PyTuple_Pack(1, __pyx_kp_u_value_must_be_a_string); if (unlikely(!__pyx_tuple__35)) __PYX_ERR(0, 1139, __pyx_L1_error)
  22940. __Pyx_GOTREF(__pyx_tuple__35);
  22941. __Pyx_GIVEREF(__pyx_tuple__35);
  22942. /* "_yaml.pyx":1412
  22943. * quoted_implicit = 0
  22944. * tag_object = node.tag
  22945. * if self.resolve(ScalarNode, node.value, (True, False)) == tag_object: # <<<<<<<<<<<<<<
  22946. * plain_implicit = 1
  22947. * if self.resolve(ScalarNode, node.value, (False, True)) == tag_object:
  22948. */
  22949. __pyx_tuple__36 = PyTuple_Pack(2, Py_True, Py_False); if (unlikely(!__pyx_tuple__36)) __PYX_ERR(0, 1412, __pyx_L1_error)
  22950. __Pyx_GOTREF(__pyx_tuple__36);
  22951. __Pyx_GIVEREF(__pyx_tuple__36);
  22952. /* "_yaml.pyx":1414
  22953. * if self.resolve(ScalarNode, node.value, (True, False)) == tag_object:
  22954. * plain_implicit = 1
  22955. * if self.resolve(ScalarNode, node.value, (False, True)) == tag_object: # <<<<<<<<<<<<<<
  22956. * quoted_implicit = 1
  22957. * tag = NULL
  22958. */
  22959. __pyx_tuple__37 = PyTuple_Pack(2, Py_False, Py_True); if (unlikely(!__pyx_tuple__37)) __PYX_ERR(0, 1414, __pyx_L1_error)
  22960. __Pyx_GOTREF(__pyx_tuple__37);
  22961. __Pyx_GIVEREF(__pyx_tuple__37);
  22962. /* "(tree fragment)":2
  22963. * def __reduce_cython__(self):
  22964. * raise TypeError("Pickling of struct members such as self.emitter must be explicitly requested with @auto_pickle(True)") # <<<<<<<<<<<<<<
  22965. * def __setstate_cython__(self, __pyx_state):
  22966. * raise TypeError("Pickling of struct members such as self.emitter must be explicitly requested with @auto_pickle(True)")
  22967. */
  22968. __pyx_tuple__38 = PyTuple_Pack(1, __pyx_kp_s_Pickling_of_struct_members_such); if (unlikely(!__pyx_tuple__38)) __PYX_ERR(1, 2, __pyx_L1_error)
  22969. __Pyx_GOTREF(__pyx_tuple__38);
  22970. __Pyx_GIVEREF(__pyx_tuple__38);
  22971. /* "(tree fragment)":4
  22972. * raise TypeError("Pickling of struct members such as self.emitter must be explicitly requested with @auto_pickle(True)")
  22973. * def __setstate_cython__(self, __pyx_state):
  22974. * raise TypeError("Pickling of struct members such as self.emitter must be explicitly requested with @auto_pickle(True)") # <<<<<<<<<<<<<<
  22975. */
  22976. __pyx_tuple__39 = PyTuple_Pack(1, __pyx_kp_s_Pickling_of_struct_members_such); if (unlikely(!__pyx_tuple__39)) __PYX_ERR(1, 4, __pyx_L1_error)
  22977. __Pyx_GOTREF(__pyx_tuple__39);
  22978. __Pyx_GIVEREF(__pyx_tuple__39);
  22979. /* "_yaml.pyx":4
  22980. * import yaml
  22981. *
  22982. * def get_version_string(): # <<<<<<<<<<<<<<
  22983. * cdef char *value
  22984. * value = yaml_get_version_string()
  22985. */
  22986. __pyx_tuple__40 = PyTuple_Pack(1, __pyx_n_s_value); if (unlikely(!__pyx_tuple__40)) __PYX_ERR(0, 4, __pyx_L1_error)
  22987. __Pyx_GOTREF(__pyx_tuple__40);
  22988. __Pyx_GIVEREF(__pyx_tuple__40);
  22989. __pyx_codeobj__41 = (PyObject*)__Pyx_PyCode_New(0, 0, 1, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__40, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_ext__yaml_pyx, __pyx_n_s_get_version_string, 4, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__41)) __PYX_ERR(0, 4, __pyx_L1_error)
  22990. /* "_yaml.pyx":12
  22991. * return PyUnicode_FromString(value)
  22992. *
  22993. * def get_version(): # <<<<<<<<<<<<<<
  22994. * cdef int major, minor, patch
  22995. * yaml_get_version(&major, &minor, &patch)
  22996. */
  22997. __pyx_tuple__42 = PyTuple_Pack(3, __pyx_n_s_major, __pyx_n_s_minor, __pyx_n_s_patch); if (unlikely(!__pyx_tuple__42)) __PYX_ERR(0, 12, __pyx_L1_error)
  22998. __Pyx_GOTREF(__pyx_tuple__42);
  22999. __Pyx_GIVEREF(__pyx_tuple__42);
  23000. __pyx_codeobj__43 = (PyObject*)__Pyx_PyCode_New(0, 0, 3, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__42, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_ext__yaml_pyx, __pyx_n_s_get_version, 12, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__43)) __PYX_ERR(0, 12, __pyx_L1_error)
  23001. /* "(tree fragment)":1
  23002. * def __pyx_unpickle_Mark(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<<
  23003. * cdef object __pyx_PickleError
  23004. * cdef object __pyx_result
  23005. */
  23006. __pyx_tuple__44 = PyTuple_Pack(5, __pyx_n_s_pyx_type, __pyx_n_s_pyx_checksum, __pyx_n_s_pyx_state, __pyx_n_s_pyx_PickleError, __pyx_n_s_pyx_result); if (unlikely(!__pyx_tuple__44)) __PYX_ERR(1, 1, __pyx_L1_error)
  23007. __Pyx_GOTREF(__pyx_tuple__44);
  23008. __Pyx_GIVEREF(__pyx_tuple__44);
  23009. __pyx_codeobj__45 = (PyObject*)__Pyx_PyCode_New(3, 0, 5, 0, CO_OPTIMIZED|CO_NEWLOCALS, __pyx_empty_bytes, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_tuple__44, __pyx_empty_tuple, __pyx_empty_tuple, __pyx_kp_s_stringsource, __pyx_n_s_pyx_unpickle_Mark, 1, __pyx_empty_bytes); if (unlikely(!__pyx_codeobj__45)) __PYX_ERR(1, 1, __pyx_L1_error)
  23010. __Pyx_RefNannyFinishContext();
  23011. return 0;
  23012. __pyx_L1_error:;
  23013. __Pyx_RefNannyFinishContext();
  23014. return -1;
  23015. }
  23016. static CYTHON_SMALL_CODE int __Pyx_InitGlobals(void) {
  23017. if (__Pyx_InitStrings(__pyx_string_tab) < 0) __PYX_ERR(0, 2, __pyx_L1_error);
  23018. __pyx_int_0 = PyInt_FromLong(0); if (unlikely(!__pyx_int_0)) __PYX_ERR(0, 2, __pyx_L1_error)
  23019. __pyx_int_1 = PyInt_FromLong(1); if (unlikely(!__pyx_int_1)) __PYX_ERR(0, 2, __pyx_L1_error)
  23020. __pyx_int_66733494 = PyInt_FromLong(66733494L); if (unlikely(!__pyx_int_66733494)) __PYX_ERR(0, 2, __pyx_L1_error)
  23021. return 0;
  23022. __pyx_L1_error:;
  23023. return -1;
  23024. }
  23025. static CYTHON_SMALL_CODE int __Pyx_modinit_global_init_code(void); /*proto*/
  23026. static CYTHON_SMALL_CODE int __Pyx_modinit_variable_export_code(void); /*proto*/
  23027. static CYTHON_SMALL_CODE int __Pyx_modinit_function_export_code(void); /*proto*/
  23028. static CYTHON_SMALL_CODE int __Pyx_modinit_type_init_code(void); /*proto*/
  23029. static CYTHON_SMALL_CODE int __Pyx_modinit_type_import_code(void); /*proto*/
  23030. static CYTHON_SMALL_CODE int __Pyx_modinit_variable_import_code(void); /*proto*/
  23031. static CYTHON_SMALL_CODE int __Pyx_modinit_function_import_code(void); /*proto*/
  23032. static int __Pyx_modinit_global_init_code(void) {
  23033. __Pyx_RefNannyDeclarations
  23034. __Pyx_RefNannySetupContext("__Pyx_modinit_global_init_code", 0);
  23035. /*--- Global init code ---*/
  23036. __Pyx_RefNannyFinishContext();
  23037. return 0;
  23038. }
  23039. static int __Pyx_modinit_variable_export_code(void) {
  23040. __Pyx_RefNannyDeclarations
  23041. __Pyx_RefNannySetupContext("__Pyx_modinit_variable_export_code", 0);
  23042. /*--- Variable export code ---*/
  23043. __Pyx_RefNannyFinishContext();
  23044. return 0;
  23045. }
  23046. static int __Pyx_modinit_function_export_code(void) {
  23047. __Pyx_RefNannyDeclarations
  23048. __Pyx_RefNannySetupContext("__Pyx_modinit_function_export_code", 0);
  23049. /*--- Function export code ---*/
  23050. __Pyx_RefNannyFinishContext();
  23051. return 0;
  23052. }
  23053. static int __Pyx_modinit_type_init_code(void) {
  23054. __Pyx_RefNannyDeclarations
  23055. __Pyx_RefNannySetupContext("__Pyx_modinit_type_init_code", 0);
  23056. /*--- Type init code ---*/
  23057. if (PyType_Ready(&__pyx_type_5_yaml_Mark) < 0) __PYX_ERR(0, 64, __pyx_L1_error)
  23058. #if PY_VERSION_HEX < 0x030800B1
  23059. __pyx_type_5_yaml_Mark.tp_print = 0;
  23060. #endif
  23061. if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_5_yaml_Mark.tp_dictoffset && __pyx_type_5_yaml_Mark.tp_getattro == PyObject_GenericGetAttr)) {
  23062. __pyx_type_5_yaml_Mark.tp_getattro = __Pyx_PyObject_GenericGetAttr;
  23063. }
  23064. if (PyObject_SetAttr(__pyx_m, __pyx_n_s_Mark, (PyObject *)&__pyx_type_5_yaml_Mark) < 0) __PYX_ERR(0, 64, __pyx_L1_error)
  23065. if (__Pyx_setup_reduce((PyObject*)&__pyx_type_5_yaml_Mark) < 0) __PYX_ERR(0, 64, __pyx_L1_error)
  23066. __pyx_ptype_5_yaml_Mark = &__pyx_type_5_yaml_Mark;
  23067. __pyx_vtabptr_5_yaml_CParser = &__pyx_vtable_5_yaml_CParser;
  23068. __pyx_vtable_5_yaml_CParser._parser_error = (PyObject *(*)(struct __pyx_obj_5_yaml_CParser *))__pyx_f_5_yaml_7CParser__parser_error;
  23069. __pyx_vtable_5_yaml_CParser._scan = (PyObject *(*)(struct __pyx_obj_5_yaml_CParser *))__pyx_f_5_yaml_7CParser__scan;
  23070. __pyx_vtable_5_yaml_CParser._token_to_object = (PyObject *(*)(struct __pyx_obj_5_yaml_CParser *, yaml_token_t *))__pyx_f_5_yaml_7CParser__token_to_object;
  23071. __pyx_vtable_5_yaml_CParser._parse = (PyObject *(*)(struct __pyx_obj_5_yaml_CParser *))__pyx_f_5_yaml_7CParser__parse;
  23072. __pyx_vtable_5_yaml_CParser._event_to_object = (PyObject *(*)(struct __pyx_obj_5_yaml_CParser *, yaml_event_t *))__pyx_f_5_yaml_7CParser__event_to_object;
  23073. __pyx_vtable_5_yaml_CParser._compose_document = (PyObject *(*)(struct __pyx_obj_5_yaml_CParser *))__pyx_f_5_yaml_7CParser__compose_document;
  23074. __pyx_vtable_5_yaml_CParser._compose_node = (PyObject *(*)(struct __pyx_obj_5_yaml_CParser *, PyObject *, PyObject *))__pyx_f_5_yaml_7CParser__compose_node;
  23075. __pyx_vtable_5_yaml_CParser._compose_scalar_node = (PyObject *(*)(struct __pyx_obj_5_yaml_CParser *, PyObject *))__pyx_f_5_yaml_7CParser__compose_scalar_node;
  23076. __pyx_vtable_5_yaml_CParser._compose_sequence_node = (PyObject *(*)(struct __pyx_obj_5_yaml_CParser *, PyObject *))__pyx_f_5_yaml_7CParser__compose_sequence_node;
  23077. __pyx_vtable_5_yaml_CParser._compose_mapping_node = (PyObject *(*)(struct __pyx_obj_5_yaml_CParser *, PyObject *))__pyx_f_5_yaml_7CParser__compose_mapping_node;
  23078. __pyx_vtable_5_yaml_CParser._parse_next_event = (int (*)(struct __pyx_obj_5_yaml_CParser *))__pyx_f_5_yaml_7CParser__parse_next_event;
  23079. if (PyType_Ready(&__pyx_type_5_yaml_CParser) < 0) __PYX_ERR(0, 247, __pyx_L1_error)
  23080. #if PY_VERSION_HEX < 0x030800B1
  23081. __pyx_type_5_yaml_CParser.tp_print = 0;
  23082. #endif
  23083. if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_5_yaml_CParser.tp_dictoffset && __pyx_type_5_yaml_CParser.tp_getattro == PyObject_GenericGetAttr)) {
  23084. __pyx_type_5_yaml_CParser.tp_getattro = __Pyx_PyObject_GenericGetAttr;
  23085. }
  23086. if (__Pyx_SetVtable(__pyx_type_5_yaml_CParser.tp_dict, __pyx_vtabptr_5_yaml_CParser) < 0) __PYX_ERR(0, 247, __pyx_L1_error)
  23087. if (PyObject_SetAttr(__pyx_m, __pyx_n_s_CParser, (PyObject *)&__pyx_type_5_yaml_CParser) < 0) __PYX_ERR(0, 247, __pyx_L1_error)
  23088. if (__Pyx_setup_reduce((PyObject*)&__pyx_type_5_yaml_CParser) < 0) __PYX_ERR(0, 247, __pyx_L1_error)
  23089. __pyx_ptype_5_yaml_CParser = &__pyx_type_5_yaml_CParser;
  23090. __pyx_vtabptr_5_yaml_CEmitter = &__pyx_vtable_5_yaml_CEmitter;
  23091. __pyx_vtable_5_yaml_CEmitter._emitter_error = (PyObject *(*)(struct __pyx_obj_5_yaml_CEmitter *))__pyx_f_5_yaml_8CEmitter__emitter_error;
  23092. __pyx_vtable_5_yaml_CEmitter._object_to_event = (int (*)(struct __pyx_obj_5_yaml_CEmitter *, PyObject *, yaml_event_t *))__pyx_f_5_yaml_8CEmitter__object_to_event;
  23093. __pyx_vtable_5_yaml_CEmitter._anchor_node = (int (*)(struct __pyx_obj_5_yaml_CEmitter *, PyObject *))__pyx_f_5_yaml_8CEmitter__anchor_node;
  23094. __pyx_vtable_5_yaml_CEmitter._serialize_node = (int (*)(struct __pyx_obj_5_yaml_CEmitter *, PyObject *, PyObject *, PyObject *))__pyx_f_5_yaml_8CEmitter__serialize_node;
  23095. if (PyType_Ready(&__pyx_type_5_yaml_CEmitter) < 0) __PYX_ERR(0, 935, __pyx_L1_error)
  23096. #if PY_VERSION_HEX < 0x030800B1
  23097. __pyx_type_5_yaml_CEmitter.tp_print = 0;
  23098. #endif
  23099. if ((CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP) && likely(!__pyx_type_5_yaml_CEmitter.tp_dictoffset && __pyx_type_5_yaml_CEmitter.tp_getattro == PyObject_GenericGetAttr)) {
  23100. __pyx_type_5_yaml_CEmitter.tp_getattro = __Pyx_PyObject_GenericGetAttr;
  23101. }
  23102. if (__Pyx_SetVtable(__pyx_type_5_yaml_CEmitter.tp_dict, __pyx_vtabptr_5_yaml_CEmitter) < 0) __PYX_ERR(0, 935, __pyx_L1_error)
  23103. if (PyObject_SetAttr(__pyx_m, __pyx_n_s_CEmitter, (PyObject *)&__pyx_type_5_yaml_CEmitter) < 0) __PYX_ERR(0, 935, __pyx_L1_error)
  23104. if (__Pyx_setup_reduce((PyObject*)&__pyx_type_5_yaml_CEmitter) < 0) __PYX_ERR(0, 935, __pyx_L1_error)
  23105. __pyx_ptype_5_yaml_CEmitter = &__pyx_type_5_yaml_CEmitter;
  23106. __Pyx_RefNannyFinishContext();
  23107. return 0;
  23108. __pyx_L1_error:;
  23109. __Pyx_RefNannyFinishContext();
  23110. return -1;
  23111. }
  23112. static int __Pyx_modinit_type_import_code(void) {
  23113. __Pyx_RefNannyDeclarations
  23114. __Pyx_RefNannySetupContext("__Pyx_modinit_type_import_code", 0);
  23115. /*--- Type import code ---*/
  23116. __Pyx_RefNannyFinishContext();
  23117. return 0;
  23118. }
  23119. static int __Pyx_modinit_variable_import_code(void) {
  23120. __Pyx_RefNannyDeclarations
  23121. __Pyx_RefNannySetupContext("__Pyx_modinit_variable_import_code", 0);
  23122. /*--- Variable import code ---*/
  23123. __Pyx_RefNannyFinishContext();
  23124. return 0;
  23125. }
  23126. static int __Pyx_modinit_function_import_code(void) {
  23127. __Pyx_RefNannyDeclarations
  23128. __Pyx_RefNannySetupContext("__Pyx_modinit_function_import_code", 0);
  23129. /*--- Function import code ---*/
  23130. __Pyx_RefNannyFinishContext();
  23131. return 0;
  23132. }
  23133. #if PY_MAJOR_VERSION < 3
  23134. #ifdef CYTHON_NO_PYINIT_EXPORT
  23135. #define __Pyx_PyMODINIT_FUNC void
  23136. #else
  23137. #define __Pyx_PyMODINIT_FUNC PyMODINIT_FUNC
  23138. #endif
  23139. #else
  23140. #ifdef CYTHON_NO_PYINIT_EXPORT
  23141. #define __Pyx_PyMODINIT_FUNC PyObject *
  23142. #else
  23143. #define __Pyx_PyMODINIT_FUNC PyMODINIT_FUNC
  23144. #endif
  23145. #endif
  23146. #if PY_MAJOR_VERSION < 3
  23147. __Pyx_PyMODINIT_FUNC init_yaml(void) CYTHON_SMALL_CODE; /*proto*/
  23148. __Pyx_PyMODINIT_FUNC init_yaml(void)
  23149. #else
  23150. __Pyx_PyMODINIT_FUNC PyInit__yaml(void) CYTHON_SMALL_CODE; /*proto*/
  23151. __Pyx_PyMODINIT_FUNC PyInit__yaml(void)
  23152. #if CYTHON_PEP489_MULTI_PHASE_INIT
  23153. {
  23154. return PyModuleDef_Init(&__pyx_moduledef);
  23155. }
  23156. static CYTHON_SMALL_CODE int __Pyx_check_single_interpreter(void) {
  23157. #if PY_VERSION_HEX >= 0x030700A1
  23158. static PY_INT64_T main_interpreter_id = -1;
  23159. PY_INT64_T current_id = PyInterpreterState_GetID(PyThreadState_Get()->interp);
  23160. if (main_interpreter_id == -1) {
  23161. main_interpreter_id = current_id;
  23162. return (unlikely(current_id == -1)) ? -1 : 0;
  23163. } else if (unlikely(main_interpreter_id != current_id))
  23164. #else
  23165. static PyInterpreterState *main_interpreter = NULL;
  23166. PyInterpreterState *current_interpreter = PyThreadState_Get()->interp;
  23167. if (!main_interpreter) {
  23168. main_interpreter = current_interpreter;
  23169. } else if (unlikely(main_interpreter != current_interpreter))
  23170. #endif
  23171. {
  23172. PyErr_SetString(
  23173. PyExc_ImportError,
  23174. "Interpreter change detected - this module can only be loaded into one interpreter per process.");
  23175. return -1;
  23176. }
  23177. return 0;
  23178. }
  23179. static CYTHON_SMALL_CODE int __Pyx_copy_spec_to_module(PyObject *spec, PyObject *moddict, const char* from_name, const char* to_name, int allow_none) {
  23180. PyObject *value = PyObject_GetAttrString(spec, from_name);
  23181. int result = 0;
  23182. if (likely(value)) {
  23183. if (allow_none || value != Py_None) {
  23184. result = PyDict_SetItemString(moddict, to_name, value);
  23185. }
  23186. Py_DECREF(value);
  23187. } else if (PyErr_ExceptionMatches(PyExc_AttributeError)) {
  23188. PyErr_Clear();
  23189. } else {
  23190. result = -1;
  23191. }
  23192. return result;
  23193. }
  23194. static CYTHON_SMALL_CODE PyObject* __pyx_pymod_create(PyObject *spec, CYTHON_UNUSED PyModuleDef *def) {
  23195. PyObject *module = NULL, *moddict, *modname;
  23196. if (__Pyx_check_single_interpreter())
  23197. return NULL;
  23198. if (__pyx_m)
  23199. return __Pyx_NewRef(__pyx_m);
  23200. modname = PyObject_GetAttrString(spec, "name");
  23201. if (unlikely(!modname)) goto bad;
  23202. module = PyModule_NewObject(modname);
  23203. Py_DECREF(modname);
  23204. if (unlikely(!module)) goto bad;
  23205. moddict = PyModule_GetDict(module);
  23206. if (unlikely(!moddict)) goto bad;
  23207. if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "loader", "__loader__", 1) < 0)) goto bad;
  23208. if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "origin", "__file__", 1) < 0)) goto bad;
  23209. if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "parent", "__package__", 1) < 0)) goto bad;
  23210. if (unlikely(__Pyx_copy_spec_to_module(spec, moddict, "submodule_search_locations", "__path__", 0) < 0)) goto bad;
  23211. return module;
  23212. bad:
  23213. Py_XDECREF(module);
  23214. return NULL;
  23215. }
  23216. static CYTHON_SMALL_CODE int __pyx_pymod_exec__yaml(PyObject *__pyx_pyinit_module)
  23217. #endif
  23218. #endif
  23219. {
  23220. PyObject *__pyx_t_1 = NULL;
  23221. PyObject *__pyx_t_2 = NULL;
  23222. __Pyx_RefNannyDeclarations
  23223. #if CYTHON_PEP489_MULTI_PHASE_INIT
  23224. if (__pyx_m) {
  23225. if (__pyx_m == __pyx_pyinit_module) return 0;
  23226. PyErr_SetString(PyExc_RuntimeError, "Module '_yaml' has already been imported. Re-initialisation is not supported.");
  23227. return -1;
  23228. }
  23229. #elif PY_MAJOR_VERSION >= 3
  23230. if (__pyx_m) return __Pyx_NewRef(__pyx_m);
  23231. #endif
  23232. #if CYTHON_REFNANNY
  23233. __Pyx_RefNanny = __Pyx_RefNannyImportAPI("refnanny");
  23234. if (!__Pyx_RefNanny) {
  23235. PyErr_Clear();
  23236. __Pyx_RefNanny = __Pyx_RefNannyImportAPI("Cython.Runtime.refnanny");
  23237. if (!__Pyx_RefNanny)
  23238. Py_FatalError("failed to import 'refnanny' module");
  23239. }
  23240. #endif
  23241. __Pyx_RefNannySetupContext("__Pyx_PyMODINIT_FUNC PyInit__yaml(void)", 0);
  23242. if (__Pyx_check_binary_version() < 0) __PYX_ERR(0, 2, __pyx_L1_error)
  23243. #ifdef __Pxy_PyFrame_Initialize_Offsets
  23244. __Pxy_PyFrame_Initialize_Offsets();
  23245. #endif
  23246. __pyx_empty_tuple = PyTuple_New(0); if (unlikely(!__pyx_empty_tuple)) __PYX_ERR(0, 2, __pyx_L1_error)
  23247. __pyx_empty_bytes = PyBytes_FromStringAndSize("", 0); if (unlikely(!__pyx_empty_bytes)) __PYX_ERR(0, 2, __pyx_L1_error)
  23248. __pyx_empty_unicode = PyUnicode_FromStringAndSize("", 0); if (unlikely(!__pyx_empty_unicode)) __PYX_ERR(0, 2, __pyx_L1_error)
  23249. #ifdef __Pyx_CyFunction_USED
  23250. if (__pyx_CyFunction_init() < 0) __PYX_ERR(0, 2, __pyx_L1_error)
  23251. #endif
  23252. #ifdef __Pyx_FusedFunction_USED
  23253. if (__pyx_FusedFunction_init() < 0) __PYX_ERR(0, 2, __pyx_L1_error)
  23254. #endif
  23255. #ifdef __Pyx_Coroutine_USED
  23256. if (__pyx_Coroutine_init() < 0) __PYX_ERR(0, 2, __pyx_L1_error)
  23257. #endif
  23258. #ifdef __Pyx_Generator_USED
  23259. if (__pyx_Generator_init() < 0) __PYX_ERR(0, 2, __pyx_L1_error)
  23260. #endif
  23261. #ifdef __Pyx_AsyncGen_USED
  23262. if (__pyx_AsyncGen_init() < 0) __PYX_ERR(0, 2, __pyx_L1_error)
  23263. #endif
  23264. #ifdef __Pyx_StopAsyncIteration_USED
  23265. if (__pyx_StopAsyncIteration_init() < 0) __PYX_ERR(0, 2, __pyx_L1_error)
  23266. #endif
  23267. /*--- Library function declarations ---*/
  23268. /*--- Threads initialization code ---*/
  23269. #if defined(__PYX_FORCE_INIT_THREADS) && __PYX_FORCE_INIT_THREADS
  23270. #ifdef WITH_THREAD /* Python build with threading support? */
  23271. PyEval_InitThreads();
  23272. #endif
  23273. #endif
  23274. /*--- Module creation code ---*/
  23275. #if CYTHON_PEP489_MULTI_PHASE_INIT
  23276. __pyx_m = __pyx_pyinit_module;
  23277. Py_INCREF(__pyx_m);
  23278. #else
  23279. #if PY_MAJOR_VERSION < 3
  23280. __pyx_m = Py_InitModule4("_yaml", __pyx_methods, 0, 0, PYTHON_API_VERSION); Py_XINCREF(__pyx_m);
  23281. #else
  23282. __pyx_m = PyModule_Create(&__pyx_moduledef);
  23283. #endif
  23284. if (unlikely(!__pyx_m)) __PYX_ERR(0, 2, __pyx_L1_error)
  23285. #endif
  23286. __pyx_d = PyModule_GetDict(__pyx_m); if (unlikely(!__pyx_d)) __PYX_ERR(0, 2, __pyx_L1_error)
  23287. Py_INCREF(__pyx_d);
  23288. __pyx_b = PyImport_AddModule(__Pyx_BUILTIN_MODULE_NAME); if (unlikely(!__pyx_b)) __PYX_ERR(0, 2, __pyx_L1_error)
  23289. Py_INCREF(__pyx_b);
  23290. __pyx_cython_runtime = PyImport_AddModule((char *) "cython_runtime"); if (unlikely(!__pyx_cython_runtime)) __PYX_ERR(0, 2, __pyx_L1_error)
  23291. Py_INCREF(__pyx_cython_runtime);
  23292. if (PyObject_SetAttrString(__pyx_m, "__builtins__", __pyx_b) < 0) __PYX_ERR(0, 2, __pyx_L1_error);
  23293. /*--- Initialize various global constants etc. ---*/
  23294. if (__Pyx_InitGlobals() < 0) __PYX_ERR(0, 2, __pyx_L1_error)
  23295. #if PY_MAJOR_VERSION < 3 && (__PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT)
  23296. if (__Pyx_init_sys_getdefaultencoding_params() < 0) __PYX_ERR(0, 2, __pyx_L1_error)
  23297. #endif
  23298. if (__pyx_module_is_main__yaml) {
  23299. if (PyObject_SetAttr(__pyx_m, __pyx_n_s_name_2, __pyx_n_s_main) < 0) __PYX_ERR(0, 2, __pyx_L1_error)
  23300. }
  23301. #if PY_MAJOR_VERSION >= 3
  23302. {
  23303. PyObject *modules = PyImport_GetModuleDict(); if (unlikely(!modules)) __PYX_ERR(0, 2, __pyx_L1_error)
  23304. if (!PyDict_GetItemString(modules, "_yaml")) {
  23305. if (unlikely(PyDict_SetItemString(modules, "_yaml", __pyx_m) < 0)) __PYX_ERR(0, 2, __pyx_L1_error)
  23306. }
  23307. }
  23308. #endif
  23309. /*--- Builtin init code ---*/
  23310. if (__Pyx_InitCachedBuiltins() < 0) goto __pyx_L1_error;
  23311. /*--- Constants init code ---*/
  23312. if (__Pyx_InitCachedConstants() < 0) goto __pyx_L1_error;
  23313. /*--- Global type/function init code ---*/
  23314. (void)__Pyx_modinit_global_init_code();
  23315. (void)__Pyx_modinit_variable_export_code();
  23316. (void)__Pyx_modinit_function_export_code();
  23317. if (unlikely(__Pyx_modinit_type_init_code() != 0)) goto __pyx_L1_error;
  23318. (void)__Pyx_modinit_type_import_code();
  23319. (void)__Pyx_modinit_variable_import_code();
  23320. (void)__Pyx_modinit_function_import_code();
  23321. /*--- Execution code ---*/
  23322. #if defined(__Pyx_Generator_USED) || defined(__Pyx_Coroutine_USED)
  23323. if (__Pyx_patch_abc() < 0) __PYX_ERR(0, 2, __pyx_L1_error)
  23324. #endif
  23325. /* "_yaml.pyx":2
  23326. *
  23327. * import yaml # <<<<<<<<<<<<<<
  23328. *
  23329. * def get_version_string():
  23330. */
  23331. __pyx_t_1 = __Pyx_Import(__pyx_n_s_yaml, 0, -1); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 2, __pyx_L1_error)
  23332. __Pyx_GOTREF(__pyx_t_1);
  23333. if (PyDict_SetItem(__pyx_d, __pyx_n_s_yaml, __pyx_t_1) < 0) __PYX_ERR(0, 2, __pyx_L1_error)
  23334. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23335. /* "_yaml.pyx":4
  23336. * import yaml
  23337. *
  23338. * def get_version_string(): # <<<<<<<<<<<<<<
  23339. * cdef char *value
  23340. * value = yaml_get_version_string()
  23341. */
  23342. __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_5_yaml_1get_version_string, NULL, __pyx_n_s_yaml_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 4, __pyx_L1_error)
  23343. __Pyx_GOTREF(__pyx_t_1);
  23344. if (PyDict_SetItem(__pyx_d, __pyx_n_s_get_version_string, __pyx_t_1) < 0) __PYX_ERR(0, 4, __pyx_L1_error)
  23345. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23346. /* "_yaml.pyx":12
  23347. * return PyUnicode_FromString(value)
  23348. *
  23349. * def get_version(): # <<<<<<<<<<<<<<
  23350. * cdef int major, minor, patch
  23351. * yaml_get_version(&major, &minor, &patch)
  23352. */
  23353. __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_5_yaml_3get_version, NULL, __pyx_n_s_yaml_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 12, __pyx_L1_error)
  23354. __Pyx_GOTREF(__pyx_t_1);
  23355. if (PyDict_SetItem(__pyx_d, __pyx_n_s_get_version, __pyx_t_1) < 0) __PYX_ERR(0, 12, __pyx_L1_error)
  23356. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23357. /* "_yaml.pyx":18
  23358. *
  23359. * #Mark = yaml.error.Mark
  23360. * YAMLError = yaml.error.YAMLError # <<<<<<<<<<<<<<
  23361. * ReaderError = yaml.reader.ReaderError
  23362. * ScannerError = yaml.scanner.ScannerError
  23363. */
  23364. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 18, __pyx_L1_error)
  23365. __Pyx_GOTREF(__pyx_t_1);
  23366. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_error); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 18, __pyx_L1_error)
  23367. __Pyx_GOTREF(__pyx_t_2);
  23368. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23369. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_YAMLError); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 18, __pyx_L1_error)
  23370. __Pyx_GOTREF(__pyx_t_1);
  23371. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23372. if (PyDict_SetItem(__pyx_d, __pyx_n_s_YAMLError, __pyx_t_1) < 0) __PYX_ERR(0, 18, __pyx_L1_error)
  23373. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23374. /* "_yaml.pyx":19
  23375. * #Mark = yaml.error.Mark
  23376. * YAMLError = yaml.error.YAMLError
  23377. * ReaderError = yaml.reader.ReaderError # <<<<<<<<<<<<<<
  23378. * ScannerError = yaml.scanner.ScannerError
  23379. * ParserError = yaml.parser.ParserError
  23380. */
  23381. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 19, __pyx_L1_error)
  23382. __Pyx_GOTREF(__pyx_t_1);
  23383. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_reader); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 19, __pyx_L1_error)
  23384. __Pyx_GOTREF(__pyx_t_2);
  23385. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23386. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_ReaderError); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 19, __pyx_L1_error)
  23387. __Pyx_GOTREF(__pyx_t_1);
  23388. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23389. if (PyDict_SetItem(__pyx_d, __pyx_n_s_ReaderError, __pyx_t_1) < 0) __PYX_ERR(0, 19, __pyx_L1_error)
  23390. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23391. /* "_yaml.pyx":20
  23392. * YAMLError = yaml.error.YAMLError
  23393. * ReaderError = yaml.reader.ReaderError
  23394. * ScannerError = yaml.scanner.ScannerError # <<<<<<<<<<<<<<
  23395. * ParserError = yaml.parser.ParserError
  23396. * ComposerError = yaml.composer.ComposerError
  23397. */
  23398. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 20, __pyx_L1_error)
  23399. __Pyx_GOTREF(__pyx_t_1);
  23400. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_scanner); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 20, __pyx_L1_error)
  23401. __Pyx_GOTREF(__pyx_t_2);
  23402. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23403. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_ScannerError); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 20, __pyx_L1_error)
  23404. __Pyx_GOTREF(__pyx_t_1);
  23405. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23406. if (PyDict_SetItem(__pyx_d, __pyx_n_s_ScannerError, __pyx_t_1) < 0) __PYX_ERR(0, 20, __pyx_L1_error)
  23407. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23408. /* "_yaml.pyx":21
  23409. * ReaderError = yaml.reader.ReaderError
  23410. * ScannerError = yaml.scanner.ScannerError
  23411. * ParserError = yaml.parser.ParserError # <<<<<<<<<<<<<<
  23412. * ComposerError = yaml.composer.ComposerError
  23413. * ConstructorError = yaml.constructor.ConstructorError
  23414. */
  23415. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 21, __pyx_L1_error)
  23416. __Pyx_GOTREF(__pyx_t_1);
  23417. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_parser); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 21, __pyx_L1_error)
  23418. __Pyx_GOTREF(__pyx_t_2);
  23419. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23420. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_ParserError); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 21, __pyx_L1_error)
  23421. __Pyx_GOTREF(__pyx_t_1);
  23422. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23423. if (PyDict_SetItem(__pyx_d, __pyx_n_s_ParserError, __pyx_t_1) < 0) __PYX_ERR(0, 21, __pyx_L1_error)
  23424. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23425. /* "_yaml.pyx":22
  23426. * ScannerError = yaml.scanner.ScannerError
  23427. * ParserError = yaml.parser.ParserError
  23428. * ComposerError = yaml.composer.ComposerError # <<<<<<<<<<<<<<
  23429. * ConstructorError = yaml.constructor.ConstructorError
  23430. * EmitterError = yaml.emitter.EmitterError
  23431. */
  23432. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 22, __pyx_L1_error)
  23433. __Pyx_GOTREF(__pyx_t_1);
  23434. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_composer); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 22, __pyx_L1_error)
  23435. __Pyx_GOTREF(__pyx_t_2);
  23436. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23437. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_ComposerError); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 22, __pyx_L1_error)
  23438. __Pyx_GOTREF(__pyx_t_1);
  23439. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23440. if (PyDict_SetItem(__pyx_d, __pyx_n_s_ComposerError, __pyx_t_1) < 0) __PYX_ERR(0, 22, __pyx_L1_error)
  23441. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23442. /* "_yaml.pyx":23
  23443. * ParserError = yaml.parser.ParserError
  23444. * ComposerError = yaml.composer.ComposerError
  23445. * ConstructorError = yaml.constructor.ConstructorError # <<<<<<<<<<<<<<
  23446. * EmitterError = yaml.emitter.EmitterError
  23447. * SerializerError = yaml.serializer.SerializerError
  23448. */
  23449. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 23, __pyx_L1_error)
  23450. __Pyx_GOTREF(__pyx_t_1);
  23451. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_constructor); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 23, __pyx_L1_error)
  23452. __Pyx_GOTREF(__pyx_t_2);
  23453. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23454. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_ConstructorError); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 23, __pyx_L1_error)
  23455. __Pyx_GOTREF(__pyx_t_1);
  23456. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23457. if (PyDict_SetItem(__pyx_d, __pyx_n_s_ConstructorError, __pyx_t_1) < 0) __PYX_ERR(0, 23, __pyx_L1_error)
  23458. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23459. /* "_yaml.pyx":24
  23460. * ComposerError = yaml.composer.ComposerError
  23461. * ConstructorError = yaml.constructor.ConstructorError
  23462. * EmitterError = yaml.emitter.EmitterError # <<<<<<<<<<<<<<
  23463. * SerializerError = yaml.serializer.SerializerError
  23464. * RepresenterError = yaml.representer.RepresenterError
  23465. */
  23466. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 24, __pyx_L1_error)
  23467. __Pyx_GOTREF(__pyx_t_1);
  23468. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_emitter); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 24, __pyx_L1_error)
  23469. __Pyx_GOTREF(__pyx_t_2);
  23470. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23471. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_EmitterError); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 24, __pyx_L1_error)
  23472. __Pyx_GOTREF(__pyx_t_1);
  23473. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23474. if (PyDict_SetItem(__pyx_d, __pyx_n_s_EmitterError, __pyx_t_1) < 0) __PYX_ERR(0, 24, __pyx_L1_error)
  23475. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23476. /* "_yaml.pyx":25
  23477. * ConstructorError = yaml.constructor.ConstructorError
  23478. * EmitterError = yaml.emitter.EmitterError
  23479. * SerializerError = yaml.serializer.SerializerError # <<<<<<<<<<<<<<
  23480. * RepresenterError = yaml.representer.RepresenterError
  23481. *
  23482. */
  23483. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 25, __pyx_L1_error)
  23484. __Pyx_GOTREF(__pyx_t_1);
  23485. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_serializer); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 25, __pyx_L1_error)
  23486. __Pyx_GOTREF(__pyx_t_2);
  23487. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23488. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_SerializerError); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 25, __pyx_L1_error)
  23489. __Pyx_GOTREF(__pyx_t_1);
  23490. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23491. if (PyDict_SetItem(__pyx_d, __pyx_n_s_SerializerError, __pyx_t_1) < 0) __PYX_ERR(0, 25, __pyx_L1_error)
  23492. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23493. /* "_yaml.pyx":26
  23494. * EmitterError = yaml.emitter.EmitterError
  23495. * SerializerError = yaml.serializer.SerializerError
  23496. * RepresenterError = yaml.representer.RepresenterError # <<<<<<<<<<<<<<
  23497. *
  23498. * StreamStartToken = yaml.tokens.StreamStartToken
  23499. */
  23500. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 26, __pyx_L1_error)
  23501. __Pyx_GOTREF(__pyx_t_1);
  23502. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_representer); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 26, __pyx_L1_error)
  23503. __Pyx_GOTREF(__pyx_t_2);
  23504. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23505. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_RepresenterError); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 26, __pyx_L1_error)
  23506. __Pyx_GOTREF(__pyx_t_1);
  23507. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23508. if (PyDict_SetItem(__pyx_d, __pyx_n_s_RepresenterError, __pyx_t_1) < 0) __PYX_ERR(0, 26, __pyx_L1_error)
  23509. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23510. /* "_yaml.pyx":28
  23511. * RepresenterError = yaml.representer.RepresenterError
  23512. *
  23513. * StreamStartToken = yaml.tokens.StreamStartToken # <<<<<<<<<<<<<<
  23514. * StreamEndToken = yaml.tokens.StreamEndToken
  23515. * DirectiveToken = yaml.tokens.DirectiveToken
  23516. */
  23517. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 28, __pyx_L1_error)
  23518. __Pyx_GOTREF(__pyx_t_1);
  23519. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 28, __pyx_L1_error)
  23520. __Pyx_GOTREF(__pyx_t_2);
  23521. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23522. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_StreamStartToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 28, __pyx_L1_error)
  23523. __Pyx_GOTREF(__pyx_t_1);
  23524. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23525. if (PyDict_SetItem(__pyx_d, __pyx_n_s_StreamStartToken, __pyx_t_1) < 0) __PYX_ERR(0, 28, __pyx_L1_error)
  23526. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23527. /* "_yaml.pyx":29
  23528. *
  23529. * StreamStartToken = yaml.tokens.StreamStartToken
  23530. * StreamEndToken = yaml.tokens.StreamEndToken # <<<<<<<<<<<<<<
  23531. * DirectiveToken = yaml.tokens.DirectiveToken
  23532. * DocumentStartToken = yaml.tokens.DocumentStartToken
  23533. */
  23534. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 29, __pyx_L1_error)
  23535. __Pyx_GOTREF(__pyx_t_1);
  23536. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 29, __pyx_L1_error)
  23537. __Pyx_GOTREF(__pyx_t_2);
  23538. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23539. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_StreamEndToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 29, __pyx_L1_error)
  23540. __Pyx_GOTREF(__pyx_t_1);
  23541. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23542. if (PyDict_SetItem(__pyx_d, __pyx_n_s_StreamEndToken, __pyx_t_1) < 0) __PYX_ERR(0, 29, __pyx_L1_error)
  23543. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23544. /* "_yaml.pyx":30
  23545. * StreamStartToken = yaml.tokens.StreamStartToken
  23546. * StreamEndToken = yaml.tokens.StreamEndToken
  23547. * DirectiveToken = yaml.tokens.DirectiveToken # <<<<<<<<<<<<<<
  23548. * DocumentStartToken = yaml.tokens.DocumentStartToken
  23549. * DocumentEndToken = yaml.tokens.DocumentEndToken
  23550. */
  23551. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 30, __pyx_L1_error)
  23552. __Pyx_GOTREF(__pyx_t_1);
  23553. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 30, __pyx_L1_error)
  23554. __Pyx_GOTREF(__pyx_t_2);
  23555. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23556. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_DirectiveToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 30, __pyx_L1_error)
  23557. __Pyx_GOTREF(__pyx_t_1);
  23558. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23559. if (PyDict_SetItem(__pyx_d, __pyx_n_s_DirectiveToken, __pyx_t_1) < 0) __PYX_ERR(0, 30, __pyx_L1_error)
  23560. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23561. /* "_yaml.pyx":31
  23562. * StreamEndToken = yaml.tokens.StreamEndToken
  23563. * DirectiveToken = yaml.tokens.DirectiveToken
  23564. * DocumentStartToken = yaml.tokens.DocumentStartToken # <<<<<<<<<<<<<<
  23565. * DocumentEndToken = yaml.tokens.DocumentEndToken
  23566. * BlockSequenceStartToken = yaml.tokens.BlockSequenceStartToken
  23567. */
  23568. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 31, __pyx_L1_error)
  23569. __Pyx_GOTREF(__pyx_t_1);
  23570. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 31, __pyx_L1_error)
  23571. __Pyx_GOTREF(__pyx_t_2);
  23572. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23573. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_DocumentStartToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 31, __pyx_L1_error)
  23574. __Pyx_GOTREF(__pyx_t_1);
  23575. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23576. if (PyDict_SetItem(__pyx_d, __pyx_n_s_DocumentStartToken, __pyx_t_1) < 0) __PYX_ERR(0, 31, __pyx_L1_error)
  23577. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23578. /* "_yaml.pyx":32
  23579. * DirectiveToken = yaml.tokens.DirectiveToken
  23580. * DocumentStartToken = yaml.tokens.DocumentStartToken
  23581. * DocumentEndToken = yaml.tokens.DocumentEndToken # <<<<<<<<<<<<<<
  23582. * BlockSequenceStartToken = yaml.tokens.BlockSequenceStartToken
  23583. * BlockMappingStartToken = yaml.tokens.BlockMappingStartToken
  23584. */
  23585. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 32, __pyx_L1_error)
  23586. __Pyx_GOTREF(__pyx_t_1);
  23587. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 32, __pyx_L1_error)
  23588. __Pyx_GOTREF(__pyx_t_2);
  23589. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23590. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_DocumentEndToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 32, __pyx_L1_error)
  23591. __Pyx_GOTREF(__pyx_t_1);
  23592. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23593. if (PyDict_SetItem(__pyx_d, __pyx_n_s_DocumentEndToken, __pyx_t_1) < 0) __PYX_ERR(0, 32, __pyx_L1_error)
  23594. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23595. /* "_yaml.pyx":33
  23596. * DocumentStartToken = yaml.tokens.DocumentStartToken
  23597. * DocumentEndToken = yaml.tokens.DocumentEndToken
  23598. * BlockSequenceStartToken = yaml.tokens.BlockSequenceStartToken # <<<<<<<<<<<<<<
  23599. * BlockMappingStartToken = yaml.tokens.BlockMappingStartToken
  23600. * BlockEndToken = yaml.tokens.BlockEndToken
  23601. */
  23602. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 33, __pyx_L1_error)
  23603. __Pyx_GOTREF(__pyx_t_1);
  23604. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 33, __pyx_L1_error)
  23605. __Pyx_GOTREF(__pyx_t_2);
  23606. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23607. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_BlockSequenceStartToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 33, __pyx_L1_error)
  23608. __Pyx_GOTREF(__pyx_t_1);
  23609. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23610. if (PyDict_SetItem(__pyx_d, __pyx_n_s_BlockSequenceStartToken, __pyx_t_1) < 0) __PYX_ERR(0, 33, __pyx_L1_error)
  23611. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23612. /* "_yaml.pyx":34
  23613. * DocumentEndToken = yaml.tokens.DocumentEndToken
  23614. * BlockSequenceStartToken = yaml.tokens.BlockSequenceStartToken
  23615. * BlockMappingStartToken = yaml.tokens.BlockMappingStartToken # <<<<<<<<<<<<<<
  23616. * BlockEndToken = yaml.tokens.BlockEndToken
  23617. * FlowSequenceStartToken = yaml.tokens.FlowSequenceStartToken
  23618. */
  23619. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 34, __pyx_L1_error)
  23620. __Pyx_GOTREF(__pyx_t_1);
  23621. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 34, __pyx_L1_error)
  23622. __Pyx_GOTREF(__pyx_t_2);
  23623. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23624. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_BlockMappingStartToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 34, __pyx_L1_error)
  23625. __Pyx_GOTREF(__pyx_t_1);
  23626. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23627. if (PyDict_SetItem(__pyx_d, __pyx_n_s_BlockMappingStartToken, __pyx_t_1) < 0) __PYX_ERR(0, 34, __pyx_L1_error)
  23628. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23629. /* "_yaml.pyx":35
  23630. * BlockSequenceStartToken = yaml.tokens.BlockSequenceStartToken
  23631. * BlockMappingStartToken = yaml.tokens.BlockMappingStartToken
  23632. * BlockEndToken = yaml.tokens.BlockEndToken # <<<<<<<<<<<<<<
  23633. * FlowSequenceStartToken = yaml.tokens.FlowSequenceStartToken
  23634. * FlowMappingStartToken = yaml.tokens.FlowMappingStartToken
  23635. */
  23636. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 35, __pyx_L1_error)
  23637. __Pyx_GOTREF(__pyx_t_1);
  23638. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 35, __pyx_L1_error)
  23639. __Pyx_GOTREF(__pyx_t_2);
  23640. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23641. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_BlockEndToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 35, __pyx_L1_error)
  23642. __Pyx_GOTREF(__pyx_t_1);
  23643. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23644. if (PyDict_SetItem(__pyx_d, __pyx_n_s_BlockEndToken, __pyx_t_1) < 0) __PYX_ERR(0, 35, __pyx_L1_error)
  23645. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23646. /* "_yaml.pyx":36
  23647. * BlockMappingStartToken = yaml.tokens.BlockMappingStartToken
  23648. * BlockEndToken = yaml.tokens.BlockEndToken
  23649. * FlowSequenceStartToken = yaml.tokens.FlowSequenceStartToken # <<<<<<<<<<<<<<
  23650. * FlowMappingStartToken = yaml.tokens.FlowMappingStartToken
  23651. * FlowSequenceEndToken = yaml.tokens.FlowSequenceEndToken
  23652. */
  23653. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 36, __pyx_L1_error)
  23654. __Pyx_GOTREF(__pyx_t_1);
  23655. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 36, __pyx_L1_error)
  23656. __Pyx_GOTREF(__pyx_t_2);
  23657. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23658. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_FlowSequenceStartToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 36, __pyx_L1_error)
  23659. __Pyx_GOTREF(__pyx_t_1);
  23660. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23661. if (PyDict_SetItem(__pyx_d, __pyx_n_s_FlowSequenceStartToken, __pyx_t_1) < 0) __PYX_ERR(0, 36, __pyx_L1_error)
  23662. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23663. /* "_yaml.pyx":37
  23664. * BlockEndToken = yaml.tokens.BlockEndToken
  23665. * FlowSequenceStartToken = yaml.tokens.FlowSequenceStartToken
  23666. * FlowMappingStartToken = yaml.tokens.FlowMappingStartToken # <<<<<<<<<<<<<<
  23667. * FlowSequenceEndToken = yaml.tokens.FlowSequenceEndToken
  23668. * FlowMappingEndToken = yaml.tokens.FlowMappingEndToken
  23669. */
  23670. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 37, __pyx_L1_error)
  23671. __Pyx_GOTREF(__pyx_t_1);
  23672. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 37, __pyx_L1_error)
  23673. __Pyx_GOTREF(__pyx_t_2);
  23674. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23675. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_FlowMappingStartToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 37, __pyx_L1_error)
  23676. __Pyx_GOTREF(__pyx_t_1);
  23677. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23678. if (PyDict_SetItem(__pyx_d, __pyx_n_s_FlowMappingStartToken, __pyx_t_1) < 0) __PYX_ERR(0, 37, __pyx_L1_error)
  23679. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23680. /* "_yaml.pyx":38
  23681. * FlowSequenceStartToken = yaml.tokens.FlowSequenceStartToken
  23682. * FlowMappingStartToken = yaml.tokens.FlowMappingStartToken
  23683. * FlowSequenceEndToken = yaml.tokens.FlowSequenceEndToken # <<<<<<<<<<<<<<
  23684. * FlowMappingEndToken = yaml.tokens.FlowMappingEndToken
  23685. * KeyToken = yaml.tokens.KeyToken
  23686. */
  23687. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 38, __pyx_L1_error)
  23688. __Pyx_GOTREF(__pyx_t_1);
  23689. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 38, __pyx_L1_error)
  23690. __Pyx_GOTREF(__pyx_t_2);
  23691. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23692. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_FlowSequenceEndToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 38, __pyx_L1_error)
  23693. __Pyx_GOTREF(__pyx_t_1);
  23694. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23695. if (PyDict_SetItem(__pyx_d, __pyx_n_s_FlowSequenceEndToken, __pyx_t_1) < 0) __PYX_ERR(0, 38, __pyx_L1_error)
  23696. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23697. /* "_yaml.pyx":39
  23698. * FlowMappingStartToken = yaml.tokens.FlowMappingStartToken
  23699. * FlowSequenceEndToken = yaml.tokens.FlowSequenceEndToken
  23700. * FlowMappingEndToken = yaml.tokens.FlowMappingEndToken # <<<<<<<<<<<<<<
  23701. * KeyToken = yaml.tokens.KeyToken
  23702. * ValueToken = yaml.tokens.ValueToken
  23703. */
  23704. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 39, __pyx_L1_error)
  23705. __Pyx_GOTREF(__pyx_t_1);
  23706. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 39, __pyx_L1_error)
  23707. __Pyx_GOTREF(__pyx_t_2);
  23708. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23709. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_FlowMappingEndToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 39, __pyx_L1_error)
  23710. __Pyx_GOTREF(__pyx_t_1);
  23711. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23712. if (PyDict_SetItem(__pyx_d, __pyx_n_s_FlowMappingEndToken, __pyx_t_1) < 0) __PYX_ERR(0, 39, __pyx_L1_error)
  23713. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23714. /* "_yaml.pyx":40
  23715. * FlowSequenceEndToken = yaml.tokens.FlowSequenceEndToken
  23716. * FlowMappingEndToken = yaml.tokens.FlowMappingEndToken
  23717. * KeyToken = yaml.tokens.KeyToken # <<<<<<<<<<<<<<
  23718. * ValueToken = yaml.tokens.ValueToken
  23719. * BlockEntryToken = yaml.tokens.BlockEntryToken
  23720. */
  23721. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 40, __pyx_L1_error)
  23722. __Pyx_GOTREF(__pyx_t_1);
  23723. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 40, __pyx_L1_error)
  23724. __Pyx_GOTREF(__pyx_t_2);
  23725. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23726. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_KeyToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 40, __pyx_L1_error)
  23727. __Pyx_GOTREF(__pyx_t_1);
  23728. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23729. if (PyDict_SetItem(__pyx_d, __pyx_n_s_KeyToken, __pyx_t_1) < 0) __PYX_ERR(0, 40, __pyx_L1_error)
  23730. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23731. /* "_yaml.pyx":41
  23732. * FlowMappingEndToken = yaml.tokens.FlowMappingEndToken
  23733. * KeyToken = yaml.tokens.KeyToken
  23734. * ValueToken = yaml.tokens.ValueToken # <<<<<<<<<<<<<<
  23735. * BlockEntryToken = yaml.tokens.BlockEntryToken
  23736. * FlowEntryToken = yaml.tokens.FlowEntryToken
  23737. */
  23738. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 41, __pyx_L1_error)
  23739. __Pyx_GOTREF(__pyx_t_1);
  23740. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 41, __pyx_L1_error)
  23741. __Pyx_GOTREF(__pyx_t_2);
  23742. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23743. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_ValueToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 41, __pyx_L1_error)
  23744. __Pyx_GOTREF(__pyx_t_1);
  23745. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23746. if (PyDict_SetItem(__pyx_d, __pyx_n_s_ValueToken, __pyx_t_1) < 0) __PYX_ERR(0, 41, __pyx_L1_error)
  23747. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23748. /* "_yaml.pyx":42
  23749. * KeyToken = yaml.tokens.KeyToken
  23750. * ValueToken = yaml.tokens.ValueToken
  23751. * BlockEntryToken = yaml.tokens.BlockEntryToken # <<<<<<<<<<<<<<
  23752. * FlowEntryToken = yaml.tokens.FlowEntryToken
  23753. * AliasToken = yaml.tokens.AliasToken
  23754. */
  23755. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 42, __pyx_L1_error)
  23756. __Pyx_GOTREF(__pyx_t_1);
  23757. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 42, __pyx_L1_error)
  23758. __Pyx_GOTREF(__pyx_t_2);
  23759. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23760. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_BlockEntryToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 42, __pyx_L1_error)
  23761. __Pyx_GOTREF(__pyx_t_1);
  23762. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23763. if (PyDict_SetItem(__pyx_d, __pyx_n_s_BlockEntryToken, __pyx_t_1) < 0) __PYX_ERR(0, 42, __pyx_L1_error)
  23764. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23765. /* "_yaml.pyx":43
  23766. * ValueToken = yaml.tokens.ValueToken
  23767. * BlockEntryToken = yaml.tokens.BlockEntryToken
  23768. * FlowEntryToken = yaml.tokens.FlowEntryToken # <<<<<<<<<<<<<<
  23769. * AliasToken = yaml.tokens.AliasToken
  23770. * AnchorToken = yaml.tokens.AnchorToken
  23771. */
  23772. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 43, __pyx_L1_error)
  23773. __Pyx_GOTREF(__pyx_t_1);
  23774. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 43, __pyx_L1_error)
  23775. __Pyx_GOTREF(__pyx_t_2);
  23776. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23777. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_FlowEntryToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 43, __pyx_L1_error)
  23778. __Pyx_GOTREF(__pyx_t_1);
  23779. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23780. if (PyDict_SetItem(__pyx_d, __pyx_n_s_FlowEntryToken, __pyx_t_1) < 0) __PYX_ERR(0, 43, __pyx_L1_error)
  23781. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23782. /* "_yaml.pyx":44
  23783. * BlockEntryToken = yaml.tokens.BlockEntryToken
  23784. * FlowEntryToken = yaml.tokens.FlowEntryToken
  23785. * AliasToken = yaml.tokens.AliasToken # <<<<<<<<<<<<<<
  23786. * AnchorToken = yaml.tokens.AnchorToken
  23787. * TagToken = yaml.tokens.TagToken
  23788. */
  23789. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 44, __pyx_L1_error)
  23790. __Pyx_GOTREF(__pyx_t_1);
  23791. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 44, __pyx_L1_error)
  23792. __Pyx_GOTREF(__pyx_t_2);
  23793. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23794. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_AliasToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 44, __pyx_L1_error)
  23795. __Pyx_GOTREF(__pyx_t_1);
  23796. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23797. if (PyDict_SetItem(__pyx_d, __pyx_n_s_AliasToken, __pyx_t_1) < 0) __PYX_ERR(0, 44, __pyx_L1_error)
  23798. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23799. /* "_yaml.pyx":45
  23800. * FlowEntryToken = yaml.tokens.FlowEntryToken
  23801. * AliasToken = yaml.tokens.AliasToken
  23802. * AnchorToken = yaml.tokens.AnchorToken # <<<<<<<<<<<<<<
  23803. * TagToken = yaml.tokens.TagToken
  23804. * ScalarToken = yaml.tokens.ScalarToken
  23805. */
  23806. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 45, __pyx_L1_error)
  23807. __Pyx_GOTREF(__pyx_t_1);
  23808. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 45, __pyx_L1_error)
  23809. __Pyx_GOTREF(__pyx_t_2);
  23810. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23811. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_AnchorToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 45, __pyx_L1_error)
  23812. __Pyx_GOTREF(__pyx_t_1);
  23813. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23814. if (PyDict_SetItem(__pyx_d, __pyx_n_s_AnchorToken, __pyx_t_1) < 0) __PYX_ERR(0, 45, __pyx_L1_error)
  23815. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23816. /* "_yaml.pyx":46
  23817. * AliasToken = yaml.tokens.AliasToken
  23818. * AnchorToken = yaml.tokens.AnchorToken
  23819. * TagToken = yaml.tokens.TagToken # <<<<<<<<<<<<<<
  23820. * ScalarToken = yaml.tokens.ScalarToken
  23821. *
  23822. */
  23823. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 46, __pyx_L1_error)
  23824. __Pyx_GOTREF(__pyx_t_1);
  23825. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 46, __pyx_L1_error)
  23826. __Pyx_GOTREF(__pyx_t_2);
  23827. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23828. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_TagToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 46, __pyx_L1_error)
  23829. __Pyx_GOTREF(__pyx_t_1);
  23830. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23831. if (PyDict_SetItem(__pyx_d, __pyx_n_s_TagToken, __pyx_t_1) < 0) __PYX_ERR(0, 46, __pyx_L1_error)
  23832. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23833. /* "_yaml.pyx":47
  23834. * AnchorToken = yaml.tokens.AnchorToken
  23835. * TagToken = yaml.tokens.TagToken
  23836. * ScalarToken = yaml.tokens.ScalarToken # <<<<<<<<<<<<<<
  23837. *
  23838. * StreamStartEvent = yaml.events.StreamStartEvent
  23839. */
  23840. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 47, __pyx_L1_error)
  23841. __Pyx_GOTREF(__pyx_t_1);
  23842. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_tokens); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 47, __pyx_L1_error)
  23843. __Pyx_GOTREF(__pyx_t_2);
  23844. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23845. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_ScalarToken); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 47, __pyx_L1_error)
  23846. __Pyx_GOTREF(__pyx_t_1);
  23847. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23848. if (PyDict_SetItem(__pyx_d, __pyx_n_s_ScalarToken, __pyx_t_1) < 0) __PYX_ERR(0, 47, __pyx_L1_error)
  23849. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23850. /* "_yaml.pyx":49
  23851. * ScalarToken = yaml.tokens.ScalarToken
  23852. *
  23853. * StreamStartEvent = yaml.events.StreamStartEvent # <<<<<<<<<<<<<<
  23854. * StreamEndEvent = yaml.events.StreamEndEvent
  23855. * DocumentStartEvent = yaml.events.DocumentStartEvent
  23856. */
  23857. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 49, __pyx_L1_error)
  23858. __Pyx_GOTREF(__pyx_t_1);
  23859. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_events); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 49, __pyx_L1_error)
  23860. __Pyx_GOTREF(__pyx_t_2);
  23861. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23862. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_StreamStartEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 49, __pyx_L1_error)
  23863. __Pyx_GOTREF(__pyx_t_1);
  23864. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23865. if (PyDict_SetItem(__pyx_d, __pyx_n_s_StreamStartEvent, __pyx_t_1) < 0) __PYX_ERR(0, 49, __pyx_L1_error)
  23866. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23867. /* "_yaml.pyx":50
  23868. *
  23869. * StreamStartEvent = yaml.events.StreamStartEvent
  23870. * StreamEndEvent = yaml.events.StreamEndEvent # <<<<<<<<<<<<<<
  23871. * DocumentStartEvent = yaml.events.DocumentStartEvent
  23872. * DocumentEndEvent = yaml.events.DocumentEndEvent
  23873. */
  23874. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 50, __pyx_L1_error)
  23875. __Pyx_GOTREF(__pyx_t_1);
  23876. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_events); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 50, __pyx_L1_error)
  23877. __Pyx_GOTREF(__pyx_t_2);
  23878. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23879. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_StreamEndEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 50, __pyx_L1_error)
  23880. __Pyx_GOTREF(__pyx_t_1);
  23881. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23882. if (PyDict_SetItem(__pyx_d, __pyx_n_s_StreamEndEvent, __pyx_t_1) < 0) __PYX_ERR(0, 50, __pyx_L1_error)
  23883. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23884. /* "_yaml.pyx":51
  23885. * StreamStartEvent = yaml.events.StreamStartEvent
  23886. * StreamEndEvent = yaml.events.StreamEndEvent
  23887. * DocumentStartEvent = yaml.events.DocumentStartEvent # <<<<<<<<<<<<<<
  23888. * DocumentEndEvent = yaml.events.DocumentEndEvent
  23889. * AliasEvent = yaml.events.AliasEvent
  23890. */
  23891. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 51, __pyx_L1_error)
  23892. __Pyx_GOTREF(__pyx_t_1);
  23893. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_events); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 51, __pyx_L1_error)
  23894. __Pyx_GOTREF(__pyx_t_2);
  23895. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23896. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_DocumentStartEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 51, __pyx_L1_error)
  23897. __Pyx_GOTREF(__pyx_t_1);
  23898. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23899. if (PyDict_SetItem(__pyx_d, __pyx_n_s_DocumentStartEvent, __pyx_t_1) < 0) __PYX_ERR(0, 51, __pyx_L1_error)
  23900. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23901. /* "_yaml.pyx":52
  23902. * StreamEndEvent = yaml.events.StreamEndEvent
  23903. * DocumentStartEvent = yaml.events.DocumentStartEvent
  23904. * DocumentEndEvent = yaml.events.DocumentEndEvent # <<<<<<<<<<<<<<
  23905. * AliasEvent = yaml.events.AliasEvent
  23906. * ScalarEvent = yaml.events.ScalarEvent
  23907. */
  23908. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 52, __pyx_L1_error)
  23909. __Pyx_GOTREF(__pyx_t_1);
  23910. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_events); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 52, __pyx_L1_error)
  23911. __Pyx_GOTREF(__pyx_t_2);
  23912. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23913. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_DocumentEndEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 52, __pyx_L1_error)
  23914. __Pyx_GOTREF(__pyx_t_1);
  23915. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23916. if (PyDict_SetItem(__pyx_d, __pyx_n_s_DocumentEndEvent, __pyx_t_1) < 0) __PYX_ERR(0, 52, __pyx_L1_error)
  23917. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23918. /* "_yaml.pyx":53
  23919. * DocumentStartEvent = yaml.events.DocumentStartEvent
  23920. * DocumentEndEvent = yaml.events.DocumentEndEvent
  23921. * AliasEvent = yaml.events.AliasEvent # <<<<<<<<<<<<<<
  23922. * ScalarEvent = yaml.events.ScalarEvent
  23923. * SequenceStartEvent = yaml.events.SequenceStartEvent
  23924. */
  23925. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 53, __pyx_L1_error)
  23926. __Pyx_GOTREF(__pyx_t_1);
  23927. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_events); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 53, __pyx_L1_error)
  23928. __Pyx_GOTREF(__pyx_t_2);
  23929. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23930. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_AliasEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 53, __pyx_L1_error)
  23931. __Pyx_GOTREF(__pyx_t_1);
  23932. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23933. if (PyDict_SetItem(__pyx_d, __pyx_n_s_AliasEvent, __pyx_t_1) < 0) __PYX_ERR(0, 53, __pyx_L1_error)
  23934. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23935. /* "_yaml.pyx":54
  23936. * DocumentEndEvent = yaml.events.DocumentEndEvent
  23937. * AliasEvent = yaml.events.AliasEvent
  23938. * ScalarEvent = yaml.events.ScalarEvent # <<<<<<<<<<<<<<
  23939. * SequenceStartEvent = yaml.events.SequenceStartEvent
  23940. * SequenceEndEvent = yaml.events.SequenceEndEvent
  23941. */
  23942. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 54, __pyx_L1_error)
  23943. __Pyx_GOTREF(__pyx_t_1);
  23944. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_events); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 54, __pyx_L1_error)
  23945. __Pyx_GOTREF(__pyx_t_2);
  23946. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23947. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_ScalarEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 54, __pyx_L1_error)
  23948. __Pyx_GOTREF(__pyx_t_1);
  23949. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23950. if (PyDict_SetItem(__pyx_d, __pyx_n_s_ScalarEvent, __pyx_t_1) < 0) __PYX_ERR(0, 54, __pyx_L1_error)
  23951. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23952. /* "_yaml.pyx":55
  23953. * AliasEvent = yaml.events.AliasEvent
  23954. * ScalarEvent = yaml.events.ScalarEvent
  23955. * SequenceStartEvent = yaml.events.SequenceStartEvent # <<<<<<<<<<<<<<
  23956. * SequenceEndEvent = yaml.events.SequenceEndEvent
  23957. * MappingStartEvent = yaml.events.MappingStartEvent
  23958. */
  23959. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 55, __pyx_L1_error)
  23960. __Pyx_GOTREF(__pyx_t_1);
  23961. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_events); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 55, __pyx_L1_error)
  23962. __Pyx_GOTREF(__pyx_t_2);
  23963. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23964. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_SequenceStartEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 55, __pyx_L1_error)
  23965. __Pyx_GOTREF(__pyx_t_1);
  23966. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23967. if (PyDict_SetItem(__pyx_d, __pyx_n_s_SequenceStartEvent, __pyx_t_1) < 0) __PYX_ERR(0, 55, __pyx_L1_error)
  23968. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23969. /* "_yaml.pyx":56
  23970. * ScalarEvent = yaml.events.ScalarEvent
  23971. * SequenceStartEvent = yaml.events.SequenceStartEvent
  23972. * SequenceEndEvent = yaml.events.SequenceEndEvent # <<<<<<<<<<<<<<
  23973. * MappingStartEvent = yaml.events.MappingStartEvent
  23974. * MappingEndEvent = yaml.events.MappingEndEvent
  23975. */
  23976. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 56, __pyx_L1_error)
  23977. __Pyx_GOTREF(__pyx_t_1);
  23978. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_events); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 56, __pyx_L1_error)
  23979. __Pyx_GOTREF(__pyx_t_2);
  23980. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23981. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_SequenceEndEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 56, __pyx_L1_error)
  23982. __Pyx_GOTREF(__pyx_t_1);
  23983. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  23984. if (PyDict_SetItem(__pyx_d, __pyx_n_s_SequenceEndEvent, __pyx_t_1) < 0) __PYX_ERR(0, 56, __pyx_L1_error)
  23985. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23986. /* "_yaml.pyx":57
  23987. * SequenceStartEvent = yaml.events.SequenceStartEvent
  23988. * SequenceEndEvent = yaml.events.SequenceEndEvent
  23989. * MappingStartEvent = yaml.events.MappingStartEvent # <<<<<<<<<<<<<<
  23990. * MappingEndEvent = yaml.events.MappingEndEvent
  23991. *
  23992. */
  23993. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 57, __pyx_L1_error)
  23994. __Pyx_GOTREF(__pyx_t_1);
  23995. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_events); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 57, __pyx_L1_error)
  23996. __Pyx_GOTREF(__pyx_t_2);
  23997. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  23998. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_MappingStartEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 57, __pyx_L1_error)
  23999. __Pyx_GOTREF(__pyx_t_1);
  24000. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  24001. if (PyDict_SetItem(__pyx_d, __pyx_n_s_MappingStartEvent, __pyx_t_1) < 0) __PYX_ERR(0, 57, __pyx_L1_error)
  24002. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  24003. /* "_yaml.pyx":58
  24004. * SequenceEndEvent = yaml.events.SequenceEndEvent
  24005. * MappingStartEvent = yaml.events.MappingStartEvent
  24006. * MappingEndEvent = yaml.events.MappingEndEvent # <<<<<<<<<<<<<<
  24007. *
  24008. * ScalarNode = yaml.nodes.ScalarNode
  24009. */
  24010. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 58, __pyx_L1_error)
  24011. __Pyx_GOTREF(__pyx_t_1);
  24012. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_events); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 58, __pyx_L1_error)
  24013. __Pyx_GOTREF(__pyx_t_2);
  24014. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  24015. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_MappingEndEvent); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 58, __pyx_L1_error)
  24016. __Pyx_GOTREF(__pyx_t_1);
  24017. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  24018. if (PyDict_SetItem(__pyx_d, __pyx_n_s_MappingEndEvent, __pyx_t_1) < 0) __PYX_ERR(0, 58, __pyx_L1_error)
  24019. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  24020. /* "_yaml.pyx":60
  24021. * MappingEndEvent = yaml.events.MappingEndEvent
  24022. *
  24023. * ScalarNode = yaml.nodes.ScalarNode # <<<<<<<<<<<<<<
  24024. * SequenceNode = yaml.nodes.SequenceNode
  24025. * MappingNode = yaml.nodes.MappingNode
  24026. */
  24027. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 60, __pyx_L1_error)
  24028. __Pyx_GOTREF(__pyx_t_1);
  24029. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_nodes); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 60, __pyx_L1_error)
  24030. __Pyx_GOTREF(__pyx_t_2);
  24031. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  24032. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_ScalarNode); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 60, __pyx_L1_error)
  24033. __Pyx_GOTREF(__pyx_t_1);
  24034. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  24035. if (PyDict_SetItem(__pyx_d, __pyx_n_s_ScalarNode, __pyx_t_1) < 0) __PYX_ERR(0, 60, __pyx_L1_error)
  24036. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  24037. /* "_yaml.pyx":61
  24038. *
  24039. * ScalarNode = yaml.nodes.ScalarNode
  24040. * SequenceNode = yaml.nodes.SequenceNode # <<<<<<<<<<<<<<
  24041. * MappingNode = yaml.nodes.MappingNode
  24042. *
  24043. */
  24044. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 61, __pyx_L1_error)
  24045. __Pyx_GOTREF(__pyx_t_1);
  24046. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_nodes); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 61, __pyx_L1_error)
  24047. __Pyx_GOTREF(__pyx_t_2);
  24048. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  24049. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_SequenceNode); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 61, __pyx_L1_error)
  24050. __Pyx_GOTREF(__pyx_t_1);
  24051. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  24052. if (PyDict_SetItem(__pyx_d, __pyx_n_s_SequenceNode, __pyx_t_1) < 0) __PYX_ERR(0, 61, __pyx_L1_error)
  24053. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  24054. /* "_yaml.pyx":62
  24055. * ScalarNode = yaml.nodes.ScalarNode
  24056. * SequenceNode = yaml.nodes.SequenceNode
  24057. * MappingNode = yaml.nodes.MappingNode # <<<<<<<<<<<<<<
  24058. *
  24059. * cdef class Mark:
  24060. */
  24061. __Pyx_GetModuleGlobalName(__pyx_t_1, __pyx_n_s_yaml); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 62, __pyx_L1_error)
  24062. __Pyx_GOTREF(__pyx_t_1);
  24063. __pyx_t_2 = __Pyx_PyObject_GetAttrStr(__pyx_t_1, __pyx_n_s_nodes); if (unlikely(!__pyx_t_2)) __PYX_ERR(0, 62, __pyx_L1_error)
  24064. __Pyx_GOTREF(__pyx_t_2);
  24065. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  24066. __pyx_t_1 = __Pyx_PyObject_GetAttrStr(__pyx_t_2, __pyx_n_s_MappingNode); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 62, __pyx_L1_error)
  24067. __Pyx_GOTREF(__pyx_t_1);
  24068. __Pyx_DECREF(__pyx_t_2); __pyx_t_2 = 0;
  24069. if (PyDict_SetItem(__pyx_d, __pyx_n_s_MappingNode, __pyx_t_1) < 0) __PYX_ERR(0, 62, __pyx_L1_error)
  24070. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  24071. /* "(tree fragment)":1
  24072. * def __pyx_unpickle_Mark(__pyx_type, long __pyx_checksum, __pyx_state): # <<<<<<<<<<<<<<
  24073. * cdef object __pyx_PickleError
  24074. * cdef object __pyx_result
  24075. */
  24076. __pyx_t_1 = PyCFunction_NewEx(&__pyx_mdef_5_yaml_5__pyx_unpickle_Mark, NULL, __pyx_n_s_yaml_2); if (unlikely(!__pyx_t_1)) __PYX_ERR(1, 1, __pyx_L1_error)
  24077. __Pyx_GOTREF(__pyx_t_1);
  24078. if (PyDict_SetItem(__pyx_d, __pyx_n_s_pyx_unpickle_Mark, __pyx_t_1) < 0) __PYX_ERR(1, 1, __pyx_L1_error)
  24079. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  24080. /* "_yaml.pyx":2
  24081. *
  24082. * import yaml # <<<<<<<<<<<<<<
  24083. *
  24084. * def get_version_string():
  24085. */
  24086. __pyx_t_1 = __Pyx_PyDict_NewPresized(0); if (unlikely(!__pyx_t_1)) __PYX_ERR(0, 2, __pyx_L1_error)
  24087. __Pyx_GOTREF(__pyx_t_1);
  24088. if (PyDict_SetItem(__pyx_d, __pyx_n_s_test, __pyx_t_1) < 0) __PYX_ERR(0, 2, __pyx_L1_error)
  24089. __Pyx_DECREF(__pyx_t_1); __pyx_t_1 = 0;
  24090. /*--- Wrapped vars code ---*/
  24091. goto __pyx_L0;
  24092. __pyx_L1_error:;
  24093. __Pyx_XDECREF(__pyx_t_1);
  24094. __Pyx_XDECREF(__pyx_t_2);
  24095. if (__pyx_m) {
  24096. if (__pyx_d) {
  24097. __Pyx_AddTraceback("init _yaml", __pyx_clineno, __pyx_lineno, __pyx_filename);
  24098. }
  24099. Py_CLEAR(__pyx_m);
  24100. } else if (!PyErr_Occurred()) {
  24101. PyErr_SetString(PyExc_ImportError, "init _yaml");
  24102. }
  24103. __pyx_L0:;
  24104. __Pyx_RefNannyFinishContext();
  24105. #if CYTHON_PEP489_MULTI_PHASE_INIT
  24106. return (__pyx_m != NULL) ? 0 : -1;
  24107. #elif PY_MAJOR_VERSION >= 3
  24108. return __pyx_m;
  24109. #else
  24110. return;
  24111. #endif
  24112. }
  24113. /* --- Runtime support code --- */
  24114. /* Refnanny */
  24115. #if CYTHON_REFNANNY
  24116. static __Pyx_RefNannyAPIStruct *__Pyx_RefNannyImportAPI(const char *modname) {
  24117. PyObject *m = NULL, *p = NULL;
  24118. void *r = NULL;
  24119. m = PyImport_ImportModule(modname);
  24120. if (!m) goto end;
  24121. p = PyObject_GetAttrString(m, "RefNannyAPI");
  24122. if (!p) goto end;
  24123. r = PyLong_AsVoidPtr(p);
  24124. end:
  24125. Py_XDECREF(p);
  24126. Py_XDECREF(m);
  24127. return (__Pyx_RefNannyAPIStruct *)r;
  24128. }
  24129. #endif
  24130. /* PyObjectGetAttrStr */
  24131. #if CYTHON_USE_TYPE_SLOTS
  24132. static CYTHON_INLINE PyObject* __Pyx_PyObject_GetAttrStr(PyObject* obj, PyObject* attr_name) {
  24133. PyTypeObject* tp = Py_TYPE(obj);
  24134. if (likely(tp->tp_getattro))
  24135. return tp->tp_getattro(obj, attr_name);
  24136. #if PY_MAJOR_VERSION < 3
  24137. if (likely(tp->tp_getattr))
  24138. return tp->tp_getattr(obj, PyString_AS_STRING(attr_name));
  24139. #endif
  24140. return PyObject_GetAttr(obj, attr_name);
  24141. }
  24142. #endif
  24143. /* GetBuiltinName */
  24144. static PyObject *__Pyx_GetBuiltinName(PyObject *name) {
  24145. PyObject* result = __Pyx_PyObject_GetAttrStr(__pyx_b, name);
  24146. if (unlikely(!result)) {
  24147. PyErr_Format(PyExc_NameError,
  24148. #if PY_MAJOR_VERSION >= 3
  24149. "name '%U' is not defined", name);
  24150. #else
  24151. "name '%.200s' is not defined", PyString_AS_STRING(name));
  24152. #endif
  24153. }
  24154. return result;
  24155. }
  24156. /* RaiseArgTupleInvalid */
  24157. static void __Pyx_RaiseArgtupleInvalid(
  24158. const char* func_name,
  24159. int exact,
  24160. Py_ssize_t num_min,
  24161. Py_ssize_t num_max,
  24162. Py_ssize_t num_found)
  24163. {
  24164. Py_ssize_t num_expected;
  24165. const char *more_or_less;
  24166. if (num_found < num_min) {
  24167. num_expected = num_min;
  24168. more_or_less = "at least";
  24169. } else {
  24170. num_expected = num_max;
  24171. more_or_less = "at most";
  24172. }
  24173. if (exact) {
  24174. more_or_less = "exactly";
  24175. }
  24176. PyErr_Format(PyExc_TypeError,
  24177. "%.200s() takes %.8s %" CYTHON_FORMAT_SSIZE_T "d positional argument%.1s (%" CYTHON_FORMAT_SSIZE_T "d given)",
  24178. func_name, more_or_less, num_expected,
  24179. (num_expected == 1) ? "" : "s", num_found);
  24180. }
  24181. /* RaiseDoubleKeywords */
  24182. static void __Pyx_RaiseDoubleKeywordsError(
  24183. const char* func_name,
  24184. PyObject* kw_name)
  24185. {
  24186. PyErr_Format(PyExc_TypeError,
  24187. #if PY_MAJOR_VERSION >= 3
  24188. "%s() got multiple values for keyword argument '%U'", func_name, kw_name);
  24189. #else
  24190. "%s() got multiple values for keyword argument '%s'", func_name,
  24191. PyString_AsString(kw_name));
  24192. #endif
  24193. }
  24194. /* ParseKeywords */
  24195. static int __Pyx_ParseOptionalKeywords(
  24196. PyObject *kwds,
  24197. PyObject **argnames[],
  24198. PyObject *kwds2,
  24199. PyObject *values[],
  24200. Py_ssize_t num_pos_args,
  24201. const char* function_name)
  24202. {
  24203. PyObject *key = 0, *value = 0;
  24204. Py_ssize_t pos = 0;
  24205. PyObject*** name;
  24206. PyObject*** first_kw_arg = argnames + num_pos_args;
  24207. while (PyDict_Next(kwds, &pos, &key, &value)) {
  24208. name = first_kw_arg;
  24209. while (*name && (**name != key)) name++;
  24210. if (*name) {
  24211. values[name-argnames] = value;
  24212. continue;
  24213. }
  24214. name = first_kw_arg;
  24215. #if PY_MAJOR_VERSION < 3
  24216. if (likely(PyString_CheckExact(key)) || likely(PyString_Check(key))) {
  24217. while (*name) {
  24218. if ((CYTHON_COMPILING_IN_PYPY || PyString_GET_SIZE(**name) == PyString_GET_SIZE(key))
  24219. && _PyString_Eq(**name, key)) {
  24220. values[name-argnames] = value;
  24221. break;
  24222. }
  24223. name++;
  24224. }
  24225. if (*name) continue;
  24226. else {
  24227. PyObject*** argname = argnames;
  24228. while (argname != first_kw_arg) {
  24229. if ((**argname == key) || (
  24230. (CYTHON_COMPILING_IN_PYPY || PyString_GET_SIZE(**argname) == PyString_GET_SIZE(key))
  24231. && _PyString_Eq(**argname, key))) {
  24232. goto arg_passed_twice;
  24233. }
  24234. argname++;
  24235. }
  24236. }
  24237. } else
  24238. #endif
  24239. if (likely(PyUnicode_Check(key))) {
  24240. while (*name) {
  24241. int cmp = (**name == key) ? 0 :
  24242. #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION >= 3
  24243. (PyUnicode_GET_SIZE(**name) != PyUnicode_GET_SIZE(key)) ? 1 :
  24244. #endif
  24245. PyUnicode_Compare(**name, key);
  24246. if (cmp < 0 && unlikely(PyErr_Occurred())) goto bad;
  24247. if (cmp == 0) {
  24248. values[name-argnames] = value;
  24249. break;
  24250. }
  24251. name++;
  24252. }
  24253. if (*name) continue;
  24254. else {
  24255. PyObject*** argname = argnames;
  24256. while (argname != first_kw_arg) {
  24257. int cmp = (**argname == key) ? 0 :
  24258. #if !CYTHON_COMPILING_IN_PYPY && PY_MAJOR_VERSION >= 3
  24259. (PyUnicode_GET_SIZE(**argname) != PyUnicode_GET_SIZE(key)) ? 1 :
  24260. #endif
  24261. PyUnicode_Compare(**argname, key);
  24262. if (cmp < 0 && unlikely(PyErr_Occurred())) goto bad;
  24263. if (cmp == 0) goto arg_passed_twice;
  24264. argname++;
  24265. }
  24266. }
  24267. } else
  24268. goto invalid_keyword_type;
  24269. if (kwds2) {
  24270. if (unlikely(PyDict_SetItem(kwds2, key, value))) goto bad;
  24271. } else {
  24272. goto invalid_keyword;
  24273. }
  24274. }
  24275. return 0;
  24276. arg_passed_twice:
  24277. __Pyx_RaiseDoubleKeywordsError(function_name, key);
  24278. goto bad;
  24279. invalid_keyword_type:
  24280. PyErr_Format(PyExc_TypeError,
  24281. "%.200s() keywords must be strings", function_name);
  24282. goto bad;
  24283. invalid_keyword:
  24284. PyErr_Format(PyExc_TypeError,
  24285. #if PY_MAJOR_VERSION < 3
  24286. "%.200s() got an unexpected keyword argument '%.200s'",
  24287. function_name, PyString_AsString(key));
  24288. #else
  24289. "%s() got an unexpected keyword argument '%U'",
  24290. function_name, key);
  24291. #endif
  24292. bad:
  24293. return -1;
  24294. }
  24295. /* PyErrExceptionMatches */
  24296. #if CYTHON_FAST_THREAD_STATE
  24297. static int __Pyx_PyErr_ExceptionMatchesTuple(PyObject *exc_type, PyObject *tuple) {
  24298. Py_ssize_t i, n;
  24299. n = PyTuple_GET_SIZE(tuple);
  24300. #if PY_MAJOR_VERSION >= 3
  24301. for (i=0; i<n; i++) {
  24302. if (exc_type == PyTuple_GET_ITEM(tuple, i)) return 1;
  24303. }
  24304. #endif
  24305. for (i=0; i<n; i++) {
  24306. if (__Pyx_PyErr_GivenExceptionMatches(exc_type, PyTuple_GET_ITEM(tuple, i))) return 1;
  24307. }
  24308. return 0;
  24309. }
  24310. static CYTHON_INLINE int __Pyx_PyErr_ExceptionMatchesInState(PyThreadState* tstate, PyObject* err) {
  24311. PyObject *exc_type = tstate->curexc_type;
  24312. if (exc_type == err) return 1;
  24313. if (unlikely(!exc_type)) return 0;
  24314. if (unlikely(PyTuple_Check(err)))
  24315. return __Pyx_PyErr_ExceptionMatchesTuple(exc_type, err);
  24316. return __Pyx_PyErr_GivenExceptionMatches(exc_type, err);
  24317. }
  24318. #endif
  24319. /* PyErrFetchRestore */
  24320. #if CYTHON_FAST_THREAD_STATE
  24321. static CYTHON_INLINE void __Pyx_ErrRestoreInState(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb) {
  24322. PyObject *tmp_type, *tmp_value, *tmp_tb;
  24323. tmp_type = tstate->curexc_type;
  24324. tmp_value = tstate->curexc_value;
  24325. tmp_tb = tstate->curexc_traceback;
  24326. tstate->curexc_type = type;
  24327. tstate->curexc_value = value;
  24328. tstate->curexc_traceback = tb;
  24329. Py_XDECREF(tmp_type);
  24330. Py_XDECREF(tmp_value);
  24331. Py_XDECREF(tmp_tb);
  24332. }
  24333. static CYTHON_INLINE void __Pyx_ErrFetchInState(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) {
  24334. *type = tstate->curexc_type;
  24335. *value = tstate->curexc_value;
  24336. *tb = tstate->curexc_traceback;
  24337. tstate->curexc_type = 0;
  24338. tstate->curexc_value = 0;
  24339. tstate->curexc_traceback = 0;
  24340. }
  24341. #endif
  24342. /* GetAttr */
  24343. static CYTHON_INLINE PyObject *__Pyx_GetAttr(PyObject *o, PyObject *n) {
  24344. #if CYTHON_USE_TYPE_SLOTS
  24345. #if PY_MAJOR_VERSION >= 3
  24346. if (likely(PyUnicode_Check(n)))
  24347. #else
  24348. if (likely(PyString_Check(n)))
  24349. #endif
  24350. return __Pyx_PyObject_GetAttrStr(o, n);
  24351. #endif
  24352. return PyObject_GetAttr(o, n);
  24353. }
  24354. /* GetAttr3 */
  24355. static PyObject *__Pyx_GetAttr3Default(PyObject *d) {
  24356. __Pyx_PyThreadState_declare
  24357. __Pyx_PyThreadState_assign
  24358. if (unlikely(!__Pyx_PyErr_ExceptionMatches(PyExc_AttributeError)))
  24359. return NULL;
  24360. __Pyx_PyErr_Clear();
  24361. Py_INCREF(d);
  24362. return d;
  24363. }
  24364. static CYTHON_INLINE PyObject *__Pyx_GetAttr3(PyObject *o, PyObject *n, PyObject *d) {
  24365. PyObject *r = __Pyx_GetAttr(o, n);
  24366. return (likely(r)) ? r : __Pyx_GetAttr3Default(d);
  24367. }
  24368. /* PyDictVersioning */
  24369. #if CYTHON_USE_DICT_VERSIONS && CYTHON_USE_TYPE_SLOTS
  24370. static CYTHON_INLINE PY_UINT64_T __Pyx_get_tp_dict_version(PyObject *obj) {
  24371. PyObject *dict = Py_TYPE(obj)->tp_dict;
  24372. return likely(dict) ? __PYX_GET_DICT_VERSION(dict) : 0;
  24373. }
  24374. static CYTHON_INLINE PY_UINT64_T __Pyx_get_object_dict_version(PyObject *obj) {
  24375. PyObject **dictptr = NULL;
  24376. Py_ssize_t offset = Py_TYPE(obj)->tp_dictoffset;
  24377. if (offset) {
  24378. #if CYTHON_COMPILING_IN_CPYTHON
  24379. dictptr = (likely(offset > 0)) ? (PyObject **) ((char *)obj + offset) : _PyObject_GetDictPtr(obj);
  24380. #else
  24381. dictptr = _PyObject_GetDictPtr(obj);
  24382. #endif
  24383. }
  24384. return (dictptr && *dictptr) ? __PYX_GET_DICT_VERSION(*dictptr) : 0;
  24385. }
  24386. static CYTHON_INLINE int __Pyx_object_dict_version_matches(PyObject* obj, PY_UINT64_T tp_dict_version, PY_UINT64_T obj_dict_version) {
  24387. PyObject *dict = Py_TYPE(obj)->tp_dict;
  24388. if (unlikely(!dict) || unlikely(tp_dict_version != __PYX_GET_DICT_VERSION(dict)))
  24389. return 0;
  24390. return obj_dict_version == __Pyx_get_object_dict_version(obj);
  24391. }
  24392. #endif
  24393. /* GetModuleGlobalName */
  24394. #if CYTHON_USE_DICT_VERSIONS
  24395. static PyObject *__Pyx__GetModuleGlobalName(PyObject *name, PY_UINT64_T *dict_version, PyObject **dict_cached_value)
  24396. #else
  24397. static CYTHON_INLINE PyObject *__Pyx__GetModuleGlobalName(PyObject *name)
  24398. #endif
  24399. {
  24400. PyObject *result;
  24401. #if !CYTHON_AVOID_BORROWED_REFS
  24402. #if CYTHON_COMPILING_IN_CPYTHON && PY_VERSION_HEX >= 0x030500A1
  24403. result = _PyDict_GetItem_KnownHash(__pyx_d, name, ((PyASCIIObject *) name)->hash);
  24404. __PYX_UPDATE_DICT_CACHE(__pyx_d, result, *dict_cached_value, *dict_version)
  24405. if (likely(result)) {
  24406. return __Pyx_NewRef(result);
  24407. } else if (unlikely(PyErr_Occurred())) {
  24408. return NULL;
  24409. }
  24410. #else
  24411. result = PyDict_GetItem(__pyx_d, name);
  24412. __PYX_UPDATE_DICT_CACHE(__pyx_d, result, *dict_cached_value, *dict_version)
  24413. if (likely(result)) {
  24414. return __Pyx_NewRef(result);
  24415. }
  24416. #endif
  24417. #else
  24418. result = PyObject_GetItem(__pyx_d, name);
  24419. __PYX_UPDATE_DICT_CACHE(__pyx_d, result, *dict_cached_value, *dict_version)
  24420. if (likely(result)) {
  24421. return __Pyx_NewRef(result);
  24422. }
  24423. PyErr_Clear();
  24424. #endif
  24425. return __Pyx_GetBuiltinName(name);
  24426. }
  24427. /* GetTopmostException */
  24428. #if CYTHON_USE_EXC_INFO_STACK
  24429. static _PyErr_StackItem *
  24430. __Pyx_PyErr_GetTopmostException(PyThreadState *tstate)
  24431. {
  24432. _PyErr_StackItem *exc_info = tstate->exc_info;
  24433. while ((exc_info->exc_type == NULL || exc_info->exc_type == Py_None) &&
  24434. exc_info->previous_item != NULL)
  24435. {
  24436. exc_info = exc_info->previous_item;
  24437. }
  24438. return exc_info;
  24439. }
  24440. #endif
  24441. /* SaveResetException */
  24442. #if CYTHON_FAST_THREAD_STATE
  24443. static CYTHON_INLINE void __Pyx__ExceptionSave(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb) {
  24444. #if CYTHON_USE_EXC_INFO_STACK
  24445. _PyErr_StackItem *exc_info = __Pyx_PyErr_GetTopmostException(tstate);
  24446. *type = exc_info->exc_type;
  24447. *value = exc_info->exc_value;
  24448. *tb = exc_info->exc_traceback;
  24449. #else
  24450. *type = tstate->exc_type;
  24451. *value = tstate->exc_value;
  24452. *tb = tstate->exc_traceback;
  24453. #endif
  24454. Py_XINCREF(*type);
  24455. Py_XINCREF(*value);
  24456. Py_XINCREF(*tb);
  24457. }
  24458. static CYTHON_INLINE void __Pyx__ExceptionReset(PyThreadState *tstate, PyObject *type, PyObject *value, PyObject *tb) {
  24459. PyObject *tmp_type, *tmp_value, *tmp_tb;
  24460. #if CYTHON_USE_EXC_INFO_STACK
  24461. _PyErr_StackItem *exc_info = tstate->exc_info;
  24462. tmp_type = exc_info->exc_type;
  24463. tmp_value = exc_info->exc_value;
  24464. tmp_tb = exc_info->exc_traceback;
  24465. exc_info->exc_type = type;
  24466. exc_info->exc_value = value;
  24467. exc_info->exc_traceback = tb;
  24468. #else
  24469. tmp_type = tstate->exc_type;
  24470. tmp_value = tstate->exc_value;
  24471. tmp_tb = tstate->exc_traceback;
  24472. tstate->exc_type = type;
  24473. tstate->exc_value = value;
  24474. tstate->exc_traceback = tb;
  24475. #endif
  24476. Py_XDECREF(tmp_type);
  24477. Py_XDECREF(tmp_value);
  24478. Py_XDECREF(tmp_tb);
  24479. }
  24480. #endif
  24481. /* GetException */
  24482. #if CYTHON_FAST_THREAD_STATE
  24483. static int __Pyx__GetException(PyThreadState *tstate, PyObject **type, PyObject **value, PyObject **tb)
  24484. #else
  24485. static int __Pyx_GetException(PyObject **type, PyObject **value, PyObject **tb)
  24486. #endif
  24487. {
  24488. PyObject *local_type, *local_value, *local_tb;
  24489. #if CYTHON_FAST_THREAD_STATE
  24490. PyObject *tmp_type, *tmp_value, *tmp_tb;
  24491. local_type = tstate->curexc_type;
  24492. local_value = tstate->curexc_value;
  24493. local_tb = tstate->curexc_traceback;
  24494. tstate->curexc_type = 0;
  24495. tstate->curexc_value = 0;
  24496. tstate->curexc_traceback = 0;
  24497. #else
  24498. PyErr_Fetch(&local_type, &local_value, &local_tb);
  24499. #endif
  24500. PyErr_NormalizeException(&local_type, &local_value, &local_tb);
  24501. #if CYTHON_FAST_THREAD_STATE
  24502. if (unlikely(tstate->curexc_type))
  24503. #else
  24504. if (unlikely(PyErr_Occurred()))
  24505. #endif
  24506. goto bad;
  24507. #if PY_MAJOR_VERSION >= 3
  24508. if (local_tb) {
  24509. if (unlikely(PyException_SetTraceback(local_value, local_tb) < 0))
  24510. goto bad;
  24511. }
  24512. #endif
  24513. Py_XINCREF(local_tb);
  24514. Py_XINCREF(local_type);
  24515. Py_XINCREF(local_value);
  24516. *type = local_type;
  24517. *value = local_value;
  24518. *tb = local_tb;
  24519. #if CYTHON_FAST_THREAD_STATE
  24520. #if CYTHON_USE_EXC_INFO_STACK
  24521. {
  24522. _PyErr_StackItem *exc_info = tstate->exc_info;
  24523. tmp_type = exc_info->exc_type;
  24524. tmp_value = exc_info->exc_value;
  24525. tmp_tb = exc_info->exc_traceback;
  24526. exc_info->exc_type = local_type;
  24527. exc_info->exc_value = local_value;
  24528. exc_info->exc_traceback = local_tb;
  24529. }
  24530. #else
  24531. tmp_type = tstate->exc_type;
  24532. tmp_value = tstate->exc_value;
  24533. tmp_tb = tstate->exc_traceback;
  24534. tstate->exc_type = local_type;
  24535. tstate->exc_value = local_value;
  24536. tstate->exc_traceback = local_tb;
  24537. #endif
  24538. Py_XDECREF(tmp_type);
  24539. Py_XDECREF(tmp_value);
  24540. Py_XDECREF(tmp_tb);
  24541. #else
  24542. PyErr_SetExcInfo(local_type, local_value, local_tb);
  24543. #endif
  24544. return 0;
  24545. bad:
  24546. *type = 0;
  24547. *value = 0;
  24548. *tb = 0;
  24549. Py_XDECREF(local_type);
  24550. Py_XDECREF(local_value);
  24551. Py_XDECREF(local_tb);
  24552. return -1;
  24553. }
  24554. /* PyObjectCall */
  24555. #if CYTHON_COMPILING_IN_CPYTHON
  24556. static CYTHON_INLINE PyObject* __Pyx_PyObject_Call(PyObject *func, PyObject *arg, PyObject *kw) {
  24557. PyObject *result;
  24558. ternaryfunc call = func->ob_type->tp_call;
  24559. if (unlikely(!call))
  24560. return PyObject_Call(func, arg, kw);
  24561. if (unlikely(Py_EnterRecursiveCall((char*)" while calling a Python object")))
  24562. return NULL;
  24563. result = (*call)(func, arg, kw);
  24564. Py_LeaveRecursiveCall();
  24565. if (unlikely(!result) && unlikely(!PyErr_Occurred())) {
  24566. PyErr_SetString(
  24567. PyExc_SystemError,
  24568. "NULL result without error in PyObject_Call");
  24569. }
  24570. return result;
  24571. }
  24572. #endif
  24573. /* RaiseException */
  24574. #if PY_MAJOR_VERSION < 3
  24575. static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb,
  24576. CYTHON_UNUSED PyObject *cause) {
  24577. __Pyx_PyThreadState_declare
  24578. Py_XINCREF(type);
  24579. if (!value || value == Py_None)
  24580. value = NULL;
  24581. else
  24582. Py_INCREF(value);
  24583. if (!tb || tb == Py_None)
  24584. tb = NULL;
  24585. else {
  24586. Py_INCREF(tb);
  24587. if (!PyTraceBack_Check(tb)) {
  24588. PyErr_SetString(PyExc_TypeError,
  24589. "raise: arg 3 must be a traceback or None");
  24590. goto raise_error;
  24591. }
  24592. }
  24593. if (PyType_Check(type)) {
  24594. #if CYTHON_COMPILING_IN_PYPY
  24595. if (!value) {
  24596. Py_INCREF(Py_None);
  24597. value = Py_None;
  24598. }
  24599. #endif
  24600. PyErr_NormalizeException(&type, &value, &tb);
  24601. } else {
  24602. if (value) {
  24603. PyErr_SetString(PyExc_TypeError,
  24604. "instance exception may not have a separate value");
  24605. goto raise_error;
  24606. }
  24607. value = type;
  24608. type = (PyObject*) Py_TYPE(type);
  24609. Py_INCREF(type);
  24610. if (!PyType_IsSubtype((PyTypeObject *)type, (PyTypeObject *)PyExc_BaseException)) {
  24611. PyErr_SetString(PyExc_TypeError,
  24612. "raise: exception class must be a subclass of BaseException");
  24613. goto raise_error;
  24614. }
  24615. }
  24616. __Pyx_PyThreadState_assign
  24617. __Pyx_ErrRestore(type, value, tb);
  24618. return;
  24619. raise_error:
  24620. Py_XDECREF(value);
  24621. Py_XDECREF(type);
  24622. Py_XDECREF(tb);
  24623. return;
  24624. }
  24625. #else
  24626. static void __Pyx_Raise(PyObject *type, PyObject *value, PyObject *tb, PyObject *cause) {
  24627. PyObject* owned_instance = NULL;
  24628. if (tb == Py_None) {
  24629. tb = 0;
  24630. } else if (tb && !PyTraceBack_Check(tb)) {
  24631. PyErr_SetString(PyExc_TypeError,
  24632. "raise: arg 3 must be a traceback or None");
  24633. goto bad;
  24634. }
  24635. if (value == Py_None)
  24636. value = 0;
  24637. if (PyExceptionInstance_Check(type)) {
  24638. if (value) {
  24639. PyErr_SetString(PyExc_TypeError,
  24640. "instance exception may not have a separate value");
  24641. goto bad;
  24642. }
  24643. value = type;
  24644. type = (PyObject*) Py_TYPE(value);
  24645. } else if (PyExceptionClass_Check(type)) {
  24646. PyObject *instance_class = NULL;
  24647. if (value && PyExceptionInstance_Check(value)) {
  24648. instance_class = (PyObject*) Py_TYPE(value);
  24649. if (instance_class != type) {
  24650. int is_subclass = PyObject_IsSubclass(instance_class, type);
  24651. if (!is_subclass) {
  24652. instance_class = NULL;
  24653. } else if (unlikely(is_subclass == -1)) {
  24654. goto bad;
  24655. } else {
  24656. type = instance_class;
  24657. }
  24658. }
  24659. }
  24660. if (!instance_class) {
  24661. PyObject *args;
  24662. if (!value)
  24663. args = PyTuple_New(0);
  24664. else if (PyTuple_Check(value)) {
  24665. Py_INCREF(value);
  24666. args = value;
  24667. } else
  24668. args = PyTuple_Pack(1, value);
  24669. if (!args)
  24670. goto bad;
  24671. owned_instance = PyObject_Call(type, args, NULL);
  24672. Py_DECREF(args);
  24673. if (!owned_instance)
  24674. goto bad;
  24675. value = owned_instance;
  24676. if (!PyExceptionInstance_Check(value)) {
  24677. PyErr_Format(PyExc_TypeError,
  24678. "calling %R should have returned an instance of "
  24679. "BaseException, not %R",
  24680. type, Py_TYPE(value));
  24681. goto bad;
  24682. }
  24683. }
  24684. } else {
  24685. PyErr_SetString(PyExc_TypeError,
  24686. "raise: exception class must be a subclass of BaseException");
  24687. goto bad;
  24688. }
  24689. if (cause) {
  24690. PyObject *fixed_cause;
  24691. if (cause == Py_None) {
  24692. fixed_cause = NULL;
  24693. } else if (PyExceptionClass_Check(cause)) {
  24694. fixed_cause = PyObject_CallObject(cause, NULL);
  24695. if (fixed_cause == NULL)
  24696. goto bad;
  24697. } else if (PyExceptionInstance_Check(cause)) {
  24698. fixed_cause = cause;
  24699. Py_INCREF(fixed_cause);
  24700. } else {
  24701. PyErr_SetString(PyExc_TypeError,
  24702. "exception causes must derive from "
  24703. "BaseException");
  24704. goto bad;
  24705. }
  24706. PyException_SetCause(value, fixed_cause);
  24707. }
  24708. PyErr_SetObject(type, value);
  24709. if (tb) {
  24710. #if CYTHON_COMPILING_IN_PYPY
  24711. PyObject *tmp_type, *tmp_value, *tmp_tb;
  24712. PyErr_Fetch(&tmp_type, &tmp_value, &tmp_tb);
  24713. Py_INCREF(tb);
  24714. PyErr_Restore(tmp_type, tmp_value, tb);
  24715. Py_XDECREF(tmp_tb);
  24716. #else
  24717. PyThreadState *tstate = __Pyx_PyThreadState_Current;
  24718. PyObject* tmp_tb = tstate->curexc_traceback;
  24719. if (tb != tmp_tb) {
  24720. Py_INCREF(tb);
  24721. tstate->curexc_traceback = tb;
  24722. Py_XDECREF(tmp_tb);
  24723. }
  24724. #endif
  24725. }
  24726. bad:
  24727. Py_XDECREF(owned_instance);
  24728. return;
  24729. }
  24730. #endif
  24731. /* PyFunctionFastCall */
  24732. #if CYTHON_FAST_PYCALL
  24733. static PyObject* __Pyx_PyFunction_FastCallNoKw(PyCodeObject *co, PyObject **args, Py_ssize_t na,
  24734. PyObject *globals) {
  24735. PyFrameObject *f;
  24736. PyThreadState *tstate = __Pyx_PyThreadState_Current;
  24737. PyObject **fastlocals;
  24738. Py_ssize_t i;
  24739. PyObject *result;
  24740. assert(globals != NULL);
  24741. /* XXX Perhaps we should create a specialized
  24742. PyFrame_New() that doesn't take locals, but does
  24743. take builtins without sanity checking them.
  24744. */
  24745. assert(tstate != NULL);
  24746. f = PyFrame_New(tstate, co, globals, NULL);
  24747. if (f == NULL) {
  24748. return NULL;
  24749. }
  24750. fastlocals = __Pyx_PyFrame_GetLocalsplus(f);
  24751. for (i = 0; i < na; i++) {
  24752. Py_INCREF(*args);
  24753. fastlocals[i] = *args++;
  24754. }
  24755. result = PyEval_EvalFrameEx(f,0);
  24756. ++tstate->recursion_depth;
  24757. Py_DECREF(f);
  24758. --tstate->recursion_depth;
  24759. return result;
  24760. }
  24761. #if 1 || PY_VERSION_HEX < 0x030600B1
  24762. static PyObject *__Pyx_PyFunction_FastCallDict(PyObject *func, PyObject **args, Py_ssize_t nargs, PyObject *kwargs) {
  24763. PyCodeObject *co = (PyCodeObject *)PyFunction_GET_CODE(func);
  24764. PyObject *globals = PyFunction_GET_GLOBALS(func);
  24765. PyObject *argdefs = PyFunction_GET_DEFAULTS(func);
  24766. PyObject *closure;
  24767. #if PY_MAJOR_VERSION >= 3
  24768. PyObject *kwdefs;
  24769. #endif
  24770. PyObject *kwtuple, **k;
  24771. PyObject **d;
  24772. Py_ssize_t nd;
  24773. Py_ssize_t nk;
  24774. PyObject *result;
  24775. assert(kwargs == NULL || PyDict_Check(kwargs));
  24776. nk = kwargs ? PyDict_Size(kwargs) : 0;
  24777. if (Py_EnterRecursiveCall((char*)" while calling a Python object")) {
  24778. return NULL;
  24779. }
  24780. if (
  24781. #if PY_MAJOR_VERSION >= 3
  24782. co->co_kwonlyargcount == 0 &&
  24783. #endif
  24784. likely(kwargs == NULL || nk == 0) &&
  24785. co->co_flags == (CO_OPTIMIZED | CO_NEWLOCALS | CO_NOFREE)) {
  24786. if (argdefs == NULL && co->co_argcount == nargs) {
  24787. result = __Pyx_PyFunction_FastCallNoKw(co, args, nargs, globals);
  24788. goto done;
  24789. }
  24790. else if (nargs == 0 && argdefs != NULL
  24791. && co->co_argcount == Py_SIZE(argdefs)) {
  24792. /* function called with no arguments, but all parameters have
  24793. a default value: use default values as arguments .*/
  24794. args = &PyTuple_GET_ITEM(argdefs, 0);
  24795. result =__Pyx_PyFunction_FastCallNoKw(co, args, Py_SIZE(argdefs), globals);
  24796. goto done;
  24797. }
  24798. }
  24799. if (kwargs != NULL) {
  24800. Py_ssize_t pos, i;
  24801. kwtuple = PyTuple_New(2 * nk);
  24802. if (kwtuple == NULL) {
  24803. result = NULL;
  24804. goto done;
  24805. }
  24806. k = &PyTuple_GET_ITEM(kwtuple, 0);
  24807. pos = i = 0;
  24808. while (PyDict_Next(kwargs, &pos, &k[i], &k[i+1])) {
  24809. Py_INCREF(k[i]);
  24810. Py_INCREF(k[i+1]);
  24811. i += 2;
  24812. }
  24813. nk = i / 2;
  24814. }
  24815. else {
  24816. kwtuple = NULL;
  24817. k = NULL;
  24818. }
  24819. closure = PyFunction_GET_CLOSURE(func);
  24820. #if PY_MAJOR_VERSION >= 3
  24821. kwdefs = PyFunction_GET_KW_DEFAULTS(func);
  24822. #endif
  24823. if (argdefs != NULL) {
  24824. d = &PyTuple_GET_ITEM(argdefs, 0);
  24825. nd = Py_SIZE(argdefs);
  24826. }
  24827. else {
  24828. d = NULL;
  24829. nd = 0;
  24830. }
  24831. #if PY_MAJOR_VERSION >= 3
  24832. result = PyEval_EvalCodeEx((PyObject*)co, globals, (PyObject *)NULL,
  24833. args, (int)nargs,
  24834. k, (int)nk,
  24835. d, (int)nd, kwdefs, closure);
  24836. #else
  24837. result = PyEval_EvalCodeEx(co, globals, (PyObject *)NULL,
  24838. args, (int)nargs,
  24839. k, (int)nk,
  24840. d, (int)nd, closure);
  24841. #endif
  24842. Py_XDECREF(kwtuple);
  24843. done:
  24844. Py_LeaveRecursiveCall();
  24845. return result;
  24846. }
  24847. #endif
  24848. #endif
  24849. /* PyCFunctionFastCall */
  24850. #if CYTHON_FAST_PYCCALL
  24851. static CYTHON_INLINE PyObject * __Pyx_PyCFunction_FastCall(PyObject *func_obj, PyObject **args, Py_ssize_t nargs) {
  24852. PyCFunctionObject *func = (PyCFunctionObject*)func_obj;
  24853. PyCFunction meth = PyCFunction_GET_FUNCTION(func);
  24854. PyObject *self = PyCFunction_GET_SELF(func);
  24855. int flags = PyCFunction_GET_FLAGS(func);
  24856. assert(PyCFunction_Check(func));
  24857. assert(METH_FASTCALL == (flags & ~(METH_CLASS | METH_STATIC | METH_COEXIST | METH_KEYWORDS | METH_STACKLESS)));
  24858. assert(nargs >= 0);
  24859. assert(nargs == 0 || args != NULL);
  24860. /* _PyCFunction_FastCallDict() must not be called with an exception set,
  24861. because it may clear it (directly or indirectly) and so the
  24862. caller loses its exception */
  24863. assert(!PyErr_Occurred());
  24864. if ((PY_VERSION_HEX < 0x030700A0) || unlikely(flags & METH_KEYWORDS)) {
  24865. return (*((__Pyx_PyCFunctionFastWithKeywords)(void*)meth)) (self, args, nargs, NULL);
  24866. } else {
  24867. return (*((__Pyx_PyCFunctionFast)(void*)meth)) (self, args, nargs);
  24868. }
  24869. }
  24870. #endif
  24871. /* KeywordStringCheck */
  24872. static int __Pyx_CheckKeywordStrings(
  24873. PyObject *kwdict,
  24874. const char* function_name,
  24875. int kw_allowed)
  24876. {
  24877. PyObject* key = 0;
  24878. Py_ssize_t pos = 0;
  24879. #if CYTHON_COMPILING_IN_PYPY
  24880. if (!kw_allowed && PyDict_Next(kwdict, &pos, &key, 0))
  24881. goto invalid_keyword;
  24882. return 1;
  24883. #else
  24884. while (PyDict_Next(kwdict, &pos, &key, 0)) {
  24885. #if PY_MAJOR_VERSION < 3
  24886. if (unlikely(!PyString_Check(key)))
  24887. #endif
  24888. if (unlikely(!PyUnicode_Check(key)))
  24889. goto invalid_keyword_type;
  24890. }
  24891. if ((!kw_allowed) && unlikely(key))
  24892. goto invalid_keyword;
  24893. return 1;
  24894. invalid_keyword_type:
  24895. PyErr_Format(PyExc_TypeError,
  24896. "%.200s() keywords must be strings", function_name);
  24897. return 0;
  24898. #endif
  24899. invalid_keyword:
  24900. PyErr_Format(PyExc_TypeError,
  24901. #if PY_MAJOR_VERSION < 3
  24902. "%.200s() got an unexpected keyword argument '%.200s'",
  24903. function_name, PyString_AsString(key));
  24904. #else
  24905. "%s() got an unexpected keyword argument '%U'",
  24906. function_name, key);
  24907. #endif
  24908. return 0;
  24909. }
  24910. /* GetItemInt */
  24911. static PyObject *__Pyx_GetItemInt_Generic(PyObject *o, PyObject* j) {
  24912. PyObject *r;
  24913. if (!j) return NULL;
  24914. r = PyObject_GetItem(o, j);
  24915. Py_DECREF(j);
  24916. return r;
  24917. }
  24918. static CYTHON_INLINE PyObject *__Pyx_GetItemInt_List_Fast(PyObject *o, Py_ssize_t i,
  24919. CYTHON_NCP_UNUSED int wraparound,
  24920. CYTHON_NCP_UNUSED int boundscheck) {
  24921. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  24922. Py_ssize_t wrapped_i = i;
  24923. if (wraparound & unlikely(i < 0)) {
  24924. wrapped_i += PyList_GET_SIZE(o);
  24925. }
  24926. if ((!boundscheck) || likely(__Pyx_is_valid_index(wrapped_i, PyList_GET_SIZE(o)))) {
  24927. PyObject *r = PyList_GET_ITEM(o, wrapped_i);
  24928. Py_INCREF(r);
  24929. return r;
  24930. }
  24931. return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
  24932. #else
  24933. return PySequence_GetItem(o, i);
  24934. #endif
  24935. }
  24936. static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Tuple_Fast(PyObject *o, Py_ssize_t i,
  24937. CYTHON_NCP_UNUSED int wraparound,
  24938. CYTHON_NCP_UNUSED int boundscheck) {
  24939. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS
  24940. Py_ssize_t wrapped_i = i;
  24941. if (wraparound & unlikely(i < 0)) {
  24942. wrapped_i += PyTuple_GET_SIZE(o);
  24943. }
  24944. if ((!boundscheck) || likely(__Pyx_is_valid_index(wrapped_i, PyTuple_GET_SIZE(o)))) {
  24945. PyObject *r = PyTuple_GET_ITEM(o, wrapped_i);
  24946. Py_INCREF(r);
  24947. return r;
  24948. }
  24949. return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
  24950. #else
  24951. return PySequence_GetItem(o, i);
  24952. #endif
  24953. }
  24954. static CYTHON_INLINE PyObject *__Pyx_GetItemInt_Fast(PyObject *o, Py_ssize_t i, int is_list,
  24955. CYTHON_NCP_UNUSED int wraparound,
  24956. CYTHON_NCP_UNUSED int boundscheck) {
  24957. #if CYTHON_ASSUME_SAFE_MACROS && !CYTHON_AVOID_BORROWED_REFS && CYTHON_USE_TYPE_SLOTS
  24958. if (is_list || PyList_CheckExact(o)) {
  24959. Py_ssize_t n = ((!wraparound) | likely(i >= 0)) ? i : i + PyList_GET_SIZE(o);
  24960. if ((!boundscheck) || (likely(__Pyx_is_valid_index(n, PyList_GET_SIZE(o))))) {
  24961. PyObject *r = PyList_GET_ITEM(o, n);
  24962. Py_INCREF(r);
  24963. return r;
  24964. }
  24965. }
  24966. else if (PyTuple_CheckExact(o)) {
  24967. Py_ssize_t n = ((!wraparound) | likely(i >= 0)) ? i : i + PyTuple_GET_SIZE(o);
  24968. if ((!boundscheck) || likely(__Pyx_is_valid_index(n, PyTuple_GET_SIZE(o)))) {
  24969. PyObject *r = PyTuple_GET_ITEM(o, n);
  24970. Py_INCREF(r);
  24971. return r;
  24972. }
  24973. } else {
  24974. PySequenceMethods *m = Py_TYPE(o)->tp_as_sequence;
  24975. if (likely(m && m->sq_item)) {
  24976. if (wraparound && unlikely(i < 0) && likely(m->sq_length)) {
  24977. Py_ssize_t l = m->sq_length(o);
  24978. if (likely(l >= 0)) {
  24979. i += l;
  24980. } else {
  24981. if (!PyErr_ExceptionMatches(PyExc_OverflowError))
  24982. return NULL;
  24983. PyErr_Clear();
  24984. }
  24985. }
  24986. return m->sq_item(o, i);
  24987. }
  24988. }
  24989. #else
  24990. if (is_list || PySequence_Check(o)) {
  24991. return PySequence_GetItem(o, i);
  24992. }
  24993. #endif
  24994. return __Pyx_GetItemInt_Generic(o, PyInt_FromSsize_t(i));
  24995. }
  24996. /* ObjectGetItem */
  24997. #if CYTHON_USE_TYPE_SLOTS
  24998. static PyObject *__Pyx_PyObject_GetIndex(PyObject *obj, PyObject* index) {
  24999. PyObject *runerr;
  25000. Py_ssize_t key_value;
  25001. PySequenceMethods *m = Py_TYPE(obj)->tp_as_sequence;
  25002. if (unlikely(!(m && m->sq_item))) {
  25003. PyErr_Format(PyExc_TypeError, "'%.200s' object is not subscriptable", Py_TYPE(obj)->tp_name);
  25004. return NULL;
  25005. }
  25006. key_value = __Pyx_PyIndex_AsSsize_t(index);
  25007. if (likely(key_value != -1 || !(runerr = PyErr_Occurred()))) {
  25008. return __Pyx_GetItemInt_Fast(obj, key_value, 0, 1, 1);
  25009. }
  25010. if (PyErr_GivenExceptionMatches(runerr, PyExc_OverflowError)) {
  25011. PyErr_Clear();
  25012. PyErr_Format(PyExc_IndexError, "cannot fit '%.200s' into an index-sized integer", Py_TYPE(index)->tp_name);
  25013. }
  25014. return NULL;
  25015. }
  25016. static PyObject *__Pyx_PyObject_GetItem(PyObject *obj, PyObject* key) {
  25017. PyMappingMethods *m = Py_TYPE(obj)->tp_as_mapping;
  25018. if (likely(m && m->mp_subscript)) {
  25019. return m->mp_subscript(obj, key);
  25020. }
  25021. return __Pyx_PyObject_GetIndex(obj, key);
  25022. }
  25023. #endif
  25024. /* PyObjectCallMethO */
  25025. #if CYTHON_COMPILING_IN_CPYTHON
  25026. static CYTHON_INLINE PyObject* __Pyx_PyObject_CallMethO(PyObject *func, PyObject *arg) {
  25027. PyObject *self, *result;
  25028. PyCFunction cfunc;
  25029. cfunc = PyCFunction_GET_FUNCTION(func);
  25030. self = PyCFunction_GET_SELF(func);
  25031. if (unlikely(Py_EnterRecursiveCall((char*)" while calling a Python object")))
  25032. return NULL;
  25033. result = cfunc(self, arg);
  25034. Py_LeaveRecursiveCall();
  25035. if (unlikely(!result) && unlikely(!PyErr_Occurred())) {
  25036. PyErr_SetString(
  25037. PyExc_SystemError,
  25038. "NULL result without error in PyObject_Call");
  25039. }
  25040. return result;
  25041. }
  25042. #endif
  25043. /* PyObjectCallNoArg */
  25044. #if CYTHON_COMPILING_IN_CPYTHON
  25045. static CYTHON_INLINE PyObject* __Pyx_PyObject_CallNoArg(PyObject *func) {
  25046. #if CYTHON_FAST_PYCALL
  25047. if (PyFunction_Check(func)) {
  25048. return __Pyx_PyFunction_FastCall(func, NULL, 0);
  25049. }
  25050. #endif
  25051. #ifdef __Pyx_CyFunction_USED
  25052. if (likely(PyCFunction_Check(func) || __Pyx_CyFunction_Check(func)))
  25053. #else
  25054. if (likely(PyCFunction_Check(func)))
  25055. #endif
  25056. {
  25057. if (likely(PyCFunction_GET_FLAGS(func) & METH_NOARGS)) {
  25058. return __Pyx_PyObject_CallMethO(func, NULL);
  25059. }
  25060. }
  25061. return __Pyx_PyObject_Call(func, __pyx_empty_tuple, NULL);
  25062. }
  25063. #endif
  25064. /* PyObjectCallOneArg */
  25065. #if CYTHON_COMPILING_IN_CPYTHON
  25066. static PyObject* __Pyx__PyObject_CallOneArg(PyObject *func, PyObject *arg) {
  25067. PyObject *result;
  25068. PyObject *args = PyTuple_New(1);
  25069. if (unlikely(!args)) return NULL;
  25070. Py_INCREF(arg);
  25071. PyTuple_SET_ITEM(args, 0, arg);
  25072. result = __Pyx_PyObject_Call(func, args, NULL);
  25073. Py_DECREF(args);
  25074. return result;
  25075. }
  25076. static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg) {
  25077. #if CYTHON_FAST_PYCALL
  25078. if (PyFunction_Check(func)) {
  25079. return __Pyx_PyFunction_FastCall(func, &arg, 1);
  25080. }
  25081. #endif
  25082. if (likely(PyCFunction_Check(func))) {
  25083. if (likely(PyCFunction_GET_FLAGS(func) & METH_O)) {
  25084. return __Pyx_PyObject_CallMethO(func, arg);
  25085. #if CYTHON_FAST_PYCCALL
  25086. } else if (PyCFunction_GET_FLAGS(func) & METH_FASTCALL) {
  25087. return __Pyx_PyCFunction_FastCall(func, &arg, 1);
  25088. #endif
  25089. }
  25090. }
  25091. return __Pyx__PyObject_CallOneArg(func, arg);
  25092. }
  25093. #else
  25094. static CYTHON_INLINE PyObject* __Pyx_PyObject_CallOneArg(PyObject *func, PyObject *arg) {
  25095. PyObject *result;
  25096. PyObject *args = PyTuple_Pack(1, arg);
  25097. if (unlikely(!args)) return NULL;
  25098. result = __Pyx_PyObject_Call(func, args, NULL);
  25099. Py_DECREF(args);
  25100. return result;
  25101. }
  25102. #endif
  25103. /* None */
  25104. static CYTHON_INLINE void __Pyx_RaiseUnboundLocalError(const char *varname) {
  25105. PyErr_Format(PyExc_UnboundLocalError, "local variable '%s' referenced before assignment", varname);
  25106. }
  25107. /* PyObjectSetAttrStr */
  25108. #if CYTHON_USE_TYPE_SLOTS
  25109. static CYTHON_INLINE int __Pyx_PyObject_SetAttrStr(PyObject* obj, PyObject* attr_name, PyObject* value) {
  25110. PyTypeObject* tp = Py_TYPE(obj);
  25111. if (likely(tp->tp_setattro))
  25112. return tp->tp_setattro(obj, attr_name, value);
  25113. #if PY_MAJOR_VERSION < 3
  25114. if (likely(tp->tp_setattr))
  25115. return tp->tp_setattr(obj, PyString_AS_STRING(attr_name), value);
  25116. #endif
  25117. return PyObject_SetAttr(obj, attr_name, value);
  25118. }
  25119. #endif
  25120. /* PyObjectCall2Args */
  25121. static CYTHON_UNUSED PyObject* __Pyx_PyObject_Call2Args(PyObject* function, PyObject* arg1, PyObject* arg2) {
  25122. PyObject *args, *result = NULL;
  25123. #if CYTHON_FAST_PYCALL
  25124. if (PyFunction_Check(function)) {
  25125. PyObject *args[2] = {arg1, arg2};
  25126. return __Pyx_PyFunction_FastCall(function, args, 2);
  25127. }
  25128. #endif
  25129. #if CYTHON_FAST_PYCCALL
  25130. if (__Pyx_PyFastCFunction_Check(function)) {
  25131. PyObject *args[2] = {arg1, arg2};
  25132. return __Pyx_PyCFunction_FastCall(function, args, 2);
  25133. }
  25134. #endif
  25135. args = PyTuple_New(2);
  25136. if (unlikely(!args)) goto done;
  25137. Py_INCREF(arg1);
  25138. PyTuple_SET_ITEM(args, 0, arg1);
  25139. Py_INCREF(arg2);
  25140. PyTuple_SET_ITEM(args, 1, arg2);
  25141. Py_INCREF(function);
  25142. result = __Pyx_PyObject_Call(function, args, NULL);
  25143. Py_DECREF(args);
  25144. Py_DECREF(function);
  25145. done:
  25146. return result;
  25147. }
  25148. /* HasAttr */
  25149. static CYTHON_INLINE int __Pyx_HasAttr(PyObject *o, PyObject *n) {
  25150. PyObject *r;
  25151. if (unlikely(!__Pyx_PyBaseString_Check(n))) {
  25152. PyErr_SetString(PyExc_TypeError,
  25153. "hasattr(): attribute name must be string");
  25154. return -1;
  25155. }
  25156. r = __Pyx_GetAttr(o, n);
  25157. if (unlikely(!r)) {
  25158. PyErr_Clear();
  25159. return 0;
  25160. } else {
  25161. Py_DECREF(r);
  25162. return 1;
  25163. }
  25164. }
  25165. /* BytesEquals */
  25166. static CYTHON_INLINE int __Pyx_PyBytes_Equals(PyObject* s1, PyObject* s2, int equals) {
  25167. #if CYTHON_COMPILING_IN_PYPY
  25168. return PyObject_RichCompareBool(s1, s2, equals);
  25169. #else
  25170. if (s1 == s2) {
  25171. return (equals == Py_EQ);
  25172. } else if (PyBytes_CheckExact(s1) & PyBytes_CheckExact(s2)) {
  25173. const char *ps1, *ps2;
  25174. Py_ssize_t length = PyBytes_GET_SIZE(s1);
  25175. if (length != PyBytes_GET_SIZE(s2))
  25176. return (equals == Py_NE);
  25177. ps1 = PyBytes_AS_STRING(s1);
  25178. ps2 = PyBytes_AS_STRING(s2);
  25179. if (ps1[0] != ps2[0]) {
  25180. return (equals == Py_NE);
  25181. } else if (length == 1) {
  25182. return (equals == Py_EQ);
  25183. } else {
  25184. int result;
  25185. #if CYTHON_USE_UNICODE_INTERNALS
  25186. Py_hash_t hash1, hash2;
  25187. hash1 = ((PyBytesObject*)s1)->ob_shash;
  25188. hash2 = ((PyBytesObject*)s2)->ob_shash;
  25189. if (hash1 != hash2 && hash1 != -1 && hash2 != -1) {
  25190. return (equals == Py_NE);
  25191. }
  25192. #endif
  25193. result = memcmp(ps1, ps2, (size_t)length);
  25194. return (equals == Py_EQ) ? (result == 0) : (result != 0);
  25195. }
  25196. } else if ((s1 == Py_None) & PyBytes_CheckExact(s2)) {
  25197. return (equals == Py_NE);
  25198. } else if ((s2 == Py_None) & PyBytes_CheckExact(s1)) {
  25199. return (equals == Py_NE);
  25200. } else {
  25201. int result;
  25202. PyObject* py_result = PyObject_RichCompare(s1, s2, equals);
  25203. if (!py_result)
  25204. return -1;
  25205. result = __Pyx_PyObject_IsTrue(py_result);
  25206. Py_DECREF(py_result);
  25207. return result;
  25208. }
  25209. #endif
  25210. }
  25211. /* UnicodeEquals */
  25212. static CYTHON_INLINE int __Pyx_PyUnicode_Equals(PyObject* s1, PyObject* s2, int equals) {
  25213. #if CYTHON_COMPILING_IN_PYPY
  25214. return PyObject_RichCompareBool(s1, s2, equals);
  25215. #else
  25216. #if PY_MAJOR_VERSION < 3
  25217. PyObject* owned_ref = NULL;
  25218. #endif
  25219. int s1_is_unicode, s2_is_unicode;
  25220. if (s1 == s2) {
  25221. goto return_eq;
  25222. }
  25223. s1_is_unicode = PyUnicode_CheckExact(s1);
  25224. s2_is_unicode = PyUnicode_CheckExact(s2);
  25225. #if PY_MAJOR_VERSION < 3
  25226. if ((s1_is_unicode & (!s2_is_unicode)) && PyString_CheckExact(s2)) {
  25227. owned_ref = PyUnicode_FromObject(s2);
  25228. if (unlikely(!owned_ref))
  25229. return -1;
  25230. s2 = owned_ref;
  25231. s2_is_unicode = 1;
  25232. } else if ((s2_is_unicode & (!s1_is_unicode)) && PyString_CheckExact(s1)) {
  25233. owned_ref = PyUnicode_FromObject(s1);
  25234. if (unlikely(!owned_ref))
  25235. return -1;
  25236. s1 = owned_ref;
  25237. s1_is_unicode = 1;
  25238. } else if (((!s2_is_unicode) & (!s1_is_unicode))) {
  25239. return __Pyx_PyBytes_Equals(s1, s2, equals);
  25240. }
  25241. #endif
  25242. if (s1_is_unicode & s2_is_unicode) {
  25243. Py_ssize_t length;
  25244. int kind;
  25245. void *data1, *data2;
  25246. if (unlikely(__Pyx_PyUnicode_READY(s1) < 0) || unlikely(__Pyx_PyUnicode_READY(s2) < 0))
  25247. return -1;
  25248. length = __Pyx_PyUnicode_GET_LENGTH(s1);
  25249. if (length != __Pyx_PyUnicode_GET_LENGTH(s2)) {
  25250. goto return_ne;
  25251. }
  25252. #if CYTHON_USE_UNICODE_INTERNALS
  25253. {
  25254. Py_hash_t hash1, hash2;
  25255. #if CYTHON_PEP393_ENABLED
  25256. hash1 = ((PyASCIIObject*)s1)->hash;
  25257. hash2 = ((PyASCIIObject*)s2)->hash;
  25258. #else
  25259. hash1 = ((PyUnicodeObject*)s1)->hash;
  25260. hash2 = ((PyUnicodeObject*)s2)->hash;
  25261. #endif
  25262. if (hash1 != hash2 && hash1 != -1 && hash2 != -1) {
  25263. goto return_ne;
  25264. }
  25265. }
  25266. #endif
  25267. kind = __Pyx_PyUnicode_KIND(s1);
  25268. if (kind != __Pyx_PyUnicode_KIND(s2)) {
  25269. goto return_ne;
  25270. }
  25271. data1 = __Pyx_PyUnicode_DATA(s1);
  25272. data2 = __Pyx_PyUnicode_DATA(s2);
  25273. if (__Pyx_PyUnicode_READ(kind, data1, 0) != __Pyx_PyUnicode_READ(kind, data2, 0)) {
  25274. goto return_ne;
  25275. } else if (length == 1) {
  25276. goto return_eq;
  25277. } else {
  25278. int result = memcmp(data1, data2, (size_t)(length * kind));
  25279. #if PY_MAJOR_VERSION < 3
  25280. Py_XDECREF(owned_ref);
  25281. #endif
  25282. return (equals == Py_EQ) ? (result == 0) : (result != 0);
  25283. }
  25284. } else if ((s1 == Py_None) & s2_is_unicode) {
  25285. goto return_ne;
  25286. } else if ((s2 == Py_None) & s1_is_unicode) {
  25287. goto return_ne;
  25288. } else {
  25289. int result;
  25290. PyObject* py_result = PyObject_RichCompare(s1, s2, equals);
  25291. #if PY_MAJOR_VERSION < 3
  25292. Py_XDECREF(owned_ref);
  25293. #endif
  25294. if (!py_result)
  25295. return -1;
  25296. result = __Pyx_PyObject_IsTrue(py_result);
  25297. Py_DECREF(py_result);
  25298. return result;
  25299. }
  25300. return_eq:
  25301. #if PY_MAJOR_VERSION < 3
  25302. Py_XDECREF(owned_ref);
  25303. #endif
  25304. return (equals == Py_EQ);
  25305. return_ne:
  25306. #if PY_MAJOR_VERSION < 3
  25307. Py_XDECREF(owned_ref);
  25308. #endif
  25309. return (equals == Py_NE);
  25310. #endif
  25311. }
  25312. /* RaiseTooManyValuesToUnpack */
  25313. static CYTHON_INLINE void __Pyx_RaiseTooManyValuesError(Py_ssize_t expected) {
  25314. PyErr_Format(PyExc_ValueError,
  25315. "too many values to unpack (expected %" CYTHON_FORMAT_SSIZE_T "d)", expected);
  25316. }
  25317. /* RaiseNeedMoreValuesToUnpack */
  25318. static CYTHON_INLINE void __Pyx_RaiseNeedMoreValuesError(Py_ssize_t index) {
  25319. PyErr_Format(PyExc_ValueError,
  25320. "need more than %" CYTHON_FORMAT_SSIZE_T "d value%.1s to unpack",
  25321. index, (index == 1) ? "" : "s");
  25322. }
  25323. /* IterFinish */
  25324. static CYTHON_INLINE int __Pyx_IterFinish(void) {
  25325. #if CYTHON_FAST_THREAD_STATE
  25326. PyThreadState *tstate = __Pyx_PyThreadState_Current;
  25327. PyObject* exc_type = tstate->curexc_type;
  25328. if (unlikely(exc_type)) {
  25329. if (likely(__Pyx_PyErr_GivenExceptionMatches(exc_type, PyExc_StopIteration))) {
  25330. PyObject *exc_value, *exc_tb;
  25331. exc_value = tstate->curexc_value;
  25332. exc_tb = tstate->curexc_traceback;
  25333. tstate->curexc_type = 0;
  25334. tstate->curexc_value = 0;
  25335. tstate->curexc_traceback = 0;
  25336. Py_DECREF(exc_type);
  25337. Py_XDECREF(exc_value);
  25338. Py_XDECREF(exc_tb);
  25339. return 0;
  25340. } else {
  25341. return -1;
  25342. }
  25343. }
  25344. return 0;
  25345. #else
  25346. if (unlikely(PyErr_Occurred())) {
  25347. if (likely(PyErr_ExceptionMatches(PyExc_StopIteration))) {
  25348. PyErr_Clear();
  25349. return 0;
  25350. } else {
  25351. return -1;
  25352. }
  25353. }
  25354. return 0;
  25355. #endif
  25356. }
  25357. /* UnpackItemEndCheck */
  25358. static int __Pyx_IternextUnpackEndCheck(PyObject *retval, Py_ssize_t expected) {
  25359. if (unlikely(retval)) {
  25360. Py_DECREF(retval);
  25361. __Pyx_RaiseTooManyValuesError(expected);
  25362. return -1;
  25363. } else {
  25364. return __Pyx_IterFinish();
  25365. }
  25366. return 0;
  25367. }
  25368. /* Import */
  25369. static PyObject *__Pyx_Import(PyObject *name, PyObject *from_list, int level) {
  25370. PyObject *empty_list = 0;
  25371. PyObject *module = 0;
  25372. PyObject *global_dict = 0;
  25373. PyObject *empty_dict = 0;
  25374. PyObject *list;
  25375. #if PY_MAJOR_VERSION < 3
  25376. PyObject *py_import;
  25377. py_import = __Pyx_PyObject_GetAttrStr(__pyx_b, __pyx_n_s_import);
  25378. if (!py_import)
  25379. goto bad;
  25380. #endif
  25381. if (from_list)
  25382. list = from_list;
  25383. else {
  25384. empty_list = PyList_New(0);
  25385. if (!empty_list)
  25386. goto bad;
  25387. list = empty_list;
  25388. }
  25389. global_dict = PyModule_GetDict(__pyx_m);
  25390. if (!global_dict)
  25391. goto bad;
  25392. empty_dict = PyDict_New();
  25393. if (!empty_dict)
  25394. goto bad;
  25395. {
  25396. #if PY_MAJOR_VERSION >= 3
  25397. if (level == -1) {
  25398. if (strchr(__Pyx_MODULE_NAME, '.')) {
  25399. module = PyImport_ImportModuleLevelObject(
  25400. name, global_dict, empty_dict, list, 1);
  25401. if (!module) {
  25402. if (!PyErr_ExceptionMatches(PyExc_ImportError))
  25403. goto bad;
  25404. PyErr_Clear();
  25405. }
  25406. }
  25407. level = 0;
  25408. }
  25409. #endif
  25410. if (!module) {
  25411. #if PY_MAJOR_VERSION < 3
  25412. PyObject *py_level = PyInt_FromLong(level);
  25413. if (!py_level)
  25414. goto bad;
  25415. module = PyObject_CallFunctionObjArgs(py_import,
  25416. name, global_dict, empty_dict, list, py_level, (PyObject *)NULL);
  25417. Py_DECREF(py_level);
  25418. #else
  25419. module = PyImport_ImportModuleLevelObject(
  25420. name, global_dict, empty_dict, list, level);
  25421. #endif
  25422. }
  25423. }
  25424. bad:
  25425. #if PY_MAJOR_VERSION < 3
  25426. Py_XDECREF(py_import);
  25427. #endif
  25428. Py_XDECREF(empty_list);
  25429. Py_XDECREF(empty_dict);
  25430. return module;
  25431. }
  25432. /* ImportFrom */
  25433. static PyObject* __Pyx_ImportFrom(PyObject* module, PyObject* name) {
  25434. PyObject* value = __Pyx_PyObject_GetAttrStr(module, name);
  25435. if (unlikely(!value) && PyErr_ExceptionMatches(PyExc_AttributeError)) {
  25436. PyErr_Format(PyExc_ImportError,
  25437. #if PY_MAJOR_VERSION < 3
  25438. "cannot import name %.230s", PyString_AS_STRING(name));
  25439. #else
  25440. "cannot import name %S", name);
  25441. #endif
  25442. }
  25443. return value;
  25444. }
  25445. /* PyObject_GenericGetAttrNoDict */
  25446. #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
  25447. static PyObject *__Pyx_RaiseGenericGetAttributeError(PyTypeObject *tp, PyObject *attr_name) {
  25448. PyErr_Format(PyExc_AttributeError,
  25449. #if PY_MAJOR_VERSION >= 3
  25450. "'%.50s' object has no attribute '%U'",
  25451. tp->tp_name, attr_name);
  25452. #else
  25453. "'%.50s' object has no attribute '%.400s'",
  25454. tp->tp_name, PyString_AS_STRING(attr_name));
  25455. #endif
  25456. return NULL;
  25457. }
  25458. static CYTHON_INLINE PyObject* __Pyx_PyObject_GenericGetAttrNoDict(PyObject* obj, PyObject* attr_name) {
  25459. PyObject *descr;
  25460. PyTypeObject *tp = Py_TYPE(obj);
  25461. if (unlikely(!PyString_Check(attr_name))) {
  25462. return PyObject_GenericGetAttr(obj, attr_name);
  25463. }
  25464. assert(!tp->tp_dictoffset);
  25465. descr = _PyType_Lookup(tp, attr_name);
  25466. if (unlikely(!descr)) {
  25467. return __Pyx_RaiseGenericGetAttributeError(tp, attr_name);
  25468. }
  25469. Py_INCREF(descr);
  25470. #if PY_MAJOR_VERSION < 3
  25471. if (likely(PyType_HasFeature(Py_TYPE(descr), Py_TPFLAGS_HAVE_CLASS)))
  25472. #endif
  25473. {
  25474. descrgetfunc f = Py_TYPE(descr)->tp_descr_get;
  25475. if (unlikely(f)) {
  25476. PyObject *res = f(descr, obj, (PyObject *)tp);
  25477. Py_DECREF(descr);
  25478. return res;
  25479. }
  25480. }
  25481. return descr;
  25482. }
  25483. #endif
  25484. /* PyObject_GenericGetAttr */
  25485. #if CYTHON_USE_TYPE_SLOTS && CYTHON_USE_PYTYPE_LOOKUP && PY_VERSION_HEX < 0x03070000
  25486. static PyObject* __Pyx_PyObject_GenericGetAttr(PyObject* obj, PyObject* attr_name) {
  25487. if (unlikely(Py_TYPE(obj)->tp_dictoffset)) {
  25488. return PyObject_GenericGetAttr(obj, attr_name);
  25489. }
  25490. return __Pyx_PyObject_GenericGetAttrNoDict(obj, attr_name);
  25491. }
  25492. #endif
  25493. /* SetupReduce */
  25494. static int __Pyx_setup_reduce_is_named(PyObject* meth, PyObject* name) {
  25495. int ret;
  25496. PyObject *name_attr;
  25497. name_attr = __Pyx_PyObject_GetAttrStr(meth, __pyx_n_s_name_2);
  25498. if (likely(name_attr)) {
  25499. ret = PyObject_RichCompareBool(name_attr, name, Py_EQ);
  25500. } else {
  25501. ret = -1;
  25502. }
  25503. if (unlikely(ret < 0)) {
  25504. PyErr_Clear();
  25505. ret = 0;
  25506. }
  25507. Py_XDECREF(name_attr);
  25508. return ret;
  25509. }
  25510. static int __Pyx_setup_reduce(PyObject* type_obj) {
  25511. int ret = 0;
  25512. PyObject *object_reduce = NULL;
  25513. PyObject *object_reduce_ex = NULL;
  25514. PyObject *reduce = NULL;
  25515. PyObject *reduce_ex = NULL;
  25516. PyObject *reduce_cython = NULL;
  25517. PyObject *setstate = NULL;
  25518. PyObject *setstate_cython = NULL;
  25519. #if CYTHON_USE_PYTYPE_LOOKUP
  25520. if (_PyType_Lookup((PyTypeObject*)type_obj, __pyx_n_s_getstate)) goto GOOD;
  25521. #else
  25522. if (PyObject_HasAttr(type_obj, __pyx_n_s_getstate)) goto GOOD;
  25523. #endif
  25524. #if CYTHON_USE_PYTYPE_LOOKUP
  25525. object_reduce_ex = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_reduce_ex); if (!object_reduce_ex) goto BAD;
  25526. #else
  25527. object_reduce_ex = __Pyx_PyObject_GetAttrStr((PyObject*)&PyBaseObject_Type, __pyx_n_s_reduce_ex); if (!object_reduce_ex) goto BAD;
  25528. #endif
  25529. reduce_ex = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce_ex); if (unlikely(!reduce_ex)) goto BAD;
  25530. if (reduce_ex == object_reduce_ex) {
  25531. #if CYTHON_USE_PYTYPE_LOOKUP
  25532. object_reduce = _PyType_Lookup(&PyBaseObject_Type, __pyx_n_s_reduce); if (!object_reduce) goto BAD;
  25533. #else
  25534. object_reduce = __Pyx_PyObject_GetAttrStr((PyObject*)&PyBaseObject_Type, __pyx_n_s_reduce); if (!object_reduce) goto BAD;
  25535. #endif
  25536. reduce = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce); if (unlikely(!reduce)) goto BAD;
  25537. if (reduce == object_reduce || __Pyx_setup_reduce_is_named(reduce, __pyx_n_s_reduce_cython)) {
  25538. reduce_cython = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_reduce_cython); if (unlikely(!reduce_cython)) goto BAD;
  25539. ret = PyDict_SetItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_reduce, reduce_cython); if (unlikely(ret < 0)) goto BAD;
  25540. ret = PyDict_DelItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_reduce_cython); if (unlikely(ret < 0)) goto BAD;
  25541. setstate = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_setstate);
  25542. if (!setstate) PyErr_Clear();
  25543. if (!setstate || __Pyx_setup_reduce_is_named(setstate, __pyx_n_s_setstate_cython)) {
  25544. setstate_cython = __Pyx_PyObject_GetAttrStr(type_obj, __pyx_n_s_setstate_cython); if (unlikely(!setstate_cython)) goto BAD;
  25545. ret = PyDict_SetItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_setstate, setstate_cython); if (unlikely(ret < 0)) goto BAD;
  25546. ret = PyDict_DelItem(((PyTypeObject*)type_obj)->tp_dict, __pyx_n_s_setstate_cython); if (unlikely(ret < 0)) goto BAD;
  25547. }
  25548. PyType_Modified((PyTypeObject*)type_obj);
  25549. }
  25550. }
  25551. goto GOOD;
  25552. BAD:
  25553. if (!PyErr_Occurred())
  25554. PyErr_Format(PyExc_RuntimeError, "Unable to initialize pickling for %s", ((PyTypeObject*)type_obj)->tp_name);
  25555. ret = -1;
  25556. GOOD:
  25557. #if !CYTHON_USE_PYTYPE_LOOKUP
  25558. Py_XDECREF(object_reduce);
  25559. Py_XDECREF(object_reduce_ex);
  25560. #endif
  25561. Py_XDECREF(reduce);
  25562. Py_XDECREF(reduce_ex);
  25563. Py_XDECREF(reduce_cython);
  25564. Py_XDECREF(setstate);
  25565. Py_XDECREF(setstate_cython);
  25566. return ret;
  25567. }
  25568. /* SetVTable */
  25569. static int __Pyx_SetVtable(PyObject *dict, void *vtable) {
  25570. #if PY_VERSION_HEX >= 0x02070000
  25571. PyObject *ob = PyCapsule_New(vtable, 0, 0);
  25572. #else
  25573. PyObject *ob = PyCObject_FromVoidPtr(vtable, 0);
  25574. #endif
  25575. if (!ob)
  25576. goto bad;
  25577. if (PyDict_SetItem(dict, __pyx_n_s_pyx_vtable, ob) < 0)
  25578. goto bad;
  25579. Py_DECREF(ob);
  25580. return 0;
  25581. bad:
  25582. Py_XDECREF(ob);
  25583. return -1;
  25584. }
  25585. /* CLineInTraceback */
  25586. #ifndef CYTHON_CLINE_IN_TRACEBACK
  25587. static int __Pyx_CLineForTraceback(PyThreadState *tstate, int c_line) {
  25588. PyObject *use_cline;
  25589. PyObject *ptype, *pvalue, *ptraceback;
  25590. #if CYTHON_COMPILING_IN_CPYTHON
  25591. PyObject **cython_runtime_dict;
  25592. #endif
  25593. if (unlikely(!__pyx_cython_runtime)) {
  25594. return c_line;
  25595. }
  25596. __Pyx_ErrFetchInState(tstate, &ptype, &pvalue, &ptraceback);
  25597. #if CYTHON_COMPILING_IN_CPYTHON
  25598. cython_runtime_dict = _PyObject_GetDictPtr(__pyx_cython_runtime);
  25599. if (likely(cython_runtime_dict)) {
  25600. __PYX_PY_DICT_LOOKUP_IF_MODIFIED(
  25601. use_cline, *cython_runtime_dict,
  25602. __Pyx_PyDict_GetItemStr(*cython_runtime_dict, __pyx_n_s_cline_in_traceback))
  25603. } else
  25604. #endif
  25605. {
  25606. PyObject *use_cline_obj = __Pyx_PyObject_GetAttrStr(__pyx_cython_runtime, __pyx_n_s_cline_in_traceback);
  25607. if (use_cline_obj) {
  25608. use_cline = PyObject_Not(use_cline_obj) ? Py_False : Py_True;
  25609. Py_DECREF(use_cline_obj);
  25610. } else {
  25611. PyErr_Clear();
  25612. use_cline = NULL;
  25613. }
  25614. }
  25615. if (!use_cline) {
  25616. c_line = 0;
  25617. PyObject_SetAttr(__pyx_cython_runtime, __pyx_n_s_cline_in_traceback, Py_False);
  25618. }
  25619. else if (use_cline == Py_False || (use_cline != Py_True && PyObject_Not(use_cline) != 0)) {
  25620. c_line = 0;
  25621. }
  25622. __Pyx_ErrRestoreInState(tstate, ptype, pvalue, ptraceback);
  25623. return c_line;
  25624. }
  25625. #endif
  25626. /* CodeObjectCache */
  25627. static int __pyx_bisect_code_objects(__Pyx_CodeObjectCacheEntry* entries, int count, int code_line) {
  25628. int start = 0, mid = 0, end = count - 1;
  25629. if (end >= 0 && code_line > entries[end].code_line) {
  25630. return count;
  25631. }
  25632. while (start < end) {
  25633. mid = start + (end - start) / 2;
  25634. if (code_line < entries[mid].code_line) {
  25635. end = mid;
  25636. } else if (code_line > entries[mid].code_line) {
  25637. start = mid + 1;
  25638. } else {
  25639. return mid;
  25640. }
  25641. }
  25642. if (code_line <= entries[mid].code_line) {
  25643. return mid;
  25644. } else {
  25645. return mid + 1;
  25646. }
  25647. }
  25648. static PyCodeObject *__pyx_find_code_object(int code_line) {
  25649. PyCodeObject* code_object;
  25650. int pos;
  25651. if (unlikely(!code_line) || unlikely(!__pyx_code_cache.entries)) {
  25652. return NULL;
  25653. }
  25654. pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line);
  25655. if (unlikely(pos >= __pyx_code_cache.count) || unlikely(__pyx_code_cache.entries[pos].code_line != code_line)) {
  25656. return NULL;
  25657. }
  25658. code_object = __pyx_code_cache.entries[pos].code_object;
  25659. Py_INCREF(code_object);
  25660. return code_object;
  25661. }
  25662. static void __pyx_insert_code_object(int code_line, PyCodeObject* code_object) {
  25663. int pos, i;
  25664. __Pyx_CodeObjectCacheEntry* entries = __pyx_code_cache.entries;
  25665. if (unlikely(!code_line)) {
  25666. return;
  25667. }
  25668. if (unlikely(!entries)) {
  25669. entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Malloc(64*sizeof(__Pyx_CodeObjectCacheEntry));
  25670. if (likely(entries)) {
  25671. __pyx_code_cache.entries = entries;
  25672. __pyx_code_cache.max_count = 64;
  25673. __pyx_code_cache.count = 1;
  25674. entries[0].code_line = code_line;
  25675. entries[0].code_object = code_object;
  25676. Py_INCREF(code_object);
  25677. }
  25678. return;
  25679. }
  25680. pos = __pyx_bisect_code_objects(__pyx_code_cache.entries, __pyx_code_cache.count, code_line);
  25681. if ((pos < __pyx_code_cache.count) && unlikely(__pyx_code_cache.entries[pos].code_line == code_line)) {
  25682. PyCodeObject* tmp = entries[pos].code_object;
  25683. entries[pos].code_object = code_object;
  25684. Py_DECREF(tmp);
  25685. return;
  25686. }
  25687. if (__pyx_code_cache.count == __pyx_code_cache.max_count) {
  25688. int new_max = __pyx_code_cache.max_count + 64;
  25689. entries = (__Pyx_CodeObjectCacheEntry*)PyMem_Realloc(
  25690. __pyx_code_cache.entries, (size_t)new_max*sizeof(__Pyx_CodeObjectCacheEntry));
  25691. if (unlikely(!entries)) {
  25692. return;
  25693. }
  25694. __pyx_code_cache.entries = entries;
  25695. __pyx_code_cache.max_count = new_max;
  25696. }
  25697. for (i=__pyx_code_cache.count; i>pos; i--) {
  25698. entries[i] = entries[i-1];
  25699. }
  25700. entries[pos].code_line = code_line;
  25701. entries[pos].code_object = code_object;
  25702. __pyx_code_cache.count++;
  25703. Py_INCREF(code_object);
  25704. }
  25705. /* AddTraceback */
  25706. #include "compile.h"
  25707. #include "frameobject.h"
  25708. #include "traceback.h"
  25709. static PyCodeObject* __Pyx_CreateCodeObjectForTraceback(
  25710. const char *funcname, int c_line,
  25711. int py_line, const char *filename) {
  25712. PyCodeObject *py_code = 0;
  25713. PyObject *py_srcfile = 0;
  25714. PyObject *py_funcname = 0;
  25715. #if PY_MAJOR_VERSION < 3
  25716. py_srcfile = PyString_FromString(filename);
  25717. #else
  25718. py_srcfile = PyUnicode_FromString(filename);
  25719. #endif
  25720. if (!py_srcfile) goto bad;
  25721. if (c_line) {
  25722. #if PY_MAJOR_VERSION < 3
  25723. py_funcname = PyString_FromFormat( "%s (%s:%d)", funcname, __pyx_cfilenm, c_line);
  25724. #else
  25725. py_funcname = PyUnicode_FromFormat( "%s (%s:%d)", funcname, __pyx_cfilenm, c_line);
  25726. #endif
  25727. }
  25728. else {
  25729. #if PY_MAJOR_VERSION < 3
  25730. py_funcname = PyString_FromString(funcname);
  25731. #else
  25732. py_funcname = PyUnicode_FromString(funcname);
  25733. #endif
  25734. }
  25735. if (!py_funcname) goto bad;
  25736. py_code = __Pyx_PyCode_New(
  25737. 0,
  25738. 0,
  25739. 0,
  25740. 0,
  25741. 0,
  25742. __pyx_empty_bytes, /*PyObject *code,*/
  25743. __pyx_empty_tuple, /*PyObject *consts,*/
  25744. __pyx_empty_tuple, /*PyObject *names,*/
  25745. __pyx_empty_tuple, /*PyObject *varnames,*/
  25746. __pyx_empty_tuple, /*PyObject *freevars,*/
  25747. __pyx_empty_tuple, /*PyObject *cellvars,*/
  25748. py_srcfile, /*PyObject *filename,*/
  25749. py_funcname, /*PyObject *name,*/
  25750. py_line,
  25751. __pyx_empty_bytes /*PyObject *lnotab*/
  25752. );
  25753. Py_DECREF(py_srcfile);
  25754. Py_DECREF(py_funcname);
  25755. return py_code;
  25756. bad:
  25757. Py_XDECREF(py_srcfile);
  25758. Py_XDECREF(py_funcname);
  25759. return NULL;
  25760. }
  25761. static void __Pyx_AddTraceback(const char *funcname, int c_line,
  25762. int py_line, const char *filename) {
  25763. PyCodeObject *py_code = 0;
  25764. PyFrameObject *py_frame = 0;
  25765. PyThreadState *tstate = __Pyx_PyThreadState_Current;
  25766. if (c_line) {
  25767. c_line = __Pyx_CLineForTraceback(tstate, c_line);
  25768. }
  25769. py_code = __pyx_find_code_object(c_line ? -c_line : py_line);
  25770. if (!py_code) {
  25771. py_code = __Pyx_CreateCodeObjectForTraceback(
  25772. funcname, c_line, py_line, filename);
  25773. if (!py_code) goto bad;
  25774. __pyx_insert_code_object(c_line ? -c_line : py_line, py_code);
  25775. }
  25776. py_frame = PyFrame_New(
  25777. tstate, /*PyThreadState *tstate,*/
  25778. py_code, /*PyCodeObject *code,*/
  25779. __pyx_d, /*PyObject *globals,*/
  25780. 0 /*PyObject *locals*/
  25781. );
  25782. if (!py_frame) goto bad;
  25783. __Pyx_PyFrame_SetLineNumber(py_frame, py_line);
  25784. PyTraceBack_Here(py_frame);
  25785. bad:
  25786. Py_XDECREF(py_code);
  25787. Py_XDECREF(py_frame);
  25788. }
  25789. /* CIntFromPyVerify */
  25790. #define __PYX_VERIFY_RETURN_INT(target_type, func_type, func_value)\
  25791. __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 0)
  25792. #define __PYX_VERIFY_RETURN_INT_EXC(target_type, func_type, func_value)\
  25793. __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, 1)
  25794. #define __PYX__VERIFY_RETURN_INT(target_type, func_type, func_value, exc)\
  25795. {\
  25796. func_type value = func_value;\
  25797. if (sizeof(target_type) < sizeof(func_type)) {\
  25798. if (unlikely(value != (func_type) (target_type) value)) {\
  25799. func_type zero = 0;\
  25800. if (exc && unlikely(value == (func_type)-1 && PyErr_Occurred()))\
  25801. return (target_type) -1;\
  25802. if (is_unsigned && unlikely(value < zero))\
  25803. goto raise_neg_overflow;\
  25804. else\
  25805. goto raise_overflow;\
  25806. }\
  25807. }\
  25808. return (target_type) value;\
  25809. }
  25810. /* CIntToPy */
  25811. static CYTHON_INLINE PyObject* __Pyx_PyInt_From_int(int value) {
  25812. const int neg_one = (int) ((int) 0 - (int) 1), const_zero = (int) 0;
  25813. const int is_unsigned = neg_one > const_zero;
  25814. if (is_unsigned) {
  25815. if (sizeof(int) < sizeof(long)) {
  25816. return PyInt_FromLong((long) value);
  25817. } else if (sizeof(int) <= sizeof(unsigned long)) {
  25818. return PyLong_FromUnsignedLong((unsigned long) value);
  25819. #ifdef HAVE_LONG_LONG
  25820. } else if (sizeof(int) <= sizeof(unsigned PY_LONG_LONG)) {
  25821. return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value);
  25822. #endif
  25823. }
  25824. } else {
  25825. if (sizeof(int) <= sizeof(long)) {
  25826. return PyInt_FromLong((long) value);
  25827. #ifdef HAVE_LONG_LONG
  25828. } else if (sizeof(int) <= sizeof(PY_LONG_LONG)) {
  25829. return PyLong_FromLongLong((PY_LONG_LONG) value);
  25830. #endif
  25831. }
  25832. }
  25833. {
  25834. int one = 1; int little = (int)*(unsigned char *)&one;
  25835. unsigned char *bytes = (unsigned char *)&value;
  25836. return _PyLong_FromByteArray(bytes, sizeof(int),
  25837. little, !is_unsigned);
  25838. }
  25839. }
  25840. /* CIntToPy */
  25841. static CYTHON_INLINE PyObject* __Pyx_PyInt_From_long(long value) {
  25842. const long neg_one = (long) ((long) 0 - (long) 1), const_zero = (long) 0;
  25843. const int is_unsigned = neg_one > const_zero;
  25844. if (is_unsigned) {
  25845. if (sizeof(long) < sizeof(long)) {
  25846. return PyInt_FromLong((long) value);
  25847. } else if (sizeof(long) <= sizeof(unsigned long)) {
  25848. return PyLong_FromUnsignedLong((unsigned long) value);
  25849. #ifdef HAVE_LONG_LONG
  25850. } else if (sizeof(long) <= sizeof(unsigned PY_LONG_LONG)) {
  25851. return PyLong_FromUnsignedLongLong((unsigned PY_LONG_LONG) value);
  25852. #endif
  25853. }
  25854. } else {
  25855. if (sizeof(long) <= sizeof(long)) {
  25856. return PyInt_FromLong((long) value);
  25857. #ifdef HAVE_LONG_LONG
  25858. } else if (sizeof(long) <= sizeof(PY_LONG_LONG)) {
  25859. return PyLong_FromLongLong((PY_LONG_LONG) value);
  25860. #endif
  25861. }
  25862. }
  25863. {
  25864. int one = 1; int little = (int)*(unsigned char *)&one;
  25865. unsigned char *bytes = (unsigned char *)&value;
  25866. return _PyLong_FromByteArray(bytes, sizeof(long),
  25867. little, !is_unsigned);
  25868. }
  25869. }
  25870. /* CIntFromPy */
  25871. static CYTHON_INLINE size_t __Pyx_PyInt_As_size_t(PyObject *x) {
  25872. const size_t neg_one = (size_t) ((size_t) 0 - (size_t) 1), const_zero = (size_t) 0;
  25873. const int is_unsigned = neg_one > const_zero;
  25874. #if PY_MAJOR_VERSION < 3
  25875. if (likely(PyInt_Check(x))) {
  25876. if (sizeof(size_t) < sizeof(long)) {
  25877. __PYX_VERIFY_RETURN_INT(size_t, long, PyInt_AS_LONG(x))
  25878. } else {
  25879. long val = PyInt_AS_LONG(x);
  25880. if (is_unsigned && unlikely(val < 0)) {
  25881. goto raise_neg_overflow;
  25882. }
  25883. return (size_t) val;
  25884. }
  25885. } else
  25886. #endif
  25887. if (likely(PyLong_Check(x))) {
  25888. if (is_unsigned) {
  25889. #if CYTHON_USE_PYLONG_INTERNALS
  25890. const digit* digits = ((PyLongObject*)x)->ob_digit;
  25891. switch (Py_SIZE(x)) {
  25892. case 0: return (size_t) 0;
  25893. case 1: __PYX_VERIFY_RETURN_INT(size_t, digit, digits[0])
  25894. case 2:
  25895. if (8 * sizeof(size_t) > 1 * PyLong_SHIFT) {
  25896. if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
  25897. __PYX_VERIFY_RETURN_INT(size_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  25898. } else if (8 * sizeof(size_t) >= 2 * PyLong_SHIFT) {
  25899. return (size_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
  25900. }
  25901. }
  25902. break;
  25903. case 3:
  25904. if (8 * sizeof(size_t) > 2 * PyLong_SHIFT) {
  25905. if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
  25906. __PYX_VERIFY_RETURN_INT(size_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  25907. } else if (8 * sizeof(size_t) >= 3 * PyLong_SHIFT) {
  25908. return (size_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
  25909. }
  25910. }
  25911. break;
  25912. case 4:
  25913. if (8 * sizeof(size_t) > 3 * PyLong_SHIFT) {
  25914. if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
  25915. __PYX_VERIFY_RETURN_INT(size_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  25916. } else if (8 * sizeof(size_t) >= 4 * PyLong_SHIFT) {
  25917. return (size_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
  25918. }
  25919. }
  25920. break;
  25921. }
  25922. #endif
  25923. #if CYTHON_COMPILING_IN_CPYTHON
  25924. if (unlikely(Py_SIZE(x) < 0)) {
  25925. goto raise_neg_overflow;
  25926. }
  25927. #else
  25928. {
  25929. int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
  25930. if (unlikely(result < 0))
  25931. return (size_t) -1;
  25932. if (unlikely(result == 1))
  25933. goto raise_neg_overflow;
  25934. }
  25935. #endif
  25936. if (sizeof(size_t) <= sizeof(unsigned long)) {
  25937. __PYX_VERIFY_RETURN_INT_EXC(size_t, unsigned long, PyLong_AsUnsignedLong(x))
  25938. #ifdef HAVE_LONG_LONG
  25939. } else if (sizeof(size_t) <= sizeof(unsigned PY_LONG_LONG)) {
  25940. __PYX_VERIFY_RETURN_INT_EXC(size_t, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
  25941. #endif
  25942. }
  25943. } else {
  25944. #if CYTHON_USE_PYLONG_INTERNALS
  25945. const digit* digits = ((PyLongObject*)x)->ob_digit;
  25946. switch (Py_SIZE(x)) {
  25947. case 0: return (size_t) 0;
  25948. case -1: __PYX_VERIFY_RETURN_INT(size_t, sdigit, (sdigit) (-(sdigit)digits[0]))
  25949. case 1: __PYX_VERIFY_RETURN_INT(size_t, digit, +digits[0])
  25950. case -2:
  25951. if (8 * sizeof(size_t) - 1 > 1 * PyLong_SHIFT) {
  25952. if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
  25953. __PYX_VERIFY_RETURN_INT(size_t, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  25954. } else if (8 * sizeof(size_t) - 1 > 2 * PyLong_SHIFT) {
  25955. return (size_t) (((size_t)-1)*(((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0])));
  25956. }
  25957. }
  25958. break;
  25959. case 2:
  25960. if (8 * sizeof(size_t) > 1 * PyLong_SHIFT) {
  25961. if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
  25962. __PYX_VERIFY_RETURN_INT(size_t, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  25963. } else if (8 * sizeof(size_t) - 1 > 2 * PyLong_SHIFT) {
  25964. return (size_t) ((((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0])));
  25965. }
  25966. }
  25967. break;
  25968. case -3:
  25969. if (8 * sizeof(size_t) - 1 > 2 * PyLong_SHIFT) {
  25970. if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
  25971. __PYX_VERIFY_RETURN_INT(size_t, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  25972. } else if (8 * sizeof(size_t) - 1 > 3 * PyLong_SHIFT) {
  25973. return (size_t) (((size_t)-1)*(((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0])));
  25974. }
  25975. }
  25976. break;
  25977. case 3:
  25978. if (8 * sizeof(size_t) > 2 * PyLong_SHIFT) {
  25979. if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
  25980. __PYX_VERIFY_RETURN_INT(size_t, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  25981. } else if (8 * sizeof(size_t) - 1 > 3 * PyLong_SHIFT) {
  25982. return (size_t) ((((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0])));
  25983. }
  25984. }
  25985. break;
  25986. case -4:
  25987. if (8 * sizeof(size_t) - 1 > 3 * PyLong_SHIFT) {
  25988. if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
  25989. __PYX_VERIFY_RETURN_INT(size_t, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  25990. } else if (8 * sizeof(size_t) - 1 > 4 * PyLong_SHIFT) {
  25991. return (size_t) (((size_t)-1)*(((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0])));
  25992. }
  25993. }
  25994. break;
  25995. case 4:
  25996. if (8 * sizeof(size_t) > 3 * PyLong_SHIFT) {
  25997. if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
  25998. __PYX_VERIFY_RETURN_INT(size_t, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  25999. } else if (8 * sizeof(size_t) - 1 > 4 * PyLong_SHIFT) {
  26000. return (size_t) ((((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0])));
  26001. }
  26002. }
  26003. break;
  26004. }
  26005. #endif
  26006. if (sizeof(size_t) <= sizeof(long)) {
  26007. __PYX_VERIFY_RETURN_INT_EXC(size_t, long, PyLong_AsLong(x))
  26008. #ifdef HAVE_LONG_LONG
  26009. } else if (sizeof(size_t) <= sizeof(PY_LONG_LONG)) {
  26010. __PYX_VERIFY_RETURN_INT_EXC(size_t, PY_LONG_LONG, PyLong_AsLongLong(x))
  26011. #endif
  26012. }
  26013. }
  26014. {
  26015. #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray)
  26016. PyErr_SetString(PyExc_RuntimeError,
  26017. "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers");
  26018. #else
  26019. size_t val;
  26020. PyObject *v = __Pyx_PyNumber_IntOrLong(x);
  26021. #if PY_MAJOR_VERSION < 3
  26022. if (likely(v) && !PyLong_Check(v)) {
  26023. PyObject *tmp = v;
  26024. v = PyNumber_Long(tmp);
  26025. Py_DECREF(tmp);
  26026. }
  26027. #endif
  26028. if (likely(v)) {
  26029. int one = 1; int is_little = (int)*(unsigned char *)&one;
  26030. unsigned char *bytes = (unsigned char *)&val;
  26031. int ret = _PyLong_AsByteArray((PyLongObject *)v,
  26032. bytes, sizeof(val),
  26033. is_little, !is_unsigned);
  26034. Py_DECREF(v);
  26035. if (likely(!ret))
  26036. return val;
  26037. }
  26038. #endif
  26039. return (size_t) -1;
  26040. }
  26041. } else {
  26042. size_t val;
  26043. PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
  26044. if (!tmp) return (size_t) -1;
  26045. val = __Pyx_PyInt_As_size_t(tmp);
  26046. Py_DECREF(tmp);
  26047. return val;
  26048. }
  26049. raise_overflow:
  26050. PyErr_SetString(PyExc_OverflowError,
  26051. "value too large to convert to size_t");
  26052. return (size_t) -1;
  26053. raise_neg_overflow:
  26054. PyErr_SetString(PyExc_OverflowError,
  26055. "can't convert negative value to size_t");
  26056. return (size_t) -1;
  26057. }
  26058. /* CIntFromPy */
  26059. static CYTHON_INLINE long __Pyx_PyInt_As_long(PyObject *x) {
  26060. const long neg_one = (long) ((long) 0 - (long) 1), const_zero = (long) 0;
  26061. const int is_unsigned = neg_one > const_zero;
  26062. #if PY_MAJOR_VERSION < 3
  26063. if (likely(PyInt_Check(x))) {
  26064. if (sizeof(long) < sizeof(long)) {
  26065. __PYX_VERIFY_RETURN_INT(long, long, PyInt_AS_LONG(x))
  26066. } else {
  26067. long val = PyInt_AS_LONG(x);
  26068. if (is_unsigned && unlikely(val < 0)) {
  26069. goto raise_neg_overflow;
  26070. }
  26071. return (long) val;
  26072. }
  26073. } else
  26074. #endif
  26075. if (likely(PyLong_Check(x))) {
  26076. if (is_unsigned) {
  26077. #if CYTHON_USE_PYLONG_INTERNALS
  26078. const digit* digits = ((PyLongObject*)x)->ob_digit;
  26079. switch (Py_SIZE(x)) {
  26080. case 0: return (long) 0;
  26081. case 1: __PYX_VERIFY_RETURN_INT(long, digit, digits[0])
  26082. case 2:
  26083. if (8 * sizeof(long) > 1 * PyLong_SHIFT) {
  26084. if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
  26085. __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26086. } else if (8 * sizeof(long) >= 2 * PyLong_SHIFT) {
  26087. return (long) (((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
  26088. }
  26089. }
  26090. break;
  26091. case 3:
  26092. if (8 * sizeof(long) > 2 * PyLong_SHIFT) {
  26093. if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
  26094. __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26095. } else if (8 * sizeof(long) >= 3 * PyLong_SHIFT) {
  26096. return (long) (((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
  26097. }
  26098. }
  26099. break;
  26100. case 4:
  26101. if (8 * sizeof(long) > 3 * PyLong_SHIFT) {
  26102. if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
  26103. __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26104. } else if (8 * sizeof(long) >= 4 * PyLong_SHIFT) {
  26105. return (long) (((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0]));
  26106. }
  26107. }
  26108. break;
  26109. }
  26110. #endif
  26111. #if CYTHON_COMPILING_IN_CPYTHON
  26112. if (unlikely(Py_SIZE(x) < 0)) {
  26113. goto raise_neg_overflow;
  26114. }
  26115. #else
  26116. {
  26117. int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
  26118. if (unlikely(result < 0))
  26119. return (long) -1;
  26120. if (unlikely(result == 1))
  26121. goto raise_neg_overflow;
  26122. }
  26123. #endif
  26124. if (sizeof(long) <= sizeof(unsigned long)) {
  26125. __PYX_VERIFY_RETURN_INT_EXC(long, unsigned long, PyLong_AsUnsignedLong(x))
  26126. #ifdef HAVE_LONG_LONG
  26127. } else if (sizeof(long) <= sizeof(unsigned PY_LONG_LONG)) {
  26128. __PYX_VERIFY_RETURN_INT_EXC(long, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
  26129. #endif
  26130. }
  26131. } else {
  26132. #if CYTHON_USE_PYLONG_INTERNALS
  26133. const digit* digits = ((PyLongObject*)x)->ob_digit;
  26134. switch (Py_SIZE(x)) {
  26135. case 0: return (long) 0;
  26136. case -1: __PYX_VERIFY_RETURN_INT(long, sdigit, (sdigit) (-(sdigit)digits[0]))
  26137. case 1: __PYX_VERIFY_RETURN_INT(long, digit, +digits[0])
  26138. case -2:
  26139. if (8 * sizeof(long) - 1 > 1 * PyLong_SHIFT) {
  26140. if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
  26141. __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26142. } else if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
  26143. return (long) (((long)-1)*(((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
  26144. }
  26145. }
  26146. break;
  26147. case 2:
  26148. if (8 * sizeof(long) > 1 * PyLong_SHIFT) {
  26149. if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
  26150. __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26151. } else if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
  26152. return (long) ((((((long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
  26153. }
  26154. }
  26155. break;
  26156. case -3:
  26157. if (8 * sizeof(long) - 1 > 2 * PyLong_SHIFT) {
  26158. if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
  26159. __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26160. } else if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
  26161. return (long) (((long)-1)*(((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
  26162. }
  26163. }
  26164. break;
  26165. case 3:
  26166. if (8 * sizeof(long) > 2 * PyLong_SHIFT) {
  26167. if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
  26168. __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26169. } else if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
  26170. return (long) ((((((((long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
  26171. }
  26172. }
  26173. break;
  26174. case -4:
  26175. if (8 * sizeof(long) - 1 > 3 * PyLong_SHIFT) {
  26176. if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
  26177. __PYX_VERIFY_RETURN_INT(long, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26178. } else if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) {
  26179. return (long) (((long)-1)*(((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
  26180. }
  26181. }
  26182. break;
  26183. case 4:
  26184. if (8 * sizeof(long) > 3 * PyLong_SHIFT) {
  26185. if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
  26186. __PYX_VERIFY_RETURN_INT(long, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26187. } else if (8 * sizeof(long) - 1 > 4 * PyLong_SHIFT) {
  26188. return (long) ((((((((((long)digits[3]) << PyLong_SHIFT) | (long)digits[2]) << PyLong_SHIFT) | (long)digits[1]) << PyLong_SHIFT) | (long)digits[0])));
  26189. }
  26190. }
  26191. break;
  26192. }
  26193. #endif
  26194. if (sizeof(long) <= sizeof(long)) {
  26195. __PYX_VERIFY_RETURN_INT_EXC(long, long, PyLong_AsLong(x))
  26196. #ifdef HAVE_LONG_LONG
  26197. } else if (sizeof(long) <= sizeof(PY_LONG_LONG)) {
  26198. __PYX_VERIFY_RETURN_INT_EXC(long, PY_LONG_LONG, PyLong_AsLongLong(x))
  26199. #endif
  26200. }
  26201. }
  26202. {
  26203. #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray)
  26204. PyErr_SetString(PyExc_RuntimeError,
  26205. "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers");
  26206. #else
  26207. long val;
  26208. PyObject *v = __Pyx_PyNumber_IntOrLong(x);
  26209. #if PY_MAJOR_VERSION < 3
  26210. if (likely(v) && !PyLong_Check(v)) {
  26211. PyObject *tmp = v;
  26212. v = PyNumber_Long(tmp);
  26213. Py_DECREF(tmp);
  26214. }
  26215. #endif
  26216. if (likely(v)) {
  26217. int one = 1; int is_little = (int)*(unsigned char *)&one;
  26218. unsigned char *bytes = (unsigned char *)&val;
  26219. int ret = _PyLong_AsByteArray((PyLongObject *)v,
  26220. bytes, sizeof(val),
  26221. is_little, !is_unsigned);
  26222. Py_DECREF(v);
  26223. if (likely(!ret))
  26224. return val;
  26225. }
  26226. #endif
  26227. return (long) -1;
  26228. }
  26229. } else {
  26230. long val;
  26231. PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
  26232. if (!tmp) return (long) -1;
  26233. val = __Pyx_PyInt_As_long(tmp);
  26234. Py_DECREF(tmp);
  26235. return val;
  26236. }
  26237. raise_overflow:
  26238. PyErr_SetString(PyExc_OverflowError,
  26239. "value too large to convert to long");
  26240. return (long) -1;
  26241. raise_neg_overflow:
  26242. PyErr_SetString(PyExc_OverflowError,
  26243. "can't convert negative value to long");
  26244. return (long) -1;
  26245. }
  26246. /* CIntFromPy */
  26247. static CYTHON_INLINE int __Pyx_PyInt_As_int(PyObject *x) {
  26248. const int neg_one = (int) ((int) 0 - (int) 1), const_zero = (int) 0;
  26249. const int is_unsigned = neg_one > const_zero;
  26250. #if PY_MAJOR_VERSION < 3
  26251. if (likely(PyInt_Check(x))) {
  26252. if (sizeof(int) < sizeof(long)) {
  26253. __PYX_VERIFY_RETURN_INT(int, long, PyInt_AS_LONG(x))
  26254. } else {
  26255. long val = PyInt_AS_LONG(x);
  26256. if (is_unsigned && unlikely(val < 0)) {
  26257. goto raise_neg_overflow;
  26258. }
  26259. return (int) val;
  26260. }
  26261. } else
  26262. #endif
  26263. if (likely(PyLong_Check(x))) {
  26264. if (is_unsigned) {
  26265. #if CYTHON_USE_PYLONG_INTERNALS
  26266. const digit* digits = ((PyLongObject*)x)->ob_digit;
  26267. switch (Py_SIZE(x)) {
  26268. case 0: return (int) 0;
  26269. case 1: __PYX_VERIFY_RETURN_INT(int, digit, digits[0])
  26270. case 2:
  26271. if (8 * sizeof(int) > 1 * PyLong_SHIFT) {
  26272. if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
  26273. __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26274. } else if (8 * sizeof(int) >= 2 * PyLong_SHIFT) {
  26275. return (int) (((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
  26276. }
  26277. }
  26278. break;
  26279. case 3:
  26280. if (8 * sizeof(int) > 2 * PyLong_SHIFT) {
  26281. if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
  26282. __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26283. } else if (8 * sizeof(int) >= 3 * PyLong_SHIFT) {
  26284. return (int) (((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
  26285. }
  26286. }
  26287. break;
  26288. case 4:
  26289. if (8 * sizeof(int) > 3 * PyLong_SHIFT) {
  26290. if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
  26291. __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26292. } else if (8 * sizeof(int) >= 4 * PyLong_SHIFT) {
  26293. return (int) (((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0]));
  26294. }
  26295. }
  26296. break;
  26297. }
  26298. #endif
  26299. #if CYTHON_COMPILING_IN_CPYTHON
  26300. if (unlikely(Py_SIZE(x) < 0)) {
  26301. goto raise_neg_overflow;
  26302. }
  26303. #else
  26304. {
  26305. int result = PyObject_RichCompareBool(x, Py_False, Py_LT);
  26306. if (unlikely(result < 0))
  26307. return (int) -1;
  26308. if (unlikely(result == 1))
  26309. goto raise_neg_overflow;
  26310. }
  26311. #endif
  26312. if (sizeof(int) <= sizeof(unsigned long)) {
  26313. __PYX_VERIFY_RETURN_INT_EXC(int, unsigned long, PyLong_AsUnsignedLong(x))
  26314. #ifdef HAVE_LONG_LONG
  26315. } else if (sizeof(int) <= sizeof(unsigned PY_LONG_LONG)) {
  26316. __PYX_VERIFY_RETURN_INT_EXC(int, unsigned PY_LONG_LONG, PyLong_AsUnsignedLongLong(x))
  26317. #endif
  26318. }
  26319. } else {
  26320. #if CYTHON_USE_PYLONG_INTERNALS
  26321. const digit* digits = ((PyLongObject*)x)->ob_digit;
  26322. switch (Py_SIZE(x)) {
  26323. case 0: return (int) 0;
  26324. case -1: __PYX_VERIFY_RETURN_INT(int, sdigit, (sdigit) (-(sdigit)digits[0]))
  26325. case 1: __PYX_VERIFY_RETURN_INT(int, digit, +digits[0])
  26326. case -2:
  26327. if (8 * sizeof(int) - 1 > 1 * PyLong_SHIFT) {
  26328. if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
  26329. __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26330. } else if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) {
  26331. return (int) (((int)-1)*(((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
  26332. }
  26333. }
  26334. break;
  26335. case 2:
  26336. if (8 * sizeof(int) > 1 * PyLong_SHIFT) {
  26337. if (8 * sizeof(unsigned long) > 2 * PyLong_SHIFT) {
  26338. __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26339. } else if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) {
  26340. return (int) ((((((int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
  26341. }
  26342. }
  26343. break;
  26344. case -3:
  26345. if (8 * sizeof(int) - 1 > 2 * PyLong_SHIFT) {
  26346. if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
  26347. __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26348. } else if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) {
  26349. return (int) (((int)-1)*(((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
  26350. }
  26351. }
  26352. break;
  26353. case 3:
  26354. if (8 * sizeof(int) > 2 * PyLong_SHIFT) {
  26355. if (8 * sizeof(unsigned long) > 3 * PyLong_SHIFT) {
  26356. __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26357. } else if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) {
  26358. return (int) ((((((((int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
  26359. }
  26360. }
  26361. break;
  26362. case -4:
  26363. if (8 * sizeof(int) - 1 > 3 * PyLong_SHIFT) {
  26364. if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
  26365. __PYX_VERIFY_RETURN_INT(int, long, -(long) (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26366. } else if (8 * sizeof(int) - 1 > 4 * PyLong_SHIFT) {
  26367. return (int) (((int)-1)*(((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
  26368. }
  26369. }
  26370. break;
  26371. case 4:
  26372. if (8 * sizeof(int) > 3 * PyLong_SHIFT) {
  26373. if (8 * sizeof(unsigned long) > 4 * PyLong_SHIFT) {
  26374. __PYX_VERIFY_RETURN_INT(int, unsigned long, (((((((((unsigned long)digits[3]) << PyLong_SHIFT) | (unsigned long)digits[2]) << PyLong_SHIFT) | (unsigned long)digits[1]) << PyLong_SHIFT) | (unsigned long)digits[0])))
  26375. } else if (8 * sizeof(int) - 1 > 4 * PyLong_SHIFT) {
  26376. return (int) ((((((((((int)digits[3]) << PyLong_SHIFT) | (int)digits[2]) << PyLong_SHIFT) | (int)digits[1]) << PyLong_SHIFT) | (int)digits[0])));
  26377. }
  26378. }
  26379. break;
  26380. }
  26381. #endif
  26382. if (sizeof(int) <= sizeof(long)) {
  26383. __PYX_VERIFY_RETURN_INT_EXC(int, long, PyLong_AsLong(x))
  26384. #ifdef HAVE_LONG_LONG
  26385. } else if (sizeof(int) <= sizeof(PY_LONG_LONG)) {
  26386. __PYX_VERIFY_RETURN_INT_EXC(int, PY_LONG_LONG, PyLong_AsLongLong(x))
  26387. #endif
  26388. }
  26389. }
  26390. {
  26391. #if CYTHON_COMPILING_IN_PYPY && !defined(_PyLong_AsByteArray)
  26392. PyErr_SetString(PyExc_RuntimeError,
  26393. "_PyLong_AsByteArray() not available in PyPy, cannot convert large numbers");
  26394. #else
  26395. int val;
  26396. PyObject *v = __Pyx_PyNumber_IntOrLong(x);
  26397. #if PY_MAJOR_VERSION < 3
  26398. if (likely(v) && !PyLong_Check(v)) {
  26399. PyObject *tmp = v;
  26400. v = PyNumber_Long(tmp);
  26401. Py_DECREF(tmp);
  26402. }
  26403. #endif
  26404. if (likely(v)) {
  26405. int one = 1; int is_little = (int)*(unsigned char *)&one;
  26406. unsigned char *bytes = (unsigned char *)&val;
  26407. int ret = _PyLong_AsByteArray((PyLongObject *)v,
  26408. bytes, sizeof(val),
  26409. is_little, !is_unsigned);
  26410. Py_DECREF(v);
  26411. if (likely(!ret))
  26412. return val;
  26413. }
  26414. #endif
  26415. return (int) -1;
  26416. }
  26417. } else {
  26418. int val;
  26419. PyObject *tmp = __Pyx_PyNumber_IntOrLong(x);
  26420. if (!tmp) return (int) -1;
  26421. val = __Pyx_PyInt_As_int(tmp);
  26422. Py_DECREF(tmp);
  26423. return val;
  26424. }
  26425. raise_overflow:
  26426. PyErr_SetString(PyExc_OverflowError,
  26427. "value too large to convert to int");
  26428. return (int) -1;
  26429. raise_neg_overflow:
  26430. PyErr_SetString(PyExc_OverflowError,
  26431. "can't convert negative value to int");
  26432. return (int) -1;
  26433. }
  26434. /* FastTypeChecks */
  26435. #if CYTHON_COMPILING_IN_CPYTHON
  26436. static int __Pyx_InBases(PyTypeObject *a, PyTypeObject *b) {
  26437. while (a) {
  26438. a = a->tp_base;
  26439. if (a == b)
  26440. return 1;
  26441. }
  26442. return b == &PyBaseObject_Type;
  26443. }
  26444. static CYTHON_INLINE int __Pyx_IsSubtype(PyTypeObject *a, PyTypeObject *b) {
  26445. PyObject *mro;
  26446. if (a == b) return 1;
  26447. mro = a->tp_mro;
  26448. if (likely(mro)) {
  26449. Py_ssize_t i, n;
  26450. n = PyTuple_GET_SIZE(mro);
  26451. for (i = 0; i < n; i++) {
  26452. if (PyTuple_GET_ITEM(mro, i) == (PyObject *)b)
  26453. return 1;
  26454. }
  26455. return 0;
  26456. }
  26457. return __Pyx_InBases(a, b);
  26458. }
  26459. #if PY_MAJOR_VERSION == 2
  26460. static int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject* exc_type2) {
  26461. PyObject *exception, *value, *tb;
  26462. int res;
  26463. __Pyx_PyThreadState_declare
  26464. __Pyx_PyThreadState_assign
  26465. __Pyx_ErrFetch(&exception, &value, &tb);
  26466. res = exc_type1 ? PyObject_IsSubclass(err, exc_type1) : 0;
  26467. if (unlikely(res == -1)) {
  26468. PyErr_WriteUnraisable(err);
  26469. res = 0;
  26470. }
  26471. if (!res) {
  26472. res = PyObject_IsSubclass(err, exc_type2);
  26473. if (unlikely(res == -1)) {
  26474. PyErr_WriteUnraisable(err);
  26475. res = 0;
  26476. }
  26477. }
  26478. __Pyx_ErrRestore(exception, value, tb);
  26479. return res;
  26480. }
  26481. #else
  26482. static CYTHON_INLINE int __Pyx_inner_PyErr_GivenExceptionMatches2(PyObject *err, PyObject* exc_type1, PyObject *exc_type2) {
  26483. int res = exc_type1 ? __Pyx_IsSubtype((PyTypeObject*)err, (PyTypeObject*)exc_type1) : 0;
  26484. if (!res) {
  26485. res = __Pyx_IsSubtype((PyTypeObject*)err, (PyTypeObject*)exc_type2);
  26486. }
  26487. return res;
  26488. }
  26489. #endif
  26490. static int __Pyx_PyErr_GivenExceptionMatchesTuple(PyObject *exc_type, PyObject *tuple) {
  26491. Py_ssize_t i, n;
  26492. assert(PyExceptionClass_Check(exc_type));
  26493. n = PyTuple_GET_SIZE(tuple);
  26494. #if PY_MAJOR_VERSION >= 3
  26495. for (i=0; i<n; i++) {
  26496. if (exc_type == PyTuple_GET_ITEM(tuple, i)) return 1;
  26497. }
  26498. #endif
  26499. for (i=0; i<n; i++) {
  26500. PyObject *t = PyTuple_GET_ITEM(tuple, i);
  26501. #if PY_MAJOR_VERSION < 3
  26502. if (likely(exc_type == t)) return 1;
  26503. #endif
  26504. if (likely(PyExceptionClass_Check(t))) {
  26505. if (__Pyx_inner_PyErr_GivenExceptionMatches2(exc_type, NULL, t)) return 1;
  26506. } else {
  26507. }
  26508. }
  26509. return 0;
  26510. }
  26511. static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches(PyObject *err, PyObject* exc_type) {
  26512. if (likely(err == exc_type)) return 1;
  26513. if (likely(PyExceptionClass_Check(err))) {
  26514. if (likely(PyExceptionClass_Check(exc_type))) {
  26515. return __Pyx_inner_PyErr_GivenExceptionMatches2(err, NULL, exc_type);
  26516. } else if (likely(PyTuple_Check(exc_type))) {
  26517. return __Pyx_PyErr_GivenExceptionMatchesTuple(err, exc_type);
  26518. } else {
  26519. }
  26520. }
  26521. return PyErr_GivenExceptionMatches(err, exc_type);
  26522. }
  26523. static CYTHON_INLINE int __Pyx_PyErr_GivenExceptionMatches2(PyObject *err, PyObject *exc_type1, PyObject *exc_type2) {
  26524. assert(PyExceptionClass_Check(exc_type1));
  26525. assert(PyExceptionClass_Check(exc_type2));
  26526. if (likely(err == exc_type1 || err == exc_type2)) return 1;
  26527. if (likely(PyExceptionClass_Check(err))) {
  26528. return __Pyx_inner_PyErr_GivenExceptionMatches2(err, exc_type1, exc_type2);
  26529. }
  26530. return (PyErr_GivenExceptionMatches(err, exc_type1) || PyErr_GivenExceptionMatches(err, exc_type2));
  26531. }
  26532. #endif
  26533. /* CheckBinaryVersion */
  26534. static int __Pyx_check_binary_version(void) {
  26535. char ctversion[4], rtversion[4];
  26536. PyOS_snprintf(ctversion, 4, "%d.%d", PY_MAJOR_VERSION, PY_MINOR_VERSION);
  26537. PyOS_snprintf(rtversion, 4, "%s", Py_GetVersion());
  26538. if (ctversion[0] != rtversion[0] || ctversion[2] != rtversion[2]) {
  26539. char message[200];
  26540. PyOS_snprintf(message, sizeof(message),
  26541. "compiletime version %s of module '%.100s' "
  26542. "does not match runtime version %s",
  26543. ctversion, __Pyx_MODULE_NAME, rtversion);
  26544. return PyErr_WarnEx(NULL, message, 1);
  26545. }
  26546. return 0;
  26547. }
  26548. /* InitStrings */
  26549. static int __Pyx_InitStrings(__Pyx_StringTabEntry *t) {
  26550. while (t->p) {
  26551. #if PY_MAJOR_VERSION < 3
  26552. if (t->is_unicode) {
  26553. *t->p = PyUnicode_DecodeUTF8(t->s, t->n - 1, NULL);
  26554. } else if (t->intern) {
  26555. *t->p = PyString_InternFromString(t->s);
  26556. } else {
  26557. *t->p = PyString_FromStringAndSize(t->s, t->n - 1);
  26558. }
  26559. #else
  26560. if (t->is_unicode | t->is_str) {
  26561. if (t->intern) {
  26562. *t->p = PyUnicode_InternFromString(t->s);
  26563. } else if (t->encoding) {
  26564. *t->p = PyUnicode_Decode(t->s, t->n - 1, t->encoding, NULL);
  26565. } else {
  26566. *t->p = PyUnicode_FromStringAndSize(t->s, t->n - 1);
  26567. }
  26568. } else {
  26569. *t->p = PyBytes_FromStringAndSize(t->s, t->n - 1);
  26570. }
  26571. #endif
  26572. if (!*t->p)
  26573. return -1;
  26574. if (PyObject_Hash(*t->p) == -1)
  26575. return -1;
  26576. ++t;
  26577. }
  26578. return 0;
  26579. }
  26580. static CYTHON_INLINE PyObject* __Pyx_PyUnicode_FromString(const char* c_str) {
  26581. return __Pyx_PyUnicode_FromStringAndSize(c_str, (Py_ssize_t)strlen(c_str));
  26582. }
  26583. static CYTHON_INLINE const char* __Pyx_PyObject_AsString(PyObject* o) {
  26584. Py_ssize_t ignore;
  26585. return __Pyx_PyObject_AsStringAndSize(o, &ignore);
  26586. }
  26587. #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
  26588. #if !CYTHON_PEP393_ENABLED
  26589. static const char* __Pyx_PyUnicode_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
  26590. char* defenc_c;
  26591. PyObject* defenc = _PyUnicode_AsDefaultEncodedString(o, NULL);
  26592. if (!defenc) return NULL;
  26593. defenc_c = PyBytes_AS_STRING(defenc);
  26594. #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
  26595. {
  26596. char* end = defenc_c + PyBytes_GET_SIZE(defenc);
  26597. char* c;
  26598. for (c = defenc_c; c < end; c++) {
  26599. if ((unsigned char) (*c) >= 128) {
  26600. PyUnicode_AsASCIIString(o);
  26601. return NULL;
  26602. }
  26603. }
  26604. }
  26605. #endif
  26606. *length = PyBytes_GET_SIZE(defenc);
  26607. return defenc_c;
  26608. }
  26609. #else
  26610. static CYTHON_INLINE const char* __Pyx_PyUnicode_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
  26611. if (unlikely(__Pyx_PyUnicode_READY(o) == -1)) return NULL;
  26612. #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
  26613. if (likely(PyUnicode_IS_ASCII(o))) {
  26614. *length = PyUnicode_GET_LENGTH(o);
  26615. return PyUnicode_AsUTF8(o);
  26616. } else {
  26617. PyUnicode_AsASCIIString(o);
  26618. return NULL;
  26619. }
  26620. #else
  26621. return PyUnicode_AsUTF8AndSize(o, length);
  26622. #endif
  26623. }
  26624. #endif
  26625. #endif
  26626. static CYTHON_INLINE const char* __Pyx_PyObject_AsStringAndSize(PyObject* o, Py_ssize_t *length) {
  26627. #if __PYX_DEFAULT_STRING_ENCODING_IS_ASCII || __PYX_DEFAULT_STRING_ENCODING_IS_DEFAULT
  26628. if (
  26629. #if PY_MAJOR_VERSION < 3 && __PYX_DEFAULT_STRING_ENCODING_IS_ASCII
  26630. __Pyx_sys_getdefaultencoding_not_ascii &&
  26631. #endif
  26632. PyUnicode_Check(o)) {
  26633. return __Pyx_PyUnicode_AsStringAndSize(o, length);
  26634. } else
  26635. #endif
  26636. #if (!CYTHON_COMPILING_IN_PYPY) || (defined(PyByteArray_AS_STRING) && defined(PyByteArray_GET_SIZE))
  26637. if (PyByteArray_Check(o)) {
  26638. *length = PyByteArray_GET_SIZE(o);
  26639. return PyByteArray_AS_STRING(o);
  26640. } else
  26641. #endif
  26642. {
  26643. char* result;
  26644. int r = PyBytes_AsStringAndSize(o, &result, length);
  26645. if (unlikely(r < 0)) {
  26646. return NULL;
  26647. } else {
  26648. return result;
  26649. }
  26650. }
  26651. }
  26652. static CYTHON_INLINE int __Pyx_PyObject_IsTrue(PyObject* x) {
  26653. int is_true = x == Py_True;
  26654. if (is_true | (x == Py_False) | (x == Py_None)) return is_true;
  26655. else return PyObject_IsTrue(x);
  26656. }
  26657. static CYTHON_INLINE int __Pyx_PyObject_IsTrueAndDecref(PyObject* x) {
  26658. int retval;
  26659. if (unlikely(!x)) return -1;
  26660. retval = __Pyx_PyObject_IsTrue(x);
  26661. Py_DECREF(x);
  26662. return retval;
  26663. }
  26664. static PyObject* __Pyx_PyNumber_IntOrLongWrongResultType(PyObject* result, const char* type_name) {
  26665. #if PY_MAJOR_VERSION >= 3
  26666. if (PyLong_Check(result)) {
  26667. if (PyErr_WarnFormat(PyExc_DeprecationWarning, 1,
  26668. "__int__ returned non-int (type %.200s). "
  26669. "The ability to return an instance of a strict subclass of int "
  26670. "is deprecated, and may be removed in a future version of Python.",
  26671. Py_TYPE(result)->tp_name)) {
  26672. Py_DECREF(result);
  26673. return NULL;
  26674. }
  26675. return result;
  26676. }
  26677. #endif
  26678. PyErr_Format(PyExc_TypeError,
  26679. "__%.4s__ returned non-%.4s (type %.200s)",
  26680. type_name, type_name, Py_TYPE(result)->tp_name);
  26681. Py_DECREF(result);
  26682. return NULL;
  26683. }
  26684. static CYTHON_INLINE PyObject* __Pyx_PyNumber_IntOrLong(PyObject* x) {
  26685. #if CYTHON_USE_TYPE_SLOTS
  26686. PyNumberMethods *m;
  26687. #endif
  26688. const char *name = NULL;
  26689. PyObject *res = NULL;
  26690. #if PY_MAJOR_VERSION < 3
  26691. if (likely(PyInt_Check(x) || PyLong_Check(x)))
  26692. #else
  26693. if (likely(PyLong_Check(x)))
  26694. #endif
  26695. return __Pyx_NewRef(x);
  26696. #if CYTHON_USE_TYPE_SLOTS
  26697. m = Py_TYPE(x)->tp_as_number;
  26698. #if PY_MAJOR_VERSION < 3
  26699. if (m && m->nb_int) {
  26700. name = "int";
  26701. res = m->nb_int(x);
  26702. }
  26703. else if (m && m->nb_long) {
  26704. name = "long";
  26705. res = m->nb_long(x);
  26706. }
  26707. #else
  26708. if (likely(m && m->nb_int)) {
  26709. name = "int";
  26710. res = m->nb_int(x);
  26711. }
  26712. #endif
  26713. #else
  26714. if (!PyBytes_CheckExact(x) && !PyUnicode_CheckExact(x)) {
  26715. res = PyNumber_Int(x);
  26716. }
  26717. #endif
  26718. if (likely(res)) {
  26719. #if PY_MAJOR_VERSION < 3
  26720. if (unlikely(!PyInt_Check(res) && !PyLong_Check(res))) {
  26721. #else
  26722. if (unlikely(!PyLong_CheckExact(res))) {
  26723. #endif
  26724. return __Pyx_PyNumber_IntOrLongWrongResultType(res, name);
  26725. }
  26726. }
  26727. else if (!PyErr_Occurred()) {
  26728. PyErr_SetString(PyExc_TypeError,
  26729. "an integer is required");
  26730. }
  26731. return res;
  26732. }
  26733. static CYTHON_INLINE Py_ssize_t __Pyx_PyIndex_AsSsize_t(PyObject* b) {
  26734. Py_ssize_t ival;
  26735. PyObject *x;
  26736. #if PY_MAJOR_VERSION < 3
  26737. if (likely(PyInt_CheckExact(b))) {
  26738. if (sizeof(Py_ssize_t) >= sizeof(long))
  26739. return PyInt_AS_LONG(b);
  26740. else
  26741. return PyInt_AsSsize_t(b);
  26742. }
  26743. #endif
  26744. if (likely(PyLong_CheckExact(b))) {
  26745. #if CYTHON_USE_PYLONG_INTERNALS
  26746. const digit* digits = ((PyLongObject*)b)->ob_digit;
  26747. const Py_ssize_t size = Py_SIZE(b);
  26748. if (likely(__Pyx_sst_abs(size) <= 1)) {
  26749. ival = likely(size) ? digits[0] : 0;
  26750. if (size == -1) ival = -ival;
  26751. return ival;
  26752. } else {
  26753. switch (size) {
  26754. case 2:
  26755. if (8 * sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) {
  26756. return (Py_ssize_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
  26757. }
  26758. break;
  26759. case -2:
  26760. if (8 * sizeof(Py_ssize_t) > 2 * PyLong_SHIFT) {
  26761. return -(Py_ssize_t) (((((size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
  26762. }
  26763. break;
  26764. case 3:
  26765. if (8 * sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) {
  26766. return (Py_ssize_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
  26767. }
  26768. break;
  26769. case -3:
  26770. if (8 * sizeof(Py_ssize_t) > 3 * PyLong_SHIFT) {
  26771. return -(Py_ssize_t) (((((((size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
  26772. }
  26773. break;
  26774. case 4:
  26775. if (8 * sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) {
  26776. return (Py_ssize_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
  26777. }
  26778. break;
  26779. case -4:
  26780. if (8 * sizeof(Py_ssize_t) > 4 * PyLong_SHIFT) {
  26781. return -(Py_ssize_t) (((((((((size_t)digits[3]) << PyLong_SHIFT) | (size_t)digits[2]) << PyLong_SHIFT) | (size_t)digits[1]) << PyLong_SHIFT) | (size_t)digits[0]));
  26782. }
  26783. break;
  26784. }
  26785. }
  26786. #endif
  26787. return PyLong_AsSsize_t(b);
  26788. }
  26789. x = PyNumber_Index(b);
  26790. if (!x) return -1;
  26791. ival = PyInt_AsSsize_t(x);
  26792. Py_DECREF(x);
  26793. return ival;
  26794. }
  26795. static CYTHON_INLINE PyObject * __Pyx_PyBool_FromLong(long b) {
  26796. return b ? __Pyx_NewRef(Py_True) : __Pyx_NewRef(Py_False);
  26797. }
  26798. static CYTHON_INLINE PyObject * __Pyx_PyInt_FromSize_t(size_t ival) {
  26799. return PyInt_FromSize_t(ival);
  26800. }
  26801. #endif /* Py_PYTHON_H */