fast-path.generated.go 731 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173317431753176317731783179318031813182318331843185318631873188318931903191319231933194319531963197319831993200320132023203320432053206320732083209321032113212321332143215321632173218321932203221322232233224322532263227322832293230323132323233323432353236323732383239324032413242324332443245324632473248324932503251325232533254325532563257325832593260326132623263326432653266326732683269327032713272327332743275327632773278327932803281328232833284328532863287328832893290329132923293329432953296329732983299330033013302330333043305330633073308330933103311331233133314331533163317331833193320332133223323332433253326332733283329333033313332333333343335333633373338333933403341334233433344334533463347334833493350335133523353335433553356335733583359336033613362336333643365336633673368336933703371337233733374337533763377337833793380338133823383338433853386338733883389339033913392339333943395339633973398339934003401340234033404340534063407340834093410341134123413341434153416341734183419342034213422342334243425342634273428342934303431343234333434343534363437343834393440344134423443344434453446344734483449345034513452345334543455345634573458345934603461346234633464346534663467346834693470347134723473347434753476347734783479348034813482348334843485348634873488348934903491349234933494349534963497349834993500350135023503350435053506350735083509351035113512351335143515351635173518351935203521352235233524352535263527352835293530353135323533353435353536353735383539354035413542354335443545354635473548354935503551355235533554355535563557355835593560356135623563356435653566356735683569357035713572357335743575357635773578357935803581358235833584358535863587358835893590359135923593359435953596359735983599360036013602360336043605360636073608360936103611361236133614361536163617361836193620362136223623362436253626362736283629363036313632363336343635363636373638363936403641364236433644364536463647364836493650365136523653365436553656365736583659366036613662366336643665366636673668366936703671367236733674367536763677367836793680368136823683368436853686368736883689369036913692369336943695369636973698369937003701370237033704370537063707370837093710371137123713371437153716371737183719372037213722372337243725372637273728372937303731373237333734373537363737373837393740374137423743374437453746374737483749375037513752375337543755375637573758375937603761376237633764376537663767376837693770377137723773377437753776377737783779378037813782378337843785378637873788378937903791379237933794379537963797379837993800380138023803380438053806380738083809381038113812381338143815381638173818381938203821382238233824382538263827382838293830383138323833383438353836383738383839384038413842384338443845384638473848384938503851385238533854385538563857385838593860386138623863386438653866386738683869387038713872387338743875387638773878387938803881388238833884388538863887388838893890389138923893389438953896389738983899390039013902390339043905390639073908390939103911391239133914391539163917391839193920392139223923392439253926392739283929393039313932393339343935393639373938393939403941394239433944394539463947394839493950395139523953395439553956395739583959396039613962396339643965396639673968396939703971397239733974397539763977397839793980398139823983398439853986398739883989399039913992399339943995399639973998399940004001400240034004400540064007400840094010401140124013401440154016401740184019402040214022402340244025402640274028402940304031403240334034403540364037403840394040404140424043404440454046404740484049405040514052405340544055405640574058405940604061406240634064406540664067406840694070407140724073407440754076407740784079408040814082408340844085408640874088408940904091409240934094409540964097409840994100410141024103410441054106410741084109411041114112411341144115411641174118411941204121412241234124412541264127412841294130413141324133413441354136413741384139414041414142414341444145414641474148414941504151415241534154415541564157415841594160416141624163416441654166416741684169417041714172417341744175417641774178417941804181418241834184418541864187418841894190419141924193419441954196419741984199420042014202420342044205420642074208420942104211421242134214421542164217421842194220422142224223422442254226422742284229423042314232423342344235423642374238423942404241424242434244424542464247424842494250425142524253425442554256425742584259426042614262426342644265426642674268426942704271427242734274427542764277427842794280428142824283428442854286428742884289429042914292429342944295429642974298429943004301430243034304430543064307430843094310431143124313431443154316431743184319432043214322432343244325432643274328432943304331433243334334433543364337433843394340434143424343434443454346434743484349435043514352435343544355435643574358435943604361436243634364436543664367436843694370437143724373437443754376437743784379438043814382438343844385438643874388438943904391439243934394439543964397439843994400440144024403440444054406440744084409441044114412441344144415441644174418441944204421442244234424442544264427442844294430443144324433443444354436443744384439444044414442444344444445444644474448444944504451445244534454445544564457445844594460446144624463446444654466446744684469447044714472447344744475447644774478447944804481448244834484448544864487448844894490449144924493449444954496449744984499450045014502450345044505450645074508450945104511451245134514451545164517451845194520452145224523452445254526452745284529453045314532453345344535453645374538453945404541454245434544454545464547454845494550455145524553455445554556455745584559456045614562456345644565456645674568456945704571457245734574457545764577457845794580458145824583458445854586458745884589459045914592459345944595459645974598459946004601460246034604460546064607460846094610461146124613461446154616461746184619462046214622462346244625462646274628462946304631463246334634463546364637463846394640464146424643464446454646464746484649465046514652465346544655465646574658465946604661466246634664466546664667466846694670467146724673467446754676467746784679468046814682468346844685468646874688468946904691469246934694469546964697469846994700470147024703470447054706470747084709471047114712471347144715471647174718471947204721472247234724472547264727472847294730473147324733473447354736473747384739474047414742474347444745474647474748474947504751475247534754475547564757475847594760476147624763476447654766476747684769477047714772477347744775477647774778477947804781478247834784478547864787478847894790479147924793479447954796479747984799480048014802480348044805480648074808480948104811481248134814481548164817481848194820482148224823482448254826482748284829483048314832483348344835483648374838483948404841484248434844484548464847484848494850485148524853485448554856485748584859486048614862486348644865486648674868486948704871487248734874487548764877487848794880488148824883488448854886488748884889489048914892489348944895489648974898489949004901490249034904490549064907490849094910491149124913491449154916491749184919492049214922492349244925492649274928492949304931493249334934493549364937493849394940494149424943494449454946494749484949495049514952495349544955495649574958495949604961496249634964496549664967496849694970497149724973497449754976497749784979498049814982498349844985498649874988498949904991499249934994499549964997499849995000500150025003500450055006500750085009501050115012501350145015501650175018501950205021502250235024502550265027502850295030503150325033503450355036503750385039504050415042504350445045504650475048504950505051505250535054505550565057505850595060506150625063506450655066506750685069507050715072507350745075507650775078507950805081508250835084508550865087508850895090509150925093509450955096509750985099510051015102510351045105510651075108510951105111511251135114511551165117511851195120512151225123512451255126512751285129513051315132513351345135513651375138513951405141514251435144514551465147514851495150515151525153515451555156515751585159516051615162516351645165516651675168516951705171517251735174517551765177517851795180518151825183518451855186518751885189519051915192519351945195519651975198519952005201520252035204520552065207520852095210521152125213521452155216521752185219522052215222522352245225522652275228522952305231523252335234523552365237523852395240524152425243524452455246524752485249525052515252525352545255525652575258525952605261526252635264526552665267526852695270527152725273527452755276527752785279528052815282528352845285528652875288528952905291529252935294529552965297529852995300530153025303530453055306530753085309531053115312531353145315531653175318531953205321532253235324532553265327532853295330533153325333533453355336533753385339534053415342534353445345534653475348534953505351535253535354535553565357535853595360536153625363536453655366536753685369537053715372537353745375537653775378537953805381538253835384538553865387538853895390539153925393539453955396539753985399540054015402540354045405540654075408540954105411541254135414541554165417541854195420542154225423542454255426542754285429543054315432543354345435543654375438543954405441544254435444544554465447544854495450545154525453545454555456545754585459546054615462546354645465546654675468546954705471547254735474547554765477547854795480548154825483548454855486548754885489549054915492549354945495549654975498549955005501550255035504550555065507550855095510551155125513551455155516551755185519552055215522552355245525552655275528552955305531553255335534553555365537553855395540554155425543554455455546554755485549555055515552555355545555555655575558555955605561556255635564556555665567556855695570557155725573557455755576557755785579558055815582558355845585558655875588558955905591559255935594559555965597559855995600560156025603560456055606560756085609561056115612561356145615561656175618561956205621562256235624562556265627562856295630563156325633563456355636563756385639564056415642564356445645564656475648564956505651565256535654565556565657565856595660566156625663566456655666566756685669567056715672567356745675567656775678567956805681568256835684568556865687568856895690569156925693569456955696569756985699570057015702570357045705570657075708570957105711571257135714571557165717571857195720572157225723572457255726572757285729573057315732573357345735573657375738573957405741574257435744574557465747574857495750575157525753575457555756575757585759576057615762576357645765576657675768576957705771577257735774577557765777577857795780578157825783578457855786578757885789579057915792579357945795579657975798579958005801580258035804580558065807580858095810581158125813581458155816581758185819582058215822582358245825582658275828582958305831583258335834583558365837583858395840584158425843584458455846584758485849585058515852585358545855585658575858585958605861586258635864586558665867586858695870587158725873587458755876587758785879588058815882588358845885588658875888588958905891589258935894589558965897589858995900590159025903590459055906590759085909591059115912591359145915591659175918591959205921592259235924592559265927592859295930593159325933593459355936593759385939594059415942594359445945594659475948594959505951595259535954595559565957595859595960596159625963596459655966596759685969597059715972597359745975597659775978597959805981598259835984598559865987598859895990599159925993599459955996599759985999600060016002600360046005600660076008600960106011601260136014601560166017601860196020602160226023602460256026602760286029603060316032603360346035603660376038603960406041604260436044604560466047604860496050605160526053605460556056605760586059606060616062606360646065606660676068606960706071607260736074607560766077607860796080608160826083608460856086608760886089609060916092609360946095609660976098609961006101610261036104610561066107610861096110611161126113611461156116611761186119612061216122612361246125612661276128612961306131613261336134613561366137613861396140614161426143614461456146614761486149615061516152615361546155615661576158615961606161616261636164616561666167616861696170617161726173617461756176617761786179618061816182618361846185618661876188618961906191619261936194619561966197619861996200620162026203620462056206620762086209621062116212621362146215621662176218621962206221622262236224622562266227622862296230623162326233623462356236623762386239624062416242624362446245624662476248624962506251625262536254625562566257625862596260626162626263626462656266626762686269627062716272627362746275627662776278627962806281628262836284628562866287628862896290629162926293629462956296629762986299630063016302630363046305630663076308630963106311631263136314631563166317631863196320632163226323632463256326632763286329633063316332633363346335633663376338633963406341634263436344634563466347634863496350635163526353635463556356635763586359636063616362636363646365636663676368636963706371637263736374637563766377637863796380638163826383638463856386638763886389639063916392639363946395639663976398639964006401640264036404640564066407640864096410641164126413641464156416641764186419642064216422642364246425642664276428642964306431643264336434643564366437643864396440644164426443644464456446644764486449645064516452645364546455645664576458645964606461646264636464646564666467646864696470647164726473647464756476647764786479648064816482648364846485648664876488648964906491649264936494649564966497649864996500650165026503650465056506650765086509651065116512651365146515651665176518651965206521652265236524652565266527652865296530653165326533653465356536653765386539654065416542654365446545654665476548654965506551655265536554655565566557655865596560656165626563656465656566656765686569657065716572657365746575657665776578657965806581658265836584658565866587658865896590659165926593659465956596659765986599660066016602660366046605660666076608660966106611661266136614661566166617661866196620662166226623662466256626662766286629663066316632663366346635663666376638663966406641664266436644664566466647664866496650665166526653665466556656665766586659666066616662666366646665666666676668666966706671667266736674667566766677667866796680668166826683668466856686668766886689669066916692669366946695669666976698669967006701670267036704670567066707670867096710671167126713671467156716671767186719672067216722672367246725672667276728672967306731673267336734673567366737673867396740674167426743674467456746674767486749675067516752675367546755675667576758675967606761676267636764676567666767676867696770677167726773677467756776677767786779678067816782678367846785678667876788678967906791679267936794679567966797679867996800680168026803680468056806680768086809681068116812681368146815681668176818681968206821682268236824682568266827682868296830683168326833683468356836683768386839684068416842684368446845684668476848684968506851685268536854685568566857685868596860686168626863686468656866686768686869687068716872687368746875687668776878687968806881688268836884688568866887688868896890689168926893689468956896689768986899690069016902690369046905690669076908690969106911691269136914691569166917691869196920692169226923692469256926692769286929693069316932693369346935693669376938693969406941694269436944694569466947694869496950695169526953695469556956695769586959696069616962696369646965696669676968696969706971697269736974697569766977697869796980698169826983698469856986698769886989699069916992699369946995699669976998699970007001700270037004700570067007700870097010701170127013701470157016701770187019702070217022702370247025702670277028702970307031703270337034703570367037703870397040704170427043704470457046704770487049705070517052705370547055705670577058705970607061706270637064706570667067706870697070707170727073707470757076707770787079708070817082708370847085708670877088708970907091709270937094709570967097709870997100710171027103710471057106710771087109711071117112711371147115711671177118711971207121712271237124712571267127712871297130713171327133713471357136713771387139714071417142714371447145714671477148714971507151715271537154715571567157715871597160716171627163716471657166716771687169717071717172717371747175717671777178717971807181718271837184718571867187718871897190719171927193719471957196719771987199720072017202720372047205720672077208720972107211721272137214721572167217721872197220722172227223722472257226722772287229723072317232723372347235723672377238723972407241724272437244724572467247724872497250725172527253725472557256725772587259726072617262726372647265726672677268726972707271727272737274727572767277727872797280728172827283728472857286728772887289729072917292729372947295729672977298729973007301730273037304730573067307730873097310731173127313731473157316731773187319732073217322732373247325732673277328732973307331733273337334733573367337733873397340734173427343734473457346734773487349735073517352735373547355735673577358735973607361736273637364736573667367736873697370737173727373737473757376737773787379738073817382738373847385738673877388738973907391739273937394739573967397739873997400740174027403740474057406740774087409741074117412741374147415741674177418741974207421742274237424742574267427742874297430743174327433743474357436743774387439744074417442744374447445744674477448744974507451745274537454745574567457745874597460746174627463746474657466746774687469747074717472747374747475747674777478747974807481748274837484748574867487748874897490749174927493749474957496749774987499750075017502750375047505750675077508750975107511751275137514751575167517751875197520752175227523752475257526752775287529753075317532753375347535753675377538753975407541754275437544754575467547754875497550755175527553755475557556755775587559756075617562756375647565756675677568756975707571757275737574757575767577757875797580758175827583758475857586758775887589759075917592759375947595759675977598759976007601760276037604760576067607760876097610761176127613761476157616761776187619762076217622762376247625762676277628762976307631763276337634763576367637763876397640764176427643764476457646764776487649765076517652765376547655765676577658765976607661766276637664766576667667766876697670767176727673767476757676767776787679768076817682768376847685768676877688768976907691769276937694769576967697769876997700770177027703770477057706770777087709771077117712771377147715771677177718771977207721772277237724772577267727772877297730773177327733773477357736773777387739774077417742774377447745774677477748774977507751775277537754775577567757775877597760776177627763776477657766776777687769777077717772777377747775777677777778777977807781778277837784778577867787778877897790779177927793779477957796779777987799780078017802780378047805780678077808780978107811781278137814781578167817781878197820782178227823782478257826782778287829783078317832783378347835783678377838783978407841784278437844784578467847784878497850785178527853785478557856785778587859786078617862786378647865786678677868786978707871787278737874787578767877787878797880788178827883788478857886788778887889789078917892789378947895789678977898789979007901790279037904790579067907790879097910791179127913791479157916791779187919792079217922792379247925792679277928792979307931793279337934793579367937793879397940794179427943794479457946794779487949795079517952795379547955795679577958795979607961796279637964796579667967796879697970797179727973797479757976797779787979798079817982798379847985798679877988798979907991799279937994799579967997799879998000800180028003800480058006800780088009801080118012801380148015801680178018801980208021802280238024802580268027802880298030803180328033803480358036803780388039804080418042804380448045804680478048804980508051805280538054805580568057805880598060806180628063806480658066806780688069807080718072807380748075807680778078807980808081808280838084808580868087808880898090809180928093809480958096809780988099810081018102810381048105810681078108810981108111811281138114811581168117811881198120812181228123812481258126812781288129813081318132813381348135813681378138813981408141814281438144814581468147814881498150815181528153815481558156815781588159816081618162816381648165816681678168816981708171817281738174817581768177817881798180818181828183818481858186818781888189819081918192819381948195819681978198819982008201820282038204820582068207820882098210821182128213821482158216821782188219822082218222822382248225822682278228822982308231823282338234823582368237823882398240824182428243824482458246824782488249825082518252825382548255825682578258825982608261826282638264826582668267826882698270827182728273827482758276827782788279828082818282828382848285828682878288828982908291829282938294829582968297829882998300830183028303830483058306830783088309831083118312831383148315831683178318831983208321832283238324832583268327832883298330833183328333833483358336833783388339834083418342834383448345834683478348834983508351835283538354835583568357835883598360836183628363836483658366836783688369837083718372837383748375837683778378837983808381838283838384838583868387838883898390839183928393839483958396839783988399840084018402840384048405840684078408840984108411841284138414841584168417841884198420842184228423842484258426842784288429843084318432843384348435843684378438843984408441844284438444844584468447844884498450845184528453845484558456845784588459846084618462846384648465846684678468846984708471847284738474847584768477847884798480848184828483848484858486848784888489849084918492849384948495849684978498849985008501850285038504850585068507850885098510851185128513851485158516851785188519852085218522852385248525852685278528852985308531853285338534853585368537853885398540854185428543854485458546854785488549855085518552855385548555855685578558855985608561856285638564856585668567856885698570857185728573857485758576857785788579858085818582858385848585858685878588858985908591859285938594859585968597859885998600860186028603860486058606860786088609861086118612861386148615861686178618861986208621862286238624862586268627862886298630863186328633863486358636863786388639864086418642864386448645864686478648864986508651865286538654865586568657865886598660866186628663866486658666866786688669867086718672867386748675867686778678867986808681868286838684868586868687868886898690869186928693869486958696869786988699870087018702870387048705870687078708870987108711871287138714871587168717871887198720872187228723872487258726872787288729873087318732873387348735873687378738873987408741874287438744874587468747874887498750875187528753875487558756875787588759876087618762876387648765876687678768876987708771877287738774877587768777877887798780878187828783878487858786878787888789879087918792879387948795879687978798879988008801880288038804880588068807880888098810881188128813881488158816881788188819882088218822882388248825882688278828882988308831883288338834883588368837883888398840884188428843884488458846884788488849885088518852885388548855885688578858885988608861886288638864886588668867886888698870887188728873887488758876887788788879888088818882888388848885888688878888888988908891889288938894889588968897889888998900890189028903890489058906890789088909891089118912891389148915891689178918891989208921892289238924892589268927892889298930893189328933893489358936893789388939894089418942894389448945894689478948894989508951895289538954895589568957895889598960896189628963896489658966896789688969897089718972897389748975897689778978897989808981898289838984898589868987898889898990899189928993899489958996899789988999900090019002900390049005900690079008900990109011901290139014901590169017901890199020902190229023902490259026902790289029903090319032903390349035903690379038903990409041904290439044904590469047904890499050905190529053905490559056905790589059906090619062906390649065906690679068906990709071907290739074907590769077907890799080908190829083908490859086908790889089909090919092909390949095909690979098909991009101910291039104910591069107910891099110911191129113911491159116911791189119912091219122912391249125912691279128912991309131913291339134913591369137913891399140914191429143914491459146914791489149915091519152915391549155915691579158915991609161916291639164916591669167916891699170917191729173917491759176917791789179918091819182918391849185918691879188918991909191919291939194919591969197919891999200920192029203920492059206920792089209921092119212921392149215921692179218921992209221922292239224922592269227922892299230923192329233923492359236923792389239924092419242924392449245924692479248924992509251925292539254925592569257925892599260926192629263926492659266926792689269927092719272927392749275927692779278927992809281928292839284928592869287928892899290929192929293929492959296929792989299930093019302930393049305930693079308930993109311931293139314931593169317931893199320932193229323932493259326932793289329933093319332933393349335933693379338933993409341934293439344934593469347934893499350935193529353935493559356935793589359936093619362936393649365936693679368936993709371937293739374937593769377937893799380938193829383938493859386938793889389939093919392939393949395939693979398939994009401940294039404940594069407940894099410941194129413941494159416941794189419942094219422942394249425942694279428942994309431943294339434943594369437943894399440944194429443944494459446944794489449945094519452945394549455945694579458945994609461946294639464946594669467946894699470947194729473947494759476947794789479948094819482948394849485948694879488948994909491949294939494949594969497949894999500950195029503950495059506950795089509951095119512951395149515951695179518951995209521952295239524952595269527952895299530953195329533953495359536953795389539954095419542954395449545954695479548954995509551955295539554955595569557955895599560956195629563956495659566956795689569957095719572957395749575957695779578957995809581958295839584958595869587958895899590959195929593959495959596959795989599960096019602960396049605960696079608960996109611961296139614961596169617961896199620962196229623962496259626962796289629963096319632963396349635963696379638963996409641964296439644964596469647964896499650965196529653965496559656965796589659966096619662966396649665966696679668966996709671967296739674967596769677967896799680968196829683968496859686968796889689969096919692969396949695969696979698969997009701970297039704970597069707970897099710971197129713971497159716971797189719972097219722972397249725972697279728972997309731973297339734973597369737973897399740974197429743974497459746974797489749975097519752975397549755975697579758975997609761976297639764976597669767976897699770977197729773977497759776977797789779978097819782978397849785978697879788978997909791979297939794979597969797979897999800980198029803980498059806980798089809981098119812981398149815981698179818981998209821982298239824982598269827982898299830983198329833983498359836983798389839984098419842984398449845984698479848984998509851985298539854985598569857985898599860986198629863986498659866986798689869987098719872987398749875987698779878987998809881988298839884988598869887988898899890989198929893989498959896989798989899990099019902990399049905990699079908990999109911991299139914991599169917991899199920992199229923992499259926992799289929993099319932993399349935993699379938993999409941994299439944994599469947994899499950995199529953995499559956995799589959996099619962996399649965996699679968996999709971997299739974997599769977997899799980998199829983998499859986998799889989999099919992999399949995999699979998999910000100011000210003100041000510006100071000810009100101001110012100131001410015100161001710018100191002010021100221002310024100251002610027100281002910030100311003210033100341003510036100371003810039100401004110042100431004410045100461004710048100491005010051100521005310054100551005610057100581005910060100611006210063100641006510066100671006810069100701007110072100731007410075100761007710078100791008010081100821008310084100851008610087100881008910090100911009210093100941009510096100971009810099101001010110102101031010410105101061010710108101091011010111101121011310114101151011610117101181011910120101211012210123101241012510126101271012810129101301013110132101331013410135101361013710138101391014010141101421014310144101451014610147101481014910150101511015210153101541015510156101571015810159101601016110162101631016410165101661016710168101691017010171101721017310174101751017610177101781017910180101811018210183101841018510186101871018810189101901019110192101931019410195101961019710198101991020010201102021020310204102051020610207102081020910210102111021210213102141021510216102171021810219102201022110222102231022410225102261022710228102291023010231102321023310234102351023610237102381023910240102411024210243102441024510246102471024810249102501025110252102531025410255102561025710258102591026010261102621026310264102651026610267102681026910270102711027210273102741027510276102771027810279102801028110282102831028410285102861028710288102891029010291102921029310294102951029610297102981029910300103011030210303103041030510306103071030810309103101031110312103131031410315103161031710318103191032010321103221032310324103251032610327103281032910330103311033210333103341033510336103371033810339103401034110342103431034410345103461034710348103491035010351103521035310354103551035610357103581035910360103611036210363103641036510366103671036810369103701037110372103731037410375103761037710378103791038010381103821038310384103851038610387103881038910390103911039210393103941039510396103971039810399104001040110402104031040410405104061040710408104091041010411104121041310414104151041610417104181041910420104211042210423104241042510426104271042810429104301043110432104331043410435104361043710438104391044010441104421044310444104451044610447104481044910450104511045210453104541045510456104571045810459104601046110462104631046410465104661046710468104691047010471104721047310474104751047610477104781047910480104811048210483104841048510486104871048810489104901049110492104931049410495104961049710498104991050010501105021050310504105051050610507105081050910510105111051210513105141051510516105171051810519105201052110522105231052410525105261052710528105291053010531105321053310534105351053610537105381053910540105411054210543105441054510546105471054810549105501055110552105531055410555105561055710558105591056010561105621056310564105651056610567105681056910570105711057210573105741057510576105771057810579105801058110582105831058410585105861058710588105891059010591105921059310594105951059610597105981059910600106011060210603106041060510606106071060810609106101061110612106131061410615106161061710618106191062010621106221062310624106251062610627106281062910630106311063210633106341063510636106371063810639106401064110642106431064410645106461064710648106491065010651106521065310654106551065610657106581065910660106611066210663106641066510666106671066810669106701067110672106731067410675106761067710678106791068010681106821068310684106851068610687106881068910690106911069210693106941069510696106971069810699107001070110702107031070410705107061070710708107091071010711107121071310714107151071610717107181071910720107211072210723107241072510726107271072810729107301073110732107331073410735107361073710738107391074010741107421074310744107451074610747107481074910750107511075210753107541075510756107571075810759107601076110762107631076410765107661076710768107691077010771107721077310774107751077610777107781077910780107811078210783107841078510786107871078810789107901079110792107931079410795107961079710798107991080010801108021080310804108051080610807108081080910810108111081210813108141081510816108171081810819108201082110822108231082410825108261082710828108291083010831108321083310834108351083610837108381083910840108411084210843108441084510846108471084810849108501085110852108531085410855108561085710858108591086010861108621086310864108651086610867108681086910870108711087210873108741087510876108771087810879108801088110882108831088410885108861088710888108891089010891108921089310894108951089610897108981089910900109011090210903109041090510906109071090810909109101091110912109131091410915109161091710918109191092010921109221092310924109251092610927109281092910930109311093210933109341093510936109371093810939109401094110942109431094410945109461094710948109491095010951109521095310954109551095610957109581095910960109611096210963109641096510966109671096810969109701097110972109731097410975109761097710978109791098010981109821098310984109851098610987109881098910990109911099210993109941099510996109971099810999110001100111002110031100411005110061100711008110091101011011110121101311014110151101611017110181101911020110211102211023110241102511026110271102811029110301103111032110331103411035110361103711038110391104011041110421104311044110451104611047110481104911050110511105211053110541105511056110571105811059110601106111062110631106411065110661106711068110691107011071110721107311074110751107611077110781107911080110811108211083110841108511086110871108811089110901109111092110931109411095110961109711098110991110011101111021110311104111051110611107111081110911110111111111211113111141111511116111171111811119111201112111122111231112411125111261112711128111291113011131111321113311134111351113611137111381113911140111411114211143111441114511146111471114811149111501115111152111531115411155111561115711158111591116011161111621116311164111651116611167111681116911170111711117211173111741117511176111771117811179111801118111182111831118411185111861118711188111891119011191111921119311194111951119611197111981119911200112011120211203112041120511206112071120811209112101121111212112131121411215112161121711218112191122011221112221122311224112251122611227112281122911230112311123211233112341123511236112371123811239112401124111242112431124411245112461124711248112491125011251112521125311254112551125611257112581125911260112611126211263112641126511266112671126811269112701127111272112731127411275112761127711278112791128011281112821128311284112851128611287112881128911290112911129211293112941129511296112971129811299113001130111302113031130411305113061130711308113091131011311113121131311314113151131611317113181131911320113211132211323113241132511326113271132811329113301133111332113331133411335113361133711338113391134011341113421134311344113451134611347113481134911350113511135211353113541135511356113571135811359113601136111362113631136411365113661136711368113691137011371113721137311374113751137611377113781137911380113811138211383113841138511386113871138811389113901139111392113931139411395113961139711398113991140011401114021140311404114051140611407114081140911410114111141211413114141141511416114171141811419114201142111422114231142411425114261142711428114291143011431114321143311434114351143611437114381143911440114411144211443114441144511446114471144811449114501145111452114531145411455114561145711458114591146011461114621146311464114651146611467114681146911470114711147211473114741147511476114771147811479114801148111482114831148411485114861148711488114891149011491114921149311494114951149611497114981149911500115011150211503115041150511506115071150811509115101151111512115131151411515115161151711518115191152011521115221152311524115251152611527115281152911530115311153211533115341153511536115371153811539115401154111542115431154411545115461154711548115491155011551115521155311554115551155611557115581155911560115611156211563115641156511566115671156811569115701157111572115731157411575115761157711578115791158011581115821158311584115851158611587115881158911590115911159211593115941159511596115971159811599116001160111602116031160411605116061160711608116091161011611116121161311614116151161611617116181161911620116211162211623116241162511626116271162811629116301163111632116331163411635116361163711638116391164011641116421164311644116451164611647116481164911650116511165211653116541165511656116571165811659116601166111662116631166411665116661166711668116691167011671116721167311674116751167611677116781167911680116811168211683116841168511686116871168811689116901169111692116931169411695116961169711698116991170011701117021170311704117051170611707117081170911710117111171211713117141171511716117171171811719117201172111722117231172411725117261172711728117291173011731117321173311734117351173611737117381173911740117411174211743117441174511746117471174811749117501175111752117531175411755117561175711758117591176011761117621176311764117651176611767117681176911770117711177211773117741177511776117771177811779117801178111782117831178411785117861178711788117891179011791117921179311794117951179611797117981179911800118011180211803118041180511806118071180811809118101181111812118131181411815118161181711818118191182011821118221182311824118251182611827118281182911830118311183211833118341183511836118371183811839118401184111842118431184411845118461184711848118491185011851118521185311854118551185611857118581185911860118611186211863118641186511866118671186811869118701187111872118731187411875118761187711878118791188011881118821188311884118851188611887118881188911890118911189211893118941189511896118971189811899119001190111902119031190411905119061190711908119091191011911119121191311914119151191611917119181191911920119211192211923119241192511926119271192811929119301193111932119331193411935119361193711938119391194011941119421194311944119451194611947119481194911950119511195211953119541195511956119571195811959119601196111962119631196411965119661196711968119691197011971119721197311974119751197611977119781197911980119811198211983119841198511986119871198811989119901199111992119931199411995119961199711998119991200012001120021200312004120051200612007120081200912010120111201212013120141201512016120171201812019120201202112022120231202412025120261202712028120291203012031120321203312034120351203612037120381203912040120411204212043120441204512046120471204812049120501205112052120531205412055120561205712058120591206012061120621206312064120651206612067120681206912070120711207212073120741207512076120771207812079120801208112082120831208412085120861208712088120891209012091120921209312094120951209612097120981209912100121011210212103121041210512106121071210812109121101211112112121131211412115121161211712118121191212012121121221212312124121251212612127121281212912130121311213212133121341213512136121371213812139121401214112142121431214412145121461214712148121491215012151121521215312154121551215612157121581215912160121611216212163121641216512166121671216812169121701217112172121731217412175121761217712178121791218012181121821218312184121851218612187121881218912190121911219212193121941219512196121971219812199122001220112202122031220412205122061220712208122091221012211122121221312214122151221612217122181221912220122211222212223122241222512226122271222812229122301223112232122331223412235122361223712238122391224012241122421224312244122451224612247122481224912250122511225212253122541225512256122571225812259122601226112262122631226412265122661226712268122691227012271122721227312274122751227612277122781227912280122811228212283122841228512286122871228812289122901229112292122931229412295122961229712298122991230012301123021230312304123051230612307123081230912310123111231212313123141231512316123171231812319123201232112322123231232412325123261232712328123291233012331123321233312334123351233612337123381233912340123411234212343123441234512346123471234812349123501235112352123531235412355123561235712358123591236012361123621236312364123651236612367123681236912370123711237212373123741237512376123771237812379123801238112382123831238412385123861238712388123891239012391123921239312394123951239612397123981239912400124011240212403124041240512406124071240812409124101241112412124131241412415124161241712418124191242012421124221242312424124251242612427124281242912430124311243212433124341243512436124371243812439124401244112442124431244412445124461244712448124491245012451124521245312454124551245612457124581245912460124611246212463124641246512466124671246812469124701247112472124731247412475124761247712478124791248012481124821248312484124851248612487124881248912490124911249212493124941249512496124971249812499125001250112502125031250412505125061250712508125091251012511125121251312514125151251612517125181251912520125211252212523125241252512526125271252812529125301253112532125331253412535125361253712538125391254012541125421254312544125451254612547125481254912550125511255212553125541255512556125571255812559125601256112562125631256412565125661256712568125691257012571125721257312574125751257612577125781257912580125811258212583125841258512586125871258812589125901259112592125931259412595125961259712598125991260012601126021260312604126051260612607126081260912610126111261212613126141261512616126171261812619126201262112622126231262412625126261262712628126291263012631126321263312634126351263612637126381263912640126411264212643126441264512646126471264812649126501265112652126531265412655126561265712658126591266012661126621266312664126651266612667126681266912670126711267212673126741267512676126771267812679126801268112682126831268412685126861268712688126891269012691126921269312694126951269612697126981269912700127011270212703127041270512706127071270812709127101271112712127131271412715127161271712718127191272012721127221272312724127251272612727127281272912730127311273212733127341273512736127371273812739127401274112742127431274412745127461274712748127491275012751127521275312754127551275612757127581275912760127611276212763127641276512766127671276812769127701277112772127731277412775127761277712778127791278012781127821278312784127851278612787127881278912790127911279212793127941279512796127971279812799128001280112802128031280412805128061280712808128091281012811128121281312814128151281612817128181281912820128211282212823128241282512826128271282812829128301283112832128331283412835128361283712838128391284012841128421284312844128451284612847128481284912850128511285212853128541285512856128571285812859128601286112862128631286412865128661286712868128691287012871128721287312874128751287612877128781287912880128811288212883128841288512886128871288812889128901289112892128931289412895128961289712898128991290012901129021290312904129051290612907129081290912910129111291212913129141291512916129171291812919129201292112922129231292412925129261292712928129291293012931129321293312934129351293612937129381293912940129411294212943129441294512946129471294812949129501295112952129531295412955129561295712958129591296012961129621296312964129651296612967129681296912970129711297212973129741297512976129771297812979129801298112982129831298412985129861298712988129891299012991129921299312994129951299612997129981299913000130011300213003130041300513006130071300813009130101301113012130131301413015130161301713018130191302013021130221302313024130251302613027130281302913030130311303213033130341303513036130371303813039130401304113042130431304413045130461304713048130491305013051130521305313054130551305613057130581305913060130611306213063130641306513066130671306813069130701307113072130731307413075130761307713078130791308013081130821308313084130851308613087130881308913090130911309213093130941309513096130971309813099131001310113102131031310413105131061310713108131091311013111131121311313114131151311613117131181311913120131211312213123131241312513126131271312813129131301313113132131331313413135131361313713138131391314013141131421314313144131451314613147131481314913150131511315213153131541315513156131571315813159131601316113162131631316413165131661316713168131691317013171131721317313174131751317613177131781317913180131811318213183131841318513186131871318813189131901319113192131931319413195131961319713198131991320013201132021320313204132051320613207132081320913210132111321213213132141321513216132171321813219132201322113222132231322413225132261322713228132291323013231132321323313234132351323613237132381323913240132411324213243132441324513246132471324813249132501325113252132531325413255132561325713258132591326013261132621326313264132651326613267132681326913270132711327213273132741327513276132771327813279132801328113282132831328413285132861328713288132891329013291132921329313294132951329613297132981329913300133011330213303133041330513306133071330813309133101331113312133131331413315133161331713318133191332013321133221332313324133251332613327133281332913330133311333213333133341333513336133371333813339133401334113342133431334413345133461334713348133491335013351133521335313354133551335613357133581335913360133611336213363133641336513366133671336813369133701337113372133731337413375133761337713378133791338013381133821338313384133851338613387133881338913390133911339213393133941339513396133971339813399134001340113402134031340413405134061340713408134091341013411134121341313414134151341613417134181341913420134211342213423134241342513426134271342813429134301343113432134331343413435134361343713438134391344013441134421344313444134451344613447134481344913450134511345213453134541345513456134571345813459134601346113462134631346413465134661346713468134691347013471134721347313474134751347613477134781347913480134811348213483134841348513486134871348813489134901349113492134931349413495134961349713498134991350013501135021350313504135051350613507135081350913510135111351213513135141351513516135171351813519135201352113522135231352413525135261352713528135291353013531135321353313534135351353613537135381353913540135411354213543135441354513546135471354813549135501355113552135531355413555135561355713558135591356013561135621356313564135651356613567135681356913570135711357213573135741357513576135771357813579135801358113582135831358413585135861358713588135891359013591135921359313594135951359613597135981359913600136011360213603136041360513606136071360813609136101361113612136131361413615136161361713618136191362013621136221362313624136251362613627136281362913630136311363213633136341363513636136371363813639136401364113642136431364413645136461364713648136491365013651136521365313654136551365613657136581365913660136611366213663136641366513666136671366813669136701367113672136731367413675136761367713678136791368013681136821368313684136851368613687136881368913690136911369213693136941369513696136971369813699137001370113702137031370413705137061370713708137091371013711137121371313714137151371613717137181371913720137211372213723137241372513726137271372813729137301373113732137331373413735137361373713738137391374013741137421374313744137451374613747137481374913750137511375213753137541375513756137571375813759137601376113762137631376413765137661376713768137691377013771137721377313774137751377613777137781377913780137811378213783137841378513786137871378813789137901379113792137931379413795137961379713798137991380013801138021380313804138051380613807138081380913810138111381213813138141381513816138171381813819138201382113822138231382413825138261382713828138291383013831138321383313834138351383613837138381383913840138411384213843138441384513846138471384813849138501385113852138531385413855138561385713858138591386013861138621386313864138651386613867138681386913870138711387213873138741387513876138771387813879138801388113882138831388413885138861388713888138891389013891138921389313894138951389613897138981389913900139011390213903139041390513906139071390813909139101391113912139131391413915139161391713918139191392013921139221392313924139251392613927139281392913930139311393213933139341393513936139371393813939139401394113942139431394413945139461394713948139491395013951139521395313954139551395613957139581395913960139611396213963139641396513966139671396813969139701397113972139731397413975139761397713978139791398013981139821398313984139851398613987139881398913990139911399213993139941399513996139971399813999140001400114002140031400414005140061400714008140091401014011140121401314014140151401614017140181401914020140211402214023140241402514026140271402814029140301403114032140331403414035140361403714038140391404014041140421404314044140451404614047140481404914050140511405214053140541405514056140571405814059140601406114062140631406414065140661406714068140691407014071140721407314074140751407614077140781407914080140811408214083140841408514086140871408814089140901409114092140931409414095140961409714098140991410014101141021410314104141051410614107141081410914110141111411214113141141411514116141171411814119141201412114122141231412414125141261412714128141291413014131141321413314134141351413614137141381413914140141411414214143141441414514146141471414814149141501415114152141531415414155141561415714158141591416014161141621416314164141651416614167141681416914170141711417214173141741417514176141771417814179141801418114182141831418414185141861418714188141891419014191141921419314194141951419614197141981419914200142011420214203142041420514206142071420814209142101421114212142131421414215142161421714218142191422014221142221422314224142251422614227142281422914230142311423214233142341423514236142371423814239142401424114242142431424414245142461424714248142491425014251142521425314254142551425614257142581425914260142611426214263142641426514266142671426814269142701427114272142731427414275142761427714278142791428014281142821428314284142851428614287142881428914290142911429214293142941429514296142971429814299143001430114302143031430414305143061430714308143091431014311143121431314314143151431614317143181431914320143211432214323143241432514326143271432814329143301433114332143331433414335143361433714338143391434014341143421434314344143451434614347143481434914350143511435214353143541435514356143571435814359143601436114362143631436414365143661436714368143691437014371143721437314374143751437614377143781437914380143811438214383143841438514386143871438814389143901439114392143931439414395143961439714398143991440014401144021440314404144051440614407144081440914410144111441214413144141441514416144171441814419144201442114422144231442414425144261442714428144291443014431144321443314434144351443614437144381443914440144411444214443144441444514446144471444814449144501445114452144531445414455144561445714458144591446014461144621446314464144651446614467144681446914470144711447214473144741447514476144771447814479144801448114482144831448414485144861448714488144891449014491144921449314494144951449614497144981449914500145011450214503145041450514506145071450814509145101451114512145131451414515145161451714518145191452014521145221452314524145251452614527145281452914530145311453214533145341453514536145371453814539145401454114542145431454414545145461454714548145491455014551145521455314554145551455614557145581455914560145611456214563145641456514566145671456814569145701457114572145731457414575145761457714578145791458014581145821458314584145851458614587145881458914590145911459214593145941459514596145971459814599146001460114602146031460414605146061460714608146091461014611146121461314614146151461614617146181461914620146211462214623146241462514626146271462814629146301463114632146331463414635146361463714638146391464014641146421464314644146451464614647146481464914650146511465214653146541465514656146571465814659146601466114662146631466414665146661466714668146691467014671146721467314674146751467614677146781467914680146811468214683146841468514686146871468814689146901469114692146931469414695146961469714698146991470014701147021470314704147051470614707147081470914710147111471214713147141471514716147171471814719147201472114722147231472414725147261472714728147291473014731147321473314734147351473614737147381473914740147411474214743147441474514746147471474814749147501475114752147531475414755147561475714758147591476014761147621476314764147651476614767147681476914770147711477214773147741477514776147771477814779147801478114782147831478414785147861478714788147891479014791147921479314794147951479614797147981479914800148011480214803148041480514806148071480814809148101481114812148131481414815148161481714818148191482014821148221482314824148251482614827148281482914830148311483214833148341483514836148371483814839148401484114842148431484414845148461484714848148491485014851148521485314854148551485614857148581485914860148611486214863148641486514866148671486814869148701487114872148731487414875148761487714878148791488014881148821488314884148851488614887148881488914890148911489214893148941489514896148971489814899149001490114902149031490414905149061490714908149091491014911149121491314914149151491614917149181491914920149211492214923149241492514926149271492814929149301493114932149331493414935149361493714938149391494014941149421494314944149451494614947149481494914950149511495214953149541495514956149571495814959149601496114962149631496414965149661496714968149691497014971149721497314974149751497614977149781497914980149811498214983149841498514986149871498814989149901499114992149931499414995149961499714998149991500015001150021500315004150051500615007150081500915010150111501215013150141501515016150171501815019150201502115022150231502415025150261502715028150291503015031150321503315034150351503615037150381503915040150411504215043150441504515046150471504815049150501505115052150531505415055150561505715058150591506015061150621506315064150651506615067150681506915070150711507215073150741507515076150771507815079150801508115082150831508415085150861508715088150891509015091150921509315094150951509615097150981509915100151011510215103151041510515106151071510815109151101511115112151131511415115151161511715118151191512015121151221512315124151251512615127151281512915130151311513215133151341513515136151371513815139151401514115142151431514415145151461514715148151491515015151151521515315154151551515615157151581515915160151611516215163151641516515166151671516815169151701517115172151731517415175151761517715178151791518015181151821518315184151851518615187151881518915190151911519215193151941519515196151971519815199152001520115202152031520415205152061520715208152091521015211152121521315214152151521615217152181521915220152211522215223152241522515226152271522815229152301523115232152331523415235152361523715238152391524015241152421524315244152451524615247152481524915250152511525215253152541525515256152571525815259152601526115262152631526415265152661526715268152691527015271152721527315274152751527615277152781527915280152811528215283152841528515286152871528815289152901529115292152931529415295152961529715298152991530015301153021530315304153051530615307153081530915310153111531215313153141531515316153171531815319153201532115322153231532415325153261532715328153291533015331153321533315334153351533615337153381533915340153411534215343153441534515346153471534815349153501535115352153531535415355153561535715358153591536015361153621536315364153651536615367153681536915370153711537215373153741537515376153771537815379153801538115382153831538415385153861538715388153891539015391153921539315394153951539615397153981539915400154011540215403154041540515406154071540815409154101541115412154131541415415154161541715418154191542015421154221542315424154251542615427154281542915430154311543215433154341543515436154371543815439154401544115442154431544415445154461544715448154491545015451154521545315454154551545615457154581545915460154611546215463154641546515466154671546815469154701547115472154731547415475154761547715478154791548015481154821548315484154851548615487154881548915490154911549215493154941549515496154971549815499155001550115502155031550415505155061550715508155091551015511155121551315514155151551615517155181551915520155211552215523155241552515526155271552815529155301553115532155331553415535155361553715538155391554015541155421554315544155451554615547155481554915550155511555215553155541555515556155571555815559155601556115562155631556415565155661556715568155691557015571155721557315574155751557615577155781557915580155811558215583155841558515586155871558815589155901559115592155931559415595155961559715598155991560015601156021560315604156051560615607156081560915610156111561215613156141561515616156171561815619156201562115622156231562415625156261562715628156291563015631156321563315634156351563615637156381563915640156411564215643156441564515646156471564815649156501565115652156531565415655156561565715658156591566015661156621566315664156651566615667156681566915670156711567215673156741567515676156771567815679156801568115682156831568415685156861568715688156891569015691156921569315694156951569615697156981569915700157011570215703157041570515706157071570815709157101571115712157131571415715157161571715718157191572015721157221572315724157251572615727157281572915730157311573215733157341573515736157371573815739157401574115742157431574415745157461574715748157491575015751157521575315754157551575615757157581575915760157611576215763157641576515766157671576815769157701577115772157731577415775157761577715778157791578015781157821578315784157851578615787157881578915790157911579215793157941579515796157971579815799158001580115802158031580415805158061580715808158091581015811158121581315814158151581615817158181581915820158211582215823158241582515826158271582815829158301583115832158331583415835158361583715838158391584015841158421584315844158451584615847158481584915850158511585215853158541585515856158571585815859158601586115862158631586415865158661586715868158691587015871158721587315874158751587615877158781587915880158811588215883158841588515886158871588815889158901589115892158931589415895158961589715898158991590015901159021590315904159051590615907159081590915910159111591215913159141591515916159171591815919159201592115922159231592415925159261592715928159291593015931159321593315934159351593615937159381593915940159411594215943159441594515946159471594815949159501595115952159531595415955159561595715958159591596015961159621596315964159651596615967159681596915970159711597215973159741597515976159771597815979159801598115982159831598415985159861598715988159891599015991159921599315994159951599615997159981599916000160011600216003160041600516006160071600816009160101601116012160131601416015160161601716018160191602016021160221602316024160251602616027160281602916030160311603216033160341603516036160371603816039160401604116042160431604416045160461604716048160491605016051160521605316054160551605616057160581605916060160611606216063160641606516066160671606816069160701607116072160731607416075160761607716078160791608016081160821608316084160851608616087160881608916090160911609216093160941609516096160971609816099161001610116102161031610416105161061610716108161091611016111161121611316114161151611616117161181611916120161211612216123161241612516126161271612816129161301613116132161331613416135161361613716138161391614016141161421614316144161451614616147161481614916150161511615216153161541615516156161571615816159161601616116162161631616416165161661616716168161691617016171161721617316174161751617616177161781617916180161811618216183161841618516186161871618816189161901619116192161931619416195161961619716198161991620016201162021620316204162051620616207162081620916210162111621216213162141621516216162171621816219162201622116222162231622416225162261622716228162291623016231162321623316234162351623616237162381623916240162411624216243162441624516246162471624816249162501625116252162531625416255162561625716258162591626016261162621626316264162651626616267162681626916270162711627216273162741627516276162771627816279162801628116282162831628416285162861628716288162891629016291162921629316294162951629616297162981629916300163011630216303163041630516306163071630816309163101631116312163131631416315163161631716318163191632016321163221632316324163251632616327163281632916330163311633216333163341633516336163371633816339163401634116342163431634416345163461634716348163491635016351163521635316354163551635616357163581635916360163611636216363163641636516366163671636816369163701637116372163731637416375163761637716378163791638016381163821638316384163851638616387163881638916390163911639216393163941639516396163971639816399164001640116402164031640416405164061640716408164091641016411164121641316414164151641616417164181641916420164211642216423164241642516426164271642816429164301643116432164331643416435164361643716438164391644016441164421644316444164451644616447164481644916450164511645216453164541645516456164571645816459164601646116462164631646416465164661646716468164691647016471164721647316474164751647616477164781647916480164811648216483164841648516486164871648816489164901649116492164931649416495164961649716498164991650016501165021650316504165051650616507165081650916510165111651216513165141651516516165171651816519165201652116522165231652416525165261652716528165291653016531165321653316534165351653616537165381653916540165411654216543165441654516546165471654816549165501655116552165531655416555165561655716558165591656016561165621656316564165651656616567165681656916570165711657216573165741657516576165771657816579165801658116582165831658416585165861658716588165891659016591165921659316594165951659616597165981659916600166011660216603166041660516606166071660816609166101661116612166131661416615166161661716618166191662016621166221662316624166251662616627166281662916630166311663216633166341663516636166371663816639166401664116642166431664416645166461664716648166491665016651166521665316654166551665616657166581665916660166611666216663166641666516666166671666816669166701667116672166731667416675166761667716678166791668016681166821668316684166851668616687166881668916690166911669216693166941669516696166971669816699167001670116702167031670416705167061670716708167091671016711167121671316714167151671616717167181671916720167211672216723167241672516726167271672816729167301673116732167331673416735167361673716738167391674016741167421674316744167451674616747167481674916750167511675216753167541675516756167571675816759167601676116762167631676416765167661676716768167691677016771167721677316774167751677616777167781677916780167811678216783167841678516786167871678816789167901679116792167931679416795167961679716798167991680016801168021680316804168051680616807168081680916810168111681216813168141681516816168171681816819168201682116822168231682416825168261682716828168291683016831168321683316834168351683616837168381683916840168411684216843168441684516846168471684816849168501685116852168531685416855168561685716858168591686016861168621686316864168651686616867168681686916870168711687216873168741687516876168771687816879168801688116882168831688416885168861688716888168891689016891168921689316894168951689616897168981689916900169011690216903169041690516906169071690816909169101691116912169131691416915169161691716918169191692016921169221692316924169251692616927169281692916930169311693216933169341693516936169371693816939169401694116942169431694416945169461694716948169491695016951169521695316954169551695616957169581695916960169611696216963169641696516966169671696816969169701697116972169731697416975169761697716978169791698016981169821698316984169851698616987169881698916990169911699216993169941699516996169971699816999170001700117002170031700417005170061700717008170091701017011170121701317014170151701617017170181701917020170211702217023170241702517026170271702817029170301703117032170331703417035170361703717038170391704017041170421704317044170451704617047170481704917050170511705217053170541705517056170571705817059170601706117062170631706417065170661706717068170691707017071170721707317074170751707617077170781707917080170811708217083170841708517086170871708817089170901709117092170931709417095170961709717098170991710017101171021710317104171051710617107171081710917110171111711217113171141711517116171171711817119171201712117122171231712417125171261712717128171291713017131171321713317134171351713617137171381713917140171411714217143171441714517146171471714817149171501715117152171531715417155171561715717158171591716017161171621716317164171651716617167171681716917170171711717217173171741717517176171771717817179171801718117182171831718417185171861718717188171891719017191171921719317194171951719617197171981719917200172011720217203172041720517206172071720817209172101721117212172131721417215172161721717218172191722017221172221722317224172251722617227172281722917230172311723217233172341723517236172371723817239172401724117242172431724417245172461724717248172491725017251172521725317254172551725617257172581725917260172611726217263172641726517266172671726817269172701727117272172731727417275172761727717278172791728017281172821728317284172851728617287172881728917290172911729217293172941729517296172971729817299173001730117302173031730417305173061730717308173091731017311173121731317314173151731617317173181731917320173211732217323173241732517326173271732817329173301733117332173331733417335173361733717338173391734017341173421734317344173451734617347173481734917350173511735217353173541735517356173571735817359173601736117362173631736417365173661736717368173691737017371173721737317374173751737617377173781737917380173811738217383173841738517386173871738817389173901739117392173931739417395173961739717398173991740017401174021740317404174051740617407174081740917410174111741217413174141741517416174171741817419174201742117422174231742417425174261742717428174291743017431174321743317434174351743617437174381743917440174411744217443174441744517446174471744817449174501745117452174531745417455174561745717458174591746017461174621746317464174651746617467174681746917470174711747217473174741747517476174771747817479174801748117482174831748417485174861748717488174891749017491174921749317494174951749617497174981749917500175011750217503175041750517506175071750817509175101751117512175131751417515175161751717518175191752017521175221752317524175251752617527175281752917530175311753217533175341753517536175371753817539175401754117542175431754417545175461754717548175491755017551175521755317554175551755617557175581755917560175611756217563175641756517566175671756817569175701757117572175731757417575175761757717578175791758017581175821758317584175851758617587175881758917590175911759217593175941759517596175971759817599176001760117602176031760417605176061760717608176091761017611176121761317614176151761617617176181761917620176211762217623176241762517626176271762817629176301763117632176331763417635176361763717638176391764017641176421764317644176451764617647176481764917650176511765217653176541765517656176571765817659176601766117662176631766417665176661766717668176691767017671176721767317674176751767617677176781767917680176811768217683176841768517686176871768817689176901769117692176931769417695176961769717698176991770017701177021770317704177051770617707177081770917710177111771217713177141771517716177171771817719177201772117722177231772417725177261772717728177291773017731177321773317734177351773617737177381773917740177411774217743177441774517746177471774817749177501775117752177531775417755177561775717758177591776017761177621776317764177651776617767177681776917770177711777217773177741777517776177771777817779177801778117782177831778417785177861778717788177891779017791177921779317794177951779617797177981779917800178011780217803178041780517806178071780817809178101781117812178131781417815178161781717818178191782017821178221782317824178251782617827178281782917830178311783217833178341783517836178371783817839178401784117842178431784417845178461784717848178491785017851178521785317854178551785617857178581785917860178611786217863178641786517866178671786817869178701787117872178731787417875178761787717878178791788017881178821788317884178851788617887178881788917890178911789217893178941789517896178971789817899179001790117902179031790417905179061790717908179091791017911179121791317914179151791617917179181791917920179211792217923179241792517926179271792817929179301793117932179331793417935179361793717938179391794017941179421794317944179451794617947179481794917950179511795217953179541795517956179571795817959179601796117962179631796417965179661796717968179691797017971179721797317974179751797617977179781797917980179811798217983179841798517986179871798817989179901799117992179931799417995179961799717998179991800018001180021800318004180051800618007180081800918010180111801218013180141801518016180171801818019180201802118022180231802418025180261802718028180291803018031180321803318034180351803618037180381803918040180411804218043180441804518046180471804818049180501805118052180531805418055180561805718058180591806018061180621806318064180651806618067180681806918070180711807218073180741807518076180771807818079180801808118082180831808418085180861808718088180891809018091180921809318094180951809618097180981809918100181011810218103181041810518106181071810818109181101811118112181131811418115181161811718118181191812018121181221812318124181251812618127181281812918130181311813218133181341813518136181371813818139181401814118142181431814418145181461814718148181491815018151181521815318154181551815618157181581815918160181611816218163181641816518166181671816818169181701817118172181731817418175181761817718178181791818018181181821818318184181851818618187181881818918190181911819218193181941819518196181971819818199182001820118202182031820418205182061820718208182091821018211182121821318214182151821618217182181821918220182211822218223182241822518226182271822818229182301823118232182331823418235182361823718238182391824018241182421824318244182451824618247182481824918250182511825218253182541825518256182571825818259182601826118262182631826418265182661826718268182691827018271182721827318274182751827618277182781827918280182811828218283182841828518286182871828818289182901829118292182931829418295182961829718298182991830018301183021830318304183051830618307183081830918310183111831218313183141831518316183171831818319183201832118322183231832418325183261832718328183291833018331183321833318334183351833618337183381833918340183411834218343183441834518346183471834818349183501835118352183531835418355183561835718358183591836018361183621836318364183651836618367183681836918370183711837218373183741837518376183771837818379183801838118382183831838418385183861838718388183891839018391183921839318394183951839618397183981839918400184011840218403184041840518406184071840818409184101841118412184131841418415184161841718418184191842018421184221842318424184251842618427184281842918430184311843218433184341843518436184371843818439184401844118442184431844418445184461844718448184491845018451184521845318454184551845618457184581845918460184611846218463184641846518466184671846818469184701847118472184731847418475184761847718478184791848018481184821848318484184851848618487184881848918490184911849218493184941849518496184971849818499185001850118502185031850418505185061850718508185091851018511185121851318514185151851618517185181851918520185211852218523185241852518526185271852818529185301853118532185331853418535185361853718538185391854018541185421854318544185451854618547185481854918550185511855218553185541855518556185571855818559185601856118562185631856418565185661856718568185691857018571185721857318574185751857618577185781857918580185811858218583185841858518586185871858818589185901859118592185931859418595185961859718598185991860018601186021860318604186051860618607186081860918610186111861218613186141861518616186171861818619186201862118622186231862418625186261862718628186291863018631186321863318634186351863618637186381863918640186411864218643186441864518646186471864818649186501865118652186531865418655186561865718658186591866018661186621866318664186651866618667186681866918670186711867218673186741867518676186771867818679186801868118682186831868418685186861868718688186891869018691186921869318694186951869618697186981869918700187011870218703187041870518706187071870818709187101871118712187131871418715187161871718718187191872018721187221872318724187251872618727187281872918730187311873218733187341873518736187371873818739187401874118742187431874418745187461874718748187491875018751187521875318754187551875618757187581875918760187611876218763187641876518766187671876818769187701877118772187731877418775187761877718778187791878018781187821878318784187851878618787187881878918790187911879218793187941879518796187971879818799188001880118802188031880418805188061880718808188091881018811188121881318814188151881618817188181881918820188211882218823188241882518826188271882818829188301883118832188331883418835188361883718838188391884018841188421884318844188451884618847188481884918850188511885218853188541885518856188571885818859188601886118862188631886418865188661886718868188691887018871188721887318874188751887618877188781887918880188811888218883188841888518886188871888818889188901889118892188931889418895188961889718898188991890018901189021890318904189051890618907189081890918910189111891218913189141891518916189171891818919189201892118922189231892418925189261892718928189291893018931189321893318934189351893618937189381893918940189411894218943189441894518946189471894818949189501895118952189531895418955189561895718958189591896018961189621896318964189651896618967189681896918970189711897218973189741897518976189771897818979189801898118982189831898418985189861898718988189891899018991189921899318994189951899618997189981899919000190011900219003190041900519006190071900819009190101901119012190131901419015190161901719018190191902019021190221902319024190251902619027190281902919030190311903219033190341903519036190371903819039190401904119042190431904419045190461904719048190491905019051190521905319054190551905619057190581905919060190611906219063190641906519066190671906819069190701907119072190731907419075190761907719078190791908019081190821908319084190851908619087190881908919090190911909219093190941909519096190971909819099191001910119102191031910419105191061910719108191091911019111191121911319114191151911619117191181911919120191211912219123191241912519126191271912819129191301913119132191331913419135191361913719138191391914019141191421914319144191451914619147191481914919150191511915219153191541915519156191571915819159191601916119162191631916419165191661916719168191691917019171191721917319174191751917619177191781917919180191811918219183191841918519186191871918819189191901919119192191931919419195191961919719198191991920019201192021920319204192051920619207192081920919210192111921219213192141921519216192171921819219192201922119222192231922419225192261922719228192291923019231192321923319234192351923619237192381923919240192411924219243192441924519246192471924819249192501925119252192531925419255192561925719258192591926019261192621926319264192651926619267192681926919270192711927219273192741927519276192771927819279192801928119282192831928419285192861928719288192891929019291192921929319294192951929619297192981929919300193011930219303193041930519306193071930819309193101931119312193131931419315193161931719318193191932019321193221932319324193251932619327193281932919330193311933219333193341933519336193371933819339193401934119342193431934419345193461934719348193491935019351193521935319354193551935619357193581935919360193611936219363193641936519366193671936819369193701937119372193731937419375193761937719378193791938019381193821938319384193851938619387193881938919390193911939219393193941939519396193971939819399194001940119402194031940419405194061940719408194091941019411194121941319414194151941619417194181941919420194211942219423194241942519426194271942819429194301943119432194331943419435194361943719438194391944019441194421944319444194451944619447194481944919450194511945219453194541945519456194571945819459194601946119462194631946419465194661946719468194691947019471194721947319474194751947619477194781947919480194811948219483194841948519486194871948819489194901949119492194931949419495194961949719498194991950019501195021950319504195051950619507195081950919510195111951219513195141951519516195171951819519195201952119522195231952419525195261952719528195291953019531195321953319534195351953619537195381953919540195411954219543195441954519546195471954819549195501955119552195531955419555195561955719558195591956019561195621956319564195651956619567195681956919570195711957219573195741957519576195771957819579195801958119582195831958419585195861958719588195891959019591195921959319594195951959619597195981959919600196011960219603196041960519606196071960819609196101961119612196131961419615196161961719618196191962019621196221962319624196251962619627196281962919630196311963219633196341963519636196371963819639196401964119642196431964419645196461964719648196491965019651196521965319654196551965619657196581965919660196611966219663196641966519666196671966819669196701967119672196731967419675196761967719678196791968019681196821968319684196851968619687196881968919690196911969219693196941969519696196971969819699197001970119702197031970419705197061970719708197091971019711197121971319714197151971619717197181971919720197211972219723197241972519726197271972819729197301973119732197331973419735197361973719738197391974019741197421974319744197451974619747197481974919750197511975219753197541975519756197571975819759197601976119762197631976419765197661976719768197691977019771197721977319774197751977619777197781977919780197811978219783197841978519786197871978819789197901979119792197931979419795197961979719798197991980019801198021980319804198051980619807198081980919810198111981219813198141981519816198171981819819198201982119822198231982419825198261982719828198291983019831198321983319834198351983619837198381983919840198411984219843198441984519846198471984819849198501985119852198531985419855198561985719858198591986019861198621986319864198651986619867198681986919870198711987219873198741987519876198771987819879198801988119882198831988419885198861988719888198891989019891198921989319894198951989619897198981989919900199011990219903199041990519906199071990819909199101991119912199131991419915199161991719918199191992019921199221992319924199251992619927199281992919930199311993219933199341993519936199371993819939199401994119942199431994419945199461994719948199491995019951199521995319954199551995619957199581995919960199611996219963199641996519966199671996819969199701997119972199731997419975199761997719978199791998019981199821998319984199851998619987199881998919990199911999219993199941999519996199971999819999200002000120002200032000420005200062000720008200092001020011200122001320014200152001620017200182001920020200212002220023200242002520026200272002820029200302003120032200332003420035200362003720038200392004020041200422004320044200452004620047200482004920050200512005220053200542005520056200572005820059200602006120062200632006420065200662006720068200692007020071200722007320074200752007620077200782007920080200812008220083200842008520086200872008820089200902009120092200932009420095200962009720098200992010020101201022010320104201052010620107201082010920110201112011220113201142011520116201172011820119201202012120122201232012420125201262012720128201292013020131201322013320134201352013620137201382013920140201412014220143201442014520146201472014820149201502015120152201532015420155201562015720158201592016020161201622016320164201652016620167201682016920170201712017220173201742017520176201772017820179201802018120182201832018420185201862018720188201892019020191201922019320194201952019620197201982019920200202012020220203202042020520206202072020820209202102021120212202132021420215202162021720218202192022020221202222022320224202252022620227202282022920230202312023220233202342023520236202372023820239202402024120242202432024420245202462024720248202492025020251202522025320254202552025620257202582025920260202612026220263202642026520266202672026820269202702027120272202732027420275202762027720278202792028020281202822028320284202852028620287202882028920290202912029220293202942029520296202972029820299203002030120302203032030420305203062030720308203092031020311203122031320314203152031620317203182031920320203212032220323203242032520326203272032820329203302033120332203332033420335203362033720338203392034020341203422034320344203452034620347203482034920350203512035220353203542035520356203572035820359203602036120362203632036420365203662036720368203692037020371203722037320374203752037620377203782037920380203812038220383203842038520386203872038820389203902039120392203932039420395203962039720398203992040020401204022040320404204052040620407204082040920410204112041220413204142041520416204172041820419204202042120422204232042420425204262042720428204292043020431204322043320434204352043620437204382043920440204412044220443204442044520446204472044820449204502045120452204532045420455204562045720458204592046020461204622046320464204652046620467204682046920470204712047220473204742047520476204772047820479204802048120482204832048420485204862048720488204892049020491204922049320494204952049620497204982049920500205012050220503205042050520506205072050820509205102051120512205132051420515205162051720518205192052020521205222052320524205252052620527205282052920530205312053220533205342053520536205372053820539205402054120542205432054420545205462054720548205492055020551205522055320554205552055620557205582055920560205612056220563205642056520566205672056820569205702057120572205732057420575205762057720578205792058020581205822058320584205852058620587205882058920590205912059220593205942059520596205972059820599206002060120602206032060420605206062060720608206092061020611206122061320614206152061620617206182061920620206212062220623206242062520626206272062820629206302063120632206332063420635206362063720638206392064020641206422064320644206452064620647206482064920650206512065220653206542065520656206572065820659206602066120662206632066420665206662066720668206692067020671206722067320674206752067620677206782067920680206812068220683206842068520686206872068820689206902069120692206932069420695206962069720698206992070020701207022070320704207052070620707207082070920710207112071220713207142071520716207172071820719207202072120722207232072420725207262072720728207292073020731207322073320734207352073620737207382073920740207412074220743207442074520746207472074820749207502075120752207532075420755207562075720758207592076020761207622076320764207652076620767207682076920770207712077220773207742077520776207772077820779207802078120782207832078420785207862078720788207892079020791207922079320794207952079620797207982079920800208012080220803208042080520806208072080820809208102081120812208132081420815208162081720818208192082020821208222082320824208252082620827208282082920830208312083220833208342083520836208372083820839208402084120842208432084420845208462084720848208492085020851208522085320854208552085620857208582085920860208612086220863208642086520866208672086820869208702087120872208732087420875208762087720878208792088020881208822088320884208852088620887208882088920890208912089220893208942089520896208972089820899209002090120902209032090420905209062090720908209092091020911209122091320914209152091620917209182091920920209212092220923209242092520926209272092820929209302093120932209332093420935209362093720938209392094020941209422094320944209452094620947209482094920950209512095220953209542095520956209572095820959209602096120962209632096420965209662096720968209692097020971209722097320974209752097620977209782097920980209812098220983209842098520986209872098820989209902099120992209932099420995209962099720998209992100021001210022100321004210052100621007210082100921010210112101221013210142101521016210172101821019210202102121022210232102421025210262102721028210292103021031210322103321034210352103621037210382103921040210412104221043210442104521046210472104821049210502105121052210532105421055210562105721058210592106021061210622106321064210652106621067210682106921070210712107221073210742107521076210772107821079210802108121082210832108421085210862108721088210892109021091210922109321094210952109621097210982109921100211012110221103211042110521106211072110821109211102111121112211132111421115211162111721118211192112021121211222112321124211252112621127211282112921130211312113221133211342113521136211372113821139211402114121142211432114421145211462114721148211492115021151211522115321154211552115621157211582115921160211612116221163211642116521166211672116821169211702117121172211732117421175211762117721178211792118021181211822118321184211852118621187211882118921190211912119221193211942119521196211972119821199212002120121202212032120421205212062120721208212092121021211212122121321214212152121621217212182121921220212212122221223212242122521226212272122821229212302123121232212332123421235212362123721238212392124021241212422124321244212452124621247212482124921250212512125221253212542125521256212572125821259212602126121262212632126421265212662126721268212692127021271212722127321274212752127621277212782127921280212812128221283212842128521286212872128821289212902129121292212932129421295212962129721298212992130021301213022130321304213052130621307213082130921310213112131221313213142131521316213172131821319213202132121322213232132421325213262132721328213292133021331213322133321334213352133621337213382133921340213412134221343213442134521346213472134821349213502135121352213532135421355213562135721358213592136021361213622136321364213652136621367213682136921370213712137221373213742137521376213772137821379213802138121382213832138421385213862138721388213892139021391213922139321394213952139621397213982139921400214012140221403214042140521406214072140821409214102141121412214132141421415214162141721418214192142021421214222142321424214252142621427214282142921430214312143221433214342143521436214372143821439214402144121442214432144421445214462144721448214492145021451214522145321454214552145621457214582145921460214612146221463214642146521466214672146821469214702147121472214732147421475214762147721478214792148021481214822148321484214852148621487214882148921490214912149221493214942149521496214972149821499215002150121502215032150421505215062150721508215092151021511215122151321514215152151621517215182151921520215212152221523215242152521526215272152821529215302153121532215332153421535215362153721538215392154021541215422154321544215452154621547215482154921550215512155221553215542155521556215572155821559215602156121562215632156421565215662156721568215692157021571215722157321574215752157621577215782157921580215812158221583215842158521586215872158821589215902159121592215932159421595215962159721598215992160021601216022160321604216052160621607216082160921610216112161221613216142161521616216172161821619216202162121622216232162421625216262162721628216292163021631216322163321634216352163621637216382163921640216412164221643216442164521646216472164821649216502165121652216532165421655216562165721658216592166021661216622166321664216652166621667216682166921670216712167221673216742167521676216772167821679216802168121682216832168421685216862168721688216892169021691216922169321694216952169621697216982169921700217012170221703217042170521706217072170821709217102171121712217132171421715217162171721718217192172021721217222172321724217252172621727217282172921730217312173221733217342173521736217372173821739217402174121742217432174421745217462174721748217492175021751217522175321754217552175621757217582175921760217612176221763217642176521766217672176821769217702177121772217732177421775217762177721778217792178021781217822178321784217852178621787217882178921790217912179221793217942179521796217972179821799218002180121802218032180421805218062180721808218092181021811218122181321814218152181621817218182181921820218212182221823218242182521826218272182821829218302183121832218332183421835218362183721838218392184021841218422184321844218452184621847218482184921850218512185221853218542185521856218572185821859218602186121862218632186421865218662186721868218692187021871218722187321874218752187621877218782187921880218812188221883218842188521886218872188821889218902189121892218932189421895218962189721898218992190021901219022190321904219052190621907219082190921910219112191221913219142191521916219172191821919219202192121922219232192421925219262192721928219292193021931219322193321934219352193621937219382193921940219412194221943219442194521946219472194821949219502195121952219532195421955219562195721958219592196021961219622196321964219652196621967219682196921970219712197221973219742197521976219772197821979219802198121982219832198421985219862198721988219892199021991219922199321994219952199621997219982199922000220012200222003220042200522006220072200822009220102201122012220132201422015220162201722018220192202022021220222202322024220252202622027220282202922030220312203222033220342203522036220372203822039220402204122042220432204422045220462204722048220492205022051220522205322054220552205622057220582205922060220612206222063220642206522066220672206822069220702207122072220732207422075220762207722078220792208022081220822208322084220852208622087220882208922090220912209222093220942209522096220972209822099221002210122102221032210422105221062210722108221092211022111221122211322114221152211622117221182211922120221212212222123221242212522126221272212822129221302213122132221332213422135221362213722138221392214022141221422214322144221452214622147221482214922150221512215222153221542215522156221572215822159221602216122162221632216422165221662216722168221692217022171221722217322174221752217622177221782217922180221812218222183221842218522186221872218822189221902219122192221932219422195221962219722198221992220022201222022220322204222052220622207222082220922210222112221222213222142221522216222172221822219222202222122222222232222422225222262222722228222292223022231222322223322234222352223622237222382223922240222412224222243222442224522246222472224822249222502225122252222532225422255222562225722258222592226022261222622226322264222652226622267222682226922270222712227222273222742227522276222772227822279222802228122282222832228422285222862228722288222892229022291222922229322294222952229622297222982229922300223012230222303223042230522306223072230822309223102231122312223132231422315223162231722318223192232022321223222232322324223252232622327223282232922330223312233222333223342233522336223372233822339223402234122342223432234422345223462234722348223492235022351223522235322354223552235622357223582235922360223612236222363223642236522366223672236822369223702237122372223732237422375223762237722378223792238022381223822238322384223852238622387223882238922390223912239222393223942239522396223972239822399224002240122402224032240422405224062240722408224092241022411224122241322414224152241622417224182241922420224212242222423224242242522426224272242822429224302243122432224332243422435224362243722438224392244022441224422244322444224452244622447224482244922450224512245222453224542245522456224572245822459224602246122462224632246422465224662246722468224692247022471224722247322474224752247622477224782247922480224812248222483224842248522486224872248822489224902249122492224932249422495224962249722498224992250022501225022250322504225052250622507225082250922510225112251222513225142251522516225172251822519225202252122522225232252422525225262252722528225292253022531225322253322534225352253622537225382253922540225412254222543225442254522546225472254822549225502255122552225532255422555225562255722558225592256022561225622256322564225652256622567225682256922570225712257222573225742257522576225772257822579225802258122582225832258422585225862258722588225892259022591225922259322594225952259622597225982259922600226012260222603226042260522606226072260822609226102261122612226132261422615226162261722618226192262022621226222262322624226252262622627226282262922630226312263222633226342263522636226372263822639226402264122642226432264422645226462264722648226492265022651226522265322654226552265622657226582265922660226612266222663226642266522666226672266822669226702267122672226732267422675226762267722678226792268022681226822268322684226852268622687226882268922690226912269222693226942269522696226972269822699227002270122702227032270422705227062270722708227092271022711227122271322714227152271622717227182271922720227212272222723227242272522726227272272822729227302273122732227332273422735227362273722738227392274022741227422274322744227452274622747227482274922750227512275222753227542275522756227572275822759227602276122762227632276422765227662276722768227692277022771227722277322774227752277622777227782277922780227812278222783227842278522786227872278822789227902279122792227932279422795227962279722798227992280022801228022280322804228052280622807228082280922810228112281222813228142281522816228172281822819228202282122822228232282422825228262282722828228292283022831228322283322834228352283622837228382283922840228412284222843228442284522846228472284822849228502285122852228532285422855228562285722858228592286022861228622286322864228652286622867228682286922870228712287222873228742287522876228772287822879228802288122882228832288422885228862288722888228892289022891228922289322894228952289622897228982289922900229012290222903229042290522906229072290822909229102291122912229132291422915229162291722918229192292022921229222292322924229252292622927229282292922930229312293222933229342293522936229372293822939229402294122942229432294422945229462294722948229492295022951229522295322954229552295622957229582295922960229612296222963229642296522966229672296822969229702297122972229732297422975229762297722978229792298022981229822298322984229852298622987229882298922990229912299222993229942299522996229972299822999230002300123002230032300423005230062300723008230092301023011230122301323014230152301623017230182301923020230212302223023230242302523026230272302823029230302303123032230332303423035230362303723038230392304023041230422304323044230452304623047230482304923050230512305223053230542305523056230572305823059230602306123062230632306423065230662306723068230692307023071230722307323074230752307623077230782307923080230812308223083230842308523086230872308823089230902309123092230932309423095230962309723098230992310023101231022310323104231052310623107231082310923110231112311223113231142311523116231172311823119231202312123122231232312423125231262312723128231292313023131231322313323134231352313623137231382313923140231412314223143231442314523146231472314823149231502315123152231532315423155231562315723158231592316023161231622316323164231652316623167231682316923170231712317223173231742317523176231772317823179231802318123182231832318423185231862318723188231892319023191231922319323194231952319623197231982319923200232012320223203232042320523206232072320823209232102321123212232132321423215232162321723218232192322023221232222322323224232252322623227232282322923230232312323223233232342323523236232372323823239232402324123242232432324423245232462324723248232492325023251232522325323254232552325623257232582325923260232612326223263232642326523266232672326823269232702327123272232732327423275232762327723278232792328023281232822328323284232852328623287232882328923290232912329223293232942329523296232972329823299233002330123302233032330423305233062330723308233092331023311233122331323314233152331623317233182331923320233212332223323233242332523326233272332823329233302333123332233332333423335233362333723338233392334023341233422334323344233452334623347233482334923350233512335223353233542335523356233572335823359233602336123362233632336423365233662336723368233692337023371233722337323374233752337623377233782337923380233812338223383233842338523386233872338823389233902339123392233932339423395233962339723398233992340023401234022340323404234052340623407234082340923410234112341223413234142341523416234172341823419234202342123422234232342423425234262342723428234292343023431234322343323434234352343623437234382343923440234412344223443234442344523446234472344823449234502345123452234532345423455234562345723458234592346023461234622346323464234652346623467234682346923470234712347223473234742347523476234772347823479234802348123482234832348423485234862348723488234892349023491234922349323494234952349623497234982349923500235012350223503235042350523506235072350823509235102351123512235132351423515235162351723518235192352023521235222352323524235252352623527235282352923530235312353223533235342353523536235372353823539235402354123542235432354423545235462354723548235492355023551235522355323554235552355623557235582355923560235612356223563235642356523566235672356823569235702357123572235732357423575235762357723578235792358023581235822358323584235852358623587235882358923590235912359223593235942359523596235972359823599236002360123602236032360423605236062360723608236092361023611236122361323614236152361623617236182361923620236212362223623236242362523626236272362823629236302363123632236332363423635236362363723638236392364023641236422364323644236452364623647236482364923650236512365223653236542365523656236572365823659236602366123662236632366423665236662366723668236692367023671236722367323674236752367623677236782367923680236812368223683236842368523686236872368823689236902369123692236932369423695236962369723698236992370023701237022370323704237052370623707237082370923710237112371223713237142371523716237172371823719237202372123722237232372423725237262372723728237292373023731237322373323734237352373623737237382373923740237412374223743237442374523746237472374823749237502375123752237532375423755237562375723758237592376023761237622376323764237652376623767237682376923770237712377223773237742377523776237772377823779237802378123782237832378423785237862378723788237892379023791237922379323794237952379623797237982379923800238012380223803238042380523806238072380823809238102381123812238132381423815238162381723818238192382023821238222382323824238252382623827238282382923830238312383223833238342383523836238372383823839238402384123842238432384423845238462384723848238492385023851238522385323854238552385623857238582385923860238612386223863238642386523866238672386823869238702387123872238732387423875238762387723878238792388023881238822388323884238852388623887238882388923890238912389223893238942389523896238972389823899239002390123902239032390423905239062390723908239092391023911239122391323914239152391623917239182391923920239212392223923239242392523926239272392823929239302393123932239332393423935239362393723938239392394023941239422394323944239452394623947239482394923950239512395223953239542395523956239572395823959239602396123962239632396423965239662396723968239692397023971239722397323974239752397623977239782397923980239812398223983239842398523986239872398823989239902399123992239932399423995239962399723998239992400024001240022400324004240052400624007240082400924010240112401224013240142401524016240172401824019240202402124022240232402424025240262402724028240292403024031240322403324034240352403624037240382403924040240412404224043240442404524046240472404824049240502405124052240532405424055240562405724058240592406024061240622406324064240652406624067240682406924070240712407224073240742407524076240772407824079240802408124082240832408424085240862408724088240892409024091240922409324094240952409624097240982409924100241012410224103241042410524106241072410824109241102411124112241132411424115241162411724118241192412024121241222412324124241252412624127241282412924130241312413224133241342413524136241372413824139241402414124142241432414424145241462414724148241492415024151241522415324154241552415624157241582415924160241612416224163241642416524166241672416824169241702417124172241732417424175241762417724178241792418024181241822418324184241852418624187241882418924190241912419224193241942419524196241972419824199242002420124202242032420424205242062420724208242092421024211242122421324214242152421624217242182421924220242212422224223242242422524226242272422824229242302423124232242332423424235242362423724238242392424024241242422424324244242452424624247242482424924250242512425224253242542425524256242572425824259242602426124262242632426424265242662426724268242692427024271242722427324274242752427624277242782427924280242812428224283242842428524286242872428824289242902429124292242932429424295242962429724298242992430024301243022430324304243052430624307243082430924310243112431224313243142431524316243172431824319243202432124322243232432424325243262432724328243292433024331243322433324334243352433624337243382433924340243412434224343243442434524346243472434824349243502435124352243532435424355243562435724358243592436024361243622436324364243652436624367243682436924370243712437224373243742437524376243772437824379243802438124382243832438424385243862438724388243892439024391243922439324394243952439624397243982439924400244012440224403244042440524406244072440824409244102441124412244132441424415244162441724418244192442024421244222442324424244252442624427244282442924430244312443224433244342443524436244372443824439244402444124442244432444424445244462444724448244492445024451244522445324454244552445624457244582445924460244612446224463244642446524466244672446824469244702447124472244732447424475244762447724478244792448024481244822448324484244852448624487244882448924490244912449224493244942449524496244972449824499245002450124502245032450424505245062450724508245092451024511245122451324514245152451624517245182451924520245212452224523245242452524526245272452824529245302453124532245332453424535245362453724538245392454024541245422454324544245452454624547245482454924550245512455224553245542455524556245572455824559245602456124562245632456424565245662456724568245692457024571245722457324574245752457624577245782457924580245812458224583245842458524586245872458824589245902459124592245932459424595245962459724598245992460024601246022460324604246052460624607246082460924610246112461224613246142461524616246172461824619246202462124622246232462424625246262462724628246292463024631246322463324634246352463624637246382463924640246412464224643246442464524646246472464824649246502465124652246532465424655246562465724658246592466024661246622466324664246652466624667246682466924670246712467224673246742467524676246772467824679246802468124682246832468424685246862468724688246892469024691246922469324694246952469624697246982469924700247012470224703247042470524706247072470824709247102471124712247132471424715247162471724718247192472024721247222472324724247252472624727247282472924730247312473224733247342473524736247372473824739247402474124742247432474424745247462474724748247492475024751247522475324754247552475624757247582475924760247612476224763247642476524766247672476824769247702477124772247732477424775247762477724778247792478024781247822478324784247852478624787247882478924790247912479224793247942479524796247972479824799248002480124802248032480424805248062480724808248092481024811248122481324814248152481624817248182481924820248212482224823248242482524826248272482824829248302483124832248332483424835248362483724838248392484024841248422484324844248452484624847248482484924850248512485224853248542485524856248572485824859248602486124862248632486424865248662486724868248692487024871248722487324874248752487624877248782487924880248812488224883248842488524886248872488824889248902489124892248932489424895248962489724898248992490024901249022490324904249052490624907249082490924910249112491224913249142491524916249172491824919249202492124922249232492424925249262492724928249292493024931249322493324934249352493624937249382493924940249412494224943249442494524946249472494824949249502495124952249532495424955249562495724958249592496024961249622496324964249652496624967249682496924970249712497224973249742497524976249772497824979249802498124982249832498424985249862498724988249892499024991249922499324994249952499624997249982499925000250012500225003250042500525006250072500825009250102501125012250132501425015250162501725018250192502025021250222502325024250252502625027250282502925030250312503225033250342503525036250372503825039250402504125042250432504425045250462504725048250492505025051250522505325054250552505625057250582505925060250612506225063250642506525066250672506825069250702507125072250732507425075250762507725078250792508025081250822508325084250852508625087250882508925090250912509225093250942509525096250972509825099251002510125102251032510425105251062510725108251092511025111251122511325114251152511625117251182511925120251212512225123251242512525126251272512825129251302513125132251332513425135251362513725138251392514025141251422514325144251452514625147251482514925150251512515225153251542515525156251572515825159251602516125162251632516425165251662516725168251692517025171251722517325174251752517625177251782517925180251812518225183251842518525186251872518825189251902519125192251932519425195251962519725198251992520025201252022520325204252052520625207252082520925210252112521225213252142521525216252172521825219252202522125222252232522425225252262522725228252292523025231252322523325234252352523625237252382523925240252412524225243252442524525246252472524825249252502525125252252532525425255252562525725258252592526025261252622526325264252652526625267252682526925270252712527225273252742527525276252772527825279252802528125282252832528425285252862528725288252892529025291252922529325294252952529625297252982529925300253012530225303253042530525306253072530825309253102531125312253132531425315253162531725318253192532025321253222532325324253252532625327253282532925330253312533225333253342533525336253372533825339253402534125342253432534425345253462534725348253492535025351253522535325354253552535625357253582535925360253612536225363253642536525366253672536825369253702537125372253732537425375253762537725378253792538025381253822538325384253852538625387253882538925390253912539225393253942539525396253972539825399254002540125402254032540425405254062540725408254092541025411254122541325414254152541625417254182541925420254212542225423254242542525426254272542825429254302543125432254332543425435254362543725438254392544025441254422544325444254452544625447254482544925450254512545225453254542545525456254572545825459254602546125462254632546425465254662546725468254692547025471254722547325474254752547625477254782547925480254812548225483254842548525486254872548825489254902549125492254932549425495254962549725498254992550025501255022550325504255052550625507255082550925510255112551225513255142551525516255172551825519255202552125522255232552425525255262552725528255292553025531255322553325534255352553625537255382553925540255412554225543255442554525546255472554825549255502555125552255532555425555255562555725558255592556025561255622556325564255652556625567255682556925570255712557225573255742557525576255772557825579255802558125582255832558425585255862558725588255892559025591255922559325594255952559625597255982559925600256012560225603256042560525606256072560825609256102561125612256132561425615256162561725618256192562025621256222562325624256252562625627256282562925630256312563225633256342563525636256372563825639256402564125642256432564425645256462564725648256492565025651256522565325654256552565625657256582565925660256612566225663256642566525666256672566825669256702567125672256732567425675256762567725678256792568025681256822568325684256852568625687256882568925690256912569225693256942569525696256972569825699257002570125702257032570425705257062570725708257092571025711257122571325714257152571625717257182571925720257212572225723257242572525726257272572825729257302573125732257332573425735257362573725738257392574025741257422574325744257452574625747257482574925750257512575225753257542575525756257572575825759257602576125762257632576425765257662576725768257692577025771257722577325774257752577625777257782577925780257812578225783257842578525786257872578825789257902579125792257932579425795257962579725798257992580025801258022580325804258052580625807258082580925810258112581225813258142581525816258172581825819258202582125822258232582425825258262582725828258292583025831258322583325834258352583625837258382583925840258412584225843258442584525846258472584825849258502585125852258532585425855258562585725858258592586025861258622586325864258652586625867258682586925870258712587225873258742587525876258772587825879258802588125882258832588425885258862588725888258892589025891258922589325894258952589625897258982589925900259012590225903259042590525906259072590825909259102591125912259132591425915259162591725918259192592025921259222592325924259252592625927259282592925930259312593225933259342593525936259372593825939259402594125942259432594425945259462594725948259492595025951259522595325954259552595625957259582595925960259612596225963259642596525966259672596825969259702597125972259732597425975259762597725978259792598025981259822598325984259852598625987259882598925990259912599225993259942599525996259972599825999260002600126002260032600426005260062600726008260092601026011260122601326014260152601626017260182601926020260212602226023260242602526026260272602826029260302603126032260332603426035260362603726038260392604026041260422604326044260452604626047260482604926050260512605226053260542605526056260572605826059260602606126062260632606426065260662606726068260692607026071260722607326074260752607626077260782607926080260812608226083260842608526086260872608826089260902609126092260932609426095260962609726098260992610026101261022610326104261052610626107261082610926110261112611226113261142611526116261172611826119261202612126122261232612426125261262612726128261292613026131261322613326134261352613626137261382613926140261412614226143261442614526146261472614826149261502615126152261532615426155261562615726158261592616026161261622616326164261652616626167261682616926170261712617226173261742617526176261772617826179261802618126182261832618426185261862618726188261892619026191261922619326194261952619626197261982619926200262012620226203262042620526206262072620826209262102621126212262132621426215262162621726218262192622026221262222622326224262252622626227262282622926230262312623226233262342623526236262372623826239262402624126242262432624426245262462624726248262492625026251262522625326254262552625626257262582625926260262612626226263262642626526266262672626826269262702627126272262732627426275262762627726278262792628026281262822628326284262852628626287262882628926290262912629226293262942629526296262972629826299263002630126302263032630426305263062630726308263092631026311263122631326314263152631626317263182631926320263212632226323263242632526326263272632826329263302633126332263332633426335263362633726338263392634026341263422634326344263452634626347263482634926350263512635226353263542635526356263572635826359263602636126362263632636426365263662636726368263692637026371263722637326374263752637626377263782637926380263812638226383263842638526386263872638826389263902639126392263932639426395263962639726398263992640026401264022640326404264052640626407264082640926410264112641226413264142641526416264172641826419264202642126422264232642426425264262642726428264292643026431264322643326434264352643626437264382643926440264412644226443264442644526446264472644826449264502645126452264532645426455264562645726458264592646026461264622646326464264652646626467264682646926470264712647226473264742647526476264772647826479264802648126482264832648426485264862648726488264892649026491264922649326494264952649626497264982649926500265012650226503265042650526506265072650826509265102651126512265132651426515265162651726518265192652026521265222652326524265252652626527265282652926530265312653226533265342653526536265372653826539265402654126542265432654426545265462654726548265492655026551265522655326554265552655626557265582655926560265612656226563265642656526566265672656826569265702657126572265732657426575265762657726578265792658026581265822658326584265852658626587265882658926590265912659226593265942659526596265972659826599266002660126602266032660426605266062660726608266092661026611266122661326614266152661626617266182661926620266212662226623266242662526626266272662826629266302663126632266332663426635266362663726638266392664026641266422664326644266452664626647266482664926650266512665226653266542665526656266572665826659266602666126662266632666426665266662666726668266692667026671266722667326674266752667626677266782667926680266812668226683266842668526686266872668826689266902669126692266932669426695266962669726698266992670026701267022670326704267052670626707267082670926710267112671226713267142671526716267172671826719267202672126722267232672426725267262672726728267292673026731267322673326734267352673626737267382673926740267412674226743267442674526746267472674826749267502675126752267532675426755267562675726758267592676026761267622676326764267652676626767267682676926770267712677226773267742677526776267772677826779267802678126782267832678426785267862678726788267892679026791267922679326794267952679626797267982679926800268012680226803268042680526806268072680826809268102681126812268132681426815268162681726818268192682026821268222682326824268252682626827268282682926830268312683226833268342683526836268372683826839268402684126842268432684426845268462684726848268492685026851268522685326854268552685626857268582685926860268612686226863268642686526866268672686826869268702687126872268732687426875268762687726878268792688026881268822688326884268852688626887268882688926890268912689226893268942689526896268972689826899269002690126902269032690426905269062690726908269092691026911269122691326914269152691626917269182691926920269212692226923269242692526926269272692826929269302693126932269332693426935269362693726938269392694026941269422694326944269452694626947269482694926950269512695226953269542695526956269572695826959269602696126962269632696426965269662696726968269692697026971269722697326974269752697626977269782697926980269812698226983269842698526986269872698826989269902699126992269932699426995269962699726998269992700027001270022700327004270052700627007270082700927010270112701227013270142701527016270172701827019270202702127022270232702427025270262702727028270292703027031270322703327034270352703627037270382703927040270412704227043270442704527046270472704827049270502705127052270532705427055270562705727058270592706027061270622706327064270652706627067270682706927070270712707227073270742707527076270772707827079270802708127082270832708427085270862708727088270892709027091270922709327094270952709627097270982709927100271012710227103271042710527106271072710827109271102711127112271132711427115271162711727118271192712027121271222712327124271252712627127271282712927130271312713227133271342713527136271372713827139271402714127142271432714427145271462714727148271492715027151271522715327154271552715627157271582715927160271612716227163271642716527166271672716827169271702717127172271732717427175271762717727178271792718027181271822718327184271852718627187271882718927190271912719227193271942719527196271972719827199272002720127202272032720427205272062720727208272092721027211272122721327214272152721627217272182721927220272212722227223272242722527226272272722827229272302723127232272332723427235272362723727238272392724027241272422724327244272452724627247272482724927250272512725227253272542725527256272572725827259272602726127262272632726427265272662726727268272692727027271272722727327274272752727627277272782727927280272812728227283272842728527286272872728827289272902729127292272932729427295272962729727298272992730027301273022730327304273052730627307273082730927310273112731227313273142731527316273172731827319273202732127322273232732427325273262732727328273292733027331273322733327334273352733627337273382733927340273412734227343273442734527346273472734827349273502735127352273532735427355273562735727358273592736027361273622736327364273652736627367273682736927370273712737227373273742737527376273772737827379273802738127382273832738427385273862738727388273892739027391273922739327394273952739627397273982739927400274012740227403274042740527406274072740827409274102741127412274132741427415274162741727418274192742027421274222742327424274252742627427274282742927430274312743227433274342743527436274372743827439274402744127442274432744427445274462744727448274492745027451274522745327454274552745627457274582745927460274612746227463274642746527466274672746827469274702747127472274732747427475274762747727478274792748027481274822748327484274852748627487274882748927490274912749227493274942749527496274972749827499275002750127502275032750427505275062750727508275092751027511275122751327514275152751627517275182751927520275212752227523275242752527526275272752827529275302753127532275332753427535275362753727538275392754027541275422754327544275452754627547275482754927550275512755227553275542755527556275572755827559275602756127562275632756427565275662756727568275692757027571275722757327574275752757627577275782757927580275812758227583275842758527586275872758827589275902759127592275932759427595275962759727598275992760027601276022760327604276052760627607276082760927610276112761227613276142761527616276172761827619276202762127622276232762427625276262762727628276292763027631276322763327634276352763627637276382763927640276412764227643276442764527646276472764827649276502765127652276532765427655276562765727658276592766027661276622766327664276652766627667276682766927670276712767227673276742767527676276772767827679276802768127682276832768427685276862768727688276892769027691276922769327694276952769627697276982769927700277012770227703277042770527706277072770827709277102771127712277132771427715277162771727718277192772027721277222772327724277252772627727277282772927730277312773227733277342773527736277372773827739277402774127742277432774427745277462774727748277492775027751277522775327754277552775627757277582775927760277612776227763277642776527766277672776827769277702777127772277732777427775277762777727778277792778027781277822778327784277852778627787277882778927790277912779227793277942779527796277972779827799278002780127802278032780427805278062780727808278092781027811278122781327814278152781627817278182781927820278212782227823278242782527826278272782827829278302783127832278332783427835278362783727838278392784027841278422784327844278452784627847278482784927850278512785227853278542785527856278572785827859278602786127862278632786427865278662786727868278692787027871278722787327874278752787627877278782787927880278812788227883278842788527886278872788827889278902789127892278932789427895278962789727898278992790027901279022790327904279052790627907279082790927910279112791227913279142791527916279172791827919279202792127922279232792427925279262792727928279292793027931279322793327934279352793627937279382793927940279412794227943279442794527946279472794827949279502795127952279532795427955279562795727958279592796027961279622796327964279652796627967279682796927970279712797227973279742797527976279772797827979279802798127982279832798427985279862798727988279892799027991279922799327994279952799627997279982799928000280012800228003280042800528006280072800828009280102801128012280132801428015280162801728018280192802028021280222802328024280252802628027280282802928030280312803228033280342803528036280372803828039280402804128042280432804428045280462804728048280492805028051280522805328054280552805628057280582805928060280612806228063280642806528066280672806828069280702807128072280732807428075280762807728078280792808028081280822808328084280852808628087280882808928090280912809228093280942809528096280972809828099281002810128102281032810428105281062810728108281092811028111281122811328114281152811628117281182811928120281212812228123281242812528126281272812828129281302813128132281332813428135281362813728138281392814028141281422814328144281452814628147281482814928150281512815228153281542815528156281572815828159281602816128162281632816428165281662816728168281692817028171281722817328174281752817628177281782817928180281812818228183281842818528186281872818828189281902819128192281932819428195281962819728198281992820028201282022820328204282052820628207282082820928210282112821228213282142821528216282172821828219282202822128222282232822428225282262822728228282292823028231282322823328234282352823628237282382823928240282412824228243282442824528246282472824828249282502825128252282532825428255282562825728258282592826028261282622826328264282652826628267282682826928270282712827228273282742827528276282772827828279282802828128282282832828428285282862828728288282892829028291282922829328294282952829628297282982829928300283012830228303283042830528306283072830828309283102831128312283132831428315283162831728318283192832028321283222832328324283252832628327283282832928330283312833228333283342833528336283372833828339283402834128342283432834428345283462834728348283492835028351283522835328354283552835628357283582835928360283612836228363283642836528366283672836828369283702837128372283732837428375283762837728378283792838028381283822838328384283852838628387283882838928390283912839228393283942839528396283972839828399284002840128402284032840428405284062840728408284092841028411284122841328414284152841628417284182841928420284212842228423284242842528426284272842828429284302843128432284332843428435284362843728438284392844028441284422844328444284452844628447284482844928450284512845228453284542845528456284572845828459284602846128462284632846428465284662846728468284692847028471284722847328474284752847628477284782847928480284812848228483284842848528486284872848828489284902849128492284932849428495284962849728498284992850028501285022850328504285052850628507285082850928510285112851228513285142851528516285172851828519285202852128522285232852428525285262852728528285292853028531285322853328534285352853628537285382853928540285412854228543285442854528546285472854828549285502855128552285532855428555285562855728558285592856028561285622856328564285652856628567285682856928570285712857228573285742857528576285772857828579285802858128582285832858428585285862858728588285892859028591285922859328594285952859628597285982859928600286012860228603286042860528606286072860828609286102861128612286132861428615286162861728618286192862028621286222862328624286252862628627286282862928630286312863228633286342863528636286372863828639286402864128642286432864428645286462864728648286492865028651286522865328654286552865628657286582865928660286612866228663286642866528666286672866828669286702867128672286732867428675286762867728678286792868028681286822868328684286852868628687286882868928690286912869228693286942869528696286972869828699287002870128702287032870428705287062870728708287092871028711287122871328714287152871628717287182871928720287212872228723287242872528726287272872828729287302873128732287332873428735287362873728738287392874028741287422874328744287452874628747287482874928750287512875228753287542875528756287572875828759287602876128762287632876428765287662876728768287692877028771287722877328774287752877628777287782877928780287812878228783287842878528786287872878828789287902879128792287932879428795287962879728798287992880028801288022880328804288052880628807288082880928810288112881228813288142881528816288172881828819288202882128822288232882428825288262882728828288292883028831288322883328834288352883628837288382883928840288412884228843288442884528846288472884828849288502885128852288532885428855288562885728858288592886028861288622886328864288652886628867288682886928870288712887228873288742887528876288772887828879288802888128882288832888428885288862888728888288892889028891288922889328894288952889628897288982889928900289012890228903289042890528906289072890828909289102891128912289132891428915289162891728918289192892028921289222892328924289252892628927289282892928930289312893228933289342893528936289372893828939289402894128942289432894428945289462894728948289492895028951289522895328954289552895628957289582895928960289612896228963289642896528966289672896828969289702897128972289732897428975289762897728978289792898028981289822898328984289852898628987289882898928990289912899228993289942899528996289972899828999290002900129002290032900429005290062900729008290092901029011290122901329014290152901629017290182901929020290212902229023290242902529026290272902829029290302903129032290332903429035290362903729038290392904029041290422904329044290452904629047290482904929050290512905229053290542905529056290572905829059290602906129062290632906429065290662906729068290692907029071290722907329074290752907629077290782907929080290812908229083290842908529086290872908829089290902909129092290932909429095290962909729098290992910029101291022910329104291052910629107291082910929110291112911229113291142911529116291172911829119291202912129122291232912429125291262912729128291292913029131291322913329134291352913629137291382913929140291412914229143291442914529146291472914829149291502915129152291532915429155291562915729158291592916029161291622916329164291652916629167291682916929170291712917229173291742917529176291772917829179291802918129182291832918429185291862918729188291892919029191291922919329194291952919629197291982919929200292012920229203292042920529206292072920829209292102921129212292132921429215292162921729218292192922029221292222922329224292252922629227292282922929230292312923229233292342923529236292372923829239292402924129242292432924429245292462924729248292492925029251292522925329254292552925629257292582925929260292612926229263292642926529266292672926829269292702927129272292732927429275292762927729278292792928029281292822928329284292852928629287292882928929290292912929229293292942929529296292972929829299293002930129302293032930429305293062930729308293092931029311293122931329314293152931629317293182931929320293212932229323293242932529326293272932829329293302933129332293332933429335293362933729338293392934029341293422934329344293452934629347293482934929350293512935229353293542935529356293572935829359293602936129362293632936429365293662936729368293692937029371293722937329374293752937629377293782937929380293812938229383293842938529386293872938829389293902939129392293932939429395293962939729398293992940029401294022940329404294052940629407294082940929410294112941229413294142941529416294172941829419294202942129422294232942429425294262942729428294292943029431294322943329434294352943629437294382943929440294412944229443294442944529446294472944829449294502945129452294532945429455294562945729458294592946029461294622946329464294652946629467294682946929470294712947229473294742947529476294772947829479294802948129482294832948429485294862948729488294892949029491294922949329494294952949629497294982949929500295012950229503295042950529506295072950829509295102951129512295132951429515295162951729518295192952029521295222952329524295252952629527295282952929530295312953229533295342953529536295372953829539295402954129542295432954429545295462954729548295492955029551295522955329554295552955629557295582955929560295612956229563295642956529566295672956829569295702957129572295732957429575295762957729578295792958029581295822958329584295852958629587295882958929590295912959229593295942959529596295972959829599296002960129602296032960429605296062960729608296092961029611296122961329614296152961629617296182961929620296212962229623296242962529626296272962829629296302963129632296332963429635296362963729638296392964029641296422964329644296452964629647296482964929650296512965229653296542965529656296572965829659296602966129662296632966429665296662966729668296692967029671296722967329674296752967629677296782967929680296812968229683296842968529686296872968829689296902969129692296932969429695296962969729698296992970029701297022970329704297052970629707297082970929710297112971229713297142971529716297172971829719297202972129722297232972429725297262972729728297292973029731297322973329734297352973629737297382973929740297412974229743297442974529746297472974829749297502975129752297532975429755297562975729758297592976029761297622976329764297652976629767297682976929770297712977229773297742977529776297772977829779297802978129782297832978429785297862978729788297892979029791297922979329794297952979629797297982979929800298012980229803298042980529806298072980829809298102981129812298132981429815298162981729818298192982029821298222982329824298252982629827298282982929830298312983229833298342983529836298372983829839298402984129842298432984429845298462984729848298492985029851298522985329854298552985629857298582985929860298612986229863298642986529866298672986829869298702987129872298732987429875298762987729878298792988029881298822988329884298852988629887298882988929890298912989229893298942989529896298972989829899299002990129902299032990429905299062990729908299092991029911299122991329914299152991629917299182991929920299212992229923299242992529926299272992829929299302993129932299332993429935299362993729938299392994029941299422994329944299452994629947299482994929950299512995229953299542995529956299572995829959299602996129962299632996429965299662996729968299692997029971299722997329974299752997629977299782997929980299812998229983299842998529986299872998829989299902999129992299932999429995299962999729998299993000030001300023000330004300053000630007300083000930010300113001230013300143001530016300173001830019300203002130022300233002430025300263002730028300293003030031300323003330034300353003630037300383003930040300413004230043300443004530046300473004830049300503005130052300533005430055300563005730058300593006030061300623006330064300653006630067300683006930070300713007230073300743007530076300773007830079300803008130082300833008430085300863008730088300893009030091300923009330094300953009630097300983009930100301013010230103301043010530106301073010830109301103011130112301133011430115301163011730118301193012030121301223012330124301253012630127301283012930130301313013230133301343013530136301373013830139301403014130142301433014430145301463014730148301493015030151301523015330154301553015630157301583015930160301613016230163301643016530166301673016830169301703017130172301733017430175301763017730178301793018030181301823018330184301853018630187301883018930190301913019230193301943019530196301973019830199302003020130202302033020430205302063020730208302093021030211302123021330214302153021630217302183021930220302213022230223302243022530226302273022830229302303023130232302333023430235302363023730238302393024030241302423024330244302453024630247302483024930250302513025230253302543025530256302573025830259302603026130262302633026430265302663026730268302693027030271302723027330274302753027630277302783027930280302813028230283302843028530286302873028830289302903029130292302933029430295302963029730298302993030030301303023030330304303053030630307303083030930310303113031230313303143031530316303173031830319303203032130322303233032430325303263032730328303293033030331303323033330334303353033630337303383033930340303413034230343303443034530346303473034830349303503035130352303533035430355303563035730358303593036030361303623036330364303653036630367303683036930370303713037230373303743037530376303773037830379303803038130382303833038430385303863038730388303893039030391303923039330394303953039630397303983039930400304013040230403304043040530406304073040830409304103041130412304133041430415304163041730418304193042030421304223042330424304253042630427304283042930430304313043230433304343043530436304373043830439304403044130442304433044430445304463044730448304493045030451304523045330454304553045630457304583045930460304613046230463304643046530466304673046830469304703047130472304733047430475304763047730478304793048030481304823048330484304853048630487304883048930490304913049230493304943049530496304973049830499305003050130502305033050430505305063050730508305093051030511305123051330514305153051630517305183051930520305213052230523305243052530526305273052830529305303053130532305333053430535305363053730538305393054030541305423054330544305453054630547305483054930550305513055230553305543055530556305573055830559305603056130562305633056430565305663056730568305693057030571305723057330574305753057630577305783057930580305813058230583305843058530586305873058830589305903059130592305933059430595305963059730598305993060030601306023060330604306053060630607306083060930610306113061230613306143061530616306173061830619306203062130622306233062430625306263062730628306293063030631306323063330634306353063630637306383063930640306413064230643306443064530646306473064830649306503065130652306533065430655306563065730658306593066030661306623066330664306653066630667306683066930670306713067230673306743067530676306773067830679306803068130682306833068430685306863068730688306893069030691306923069330694306953069630697306983069930700307013070230703307043070530706307073070830709307103071130712307133071430715307163071730718307193072030721307223072330724307253072630727307283072930730307313073230733307343073530736307373073830739307403074130742307433074430745307463074730748307493075030751307523075330754307553075630757307583075930760307613076230763307643076530766307673076830769307703077130772307733077430775307763077730778307793078030781307823078330784307853078630787307883078930790307913079230793307943079530796307973079830799308003080130802308033080430805308063080730808308093081030811308123081330814308153081630817308183081930820308213082230823308243082530826308273082830829308303083130832308333083430835308363083730838308393084030841308423084330844308453084630847308483084930850308513085230853308543085530856308573085830859308603086130862308633086430865308663086730868308693087030871308723087330874308753087630877308783087930880308813088230883308843088530886308873088830889308903089130892308933089430895308963089730898308993090030901309023090330904309053090630907309083090930910309113091230913309143091530916309173091830919309203092130922309233092430925309263092730928309293093030931309323093330934309353093630937309383093930940309413094230943309443094530946309473094830949309503095130952309533095430955309563095730958309593096030961309623096330964309653096630967309683096930970309713097230973309743097530976309773097830979309803098130982309833098430985309863098730988309893099030991309923099330994309953099630997309983099931000310013100231003310043100531006310073100831009310103101131012310133101431015310163101731018310193102031021310223102331024310253102631027310283102931030310313103231033310343103531036310373103831039310403104131042310433104431045310463104731048310493105031051310523105331054310553105631057310583105931060310613106231063310643106531066310673106831069310703107131072310733107431075310763107731078310793108031081310823108331084310853108631087310883108931090310913109231093310943109531096310973109831099311003110131102311033110431105311063110731108311093111031111311123111331114311153111631117311183111931120311213112231123311243112531126311273112831129311303113131132311333113431135311363113731138311393114031141311423114331144311453114631147311483114931150311513115231153311543115531156311573115831159311603116131162311633116431165311663116731168311693117031171311723117331174311753117631177311783117931180311813118231183311843118531186311873118831189311903119131192311933119431195311963119731198311993120031201312023120331204312053120631207312083120931210312113121231213312143121531216312173121831219312203122131222312233122431225312263122731228312293123031231312323123331234312353123631237312383123931240312413124231243312443124531246312473124831249312503125131252312533125431255312563125731258312593126031261312623126331264312653126631267312683126931270312713127231273312743127531276312773127831279312803128131282312833128431285312863128731288312893129031291312923129331294312953129631297312983129931300313013130231303313043130531306313073130831309313103131131312313133131431315313163131731318313193132031321313223132331324313253132631327313283132931330313313133231333313343133531336313373133831339313403134131342313433134431345313463134731348313493135031351313523135331354313553135631357313583135931360313613136231363313643136531366313673136831369313703137131372313733137431375313763137731378313793138031381313823138331384313853138631387313883138931390313913139231393313943139531396313973139831399314003140131402314033140431405314063140731408314093141031411314123141331414314153141631417314183141931420314213142231423314243142531426314273142831429314303143131432314333143431435314363143731438314393144031441314423144331444314453144631447314483144931450314513145231453314543145531456314573145831459314603146131462314633146431465314663146731468314693147031471314723147331474314753147631477314783147931480314813148231483314843148531486314873148831489314903149131492314933149431495314963149731498314993150031501315023150331504315053150631507315083150931510315113151231513315143151531516315173151831519315203152131522315233152431525315263152731528315293153031531315323153331534315353153631537315383153931540315413154231543315443154531546315473154831549315503155131552315533155431555315563155731558315593156031561315623156331564315653156631567315683156931570315713157231573315743157531576315773157831579315803158131582315833158431585315863158731588315893159031591315923159331594315953159631597315983159931600316013160231603316043160531606316073160831609316103161131612316133161431615316163161731618316193162031621316223162331624316253162631627316283162931630316313163231633316343163531636316373163831639316403164131642316433164431645316463164731648316493165031651316523165331654316553165631657316583165931660316613166231663316643166531666316673166831669316703167131672316733167431675316763167731678316793168031681316823168331684316853168631687316883168931690316913169231693316943169531696316973169831699317003170131702317033170431705317063170731708317093171031711317123171331714317153171631717317183171931720317213172231723317243172531726317273172831729317303173131732317333173431735317363173731738317393174031741317423174331744317453174631747317483174931750317513175231753317543175531756317573175831759317603176131762317633176431765317663176731768317693177031771317723177331774317753177631777317783177931780317813178231783317843178531786317873178831789317903179131792317933179431795317963179731798317993180031801318023180331804318053180631807318083180931810318113181231813318143181531816318173181831819318203182131822318233182431825318263182731828318293183031831318323183331834318353183631837318383183931840318413184231843318443184531846318473184831849318503185131852318533185431855318563185731858318593186031861318623186331864318653186631867318683186931870318713187231873318743187531876318773187831879318803188131882318833188431885318863188731888318893189031891318923189331894318953189631897318983189931900319013190231903319043190531906319073190831909319103191131912319133191431915319163191731918319193192031921319223192331924319253192631927319283192931930319313193231933319343193531936319373193831939319403194131942319433194431945319463194731948319493195031951319523195331954319553195631957319583195931960319613196231963319643196531966319673196831969319703197131972319733197431975319763197731978319793198031981319823198331984319853198631987319883198931990319913199231993319943199531996319973199831999320003200132002320033200432005320063200732008320093201032011320123201332014320153201632017320183201932020320213202232023320243202532026320273202832029320303203132032320333203432035320363203732038320393204032041320423204332044320453204632047320483204932050320513205232053320543205532056320573205832059320603206132062320633206432065320663206732068320693207032071320723207332074320753207632077320783207932080320813208232083320843208532086320873208832089320903209132092320933209432095320963209732098320993210032101321023210332104321053210632107321083210932110321113211232113321143211532116321173211832119321203212132122321233212432125321263212732128321293213032131321323213332134321353213632137321383213932140321413214232143321443214532146321473214832149321503215132152321533215432155321563215732158321593216032161321623216332164321653216632167321683216932170321713217232173321743217532176321773217832179321803218132182321833218432185321863218732188321893219032191321923219332194321953219632197321983219932200322013220232203322043220532206322073220832209322103221132212322133221432215322163221732218322193222032221322223222332224322253222632227322283222932230322313223232233322343223532236322373223832239322403224132242322433224432245322463224732248322493225032251322523225332254322553225632257322583225932260322613226232263322643226532266322673226832269322703227132272322733227432275322763227732278322793228032281322823228332284322853228632287322883228932290322913229232293322943229532296322973229832299323003230132302323033230432305323063230732308323093231032311323123231332314323153231632317323183231932320323213232232323323243232532326323273232832329323303233132332323333233432335323363233732338323393234032341323423234332344323453234632347323483234932350323513235232353323543235532356323573235832359323603236132362323633236432365323663236732368323693237032371323723237332374323753237632377323783237932380323813238232383323843238532386323873238832389323903239132392323933239432395323963239732398323993240032401324023240332404324053240632407324083240932410324113241232413324143241532416324173241832419324203242132422324233242432425324263242732428324293243032431324323243332434324353243632437324383243932440324413244232443324443244532446324473244832449324503245132452324533245432455324563245732458324593246032461324623246332464324653246632467324683246932470324713247232473324743247532476324773247832479324803248132482324833248432485324863248732488324893249032491324923249332494324953249632497324983249932500325013250232503325043250532506325073250832509325103251132512325133251432515325163251732518325193252032521325223252332524325253252632527325283252932530325313253232533325343253532536325373253832539325403254132542325433254432545325463254732548325493255032551325523255332554325553255632557325583255932560325613256232563325643256532566325673256832569325703257132572325733257432575325763257732578325793258032581325823258332584325853258632587325883258932590325913259232593325943259532596325973259832599326003260132602326033260432605326063260732608326093261032611326123261332614326153261632617326183261932620326213262232623326243262532626326273262832629326303263132632326333263432635326363263732638326393264032641326423264332644326453264632647326483264932650326513265232653326543265532656326573265832659326603266132662326633266432665326663266732668326693267032671326723267332674326753267632677326783267932680326813268232683326843268532686326873268832689326903269132692326933269432695326963269732698326993270032701327023270332704327053270632707327083270932710327113271232713327143271532716327173271832719327203272132722327233272432725327263272732728
  1. // +build !notfastpath
  2. // Copyright (c) 2012-2015 Ugorji Nwoke. All rights reserved.
  3. // Use of this source code is governed by a MIT license found in the LICENSE file.
  4. // ************************************************************
  5. // DO NOT EDIT.
  6. // THIS FILE IS AUTO-GENERATED from fast-path.go.tmpl
  7. // ************************************************************
  8. package codec
  9. // Fast path functions try to create a fast path encode or decode implementation
  10. // for common maps and slices.
  11. //
  12. // We define the functions and register then in this single file
  13. // so as not to pollute the encode.go and decode.go, and create a dependency in there.
  14. // This file can be omitted without causing a build failure.
  15. //
  16. // The advantage of fast paths is:
  17. // - Many calls bypass reflection altogether
  18. //
  19. // Currently support
  20. // - slice of all builtin types,
  21. // - map of all builtin types to string or interface value
  22. // - symmetrical maps of all builtin types (e.g. str-str, uint8-uint8)
  23. // This should provide adequate "typical" implementations.
  24. //
  25. // Note that fast track decode functions must handle values for which an address cannot be obtained.
  26. // For example:
  27. // m2 := map[string]int{}
  28. // p2 := []interface{}{m2}
  29. // // decoding into p2 will bomb if fast track functions do not treat like unaddressable.
  30. //
  31. import (
  32. "reflect"
  33. "sort"
  34. )
  35. const fastpathEnabled = true
  36. type fastpathT struct{}
  37. var fastpathTV fastpathT
  38. type fastpathE struct {
  39. rtid uintptr
  40. rt reflect.Type
  41. encfn func(*Encoder, *codecFnInfo, reflect.Value)
  42. decfn func(*Decoder, *codecFnInfo, reflect.Value)
  43. }
  44. type fastpathA [271]fastpathE
  45. func (x *fastpathA) index(rtid uintptr) int {
  46. // use binary search to grab the index (adapted from sort/search.go)
  47. h, i, j := 0, 0, 271 // len(x)
  48. for i < j {
  49. h = i + (j-i)/2
  50. if x[h].rtid < rtid {
  51. i = h + 1
  52. } else {
  53. j = h
  54. }
  55. }
  56. if i < 271 && x[i].rtid == rtid {
  57. return i
  58. }
  59. return -1
  60. }
  61. type fastpathAslice []fastpathE
  62. func (x fastpathAslice) Len() int { return len(x) }
  63. func (x fastpathAslice) Less(i, j int) bool { return x[i].rtid < x[j].rtid }
  64. func (x fastpathAslice) Swap(i, j int) { x[i], x[j] = x[j], x[i] }
  65. var fastpathAV fastpathA
  66. // due to possible initialization loop error, make fastpath in an init()
  67. func init() {
  68. i := 0
  69. fn := func(v interface{},
  70. fe func(*Encoder, *codecFnInfo, reflect.Value),
  71. fd func(*Decoder, *codecFnInfo, reflect.Value)) (f fastpathE) {
  72. xrt := reflect.TypeOf(v)
  73. xptr := rt2id(xrt)
  74. if useLookupRecognizedTypes {
  75. recognizedRtids = append(recognizedRtids, xptr)
  76. recognizedRtidPtrs = append(recognizedRtidPtrs, rt2id(reflect.PtrTo(xrt)))
  77. }
  78. fastpathAV[i] = fastpathE{xptr, xrt, fe, fd}
  79. i++
  80. return
  81. }
  82. fn([]interface{}(nil), (*Encoder).fastpathEncSliceIntfR, (*Decoder).fastpathDecSliceIntfR)
  83. fn([]string(nil), (*Encoder).fastpathEncSliceStringR, (*Decoder).fastpathDecSliceStringR)
  84. fn([]float32(nil), (*Encoder).fastpathEncSliceFloat32R, (*Decoder).fastpathDecSliceFloat32R)
  85. fn([]float64(nil), (*Encoder).fastpathEncSliceFloat64R, (*Decoder).fastpathDecSliceFloat64R)
  86. fn([]uint(nil), (*Encoder).fastpathEncSliceUintR, (*Decoder).fastpathDecSliceUintR)
  87. fn([]uint16(nil), (*Encoder).fastpathEncSliceUint16R, (*Decoder).fastpathDecSliceUint16R)
  88. fn([]uint32(nil), (*Encoder).fastpathEncSliceUint32R, (*Decoder).fastpathDecSliceUint32R)
  89. fn([]uint64(nil), (*Encoder).fastpathEncSliceUint64R, (*Decoder).fastpathDecSliceUint64R)
  90. fn([]uintptr(nil), (*Encoder).fastpathEncSliceUintptrR, (*Decoder).fastpathDecSliceUintptrR)
  91. fn([]int(nil), (*Encoder).fastpathEncSliceIntR, (*Decoder).fastpathDecSliceIntR)
  92. fn([]int8(nil), (*Encoder).fastpathEncSliceInt8R, (*Decoder).fastpathDecSliceInt8R)
  93. fn([]int16(nil), (*Encoder).fastpathEncSliceInt16R, (*Decoder).fastpathDecSliceInt16R)
  94. fn([]int32(nil), (*Encoder).fastpathEncSliceInt32R, (*Decoder).fastpathDecSliceInt32R)
  95. fn([]int64(nil), (*Encoder).fastpathEncSliceInt64R, (*Decoder).fastpathDecSliceInt64R)
  96. fn([]bool(nil), (*Encoder).fastpathEncSliceBoolR, (*Decoder).fastpathDecSliceBoolR)
  97. fn(map[interface{}]interface{}(nil), (*Encoder).fastpathEncMapIntfIntfR, (*Decoder).fastpathDecMapIntfIntfR)
  98. fn(map[interface{}]string(nil), (*Encoder).fastpathEncMapIntfStringR, (*Decoder).fastpathDecMapIntfStringR)
  99. fn(map[interface{}]uint(nil), (*Encoder).fastpathEncMapIntfUintR, (*Decoder).fastpathDecMapIntfUintR)
  100. fn(map[interface{}]uint8(nil), (*Encoder).fastpathEncMapIntfUint8R, (*Decoder).fastpathDecMapIntfUint8R)
  101. fn(map[interface{}]uint16(nil), (*Encoder).fastpathEncMapIntfUint16R, (*Decoder).fastpathDecMapIntfUint16R)
  102. fn(map[interface{}]uint32(nil), (*Encoder).fastpathEncMapIntfUint32R, (*Decoder).fastpathDecMapIntfUint32R)
  103. fn(map[interface{}]uint64(nil), (*Encoder).fastpathEncMapIntfUint64R, (*Decoder).fastpathDecMapIntfUint64R)
  104. fn(map[interface{}]uintptr(nil), (*Encoder).fastpathEncMapIntfUintptrR, (*Decoder).fastpathDecMapIntfUintptrR)
  105. fn(map[interface{}]int(nil), (*Encoder).fastpathEncMapIntfIntR, (*Decoder).fastpathDecMapIntfIntR)
  106. fn(map[interface{}]int8(nil), (*Encoder).fastpathEncMapIntfInt8R, (*Decoder).fastpathDecMapIntfInt8R)
  107. fn(map[interface{}]int16(nil), (*Encoder).fastpathEncMapIntfInt16R, (*Decoder).fastpathDecMapIntfInt16R)
  108. fn(map[interface{}]int32(nil), (*Encoder).fastpathEncMapIntfInt32R, (*Decoder).fastpathDecMapIntfInt32R)
  109. fn(map[interface{}]int64(nil), (*Encoder).fastpathEncMapIntfInt64R, (*Decoder).fastpathDecMapIntfInt64R)
  110. fn(map[interface{}]float32(nil), (*Encoder).fastpathEncMapIntfFloat32R, (*Decoder).fastpathDecMapIntfFloat32R)
  111. fn(map[interface{}]float64(nil), (*Encoder).fastpathEncMapIntfFloat64R, (*Decoder).fastpathDecMapIntfFloat64R)
  112. fn(map[interface{}]bool(nil), (*Encoder).fastpathEncMapIntfBoolR, (*Decoder).fastpathDecMapIntfBoolR)
  113. fn(map[string]interface{}(nil), (*Encoder).fastpathEncMapStringIntfR, (*Decoder).fastpathDecMapStringIntfR)
  114. fn(map[string]string(nil), (*Encoder).fastpathEncMapStringStringR, (*Decoder).fastpathDecMapStringStringR)
  115. fn(map[string]uint(nil), (*Encoder).fastpathEncMapStringUintR, (*Decoder).fastpathDecMapStringUintR)
  116. fn(map[string]uint8(nil), (*Encoder).fastpathEncMapStringUint8R, (*Decoder).fastpathDecMapStringUint8R)
  117. fn(map[string]uint16(nil), (*Encoder).fastpathEncMapStringUint16R, (*Decoder).fastpathDecMapStringUint16R)
  118. fn(map[string]uint32(nil), (*Encoder).fastpathEncMapStringUint32R, (*Decoder).fastpathDecMapStringUint32R)
  119. fn(map[string]uint64(nil), (*Encoder).fastpathEncMapStringUint64R, (*Decoder).fastpathDecMapStringUint64R)
  120. fn(map[string]uintptr(nil), (*Encoder).fastpathEncMapStringUintptrR, (*Decoder).fastpathDecMapStringUintptrR)
  121. fn(map[string]int(nil), (*Encoder).fastpathEncMapStringIntR, (*Decoder).fastpathDecMapStringIntR)
  122. fn(map[string]int8(nil), (*Encoder).fastpathEncMapStringInt8R, (*Decoder).fastpathDecMapStringInt8R)
  123. fn(map[string]int16(nil), (*Encoder).fastpathEncMapStringInt16R, (*Decoder).fastpathDecMapStringInt16R)
  124. fn(map[string]int32(nil), (*Encoder).fastpathEncMapStringInt32R, (*Decoder).fastpathDecMapStringInt32R)
  125. fn(map[string]int64(nil), (*Encoder).fastpathEncMapStringInt64R, (*Decoder).fastpathDecMapStringInt64R)
  126. fn(map[string]float32(nil), (*Encoder).fastpathEncMapStringFloat32R, (*Decoder).fastpathDecMapStringFloat32R)
  127. fn(map[string]float64(nil), (*Encoder).fastpathEncMapStringFloat64R, (*Decoder).fastpathDecMapStringFloat64R)
  128. fn(map[string]bool(nil), (*Encoder).fastpathEncMapStringBoolR, (*Decoder).fastpathDecMapStringBoolR)
  129. fn(map[float32]interface{}(nil), (*Encoder).fastpathEncMapFloat32IntfR, (*Decoder).fastpathDecMapFloat32IntfR)
  130. fn(map[float32]string(nil), (*Encoder).fastpathEncMapFloat32StringR, (*Decoder).fastpathDecMapFloat32StringR)
  131. fn(map[float32]uint(nil), (*Encoder).fastpathEncMapFloat32UintR, (*Decoder).fastpathDecMapFloat32UintR)
  132. fn(map[float32]uint8(nil), (*Encoder).fastpathEncMapFloat32Uint8R, (*Decoder).fastpathDecMapFloat32Uint8R)
  133. fn(map[float32]uint16(nil), (*Encoder).fastpathEncMapFloat32Uint16R, (*Decoder).fastpathDecMapFloat32Uint16R)
  134. fn(map[float32]uint32(nil), (*Encoder).fastpathEncMapFloat32Uint32R, (*Decoder).fastpathDecMapFloat32Uint32R)
  135. fn(map[float32]uint64(nil), (*Encoder).fastpathEncMapFloat32Uint64R, (*Decoder).fastpathDecMapFloat32Uint64R)
  136. fn(map[float32]uintptr(nil), (*Encoder).fastpathEncMapFloat32UintptrR, (*Decoder).fastpathDecMapFloat32UintptrR)
  137. fn(map[float32]int(nil), (*Encoder).fastpathEncMapFloat32IntR, (*Decoder).fastpathDecMapFloat32IntR)
  138. fn(map[float32]int8(nil), (*Encoder).fastpathEncMapFloat32Int8R, (*Decoder).fastpathDecMapFloat32Int8R)
  139. fn(map[float32]int16(nil), (*Encoder).fastpathEncMapFloat32Int16R, (*Decoder).fastpathDecMapFloat32Int16R)
  140. fn(map[float32]int32(nil), (*Encoder).fastpathEncMapFloat32Int32R, (*Decoder).fastpathDecMapFloat32Int32R)
  141. fn(map[float32]int64(nil), (*Encoder).fastpathEncMapFloat32Int64R, (*Decoder).fastpathDecMapFloat32Int64R)
  142. fn(map[float32]float32(nil), (*Encoder).fastpathEncMapFloat32Float32R, (*Decoder).fastpathDecMapFloat32Float32R)
  143. fn(map[float32]float64(nil), (*Encoder).fastpathEncMapFloat32Float64R, (*Decoder).fastpathDecMapFloat32Float64R)
  144. fn(map[float32]bool(nil), (*Encoder).fastpathEncMapFloat32BoolR, (*Decoder).fastpathDecMapFloat32BoolR)
  145. fn(map[float64]interface{}(nil), (*Encoder).fastpathEncMapFloat64IntfR, (*Decoder).fastpathDecMapFloat64IntfR)
  146. fn(map[float64]string(nil), (*Encoder).fastpathEncMapFloat64StringR, (*Decoder).fastpathDecMapFloat64StringR)
  147. fn(map[float64]uint(nil), (*Encoder).fastpathEncMapFloat64UintR, (*Decoder).fastpathDecMapFloat64UintR)
  148. fn(map[float64]uint8(nil), (*Encoder).fastpathEncMapFloat64Uint8R, (*Decoder).fastpathDecMapFloat64Uint8R)
  149. fn(map[float64]uint16(nil), (*Encoder).fastpathEncMapFloat64Uint16R, (*Decoder).fastpathDecMapFloat64Uint16R)
  150. fn(map[float64]uint32(nil), (*Encoder).fastpathEncMapFloat64Uint32R, (*Decoder).fastpathDecMapFloat64Uint32R)
  151. fn(map[float64]uint64(nil), (*Encoder).fastpathEncMapFloat64Uint64R, (*Decoder).fastpathDecMapFloat64Uint64R)
  152. fn(map[float64]uintptr(nil), (*Encoder).fastpathEncMapFloat64UintptrR, (*Decoder).fastpathDecMapFloat64UintptrR)
  153. fn(map[float64]int(nil), (*Encoder).fastpathEncMapFloat64IntR, (*Decoder).fastpathDecMapFloat64IntR)
  154. fn(map[float64]int8(nil), (*Encoder).fastpathEncMapFloat64Int8R, (*Decoder).fastpathDecMapFloat64Int8R)
  155. fn(map[float64]int16(nil), (*Encoder).fastpathEncMapFloat64Int16R, (*Decoder).fastpathDecMapFloat64Int16R)
  156. fn(map[float64]int32(nil), (*Encoder).fastpathEncMapFloat64Int32R, (*Decoder).fastpathDecMapFloat64Int32R)
  157. fn(map[float64]int64(nil), (*Encoder).fastpathEncMapFloat64Int64R, (*Decoder).fastpathDecMapFloat64Int64R)
  158. fn(map[float64]float32(nil), (*Encoder).fastpathEncMapFloat64Float32R, (*Decoder).fastpathDecMapFloat64Float32R)
  159. fn(map[float64]float64(nil), (*Encoder).fastpathEncMapFloat64Float64R, (*Decoder).fastpathDecMapFloat64Float64R)
  160. fn(map[float64]bool(nil), (*Encoder).fastpathEncMapFloat64BoolR, (*Decoder).fastpathDecMapFloat64BoolR)
  161. fn(map[uint]interface{}(nil), (*Encoder).fastpathEncMapUintIntfR, (*Decoder).fastpathDecMapUintIntfR)
  162. fn(map[uint]string(nil), (*Encoder).fastpathEncMapUintStringR, (*Decoder).fastpathDecMapUintStringR)
  163. fn(map[uint]uint(nil), (*Encoder).fastpathEncMapUintUintR, (*Decoder).fastpathDecMapUintUintR)
  164. fn(map[uint]uint8(nil), (*Encoder).fastpathEncMapUintUint8R, (*Decoder).fastpathDecMapUintUint8R)
  165. fn(map[uint]uint16(nil), (*Encoder).fastpathEncMapUintUint16R, (*Decoder).fastpathDecMapUintUint16R)
  166. fn(map[uint]uint32(nil), (*Encoder).fastpathEncMapUintUint32R, (*Decoder).fastpathDecMapUintUint32R)
  167. fn(map[uint]uint64(nil), (*Encoder).fastpathEncMapUintUint64R, (*Decoder).fastpathDecMapUintUint64R)
  168. fn(map[uint]uintptr(nil), (*Encoder).fastpathEncMapUintUintptrR, (*Decoder).fastpathDecMapUintUintptrR)
  169. fn(map[uint]int(nil), (*Encoder).fastpathEncMapUintIntR, (*Decoder).fastpathDecMapUintIntR)
  170. fn(map[uint]int8(nil), (*Encoder).fastpathEncMapUintInt8R, (*Decoder).fastpathDecMapUintInt8R)
  171. fn(map[uint]int16(nil), (*Encoder).fastpathEncMapUintInt16R, (*Decoder).fastpathDecMapUintInt16R)
  172. fn(map[uint]int32(nil), (*Encoder).fastpathEncMapUintInt32R, (*Decoder).fastpathDecMapUintInt32R)
  173. fn(map[uint]int64(nil), (*Encoder).fastpathEncMapUintInt64R, (*Decoder).fastpathDecMapUintInt64R)
  174. fn(map[uint]float32(nil), (*Encoder).fastpathEncMapUintFloat32R, (*Decoder).fastpathDecMapUintFloat32R)
  175. fn(map[uint]float64(nil), (*Encoder).fastpathEncMapUintFloat64R, (*Decoder).fastpathDecMapUintFloat64R)
  176. fn(map[uint]bool(nil), (*Encoder).fastpathEncMapUintBoolR, (*Decoder).fastpathDecMapUintBoolR)
  177. fn(map[uint8]interface{}(nil), (*Encoder).fastpathEncMapUint8IntfR, (*Decoder).fastpathDecMapUint8IntfR)
  178. fn(map[uint8]string(nil), (*Encoder).fastpathEncMapUint8StringR, (*Decoder).fastpathDecMapUint8StringR)
  179. fn(map[uint8]uint(nil), (*Encoder).fastpathEncMapUint8UintR, (*Decoder).fastpathDecMapUint8UintR)
  180. fn(map[uint8]uint8(nil), (*Encoder).fastpathEncMapUint8Uint8R, (*Decoder).fastpathDecMapUint8Uint8R)
  181. fn(map[uint8]uint16(nil), (*Encoder).fastpathEncMapUint8Uint16R, (*Decoder).fastpathDecMapUint8Uint16R)
  182. fn(map[uint8]uint32(nil), (*Encoder).fastpathEncMapUint8Uint32R, (*Decoder).fastpathDecMapUint8Uint32R)
  183. fn(map[uint8]uint64(nil), (*Encoder).fastpathEncMapUint8Uint64R, (*Decoder).fastpathDecMapUint8Uint64R)
  184. fn(map[uint8]uintptr(nil), (*Encoder).fastpathEncMapUint8UintptrR, (*Decoder).fastpathDecMapUint8UintptrR)
  185. fn(map[uint8]int(nil), (*Encoder).fastpathEncMapUint8IntR, (*Decoder).fastpathDecMapUint8IntR)
  186. fn(map[uint8]int8(nil), (*Encoder).fastpathEncMapUint8Int8R, (*Decoder).fastpathDecMapUint8Int8R)
  187. fn(map[uint8]int16(nil), (*Encoder).fastpathEncMapUint8Int16R, (*Decoder).fastpathDecMapUint8Int16R)
  188. fn(map[uint8]int32(nil), (*Encoder).fastpathEncMapUint8Int32R, (*Decoder).fastpathDecMapUint8Int32R)
  189. fn(map[uint8]int64(nil), (*Encoder).fastpathEncMapUint8Int64R, (*Decoder).fastpathDecMapUint8Int64R)
  190. fn(map[uint8]float32(nil), (*Encoder).fastpathEncMapUint8Float32R, (*Decoder).fastpathDecMapUint8Float32R)
  191. fn(map[uint8]float64(nil), (*Encoder).fastpathEncMapUint8Float64R, (*Decoder).fastpathDecMapUint8Float64R)
  192. fn(map[uint8]bool(nil), (*Encoder).fastpathEncMapUint8BoolR, (*Decoder).fastpathDecMapUint8BoolR)
  193. fn(map[uint16]interface{}(nil), (*Encoder).fastpathEncMapUint16IntfR, (*Decoder).fastpathDecMapUint16IntfR)
  194. fn(map[uint16]string(nil), (*Encoder).fastpathEncMapUint16StringR, (*Decoder).fastpathDecMapUint16StringR)
  195. fn(map[uint16]uint(nil), (*Encoder).fastpathEncMapUint16UintR, (*Decoder).fastpathDecMapUint16UintR)
  196. fn(map[uint16]uint8(nil), (*Encoder).fastpathEncMapUint16Uint8R, (*Decoder).fastpathDecMapUint16Uint8R)
  197. fn(map[uint16]uint16(nil), (*Encoder).fastpathEncMapUint16Uint16R, (*Decoder).fastpathDecMapUint16Uint16R)
  198. fn(map[uint16]uint32(nil), (*Encoder).fastpathEncMapUint16Uint32R, (*Decoder).fastpathDecMapUint16Uint32R)
  199. fn(map[uint16]uint64(nil), (*Encoder).fastpathEncMapUint16Uint64R, (*Decoder).fastpathDecMapUint16Uint64R)
  200. fn(map[uint16]uintptr(nil), (*Encoder).fastpathEncMapUint16UintptrR, (*Decoder).fastpathDecMapUint16UintptrR)
  201. fn(map[uint16]int(nil), (*Encoder).fastpathEncMapUint16IntR, (*Decoder).fastpathDecMapUint16IntR)
  202. fn(map[uint16]int8(nil), (*Encoder).fastpathEncMapUint16Int8R, (*Decoder).fastpathDecMapUint16Int8R)
  203. fn(map[uint16]int16(nil), (*Encoder).fastpathEncMapUint16Int16R, (*Decoder).fastpathDecMapUint16Int16R)
  204. fn(map[uint16]int32(nil), (*Encoder).fastpathEncMapUint16Int32R, (*Decoder).fastpathDecMapUint16Int32R)
  205. fn(map[uint16]int64(nil), (*Encoder).fastpathEncMapUint16Int64R, (*Decoder).fastpathDecMapUint16Int64R)
  206. fn(map[uint16]float32(nil), (*Encoder).fastpathEncMapUint16Float32R, (*Decoder).fastpathDecMapUint16Float32R)
  207. fn(map[uint16]float64(nil), (*Encoder).fastpathEncMapUint16Float64R, (*Decoder).fastpathDecMapUint16Float64R)
  208. fn(map[uint16]bool(nil), (*Encoder).fastpathEncMapUint16BoolR, (*Decoder).fastpathDecMapUint16BoolR)
  209. fn(map[uint32]interface{}(nil), (*Encoder).fastpathEncMapUint32IntfR, (*Decoder).fastpathDecMapUint32IntfR)
  210. fn(map[uint32]string(nil), (*Encoder).fastpathEncMapUint32StringR, (*Decoder).fastpathDecMapUint32StringR)
  211. fn(map[uint32]uint(nil), (*Encoder).fastpathEncMapUint32UintR, (*Decoder).fastpathDecMapUint32UintR)
  212. fn(map[uint32]uint8(nil), (*Encoder).fastpathEncMapUint32Uint8R, (*Decoder).fastpathDecMapUint32Uint8R)
  213. fn(map[uint32]uint16(nil), (*Encoder).fastpathEncMapUint32Uint16R, (*Decoder).fastpathDecMapUint32Uint16R)
  214. fn(map[uint32]uint32(nil), (*Encoder).fastpathEncMapUint32Uint32R, (*Decoder).fastpathDecMapUint32Uint32R)
  215. fn(map[uint32]uint64(nil), (*Encoder).fastpathEncMapUint32Uint64R, (*Decoder).fastpathDecMapUint32Uint64R)
  216. fn(map[uint32]uintptr(nil), (*Encoder).fastpathEncMapUint32UintptrR, (*Decoder).fastpathDecMapUint32UintptrR)
  217. fn(map[uint32]int(nil), (*Encoder).fastpathEncMapUint32IntR, (*Decoder).fastpathDecMapUint32IntR)
  218. fn(map[uint32]int8(nil), (*Encoder).fastpathEncMapUint32Int8R, (*Decoder).fastpathDecMapUint32Int8R)
  219. fn(map[uint32]int16(nil), (*Encoder).fastpathEncMapUint32Int16R, (*Decoder).fastpathDecMapUint32Int16R)
  220. fn(map[uint32]int32(nil), (*Encoder).fastpathEncMapUint32Int32R, (*Decoder).fastpathDecMapUint32Int32R)
  221. fn(map[uint32]int64(nil), (*Encoder).fastpathEncMapUint32Int64R, (*Decoder).fastpathDecMapUint32Int64R)
  222. fn(map[uint32]float32(nil), (*Encoder).fastpathEncMapUint32Float32R, (*Decoder).fastpathDecMapUint32Float32R)
  223. fn(map[uint32]float64(nil), (*Encoder).fastpathEncMapUint32Float64R, (*Decoder).fastpathDecMapUint32Float64R)
  224. fn(map[uint32]bool(nil), (*Encoder).fastpathEncMapUint32BoolR, (*Decoder).fastpathDecMapUint32BoolR)
  225. fn(map[uint64]interface{}(nil), (*Encoder).fastpathEncMapUint64IntfR, (*Decoder).fastpathDecMapUint64IntfR)
  226. fn(map[uint64]string(nil), (*Encoder).fastpathEncMapUint64StringR, (*Decoder).fastpathDecMapUint64StringR)
  227. fn(map[uint64]uint(nil), (*Encoder).fastpathEncMapUint64UintR, (*Decoder).fastpathDecMapUint64UintR)
  228. fn(map[uint64]uint8(nil), (*Encoder).fastpathEncMapUint64Uint8R, (*Decoder).fastpathDecMapUint64Uint8R)
  229. fn(map[uint64]uint16(nil), (*Encoder).fastpathEncMapUint64Uint16R, (*Decoder).fastpathDecMapUint64Uint16R)
  230. fn(map[uint64]uint32(nil), (*Encoder).fastpathEncMapUint64Uint32R, (*Decoder).fastpathDecMapUint64Uint32R)
  231. fn(map[uint64]uint64(nil), (*Encoder).fastpathEncMapUint64Uint64R, (*Decoder).fastpathDecMapUint64Uint64R)
  232. fn(map[uint64]uintptr(nil), (*Encoder).fastpathEncMapUint64UintptrR, (*Decoder).fastpathDecMapUint64UintptrR)
  233. fn(map[uint64]int(nil), (*Encoder).fastpathEncMapUint64IntR, (*Decoder).fastpathDecMapUint64IntR)
  234. fn(map[uint64]int8(nil), (*Encoder).fastpathEncMapUint64Int8R, (*Decoder).fastpathDecMapUint64Int8R)
  235. fn(map[uint64]int16(nil), (*Encoder).fastpathEncMapUint64Int16R, (*Decoder).fastpathDecMapUint64Int16R)
  236. fn(map[uint64]int32(nil), (*Encoder).fastpathEncMapUint64Int32R, (*Decoder).fastpathDecMapUint64Int32R)
  237. fn(map[uint64]int64(nil), (*Encoder).fastpathEncMapUint64Int64R, (*Decoder).fastpathDecMapUint64Int64R)
  238. fn(map[uint64]float32(nil), (*Encoder).fastpathEncMapUint64Float32R, (*Decoder).fastpathDecMapUint64Float32R)
  239. fn(map[uint64]float64(nil), (*Encoder).fastpathEncMapUint64Float64R, (*Decoder).fastpathDecMapUint64Float64R)
  240. fn(map[uint64]bool(nil), (*Encoder).fastpathEncMapUint64BoolR, (*Decoder).fastpathDecMapUint64BoolR)
  241. fn(map[uintptr]interface{}(nil), (*Encoder).fastpathEncMapUintptrIntfR, (*Decoder).fastpathDecMapUintptrIntfR)
  242. fn(map[uintptr]string(nil), (*Encoder).fastpathEncMapUintptrStringR, (*Decoder).fastpathDecMapUintptrStringR)
  243. fn(map[uintptr]uint(nil), (*Encoder).fastpathEncMapUintptrUintR, (*Decoder).fastpathDecMapUintptrUintR)
  244. fn(map[uintptr]uint8(nil), (*Encoder).fastpathEncMapUintptrUint8R, (*Decoder).fastpathDecMapUintptrUint8R)
  245. fn(map[uintptr]uint16(nil), (*Encoder).fastpathEncMapUintptrUint16R, (*Decoder).fastpathDecMapUintptrUint16R)
  246. fn(map[uintptr]uint32(nil), (*Encoder).fastpathEncMapUintptrUint32R, (*Decoder).fastpathDecMapUintptrUint32R)
  247. fn(map[uintptr]uint64(nil), (*Encoder).fastpathEncMapUintptrUint64R, (*Decoder).fastpathDecMapUintptrUint64R)
  248. fn(map[uintptr]uintptr(nil), (*Encoder).fastpathEncMapUintptrUintptrR, (*Decoder).fastpathDecMapUintptrUintptrR)
  249. fn(map[uintptr]int(nil), (*Encoder).fastpathEncMapUintptrIntR, (*Decoder).fastpathDecMapUintptrIntR)
  250. fn(map[uintptr]int8(nil), (*Encoder).fastpathEncMapUintptrInt8R, (*Decoder).fastpathDecMapUintptrInt8R)
  251. fn(map[uintptr]int16(nil), (*Encoder).fastpathEncMapUintptrInt16R, (*Decoder).fastpathDecMapUintptrInt16R)
  252. fn(map[uintptr]int32(nil), (*Encoder).fastpathEncMapUintptrInt32R, (*Decoder).fastpathDecMapUintptrInt32R)
  253. fn(map[uintptr]int64(nil), (*Encoder).fastpathEncMapUintptrInt64R, (*Decoder).fastpathDecMapUintptrInt64R)
  254. fn(map[uintptr]float32(nil), (*Encoder).fastpathEncMapUintptrFloat32R, (*Decoder).fastpathDecMapUintptrFloat32R)
  255. fn(map[uintptr]float64(nil), (*Encoder).fastpathEncMapUintptrFloat64R, (*Decoder).fastpathDecMapUintptrFloat64R)
  256. fn(map[uintptr]bool(nil), (*Encoder).fastpathEncMapUintptrBoolR, (*Decoder).fastpathDecMapUintptrBoolR)
  257. fn(map[int]interface{}(nil), (*Encoder).fastpathEncMapIntIntfR, (*Decoder).fastpathDecMapIntIntfR)
  258. fn(map[int]string(nil), (*Encoder).fastpathEncMapIntStringR, (*Decoder).fastpathDecMapIntStringR)
  259. fn(map[int]uint(nil), (*Encoder).fastpathEncMapIntUintR, (*Decoder).fastpathDecMapIntUintR)
  260. fn(map[int]uint8(nil), (*Encoder).fastpathEncMapIntUint8R, (*Decoder).fastpathDecMapIntUint8R)
  261. fn(map[int]uint16(nil), (*Encoder).fastpathEncMapIntUint16R, (*Decoder).fastpathDecMapIntUint16R)
  262. fn(map[int]uint32(nil), (*Encoder).fastpathEncMapIntUint32R, (*Decoder).fastpathDecMapIntUint32R)
  263. fn(map[int]uint64(nil), (*Encoder).fastpathEncMapIntUint64R, (*Decoder).fastpathDecMapIntUint64R)
  264. fn(map[int]uintptr(nil), (*Encoder).fastpathEncMapIntUintptrR, (*Decoder).fastpathDecMapIntUintptrR)
  265. fn(map[int]int(nil), (*Encoder).fastpathEncMapIntIntR, (*Decoder).fastpathDecMapIntIntR)
  266. fn(map[int]int8(nil), (*Encoder).fastpathEncMapIntInt8R, (*Decoder).fastpathDecMapIntInt8R)
  267. fn(map[int]int16(nil), (*Encoder).fastpathEncMapIntInt16R, (*Decoder).fastpathDecMapIntInt16R)
  268. fn(map[int]int32(nil), (*Encoder).fastpathEncMapIntInt32R, (*Decoder).fastpathDecMapIntInt32R)
  269. fn(map[int]int64(nil), (*Encoder).fastpathEncMapIntInt64R, (*Decoder).fastpathDecMapIntInt64R)
  270. fn(map[int]float32(nil), (*Encoder).fastpathEncMapIntFloat32R, (*Decoder).fastpathDecMapIntFloat32R)
  271. fn(map[int]float64(nil), (*Encoder).fastpathEncMapIntFloat64R, (*Decoder).fastpathDecMapIntFloat64R)
  272. fn(map[int]bool(nil), (*Encoder).fastpathEncMapIntBoolR, (*Decoder).fastpathDecMapIntBoolR)
  273. fn(map[int8]interface{}(nil), (*Encoder).fastpathEncMapInt8IntfR, (*Decoder).fastpathDecMapInt8IntfR)
  274. fn(map[int8]string(nil), (*Encoder).fastpathEncMapInt8StringR, (*Decoder).fastpathDecMapInt8StringR)
  275. fn(map[int8]uint(nil), (*Encoder).fastpathEncMapInt8UintR, (*Decoder).fastpathDecMapInt8UintR)
  276. fn(map[int8]uint8(nil), (*Encoder).fastpathEncMapInt8Uint8R, (*Decoder).fastpathDecMapInt8Uint8R)
  277. fn(map[int8]uint16(nil), (*Encoder).fastpathEncMapInt8Uint16R, (*Decoder).fastpathDecMapInt8Uint16R)
  278. fn(map[int8]uint32(nil), (*Encoder).fastpathEncMapInt8Uint32R, (*Decoder).fastpathDecMapInt8Uint32R)
  279. fn(map[int8]uint64(nil), (*Encoder).fastpathEncMapInt8Uint64R, (*Decoder).fastpathDecMapInt8Uint64R)
  280. fn(map[int8]uintptr(nil), (*Encoder).fastpathEncMapInt8UintptrR, (*Decoder).fastpathDecMapInt8UintptrR)
  281. fn(map[int8]int(nil), (*Encoder).fastpathEncMapInt8IntR, (*Decoder).fastpathDecMapInt8IntR)
  282. fn(map[int8]int8(nil), (*Encoder).fastpathEncMapInt8Int8R, (*Decoder).fastpathDecMapInt8Int8R)
  283. fn(map[int8]int16(nil), (*Encoder).fastpathEncMapInt8Int16R, (*Decoder).fastpathDecMapInt8Int16R)
  284. fn(map[int8]int32(nil), (*Encoder).fastpathEncMapInt8Int32R, (*Decoder).fastpathDecMapInt8Int32R)
  285. fn(map[int8]int64(nil), (*Encoder).fastpathEncMapInt8Int64R, (*Decoder).fastpathDecMapInt8Int64R)
  286. fn(map[int8]float32(nil), (*Encoder).fastpathEncMapInt8Float32R, (*Decoder).fastpathDecMapInt8Float32R)
  287. fn(map[int8]float64(nil), (*Encoder).fastpathEncMapInt8Float64R, (*Decoder).fastpathDecMapInt8Float64R)
  288. fn(map[int8]bool(nil), (*Encoder).fastpathEncMapInt8BoolR, (*Decoder).fastpathDecMapInt8BoolR)
  289. fn(map[int16]interface{}(nil), (*Encoder).fastpathEncMapInt16IntfR, (*Decoder).fastpathDecMapInt16IntfR)
  290. fn(map[int16]string(nil), (*Encoder).fastpathEncMapInt16StringR, (*Decoder).fastpathDecMapInt16StringR)
  291. fn(map[int16]uint(nil), (*Encoder).fastpathEncMapInt16UintR, (*Decoder).fastpathDecMapInt16UintR)
  292. fn(map[int16]uint8(nil), (*Encoder).fastpathEncMapInt16Uint8R, (*Decoder).fastpathDecMapInt16Uint8R)
  293. fn(map[int16]uint16(nil), (*Encoder).fastpathEncMapInt16Uint16R, (*Decoder).fastpathDecMapInt16Uint16R)
  294. fn(map[int16]uint32(nil), (*Encoder).fastpathEncMapInt16Uint32R, (*Decoder).fastpathDecMapInt16Uint32R)
  295. fn(map[int16]uint64(nil), (*Encoder).fastpathEncMapInt16Uint64R, (*Decoder).fastpathDecMapInt16Uint64R)
  296. fn(map[int16]uintptr(nil), (*Encoder).fastpathEncMapInt16UintptrR, (*Decoder).fastpathDecMapInt16UintptrR)
  297. fn(map[int16]int(nil), (*Encoder).fastpathEncMapInt16IntR, (*Decoder).fastpathDecMapInt16IntR)
  298. fn(map[int16]int8(nil), (*Encoder).fastpathEncMapInt16Int8R, (*Decoder).fastpathDecMapInt16Int8R)
  299. fn(map[int16]int16(nil), (*Encoder).fastpathEncMapInt16Int16R, (*Decoder).fastpathDecMapInt16Int16R)
  300. fn(map[int16]int32(nil), (*Encoder).fastpathEncMapInt16Int32R, (*Decoder).fastpathDecMapInt16Int32R)
  301. fn(map[int16]int64(nil), (*Encoder).fastpathEncMapInt16Int64R, (*Decoder).fastpathDecMapInt16Int64R)
  302. fn(map[int16]float32(nil), (*Encoder).fastpathEncMapInt16Float32R, (*Decoder).fastpathDecMapInt16Float32R)
  303. fn(map[int16]float64(nil), (*Encoder).fastpathEncMapInt16Float64R, (*Decoder).fastpathDecMapInt16Float64R)
  304. fn(map[int16]bool(nil), (*Encoder).fastpathEncMapInt16BoolR, (*Decoder).fastpathDecMapInt16BoolR)
  305. fn(map[int32]interface{}(nil), (*Encoder).fastpathEncMapInt32IntfR, (*Decoder).fastpathDecMapInt32IntfR)
  306. fn(map[int32]string(nil), (*Encoder).fastpathEncMapInt32StringR, (*Decoder).fastpathDecMapInt32StringR)
  307. fn(map[int32]uint(nil), (*Encoder).fastpathEncMapInt32UintR, (*Decoder).fastpathDecMapInt32UintR)
  308. fn(map[int32]uint8(nil), (*Encoder).fastpathEncMapInt32Uint8R, (*Decoder).fastpathDecMapInt32Uint8R)
  309. fn(map[int32]uint16(nil), (*Encoder).fastpathEncMapInt32Uint16R, (*Decoder).fastpathDecMapInt32Uint16R)
  310. fn(map[int32]uint32(nil), (*Encoder).fastpathEncMapInt32Uint32R, (*Decoder).fastpathDecMapInt32Uint32R)
  311. fn(map[int32]uint64(nil), (*Encoder).fastpathEncMapInt32Uint64R, (*Decoder).fastpathDecMapInt32Uint64R)
  312. fn(map[int32]uintptr(nil), (*Encoder).fastpathEncMapInt32UintptrR, (*Decoder).fastpathDecMapInt32UintptrR)
  313. fn(map[int32]int(nil), (*Encoder).fastpathEncMapInt32IntR, (*Decoder).fastpathDecMapInt32IntR)
  314. fn(map[int32]int8(nil), (*Encoder).fastpathEncMapInt32Int8R, (*Decoder).fastpathDecMapInt32Int8R)
  315. fn(map[int32]int16(nil), (*Encoder).fastpathEncMapInt32Int16R, (*Decoder).fastpathDecMapInt32Int16R)
  316. fn(map[int32]int32(nil), (*Encoder).fastpathEncMapInt32Int32R, (*Decoder).fastpathDecMapInt32Int32R)
  317. fn(map[int32]int64(nil), (*Encoder).fastpathEncMapInt32Int64R, (*Decoder).fastpathDecMapInt32Int64R)
  318. fn(map[int32]float32(nil), (*Encoder).fastpathEncMapInt32Float32R, (*Decoder).fastpathDecMapInt32Float32R)
  319. fn(map[int32]float64(nil), (*Encoder).fastpathEncMapInt32Float64R, (*Decoder).fastpathDecMapInt32Float64R)
  320. fn(map[int32]bool(nil), (*Encoder).fastpathEncMapInt32BoolR, (*Decoder).fastpathDecMapInt32BoolR)
  321. fn(map[int64]interface{}(nil), (*Encoder).fastpathEncMapInt64IntfR, (*Decoder).fastpathDecMapInt64IntfR)
  322. fn(map[int64]string(nil), (*Encoder).fastpathEncMapInt64StringR, (*Decoder).fastpathDecMapInt64StringR)
  323. fn(map[int64]uint(nil), (*Encoder).fastpathEncMapInt64UintR, (*Decoder).fastpathDecMapInt64UintR)
  324. fn(map[int64]uint8(nil), (*Encoder).fastpathEncMapInt64Uint8R, (*Decoder).fastpathDecMapInt64Uint8R)
  325. fn(map[int64]uint16(nil), (*Encoder).fastpathEncMapInt64Uint16R, (*Decoder).fastpathDecMapInt64Uint16R)
  326. fn(map[int64]uint32(nil), (*Encoder).fastpathEncMapInt64Uint32R, (*Decoder).fastpathDecMapInt64Uint32R)
  327. fn(map[int64]uint64(nil), (*Encoder).fastpathEncMapInt64Uint64R, (*Decoder).fastpathDecMapInt64Uint64R)
  328. fn(map[int64]uintptr(nil), (*Encoder).fastpathEncMapInt64UintptrR, (*Decoder).fastpathDecMapInt64UintptrR)
  329. fn(map[int64]int(nil), (*Encoder).fastpathEncMapInt64IntR, (*Decoder).fastpathDecMapInt64IntR)
  330. fn(map[int64]int8(nil), (*Encoder).fastpathEncMapInt64Int8R, (*Decoder).fastpathDecMapInt64Int8R)
  331. fn(map[int64]int16(nil), (*Encoder).fastpathEncMapInt64Int16R, (*Decoder).fastpathDecMapInt64Int16R)
  332. fn(map[int64]int32(nil), (*Encoder).fastpathEncMapInt64Int32R, (*Decoder).fastpathDecMapInt64Int32R)
  333. fn(map[int64]int64(nil), (*Encoder).fastpathEncMapInt64Int64R, (*Decoder).fastpathDecMapInt64Int64R)
  334. fn(map[int64]float32(nil), (*Encoder).fastpathEncMapInt64Float32R, (*Decoder).fastpathDecMapInt64Float32R)
  335. fn(map[int64]float64(nil), (*Encoder).fastpathEncMapInt64Float64R, (*Decoder).fastpathDecMapInt64Float64R)
  336. fn(map[int64]bool(nil), (*Encoder).fastpathEncMapInt64BoolR, (*Decoder).fastpathDecMapInt64BoolR)
  337. fn(map[bool]interface{}(nil), (*Encoder).fastpathEncMapBoolIntfR, (*Decoder).fastpathDecMapBoolIntfR)
  338. fn(map[bool]string(nil), (*Encoder).fastpathEncMapBoolStringR, (*Decoder).fastpathDecMapBoolStringR)
  339. fn(map[bool]uint(nil), (*Encoder).fastpathEncMapBoolUintR, (*Decoder).fastpathDecMapBoolUintR)
  340. fn(map[bool]uint8(nil), (*Encoder).fastpathEncMapBoolUint8R, (*Decoder).fastpathDecMapBoolUint8R)
  341. fn(map[bool]uint16(nil), (*Encoder).fastpathEncMapBoolUint16R, (*Decoder).fastpathDecMapBoolUint16R)
  342. fn(map[bool]uint32(nil), (*Encoder).fastpathEncMapBoolUint32R, (*Decoder).fastpathDecMapBoolUint32R)
  343. fn(map[bool]uint64(nil), (*Encoder).fastpathEncMapBoolUint64R, (*Decoder).fastpathDecMapBoolUint64R)
  344. fn(map[bool]uintptr(nil), (*Encoder).fastpathEncMapBoolUintptrR, (*Decoder).fastpathDecMapBoolUintptrR)
  345. fn(map[bool]int(nil), (*Encoder).fastpathEncMapBoolIntR, (*Decoder).fastpathDecMapBoolIntR)
  346. fn(map[bool]int8(nil), (*Encoder).fastpathEncMapBoolInt8R, (*Decoder).fastpathDecMapBoolInt8R)
  347. fn(map[bool]int16(nil), (*Encoder).fastpathEncMapBoolInt16R, (*Decoder).fastpathDecMapBoolInt16R)
  348. fn(map[bool]int32(nil), (*Encoder).fastpathEncMapBoolInt32R, (*Decoder).fastpathDecMapBoolInt32R)
  349. fn(map[bool]int64(nil), (*Encoder).fastpathEncMapBoolInt64R, (*Decoder).fastpathDecMapBoolInt64R)
  350. fn(map[bool]float32(nil), (*Encoder).fastpathEncMapBoolFloat32R, (*Decoder).fastpathDecMapBoolFloat32R)
  351. fn(map[bool]float64(nil), (*Encoder).fastpathEncMapBoolFloat64R, (*Decoder).fastpathDecMapBoolFloat64R)
  352. fn(map[bool]bool(nil), (*Encoder).fastpathEncMapBoolBoolR, (*Decoder).fastpathDecMapBoolBoolR)
  353. sort.Sort(fastpathAslice(fastpathAV[:]))
  354. }
  355. // -- encode
  356. // -- -- fast path type switch
  357. func fastpathEncodeTypeSwitch(iv interface{}, e *Encoder) bool {
  358. switch v := iv.(type) {
  359. case []interface{}:
  360. fastpathTV.EncSliceIntfV(v, e)
  361. case *[]interface{}:
  362. fastpathTV.EncSliceIntfV(*v, e)
  363. case map[interface{}]interface{}:
  364. fastpathTV.EncMapIntfIntfV(v, e)
  365. case *map[interface{}]interface{}:
  366. fastpathTV.EncMapIntfIntfV(*v, e)
  367. case map[interface{}]string:
  368. fastpathTV.EncMapIntfStringV(v, e)
  369. case *map[interface{}]string:
  370. fastpathTV.EncMapIntfStringV(*v, e)
  371. case map[interface{}]uint:
  372. fastpathTV.EncMapIntfUintV(v, e)
  373. case *map[interface{}]uint:
  374. fastpathTV.EncMapIntfUintV(*v, e)
  375. case map[interface{}]uint8:
  376. fastpathTV.EncMapIntfUint8V(v, e)
  377. case *map[interface{}]uint8:
  378. fastpathTV.EncMapIntfUint8V(*v, e)
  379. case map[interface{}]uint16:
  380. fastpathTV.EncMapIntfUint16V(v, e)
  381. case *map[interface{}]uint16:
  382. fastpathTV.EncMapIntfUint16V(*v, e)
  383. case map[interface{}]uint32:
  384. fastpathTV.EncMapIntfUint32V(v, e)
  385. case *map[interface{}]uint32:
  386. fastpathTV.EncMapIntfUint32V(*v, e)
  387. case map[interface{}]uint64:
  388. fastpathTV.EncMapIntfUint64V(v, e)
  389. case *map[interface{}]uint64:
  390. fastpathTV.EncMapIntfUint64V(*v, e)
  391. case map[interface{}]uintptr:
  392. fastpathTV.EncMapIntfUintptrV(v, e)
  393. case *map[interface{}]uintptr:
  394. fastpathTV.EncMapIntfUintptrV(*v, e)
  395. case map[interface{}]int:
  396. fastpathTV.EncMapIntfIntV(v, e)
  397. case *map[interface{}]int:
  398. fastpathTV.EncMapIntfIntV(*v, e)
  399. case map[interface{}]int8:
  400. fastpathTV.EncMapIntfInt8V(v, e)
  401. case *map[interface{}]int8:
  402. fastpathTV.EncMapIntfInt8V(*v, e)
  403. case map[interface{}]int16:
  404. fastpathTV.EncMapIntfInt16V(v, e)
  405. case *map[interface{}]int16:
  406. fastpathTV.EncMapIntfInt16V(*v, e)
  407. case map[interface{}]int32:
  408. fastpathTV.EncMapIntfInt32V(v, e)
  409. case *map[interface{}]int32:
  410. fastpathTV.EncMapIntfInt32V(*v, e)
  411. case map[interface{}]int64:
  412. fastpathTV.EncMapIntfInt64V(v, e)
  413. case *map[interface{}]int64:
  414. fastpathTV.EncMapIntfInt64V(*v, e)
  415. case map[interface{}]float32:
  416. fastpathTV.EncMapIntfFloat32V(v, e)
  417. case *map[interface{}]float32:
  418. fastpathTV.EncMapIntfFloat32V(*v, e)
  419. case map[interface{}]float64:
  420. fastpathTV.EncMapIntfFloat64V(v, e)
  421. case *map[interface{}]float64:
  422. fastpathTV.EncMapIntfFloat64V(*v, e)
  423. case map[interface{}]bool:
  424. fastpathTV.EncMapIntfBoolV(v, e)
  425. case *map[interface{}]bool:
  426. fastpathTV.EncMapIntfBoolV(*v, e)
  427. case []string:
  428. fastpathTV.EncSliceStringV(v, e)
  429. case *[]string:
  430. fastpathTV.EncSliceStringV(*v, e)
  431. case map[string]interface{}:
  432. fastpathTV.EncMapStringIntfV(v, e)
  433. case *map[string]interface{}:
  434. fastpathTV.EncMapStringIntfV(*v, e)
  435. case map[string]string:
  436. fastpathTV.EncMapStringStringV(v, e)
  437. case *map[string]string:
  438. fastpathTV.EncMapStringStringV(*v, e)
  439. case map[string]uint:
  440. fastpathTV.EncMapStringUintV(v, e)
  441. case *map[string]uint:
  442. fastpathTV.EncMapStringUintV(*v, e)
  443. case map[string]uint8:
  444. fastpathTV.EncMapStringUint8V(v, e)
  445. case *map[string]uint8:
  446. fastpathTV.EncMapStringUint8V(*v, e)
  447. case map[string]uint16:
  448. fastpathTV.EncMapStringUint16V(v, e)
  449. case *map[string]uint16:
  450. fastpathTV.EncMapStringUint16V(*v, e)
  451. case map[string]uint32:
  452. fastpathTV.EncMapStringUint32V(v, e)
  453. case *map[string]uint32:
  454. fastpathTV.EncMapStringUint32V(*v, e)
  455. case map[string]uint64:
  456. fastpathTV.EncMapStringUint64V(v, e)
  457. case *map[string]uint64:
  458. fastpathTV.EncMapStringUint64V(*v, e)
  459. case map[string]uintptr:
  460. fastpathTV.EncMapStringUintptrV(v, e)
  461. case *map[string]uintptr:
  462. fastpathTV.EncMapStringUintptrV(*v, e)
  463. case map[string]int:
  464. fastpathTV.EncMapStringIntV(v, e)
  465. case *map[string]int:
  466. fastpathTV.EncMapStringIntV(*v, e)
  467. case map[string]int8:
  468. fastpathTV.EncMapStringInt8V(v, e)
  469. case *map[string]int8:
  470. fastpathTV.EncMapStringInt8V(*v, e)
  471. case map[string]int16:
  472. fastpathTV.EncMapStringInt16V(v, e)
  473. case *map[string]int16:
  474. fastpathTV.EncMapStringInt16V(*v, e)
  475. case map[string]int32:
  476. fastpathTV.EncMapStringInt32V(v, e)
  477. case *map[string]int32:
  478. fastpathTV.EncMapStringInt32V(*v, e)
  479. case map[string]int64:
  480. fastpathTV.EncMapStringInt64V(v, e)
  481. case *map[string]int64:
  482. fastpathTV.EncMapStringInt64V(*v, e)
  483. case map[string]float32:
  484. fastpathTV.EncMapStringFloat32V(v, e)
  485. case *map[string]float32:
  486. fastpathTV.EncMapStringFloat32V(*v, e)
  487. case map[string]float64:
  488. fastpathTV.EncMapStringFloat64V(v, e)
  489. case *map[string]float64:
  490. fastpathTV.EncMapStringFloat64V(*v, e)
  491. case map[string]bool:
  492. fastpathTV.EncMapStringBoolV(v, e)
  493. case *map[string]bool:
  494. fastpathTV.EncMapStringBoolV(*v, e)
  495. case []float32:
  496. fastpathTV.EncSliceFloat32V(v, e)
  497. case *[]float32:
  498. fastpathTV.EncSliceFloat32V(*v, e)
  499. case map[float32]interface{}:
  500. fastpathTV.EncMapFloat32IntfV(v, e)
  501. case *map[float32]interface{}:
  502. fastpathTV.EncMapFloat32IntfV(*v, e)
  503. case map[float32]string:
  504. fastpathTV.EncMapFloat32StringV(v, e)
  505. case *map[float32]string:
  506. fastpathTV.EncMapFloat32StringV(*v, e)
  507. case map[float32]uint:
  508. fastpathTV.EncMapFloat32UintV(v, e)
  509. case *map[float32]uint:
  510. fastpathTV.EncMapFloat32UintV(*v, e)
  511. case map[float32]uint8:
  512. fastpathTV.EncMapFloat32Uint8V(v, e)
  513. case *map[float32]uint8:
  514. fastpathTV.EncMapFloat32Uint8V(*v, e)
  515. case map[float32]uint16:
  516. fastpathTV.EncMapFloat32Uint16V(v, e)
  517. case *map[float32]uint16:
  518. fastpathTV.EncMapFloat32Uint16V(*v, e)
  519. case map[float32]uint32:
  520. fastpathTV.EncMapFloat32Uint32V(v, e)
  521. case *map[float32]uint32:
  522. fastpathTV.EncMapFloat32Uint32V(*v, e)
  523. case map[float32]uint64:
  524. fastpathTV.EncMapFloat32Uint64V(v, e)
  525. case *map[float32]uint64:
  526. fastpathTV.EncMapFloat32Uint64V(*v, e)
  527. case map[float32]uintptr:
  528. fastpathTV.EncMapFloat32UintptrV(v, e)
  529. case *map[float32]uintptr:
  530. fastpathTV.EncMapFloat32UintptrV(*v, e)
  531. case map[float32]int:
  532. fastpathTV.EncMapFloat32IntV(v, e)
  533. case *map[float32]int:
  534. fastpathTV.EncMapFloat32IntV(*v, e)
  535. case map[float32]int8:
  536. fastpathTV.EncMapFloat32Int8V(v, e)
  537. case *map[float32]int8:
  538. fastpathTV.EncMapFloat32Int8V(*v, e)
  539. case map[float32]int16:
  540. fastpathTV.EncMapFloat32Int16V(v, e)
  541. case *map[float32]int16:
  542. fastpathTV.EncMapFloat32Int16V(*v, e)
  543. case map[float32]int32:
  544. fastpathTV.EncMapFloat32Int32V(v, e)
  545. case *map[float32]int32:
  546. fastpathTV.EncMapFloat32Int32V(*v, e)
  547. case map[float32]int64:
  548. fastpathTV.EncMapFloat32Int64V(v, e)
  549. case *map[float32]int64:
  550. fastpathTV.EncMapFloat32Int64V(*v, e)
  551. case map[float32]float32:
  552. fastpathTV.EncMapFloat32Float32V(v, e)
  553. case *map[float32]float32:
  554. fastpathTV.EncMapFloat32Float32V(*v, e)
  555. case map[float32]float64:
  556. fastpathTV.EncMapFloat32Float64V(v, e)
  557. case *map[float32]float64:
  558. fastpathTV.EncMapFloat32Float64V(*v, e)
  559. case map[float32]bool:
  560. fastpathTV.EncMapFloat32BoolV(v, e)
  561. case *map[float32]bool:
  562. fastpathTV.EncMapFloat32BoolV(*v, e)
  563. case []float64:
  564. fastpathTV.EncSliceFloat64V(v, e)
  565. case *[]float64:
  566. fastpathTV.EncSliceFloat64V(*v, e)
  567. case map[float64]interface{}:
  568. fastpathTV.EncMapFloat64IntfV(v, e)
  569. case *map[float64]interface{}:
  570. fastpathTV.EncMapFloat64IntfV(*v, e)
  571. case map[float64]string:
  572. fastpathTV.EncMapFloat64StringV(v, e)
  573. case *map[float64]string:
  574. fastpathTV.EncMapFloat64StringV(*v, e)
  575. case map[float64]uint:
  576. fastpathTV.EncMapFloat64UintV(v, e)
  577. case *map[float64]uint:
  578. fastpathTV.EncMapFloat64UintV(*v, e)
  579. case map[float64]uint8:
  580. fastpathTV.EncMapFloat64Uint8V(v, e)
  581. case *map[float64]uint8:
  582. fastpathTV.EncMapFloat64Uint8V(*v, e)
  583. case map[float64]uint16:
  584. fastpathTV.EncMapFloat64Uint16V(v, e)
  585. case *map[float64]uint16:
  586. fastpathTV.EncMapFloat64Uint16V(*v, e)
  587. case map[float64]uint32:
  588. fastpathTV.EncMapFloat64Uint32V(v, e)
  589. case *map[float64]uint32:
  590. fastpathTV.EncMapFloat64Uint32V(*v, e)
  591. case map[float64]uint64:
  592. fastpathTV.EncMapFloat64Uint64V(v, e)
  593. case *map[float64]uint64:
  594. fastpathTV.EncMapFloat64Uint64V(*v, e)
  595. case map[float64]uintptr:
  596. fastpathTV.EncMapFloat64UintptrV(v, e)
  597. case *map[float64]uintptr:
  598. fastpathTV.EncMapFloat64UintptrV(*v, e)
  599. case map[float64]int:
  600. fastpathTV.EncMapFloat64IntV(v, e)
  601. case *map[float64]int:
  602. fastpathTV.EncMapFloat64IntV(*v, e)
  603. case map[float64]int8:
  604. fastpathTV.EncMapFloat64Int8V(v, e)
  605. case *map[float64]int8:
  606. fastpathTV.EncMapFloat64Int8V(*v, e)
  607. case map[float64]int16:
  608. fastpathTV.EncMapFloat64Int16V(v, e)
  609. case *map[float64]int16:
  610. fastpathTV.EncMapFloat64Int16V(*v, e)
  611. case map[float64]int32:
  612. fastpathTV.EncMapFloat64Int32V(v, e)
  613. case *map[float64]int32:
  614. fastpathTV.EncMapFloat64Int32V(*v, e)
  615. case map[float64]int64:
  616. fastpathTV.EncMapFloat64Int64V(v, e)
  617. case *map[float64]int64:
  618. fastpathTV.EncMapFloat64Int64V(*v, e)
  619. case map[float64]float32:
  620. fastpathTV.EncMapFloat64Float32V(v, e)
  621. case *map[float64]float32:
  622. fastpathTV.EncMapFloat64Float32V(*v, e)
  623. case map[float64]float64:
  624. fastpathTV.EncMapFloat64Float64V(v, e)
  625. case *map[float64]float64:
  626. fastpathTV.EncMapFloat64Float64V(*v, e)
  627. case map[float64]bool:
  628. fastpathTV.EncMapFloat64BoolV(v, e)
  629. case *map[float64]bool:
  630. fastpathTV.EncMapFloat64BoolV(*v, e)
  631. case []uint:
  632. fastpathTV.EncSliceUintV(v, e)
  633. case *[]uint:
  634. fastpathTV.EncSliceUintV(*v, e)
  635. case map[uint]interface{}:
  636. fastpathTV.EncMapUintIntfV(v, e)
  637. case *map[uint]interface{}:
  638. fastpathTV.EncMapUintIntfV(*v, e)
  639. case map[uint]string:
  640. fastpathTV.EncMapUintStringV(v, e)
  641. case *map[uint]string:
  642. fastpathTV.EncMapUintStringV(*v, e)
  643. case map[uint]uint:
  644. fastpathTV.EncMapUintUintV(v, e)
  645. case *map[uint]uint:
  646. fastpathTV.EncMapUintUintV(*v, e)
  647. case map[uint]uint8:
  648. fastpathTV.EncMapUintUint8V(v, e)
  649. case *map[uint]uint8:
  650. fastpathTV.EncMapUintUint8V(*v, e)
  651. case map[uint]uint16:
  652. fastpathTV.EncMapUintUint16V(v, e)
  653. case *map[uint]uint16:
  654. fastpathTV.EncMapUintUint16V(*v, e)
  655. case map[uint]uint32:
  656. fastpathTV.EncMapUintUint32V(v, e)
  657. case *map[uint]uint32:
  658. fastpathTV.EncMapUintUint32V(*v, e)
  659. case map[uint]uint64:
  660. fastpathTV.EncMapUintUint64V(v, e)
  661. case *map[uint]uint64:
  662. fastpathTV.EncMapUintUint64V(*v, e)
  663. case map[uint]uintptr:
  664. fastpathTV.EncMapUintUintptrV(v, e)
  665. case *map[uint]uintptr:
  666. fastpathTV.EncMapUintUintptrV(*v, e)
  667. case map[uint]int:
  668. fastpathTV.EncMapUintIntV(v, e)
  669. case *map[uint]int:
  670. fastpathTV.EncMapUintIntV(*v, e)
  671. case map[uint]int8:
  672. fastpathTV.EncMapUintInt8V(v, e)
  673. case *map[uint]int8:
  674. fastpathTV.EncMapUintInt8V(*v, e)
  675. case map[uint]int16:
  676. fastpathTV.EncMapUintInt16V(v, e)
  677. case *map[uint]int16:
  678. fastpathTV.EncMapUintInt16V(*v, e)
  679. case map[uint]int32:
  680. fastpathTV.EncMapUintInt32V(v, e)
  681. case *map[uint]int32:
  682. fastpathTV.EncMapUintInt32V(*v, e)
  683. case map[uint]int64:
  684. fastpathTV.EncMapUintInt64V(v, e)
  685. case *map[uint]int64:
  686. fastpathTV.EncMapUintInt64V(*v, e)
  687. case map[uint]float32:
  688. fastpathTV.EncMapUintFloat32V(v, e)
  689. case *map[uint]float32:
  690. fastpathTV.EncMapUintFloat32V(*v, e)
  691. case map[uint]float64:
  692. fastpathTV.EncMapUintFloat64V(v, e)
  693. case *map[uint]float64:
  694. fastpathTV.EncMapUintFloat64V(*v, e)
  695. case map[uint]bool:
  696. fastpathTV.EncMapUintBoolV(v, e)
  697. case *map[uint]bool:
  698. fastpathTV.EncMapUintBoolV(*v, e)
  699. case map[uint8]interface{}:
  700. fastpathTV.EncMapUint8IntfV(v, e)
  701. case *map[uint8]interface{}:
  702. fastpathTV.EncMapUint8IntfV(*v, e)
  703. case map[uint8]string:
  704. fastpathTV.EncMapUint8StringV(v, e)
  705. case *map[uint8]string:
  706. fastpathTV.EncMapUint8StringV(*v, e)
  707. case map[uint8]uint:
  708. fastpathTV.EncMapUint8UintV(v, e)
  709. case *map[uint8]uint:
  710. fastpathTV.EncMapUint8UintV(*v, e)
  711. case map[uint8]uint8:
  712. fastpathTV.EncMapUint8Uint8V(v, e)
  713. case *map[uint8]uint8:
  714. fastpathTV.EncMapUint8Uint8V(*v, e)
  715. case map[uint8]uint16:
  716. fastpathTV.EncMapUint8Uint16V(v, e)
  717. case *map[uint8]uint16:
  718. fastpathTV.EncMapUint8Uint16V(*v, e)
  719. case map[uint8]uint32:
  720. fastpathTV.EncMapUint8Uint32V(v, e)
  721. case *map[uint8]uint32:
  722. fastpathTV.EncMapUint8Uint32V(*v, e)
  723. case map[uint8]uint64:
  724. fastpathTV.EncMapUint8Uint64V(v, e)
  725. case *map[uint8]uint64:
  726. fastpathTV.EncMapUint8Uint64V(*v, e)
  727. case map[uint8]uintptr:
  728. fastpathTV.EncMapUint8UintptrV(v, e)
  729. case *map[uint8]uintptr:
  730. fastpathTV.EncMapUint8UintptrV(*v, e)
  731. case map[uint8]int:
  732. fastpathTV.EncMapUint8IntV(v, e)
  733. case *map[uint8]int:
  734. fastpathTV.EncMapUint8IntV(*v, e)
  735. case map[uint8]int8:
  736. fastpathTV.EncMapUint8Int8V(v, e)
  737. case *map[uint8]int8:
  738. fastpathTV.EncMapUint8Int8V(*v, e)
  739. case map[uint8]int16:
  740. fastpathTV.EncMapUint8Int16V(v, e)
  741. case *map[uint8]int16:
  742. fastpathTV.EncMapUint8Int16V(*v, e)
  743. case map[uint8]int32:
  744. fastpathTV.EncMapUint8Int32V(v, e)
  745. case *map[uint8]int32:
  746. fastpathTV.EncMapUint8Int32V(*v, e)
  747. case map[uint8]int64:
  748. fastpathTV.EncMapUint8Int64V(v, e)
  749. case *map[uint8]int64:
  750. fastpathTV.EncMapUint8Int64V(*v, e)
  751. case map[uint8]float32:
  752. fastpathTV.EncMapUint8Float32V(v, e)
  753. case *map[uint8]float32:
  754. fastpathTV.EncMapUint8Float32V(*v, e)
  755. case map[uint8]float64:
  756. fastpathTV.EncMapUint8Float64V(v, e)
  757. case *map[uint8]float64:
  758. fastpathTV.EncMapUint8Float64V(*v, e)
  759. case map[uint8]bool:
  760. fastpathTV.EncMapUint8BoolV(v, e)
  761. case *map[uint8]bool:
  762. fastpathTV.EncMapUint8BoolV(*v, e)
  763. case []uint16:
  764. fastpathTV.EncSliceUint16V(v, e)
  765. case *[]uint16:
  766. fastpathTV.EncSliceUint16V(*v, e)
  767. case map[uint16]interface{}:
  768. fastpathTV.EncMapUint16IntfV(v, e)
  769. case *map[uint16]interface{}:
  770. fastpathTV.EncMapUint16IntfV(*v, e)
  771. case map[uint16]string:
  772. fastpathTV.EncMapUint16StringV(v, e)
  773. case *map[uint16]string:
  774. fastpathTV.EncMapUint16StringV(*v, e)
  775. case map[uint16]uint:
  776. fastpathTV.EncMapUint16UintV(v, e)
  777. case *map[uint16]uint:
  778. fastpathTV.EncMapUint16UintV(*v, e)
  779. case map[uint16]uint8:
  780. fastpathTV.EncMapUint16Uint8V(v, e)
  781. case *map[uint16]uint8:
  782. fastpathTV.EncMapUint16Uint8V(*v, e)
  783. case map[uint16]uint16:
  784. fastpathTV.EncMapUint16Uint16V(v, e)
  785. case *map[uint16]uint16:
  786. fastpathTV.EncMapUint16Uint16V(*v, e)
  787. case map[uint16]uint32:
  788. fastpathTV.EncMapUint16Uint32V(v, e)
  789. case *map[uint16]uint32:
  790. fastpathTV.EncMapUint16Uint32V(*v, e)
  791. case map[uint16]uint64:
  792. fastpathTV.EncMapUint16Uint64V(v, e)
  793. case *map[uint16]uint64:
  794. fastpathTV.EncMapUint16Uint64V(*v, e)
  795. case map[uint16]uintptr:
  796. fastpathTV.EncMapUint16UintptrV(v, e)
  797. case *map[uint16]uintptr:
  798. fastpathTV.EncMapUint16UintptrV(*v, e)
  799. case map[uint16]int:
  800. fastpathTV.EncMapUint16IntV(v, e)
  801. case *map[uint16]int:
  802. fastpathTV.EncMapUint16IntV(*v, e)
  803. case map[uint16]int8:
  804. fastpathTV.EncMapUint16Int8V(v, e)
  805. case *map[uint16]int8:
  806. fastpathTV.EncMapUint16Int8V(*v, e)
  807. case map[uint16]int16:
  808. fastpathTV.EncMapUint16Int16V(v, e)
  809. case *map[uint16]int16:
  810. fastpathTV.EncMapUint16Int16V(*v, e)
  811. case map[uint16]int32:
  812. fastpathTV.EncMapUint16Int32V(v, e)
  813. case *map[uint16]int32:
  814. fastpathTV.EncMapUint16Int32V(*v, e)
  815. case map[uint16]int64:
  816. fastpathTV.EncMapUint16Int64V(v, e)
  817. case *map[uint16]int64:
  818. fastpathTV.EncMapUint16Int64V(*v, e)
  819. case map[uint16]float32:
  820. fastpathTV.EncMapUint16Float32V(v, e)
  821. case *map[uint16]float32:
  822. fastpathTV.EncMapUint16Float32V(*v, e)
  823. case map[uint16]float64:
  824. fastpathTV.EncMapUint16Float64V(v, e)
  825. case *map[uint16]float64:
  826. fastpathTV.EncMapUint16Float64V(*v, e)
  827. case map[uint16]bool:
  828. fastpathTV.EncMapUint16BoolV(v, e)
  829. case *map[uint16]bool:
  830. fastpathTV.EncMapUint16BoolV(*v, e)
  831. case []uint32:
  832. fastpathTV.EncSliceUint32V(v, e)
  833. case *[]uint32:
  834. fastpathTV.EncSliceUint32V(*v, e)
  835. case map[uint32]interface{}:
  836. fastpathTV.EncMapUint32IntfV(v, e)
  837. case *map[uint32]interface{}:
  838. fastpathTV.EncMapUint32IntfV(*v, e)
  839. case map[uint32]string:
  840. fastpathTV.EncMapUint32StringV(v, e)
  841. case *map[uint32]string:
  842. fastpathTV.EncMapUint32StringV(*v, e)
  843. case map[uint32]uint:
  844. fastpathTV.EncMapUint32UintV(v, e)
  845. case *map[uint32]uint:
  846. fastpathTV.EncMapUint32UintV(*v, e)
  847. case map[uint32]uint8:
  848. fastpathTV.EncMapUint32Uint8V(v, e)
  849. case *map[uint32]uint8:
  850. fastpathTV.EncMapUint32Uint8V(*v, e)
  851. case map[uint32]uint16:
  852. fastpathTV.EncMapUint32Uint16V(v, e)
  853. case *map[uint32]uint16:
  854. fastpathTV.EncMapUint32Uint16V(*v, e)
  855. case map[uint32]uint32:
  856. fastpathTV.EncMapUint32Uint32V(v, e)
  857. case *map[uint32]uint32:
  858. fastpathTV.EncMapUint32Uint32V(*v, e)
  859. case map[uint32]uint64:
  860. fastpathTV.EncMapUint32Uint64V(v, e)
  861. case *map[uint32]uint64:
  862. fastpathTV.EncMapUint32Uint64V(*v, e)
  863. case map[uint32]uintptr:
  864. fastpathTV.EncMapUint32UintptrV(v, e)
  865. case *map[uint32]uintptr:
  866. fastpathTV.EncMapUint32UintptrV(*v, e)
  867. case map[uint32]int:
  868. fastpathTV.EncMapUint32IntV(v, e)
  869. case *map[uint32]int:
  870. fastpathTV.EncMapUint32IntV(*v, e)
  871. case map[uint32]int8:
  872. fastpathTV.EncMapUint32Int8V(v, e)
  873. case *map[uint32]int8:
  874. fastpathTV.EncMapUint32Int8V(*v, e)
  875. case map[uint32]int16:
  876. fastpathTV.EncMapUint32Int16V(v, e)
  877. case *map[uint32]int16:
  878. fastpathTV.EncMapUint32Int16V(*v, e)
  879. case map[uint32]int32:
  880. fastpathTV.EncMapUint32Int32V(v, e)
  881. case *map[uint32]int32:
  882. fastpathTV.EncMapUint32Int32V(*v, e)
  883. case map[uint32]int64:
  884. fastpathTV.EncMapUint32Int64V(v, e)
  885. case *map[uint32]int64:
  886. fastpathTV.EncMapUint32Int64V(*v, e)
  887. case map[uint32]float32:
  888. fastpathTV.EncMapUint32Float32V(v, e)
  889. case *map[uint32]float32:
  890. fastpathTV.EncMapUint32Float32V(*v, e)
  891. case map[uint32]float64:
  892. fastpathTV.EncMapUint32Float64V(v, e)
  893. case *map[uint32]float64:
  894. fastpathTV.EncMapUint32Float64V(*v, e)
  895. case map[uint32]bool:
  896. fastpathTV.EncMapUint32BoolV(v, e)
  897. case *map[uint32]bool:
  898. fastpathTV.EncMapUint32BoolV(*v, e)
  899. case []uint64:
  900. fastpathTV.EncSliceUint64V(v, e)
  901. case *[]uint64:
  902. fastpathTV.EncSliceUint64V(*v, e)
  903. case map[uint64]interface{}:
  904. fastpathTV.EncMapUint64IntfV(v, e)
  905. case *map[uint64]interface{}:
  906. fastpathTV.EncMapUint64IntfV(*v, e)
  907. case map[uint64]string:
  908. fastpathTV.EncMapUint64StringV(v, e)
  909. case *map[uint64]string:
  910. fastpathTV.EncMapUint64StringV(*v, e)
  911. case map[uint64]uint:
  912. fastpathTV.EncMapUint64UintV(v, e)
  913. case *map[uint64]uint:
  914. fastpathTV.EncMapUint64UintV(*v, e)
  915. case map[uint64]uint8:
  916. fastpathTV.EncMapUint64Uint8V(v, e)
  917. case *map[uint64]uint8:
  918. fastpathTV.EncMapUint64Uint8V(*v, e)
  919. case map[uint64]uint16:
  920. fastpathTV.EncMapUint64Uint16V(v, e)
  921. case *map[uint64]uint16:
  922. fastpathTV.EncMapUint64Uint16V(*v, e)
  923. case map[uint64]uint32:
  924. fastpathTV.EncMapUint64Uint32V(v, e)
  925. case *map[uint64]uint32:
  926. fastpathTV.EncMapUint64Uint32V(*v, e)
  927. case map[uint64]uint64:
  928. fastpathTV.EncMapUint64Uint64V(v, e)
  929. case *map[uint64]uint64:
  930. fastpathTV.EncMapUint64Uint64V(*v, e)
  931. case map[uint64]uintptr:
  932. fastpathTV.EncMapUint64UintptrV(v, e)
  933. case *map[uint64]uintptr:
  934. fastpathTV.EncMapUint64UintptrV(*v, e)
  935. case map[uint64]int:
  936. fastpathTV.EncMapUint64IntV(v, e)
  937. case *map[uint64]int:
  938. fastpathTV.EncMapUint64IntV(*v, e)
  939. case map[uint64]int8:
  940. fastpathTV.EncMapUint64Int8V(v, e)
  941. case *map[uint64]int8:
  942. fastpathTV.EncMapUint64Int8V(*v, e)
  943. case map[uint64]int16:
  944. fastpathTV.EncMapUint64Int16V(v, e)
  945. case *map[uint64]int16:
  946. fastpathTV.EncMapUint64Int16V(*v, e)
  947. case map[uint64]int32:
  948. fastpathTV.EncMapUint64Int32V(v, e)
  949. case *map[uint64]int32:
  950. fastpathTV.EncMapUint64Int32V(*v, e)
  951. case map[uint64]int64:
  952. fastpathTV.EncMapUint64Int64V(v, e)
  953. case *map[uint64]int64:
  954. fastpathTV.EncMapUint64Int64V(*v, e)
  955. case map[uint64]float32:
  956. fastpathTV.EncMapUint64Float32V(v, e)
  957. case *map[uint64]float32:
  958. fastpathTV.EncMapUint64Float32V(*v, e)
  959. case map[uint64]float64:
  960. fastpathTV.EncMapUint64Float64V(v, e)
  961. case *map[uint64]float64:
  962. fastpathTV.EncMapUint64Float64V(*v, e)
  963. case map[uint64]bool:
  964. fastpathTV.EncMapUint64BoolV(v, e)
  965. case *map[uint64]bool:
  966. fastpathTV.EncMapUint64BoolV(*v, e)
  967. case []uintptr:
  968. fastpathTV.EncSliceUintptrV(v, e)
  969. case *[]uintptr:
  970. fastpathTV.EncSliceUintptrV(*v, e)
  971. case map[uintptr]interface{}:
  972. fastpathTV.EncMapUintptrIntfV(v, e)
  973. case *map[uintptr]interface{}:
  974. fastpathTV.EncMapUintptrIntfV(*v, e)
  975. case map[uintptr]string:
  976. fastpathTV.EncMapUintptrStringV(v, e)
  977. case *map[uintptr]string:
  978. fastpathTV.EncMapUintptrStringV(*v, e)
  979. case map[uintptr]uint:
  980. fastpathTV.EncMapUintptrUintV(v, e)
  981. case *map[uintptr]uint:
  982. fastpathTV.EncMapUintptrUintV(*v, e)
  983. case map[uintptr]uint8:
  984. fastpathTV.EncMapUintptrUint8V(v, e)
  985. case *map[uintptr]uint8:
  986. fastpathTV.EncMapUintptrUint8V(*v, e)
  987. case map[uintptr]uint16:
  988. fastpathTV.EncMapUintptrUint16V(v, e)
  989. case *map[uintptr]uint16:
  990. fastpathTV.EncMapUintptrUint16V(*v, e)
  991. case map[uintptr]uint32:
  992. fastpathTV.EncMapUintptrUint32V(v, e)
  993. case *map[uintptr]uint32:
  994. fastpathTV.EncMapUintptrUint32V(*v, e)
  995. case map[uintptr]uint64:
  996. fastpathTV.EncMapUintptrUint64V(v, e)
  997. case *map[uintptr]uint64:
  998. fastpathTV.EncMapUintptrUint64V(*v, e)
  999. case map[uintptr]uintptr:
  1000. fastpathTV.EncMapUintptrUintptrV(v, e)
  1001. case *map[uintptr]uintptr:
  1002. fastpathTV.EncMapUintptrUintptrV(*v, e)
  1003. case map[uintptr]int:
  1004. fastpathTV.EncMapUintptrIntV(v, e)
  1005. case *map[uintptr]int:
  1006. fastpathTV.EncMapUintptrIntV(*v, e)
  1007. case map[uintptr]int8:
  1008. fastpathTV.EncMapUintptrInt8V(v, e)
  1009. case *map[uintptr]int8:
  1010. fastpathTV.EncMapUintptrInt8V(*v, e)
  1011. case map[uintptr]int16:
  1012. fastpathTV.EncMapUintptrInt16V(v, e)
  1013. case *map[uintptr]int16:
  1014. fastpathTV.EncMapUintptrInt16V(*v, e)
  1015. case map[uintptr]int32:
  1016. fastpathTV.EncMapUintptrInt32V(v, e)
  1017. case *map[uintptr]int32:
  1018. fastpathTV.EncMapUintptrInt32V(*v, e)
  1019. case map[uintptr]int64:
  1020. fastpathTV.EncMapUintptrInt64V(v, e)
  1021. case *map[uintptr]int64:
  1022. fastpathTV.EncMapUintptrInt64V(*v, e)
  1023. case map[uintptr]float32:
  1024. fastpathTV.EncMapUintptrFloat32V(v, e)
  1025. case *map[uintptr]float32:
  1026. fastpathTV.EncMapUintptrFloat32V(*v, e)
  1027. case map[uintptr]float64:
  1028. fastpathTV.EncMapUintptrFloat64V(v, e)
  1029. case *map[uintptr]float64:
  1030. fastpathTV.EncMapUintptrFloat64V(*v, e)
  1031. case map[uintptr]bool:
  1032. fastpathTV.EncMapUintptrBoolV(v, e)
  1033. case *map[uintptr]bool:
  1034. fastpathTV.EncMapUintptrBoolV(*v, e)
  1035. case []int:
  1036. fastpathTV.EncSliceIntV(v, e)
  1037. case *[]int:
  1038. fastpathTV.EncSliceIntV(*v, e)
  1039. case map[int]interface{}:
  1040. fastpathTV.EncMapIntIntfV(v, e)
  1041. case *map[int]interface{}:
  1042. fastpathTV.EncMapIntIntfV(*v, e)
  1043. case map[int]string:
  1044. fastpathTV.EncMapIntStringV(v, e)
  1045. case *map[int]string:
  1046. fastpathTV.EncMapIntStringV(*v, e)
  1047. case map[int]uint:
  1048. fastpathTV.EncMapIntUintV(v, e)
  1049. case *map[int]uint:
  1050. fastpathTV.EncMapIntUintV(*v, e)
  1051. case map[int]uint8:
  1052. fastpathTV.EncMapIntUint8V(v, e)
  1053. case *map[int]uint8:
  1054. fastpathTV.EncMapIntUint8V(*v, e)
  1055. case map[int]uint16:
  1056. fastpathTV.EncMapIntUint16V(v, e)
  1057. case *map[int]uint16:
  1058. fastpathTV.EncMapIntUint16V(*v, e)
  1059. case map[int]uint32:
  1060. fastpathTV.EncMapIntUint32V(v, e)
  1061. case *map[int]uint32:
  1062. fastpathTV.EncMapIntUint32V(*v, e)
  1063. case map[int]uint64:
  1064. fastpathTV.EncMapIntUint64V(v, e)
  1065. case *map[int]uint64:
  1066. fastpathTV.EncMapIntUint64V(*v, e)
  1067. case map[int]uintptr:
  1068. fastpathTV.EncMapIntUintptrV(v, e)
  1069. case *map[int]uintptr:
  1070. fastpathTV.EncMapIntUintptrV(*v, e)
  1071. case map[int]int:
  1072. fastpathTV.EncMapIntIntV(v, e)
  1073. case *map[int]int:
  1074. fastpathTV.EncMapIntIntV(*v, e)
  1075. case map[int]int8:
  1076. fastpathTV.EncMapIntInt8V(v, e)
  1077. case *map[int]int8:
  1078. fastpathTV.EncMapIntInt8V(*v, e)
  1079. case map[int]int16:
  1080. fastpathTV.EncMapIntInt16V(v, e)
  1081. case *map[int]int16:
  1082. fastpathTV.EncMapIntInt16V(*v, e)
  1083. case map[int]int32:
  1084. fastpathTV.EncMapIntInt32V(v, e)
  1085. case *map[int]int32:
  1086. fastpathTV.EncMapIntInt32V(*v, e)
  1087. case map[int]int64:
  1088. fastpathTV.EncMapIntInt64V(v, e)
  1089. case *map[int]int64:
  1090. fastpathTV.EncMapIntInt64V(*v, e)
  1091. case map[int]float32:
  1092. fastpathTV.EncMapIntFloat32V(v, e)
  1093. case *map[int]float32:
  1094. fastpathTV.EncMapIntFloat32V(*v, e)
  1095. case map[int]float64:
  1096. fastpathTV.EncMapIntFloat64V(v, e)
  1097. case *map[int]float64:
  1098. fastpathTV.EncMapIntFloat64V(*v, e)
  1099. case map[int]bool:
  1100. fastpathTV.EncMapIntBoolV(v, e)
  1101. case *map[int]bool:
  1102. fastpathTV.EncMapIntBoolV(*v, e)
  1103. case []int8:
  1104. fastpathTV.EncSliceInt8V(v, e)
  1105. case *[]int8:
  1106. fastpathTV.EncSliceInt8V(*v, e)
  1107. case map[int8]interface{}:
  1108. fastpathTV.EncMapInt8IntfV(v, e)
  1109. case *map[int8]interface{}:
  1110. fastpathTV.EncMapInt8IntfV(*v, e)
  1111. case map[int8]string:
  1112. fastpathTV.EncMapInt8StringV(v, e)
  1113. case *map[int8]string:
  1114. fastpathTV.EncMapInt8StringV(*v, e)
  1115. case map[int8]uint:
  1116. fastpathTV.EncMapInt8UintV(v, e)
  1117. case *map[int8]uint:
  1118. fastpathTV.EncMapInt8UintV(*v, e)
  1119. case map[int8]uint8:
  1120. fastpathTV.EncMapInt8Uint8V(v, e)
  1121. case *map[int8]uint8:
  1122. fastpathTV.EncMapInt8Uint8V(*v, e)
  1123. case map[int8]uint16:
  1124. fastpathTV.EncMapInt8Uint16V(v, e)
  1125. case *map[int8]uint16:
  1126. fastpathTV.EncMapInt8Uint16V(*v, e)
  1127. case map[int8]uint32:
  1128. fastpathTV.EncMapInt8Uint32V(v, e)
  1129. case *map[int8]uint32:
  1130. fastpathTV.EncMapInt8Uint32V(*v, e)
  1131. case map[int8]uint64:
  1132. fastpathTV.EncMapInt8Uint64V(v, e)
  1133. case *map[int8]uint64:
  1134. fastpathTV.EncMapInt8Uint64V(*v, e)
  1135. case map[int8]uintptr:
  1136. fastpathTV.EncMapInt8UintptrV(v, e)
  1137. case *map[int8]uintptr:
  1138. fastpathTV.EncMapInt8UintptrV(*v, e)
  1139. case map[int8]int:
  1140. fastpathTV.EncMapInt8IntV(v, e)
  1141. case *map[int8]int:
  1142. fastpathTV.EncMapInt8IntV(*v, e)
  1143. case map[int8]int8:
  1144. fastpathTV.EncMapInt8Int8V(v, e)
  1145. case *map[int8]int8:
  1146. fastpathTV.EncMapInt8Int8V(*v, e)
  1147. case map[int8]int16:
  1148. fastpathTV.EncMapInt8Int16V(v, e)
  1149. case *map[int8]int16:
  1150. fastpathTV.EncMapInt8Int16V(*v, e)
  1151. case map[int8]int32:
  1152. fastpathTV.EncMapInt8Int32V(v, e)
  1153. case *map[int8]int32:
  1154. fastpathTV.EncMapInt8Int32V(*v, e)
  1155. case map[int8]int64:
  1156. fastpathTV.EncMapInt8Int64V(v, e)
  1157. case *map[int8]int64:
  1158. fastpathTV.EncMapInt8Int64V(*v, e)
  1159. case map[int8]float32:
  1160. fastpathTV.EncMapInt8Float32V(v, e)
  1161. case *map[int8]float32:
  1162. fastpathTV.EncMapInt8Float32V(*v, e)
  1163. case map[int8]float64:
  1164. fastpathTV.EncMapInt8Float64V(v, e)
  1165. case *map[int8]float64:
  1166. fastpathTV.EncMapInt8Float64V(*v, e)
  1167. case map[int8]bool:
  1168. fastpathTV.EncMapInt8BoolV(v, e)
  1169. case *map[int8]bool:
  1170. fastpathTV.EncMapInt8BoolV(*v, e)
  1171. case []int16:
  1172. fastpathTV.EncSliceInt16V(v, e)
  1173. case *[]int16:
  1174. fastpathTV.EncSliceInt16V(*v, e)
  1175. case map[int16]interface{}:
  1176. fastpathTV.EncMapInt16IntfV(v, e)
  1177. case *map[int16]interface{}:
  1178. fastpathTV.EncMapInt16IntfV(*v, e)
  1179. case map[int16]string:
  1180. fastpathTV.EncMapInt16StringV(v, e)
  1181. case *map[int16]string:
  1182. fastpathTV.EncMapInt16StringV(*v, e)
  1183. case map[int16]uint:
  1184. fastpathTV.EncMapInt16UintV(v, e)
  1185. case *map[int16]uint:
  1186. fastpathTV.EncMapInt16UintV(*v, e)
  1187. case map[int16]uint8:
  1188. fastpathTV.EncMapInt16Uint8V(v, e)
  1189. case *map[int16]uint8:
  1190. fastpathTV.EncMapInt16Uint8V(*v, e)
  1191. case map[int16]uint16:
  1192. fastpathTV.EncMapInt16Uint16V(v, e)
  1193. case *map[int16]uint16:
  1194. fastpathTV.EncMapInt16Uint16V(*v, e)
  1195. case map[int16]uint32:
  1196. fastpathTV.EncMapInt16Uint32V(v, e)
  1197. case *map[int16]uint32:
  1198. fastpathTV.EncMapInt16Uint32V(*v, e)
  1199. case map[int16]uint64:
  1200. fastpathTV.EncMapInt16Uint64V(v, e)
  1201. case *map[int16]uint64:
  1202. fastpathTV.EncMapInt16Uint64V(*v, e)
  1203. case map[int16]uintptr:
  1204. fastpathTV.EncMapInt16UintptrV(v, e)
  1205. case *map[int16]uintptr:
  1206. fastpathTV.EncMapInt16UintptrV(*v, e)
  1207. case map[int16]int:
  1208. fastpathTV.EncMapInt16IntV(v, e)
  1209. case *map[int16]int:
  1210. fastpathTV.EncMapInt16IntV(*v, e)
  1211. case map[int16]int8:
  1212. fastpathTV.EncMapInt16Int8V(v, e)
  1213. case *map[int16]int8:
  1214. fastpathTV.EncMapInt16Int8V(*v, e)
  1215. case map[int16]int16:
  1216. fastpathTV.EncMapInt16Int16V(v, e)
  1217. case *map[int16]int16:
  1218. fastpathTV.EncMapInt16Int16V(*v, e)
  1219. case map[int16]int32:
  1220. fastpathTV.EncMapInt16Int32V(v, e)
  1221. case *map[int16]int32:
  1222. fastpathTV.EncMapInt16Int32V(*v, e)
  1223. case map[int16]int64:
  1224. fastpathTV.EncMapInt16Int64V(v, e)
  1225. case *map[int16]int64:
  1226. fastpathTV.EncMapInt16Int64V(*v, e)
  1227. case map[int16]float32:
  1228. fastpathTV.EncMapInt16Float32V(v, e)
  1229. case *map[int16]float32:
  1230. fastpathTV.EncMapInt16Float32V(*v, e)
  1231. case map[int16]float64:
  1232. fastpathTV.EncMapInt16Float64V(v, e)
  1233. case *map[int16]float64:
  1234. fastpathTV.EncMapInt16Float64V(*v, e)
  1235. case map[int16]bool:
  1236. fastpathTV.EncMapInt16BoolV(v, e)
  1237. case *map[int16]bool:
  1238. fastpathTV.EncMapInt16BoolV(*v, e)
  1239. case []int32:
  1240. fastpathTV.EncSliceInt32V(v, e)
  1241. case *[]int32:
  1242. fastpathTV.EncSliceInt32V(*v, e)
  1243. case map[int32]interface{}:
  1244. fastpathTV.EncMapInt32IntfV(v, e)
  1245. case *map[int32]interface{}:
  1246. fastpathTV.EncMapInt32IntfV(*v, e)
  1247. case map[int32]string:
  1248. fastpathTV.EncMapInt32StringV(v, e)
  1249. case *map[int32]string:
  1250. fastpathTV.EncMapInt32StringV(*v, e)
  1251. case map[int32]uint:
  1252. fastpathTV.EncMapInt32UintV(v, e)
  1253. case *map[int32]uint:
  1254. fastpathTV.EncMapInt32UintV(*v, e)
  1255. case map[int32]uint8:
  1256. fastpathTV.EncMapInt32Uint8V(v, e)
  1257. case *map[int32]uint8:
  1258. fastpathTV.EncMapInt32Uint8V(*v, e)
  1259. case map[int32]uint16:
  1260. fastpathTV.EncMapInt32Uint16V(v, e)
  1261. case *map[int32]uint16:
  1262. fastpathTV.EncMapInt32Uint16V(*v, e)
  1263. case map[int32]uint32:
  1264. fastpathTV.EncMapInt32Uint32V(v, e)
  1265. case *map[int32]uint32:
  1266. fastpathTV.EncMapInt32Uint32V(*v, e)
  1267. case map[int32]uint64:
  1268. fastpathTV.EncMapInt32Uint64V(v, e)
  1269. case *map[int32]uint64:
  1270. fastpathTV.EncMapInt32Uint64V(*v, e)
  1271. case map[int32]uintptr:
  1272. fastpathTV.EncMapInt32UintptrV(v, e)
  1273. case *map[int32]uintptr:
  1274. fastpathTV.EncMapInt32UintptrV(*v, e)
  1275. case map[int32]int:
  1276. fastpathTV.EncMapInt32IntV(v, e)
  1277. case *map[int32]int:
  1278. fastpathTV.EncMapInt32IntV(*v, e)
  1279. case map[int32]int8:
  1280. fastpathTV.EncMapInt32Int8V(v, e)
  1281. case *map[int32]int8:
  1282. fastpathTV.EncMapInt32Int8V(*v, e)
  1283. case map[int32]int16:
  1284. fastpathTV.EncMapInt32Int16V(v, e)
  1285. case *map[int32]int16:
  1286. fastpathTV.EncMapInt32Int16V(*v, e)
  1287. case map[int32]int32:
  1288. fastpathTV.EncMapInt32Int32V(v, e)
  1289. case *map[int32]int32:
  1290. fastpathTV.EncMapInt32Int32V(*v, e)
  1291. case map[int32]int64:
  1292. fastpathTV.EncMapInt32Int64V(v, e)
  1293. case *map[int32]int64:
  1294. fastpathTV.EncMapInt32Int64V(*v, e)
  1295. case map[int32]float32:
  1296. fastpathTV.EncMapInt32Float32V(v, e)
  1297. case *map[int32]float32:
  1298. fastpathTV.EncMapInt32Float32V(*v, e)
  1299. case map[int32]float64:
  1300. fastpathTV.EncMapInt32Float64V(v, e)
  1301. case *map[int32]float64:
  1302. fastpathTV.EncMapInt32Float64V(*v, e)
  1303. case map[int32]bool:
  1304. fastpathTV.EncMapInt32BoolV(v, e)
  1305. case *map[int32]bool:
  1306. fastpathTV.EncMapInt32BoolV(*v, e)
  1307. case []int64:
  1308. fastpathTV.EncSliceInt64V(v, e)
  1309. case *[]int64:
  1310. fastpathTV.EncSliceInt64V(*v, e)
  1311. case map[int64]interface{}:
  1312. fastpathTV.EncMapInt64IntfV(v, e)
  1313. case *map[int64]interface{}:
  1314. fastpathTV.EncMapInt64IntfV(*v, e)
  1315. case map[int64]string:
  1316. fastpathTV.EncMapInt64StringV(v, e)
  1317. case *map[int64]string:
  1318. fastpathTV.EncMapInt64StringV(*v, e)
  1319. case map[int64]uint:
  1320. fastpathTV.EncMapInt64UintV(v, e)
  1321. case *map[int64]uint:
  1322. fastpathTV.EncMapInt64UintV(*v, e)
  1323. case map[int64]uint8:
  1324. fastpathTV.EncMapInt64Uint8V(v, e)
  1325. case *map[int64]uint8:
  1326. fastpathTV.EncMapInt64Uint8V(*v, e)
  1327. case map[int64]uint16:
  1328. fastpathTV.EncMapInt64Uint16V(v, e)
  1329. case *map[int64]uint16:
  1330. fastpathTV.EncMapInt64Uint16V(*v, e)
  1331. case map[int64]uint32:
  1332. fastpathTV.EncMapInt64Uint32V(v, e)
  1333. case *map[int64]uint32:
  1334. fastpathTV.EncMapInt64Uint32V(*v, e)
  1335. case map[int64]uint64:
  1336. fastpathTV.EncMapInt64Uint64V(v, e)
  1337. case *map[int64]uint64:
  1338. fastpathTV.EncMapInt64Uint64V(*v, e)
  1339. case map[int64]uintptr:
  1340. fastpathTV.EncMapInt64UintptrV(v, e)
  1341. case *map[int64]uintptr:
  1342. fastpathTV.EncMapInt64UintptrV(*v, e)
  1343. case map[int64]int:
  1344. fastpathTV.EncMapInt64IntV(v, e)
  1345. case *map[int64]int:
  1346. fastpathTV.EncMapInt64IntV(*v, e)
  1347. case map[int64]int8:
  1348. fastpathTV.EncMapInt64Int8V(v, e)
  1349. case *map[int64]int8:
  1350. fastpathTV.EncMapInt64Int8V(*v, e)
  1351. case map[int64]int16:
  1352. fastpathTV.EncMapInt64Int16V(v, e)
  1353. case *map[int64]int16:
  1354. fastpathTV.EncMapInt64Int16V(*v, e)
  1355. case map[int64]int32:
  1356. fastpathTV.EncMapInt64Int32V(v, e)
  1357. case *map[int64]int32:
  1358. fastpathTV.EncMapInt64Int32V(*v, e)
  1359. case map[int64]int64:
  1360. fastpathTV.EncMapInt64Int64V(v, e)
  1361. case *map[int64]int64:
  1362. fastpathTV.EncMapInt64Int64V(*v, e)
  1363. case map[int64]float32:
  1364. fastpathTV.EncMapInt64Float32V(v, e)
  1365. case *map[int64]float32:
  1366. fastpathTV.EncMapInt64Float32V(*v, e)
  1367. case map[int64]float64:
  1368. fastpathTV.EncMapInt64Float64V(v, e)
  1369. case *map[int64]float64:
  1370. fastpathTV.EncMapInt64Float64V(*v, e)
  1371. case map[int64]bool:
  1372. fastpathTV.EncMapInt64BoolV(v, e)
  1373. case *map[int64]bool:
  1374. fastpathTV.EncMapInt64BoolV(*v, e)
  1375. case []bool:
  1376. fastpathTV.EncSliceBoolV(v, e)
  1377. case *[]bool:
  1378. fastpathTV.EncSliceBoolV(*v, e)
  1379. case map[bool]interface{}:
  1380. fastpathTV.EncMapBoolIntfV(v, e)
  1381. case *map[bool]interface{}:
  1382. fastpathTV.EncMapBoolIntfV(*v, e)
  1383. case map[bool]string:
  1384. fastpathTV.EncMapBoolStringV(v, e)
  1385. case *map[bool]string:
  1386. fastpathTV.EncMapBoolStringV(*v, e)
  1387. case map[bool]uint:
  1388. fastpathTV.EncMapBoolUintV(v, e)
  1389. case *map[bool]uint:
  1390. fastpathTV.EncMapBoolUintV(*v, e)
  1391. case map[bool]uint8:
  1392. fastpathTV.EncMapBoolUint8V(v, e)
  1393. case *map[bool]uint8:
  1394. fastpathTV.EncMapBoolUint8V(*v, e)
  1395. case map[bool]uint16:
  1396. fastpathTV.EncMapBoolUint16V(v, e)
  1397. case *map[bool]uint16:
  1398. fastpathTV.EncMapBoolUint16V(*v, e)
  1399. case map[bool]uint32:
  1400. fastpathTV.EncMapBoolUint32V(v, e)
  1401. case *map[bool]uint32:
  1402. fastpathTV.EncMapBoolUint32V(*v, e)
  1403. case map[bool]uint64:
  1404. fastpathTV.EncMapBoolUint64V(v, e)
  1405. case *map[bool]uint64:
  1406. fastpathTV.EncMapBoolUint64V(*v, e)
  1407. case map[bool]uintptr:
  1408. fastpathTV.EncMapBoolUintptrV(v, e)
  1409. case *map[bool]uintptr:
  1410. fastpathTV.EncMapBoolUintptrV(*v, e)
  1411. case map[bool]int:
  1412. fastpathTV.EncMapBoolIntV(v, e)
  1413. case *map[bool]int:
  1414. fastpathTV.EncMapBoolIntV(*v, e)
  1415. case map[bool]int8:
  1416. fastpathTV.EncMapBoolInt8V(v, e)
  1417. case *map[bool]int8:
  1418. fastpathTV.EncMapBoolInt8V(*v, e)
  1419. case map[bool]int16:
  1420. fastpathTV.EncMapBoolInt16V(v, e)
  1421. case *map[bool]int16:
  1422. fastpathTV.EncMapBoolInt16V(*v, e)
  1423. case map[bool]int32:
  1424. fastpathTV.EncMapBoolInt32V(v, e)
  1425. case *map[bool]int32:
  1426. fastpathTV.EncMapBoolInt32V(*v, e)
  1427. case map[bool]int64:
  1428. fastpathTV.EncMapBoolInt64V(v, e)
  1429. case *map[bool]int64:
  1430. fastpathTV.EncMapBoolInt64V(*v, e)
  1431. case map[bool]float32:
  1432. fastpathTV.EncMapBoolFloat32V(v, e)
  1433. case *map[bool]float32:
  1434. fastpathTV.EncMapBoolFloat32V(*v, e)
  1435. case map[bool]float64:
  1436. fastpathTV.EncMapBoolFloat64V(v, e)
  1437. case *map[bool]float64:
  1438. fastpathTV.EncMapBoolFloat64V(*v, e)
  1439. case map[bool]bool:
  1440. fastpathTV.EncMapBoolBoolV(v, e)
  1441. case *map[bool]bool:
  1442. fastpathTV.EncMapBoolBoolV(*v, e)
  1443. default:
  1444. _ = v // TODO: workaround https://github.com/golang/go/issues/12927 (remove after go 1.6 release)
  1445. return false
  1446. }
  1447. return true
  1448. }
  1449. // -- -- fast path functions
  1450. func (e *Encoder) fastpathEncSliceIntfR(f *codecFnInfo, rv reflect.Value) {
  1451. if f.ti.mbs {
  1452. fastpathTV.EncAsMapSliceIntfV(rv2i(rv).([]interface{}), e)
  1453. } else {
  1454. fastpathTV.EncSliceIntfV(rv2i(rv).([]interface{}), e)
  1455. }
  1456. }
  1457. func (_ fastpathT) EncSliceIntfV(v []interface{}, e *Encoder) {
  1458. if v == nil {
  1459. e.e.EncodeNil()
  1460. return
  1461. }
  1462. ee, esep := e.e, e.hh.hasElemSeparators()
  1463. ee.WriteArrayStart(len(v))
  1464. for _, v2 := range v {
  1465. if esep {
  1466. ee.WriteArrayElem()
  1467. }
  1468. e.encode(v2)
  1469. }
  1470. ee.WriteArrayEnd()
  1471. }
  1472. func (_ fastpathT) EncAsMapSliceIntfV(v []interface{}, e *Encoder) {
  1473. ee, esep := e.e, e.hh.hasElemSeparators()
  1474. if len(v)%2 == 1 {
  1475. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1476. return
  1477. }
  1478. ee.WriteMapStart(len(v) / 2)
  1479. for j, v2 := range v {
  1480. if esep {
  1481. if j%2 == 0 {
  1482. ee.WriteMapElemKey()
  1483. } else {
  1484. ee.WriteMapElemValue()
  1485. }
  1486. }
  1487. e.encode(v2)
  1488. }
  1489. ee.WriteMapEnd()
  1490. }
  1491. func (e *Encoder) fastpathEncSliceStringR(f *codecFnInfo, rv reflect.Value) {
  1492. if f.ti.mbs {
  1493. fastpathTV.EncAsMapSliceStringV(rv2i(rv).([]string), e)
  1494. } else {
  1495. fastpathTV.EncSliceStringV(rv2i(rv).([]string), e)
  1496. }
  1497. }
  1498. func (_ fastpathT) EncSliceStringV(v []string, e *Encoder) {
  1499. if v == nil {
  1500. e.e.EncodeNil()
  1501. return
  1502. }
  1503. ee, esep := e.e, e.hh.hasElemSeparators()
  1504. ee.WriteArrayStart(len(v))
  1505. for _, v2 := range v {
  1506. if esep {
  1507. ee.WriteArrayElem()
  1508. }
  1509. ee.EncodeString(c_UTF8, v2)
  1510. }
  1511. ee.WriteArrayEnd()
  1512. }
  1513. func (_ fastpathT) EncAsMapSliceStringV(v []string, e *Encoder) {
  1514. ee, esep := e.e, e.hh.hasElemSeparators()
  1515. if len(v)%2 == 1 {
  1516. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1517. return
  1518. }
  1519. ee.WriteMapStart(len(v) / 2)
  1520. for j, v2 := range v {
  1521. if esep {
  1522. if j%2 == 0 {
  1523. ee.WriteMapElemKey()
  1524. } else {
  1525. ee.WriteMapElemValue()
  1526. }
  1527. }
  1528. ee.EncodeString(c_UTF8, v2)
  1529. }
  1530. ee.WriteMapEnd()
  1531. }
  1532. func (e *Encoder) fastpathEncSliceFloat32R(f *codecFnInfo, rv reflect.Value) {
  1533. if f.ti.mbs {
  1534. fastpathTV.EncAsMapSliceFloat32V(rv2i(rv).([]float32), e)
  1535. } else {
  1536. fastpathTV.EncSliceFloat32V(rv2i(rv).([]float32), e)
  1537. }
  1538. }
  1539. func (_ fastpathT) EncSliceFloat32V(v []float32, e *Encoder) {
  1540. if v == nil {
  1541. e.e.EncodeNil()
  1542. return
  1543. }
  1544. ee, esep := e.e, e.hh.hasElemSeparators()
  1545. ee.WriteArrayStart(len(v))
  1546. for _, v2 := range v {
  1547. if esep {
  1548. ee.WriteArrayElem()
  1549. }
  1550. ee.EncodeFloat32(v2)
  1551. }
  1552. ee.WriteArrayEnd()
  1553. }
  1554. func (_ fastpathT) EncAsMapSliceFloat32V(v []float32, e *Encoder) {
  1555. ee, esep := e.e, e.hh.hasElemSeparators()
  1556. if len(v)%2 == 1 {
  1557. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1558. return
  1559. }
  1560. ee.WriteMapStart(len(v) / 2)
  1561. for j, v2 := range v {
  1562. if esep {
  1563. if j%2 == 0 {
  1564. ee.WriteMapElemKey()
  1565. } else {
  1566. ee.WriteMapElemValue()
  1567. }
  1568. }
  1569. ee.EncodeFloat32(v2)
  1570. }
  1571. ee.WriteMapEnd()
  1572. }
  1573. func (e *Encoder) fastpathEncSliceFloat64R(f *codecFnInfo, rv reflect.Value) {
  1574. if f.ti.mbs {
  1575. fastpathTV.EncAsMapSliceFloat64V(rv2i(rv).([]float64), e)
  1576. } else {
  1577. fastpathTV.EncSliceFloat64V(rv2i(rv).([]float64), e)
  1578. }
  1579. }
  1580. func (_ fastpathT) EncSliceFloat64V(v []float64, e *Encoder) {
  1581. if v == nil {
  1582. e.e.EncodeNil()
  1583. return
  1584. }
  1585. ee, esep := e.e, e.hh.hasElemSeparators()
  1586. ee.WriteArrayStart(len(v))
  1587. for _, v2 := range v {
  1588. if esep {
  1589. ee.WriteArrayElem()
  1590. }
  1591. ee.EncodeFloat64(v2)
  1592. }
  1593. ee.WriteArrayEnd()
  1594. }
  1595. func (_ fastpathT) EncAsMapSliceFloat64V(v []float64, e *Encoder) {
  1596. ee, esep := e.e, e.hh.hasElemSeparators()
  1597. if len(v)%2 == 1 {
  1598. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1599. return
  1600. }
  1601. ee.WriteMapStart(len(v) / 2)
  1602. for j, v2 := range v {
  1603. if esep {
  1604. if j%2 == 0 {
  1605. ee.WriteMapElemKey()
  1606. } else {
  1607. ee.WriteMapElemValue()
  1608. }
  1609. }
  1610. ee.EncodeFloat64(v2)
  1611. }
  1612. ee.WriteMapEnd()
  1613. }
  1614. func (e *Encoder) fastpathEncSliceUintR(f *codecFnInfo, rv reflect.Value) {
  1615. if f.ti.mbs {
  1616. fastpathTV.EncAsMapSliceUintV(rv2i(rv).([]uint), e)
  1617. } else {
  1618. fastpathTV.EncSliceUintV(rv2i(rv).([]uint), e)
  1619. }
  1620. }
  1621. func (_ fastpathT) EncSliceUintV(v []uint, e *Encoder) {
  1622. if v == nil {
  1623. e.e.EncodeNil()
  1624. return
  1625. }
  1626. ee, esep := e.e, e.hh.hasElemSeparators()
  1627. ee.WriteArrayStart(len(v))
  1628. for _, v2 := range v {
  1629. if esep {
  1630. ee.WriteArrayElem()
  1631. }
  1632. ee.EncodeUint(uint64(v2))
  1633. }
  1634. ee.WriteArrayEnd()
  1635. }
  1636. func (_ fastpathT) EncAsMapSliceUintV(v []uint, e *Encoder) {
  1637. ee, esep := e.e, e.hh.hasElemSeparators()
  1638. if len(v)%2 == 1 {
  1639. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1640. return
  1641. }
  1642. ee.WriteMapStart(len(v) / 2)
  1643. for j, v2 := range v {
  1644. if esep {
  1645. if j%2 == 0 {
  1646. ee.WriteMapElemKey()
  1647. } else {
  1648. ee.WriteMapElemValue()
  1649. }
  1650. }
  1651. ee.EncodeUint(uint64(v2))
  1652. }
  1653. ee.WriteMapEnd()
  1654. }
  1655. func (e *Encoder) fastpathEncSliceUint16R(f *codecFnInfo, rv reflect.Value) {
  1656. if f.ti.mbs {
  1657. fastpathTV.EncAsMapSliceUint16V(rv2i(rv).([]uint16), e)
  1658. } else {
  1659. fastpathTV.EncSliceUint16V(rv2i(rv).([]uint16), e)
  1660. }
  1661. }
  1662. func (_ fastpathT) EncSliceUint16V(v []uint16, e *Encoder) {
  1663. if v == nil {
  1664. e.e.EncodeNil()
  1665. return
  1666. }
  1667. ee, esep := e.e, e.hh.hasElemSeparators()
  1668. ee.WriteArrayStart(len(v))
  1669. for _, v2 := range v {
  1670. if esep {
  1671. ee.WriteArrayElem()
  1672. }
  1673. ee.EncodeUint(uint64(v2))
  1674. }
  1675. ee.WriteArrayEnd()
  1676. }
  1677. func (_ fastpathT) EncAsMapSliceUint16V(v []uint16, e *Encoder) {
  1678. ee, esep := e.e, e.hh.hasElemSeparators()
  1679. if len(v)%2 == 1 {
  1680. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1681. return
  1682. }
  1683. ee.WriteMapStart(len(v) / 2)
  1684. for j, v2 := range v {
  1685. if esep {
  1686. if j%2 == 0 {
  1687. ee.WriteMapElemKey()
  1688. } else {
  1689. ee.WriteMapElemValue()
  1690. }
  1691. }
  1692. ee.EncodeUint(uint64(v2))
  1693. }
  1694. ee.WriteMapEnd()
  1695. }
  1696. func (e *Encoder) fastpathEncSliceUint32R(f *codecFnInfo, rv reflect.Value) {
  1697. if f.ti.mbs {
  1698. fastpathTV.EncAsMapSliceUint32V(rv2i(rv).([]uint32), e)
  1699. } else {
  1700. fastpathTV.EncSliceUint32V(rv2i(rv).([]uint32), e)
  1701. }
  1702. }
  1703. func (_ fastpathT) EncSliceUint32V(v []uint32, e *Encoder) {
  1704. if v == nil {
  1705. e.e.EncodeNil()
  1706. return
  1707. }
  1708. ee, esep := e.e, e.hh.hasElemSeparators()
  1709. ee.WriteArrayStart(len(v))
  1710. for _, v2 := range v {
  1711. if esep {
  1712. ee.WriteArrayElem()
  1713. }
  1714. ee.EncodeUint(uint64(v2))
  1715. }
  1716. ee.WriteArrayEnd()
  1717. }
  1718. func (_ fastpathT) EncAsMapSliceUint32V(v []uint32, e *Encoder) {
  1719. ee, esep := e.e, e.hh.hasElemSeparators()
  1720. if len(v)%2 == 1 {
  1721. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1722. return
  1723. }
  1724. ee.WriteMapStart(len(v) / 2)
  1725. for j, v2 := range v {
  1726. if esep {
  1727. if j%2 == 0 {
  1728. ee.WriteMapElemKey()
  1729. } else {
  1730. ee.WriteMapElemValue()
  1731. }
  1732. }
  1733. ee.EncodeUint(uint64(v2))
  1734. }
  1735. ee.WriteMapEnd()
  1736. }
  1737. func (e *Encoder) fastpathEncSliceUint64R(f *codecFnInfo, rv reflect.Value) {
  1738. if f.ti.mbs {
  1739. fastpathTV.EncAsMapSliceUint64V(rv2i(rv).([]uint64), e)
  1740. } else {
  1741. fastpathTV.EncSliceUint64V(rv2i(rv).([]uint64), e)
  1742. }
  1743. }
  1744. func (_ fastpathT) EncSliceUint64V(v []uint64, e *Encoder) {
  1745. if v == nil {
  1746. e.e.EncodeNil()
  1747. return
  1748. }
  1749. ee, esep := e.e, e.hh.hasElemSeparators()
  1750. ee.WriteArrayStart(len(v))
  1751. for _, v2 := range v {
  1752. if esep {
  1753. ee.WriteArrayElem()
  1754. }
  1755. ee.EncodeUint(uint64(v2))
  1756. }
  1757. ee.WriteArrayEnd()
  1758. }
  1759. func (_ fastpathT) EncAsMapSliceUint64V(v []uint64, e *Encoder) {
  1760. ee, esep := e.e, e.hh.hasElemSeparators()
  1761. if len(v)%2 == 1 {
  1762. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1763. return
  1764. }
  1765. ee.WriteMapStart(len(v) / 2)
  1766. for j, v2 := range v {
  1767. if esep {
  1768. if j%2 == 0 {
  1769. ee.WriteMapElemKey()
  1770. } else {
  1771. ee.WriteMapElemValue()
  1772. }
  1773. }
  1774. ee.EncodeUint(uint64(v2))
  1775. }
  1776. ee.WriteMapEnd()
  1777. }
  1778. func (e *Encoder) fastpathEncSliceUintptrR(f *codecFnInfo, rv reflect.Value) {
  1779. if f.ti.mbs {
  1780. fastpathTV.EncAsMapSliceUintptrV(rv2i(rv).([]uintptr), e)
  1781. } else {
  1782. fastpathTV.EncSliceUintptrV(rv2i(rv).([]uintptr), e)
  1783. }
  1784. }
  1785. func (_ fastpathT) EncSliceUintptrV(v []uintptr, e *Encoder) {
  1786. if v == nil {
  1787. e.e.EncodeNil()
  1788. return
  1789. }
  1790. ee, esep := e.e, e.hh.hasElemSeparators()
  1791. ee.WriteArrayStart(len(v))
  1792. for _, v2 := range v {
  1793. if esep {
  1794. ee.WriteArrayElem()
  1795. }
  1796. e.encode(v2)
  1797. }
  1798. ee.WriteArrayEnd()
  1799. }
  1800. func (_ fastpathT) EncAsMapSliceUintptrV(v []uintptr, e *Encoder) {
  1801. ee, esep := e.e, e.hh.hasElemSeparators()
  1802. if len(v)%2 == 1 {
  1803. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1804. return
  1805. }
  1806. ee.WriteMapStart(len(v) / 2)
  1807. for j, v2 := range v {
  1808. if esep {
  1809. if j%2 == 0 {
  1810. ee.WriteMapElemKey()
  1811. } else {
  1812. ee.WriteMapElemValue()
  1813. }
  1814. }
  1815. e.encode(v2)
  1816. }
  1817. ee.WriteMapEnd()
  1818. }
  1819. func (e *Encoder) fastpathEncSliceIntR(f *codecFnInfo, rv reflect.Value) {
  1820. if f.ti.mbs {
  1821. fastpathTV.EncAsMapSliceIntV(rv2i(rv).([]int), e)
  1822. } else {
  1823. fastpathTV.EncSliceIntV(rv2i(rv).([]int), e)
  1824. }
  1825. }
  1826. func (_ fastpathT) EncSliceIntV(v []int, e *Encoder) {
  1827. if v == nil {
  1828. e.e.EncodeNil()
  1829. return
  1830. }
  1831. ee, esep := e.e, e.hh.hasElemSeparators()
  1832. ee.WriteArrayStart(len(v))
  1833. for _, v2 := range v {
  1834. if esep {
  1835. ee.WriteArrayElem()
  1836. }
  1837. ee.EncodeInt(int64(v2))
  1838. }
  1839. ee.WriteArrayEnd()
  1840. }
  1841. func (_ fastpathT) EncAsMapSliceIntV(v []int, e *Encoder) {
  1842. ee, esep := e.e, e.hh.hasElemSeparators()
  1843. if len(v)%2 == 1 {
  1844. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1845. return
  1846. }
  1847. ee.WriteMapStart(len(v) / 2)
  1848. for j, v2 := range v {
  1849. if esep {
  1850. if j%2 == 0 {
  1851. ee.WriteMapElemKey()
  1852. } else {
  1853. ee.WriteMapElemValue()
  1854. }
  1855. }
  1856. ee.EncodeInt(int64(v2))
  1857. }
  1858. ee.WriteMapEnd()
  1859. }
  1860. func (e *Encoder) fastpathEncSliceInt8R(f *codecFnInfo, rv reflect.Value) {
  1861. if f.ti.mbs {
  1862. fastpathTV.EncAsMapSliceInt8V(rv2i(rv).([]int8), e)
  1863. } else {
  1864. fastpathTV.EncSliceInt8V(rv2i(rv).([]int8), e)
  1865. }
  1866. }
  1867. func (_ fastpathT) EncSliceInt8V(v []int8, e *Encoder) {
  1868. if v == nil {
  1869. e.e.EncodeNil()
  1870. return
  1871. }
  1872. ee, esep := e.e, e.hh.hasElemSeparators()
  1873. ee.WriteArrayStart(len(v))
  1874. for _, v2 := range v {
  1875. if esep {
  1876. ee.WriteArrayElem()
  1877. }
  1878. ee.EncodeInt(int64(v2))
  1879. }
  1880. ee.WriteArrayEnd()
  1881. }
  1882. func (_ fastpathT) EncAsMapSliceInt8V(v []int8, e *Encoder) {
  1883. ee, esep := e.e, e.hh.hasElemSeparators()
  1884. if len(v)%2 == 1 {
  1885. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1886. return
  1887. }
  1888. ee.WriteMapStart(len(v) / 2)
  1889. for j, v2 := range v {
  1890. if esep {
  1891. if j%2 == 0 {
  1892. ee.WriteMapElemKey()
  1893. } else {
  1894. ee.WriteMapElemValue()
  1895. }
  1896. }
  1897. ee.EncodeInt(int64(v2))
  1898. }
  1899. ee.WriteMapEnd()
  1900. }
  1901. func (e *Encoder) fastpathEncSliceInt16R(f *codecFnInfo, rv reflect.Value) {
  1902. if f.ti.mbs {
  1903. fastpathTV.EncAsMapSliceInt16V(rv2i(rv).([]int16), e)
  1904. } else {
  1905. fastpathTV.EncSliceInt16V(rv2i(rv).([]int16), e)
  1906. }
  1907. }
  1908. func (_ fastpathT) EncSliceInt16V(v []int16, e *Encoder) {
  1909. if v == nil {
  1910. e.e.EncodeNil()
  1911. return
  1912. }
  1913. ee, esep := e.e, e.hh.hasElemSeparators()
  1914. ee.WriteArrayStart(len(v))
  1915. for _, v2 := range v {
  1916. if esep {
  1917. ee.WriteArrayElem()
  1918. }
  1919. ee.EncodeInt(int64(v2))
  1920. }
  1921. ee.WriteArrayEnd()
  1922. }
  1923. func (_ fastpathT) EncAsMapSliceInt16V(v []int16, e *Encoder) {
  1924. ee, esep := e.e, e.hh.hasElemSeparators()
  1925. if len(v)%2 == 1 {
  1926. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1927. return
  1928. }
  1929. ee.WriteMapStart(len(v) / 2)
  1930. for j, v2 := range v {
  1931. if esep {
  1932. if j%2 == 0 {
  1933. ee.WriteMapElemKey()
  1934. } else {
  1935. ee.WriteMapElemValue()
  1936. }
  1937. }
  1938. ee.EncodeInt(int64(v2))
  1939. }
  1940. ee.WriteMapEnd()
  1941. }
  1942. func (e *Encoder) fastpathEncSliceInt32R(f *codecFnInfo, rv reflect.Value) {
  1943. if f.ti.mbs {
  1944. fastpathTV.EncAsMapSliceInt32V(rv2i(rv).([]int32), e)
  1945. } else {
  1946. fastpathTV.EncSliceInt32V(rv2i(rv).([]int32), e)
  1947. }
  1948. }
  1949. func (_ fastpathT) EncSliceInt32V(v []int32, e *Encoder) {
  1950. if v == nil {
  1951. e.e.EncodeNil()
  1952. return
  1953. }
  1954. ee, esep := e.e, e.hh.hasElemSeparators()
  1955. ee.WriteArrayStart(len(v))
  1956. for _, v2 := range v {
  1957. if esep {
  1958. ee.WriteArrayElem()
  1959. }
  1960. ee.EncodeInt(int64(v2))
  1961. }
  1962. ee.WriteArrayEnd()
  1963. }
  1964. func (_ fastpathT) EncAsMapSliceInt32V(v []int32, e *Encoder) {
  1965. ee, esep := e.e, e.hh.hasElemSeparators()
  1966. if len(v)%2 == 1 {
  1967. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  1968. return
  1969. }
  1970. ee.WriteMapStart(len(v) / 2)
  1971. for j, v2 := range v {
  1972. if esep {
  1973. if j%2 == 0 {
  1974. ee.WriteMapElemKey()
  1975. } else {
  1976. ee.WriteMapElemValue()
  1977. }
  1978. }
  1979. ee.EncodeInt(int64(v2))
  1980. }
  1981. ee.WriteMapEnd()
  1982. }
  1983. func (e *Encoder) fastpathEncSliceInt64R(f *codecFnInfo, rv reflect.Value) {
  1984. if f.ti.mbs {
  1985. fastpathTV.EncAsMapSliceInt64V(rv2i(rv).([]int64), e)
  1986. } else {
  1987. fastpathTV.EncSliceInt64V(rv2i(rv).([]int64), e)
  1988. }
  1989. }
  1990. func (_ fastpathT) EncSliceInt64V(v []int64, e *Encoder) {
  1991. if v == nil {
  1992. e.e.EncodeNil()
  1993. return
  1994. }
  1995. ee, esep := e.e, e.hh.hasElemSeparators()
  1996. ee.WriteArrayStart(len(v))
  1997. for _, v2 := range v {
  1998. if esep {
  1999. ee.WriteArrayElem()
  2000. }
  2001. ee.EncodeInt(int64(v2))
  2002. }
  2003. ee.WriteArrayEnd()
  2004. }
  2005. func (_ fastpathT) EncAsMapSliceInt64V(v []int64, e *Encoder) {
  2006. ee, esep := e.e, e.hh.hasElemSeparators()
  2007. if len(v)%2 == 1 {
  2008. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  2009. return
  2010. }
  2011. ee.WriteMapStart(len(v) / 2)
  2012. for j, v2 := range v {
  2013. if esep {
  2014. if j%2 == 0 {
  2015. ee.WriteMapElemKey()
  2016. } else {
  2017. ee.WriteMapElemValue()
  2018. }
  2019. }
  2020. ee.EncodeInt(int64(v2))
  2021. }
  2022. ee.WriteMapEnd()
  2023. }
  2024. func (e *Encoder) fastpathEncSliceBoolR(f *codecFnInfo, rv reflect.Value) {
  2025. if f.ti.mbs {
  2026. fastpathTV.EncAsMapSliceBoolV(rv2i(rv).([]bool), e)
  2027. } else {
  2028. fastpathTV.EncSliceBoolV(rv2i(rv).([]bool), e)
  2029. }
  2030. }
  2031. func (_ fastpathT) EncSliceBoolV(v []bool, e *Encoder) {
  2032. if v == nil {
  2033. e.e.EncodeNil()
  2034. return
  2035. }
  2036. ee, esep := e.e, e.hh.hasElemSeparators()
  2037. ee.WriteArrayStart(len(v))
  2038. for _, v2 := range v {
  2039. if esep {
  2040. ee.WriteArrayElem()
  2041. }
  2042. ee.EncodeBool(v2)
  2043. }
  2044. ee.WriteArrayEnd()
  2045. }
  2046. func (_ fastpathT) EncAsMapSliceBoolV(v []bool, e *Encoder) {
  2047. ee, esep := e.e, e.hh.hasElemSeparators()
  2048. if len(v)%2 == 1 {
  2049. e.errorf("mapBySlice requires even slice length, but got %v", len(v))
  2050. return
  2051. }
  2052. ee.WriteMapStart(len(v) / 2)
  2053. for j, v2 := range v {
  2054. if esep {
  2055. if j%2 == 0 {
  2056. ee.WriteMapElemKey()
  2057. } else {
  2058. ee.WriteMapElemValue()
  2059. }
  2060. }
  2061. ee.EncodeBool(v2)
  2062. }
  2063. ee.WriteMapEnd()
  2064. }
  2065. func (e *Encoder) fastpathEncMapIntfIntfR(f *codecFnInfo, rv reflect.Value) {
  2066. fastpathTV.EncMapIntfIntfV(rv2i(rv).(map[interface{}]interface{}), e)
  2067. }
  2068. func (_ fastpathT) EncMapIntfIntfV(v map[interface{}]interface{}, e *Encoder) {
  2069. if v == nil {
  2070. e.e.EncodeNil()
  2071. return
  2072. }
  2073. ee, esep := e.e, e.hh.hasElemSeparators()
  2074. ee.WriteMapStart(len(v))
  2075. if e.h.Canonical {
  2076. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2077. e2 := NewEncoderBytes(&mksv, e.hh)
  2078. v2 := make([]bytesI, len(v))
  2079. var i, l int
  2080. var vp *bytesI
  2081. for k2, _ := range v {
  2082. l = len(mksv)
  2083. e2.MustEncode(k2)
  2084. vp = &v2[i]
  2085. vp.v = mksv[l:]
  2086. vp.i = k2
  2087. i++
  2088. }
  2089. sort.Sort(bytesISlice(v2))
  2090. for j := range v2 {
  2091. if esep {
  2092. ee.WriteMapElemKey()
  2093. }
  2094. e.asis(v2[j].v)
  2095. if esep {
  2096. ee.WriteMapElemValue()
  2097. }
  2098. e.encode(v[v2[j].i])
  2099. }
  2100. } else {
  2101. for k2, v2 := range v {
  2102. if esep {
  2103. ee.WriteMapElemKey()
  2104. }
  2105. e.encode(k2)
  2106. if esep {
  2107. ee.WriteMapElemValue()
  2108. }
  2109. e.encode(v2)
  2110. }
  2111. }
  2112. ee.WriteMapEnd()
  2113. }
  2114. func (e *Encoder) fastpathEncMapIntfStringR(f *codecFnInfo, rv reflect.Value) {
  2115. fastpathTV.EncMapIntfStringV(rv2i(rv).(map[interface{}]string), e)
  2116. }
  2117. func (_ fastpathT) EncMapIntfStringV(v map[interface{}]string, e *Encoder) {
  2118. if v == nil {
  2119. e.e.EncodeNil()
  2120. return
  2121. }
  2122. ee, esep := e.e, e.hh.hasElemSeparators()
  2123. ee.WriteMapStart(len(v))
  2124. if e.h.Canonical {
  2125. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2126. e2 := NewEncoderBytes(&mksv, e.hh)
  2127. v2 := make([]bytesI, len(v))
  2128. var i, l int
  2129. var vp *bytesI
  2130. for k2, _ := range v {
  2131. l = len(mksv)
  2132. e2.MustEncode(k2)
  2133. vp = &v2[i]
  2134. vp.v = mksv[l:]
  2135. vp.i = k2
  2136. i++
  2137. }
  2138. sort.Sort(bytesISlice(v2))
  2139. for j := range v2 {
  2140. if esep {
  2141. ee.WriteMapElemKey()
  2142. }
  2143. e.asis(v2[j].v)
  2144. if esep {
  2145. ee.WriteMapElemValue()
  2146. }
  2147. e.encode(v[v2[j].i])
  2148. }
  2149. } else {
  2150. for k2, v2 := range v {
  2151. if esep {
  2152. ee.WriteMapElemKey()
  2153. }
  2154. e.encode(k2)
  2155. if esep {
  2156. ee.WriteMapElemValue()
  2157. }
  2158. ee.EncodeString(c_UTF8, v2)
  2159. }
  2160. }
  2161. ee.WriteMapEnd()
  2162. }
  2163. func (e *Encoder) fastpathEncMapIntfUintR(f *codecFnInfo, rv reflect.Value) {
  2164. fastpathTV.EncMapIntfUintV(rv2i(rv).(map[interface{}]uint), e)
  2165. }
  2166. func (_ fastpathT) EncMapIntfUintV(v map[interface{}]uint, e *Encoder) {
  2167. if v == nil {
  2168. e.e.EncodeNil()
  2169. return
  2170. }
  2171. ee, esep := e.e, e.hh.hasElemSeparators()
  2172. ee.WriteMapStart(len(v))
  2173. if e.h.Canonical {
  2174. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2175. e2 := NewEncoderBytes(&mksv, e.hh)
  2176. v2 := make([]bytesI, len(v))
  2177. var i, l int
  2178. var vp *bytesI
  2179. for k2, _ := range v {
  2180. l = len(mksv)
  2181. e2.MustEncode(k2)
  2182. vp = &v2[i]
  2183. vp.v = mksv[l:]
  2184. vp.i = k2
  2185. i++
  2186. }
  2187. sort.Sort(bytesISlice(v2))
  2188. for j := range v2 {
  2189. if esep {
  2190. ee.WriteMapElemKey()
  2191. }
  2192. e.asis(v2[j].v)
  2193. if esep {
  2194. ee.WriteMapElemValue()
  2195. }
  2196. e.encode(v[v2[j].i])
  2197. }
  2198. } else {
  2199. for k2, v2 := range v {
  2200. if esep {
  2201. ee.WriteMapElemKey()
  2202. }
  2203. e.encode(k2)
  2204. if esep {
  2205. ee.WriteMapElemValue()
  2206. }
  2207. ee.EncodeUint(uint64(v2))
  2208. }
  2209. }
  2210. ee.WriteMapEnd()
  2211. }
  2212. func (e *Encoder) fastpathEncMapIntfUint8R(f *codecFnInfo, rv reflect.Value) {
  2213. fastpathTV.EncMapIntfUint8V(rv2i(rv).(map[interface{}]uint8), e)
  2214. }
  2215. func (_ fastpathT) EncMapIntfUint8V(v map[interface{}]uint8, e *Encoder) {
  2216. if v == nil {
  2217. e.e.EncodeNil()
  2218. return
  2219. }
  2220. ee, esep := e.e, e.hh.hasElemSeparators()
  2221. ee.WriteMapStart(len(v))
  2222. if e.h.Canonical {
  2223. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2224. e2 := NewEncoderBytes(&mksv, e.hh)
  2225. v2 := make([]bytesI, len(v))
  2226. var i, l int
  2227. var vp *bytesI
  2228. for k2, _ := range v {
  2229. l = len(mksv)
  2230. e2.MustEncode(k2)
  2231. vp = &v2[i]
  2232. vp.v = mksv[l:]
  2233. vp.i = k2
  2234. i++
  2235. }
  2236. sort.Sort(bytesISlice(v2))
  2237. for j := range v2 {
  2238. if esep {
  2239. ee.WriteMapElemKey()
  2240. }
  2241. e.asis(v2[j].v)
  2242. if esep {
  2243. ee.WriteMapElemValue()
  2244. }
  2245. e.encode(v[v2[j].i])
  2246. }
  2247. } else {
  2248. for k2, v2 := range v {
  2249. if esep {
  2250. ee.WriteMapElemKey()
  2251. }
  2252. e.encode(k2)
  2253. if esep {
  2254. ee.WriteMapElemValue()
  2255. }
  2256. ee.EncodeUint(uint64(v2))
  2257. }
  2258. }
  2259. ee.WriteMapEnd()
  2260. }
  2261. func (e *Encoder) fastpathEncMapIntfUint16R(f *codecFnInfo, rv reflect.Value) {
  2262. fastpathTV.EncMapIntfUint16V(rv2i(rv).(map[interface{}]uint16), e)
  2263. }
  2264. func (_ fastpathT) EncMapIntfUint16V(v map[interface{}]uint16, e *Encoder) {
  2265. if v == nil {
  2266. e.e.EncodeNil()
  2267. return
  2268. }
  2269. ee, esep := e.e, e.hh.hasElemSeparators()
  2270. ee.WriteMapStart(len(v))
  2271. if e.h.Canonical {
  2272. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2273. e2 := NewEncoderBytes(&mksv, e.hh)
  2274. v2 := make([]bytesI, len(v))
  2275. var i, l int
  2276. var vp *bytesI
  2277. for k2, _ := range v {
  2278. l = len(mksv)
  2279. e2.MustEncode(k2)
  2280. vp = &v2[i]
  2281. vp.v = mksv[l:]
  2282. vp.i = k2
  2283. i++
  2284. }
  2285. sort.Sort(bytesISlice(v2))
  2286. for j := range v2 {
  2287. if esep {
  2288. ee.WriteMapElemKey()
  2289. }
  2290. e.asis(v2[j].v)
  2291. if esep {
  2292. ee.WriteMapElemValue()
  2293. }
  2294. e.encode(v[v2[j].i])
  2295. }
  2296. } else {
  2297. for k2, v2 := range v {
  2298. if esep {
  2299. ee.WriteMapElemKey()
  2300. }
  2301. e.encode(k2)
  2302. if esep {
  2303. ee.WriteMapElemValue()
  2304. }
  2305. ee.EncodeUint(uint64(v2))
  2306. }
  2307. }
  2308. ee.WriteMapEnd()
  2309. }
  2310. func (e *Encoder) fastpathEncMapIntfUint32R(f *codecFnInfo, rv reflect.Value) {
  2311. fastpathTV.EncMapIntfUint32V(rv2i(rv).(map[interface{}]uint32), e)
  2312. }
  2313. func (_ fastpathT) EncMapIntfUint32V(v map[interface{}]uint32, e *Encoder) {
  2314. if v == nil {
  2315. e.e.EncodeNil()
  2316. return
  2317. }
  2318. ee, esep := e.e, e.hh.hasElemSeparators()
  2319. ee.WriteMapStart(len(v))
  2320. if e.h.Canonical {
  2321. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2322. e2 := NewEncoderBytes(&mksv, e.hh)
  2323. v2 := make([]bytesI, len(v))
  2324. var i, l int
  2325. var vp *bytesI
  2326. for k2, _ := range v {
  2327. l = len(mksv)
  2328. e2.MustEncode(k2)
  2329. vp = &v2[i]
  2330. vp.v = mksv[l:]
  2331. vp.i = k2
  2332. i++
  2333. }
  2334. sort.Sort(bytesISlice(v2))
  2335. for j := range v2 {
  2336. if esep {
  2337. ee.WriteMapElemKey()
  2338. }
  2339. e.asis(v2[j].v)
  2340. if esep {
  2341. ee.WriteMapElemValue()
  2342. }
  2343. e.encode(v[v2[j].i])
  2344. }
  2345. } else {
  2346. for k2, v2 := range v {
  2347. if esep {
  2348. ee.WriteMapElemKey()
  2349. }
  2350. e.encode(k2)
  2351. if esep {
  2352. ee.WriteMapElemValue()
  2353. }
  2354. ee.EncodeUint(uint64(v2))
  2355. }
  2356. }
  2357. ee.WriteMapEnd()
  2358. }
  2359. func (e *Encoder) fastpathEncMapIntfUint64R(f *codecFnInfo, rv reflect.Value) {
  2360. fastpathTV.EncMapIntfUint64V(rv2i(rv).(map[interface{}]uint64), e)
  2361. }
  2362. func (_ fastpathT) EncMapIntfUint64V(v map[interface{}]uint64, e *Encoder) {
  2363. if v == nil {
  2364. e.e.EncodeNil()
  2365. return
  2366. }
  2367. ee, esep := e.e, e.hh.hasElemSeparators()
  2368. ee.WriteMapStart(len(v))
  2369. if e.h.Canonical {
  2370. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2371. e2 := NewEncoderBytes(&mksv, e.hh)
  2372. v2 := make([]bytesI, len(v))
  2373. var i, l int
  2374. var vp *bytesI
  2375. for k2, _ := range v {
  2376. l = len(mksv)
  2377. e2.MustEncode(k2)
  2378. vp = &v2[i]
  2379. vp.v = mksv[l:]
  2380. vp.i = k2
  2381. i++
  2382. }
  2383. sort.Sort(bytesISlice(v2))
  2384. for j := range v2 {
  2385. if esep {
  2386. ee.WriteMapElemKey()
  2387. }
  2388. e.asis(v2[j].v)
  2389. if esep {
  2390. ee.WriteMapElemValue()
  2391. }
  2392. e.encode(v[v2[j].i])
  2393. }
  2394. } else {
  2395. for k2, v2 := range v {
  2396. if esep {
  2397. ee.WriteMapElemKey()
  2398. }
  2399. e.encode(k2)
  2400. if esep {
  2401. ee.WriteMapElemValue()
  2402. }
  2403. ee.EncodeUint(uint64(v2))
  2404. }
  2405. }
  2406. ee.WriteMapEnd()
  2407. }
  2408. func (e *Encoder) fastpathEncMapIntfUintptrR(f *codecFnInfo, rv reflect.Value) {
  2409. fastpathTV.EncMapIntfUintptrV(rv2i(rv).(map[interface{}]uintptr), e)
  2410. }
  2411. func (_ fastpathT) EncMapIntfUintptrV(v map[interface{}]uintptr, e *Encoder) {
  2412. if v == nil {
  2413. e.e.EncodeNil()
  2414. return
  2415. }
  2416. ee, esep := e.e, e.hh.hasElemSeparators()
  2417. ee.WriteMapStart(len(v))
  2418. if e.h.Canonical {
  2419. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2420. e2 := NewEncoderBytes(&mksv, e.hh)
  2421. v2 := make([]bytesI, len(v))
  2422. var i, l int
  2423. var vp *bytesI
  2424. for k2, _ := range v {
  2425. l = len(mksv)
  2426. e2.MustEncode(k2)
  2427. vp = &v2[i]
  2428. vp.v = mksv[l:]
  2429. vp.i = k2
  2430. i++
  2431. }
  2432. sort.Sort(bytesISlice(v2))
  2433. for j := range v2 {
  2434. if esep {
  2435. ee.WriteMapElemKey()
  2436. }
  2437. e.asis(v2[j].v)
  2438. if esep {
  2439. ee.WriteMapElemValue()
  2440. }
  2441. e.encode(v[v2[j].i])
  2442. }
  2443. } else {
  2444. for k2, v2 := range v {
  2445. if esep {
  2446. ee.WriteMapElemKey()
  2447. }
  2448. e.encode(k2)
  2449. if esep {
  2450. ee.WriteMapElemValue()
  2451. }
  2452. e.encode(v2)
  2453. }
  2454. }
  2455. ee.WriteMapEnd()
  2456. }
  2457. func (e *Encoder) fastpathEncMapIntfIntR(f *codecFnInfo, rv reflect.Value) {
  2458. fastpathTV.EncMapIntfIntV(rv2i(rv).(map[interface{}]int), e)
  2459. }
  2460. func (_ fastpathT) EncMapIntfIntV(v map[interface{}]int, e *Encoder) {
  2461. if v == nil {
  2462. e.e.EncodeNil()
  2463. return
  2464. }
  2465. ee, esep := e.e, e.hh.hasElemSeparators()
  2466. ee.WriteMapStart(len(v))
  2467. if e.h.Canonical {
  2468. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2469. e2 := NewEncoderBytes(&mksv, e.hh)
  2470. v2 := make([]bytesI, len(v))
  2471. var i, l int
  2472. var vp *bytesI
  2473. for k2, _ := range v {
  2474. l = len(mksv)
  2475. e2.MustEncode(k2)
  2476. vp = &v2[i]
  2477. vp.v = mksv[l:]
  2478. vp.i = k2
  2479. i++
  2480. }
  2481. sort.Sort(bytesISlice(v2))
  2482. for j := range v2 {
  2483. if esep {
  2484. ee.WriteMapElemKey()
  2485. }
  2486. e.asis(v2[j].v)
  2487. if esep {
  2488. ee.WriteMapElemValue()
  2489. }
  2490. e.encode(v[v2[j].i])
  2491. }
  2492. } else {
  2493. for k2, v2 := range v {
  2494. if esep {
  2495. ee.WriteMapElemKey()
  2496. }
  2497. e.encode(k2)
  2498. if esep {
  2499. ee.WriteMapElemValue()
  2500. }
  2501. ee.EncodeInt(int64(v2))
  2502. }
  2503. }
  2504. ee.WriteMapEnd()
  2505. }
  2506. func (e *Encoder) fastpathEncMapIntfInt8R(f *codecFnInfo, rv reflect.Value) {
  2507. fastpathTV.EncMapIntfInt8V(rv2i(rv).(map[interface{}]int8), e)
  2508. }
  2509. func (_ fastpathT) EncMapIntfInt8V(v map[interface{}]int8, e *Encoder) {
  2510. if v == nil {
  2511. e.e.EncodeNil()
  2512. return
  2513. }
  2514. ee, esep := e.e, e.hh.hasElemSeparators()
  2515. ee.WriteMapStart(len(v))
  2516. if e.h.Canonical {
  2517. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2518. e2 := NewEncoderBytes(&mksv, e.hh)
  2519. v2 := make([]bytesI, len(v))
  2520. var i, l int
  2521. var vp *bytesI
  2522. for k2, _ := range v {
  2523. l = len(mksv)
  2524. e2.MustEncode(k2)
  2525. vp = &v2[i]
  2526. vp.v = mksv[l:]
  2527. vp.i = k2
  2528. i++
  2529. }
  2530. sort.Sort(bytesISlice(v2))
  2531. for j := range v2 {
  2532. if esep {
  2533. ee.WriteMapElemKey()
  2534. }
  2535. e.asis(v2[j].v)
  2536. if esep {
  2537. ee.WriteMapElemValue()
  2538. }
  2539. e.encode(v[v2[j].i])
  2540. }
  2541. } else {
  2542. for k2, v2 := range v {
  2543. if esep {
  2544. ee.WriteMapElemKey()
  2545. }
  2546. e.encode(k2)
  2547. if esep {
  2548. ee.WriteMapElemValue()
  2549. }
  2550. ee.EncodeInt(int64(v2))
  2551. }
  2552. }
  2553. ee.WriteMapEnd()
  2554. }
  2555. func (e *Encoder) fastpathEncMapIntfInt16R(f *codecFnInfo, rv reflect.Value) {
  2556. fastpathTV.EncMapIntfInt16V(rv2i(rv).(map[interface{}]int16), e)
  2557. }
  2558. func (_ fastpathT) EncMapIntfInt16V(v map[interface{}]int16, e *Encoder) {
  2559. if v == nil {
  2560. e.e.EncodeNil()
  2561. return
  2562. }
  2563. ee, esep := e.e, e.hh.hasElemSeparators()
  2564. ee.WriteMapStart(len(v))
  2565. if e.h.Canonical {
  2566. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2567. e2 := NewEncoderBytes(&mksv, e.hh)
  2568. v2 := make([]bytesI, len(v))
  2569. var i, l int
  2570. var vp *bytesI
  2571. for k2, _ := range v {
  2572. l = len(mksv)
  2573. e2.MustEncode(k2)
  2574. vp = &v2[i]
  2575. vp.v = mksv[l:]
  2576. vp.i = k2
  2577. i++
  2578. }
  2579. sort.Sort(bytesISlice(v2))
  2580. for j := range v2 {
  2581. if esep {
  2582. ee.WriteMapElemKey()
  2583. }
  2584. e.asis(v2[j].v)
  2585. if esep {
  2586. ee.WriteMapElemValue()
  2587. }
  2588. e.encode(v[v2[j].i])
  2589. }
  2590. } else {
  2591. for k2, v2 := range v {
  2592. if esep {
  2593. ee.WriteMapElemKey()
  2594. }
  2595. e.encode(k2)
  2596. if esep {
  2597. ee.WriteMapElemValue()
  2598. }
  2599. ee.EncodeInt(int64(v2))
  2600. }
  2601. }
  2602. ee.WriteMapEnd()
  2603. }
  2604. func (e *Encoder) fastpathEncMapIntfInt32R(f *codecFnInfo, rv reflect.Value) {
  2605. fastpathTV.EncMapIntfInt32V(rv2i(rv).(map[interface{}]int32), e)
  2606. }
  2607. func (_ fastpathT) EncMapIntfInt32V(v map[interface{}]int32, e *Encoder) {
  2608. if v == nil {
  2609. e.e.EncodeNil()
  2610. return
  2611. }
  2612. ee, esep := e.e, e.hh.hasElemSeparators()
  2613. ee.WriteMapStart(len(v))
  2614. if e.h.Canonical {
  2615. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2616. e2 := NewEncoderBytes(&mksv, e.hh)
  2617. v2 := make([]bytesI, len(v))
  2618. var i, l int
  2619. var vp *bytesI
  2620. for k2, _ := range v {
  2621. l = len(mksv)
  2622. e2.MustEncode(k2)
  2623. vp = &v2[i]
  2624. vp.v = mksv[l:]
  2625. vp.i = k2
  2626. i++
  2627. }
  2628. sort.Sort(bytesISlice(v2))
  2629. for j := range v2 {
  2630. if esep {
  2631. ee.WriteMapElemKey()
  2632. }
  2633. e.asis(v2[j].v)
  2634. if esep {
  2635. ee.WriteMapElemValue()
  2636. }
  2637. e.encode(v[v2[j].i])
  2638. }
  2639. } else {
  2640. for k2, v2 := range v {
  2641. if esep {
  2642. ee.WriteMapElemKey()
  2643. }
  2644. e.encode(k2)
  2645. if esep {
  2646. ee.WriteMapElemValue()
  2647. }
  2648. ee.EncodeInt(int64(v2))
  2649. }
  2650. }
  2651. ee.WriteMapEnd()
  2652. }
  2653. func (e *Encoder) fastpathEncMapIntfInt64R(f *codecFnInfo, rv reflect.Value) {
  2654. fastpathTV.EncMapIntfInt64V(rv2i(rv).(map[interface{}]int64), e)
  2655. }
  2656. func (_ fastpathT) EncMapIntfInt64V(v map[interface{}]int64, e *Encoder) {
  2657. if v == nil {
  2658. e.e.EncodeNil()
  2659. return
  2660. }
  2661. ee, esep := e.e, e.hh.hasElemSeparators()
  2662. ee.WriteMapStart(len(v))
  2663. if e.h.Canonical {
  2664. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2665. e2 := NewEncoderBytes(&mksv, e.hh)
  2666. v2 := make([]bytesI, len(v))
  2667. var i, l int
  2668. var vp *bytesI
  2669. for k2, _ := range v {
  2670. l = len(mksv)
  2671. e2.MustEncode(k2)
  2672. vp = &v2[i]
  2673. vp.v = mksv[l:]
  2674. vp.i = k2
  2675. i++
  2676. }
  2677. sort.Sort(bytesISlice(v2))
  2678. for j := range v2 {
  2679. if esep {
  2680. ee.WriteMapElemKey()
  2681. }
  2682. e.asis(v2[j].v)
  2683. if esep {
  2684. ee.WriteMapElemValue()
  2685. }
  2686. e.encode(v[v2[j].i])
  2687. }
  2688. } else {
  2689. for k2, v2 := range v {
  2690. if esep {
  2691. ee.WriteMapElemKey()
  2692. }
  2693. e.encode(k2)
  2694. if esep {
  2695. ee.WriteMapElemValue()
  2696. }
  2697. ee.EncodeInt(int64(v2))
  2698. }
  2699. }
  2700. ee.WriteMapEnd()
  2701. }
  2702. func (e *Encoder) fastpathEncMapIntfFloat32R(f *codecFnInfo, rv reflect.Value) {
  2703. fastpathTV.EncMapIntfFloat32V(rv2i(rv).(map[interface{}]float32), e)
  2704. }
  2705. func (_ fastpathT) EncMapIntfFloat32V(v map[interface{}]float32, e *Encoder) {
  2706. if v == nil {
  2707. e.e.EncodeNil()
  2708. return
  2709. }
  2710. ee, esep := e.e, e.hh.hasElemSeparators()
  2711. ee.WriteMapStart(len(v))
  2712. if e.h.Canonical {
  2713. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2714. e2 := NewEncoderBytes(&mksv, e.hh)
  2715. v2 := make([]bytesI, len(v))
  2716. var i, l int
  2717. var vp *bytesI
  2718. for k2, _ := range v {
  2719. l = len(mksv)
  2720. e2.MustEncode(k2)
  2721. vp = &v2[i]
  2722. vp.v = mksv[l:]
  2723. vp.i = k2
  2724. i++
  2725. }
  2726. sort.Sort(bytesISlice(v2))
  2727. for j := range v2 {
  2728. if esep {
  2729. ee.WriteMapElemKey()
  2730. }
  2731. e.asis(v2[j].v)
  2732. if esep {
  2733. ee.WriteMapElemValue()
  2734. }
  2735. e.encode(v[v2[j].i])
  2736. }
  2737. } else {
  2738. for k2, v2 := range v {
  2739. if esep {
  2740. ee.WriteMapElemKey()
  2741. }
  2742. e.encode(k2)
  2743. if esep {
  2744. ee.WriteMapElemValue()
  2745. }
  2746. ee.EncodeFloat32(v2)
  2747. }
  2748. }
  2749. ee.WriteMapEnd()
  2750. }
  2751. func (e *Encoder) fastpathEncMapIntfFloat64R(f *codecFnInfo, rv reflect.Value) {
  2752. fastpathTV.EncMapIntfFloat64V(rv2i(rv).(map[interface{}]float64), e)
  2753. }
  2754. func (_ fastpathT) EncMapIntfFloat64V(v map[interface{}]float64, e *Encoder) {
  2755. if v == nil {
  2756. e.e.EncodeNil()
  2757. return
  2758. }
  2759. ee, esep := e.e, e.hh.hasElemSeparators()
  2760. ee.WriteMapStart(len(v))
  2761. if e.h.Canonical {
  2762. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2763. e2 := NewEncoderBytes(&mksv, e.hh)
  2764. v2 := make([]bytesI, len(v))
  2765. var i, l int
  2766. var vp *bytesI
  2767. for k2, _ := range v {
  2768. l = len(mksv)
  2769. e2.MustEncode(k2)
  2770. vp = &v2[i]
  2771. vp.v = mksv[l:]
  2772. vp.i = k2
  2773. i++
  2774. }
  2775. sort.Sort(bytesISlice(v2))
  2776. for j := range v2 {
  2777. if esep {
  2778. ee.WriteMapElemKey()
  2779. }
  2780. e.asis(v2[j].v)
  2781. if esep {
  2782. ee.WriteMapElemValue()
  2783. }
  2784. e.encode(v[v2[j].i])
  2785. }
  2786. } else {
  2787. for k2, v2 := range v {
  2788. if esep {
  2789. ee.WriteMapElemKey()
  2790. }
  2791. e.encode(k2)
  2792. if esep {
  2793. ee.WriteMapElemValue()
  2794. }
  2795. ee.EncodeFloat64(v2)
  2796. }
  2797. }
  2798. ee.WriteMapEnd()
  2799. }
  2800. func (e *Encoder) fastpathEncMapIntfBoolR(f *codecFnInfo, rv reflect.Value) {
  2801. fastpathTV.EncMapIntfBoolV(rv2i(rv).(map[interface{}]bool), e)
  2802. }
  2803. func (_ fastpathT) EncMapIntfBoolV(v map[interface{}]bool, e *Encoder) {
  2804. if v == nil {
  2805. e.e.EncodeNil()
  2806. return
  2807. }
  2808. ee, esep := e.e, e.hh.hasElemSeparators()
  2809. ee.WriteMapStart(len(v))
  2810. if e.h.Canonical {
  2811. var mksv []byte = make([]byte, 0, len(v)*16) // temporary byte slice for the encoding
  2812. e2 := NewEncoderBytes(&mksv, e.hh)
  2813. v2 := make([]bytesI, len(v))
  2814. var i, l int
  2815. var vp *bytesI
  2816. for k2, _ := range v {
  2817. l = len(mksv)
  2818. e2.MustEncode(k2)
  2819. vp = &v2[i]
  2820. vp.v = mksv[l:]
  2821. vp.i = k2
  2822. i++
  2823. }
  2824. sort.Sort(bytesISlice(v2))
  2825. for j := range v2 {
  2826. if esep {
  2827. ee.WriteMapElemKey()
  2828. }
  2829. e.asis(v2[j].v)
  2830. if esep {
  2831. ee.WriteMapElemValue()
  2832. }
  2833. e.encode(v[v2[j].i])
  2834. }
  2835. } else {
  2836. for k2, v2 := range v {
  2837. if esep {
  2838. ee.WriteMapElemKey()
  2839. }
  2840. e.encode(k2)
  2841. if esep {
  2842. ee.WriteMapElemValue()
  2843. }
  2844. ee.EncodeBool(v2)
  2845. }
  2846. }
  2847. ee.WriteMapEnd()
  2848. }
  2849. func (e *Encoder) fastpathEncMapStringIntfR(f *codecFnInfo, rv reflect.Value) {
  2850. fastpathTV.EncMapStringIntfV(rv2i(rv).(map[string]interface{}), e)
  2851. }
  2852. func (_ fastpathT) EncMapStringIntfV(v map[string]interface{}, e *Encoder) {
  2853. if v == nil {
  2854. e.e.EncodeNil()
  2855. return
  2856. }
  2857. ee, esep := e.e, e.hh.hasElemSeparators()
  2858. ee.WriteMapStart(len(v))
  2859. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  2860. if e.h.Canonical {
  2861. v2 := make([]string, len(v))
  2862. var i int
  2863. for k, _ := range v {
  2864. v2[i] = string(k)
  2865. i++
  2866. }
  2867. sort.Sort(stringSlice(v2))
  2868. for _, k2 := range v2 {
  2869. if esep {
  2870. ee.WriteMapElemKey()
  2871. }
  2872. if asSymbols {
  2873. ee.EncodeSymbol(k2)
  2874. } else {
  2875. ee.EncodeString(c_UTF8, k2)
  2876. }
  2877. if esep {
  2878. ee.WriteMapElemValue()
  2879. }
  2880. e.encode(v[string(k2)])
  2881. }
  2882. } else {
  2883. for k2, v2 := range v {
  2884. if esep {
  2885. ee.WriteMapElemKey()
  2886. }
  2887. if asSymbols {
  2888. ee.EncodeSymbol(k2)
  2889. } else {
  2890. ee.EncodeString(c_UTF8, k2)
  2891. }
  2892. if esep {
  2893. ee.WriteMapElemValue()
  2894. }
  2895. e.encode(v2)
  2896. }
  2897. }
  2898. ee.WriteMapEnd()
  2899. }
  2900. func (e *Encoder) fastpathEncMapStringStringR(f *codecFnInfo, rv reflect.Value) {
  2901. fastpathTV.EncMapStringStringV(rv2i(rv).(map[string]string), e)
  2902. }
  2903. func (_ fastpathT) EncMapStringStringV(v map[string]string, e *Encoder) {
  2904. if v == nil {
  2905. e.e.EncodeNil()
  2906. return
  2907. }
  2908. ee, esep := e.e, e.hh.hasElemSeparators()
  2909. ee.WriteMapStart(len(v))
  2910. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  2911. if e.h.Canonical {
  2912. v2 := make([]string, len(v))
  2913. var i int
  2914. for k, _ := range v {
  2915. v2[i] = string(k)
  2916. i++
  2917. }
  2918. sort.Sort(stringSlice(v2))
  2919. for _, k2 := range v2 {
  2920. if esep {
  2921. ee.WriteMapElemKey()
  2922. }
  2923. if asSymbols {
  2924. ee.EncodeSymbol(k2)
  2925. } else {
  2926. ee.EncodeString(c_UTF8, k2)
  2927. }
  2928. if esep {
  2929. ee.WriteMapElemValue()
  2930. }
  2931. ee.EncodeString(c_UTF8, v[string(k2)])
  2932. }
  2933. } else {
  2934. for k2, v2 := range v {
  2935. if esep {
  2936. ee.WriteMapElemKey()
  2937. }
  2938. if asSymbols {
  2939. ee.EncodeSymbol(k2)
  2940. } else {
  2941. ee.EncodeString(c_UTF8, k2)
  2942. }
  2943. if esep {
  2944. ee.WriteMapElemValue()
  2945. }
  2946. ee.EncodeString(c_UTF8, v2)
  2947. }
  2948. }
  2949. ee.WriteMapEnd()
  2950. }
  2951. func (e *Encoder) fastpathEncMapStringUintR(f *codecFnInfo, rv reflect.Value) {
  2952. fastpathTV.EncMapStringUintV(rv2i(rv).(map[string]uint), e)
  2953. }
  2954. func (_ fastpathT) EncMapStringUintV(v map[string]uint, e *Encoder) {
  2955. if v == nil {
  2956. e.e.EncodeNil()
  2957. return
  2958. }
  2959. ee, esep := e.e, e.hh.hasElemSeparators()
  2960. ee.WriteMapStart(len(v))
  2961. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  2962. if e.h.Canonical {
  2963. v2 := make([]string, len(v))
  2964. var i int
  2965. for k, _ := range v {
  2966. v2[i] = string(k)
  2967. i++
  2968. }
  2969. sort.Sort(stringSlice(v2))
  2970. for _, k2 := range v2 {
  2971. if esep {
  2972. ee.WriteMapElemKey()
  2973. }
  2974. if asSymbols {
  2975. ee.EncodeSymbol(k2)
  2976. } else {
  2977. ee.EncodeString(c_UTF8, k2)
  2978. }
  2979. if esep {
  2980. ee.WriteMapElemValue()
  2981. }
  2982. ee.EncodeUint(uint64(v[string(k2)]))
  2983. }
  2984. } else {
  2985. for k2, v2 := range v {
  2986. if esep {
  2987. ee.WriteMapElemKey()
  2988. }
  2989. if asSymbols {
  2990. ee.EncodeSymbol(k2)
  2991. } else {
  2992. ee.EncodeString(c_UTF8, k2)
  2993. }
  2994. if esep {
  2995. ee.WriteMapElemValue()
  2996. }
  2997. ee.EncodeUint(uint64(v2))
  2998. }
  2999. }
  3000. ee.WriteMapEnd()
  3001. }
  3002. func (e *Encoder) fastpathEncMapStringUint8R(f *codecFnInfo, rv reflect.Value) {
  3003. fastpathTV.EncMapStringUint8V(rv2i(rv).(map[string]uint8), e)
  3004. }
  3005. func (_ fastpathT) EncMapStringUint8V(v map[string]uint8, e *Encoder) {
  3006. if v == nil {
  3007. e.e.EncodeNil()
  3008. return
  3009. }
  3010. ee, esep := e.e, e.hh.hasElemSeparators()
  3011. ee.WriteMapStart(len(v))
  3012. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3013. if e.h.Canonical {
  3014. v2 := make([]string, len(v))
  3015. var i int
  3016. for k, _ := range v {
  3017. v2[i] = string(k)
  3018. i++
  3019. }
  3020. sort.Sort(stringSlice(v2))
  3021. for _, k2 := range v2 {
  3022. if esep {
  3023. ee.WriteMapElemKey()
  3024. }
  3025. if asSymbols {
  3026. ee.EncodeSymbol(k2)
  3027. } else {
  3028. ee.EncodeString(c_UTF8, k2)
  3029. }
  3030. if esep {
  3031. ee.WriteMapElemValue()
  3032. }
  3033. ee.EncodeUint(uint64(v[string(k2)]))
  3034. }
  3035. } else {
  3036. for k2, v2 := range v {
  3037. if esep {
  3038. ee.WriteMapElemKey()
  3039. }
  3040. if asSymbols {
  3041. ee.EncodeSymbol(k2)
  3042. } else {
  3043. ee.EncodeString(c_UTF8, k2)
  3044. }
  3045. if esep {
  3046. ee.WriteMapElemValue()
  3047. }
  3048. ee.EncodeUint(uint64(v2))
  3049. }
  3050. }
  3051. ee.WriteMapEnd()
  3052. }
  3053. func (e *Encoder) fastpathEncMapStringUint16R(f *codecFnInfo, rv reflect.Value) {
  3054. fastpathTV.EncMapStringUint16V(rv2i(rv).(map[string]uint16), e)
  3055. }
  3056. func (_ fastpathT) EncMapStringUint16V(v map[string]uint16, e *Encoder) {
  3057. if v == nil {
  3058. e.e.EncodeNil()
  3059. return
  3060. }
  3061. ee, esep := e.e, e.hh.hasElemSeparators()
  3062. ee.WriteMapStart(len(v))
  3063. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3064. if e.h.Canonical {
  3065. v2 := make([]string, len(v))
  3066. var i int
  3067. for k, _ := range v {
  3068. v2[i] = string(k)
  3069. i++
  3070. }
  3071. sort.Sort(stringSlice(v2))
  3072. for _, k2 := range v2 {
  3073. if esep {
  3074. ee.WriteMapElemKey()
  3075. }
  3076. if asSymbols {
  3077. ee.EncodeSymbol(k2)
  3078. } else {
  3079. ee.EncodeString(c_UTF8, k2)
  3080. }
  3081. if esep {
  3082. ee.WriteMapElemValue()
  3083. }
  3084. ee.EncodeUint(uint64(v[string(k2)]))
  3085. }
  3086. } else {
  3087. for k2, v2 := range v {
  3088. if esep {
  3089. ee.WriteMapElemKey()
  3090. }
  3091. if asSymbols {
  3092. ee.EncodeSymbol(k2)
  3093. } else {
  3094. ee.EncodeString(c_UTF8, k2)
  3095. }
  3096. if esep {
  3097. ee.WriteMapElemValue()
  3098. }
  3099. ee.EncodeUint(uint64(v2))
  3100. }
  3101. }
  3102. ee.WriteMapEnd()
  3103. }
  3104. func (e *Encoder) fastpathEncMapStringUint32R(f *codecFnInfo, rv reflect.Value) {
  3105. fastpathTV.EncMapStringUint32V(rv2i(rv).(map[string]uint32), e)
  3106. }
  3107. func (_ fastpathT) EncMapStringUint32V(v map[string]uint32, e *Encoder) {
  3108. if v == nil {
  3109. e.e.EncodeNil()
  3110. return
  3111. }
  3112. ee, esep := e.e, e.hh.hasElemSeparators()
  3113. ee.WriteMapStart(len(v))
  3114. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3115. if e.h.Canonical {
  3116. v2 := make([]string, len(v))
  3117. var i int
  3118. for k, _ := range v {
  3119. v2[i] = string(k)
  3120. i++
  3121. }
  3122. sort.Sort(stringSlice(v2))
  3123. for _, k2 := range v2 {
  3124. if esep {
  3125. ee.WriteMapElemKey()
  3126. }
  3127. if asSymbols {
  3128. ee.EncodeSymbol(k2)
  3129. } else {
  3130. ee.EncodeString(c_UTF8, k2)
  3131. }
  3132. if esep {
  3133. ee.WriteMapElemValue()
  3134. }
  3135. ee.EncodeUint(uint64(v[string(k2)]))
  3136. }
  3137. } else {
  3138. for k2, v2 := range v {
  3139. if esep {
  3140. ee.WriteMapElemKey()
  3141. }
  3142. if asSymbols {
  3143. ee.EncodeSymbol(k2)
  3144. } else {
  3145. ee.EncodeString(c_UTF8, k2)
  3146. }
  3147. if esep {
  3148. ee.WriteMapElemValue()
  3149. }
  3150. ee.EncodeUint(uint64(v2))
  3151. }
  3152. }
  3153. ee.WriteMapEnd()
  3154. }
  3155. func (e *Encoder) fastpathEncMapStringUint64R(f *codecFnInfo, rv reflect.Value) {
  3156. fastpathTV.EncMapStringUint64V(rv2i(rv).(map[string]uint64), e)
  3157. }
  3158. func (_ fastpathT) EncMapStringUint64V(v map[string]uint64, e *Encoder) {
  3159. if v == nil {
  3160. e.e.EncodeNil()
  3161. return
  3162. }
  3163. ee, esep := e.e, e.hh.hasElemSeparators()
  3164. ee.WriteMapStart(len(v))
  3165. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3166. if e.h.Canonical {
  3167. v2 := make([]string, len(v))
  3168. var i int
  3169. for k, _ := range v {
  3170. v2[i] = string(k)
  3171. i++
  3172. }
  3173. sort.Sort(stringSlice(v2))
  3174. for _, k2 := range v2 {
  3175. if esep {
  3176. ee.WriteMapElemKey()
  3177. }
  3178. if asSymbols {
  3179. ee.EncodeSymbol(k2)
  3180. } else {
  3181. ee.EncodeString(c_UTF8, k2)
  3182. }
  3183. if esep {
  3184. ee.WriteMapElemValue()
  3185. }
  3186. ee.EncodeUint(uint64(v[string(k2)]))
  3187. }
  3188. } else {
  3189. for k2, v2 := range v {
  3190. if esep {
  3191. ee.WriteMapElemKey()
  3192. }
  3193. if asSymbols {
  3194. ee.EncodeSymbol(k2)
  3195. } else {
  3196. ee.EncodeString(c_UTF8, k2)
  3197. }
  3198. if esep {
  3199. ee.WriteMapElemValue()
  3200. }
  3201. ee.EncodeUint(uint64(v2))
  3202. }
  3203. }
  3204. ee.WriteMapEnd()
  3205. }
  3206. func (e *Encoder) fastpathEncMapStringUintptrR(f *codecFnInfo, rv reflect.Value) {
  3207. fastpathTV.EncMapStringUintptrV(rv2i(rv).(map[string]uintptr), e)
  3208. }
  3209. func (_ fastpathT) EncMapStringUintptrV(v map[string]uintptr, e *Encoder) {
  3210. if v == nil {
  3211. e.e.EncodeNil()
  3212. return
  3213. }
  3214. ee, esep := e.e, e.hh.hasElemSeparators()
  3215. ee.WriteMapStart(len(v))
  3216. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3217. if e.h.Canonical {
  3218. v2 := make([]string, len(v))
  3219. var i int
  3220. for k, _ := range v {
  3221. v2[i] = string(k)
  3222. i++
  3223. }
  3224. sort.Sort(stringSlice(v2))
  3225. for _, k2 := range v2 {
  3226. if esep {
  3227. ee.WriteMapElemKey()
  3228. }
  3229. if asSymbols {
  3230. ee.EncodeSymbol(k2)
  3231. } else {
  3232. ee.EncodeString(c_UTF8, k2)
  3233. }
  3234. if esep {
  3235. ee.WriteMapElemValue()
  3236. }
  3237. e.encode(v[string(k2)])
  3238. }
  3239. } else {
  3240. for k2, v2 := range v {
  3241. if esep {
  3242. ee.WriteMapElemKey()
  3243. }
  3244. if asSymbols {
  3245. ee.EncodeSymbol(k2)
  3246. } else {
  3247. ee.EncodeString(c_UTF8, k2)
  3248. }
  3249. if esep {
  3250. ee.WriteMapElemValue()
  3251. }
  3252. e.encode(v2)
  3253. }
  3254. }
  3255. ee.WriteMapEnd()
  3256. }
  3257. func (e *Encoder) fastpathEncMapStringIntR(f *codecFnInfo, rv reflect.Value) {
  3258. fastpathTV.EncMapStringIntV(rv2i(rv).(map[string]int), e)
  3259. }
  3260. func (_ fastpathT) EncMapStringIntV(v map[string]int, e *Encoder) {
  3261. if v == nil {
  3262. e.e.EncodeNil()
  3263. return
  3264. }
  3265. ee, esep := e.e, e.hh.hasElemSeparators()
  3266. ee.WriteMapStart(len(v))
  3267. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3268. if e.h.Canonical {
  3269. v2 := make([]string, len(v))
  3270. var i int
  3271. for k, _ := range v {
  3272. v2[i] = string(k)
  3273. i++
  3274. }
  3275. sort.Sort(stringSlice(v2))
  3276. for _, k2 := range v2 {
  3277. if esep {
  3278. ee.WriteMapElemKey()
  3279. }
  3280. if asSymbols {
  3281. ee.EncodeSymbol(k2)
  3282. } else {
  3283. ee.EncodeString(c_UTF8, k2)
  3284. }
  3285. if esep {
  3286. ee.WriteMapElemValue()
  3287. }
  3288. ee.EncodeInt(int64(v[string(k2)]))
  3289. }
  3290. } else {
  3291. for k2, v2 := range v {
  3292. if esep {
  3293. ee.WriteMapElemKey()
  3294. }
  3295. if asSymbols {
  3296. ee.EncodeSymbol(k2)
  3297. } else {
  3298. ee.EncodeString(c_UTF8, k2)
  3299. }
  3300. if esep {
  3301. ee.WriteMapElemValue()
  3302. }
  3303. ee.EncodeInt(int64(v2))
  3304. }
  3305. }
  3306. ee.WriteMapEnd()
  3307. }
  3308. func (e *Encoder) fastpathEncMapStringInt8R(f *codecFnInfo, rv reflect.Value) {
  3309. fastpathTV.EncMapStringInt8V(rv2i(rv).(map[string]int8), e)
  3310. }
  3311. func (_ fastpathT) EncMapStringInt8V(v map[string]int8, e *Encoder) {
  3312. if v == nil {
  3313. e.e.EncodeNil()
  3314. return
  3315. }
  3316. ee, esep := e.e, e.hh.hasElemSeparators()
  3317. ee.WriteMapStart(len(v))
  3318. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3319. if e.h.Canonical {
  3320. v2 := make([]string, len(v))
  3321. var i int
  3322. for k, _ := range v {
  3323. v2[i] = string(k)
  3324. i++
  3325. }
  3326. sort.Sort(stringSlice(v2))
  3327. for _, k2 := range v2 {
  3328. if esep {
  3329. ee.WriteMapElemKey()
  3330. }
  3331. if asSymbols {
  3332. ee.EncodeSymbol(k2)
  3333. } else {
  3334. ee.EncodeString(c_UTF8, k2)
  3335. }
  3336. if esep {
  3337. ee.WriteMapElemValue()
  3338. }
  3339. ee.EncodeInt(int64(v[string(k2)]))
  3340. }
  3341. } else {
  3342. for k2, v2 := range v {
  3343. if esep {
  3344. ee.WriteMapElemKey()
  3345. }
  3346. if asSymbols {
  3347. ee.EncodeSymbol(k2)
  3348. } else {
  3349. ee.EncodeString(c_UTF8, k2)
  3350. }
  3351. if esep {
  3352. ee.WriteMapElemValue()
  3353. }
  3354. ee.EncodeInt(int64(v2))
  3355. }
  3356. }
  3357. ee.WriteMapEnd()
  3358. }
  3359. func (e *Encoder) fastpathEncMapStringInt16R(f *codecFnInfo, rv reflect.Value) {
  3360. fastpathTV.EncMapStringInt16V(rv2i(rv).(map[string]int16), e)
  3361. }
  3362. func (_ fastpathT) EncMapStringInt16V(v map[string]int16, e *Encoder) {
  3363. if v == nil {
  3364. e.e.EncodeNil()
  3365. return
  3366. }
  3367. ee, esep := e.e, e.hh.hasElemSeparators()
  3368. ee.WriteMapStart(len(v))
  3369. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3370. if e.h.Canonical {
  3371. v2 := make([]string, len(v))
  3372. var i int
  3373. for k, _ := range v {
  3374. v2[i] = string(k)
  3375. i++
  3376. }
  3377. sort.Sort(stringSlice(v2))
  3378. for _, k2 := range v2 {
  3379. if esep {
  3380. ee.WriteMapElemKey()
  3381. }
  3382. if asSymbols {
  3383. ee.EncodeSymbol(k2)
  3384. } else {
  3385. ee.EncodeString(c_UTF8, k2)
  3386. }
  3387. if esep {
  3388. ee.WriteMapElemValue()
  3389. }
  3390. ee.EncodeInt(int64(v[string(k2)]))
  3391. }
  3392. } else {
  3393. for k2, v2 := range v {
  3394. if esep {
  3395. ee.WriteMapElemKey()
  3396. }
  3397. if asSymbols {
  3398. ee.EncodeSymbol(k2)
  3399. } else {
  3400. ee.EncodeString(c_UTF8, k2)
  3401. }
  3402. if esep {
  3403. ee.WriteMapElemValue()
  3404. }
  3405. ee.EncodeInt(int64(v2))
  3406. }
  3407. }
  3408. ee.WriteMapEnd()
  3409. }
  3410. func (e *Encoder) fastpathEncMapStringInt32R(f *codecFnInfo, rv reflect.Value) {
  3411. fastpathTV.EncMapStringInt32V(rv2i(rv).(map[string]int32), e)
  3412. }
  3413. func (_ fastpathT) EncMapStringInt32V(v map[string]int32, e *Encoder) {
  3414. if v == nil {
  3415. e.e.EncodeNil()
  3416. return
  3417. }
  3418. ee, esep := e.e, e.hh.hasElemSeparators()
  3419. ee.WriteMapStart(len(v))
  3420. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3421. if e.h.Canonical {
  3422. v2 := make([]string, len(v))
  3423. var i int
  3424. for k, _ := range v {
  3425. v2[i] = string(k)
  3426. i++
  3427. }
  3428. sort.Sort(stringSlice(v2))
  3429. for _, k2 := range v2 {
  3430. if esep {
  3431. ee.WriteMapElemKey()
  3432. }
  3433. if asSymbols {
  3434. ee.EncodeSymbol(k2)
  3435. } else {
  3436. ee.EncodeString(c_UTF8, k2)
  3437. }
  3438. if esep {
  3439. ee.WriteMapElemValue()
  3440. }
  3441. ee.EncodeInt(int64(v[string(k2)]))
  3442. }
  3443. } else {
  3444. for k2, v2 := range v {
  3445. if esep {
  3446. ee.WriteMapElemKey()
  3447. }
  3448. if asSymbols {
  3449. ee.EncodeSymbol(k2)
  3450. } else {
  3451. ee.EncodeString(c_UTF8, k2)
  3452. }
  3453. if esep {
  3454. ee.WriteMapElemValue()
  3455. }
  3456. ee.EncodeInt(int64(v2))
  3457. }
  3458. }
  3459. ee.WriteMapEnd()
  3460. }
  3461. func (e *Encoder) fastpathEncMapStringInt64R(f *codecFnInfo, rv reflect.Value) {
  3462. fastpathTV.EncMapStringInt64V(rv2i(rv).(map[string]int64), e)
  3463. }
  3464. func (_ fastpathT) EncMapStringInt64V(v map[string]int64, e *Encoder) {
  3465. if v == nil {
  3466. e.e.EncodeNil()
  3467. return
  3468. }
  3469. ee, esep := e.e, e.hh.hasElemSeparators()
  3470. ee.WriteMapStart(len(v))
  3471. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3472. if e.h.Canonical {
  3473. v2 := make([]string, len(v))
  3474. var i int
  3475. for k, _ := range v {
  3476. v2[i] = string(k)
  3477. i++
  3478. }
  3479. sort.Sort(stringSlice(v2))
  3480. for _, k2 := range v2 {
  3481. if esep {
  3482. ee.WriteMapElemKey()
  3483. }
  3484. if asSymbols {
  3485. ee.EncodeSymbol(k2)
  3486. } else {
  3487. ee.EncodeString(c_UTF8, k2)
  3488. }
  3489. if esep {
  3490. ee.WriteMapElemValue()
  3491. }
  3492. ee.EncodeInt(int64(v[string(k2)]))
  3493. }
  3494. } else {
  3495. for k2, v2 := range v {
  3496. if esep {
  3497. ee.WriteMapElemKey()
  3498. }
  3499. if asSymbols {
  3500. ee.EncodeSymbol(k2)
  3501. } else {
  3502. ee.EncodeString(c_UTF8, k2)
  3503. }
  3504. if esep {
  3505. ee.WriteMapElemValue()
  3506. }
  3507. ee.EncodeInt(int64(v2))
  3508. }
  3509. }
  3510. ee.WriteMapEnd()
  3511. }
  3512. func (e *Encoder) fastpathEncMapStringFloat32R(f *codecFnInfo, rv reflect.Value) {
  3513. fastpathTV.EncMapStringFloat32V(rv2i(rv).(map[string]float32), e)
  3514. }
  3515. func (_ fastpathT) EncMapStringFloat32V(v map[string]float32, e *Encoder) {
  3516. if v == nil {
  3517. e.e.EncodeNil()
  3518. return
  3519. }
  3520. ee, esep := e.e, e.hh.hasElemSeparators()
  3521. ee.WriteMapStart(len(v))
  3522. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3523. if e.h.Canonical {
  3524. v2 := make([]string, len(v))
  3525. var i int
  3526. for k, _ := range v {
  3527. v2[i] = string(k)
  3528. i++
  3529. }
  3530. sort.Sort(stringSlice(v2))
  3531. for _, k2 := range v2 {
  3532. if esep {
  3533. ee.WriteMapElemKey()
  3534. }
  3535. if asSymbols {
  3536. ee.EncodeSymbol(k2)
  3537. } else {
  3538. ee.EncodeString(c_UTF8, k2)
  3539. }
  3540. if esep {
  3541. ee.WriteMapElemValue()
  3542. }
  3543. ee.EncodeFloat32(v[string(k2)])
  3544. }
  3545. } else {
  3546. for k2, v2 := range v {
  3547. if esep {
  3548. ee.WriteMapElemKey()
  3549. }
  3550. if asSymbols {
  3551. ee.EncodeSymbol(k2)
  3552. } else {
  3553. ee.EncodeString(c_UTF8, k2)
  3554. }
  3555. if esep {
  3556. ee.WriteMapElemValue()
  3557. }
  3558. ee.EncodeFloat32(v2)
  3559. }
  3560. }
  3561. ee.WriteMapEnd()
  3562. }
  3563. func (e *Encoder) fastpathEncMapStringFloat64R(f *codecFnInfo, rv reflect.Value) {
  3564. fastpathTV.EncMapStringFloat64V(rv2i(rv).(map[string]float64), e)
  3565. }
  3566. func (_ fastpathT) EncMapStringFloat64V(v map[string]float64, e *Encoder) {
  3567. if v == nil {
  3568. e.e.EncodeNil()
  3569. return
  3570. }
  3571. ee, esep := e.e, e.hh.hasElemSeparators()
  3572. ee.WriteMapStart(len(v))
  3573. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3574. if e.h.Canonical {
  3575. v2 := make([]string, len(v))
  3576. var i int
  3577. for k, _ := range v {
  3578. v2[i] = string(k)
  3579. i++
  3580. }
  3581. sort.Sort(stringSlice(v2))
  3582. for _, k2 := range v2 {
  3583. if esep {
  3584. ee.WriteMapElemKey()
  3585. }
  3586. if asSymbols {
  3587. ee.EncodeSymbol(k2)
  3588. } else {
  3589. ee.EncodeString(c_UTF8, k2)
  3590. }
  3591. if esep {
  3592. ee.WriteMapElemValue()
  3593. }
  3594. ee.EncodeFloat64(v[string(k2)])
  3595. }
  3596. } else {
  3597. for k2, v2 := range v {
  3598. if esep {
  3599. ee.WriteMapElemKey()
  3600. }
  3601. if asSymbols {
  3602. ee.EncodeSymbol(k2)
  3603. } else {
  3604. ee.EncodeString(c_UTF8, k2)
  3605. }
  3606. if esep {
  3607. ee.WriteMapElemValue()
  3608. }
  3609. ee.EncodeFloat64(v2)
  3610. }
  3611. }
  3612. ee.WriteMapEnd()
  3613. }
  3614. func (e *Encoder) fastpathEncMapStringBoolR(f *codecFnInfo, rv reflect.Value) {
  3615. fastpathTV.EncMapStringBoolV(rv2i(rv).(map[string]bool), e)
  3616. }
  3617. func (_ fastpathT) EncMapStringBoolV(v map[string]bool, e *Encoder) {
  3618. if v == nil {
  3619. e.e.EncodeNil()
  3620. return
  3621. }
  3622. ee, esep := e.e, e.hh.hasElemSeparators()
  3623. ee.WriteMapStart(len(v))
  3624. asSymbols := e.h.AsSymbols&AsSymbolMapStringKeysFlag != 0
  3625. if e.h.Canonical {
  3626. v2 := make([]string, len(v))
  3627. var i int
  3628. for k, _ := range v {
  3629. v2[i] = string(k)
  3630. i++
  3631. }
  3632. sort.Sort(stringSlice(v2))
  3633. for _, k2 := range v2 {
  3634. if esep {
  3635. ee.WriteMapElemKey()
  3636. }
  3637. if asSymbols {
  3638. ee.EncodeSymbol(k2)
  3639. } else {
  3640. ee.EncodeString(c_UTF8, k2)
  3641. }
  3642. if esep {
  3643. ee.WriteMapElemValue()
  3644. }
  3645. ee.EncodeBool(v[string(k2)])
  3646. }
  3647. } else {
  3648. for k2, v2 := range v {
  3649. if esep {
  3650. ee.WriteMapElemKey()
  3651. }
  3652. if asSymbols {
  3653. ee.EncodeSymbol(k2)
  3654. } else {
  3655. ee.EncodeString(c_UTF8, k2)
  3656. }
  3657. if esep {
  3658. ee.WriteMapElemValue()
  3659. }
  3660. ee.EncodeBool(v2)
  3661. }
  3662. }
  3663. ee.WriteMapEnd()
  3664. }
  3665. func (e *Encoder) fastpathEncMapFloat32IntfR(f *codecFnInfo, rv reflect.Value) {
  3666. fastpathTV.EncMapFloat32IntfV(rv2i(rv).(map[float32]interface{}), e)
  3667. }
  3668. func (_ fastpathT) EncMapFloat32IntfV(v map[float32]interface{}, e *Encoder) {
  3669. if v == nil {
  3670. e.e.EncodeNil()
  3671. return
  3672. }
  3673. ee, esep := e.e, e.hh.hasElemSeparators()
  3674. ee.WriteMapStart(len(v))
  3675. if e.h.Canonical {
  3676. v2 := make([]float64, len(v))
  3677. var i int
  3678. for k, _ := range v {
  3679. v2[i] = float64(k)
  3680. i++
  3681. }
  3682. sort.Sort(floatSlice(v2))
  3683. for _, k2 := range v2 {
  3684. if esep {
  3685. ee.WriteMapElemKey()
  3686. }
  3687. ee.EncodeFloat32(float32(k2))
  3688. if esep {
  3689. ee.WriteMapElemValue()
  3690. }
  3691. e.encode(v[float32(k2)])
  3692. }
  3693. } else {
  3694. for k2, v2 := range v {
  3695. if esep {
  3696. ee.WriteMapElemKey()
  3697. }
  3698. ee.EncodeFloat32(k2)
  3699. if esep {
  3700. ee.WriteMapElemValue()
  3701. }
  3702. e.encode(v2)
  3703. }
  3704. }
  3705. ee.WriteMapEnd()
  3706. }
  3707. func (e *Encoder) fastpathEncMapFloat32StringR(f *codecFnInfo, rv reflect.Value) {
  3708. fastpathTV.EncMapFloat32StringV(rv2i(rv).(map[float32]string), e)
  3709. }
  3710. func (_ fastpathT) EncMapFloat32StringV(v map[float32]string, e *Encoder) {
  3711. if v == nil {
  3712. e.e.EncodeNil()
  3713. return
  3714. }
  3715. ee, esep := e.e, e.hh.hasElemSeparators()
  3716. ee.WriteMapStart(len(v))
  3717. if e.h.Canonical {
  3718. v2 := make([]float64, len(v))
  3719. var i int
  3720. for k, _ := range v {
  3721. v2[i] = float64(k)
  3722. i++
  3723. }
  3724. sort.Sort(floatSlice(v2))
  3725. for _, k2 := range v2 {
  3726. if esep {
  3727. ee.WriteMapElemKey()
  3728. }
  3729. ee.EncodeFloat32(float32(k2))
  3730. if esep {
  3731. ee.WriteMapElemValue()
  3732. }
  3733. ee.EncodeString(c_UTF8, v[float32(k2)])
  3734. }
  3735. } else {
  3736. for k2, v2 := range v {
  3737. if esep {
  3738. ee.WriteMapElemKey()
  3739. }
  3740. ee.EncodeFloat32(k2)
  3741. if esep {
  3742. ee.WriteMapElemValue()
  3743. }
  3744. ee.EncodeString(c_UTF8, v2)
  3745. }
  3746. }
  3747. ee.WriteMapEnd()
  3748. }
  3749. func (e *Encoder) fastpathEncMapFloat32UintR(f *codecFnInfo, rv reflect.Value) {
  3750. fastpathTV.EncMapFloat32UintV(rv2i(rv).(map[float32]uint), e)
  3751. }
  3752. func (_ fastpathT) EncMapFloat32UintV(v map[float32]uint, e *Encoder) {
  3753. if v == nil {
  3754. e.e.EncodeNil()
  3755. return
  3756. }
  3757. ee, esep := e.e, e.hh.hasElemSeparators()
  3758. ee.WriteMapStart(len(v))
  3759. if e.h.Canonical {
  3760. v2 := make([]float64, len(v))
  3761. var i int
  3762. for k, _ := range v {
  3763. v2[i] = float64(k)
  3764. i++
  3765. }
  3766. sort.Sort(floatSlice(v2))
  3767. for _, k2 := range v2 {
  3768. if esep {
  3769. ee.WriteMapElemKey()
  3770. }
  3771. ee.EncodeFloat32(float32(k2))
  3772. if esep {
  3773. ee.WriteMapElemValue()
  3774. }
  3775. ee.EncodeUint(uint64(v[float32(k2)]))
  3776. }
  3777. } else {
  3778. for k2, v2 := range v {
  3779. if esep {
  3780. ee.WriteMapElemKey()
  3781. }
  3782. ee.EncodeFloat32(k2)
  3783. if esep {
  3784. ee.WriteMapElemValue()
  3785. }
  3786. ee.EncodeUint(uint64(v2))
  3787. }
  3788. }
  3789. ee.WriteMapEnd()
  3790. }
  3791. func (e *Encoder) fastpathEncMapFloat32Uint8R(f *codecFnInfo, rv reflect.Value) {
  3792. fastpathTV.EncMapFloat32Uint8V(rv2i(rv).(map[float32]uint8), e)
  3793. }
  3794. func (_ fastpathT) EncMapFloat32Uint8V(v map[float32]uint8, e *Encoder) {
  3795. if v == nil {
  3796. e.e.EncodeNil()
  3797. return
  3798. }
  3799. ee, esep := e.e, e.hh.hasElemSeparators()
  3800. ee.WriteMapStart(len(v))
  3801. if e.h.Canonical {
  3802. v2 := make([]float64, len(v))
  3803. var i int
  3804. for k, _ := range v {
  3805. v2[i] = float64(k)
  3806. i++
  3807. }
  3808. sort.Sort(floatSlice(v2))
  3809. for _, k2 := range v2 {
  3810. if esep {
  3811. ee.WriteMapElemKey()
  3812. }
  3813. ee.EncodeFloat32(float32(k2))
  3814. if esep {
  3815. ee.WriteMapElemValue()
  3816. }
  3817. ee.EncodeUint(uint64(v[float32(k2)]))
  3818. }
  3819. } else {
  3820. for k2, v2 := range v {
  3821. if esep {
  3822. ee.WriteMapElemKey()
  3823. }
  3824. ee.EncodeFloat32(k2)
  3825. if esep {
  3826. ee.WriteMapElemValue()
  3827. }
  3828. ee.EncodeUint(uint64(v2))
  3829. }
  3830. }
  3831. ee.WriteMapEnd()
  3832. }
  3833. func (e *Encoder) fastpathEncMapFloat32Uint16R(f *codecFnInfo, rv reflect.Value) {
  3834. fastpathTV.EncMapFloat32Uint16V(rv2i(rv).(map[float32]uint16), e)
  3835. }
  3836. func (_ fastpathT) EncMapFloat32Uint16V(v map[float32]uint16, e *Encoder) {
  3837. if v == nil {
  3838. e.e.EncodeNil()
  3839. return
  3840. }
  3841. ee, esep := e.e, e.hh.hasElemSeparators()
  3842. ee.WriteMapStart(len(v))
  3843. if e.h.Canonical {
  3844. v2 := make([]float64, len(v))
  3845. var i int
  3846. for k, _ := range v {
  3847. v2[i] = float64(k)
  3848. i++
  3849. }
  3850. sort.Sort(floatSlice(v2))
  3851. for _, k2 := range v2 {
  3852. if esep {
  3853. ee.WriteMapElemKey()
  3854. }
  3855. ee.EncodeFloat32(float32(k2))
  3856. if esep {
  3857. ee.WriteMapElemValue()
  3858. }
  3859. ee.EncodeUint(uint64(v[float32(k2)]))
  3860. }
  3861. } else {
  3862. for k2, v2 := range v {
  3863. if esep {
  3864. ee.WriteMapElemKey()
  3865. }
  3866. ee.EncodeFloat32(k2)
  3867. if esep {
  3868. ee.WriteMapElemValue()
  3869. }
  3870. ee.EncodeUint(uint64(v2))
  3871. }
  3872. }
  3873. ee.WriteMapEnd()
  3874. }
  3875. func (e *Encoder) fastpathEncMapFloat32Uint32R(f *codecFnInfo, rv reflect.Value) {
  3876. fastpathTV.EncMapFloat32Uint32V(rv2i(rv).(map[float32]uint32), e)
  3877. }
  3878. func (_ fastpathT) EncMapFloat32Uint32V(v map[float32]uint32, e *Encoder) {
  3879. if v == nil {
  3880. e.e.EncodeNil()
  3881. return
  3882. }
  3883. ee, esep := e.e, e.hh.hasElemSeparators()
  3884. ee.WriteMapStart(len(v))
  3885. if e.h.Canonical {
  3886. v2 := make([]float64, len(v))
  3887. var i int
  3888. for k, _ := range v {
  3889. v2[i] = float64(k)
  3890. i++
  3891. }
  3892. sort.Sort(floatSlice(v2))
  3893. for _, k2 := range v2 {
  3894. if esep {
  3895. ee.WriteMapElemKey()
  3896. }
  3897. ee.EncodeFloat32(float32(k2))
  3898. if esep {
  3899. ee.WriteMapElemValue()
  3900. }
  3901. ee.EncodeUint(uint64(v[float32(k2)]))
  3902. }
  3903. } else {
  3904. for k2, v2 := range v {
  3905. if esep {
  3906. ee.WriteMapElemKey()
  3907. }
  3908. ee.EncodeFloat32(k2)
  3909. if esep {
  3910. ee.WriteMapElemValue()
  3911. }
  3912. ee.EncodeUint(uint64(v2))
  3913. }
  3914. }
  3915. ee.WriteMapEnd()
  3916. }
  3917. func (e *Encoder) fastpathEncMapFloat32Uint64R(f *codecFnInfo, rv reflect.Value) {
  3918. fastpathTV.EncMapFloat32Uint64V(rv2i(rv).(map[float32]uint64), e)
  3919. }
  3920. func (_ fastpathT) EncMapFloat32Uint64V(v map[float32]uint64, e *Encoder) {
  3921. if v == nil {
  3922. e.e.EncodeNil()
  3923. return
  3924. }
  3925. ee, esep := e.e, e.hh.hasElemSeparators()
  3926. ee.WriteMapStart(len(v))
  3927. if e.h.Canonical {
  3928. v2 := make([]float64, len(v))
  3929. var i int
  3930. for k, _ := range v {
  3931. v2[i] = float64(k)
  3932. i++
  3933. }
  3934. sort.Sort(floatSlice(v2))
  3935. for _, k2 := range v2 {
  3936. if esep {
  3937. ee.WriteMapElemKey()
  3938. }
  3939. ee.EncodeFloat32(float32(k2))
  3940. if esep {
  3941. ee.WriteMapElemValue()
  3942. }
  3943. ee.EncodeUint(uint64(v[float32(k2)]))
  3944. }
  3945. } else {
  3946. for k2, v2 := range v {
  3947. if esep {
  3948. ee.WriteMapElemKey()
  3949. }
  3950. ee.EncodeFloat32(k2)
  3951. if esep {
  3952. ee.WriteMapElemValue()
  3953. }
  3954. ee.EncodeUint(uint64(v2))
  3955. }
  3956. }
  3957. ee.WriteMapEnd()
  3958. }
  3959. func (e *Encoder) fastpathEncMapFloat32UintptrR(f *codecFnInfo, rv reflect.Value) {
  3960. fastpathTV.EncMapFloat32UintptrV(rv2i(rv).(map[float32]uintptr), e)
  3961. }
  3962. func (_ fastpathT) EncMapFloat32UintptrV(v map[float32]uintptr, e *Encoder) {
  3963. if v == nil {
  3964. e.e.EncodeNil()
  3965. return
  3966. }
  3967. ee, esep := e.e, e.hh.hasElemSeparators()
  3968. ee.WriteMapStart(len(v))
  3969. if e.h.Canonical {
  3970. v2 := make([]float64, len(v))
  3971. var i int
  3972. for k, _ := range v {
  3973. v2[i] = float64(k)
  3974. i++
  3975. }
  3976. sort.Sort(floatSlice(v2))
  3977. for _, k2 := range v2 {
  3978. if esep {
  3979. ee.WriteMapElemKey()
  3980. }
  3981. ee.EncodeFloat32(float32(k2))
  3982. if esep {
  3983. ee.WriteMapElemValue()
  3984. }
  3985. e.encode(v[float32(k2)])
  3986. }
  3987. } else {
  3988. for k2, v2 := range v {
  3989. if esep {
  3990. ee.WriteMapElemKey()
  3991. }
  3992. ee.EncodeFloat32(k2)
  3993. if esep {
  3994. ee.WriteMapElemValue()
  3995. }
  3996. e.encode(v2)
  3997. }
  3998. }
  3999. ee.WriteMapEnd()
  4000. }
  4001. func (e *Encoder) fastpathEncMapFloat32IntR(f *codecFnInfo, rv reflect.Value) {
  4002. fastpathTV.EncMapFloat32IntV(rv2i(rv).(map[float32]int), e)
  4003. }
  4004. func (_ fastpathT) EncMapFloat32IntV(v map[float32]int, e *Encoder) {
  4005. if v == nil {
  4006. e.e.EncodeNil()
  4007. return
  4008. }
  4009. ee, esep := e.e, e.hh.hasElemSeparators()
  4010. ee.WriteMapStart(len(v))
  4011. if e.h.Canonical {
  4012. v2 := make([]float64, len(v))
  4013. var i int
  4014. for k, _ := range v {
  4015. v2[i] = float64(k)
  4016. i++
  4017. }
  4018. sort.Sort(floatSlice(v2))
  4019. for _, k2 := range v2 {
  4020. if esep {
  4021. ee.WriteMapElemKey()
  4022. }
  4023. ee.EncodeFloat32(float32(k2))
  4024. if esep {
  4025. ee.WriteMapElemValue()
  4026. }
  4027. ee.EncodeInt(int64(v[float32(k2)]))
  4028. }
  4029. } else {
  4030. for k2, v2 := range v {
  4031. if esep {
  4032. ee.WriteMapElemKey()
  4033. }
  4034. ee.EncodeFloat32(k2)
  4035. if esep {
  4036. ee.WriteMapElemValue()
  4037. }
  4038. ee.EncodeInt(int64(v2))
  4039. }
  4040. }
  4041. ee.WriteMapEnd()
  4042. }
  4043. func (e *Encoder) fastpathEncMapFloat32Int8R(f *codecFnInfo, rv reflect.Value) {
  4044. fastpathTV.EncMapFloat32Int8V(rv2i(rv).(map[float32]int8), e)
  4045. }
  4046. func (_ fastpathT) EncMapFloat32Int8V(v map[float32]int8, e *Encoder) {
  4047. if v == nil {
  4048. e.e.EncodeNil()
  4049. return
  4050. }
  4051. ee, esep := e.e, e.hh.hasElemSeparators()
  4052. ee.WriteMapStart(len(v))
  4053. if e.h.Canonical {
  4054. v2 := make([]float64, len(v))
  4055. var i int
  4056. for k, _ := range v {
  4057. v2[i] = float64(k)
  4058. i++
  4059. }
  4060. sort.Sort(floatSlice(v2))
  4061. for _, k2 := range v2 {
  4062. if esep {
  4063. ee.WriteMapElemKey()
  4064. }
  4065. ee.EncodeFloat32(float32(k2))
  4066. if esep {
  4067. ee.WriteMapElemValue()
  4068. }
  4069. ee.EncodeInt(int64(v[float32(k2)]))
  4070. }
  4071. } else {
  4072. for k2, v2 := range v {
  4073. if esep {
  4074. ee.WriteMapElemKey()
  4075. }
  4076. ee.EncodeFloat32(k2)
  4077. if esep {
  4078. ee.WriteMapElemValue()
  4079. }
  4080. ee.EncodeInt(int64(v2))
  4081. }
  4082. }
  4083. ee.WriteMapEnd()
  4084. }
  4085. func (e *Encoder) fastpathEncMapFloat32Int16R(f *codecFnInfo, rv reflect.Value) {
  4086. fastpathTV.EncMapFloat32Int16V(rv2i(rv).(map[float32]int16), e)
  4087. }
  4088. func (_ fastpathT) EncMapFloat32Int16V(v map[float32]int16, e *Encoder) {
  4089. if v == nil {
  4090. e.e.EncodeNil()
  4091. return
  4092. }
  4093. ee, esep := e.e, e.hh.hasElemSeparators()
  4094. ee.WriteMapStart(len(v))
  4095. if e.h.Canonical {
  4096. v2 := make([]float64, len(v))
  4097. var i int
  4098. for k, _ := range v {
  4099. v2[i] = float64(k)
  4100. i++
  4101. }
  4102. sort.Sort(floatSlice(v2))
  4103. for _, k2 := range v2 {
  4104. if esep {
  4105. ee.WriteMapElemKey()
  4106. }
  4107. ee.EncodeFloat32(float32(k2))
  4108. if esep {
  4109. ee.WriteMapElemValue()
  4110. }
  4111. ee.EncodeInt(int64(v[float32(k2)]))
  4112. }
  4113. } else {
  4114. for k2, v2 := range v {
  4115. if esep {
  4116. ee.WriteMapElemKey()
  4117. }
  4118. ee.EncodeFloat32(k2)
  4119. if esep {
  4120. ee.WriteMapElemValue()
  4121. }
  4122. ee.EncodeInt(int64(v2))
  4123. }
  4124. }
  4125. ee.WriteMapEnd()
  4126. }
  4127. func (e *Encoder) fastpathEncMapFloat32Int32R(f *codecFnInfo, rv reflect.Value) {
  4128. fastpathTV.EncMapFloat32Int32V(rv2i(rv).(map[float32]int32), e)
  4129. }
  4130. func (_ fastpathT) EncMapFloat32Int32V(v map[float32]int32, e *Encoder) {
  4131. if v == nil {
  4132. e.e.EncodeNil()
  4133. return
  4134. }
  4135. ee, esep := e.e, e.hh.hasElemSeparators()
  4136. ee.WriteMapStart(len(v))
  4137. if e.h.Canonical {
  4138. v2 := make([]float64, len(v))
  4139. var i int
  4140. for k, _ := range v {
  4141. v2[i] = float64(k)
  4142. i++
  4143. }
  4144. sort.Sort(floatSlice(v2))
  4145. for _, k2 := range v2 {
  4146. if esep {
  4147. ee.WriteMapElemKey()
  4148. }
  4149. ee.EncodeFloat32(float32(k2))
  4150. if esep {
  4151. ee.WriteMapElemValue()
  4152. }
  4153. ee.EncodeInt(int64(v[float32(k2)]))
  4154. }
  4155. } else {
  4156. for k2, v2 := range v {
  4157. if esep {
  4158. ee.WriteMapElemKey()
  4159. }
  4160. ee.EncodeFloat32(k2)
  4161. if esep {
  4162. ee.WriteMapElemValue()
  4163. }
  4164. ee.EncodeInt(int64(v2))
  4165. }
  4166. }
  4167. ee.WriteMapEnd()
  4168. }
  4169. func (e *Encoder) fastpathEncMapFloat32Int64R(f *codecFnInfo, rv reflect.Value) {
  4170. fastpathTV.EncMapFloat32Int64V(rv2i(rv).(map[float32]int64), e)
  4171. }
  4172. func (_ fastpathT) EncMapFloat32Int64V(v map[float32]int64, e *Encoder) {
  4173. if v == nil {
  4174. e.e.EncodeNil()
  4175. return
  4176. }
  4177. ee, esep := e.e, e.hh.hasElemSeparators()
  4178. ee.WriteMapStart(len(v))
  4179. if e.h.Canonical {
  4180. v2 := make([]float64, len(v))
  4181. var i int
  4182. for k, _ := range v {
  4183. v2[i] = float64(k)
  4184. i++
  4185. }
  4186. sort.Sort(floatSlice(v2))
  4187. for _, k2 := range v2 {
  4188. if esep {
  4189. ee.WriteMapElemKey()
  4190. }
  4191. ee.EncodeFloat32(float32(k2))
  4192. if esep {
  4193. ee.WriteMapElemValue()
  4194. }
  4195. ee.EncodeInt(int64(v[float32(k2)]))
  4196. }
  4197. } else {
  4198. for k2, v2 := range v {
  4199. if esep {
  4200. ee.WriteMapElemKey()
  4201. }
  4202. ee.EncodeFloat32(k2)
  4203. if esep {
  4204. ee.WriteMapElemValue()
  4205. }
  4206. ee.EncodeInt(int64(v2))
  4207. }
  4208. }
  4209. ee.WriteMapEnd()
  4210. }
  4211. func (e *Encoder) fastpathEncMapFloat32Float32R(f *codecFnInfo, rv reflect.Value) {
  4212. fastpathTV.EncMapFloat32Float32V(rv2i(rv).(map[float32]float32), e)
  4213. }
  4214. func (_ fastpathT) EncMapFloat32Float32V(v map[float32]float32, e *Encoder) {
  4215. if v == nil {
  4216. e.e.EncodeNil()
  4217. return
  4218. }
  4219. ee, esep := e.e, e.hh.hasElemSeparators()
  4220. ee.WriteMapStart(len(v))
  4221. if e.h.Canonical {
  4222. v2 := make([]float64, len(v))
  4223. var i int
  4224. for k, _ := range v {
  4225. v2[i] = float64(k)
  4226. i++
  4227. }
  4228. sort.Sort(floatSlice(v2))
  4229. for _, k2 := range v2 {
  4230. if esep {
  4231. ee.WriteMapElemKey()
  4232. }
  4233. ee.EncodeFloat32(float32(k2))
  4234. if esep {
  4235. ee.WriteMapElemValue()
  4236. }
  4237. ee.EncodeFloat32(v[float32(k2)])
  4238. }
  4239. } else {
  4240. for k2, v2 := range v {
  4241. if esep {
  4242. ee.WriteMapElemKey()
  4243. }
  4244. ee.EncodeFloat32(k2)
  4245. if esep {
  4246. ee.WriteMapElemValue()
  4247. }
  4248. ee.EncodeFloat32(v2)
  4249. }
  4250. }
  4251. ee.WriteMapEnd()
  4252. }
  4253. func (e *Encoder) fastpathEncMapFloat32Float64R(f *codecFnInfo, rv reflect.Value) {
  4254. fastpathTV.EncMapFloat32Float64V(rv2i(rv).(map[float32]float64), e)
  4255. }
  4256. func (_ fastpathT) EncMapFloat32Float64V(v map[float32]float64, e *Encoder) {
  4257. if v == nil {
  4258. e.e.EncodeNil()
  4259. return
  4260. }
  4261. ee, esep := e.e, e.hh.hasElemSeparators()
  4262. ee.WriteMapStart(len(v))
  4263. if e.h.Canonical {
  4264. v2 := make([]float64, len(v))
  4265. var i int
  4266. for k, _ := range v {
  4267. v2[i] = float64(k)
  4268. i++
  4269. }
  4270. sort.Sort(floatSlice(v2))
  4271. for _, k2 := range v2 {
  4272. if esep {
  4273. ee.WriteMapElemKey()
  4274. }
  4275. ee.EncodeFloat32(float32(k2))
  4276. if esep {
  4277. ee.WriteMapElemValue()
  4278. }
  4279. ee.EncodeFloat64(v[float32(k2)])
  4280. }
  4281. } else {
  4282. for k2, v2 := range v {
  4283. if esep {
  4284. ee.WriteMapElemKey()
  4285. }
  4286. ee.EncodeFloat32(k2)
  4287. if esep {
  4288. ee.WriteMapElemValue()
  4289. }
  4290. ee.EncodeFloat64(v2)
  4291. }
  4292. }
  4293. ee.WriteMapEnd()
  4294. }
  4295. func (e *Encoder) fastpathEncMapFloat32BoolR(f *codecFnInfo, rv reflect.Value) {
  4296. fastpathTV.EncMapFloat32BoolV(rv2i(rv).(map[float32]bool), e)
  4297. }
  4298. func (_ fastpathT) EncMapFloat32BoolV(v map[float32]bool, e *Encoder) {
  4299. if v == nil {
  4300. e.e.EncodeNil()
  4301. return
  4302. }
  4303. ee, esep := e.e, e.hh.hasElemSeparators()
  4304. ee.WriteMapStart(len(v))
  4305. if e.h.Canonical {
  4306. v2 := make([]float64, len(v))
  4307. var i int
  4308. for k, _ := range v {
  4309. v2[i] = float64(k)
  4310. i++
  4311. }
  4312. sort.Sort(floatSlice(v2))
  4313. for _, k2 := range v2 {
  4314. if esep {
  4315. ee.WriteMapElemKey()
  4316. }
  4317. ee.EncodeFloat32(float32(k2))
  4318. if esep {
  4319. ee.WriteMapElemValue()
  4320. }
  4321. ee.EncodeBool(v[float32(k2)])
  4322. }
  4323. } else {
  4324. for k2, v2 := range v {
  4325. if esep {
  4326. ee.WriteMapElemKey()
  4327. }
  4328. ee.EncodeFloat32(k2)
  4329. if esep {
  4330. ee.WriteMapElemValue()
  4331. }
  4332. ee.EncodeBool(v2)
  4333. }
  4334. }
  4335. ee.WriteMapEnd()
  4336. }
  4337. func (e *Encoder) fastpathEncMapFloat64IntfR(f *codecFnInfo, rv reflect.Value) {
  4338. fastpathTV.EncMapFloat64IntfV(rv2i(rv).(map[float64]interface{}), e)
  4339. }
  4340. func (_ fastpathT) EncMapFloat64IntfV(v map[float64]interface{}, e *Encoder) {
  4341. if v == nil {
  4342. e.e.EncodeNil()
  4343. return
  4344. }
  4345. ee, esep := e.e, e.hh.hasElemSeparators()
  4346. ee.WriteMapStart(len(v))
  4347. if e.h.Canonical {
  4348. v2 := make([]float64, len(v))
  4349. var i int
  4350. for k, _ := range v {
  4351. v2[i] = float64(k)
  4352. i++
  4353. }
  4354. sort.Sort(floatSlice(v2))
  4355. for _, k2 := range v2 {
  4356. if esep {
  4357. ee.WriteMapElemKey()
  4358. }
  4359. ee.EncodeFloat64(float64(k2))
  4360. if esep {
  4361. ee.WriteMapElemValue()
  4362. }
  4363. e.encode(v[float64(k2)])
  4364. }
  4365. } else {
  4366. for k2, v2 := range v {
  4367. if esep {
  4368. ee.WriteMapElemKey()
  4369. }
  4370. ee.EncodeFloat64(k2)
  4371. if esep {
  4372. ee.WriteMapElemValue()
  4373. }
  4374. e.encode(v2)
  4375. }
  4376. }
  4377. ee.WriteMapEnd()
  4378. }
  4379. func (e *Encoder) fastpathEncMapFloat64StringR(f *codecFnInfo, rv reflect.Value) {
  4380. fastpathTV.EncMapFloat64StringV(rv2i(rv).(map[float64]string), e)
  4381. }
  4382. func (_ fastpathT) EncMapFloat64StringV(v map[float64]string, e *Encoder) {
  4383. if v == nil {
  4384. e.e.EncodeNil()
  4385. return
  4386. }
  4387. ee, esep := e.e, e.hh.hasElemSeparators()
  4388. ee.WriteMapStart(len(v))
  4389. if e.h.Canonical {
  4390. v2 := make([]float64, len(v))
  4391. var i int
  4392. for k, _ := range v {
  4393. v2[i] = float64(k)
  4394. i++
  4395. }
  4396. sort.Sort(floatSlice(v2))
  4397. for _, k2 := range v2 {
  4398. if esep {
  4399. ee.WriteMapElemKey()
  4400. }
  4401. ee.EncodeFloat64(float64(k2))
  4402. if esep {
  4403. ee.WriteMapElemValue()
  4404. }
  4405. ee.EncodeString(c_UTF8, v[float64(k2)])
  4406. }
  4407. } else {
  4408. for k2, v2 := range v {
  4409. if esep {
  4410. ee.WriteMapElemKey()
  4411. }
  4412. ee.EncodeFloat64(k2)
  4413. if esep {
  4414. ee.WriteMapElemValue()
  4415. }
  4416. ee.EncodeString(c_UTF8, v2)
  4417. }
  4418. }
  4419. ee.WriteMapEnd()
  4420. }
  4421. func (e *Encoder) fastpathEncMapFloat64UintR(f *codecFnInfo, rv reflect.Value) {
  4422. fastpathTV.EncMapFloat64UintV(rv2i(rv).(map[float64]uint), e)
  4423. }
  4424. func (_ fastpathT) EncMapFloat64UintV(v map[float64]uint, e *Encoder) {
  4425. if v == nil {
  4426. e.e.EncodeNil()
  4427. return
  4428. }
  4429. ee, esep := e.e, e.hh.hasElemSeparators()
  4430. ee.WriteMapStart(len(v))
  4431. if e.h.Canonical {
  4432. v2 := make([]float64, len(v))
  4433. var i int
  4434. for k, _ := range v {
  4435. v2[i] = float64(k)
  4436. i++
  4437. }
  4438. sort.Sort(floatSlice(v2))
  4439. for _, k2 := range v2 {
  4440. if esep {
  4441. ee.WriteMapElemKey()
  4442. }
  4443. ee.EncodeFloat64(float64(k2))
  4444. if esep {
  4445. ee.WriteMapElemValue()
  4446. }
  4447. ee.EncodeUint(uint64(v[float64(k2)]))
  4448. }
  4449. } else {
  4450. for k2, v2 := range v {
  4451. if esep {
  4452. ee.WriteMapElemKey()
  4453. }
  4454. ee.EncodeFloat64(k2)
  4455. if esep {
  4456. ee.WriteMapElemValue()
  4457. }
  4458. ee.EncodeUint(uint64(v2))
  4459. }
  4460. }
  4461. ee.WriteMapEnd()
  4462. }
  4463. func (e *Encoder) fastpathEncMapFloat64Uint8R(f *codecFnInfo, rv reflect.Value) {
  4464. fastpathTV.EncMapFloat64Uint8V(rv2i(rv).(map[float64]uint8), e)
  4465. }
  4466. func (_ fastpathT) EncMapFloat64Uint8V(v map[float64]uint8, e *Encoder) {
  4467. if v == nil {
  4468. e.e.EncodeNil()
  4469. return
  4470. }
  4471. ee, esep := e.e, e.hh.hasElemSeparators()
  4472. ee.WriteMapStart(len(v))
  4473. if e.h.Canonical {
  4474. v2 := make([]float64, len(v))
  4475. var i int
  4476. for k, _ := range v {
  4477. v2[i] = float64(k)
  4478. i++
  4479. }
  4480. sort.Sort(floatSlice(v2))
  4481. for _, k2 := range v2 {
  4482. if esep {
  4483. ee.WriteMapElemKey()
  4484. }
  4485. ee.EncodeFloat64(float64(k2))
  4486. if esep {
  4487. ee.WriteMapElemValue()
  4488. }
  4489. ee.EncodeUint(uint64(v[float64(k2)]))
  4490. }
  4491. } else {
  4492. for k2, v2 := range v {
  4493. if esep {
  4494. ee.WriteMapElemKey()
  4495. }
  4496. ee.EncodeFloat64(k2)
  4497. if esep {
  4498. ee.WriteMapElemValue()
  4499. }
  4500. ee.EncodeUint(uint64(v2))
  4501. }
  4502. }
  4503. ee.WriteMapEnd()
  4504. }
  4505. func (e *Encoder) fastpathEncMapFloat64Uint16R(f *codecFnInfo, rv reflect.Value) {
  4506. fastpathTV.EncMapFloat64Uint16V(rv2i(rv).(map[float64]uint16), e)
  4507. }
  4508. func (_ fastpathT) EncMapFloat64Uint16V(v map[float64]uint16, e *Encoder) {
  4509. if v == nil {
  4510. e.e.EncodeNil()
  4511. return
  4512. }
  4513. ee, esep := e.e, e.hh.hasElemSeparators()
  4514. ee.WriteMapStart(len(v))
  4515. if e.h.Canonical {
  4516. v2 := make([]float64, len(v))
  4517. var i int
  4518. for k, _ := range v {
  4519. v2[i] = float64(k)
  4520. i++
  4521. }
  4522. sort.Sort(floatSlice(v2))
  4523. for _, k2 := range v2 {
  4524. if esep {
  4525. ee.WriteMapElemKey()
  4526. }
  4527. ee.EncodeFloat64(float64(k2))
  4528. if esep {
  4529. ee.WriteMapElemValue()
  4530. }
  4531. ee.EncodeUint(uint64(v[float64(k2)]))
  4532. }
  4533. } else {
  4534. for k2, v2 := range v {
  4535. if esep {
  4536. ee.WriteMapElemKey()
  4537. }
  4538. ee.EncodeFloat64(k2)
  4539. if esep {
  4540. ee.WriteMapElemValue()
  4541. }
  4542. ee.EncodeUint(uint64(v2))
  4543. }
  4544. }
  4545. ee.WriteMapEnd()
  4546. }
  4547. func (e *Encoder) fastpathEncMapFloat64Uint32R(f *codecFnInfo, rv reflect.Value) {
  4548. fastpathTV.EncMapFloat64Uint32V(rv2i(rv).(map[float64]uint32), e)
  4549. }
  4550. func (_ fastpathT) EncMapFloat64Uint32V(v map[float64]uint32, e *Encoder) {
  4551. if v == nil {
  4552. e.e.EncodeNil()
  4553. return
  4554. }
  4555. ee, esep := e.e, e.hh.hasElemSeparators()
  4556. ee.WriteMapStart(len(v))
  4557. if e.h.Canonical {
  4558. v2 := make([]float64, len(v))
  4559. var i int
  4560. for k, _ := range v {
  4561. v2[i] = float64(k)
  4562. i++
  4563. }
  4564. sort.Sort(floatSlice(v2))
  4565. for _, k2 := range v2 {
  4566. if esep {
  4567. ee.WriteMapElemKey()
  4568. }
  4569. ee.EncodeFloat64(float64(k2))
  4570. if esep {
  4571. ee.WriteMapElemValue()
  4572. }
  4573. ee.EncodeUint(uint64(v[float64(k2)]))
  4574. }
  4575. } else {
  4576. for k2, v2 := range v {
  4577. if esep {
  4578. ee.WriteMapElemKey()
  4579. }
  4580. ee.EncodeFloat64(k2)
  4581. if esep {
  4582. ee.WriteMapElemValue()
  4583. }
  4584. ee.EncodeUint(uint64(v2))
  4585. }
  4586. }
  4587. ee.WriteMapEnd()
  4588. }
  4589. func (e *Encoder) fastpathEncMapFloat64Uint64R(f *codecFnInfo, rv reflect.Value) {
  4590. fastpathTV.EncMapFloat64Uint64V(rv2i(rv).(map[float64]uint64), e)
  4591. }
  4592. func (_ fastpathT) EncMapFloat64Uint64V(v map[float64]uint64, e *Encoder) {
  4593. if v == nil {
  4594. e.e.EncodeNil()
  4595. return
  4596. }
  4597. ee, esep := e.e, e.hh.hasElemSeparators()
  4598. ee.WriteMapStart(len(v))
  4599. if e.h.Canonical {
  4600. v2 := make([]float64, len(v))
  4601. var i int
  4602. for k, _ := range v {
  4603. v2[i] = float64(k)
  4604. i++
  4605. }
  4606. sort.Sort(floatSlice(v2))
  4607. for _, k2 := range v2 {
  4608. if esep {
  4609. ee.WriteMapElemKey()
  4610. }
  4611. ee.EncodeFloat64(float64(k2))
  4612. if esep {
  4613. ee.WriteMapElemValue()
  4614. }
  4615. ee.EncodeUint(uint64(v[float64(k2)]))
  4616. }
  4617. } else {
  4618. for k2, v2 := range v {
  4619. if esep {
  4620. ee.WriteMapElemKey()
  4621. }
  4622. ee.EncodeFloat64(k2)
  4623. if esep {
  4624. ee.WriteMapElemValue()
  4625. }
  4626. ee.EncodeUint(uint64(v2))
  4627. }
  4628. }
  4629. ee.WriteMapEnd()
  4630. }
  4631. func (e *Encoder) fastpathEncMapFloat64UintptrR(f *codecFnInfo, rv reflect.Value) {
  4632. fastpathTV.EncMapFloat64UintptrV(rv2i(rv).(map[float64]uintptr), e)
  4633. }
  4634. func (_ fastpathT) EncMapFloat64UintptrV(v map[float64]uintptr, e *Encoder) {
  4635. if v == nil {
  4636. e.e.EncodeNil()
  4637. return
  4638. }
  4639. ee, esep := e.e, e.hh.hasElemSeparators()
  4640. ee.WriteMapStart(len(v))
  4641. if e.h.Canonical {
  4642. v2 := make([]float64, len(v))
  4643. var i int
  4644. for k, _ := range v {
  4645. v2[i] = float64(k)
  4646. i++
  4647. }
  4648. sort.Sort(floatSlice(v2))
  4649. for _, k2 := range v2 {
  4650. if esep {
  4651. ee.WriteMapElemKey()
  4652. }
  4653. ee.EncodeFloat64(float64(k2))
  4654. if esep {
  4655. ee.WriteMapElemValue()
  4656. }
  4657. e.encode(v[float64(k2)])
  4658. }
  4659. } else {
  4660. for k2, v2 := range v {
  4661. if esep {
  4662. ee.WriteMapElemKey()
  4663. }
  4664. ee.EncodeFloat64(k2)
  4665. if esep {
  4666. ee.WriteMapElemValue()
  4667. }
  4668. e.encode(v2)
  4669. }
  4670. }
  4671. ee.WriteMapEnd()
  4672. }
  4673. func (e *Encoder) fastpathEncMapFloat64IntR(f *codecFnInfo, rv reflect.Value) {
  4674. fastpathTV.EncMapFloat64IntV(rv2i(rv).(map[float64]int), e)
  4675. }
  4676. func (_ fastpathT) EncMapFloat64IntV(v map[float64]int, e *Encoder) {
  4677. if v == nil {
  4678. e.e.EncodeNil()
  4679. return
  4680. }
  4681. ee, esep := e.e, e.hh.hasElemSeparators()
  4682. ee.WriteMapStart(len(v))
  4683. if e.h.Canonical {
  4684. v2 := make([]float64, len(v))
  4685. var i int
  4686. for k, _ := range v {
  4687. v2[i] = float64(k)
  4688. i++
  4689. }
  4690. sort.Sort(floatSlice(v2))
  4691. for _, k2 := range v2 {
  4692. if esep {
  4693. ee.WriteMapElemKey()
  4694. }
  4695. ee.EncodeFloat64(float64(k2))
  4696. if esep {
  4697. ee.WriteMapElemValue()
  4698. }
  4699. ee.EncodeInt(int64(v[float64(k2)]))
  4700. }
  4701. } else {
  4702. for k2, v2 := range v {
  4703. if esep {
  4704. ee.WriteMapElemKey()
  4705. }
  4706. ee.EncodeFloat64(k2)
  4707. if esep {
  4708. ee.WriteMapElemValue()
  4709. }
  4710. ee.EncodeInt(int64(v2))
  4711. }
  4712. }
  4713. ee.WriteMapEnd()
  4714. }
  4715. func (e *Encoder) fastpathEncMapFloat64Int8R(f *codecFnInfo, rv reflect.Value) {
  4716. fastpathTV.EncMapFloat64Int8V(rv2i(rv).(map[float64]int8), e)
  4717. }
  4718. func (_ fastpathT) EncMapFloat64Int8V(v map[float64]int8, e *Encoder) {
  4719. if v == nil {
  4720. e.e.EncodeNil()
  4721. return
  4722. }
  4723. ee, esep := e.e, e.hh.hasElemSeparators()
  4724. ee.WriteMapStart(len(v))
  4725. if e.h.Canonical {
  4726. v2 := make([]float64, len(v))
  4727. var i int
  4728. for k, _ := range v {
  4729. v2[i] = float64(k)
  4730. i++
  4731. }
  4732. sort.Sort(floatSlice(v2))
  4733. for _, k2 := range v2 {
  4734. if esep {
  4735. ee.WriteMapElemKey()
  4736. }
  4737. ee.EncodeFloat64(float64(k2))
  4738. if esep {
  4739. ee.WriteMapElemValue()
  4740. }
  4741. ee.EncodeInt(int64(v[float64(k2)]))
  4742. }
  4743. } else {
  4744. for k2, v2 := range v {
  4745. if esep {
  4746. ee.WriteMapElemKey()
  4747. }
  4748. ee.EncodeFloat64(k2)
  4749. if esep {
  4750. ee.WriteMapElemValue()
  4751. }
  4752. ee.EncodeInt(int64(v2))
  4753. }
  4754. }
  4755. ee.WriteMapEnd()
  4756. }
  4757. func (e *Encoder) fastpathEncMapFloat64Int16R(f *codecFnInfo, rv reflect.Value) {
  4758. fastpathTV.EncMapFloat64Int16V(rv2i(rv).(map[float64]int16), e)
  4759. }
  4760. func (_ fastpathT) EncMapFloat64Int16V(v map[float64]int16, e *Encoder) {
  4761. if v == nil {
  4762. e.e.EncodeNil()
  4763. return
  4764. }
  4765. ee, esep := e.e, e.hh.hasElemSeparators()
  4766. ee.WriteMapStart(len(v))
  4767. if e.h.Canonical {
  4768. v2 := make([]float64, len(v))
  4769. var i int
  4770. for k, _ := range v {
  4771. v2[i] = float64(k)
  4772. i++
  4773. }
  4774. sort.Sort(floatSlice(v2))
  4775. for _, k2 := range v2 {
  4776. if esep {
  4777. ee.WriteMapElemKey()
  4778. }
  4779. ee.EncodeFloat64(float64(k2))
  4780. if esep {
  4781. ee.WriteMapElemValue()
  4782. }
  4783. ee.EncodeInt(int64(v[float64(k2)]))
  4784. }
  4785. } else {
  4786. for k2, v2 := range v {
  4787. if esep {
  4788. ee.WriteMapElemKey()
  4789. }
  4790. ee.EncodeFloat64(k2)
  4791. if esep {
  4792. ee.WriteMapElemValue()
  4793. }
  4794. ee.EncodeInt(int64(v2))
  4795. }
  4796. }
  4797. ee.WriteMapEnd()
  4798. }
  4799. func (e *Encoder) fastpathEncMapFloat64Int32R(f *codecFnInfo, rv reflect.Value) {
  4800. fastpathTV.EncMapFloat64Int32V(rv2i(rv).(map[float64]int32), e)
  4801. }
  4802. func (_ fastpathT) EncMapFloat64Int32V(v map[float64]int32, e *Encoder) {
  4803. if v == nil {
  4804. e.e.EncodeNil()
  4805. return
  4806. }
  4807. ee, esep := e.e, e.hh.hasElemSeparators()
  4808. ee.WriteMapStart(len(v))
  4809. if e.h.Canonical {
  4810. v2 := make([]float64, len(v))
  4811. var i int
  4812. for k, _ := range v {
  4813. v2[i] = float64(k)
  4814. i++
  4815. }
  4816. sort.Sort(floatSlice(v2))
  4817. for _, k2 := range v2 {
  4818. if esep {
  4819. ee.WriteMapElemKey()
  4820. }
  4821. ee.EncodeFloat64(float64(k2))
  4822. if esep {
  4823. ee.WriteMapElemValue()
  4824. }
  4825. ee.EncodeInt(int64(v[float64(k2)]))
  4826. }
  4827. } else {
  4828. for k2, v2 := range v {
  4829. if esep {
  4830. ee.WriteMapElemKey()
  4831. }
  4832. ee.EncodeFloat64(k2)
  4833. if esep {
  4834. ee.WriteMapElemValue()
  4835. }
  4836. ee.EncodeInt(int64(v2))
  4837. }
  4838. }
  4839. ee.WriteMapEnd()
  4840. }
  4841. func (e *Encoder) fastpathEncMapFloat64Int64R(f *codecFnInfo, rv reflect.Value) {
  4842. fastpathTV.EncMapFloat64Int64V(rv2i(rv).(map[float64]int64), e)
  4843. }
  4844. func (_ fastpathT) EncMapFloat64Int64V(v map[float64]int64, e *Encoder) {
  4845. if v == nil {
  4846. e.e.EncodeNil()
  4847. return
  4848. }
  4849. ee, esep := e.e, e.hh.hasElemSeparators()
  4850. ee.WriteMapStart(len(v))
  4851. if e.h.Canonical {
  4852. v2 := make([]float64, len(v))
  4853. var i int
  4854. for k, _ := range v {
  4855. v2[i] = float64(k)
  4856. i++
  4857. }
  4858. sort.Sort(floatSlice(v2))
  4859. for _, k2 := range v2 {
  4860. if esep {
  4861. ee.WriteMapElemKey()
  4862. }
  4863. ee.EncodeFloat64(float64(k2))
  4864. if esep {
  4865. ee.WriteMapElemValue()
  4866. }
  4867. ee.EncodeInt(int64(v[float64(k2)]))
  4868. }
  4869. } else {
  4870. for k2, v2 := range v {
  4871. if esep {
  4872. ee.WriteMapElemKey()
  4873. }
  4874. ee.EncodeFloat64(k2)
  4875. if esep {
  4876. ee.WriteMapElemValue()
  4877. }
  4878. ee.EncodeInt(int64(v2))
  4879. }
  4880. }
  4881. ee.WriteMapEnd()
  4882. }
  4883. func (e *Encoder) fastpathEncMapFloat64Float32R(f *codecFnInfo, rv reflect.Value) {
  4884. fastpathTV.EncMapFloat64Float32V(rv2i(rv).(map[float64]float32), e)
  4885. }
  4886. func (_ fastpathT) EncMapFloat64Float32V(v map[float64]float32, e *Encoder) {
  4887. if v == nil {
  4888. e.e.EncodeNil()
  4889. return
  4890. }
  4891. ee, esep := e.e, e.hh.hasElemSeparators()
  4892. ee.WriteMapStart(len(v))
  4893. if e.h.Canonical {
  4894. v2 := make([]float64, len(v))
  4895. var i int
  4896. for k, _ := range v {
  4897. v2[i] = float64(k)
  4898. i++
  4899. }
  4900. sort.Sort(floatSlice(v2))
  4901. for _, k2 := range v2 {
  4902. if esep {
  4903. ee.WriteMapElemKey()
  4904. }
  4905. ee.EncodeFloat64(float64(k2))
  4906. if esep {
  4907. ee.WriteMapElemValue()
  4908. }
  4909. ee.EncodeFloat32(v[float64(k2)])
  4910. }
  4911. } else {
  4912. for k2, v2 := range v {
  4913. if esep {
  4914. ee.WriteMapElemKey()
  4915. }
  4916. ee.EncodeFloat64(k2)
  4917. if esep {
  4918. ee.WriteMapElemValue()
  4919. }
  4920. ee.EncodeFloat32(v2)
  4921. }
  4922. }
  4923. ee.WriteMapEnd()
  4924. }
  4925. func (e *Encoder) fastpathEncMapFloat64Float64R(f *codecFnInfo, rv reflect.Value) {
  4926. fastpathTV.EncMapFloat64Float64V(rv2i(rv).(map[float64]float64), e)
  4927. }
  4928. func (_ fastpathT) EncMapFloat64Float64V(v map[float64]float64, e *Encoder) {
  4929. if v == nil {
  4930. e.e.EncodeNil()
  4931. return
  4932. }
  4933. ee, esep := e.e, e.hh.hasElemSeparators()
  4934. ee.WriteMapStart(len(v))
  4935. if e.h.Canonical {
  4936. v2 := make([]float64, len(v))
  4937. var i int
  4938. for k, _ := range v {
  4939. v2[i] = float64(k)
  4940. i++
  4941. }
  4942. sort.Sort(floatSlice(v2))
  4943. for _, k2 := range v2 {
  4944. if esep {
  4945. ee.WriteMapElemKey()
  4946. }
  4947. ee.EncodeFloat64(float64(k2))
  4948. if esep {
  4949. ee.WriteMapElemValue()
  4950. }
  4951. ee.EncodeFloat64(v[float64(k2)])
  4952. }
  4953. } else {
  4954. for k2, v2 := range v {
  4955. if esep {
  4956. ee.WriteMapElemKey()
  4957. }
  4958. ee.EncodeFloat64(k2)
  4959. if esep {
  4960. ee.WriteMapElemValue()
  4961. }
  4962. ee.EncodeFloat64(v2)
  4963. }
  4964. }
  4965. ee.WriteMapEnd()
  4966. }
  4967. func (e *Encoder) fastpathEncMapFloat64BoolR(f *codecFnInfo, rv reflect.Value) {
  4968. fastpathTV.EncMapFloat64BoolV(rv2i(rv).(map[float64]bool), e)
  4969. }
  4970. func (_ fastpathT) EncMapFloat64BoolV(v map[float64]bool, e *Encoder) {
  4971. if v == nil {
  4972. e.e.EncodeNil()
  4973. return
  4974. }
  4975. ee, esep := e.e, e.hh.hasElemSeparators()
  4976. ee.WriteMapStart(len(v))
  4977. if e.h.Canonical {
  4978. v2 := make([]float64, len(v))
  4979. var i int
  4980. for k, _ := range v {
  4981. v2[i] = float64(k)
  4982. i++
  4983. }
  4984. sort.Sort(floatSlice(v2))
  4985. for _, k2 := range v2 {
  4986. if esep {
  4987. ee.WriteMapElemKey()
  4988. }
  4989. ee.EncodeFloat64(float64(k2))
  4990. if esep {
  4991. ee.WriteMapElemValue()
  4992. }
  4993. ee.EncodeBool(v[float64(k2)])
  4994. }
  4995. } else {
  4996. for k2, v2 := range v {
  4997. if esep {
  4998. ee.WriteMapElemKey()
  4999. }
  5000. ee.EncodeFloat64(k2)
  5001. if esep {
  5002. ee.WriteMapElemValue()
  5003. }
  5004. ee.EncodeBool(v2)
  5005. }
  5006. }
  5007. ee.WriteMapEnd()
  5008. }
  5009. func (e *Encoder) fastpathEncMapUintIntfR(f *codecFnInfo, rv reflect.Value) {
  5010. fastpathTV.EncMapUintIntfV(rv2i(rv).(map[uint]interface{}), e)
  5011. }
  5012. func (_ fastpathT) EncMapUintIntfV(v map[uint]interface{}, e *Encoder) {
  5013. if v == nil {
  5014. e.e.EncodeNil()
  5015. return
  5016. }
  5017. ee, esep := e.e, e.hh.hasElemSeparators()
  5018. ee.WriteMapStart(len(v))
  5019. if e.h.Canonical {
  5020. v2 := make([]uint64, len(v))
  5021. var i int
  5022. for k, _ := range v {
  5023. v2[i] = uint64(k)
  5024. i++
  5025. }
  5026. sort.Sort(uintSlice(v2))
  5027. for _, k2 := range v2 {
  5028. if esep {
  5029. ee.WriteMapElemKey()
  5030. }
  5031. ee.EncodeUint(uint64(uint(k2)))
  5032. if esep {
  5033. ee.WriteMapElemValue()
  5034. }
  5035. e.encode(v[uint(k2)])
  5036. }
  5037. } else {
  5038. for k2, v2 := range v {
  5039. if esep {
  5040. ee.WriteMapElemKey()
  5041. }
  5042. ee.EncodeUint(uint64(k2))
  5043. if esep {
  5044. ee.WriteMapElemValue()
  5045. }
  5046. e.encode(v2)
  5047. }
  5048. }
  5049. ee.WriteMapEnd()
  5050. }
  5051. func (e *Encoder) fastpathEncMapUintStringR(f *codecFnInfo, rv reflect.Value) {
  5052. fastpathTV.EncMapUintStringV(rv2i(rv).(map[uint]string), e)
  5053. }
  5054. func (_ fastpathT) EncMapUintStringV(v map[uint]string, e *Encoder) {
  5055. if v == nil {
  5056. e.e.EncodeNil()
  5057. return
  5058. }
  5059. ee, esep := e.e, e.hh.hasElemSeparators()
  5060. ee.WriteMapStart(len(v))
  5061. if e.h.Canonical {
  5062. v2 := make([]uint64, len(v))
  5063. var i int
  5064. for k, _ := range v {
  5065. v2[i] = uint64(k)
  5066. i++
  5067. }
  5068. sort.Sort(uintSlice(v2))
  5069. for _, k2 := range v2 {
  5070. if esep {
  5071. ee.WriteMapElemKey()
  5072. }
  5073. ee.EncodeUint(uint64(uint(k2)))
  5074. if esep {
  5075. ee.WriteMapElemValue()
  5076. }
  5077. ee.EncodeString(c_UTF8, v[uint(k2)])
  5078. }
  5079. } else {
  5080. for k2, v2 := range v {
  5081. if esep {
  5082. ee.WriteMapElemKey()
  5083. }
  5084. ee.EncodeUint(uint64(k2))
  5085. if esep {
  5086. ee.WriteMapElemValue()
  5087. }
  5088. ee.EncodeString(c_UTF8, v2)
  5089. }
  5090. }
  5091. ee.WriteMapEnd()
  5092. }
  5093. func (e *Encoder) fastpathEncMapUintUintR(f *codecFnInfo, rv reflect.Value) {
  5094. fastpathTV.EncMapUintUintV(rv2i(rv).(map[uint]uint), e)
  5095. }
  5096. func (_ fastpathT) EncMapUintUintV(v map[uint]uint, e *Encoder) {
  5097. if v == nil {
  5098. e.e.EncodeNil()
  5099. return
  5100. }
  5101. ee, esep := e.e, e.hh.hasElemSeparators()
  5102. ee.WriteMapStart(len(v))
  5103. if e.h.Canonical {
  5104. v2 := make([]uint64, len(v))
  5105. var i int
  5106. for k, _ := range v {
  5107. v2[i] = uint64(k)
  5108. i++
  5109. }
  5110. sort.Sort(uintSlice(v2))
  5111. for _, k2 := range v2 {
  5112. if esep {
  5113. ee.WriteMapElemKey()
  5114. }
  5115. ee.EncodeUint(uint64(uint(k2)))
  5116. if esep {
  5117. ee.WriteMapElemValue()
  5118. }
  5119. ee.EncodeUint(uint64(v[uint(k2)]))
  5120. }
  5121. } else {
  5122. for k2, v2 := range v {
  5123. if esep {
  5124. ee.WriteMapElemKey()
  5125. }
  5126. ee.EncodeUint(uint64(k2))
  5127. if esep {
  5128. ee.WriteMapElemValue()
  5129. }
  5130. ee.EncodeUint(uint64(v2))
  5131. }
  5132. }
  5133. ee.WriteMapEnd()
  5134. }
  5135. func (e *Encoder) fastpathEncMapUintUint8R(f *codecFnInfo, rv reflect.Value) {
  5136. fastpathTV.EncMapUintUint8V(rv2i(rv).(map[uint]uint8), e)
  5137. }
  5138. func (_ fastpathT) EncMapUintUint8V(v map[uint]uint8, e *Encoder) {
  5139. if v == nil {
  5140. e.e.EncodeNil()
  5141. return
  5142. }
  5143. ee, esep := e.e, e.hh.hasElemSeparators()
  5144. ee.WriteMapStart(len(v))
  5145. if e.h.Canonical {
  5146. v2 := make([]uint64, len(v))
  5147. var i int
  5148. for k, _ := range v {
  5149. v2[i] = uint64(k)
  5150. i++
  5151. }
  5152. sort.Sort(uintSlice(v2))
  5153. for _, k2 := range v2 {
  5154. if esep {
  5155. ee.WriteMapElemKey()
  5156. }
  5157. ee.EncodeUint(uint64(uint(k2)))
  5158. if esep {
  5159. ee.WriteMapElemValue()
  5160. }
  5161. ee.EncodeUint(uint64(v[uint(k2)]))
  5162. }
  5163. } else {
  5164. for k2, v2 := range v {
  5165. if esep {
  5166. ee.WriteMapElemKey()
  5167. }
  5168. ee.EncodeUint(uint64(k2))
  5169. if esep {
  5170. ee.WriteMapElemValue()
  5171. }
  5172. ee.EncodeUint(uint64(v2))
  5173. }
  5174. }
  5175. ee.WriteMapEnd()
  5176. }
  5177. func (e *Encoder) fastpathEncMapUintUint16R(f *codecFnInfo, rv reflect.Value) {
  5178. fastpathTV.EncMapUintUint16V(rv2i(rv).(map[uint]uint16), e)
  5179. }
  5180. func (_ fastpathT) EncMapUintUint16V(v map[uint]uint16, e *Encoder) {
  5181. if v == nil {
  5182. e.e.EncodeNil()
  5183. return
  5184. }
  5185. ee, esep := e.e, e.hh.hasElemSeparators()
  5186. ee.WriteMapStart(len(v))
  5187. if e.h.Canonical {
  5188. v2 := make([]uint64, len(v))
  5189. var i int
  5190. for k, _ := range v {
  5191. v2[i] = uint64(k)
  5192. i++
  5193. }
  5194. sort.Sort(uintSlice(v2))
  5195. for _, k2 := range v2 {
  5196. if esep {
  5197. ee.WriteMapElemKey()
  5198. }
  5199. ee.EncodeUint(uint64(uint(k2)))
  5200. if esep {
  5201. ee.WriteMapElemValue()
  5202. }
  5203. ee.EncodeUint(uint64(v[uint(k2)]))
  5204. }
  5205. } else {
  5206. for k2, v2 := range v {
  5207. if esep {
  5208. ee.WriteMapElemKey()
  5209. }
  5210. ee.EncodeUint(uint64(k2))
  5211. if esep {
  5212. ee.WriteMapElemValue()
  5213. }
  5214. ee.EncodeUint(uint64(v2))
  5215. }
  5216. }
  5217. ee.WriteMapEnd()
  5218. }
  5219. func (e *Encoder) fastpathEncMapUintUint32R(f *codecFnInfo, rv reflect.Value) {
  5220. fastpathTV.EncMapUintUint32V(rv2i(rv).(map[uint]uint32), e)
  5221. }
  5222. func (_ fastpathT) EncMapUintUint32V(v map[uint]uint32, e *Encoder) {
  5223. if v == nil {
  5224. e.e.EncodeNil()
  5225. return
  5226. }
  5227. ee, esep := e.e, e.hh.hasElemSeparators()
  5228. ee.WriteMapStart(len(v))
  5229. if e.h.Canonical {
  5230. v2 := make([]uint64, len(v))
  5231. var i int
  5232. for k, _ := range v {
  5233. v2[i] = uint64(k)
  5234. i++
  5235. }
  5236. sort.Sort(uintSlice(v2))
  5237. for _, k2 := range v2 {
  5238. if esep {
  5239. ee.WriteMapElemKey()
  5240. }
  5241. ee.EncodeUint(uint64(uint(k2)))
  5242. if esep {
  5243. ee.WriteMapElemValue()
  5244. }
  5245. ee.EncodeUint(uint64(v[uint(k2)]))
  5246. }
  5247. } else {
  5248. for k2, v2 := range v {
  5249. if esep {
  5250. ee.WriteMapElemKey()
  5251. }
  5252. ee.EncodeUint(uint64(k2))
  5253. if esep {
  5254. ee.WriteMapElemValue()
  5255. }
  5256. ee.EncodeUint(uint64(v2))
  5257. }
  5258. }
  5259. ee.WriteMapEnd()
  5260. }
  5261. func (e *Encoder) fastpathEncMapUintUint64R(f *codecFnInfo, rv reflect.Value) {
  5262. fastpathTV.EncMapUintUint64V(rv2i(rv).(map[uint]uint64), e)
  5263. }
  5264. func (_ fastpathT) EncMapUintUint64V(v map[uint]uint64, e *Encoder) {
  5265. if v == nil {
  5266. e.e.EncodeNil()
  5267. return
  5268. }
  5269. ee, esep := e.e, e.hh.hasElemSeparators()
  5270. ee.WriteMapStart(len(v))
  5271. if e.h.Canonical {
  5272. v2 := make([]uint64, len(v))
  5273. var i int
  5274. for k, _ := range v {
  5275. v2[i] = uint64(k)
  5276. i++
  5277. }
  5278. sort.Sort(uintSlice(v2))
  5279. for _, k2 := range v2 {
  5280. if esep {
  5281. ee.WriteMapElemKey()
  5282. }
  5283. ee.EncodeUint(uint64(uint(k2)))
  5284. if esep {
  5285. ee.WriteMapElemValue()
  5286. }
  5287. ee.EncodeUint(uint64(v[uint(k2)]))
  5288. }
  5289. } else {
  5290. for k2, v2 := range v {
  5291. if esep {
  5292. ee.WriteMapElemKey()
  5293. }
  5294. ee.EncodeUint(uint64(k2))
  5295. if esep {
  5296. ee.WriteMapElemValue()
  5297. }
  5298. ee.EncodeUint(uint64(v2))
  5299. }
  5300. }
  5301. ee.WriteMapEnd()
  5302. }
  5303. func (e *Encoder) fastpathEncMapUintUintptrR(f *codecFnInfo, rv reflect.Value) {
  5304. fastpathTV.EncMapUintUintptrV(rv2i(rv).(map[uint]uintptr), e)
  5305. }
  5306. func (_ fastpathT) EncMapUintUintptrV(v map[uint]uintptr, e *Encoder) {
  5307. if v == nil {
  5308. e.e.EncodeNil()
  5309. return
  5310. }
  5311. ee, esep := e.e, e.hh.hasElemSeparators()
  5312. ee.WriteMapStart(len(v))
  5313. if e.h.Canonical {
  5314. v2 := make([]uint64, len(v))
  5315. var i int
  5316. for k, _ := range v {
  5317. v2[i] = uint64(k)
  5318. i++
  5319. }
  5320. sort.Sort(uintSlice(v2))
  5321. for _, k2 := range v2 {
  5322. if esep {
  5323. ee.WriteMapElemKey()
  5324. }
  5325. ee.EncodeUint(uint64(uint(k2)))
  5326. if esep {
  5327. ee.WriteMapElemValue()
  5328. }
  5329. e.encode(v[uint(k2)])
  5330. }
  5331. } else {
  5332. for k2, v2 := range v {
  5333. if esep {
  5334. ee.WriteMapElemKey()
  5335. }
  5336. ee.EncodeUint(uint64(k2))
  5337. if esep {
  5338. ee.WriteMapElemValue()
  5339. }
  5340. e.encode(v2)
  5341. }
  5342. }
  5343. ee.WriteMapEnd()
  5344. }
  5345. func (e *Encoder) fastpathEncMapUintIntR(f *codecFnInfo, rv reflect.Value) {
  5346. fastpathTV.EncMapUintIntV(rv2i(rv).(map[uint]int), e)
  5347. }
  5348. func (_ fastpathT) EncMapUintIntV(v map[uint]int, e *Encoder) {
  5349. if v == nil {
  5350. e.e.EncodeNil()
  5351. return
  5352. }
  5353. ee, esep := e.e, e.hh.hasElemSeparators()
  5354. ee.WriteMapStart(len(v))
  5355. if e.h.Canonical {
  5356. v2 := make([]uint64, len(v))
  5357. var i int
  5358. for k, _ := range v {
  5359. v2[i] = uint64(k)
  5360. i++
  5361. }
  5362. sort.Sort(uintSlice(v2))
  5363. for _, k2 := range v2 {
  5364. if esep {
  5365. ee.WriteMapElemKey()
  5366. }
  5367. ee.EncodeUint(uint64(uint(k2)))
  5368. if esep {
  5369. ee.WriteMapElemValue()
  5370. }
  5371. ee.EncodeInt(int64(v[uint(k2)]))
  5372. }
  5373. } else {
  5374. for k2, v2 := range v {
  5375. if esep {
  5376. ee.WriteMapElemKey()
  5377. }
  5378. ee.EncodeUint(uint64(k2))
  5379. if esep {
  5380. ee.WriteMapElemValue()
  5381. }
  5382. ee.EncodeInt(int64(v2))
  5383. }
  5384. }
  5385. ee.WriteMapEnd()
  5386. }
  5387. func (e *Encoder) fastpathEncMapUintInt8R(f *codecFnInfo, rv reflect.Value) {
  5388. fastpathTV.EncMapUintInt8V(rv2i(rv).(map[uint]int8), e)
  5389. }
  5390. func (_ fastpathT) EncMapUintInt8V(v map[uint]int8, e *Encoder) {
  5391. if v == nil {
  5392. e.e.EncodeNil()
  5393. return
  5394. }
  5395. ee, esep := e.e, e.hh.hasElemSeparators()
  5396. ee.WriteMapStart(len(v))
  5397. if e.h.Canonical {
  5398. v2 := make([]uint64, len(v))
  5399. var i int
  5400. for k, _ := range v {
  5401. v2[i] = uint64(k)
  5402. i++
  5403. }
  5404. sort.Sort(uintSlice(v2))
  5405. for _, k2 := range v2 {
  5406. if esep {
  5407. ee.WriteMapElemKey()
  5408. }
  5409. ee.EncodeUint(uint64(uint(k2)))
  5410. if esep {
  5411. ee.WriteMapElemValue()
  5412. }
  5413. ee.EncodeInt(int64(v[uint(k2)]))
  5414. }
  5415. } else {
  5416. for k2, v2 := range v {
  5417. if esep {
  5418. ee.WriteMapElemKey()
  5419. }
  5420. ee.EncodeUint(uint64(k2))
  5421. if esep {
  5422. ee.WriteMapElemValue()
  5423. }
  5424. ee.EncodeInt(int64(v2))
  5425. }
  5426. }
  5427. ee.WriteMapEnd()
  5428. }
  5429. func (e *Encoder) fastpathEncMapUintInt16R(f *codecFnInfo, rv reflect.Value) {
  5430. fastpathTV.EncMapUintInt16V(rv2i(rv).(map[uint]int16), e)
  5431. }
  5432. func (_ fastpathT) EncMapUintInt16V(v map[uint]int16, e *Encoder) {
  5433. if v == nil {
  5434. e.e.EncodeNil()
  5435. return
  5436. }
  5437. ee, esep := e.e, e.hh.hasElemSeparators()
  5438. ee.WriteMapStart(len(v))
  5439. if e.h.Canonical {
  5440. v2 := make([]uint64, len(v))
  5441. var i int
  5442. for k, _ := range v {
  5443. v2[i] = uint64(k)
  5444. i++
  5445. }
  5446. sort.Sort(uintSlice(v2))
  5447. for _, k2 := range v2 {
  5448. if esep {
  5449. ee.WriteMapElemKey()
  5450. }
  5451. ee.EncodeUint(uint64(uint(k2)))
  5452. if esep {
  5453. ee.WriteMapElemValue()
  5454. }
  5455. ee.EncodeInt(int64(v[uint(k2)]))
  5456. }
  5457. } else {
  5458. for k2, v2 := range v {
  5459. if esep {
  5460. ee.WriteMapElemKey()
  5461. }
  5462. ee.EncodeUint(uint64(k2))
  5463. if esep {
  5464. ee.WriteMapElemValue()
  5465. }
  5466. ee.EncodeInt(int64(v2))
  5467. }
  5468. }
  5469. ee.WriteMapEnd()
  5470. }
  5471. func (e *Encoder) fastpathEncMapUintInt32R(f *codecFnInfo, rv reflect.Value) {
  5472. fastpathTV.EncMapUintInt32V(rv2i(rv).(map[uint]int32), e)
  5473. }
  5474. func (_ fastpathT) EncMapUintInt32V(v map[uint]int32, e *Encoder) {
  5475. if v == nil {
  5476. e.e.EncodeNil()
  5477. return
  5478. }
  5479. ee, esep := e.e, e.hh.hasElemSeparators()
  5480. ee.WriteMapStart(len(v))
  5481. if e.h.Canonical {
  5482. v2 := make([]uint64, len(v))
  5483. var i int
  5484. for k, _ := range v {
  5485. v2[i] = uint64(k)
  5486. i++
  5487. }
  5488. sort.Sort(uintSlice(v2))
  5489. for _, k2 := range v2 {
  5490. if esep {
  5491. ee.WriteMapElemKey()
  5492. }
  5493. ee.EncodeUint(uint64(uint(k2)))
  5494. if esep {
  5495. ee.WriteMapElemValue()
  5496. }
  5497. ee.EncodeInt(int64(v[uint(k2)]))
  5498. }
  5499. } else {
  5500. for k2, v2 := range v {
  5501. if esep {
  5502. ee.WriteMapElemKey()
  5503. }
  5504. ee.EncodeUint(uint64(k2))
  5505. if esep {
  5506. ee.WriteMapElemValue()
  5507. }
  5508. ee.EncodeInt(int64(v2))
  5509. }
  5510. }
  5511. ee.WriteMapEnd()
  5512. }
  5513. func (e *Encoder) fastpathEncMapUintInt64R(f *codecFnInfo, rv reflect.Value) {
  5514. fastpathTV.EncMapUintInt64V(rv2i(rv).(map[uint]int64), e)
  5515. }
  5516. func (_ fastpathT) EncMapUintInt64V(v map[uint]int64, e *Encoder) {
  5517. if v == nil {
  5518. e.e.EncodeNil()
  5519. return
  5520. }
  5521. ee, esep := e.e, e.hh.hasElemSeparators()
  5522. ee.WriteMapStart(len(v))
  5523. if e.h.Canonical {
  5524. v2 := make([]uint64, len(v))
  5525. var i int
  5526. for k, _ := range v {
  5527. v2[i] = uint64(k)
  5528. i++
  5529. }
  5530. sort.Sort(uintSlice(v2))
  5531. for _, k2 := range v2 {
  5532. if esep {
  5533. ee.WriteMapElemKey()
  5534. }
  5535. ee.EncodeUint(uint64(uint(k2)))
  5536. if esep {
  5537. ee.WriteMapElemValue()
  5538. }
  5539. ee.EncodeInt(int64(v[uint(k2)]))
  5540. }
  5541. } else {
  5542. for k2, v2 := range v {
  5543. if esep {
  5544. ee.WriteMapElemKey()
  5545. }
  5546. ee.EncodeUint(uint64(k2))
  5547. if esep {
  5548. ee.WriteMapElemValue()
  5549. }
  5550. ee.EncodeInt(int64(v2))
  5551. }
  5552. }
  5553. ee.WriteMapEnd()
  5554. }
  5555. func (e *Encoder) fastpathEncMapUintFloat32R(f *codecFnInfo, rv reflect.Value) {
  5556. fastpathTV.EncMapUintFloat32V(rv2i(rv).(map[uint]float32), e)
  5557. }
  5558. func (_ fastpathT) EncMapUintFloat32V(v map[uint]float32, e *Encoder) {
  5559. if v == nil {
  5560. e.e.EncodeNil()
  5561. return
  5562. }
  5563. ee, esep := e.e, e.hh.hasElemSeparators()
  5564. ee.WriteMapStart(len(v))
  5565. if e.h.Canonical {
  5566. v2 := make([]uint64, len(v))
  5567. var i int
  5568. for k, _ := range v {
  5569. v2[i] = uint64(k)
  5570. i++
  5571. }
  5572. sort.Sort(uintSlice(v2))
  5573. for _, k2 := range v2 {
  5574. if esep {
  5575. ee.WriteMapElemKey()
  5576. }
  5577. ee.EncodeUint(uint64(uint(k2)))
  5578. if esep {
  5579. ee.WriteMapElemValue()
  5580. }
  5581. ee.EncodeFloat32(v[uint(k2)])
  5582. }
  5583. } else {
  5584. for k2, v2 := range v {
  5585. if esep {
  5586. ee.WriteMapElemKey()
  5587. }
  5588. ee.EncodeUint(uint64(k2))
  5589. if esep {
  5590. ee.WriteMapElemValue()
  5591. }
  5592. ee.EncodeFloat32(v2)
  5593. }
  5594. }
  5595. ee.WriteMapEnd()
  5596. }
  5597. func (e *Encoder) fastpathEncMapUintFloat64R(f *codecFnInfo, rv reflect.Value) {
  5598. fastpathTV.EncMapUintFloat64V(rv2i(rv).(map[uint]float64), e)
  5599. }
  5600. func (_ fastpathT) EncMapUintFloat64V(v map[uint]float64, e *Encoder) {
  5601. if v == nil {
  5602. e.e.EncodeNil()
  5603. return
  5604. }
  5605. ee, esep := e.e, e.hh.hasElemSeparators()
  5606. ee.WriteMapStart(len(v))
  5607. if e.h.Canonical {
  5608. v2 := make([]uint64, len(v))
  5609. var i int
  5610. for k, _ := range v {
  5611. v2[i] = uint64(k)
  5612. i++
  5613. }
  5614. sort.Sort(uintSlice(v2))
  5615. for _, k2 := range v2 {
  5616. if esep {
  5617. ee.WriteMapElemKey()
  5618. }
  5619. ee.EncodeUint(uint64(uint(k2)))
  5620. if esep {
  5621. ee.WriteMapElemValue()
  5622. }
  5623. ee.EncodeFloat64(v[uint(k2)])
  5624. }
  5625. } else {
  5626. for k2, v2 := range v {
  5627. if esep {
  5628. ee.WriteMapElemKey()
  5629. }
  5630. ee.EncodeUint(uint64(k2))
  5631. if esep {
  5632. ee.WriteMapElemValue()
  5633. }
  5634. ee.EncodeFloat64(v2)
  5635. }
  5636. }
  5637. ee.WriteMapEnd()
  5638. }
  5639. func (e *Encoder) fastpathEncMapUintBoolR(f *codecFnInfo, rv reflect.Value) {
  5640. fastpathTV.EncMapUintBoolV(rv2i(rv).(map[uint]bool), e)
  5641. }
  5642. func (_ fastpathT) EncMapUintBoolV(v map[uint]bool, e *Encoder) {
  5643. if v == nil {
  5644. e.e.EncodeNil()
  5645. return
  5646. }
  5647. ee, esep := e.e, e.hh.hasElemSeparators()
  5648. ee.WriteMapStart(len(v))
  5649. if e.h.Canonical {
  5650. v2 := make([]uint64, len(v))
  5651. var i int
  5652. for k, _ := range v {
  5653. v2[i] = uint64(k)
  5654. i++
  5655. }
  5656. sort.Sort(uintSlice(v2))
  5657. for _, k2 := range v2 {
  5658. if esep {
  5659. ee.WriteMapElemKey()
  5660. }
  5661. ee.EncodeUint(uint64(uint(k2)))
  5662. if esep {
  5663. ee.WriteMapElemValue()
  5664. }
  5665. ee.EncodeBool(v[uint(k2)])
  5666. }
  5667. } else {
  5668. for k2, v2 := range v {
  5669. if esep {
  5670. ee.WriteMapElemKey()
  5671. }
  5672. ee.EncodeUint(uint64(k2))
  5673. if esep {
  5674. ee.WriteMapElemValue()
  5675. }
  5676. ee.EncodeBool(v2)
  5677. }
  5678. }
  5679. ee.WriteMapEnd()
  5680. }
  5681. func (e *Encoder) fastpathEncMapUint8IntfR(f *codecFnInfo, rv reflect.Value) {
  5682. fastpathTV.EncMapUint8IntfV(rv2i(rv).(map[uint8]interface{}), e)
  5683. }
  5684. func (_ fastpathT) EncMapUint8IntfV(v map[uint8]interface{}, e *Encoder) {
  5685. if v == nil {
  5686. e.e.EncodeNil()
  5687. return
  5688. }
  5689. ee, esep := e.e, e.hh.hasElemSeparators()
  5690. ee.WriteMapStart(len(v))
  5691. if e.h.Canonical {
  5692. v2 := make([]uint64, len(v))
  5693. var i int
  5694. for k, _ := range v {
  5695. v2[i] = uint64(k)
  5696. i++
  5697. }
  5698. sort.Sort(uintSlice(v2))
  5699. for _, k2 := range v2 {
  5700. if esep {
  5701. ee.WriteMapElemKey()
  5702. }
  5703. ee.EncodeUint(uint64(uint8(k2)))
  5704. if esep {
  5705. ee.WriteMapElemValue()
  5706. }
  5707. e.encode(v[uint8(k2)])
  5708. }
  5709. } else {
  5710. for k2, v2 := range v {
  5711. if esep {
  5712. ee.WriteMapElemKey()
  5713. }
  5714. ee.EncodeUint(uint64(k2))
  5715. if esep {
  5716. ee.WriteMapElemValue()
  5717. }
  5718. e.encode(v2)
  5719. }
  5720. }
  5721. ee.WriteMapEnd()
  5722. }
  5723. func (e *Encoder) fastpathEncMapUint8StringR(f *codecFnInfo, rv reflect.Value) {
  5724. fastpathTV.EncMapUint8StringV(rv2i(rv).(map[uint8]string), e)
  5725. }
  5726. func (_ fastpathT) EncMapUint8StringV(v map[uint8]string, e *Encoder) {
  5727. if v == nil {
  5728. e.e.EncodeNil()
  5729. return
  5730. }
  5731. ee, esep := e.e, e.hh.hasElemSeparators()
  5732. ee.WriteMapStart(len(v))
  5733. if e.h.Canonical {
  5734. v2 := make([]uint64, len(v))
  5735. var i int
  5736. for k, _ := range v {
  5737. v2[i] = uint64(k)
  5738. i++
  5739. }
  5740. sort.Sort(uintSlice(v2))
  5741. for _, k2 := range v2 {
  5742. if esep {
  5743. ee.WriteMapElemKey()
  5744. }
  5745. ee.EncodeUint(uint64(uint8(k2)))
  5746. if esep {
  5747. ee.WriteMapElemValue()
  5748. }
  5749. ee.EncodeString(c_UTF8, v[uint8(k2)])
  5750. }
  5751. } else {
  5752. for k2, v2 := range v {
  5753. if esep {
  5754. ee.WriteMapElemKey()
  5755. }
  5756. ee.EncodeUint(uint64(k2))
  5757. if esep {
  5758. ee.WriteMapElemValue()
  5759. }
  5760. ee.EncodeString(c_UTF8, v2)
  5761. }
  5762. }
  5763. ee.WriteMapEnd()
  5764. }
  5765. func (e *Encoder) fastpathEncMapUint8UintR(f *codecFnInfo, rv reflect.Value) {
  5766. fastpathTV.EncMapUint8UintV(rv2i(rv).(map[uint8]uint), e)
  5767. }
  5768. func (_ fastpathT) EncMapUint8UintV(v map[uint8]uint, e *Encoder) {
  5769. if v == nil {
  5770. e.e.EncodeNil()
  5771. return
  5772. }
  5773. ee, esep := e.e, e.hh.hasElemSeparators()
  5774. ee.WriteMapStart(len(v))
  5775. if e.h.Canonical {
  5776. v2 := make([]uint64, len(v))
  5777. var i int
  5778. for k, _ := range v {
  5779. v2[i] = uint64(k)
  5780. i++
  5781. }
  5782. sort.Sort(uintSlice(v2))
  5783. for _, k2 := range v2 {
  5784. if esep {
  5785. ee.WriteMapElemKey()
  5786. }
  5787. ee.EncodeUint(uint64(uint8(k2)))
  5788. if esep {
  5789. ee.WriteMapElemValue()
  5790. }
  5791. ee.EncodeUint(uint64(v[uint8(k2)]))
  5792. }
  5793. } else {
  5794. for k2, v2 := range v {
  5795. if esep {
  5796. ee.WriteMapElemKey()
  5797. }
  5798. ee.EncodeUint(uint64(k2))
  5799. if esep {
  5800. ee.WriteMapElemValue()
  5801. }
  5802. ee.EncodeUint(uint64(v2))
  5803. }
  5804. }
  5805. ee.WriteMapEnd()
  5806. }
  5807. func (e *Encoder) fastpathEncMapUint8Uint8R(f *codecFnInfo, rv reflect.Value) {
  5808. fastpathTV.EncMapUint8Uint8V(rv2i(rv).(map[uint8]uint8), e)
  5809. }
  5810. func (_ fastpathT) EncMapUint8Uint8V(v map[uint8]uint8, e *Encoder) {
  5811. if v == nil {
  5812. e.e.EncodeNil()
  5813. return
  5814. }
  5815. ee, esep := e.e, e.hh.hasElemSeparators()
  5816. ee.WriteMapStart(len(v))
  5817. if e.h.Canonical {
  5818. v2 := make([]uint64, len(v))
  5819. var i int
  5820. for k, _ := range v {
  5821. v2[i] = uint64(k)
  5822. i++
  5823. }
  5824. sort.Sort(uintSlice(v2))
  5825. for _, k2 := range v2 {
  5826. if esep {
  5827. ee.WriteMapElemKey()
  5828. }
  5829. ee.EncodeUint(uint64(uint8(k2)))
  5830. if esep {
  5831. ee.WriteMapElemValue()
  5832. }
  5833. ee.EncodeUint(uint64(v[uint8(k2)]))
  5834. }
  5835. } else {
  5836. for k2, v2 := range v {
  5837. if esep {
  5838. ee.WriteMapElemKey()
  5839. }
  5840. ee.EncodeUint(uint64(k2))
  5841. if esep {
  5842. ee.WriteMapElemValue()
  5843. }
  5844. ee.EncodeUint(uint64(v2))
  5845. }
  5846. }
  5847. ee.WriteMapEnd()
  5848. }
  5849. func (e *Encoder) fastpathEncMapUint8Uint16R(f *codecFnInfo, rv reflect.Value) {
  5850. fastpathTV.EncMapUint8Uint16V(rv2i(rv).(map[uint8]uint16), e)
  5851. }
  5852. func (_ fastpathT) EncMapUint8Uint16V(v map[uint8]uint16, e *Encoder) {
  5853. if v == nil {
  5854. e.e.EncodeNil()
  5855. return
  5856. }
  5857. ee, esep := e.e, e.hh.hasElemSeparators()
  5858. ee.WriteMapStart(len(v))
  5859. if e.h.Canonical {
  5860. v2 := make([]uint64, len(v))
  5861. var i int
  5862. for k, _ := range v {
  5863. v2[i] = uint64(k)
  5864. i++
  5865. }
  5866. sort.Sort(uintSlice(v2))
  5867. for _, k2 := range v2 {
  5868. if esep {
  5869. ee.WriteMapElemKey()
  5870. }
  5871. ee.EncodeUint(uint64(uint8(k2)))
  5872. if esep {
  5873. ee.WriteMapElemValue()
  5874. }
  5875. ee.EncodeUint(uint64(v[uint8(k2)]))
  5876. }
  5877. } else {
  5878. for k2, v2 := range v {
  5879. if esep {
  5880. ee.WriteMapElemKey()
  5881. }
  5882. ee.EncodeUint(uint64(k2))
  5883. if esep {
  5884. ee.WriteMapElemValue()
  5885. }
  5886. ee.EncodeUint(uint64(v2))
  5887. }
  5888. }
  5889. ee.WriteMapEnd()
  5890. }
  5891. func (e *Encoder) fastpathEncMapUint8Uint32R(f *codecFnInfo, rv reflect.Value) {
  5892. fastpathTV.EncMapUint8Uint32V(rv2i(rv).(map[uint8]uint32), e)
  5893. }
  5894. func (_ fastpathT) EncMapUint8Uint32V(v map[uint8]uint32, e *Encoder) {
  5895. if v == nil {
  5896. e.e.EncodeNil()
  5897. return
  5898. }
  5899. ee, esep := e.e, e.hh.hasElemSeparators()
  5900. ee.WriteMapStart(len(v))
  5901. if e.h.Canonical {
  5902. v2 := make([]uint64, len(v))
  5903. var i int
  5904. for k, _ := range v {
  5905. v2[i] = uint64(k)
  5906. i++
  5907. }
  5908. sort.Sort(uintSlice(v2))
  5909. for _, k2 := range v2 {
  5910. if esep {
  5911. ee.WriteMapElemKey()
  5912. }
  5913. ee.EncodeUint(uint64(uint8(k2)))
  5914. if esep {
  5915. ee.WriteMapElemValue()
  5916. }
  5917. ee.EncodeUint(uint64(v[uint8(k2)]))
  5918. }
  5919. } else {
  5920. for k2, v2 := range v {
  5921. if esep {
  5922. ee.WriteMapElemKey()
  5923. }
  5924. ee.EncodeUint(uint64(k2))
  5925. if esep {
  5926. ee.WriteMapElemValue()
  5927. }
  5928. ee.EncodeUint(uint64(v2))
  5929. }
  5930. }
  5931. ee.WriteMapEnd()
  5932. }
  5933. func (e *Encoder) fastpathEncMapUint8Uint64R(f *codecFnInfo, rv reflect.Value) {
  5934. fastpathTV.EncMapUint8Uint64V(rv2i(rv).(map[uint8]uint64), e)
  5935. }
  5936. func (_ fastpathT) EncMapUint8Uint64V(v map[uint8]uint64, e *Encoder) {
  5937. if v == nil {
  5938. e.e.EncodeNil()
  5939. return
  5940. }
  5941. ee, esep := e.e, e.hh.hasElemSeparators()
  5942. ee.WriteMapStart(len(v))
  5943. if e.h.Canonical {
  5944. v2 := make([]uint64, len(v))
  5945. var i int
  5946. for k, _ := range v {
  5947. v2[i] = uint64(k)
  5948. i++
  5949. }
  5950. sort.Sort(uintSlice(v2))
  5951. for _, k2 := range v2 {
  5952. if esep {
  5953. ee.WriteMapElemKey()
  5954. }
  5955. ee.EncodeUint(uint64(uint8(k2)))
  5956. if esep {
  5957. ee.WriteMapElemValue()
  5958. }
  5959. ee.EncodeUint(uint64(v[uint8(k2)]))
  5960. }
  5961. } else {
  5962. for k2, v2 := range v {
  5963. if esep {
  5964. ee.WriteMapElemKey()
  5965. }
  5966. ee.EncodeUint(uint64(k2))
  5967. if esep {
  5968. ee.WriteMapElemValue()
  5969. }
  5970. ee.EncodeUint(uint64(v2))
  5971. }
  5972. }
  5973. ee.WriteMapEnd()
  5974. }
  5975. func (e *Encoder) fastpathEncMapUint8UintptrR(f *codecFnInfo, rv reflect.Value) {
  5976. fastpathTV.EncMapUint8UintptrV(rv2i(rv).(map[uint8]uintptr), e)
  5977. }
  5978. func (_ fastpathT) EncMapUint8UintptrV(v map[uint8]uintptr, e *Encoder) {
  5979. if v == nil {
  5980. e.e.EncodeNil()
  5981. return
  5982. }
  5983. ee, esep := e.e, e.hh.hasElemSeparators()
  5984. ee.WriteMapStart(len(v))
  5985. if e.h.Canonical {
  5986. v2 := make([]uint64, len(v))
  5987. var i int
  5988. for k, _ := range v {
  5989. v2[i] = uint64(k)
  5990. i++
  5991. }
  5992. sort.Sort(uintSlice(v2))
  5993. for _, k2 := range v2 {
  5994. if esep {
  5995. ee.WriteMapElemKey()
  5996. }
  5997. ee.EncodeUint(uint64(uint8(k2)))
  5998. if esep {
  5999. ee.WriteMapElemValue()
  6000. }
  6001. e.encode(v[uint8(k2)])
  6002. }
  6003. } else {
  6004. for k2, v2 := range v {
  6005. if esep {
  6006. ee.WriteMapElemKey()
  6007. }
  6008. ee.EncodeUint(uint64(k2))
  6009. if esep {
  6010. ee.WriteMapElemValue()
  6011. }
  6012. e.encode(v2)
  6013. }
  6014. }
  6015. ee.WriteMapEnd()
  6016. }
  6017. func (e *Encoder) fastpathEncMapUint8IntR(f *codecFnInfo, rv reflect.Value) {
  6018. fastpathTV.EncMapUint8IntV(rv2i(rv).(map[uint8]int), e)
  6019. }
  6020. func (_ fastpathT) EncMapUint8IntV(v map[uint8]int, e *Encoder) {
  6021. if v == nil {
  6022. e.e.EncodeNil()
  6023. return
  6024. }
  6025. ee, esep := e.e, e.hh.hasElemSeparators()
  6026. ee.WriteMapStart(len(v))
  6027. if e.h.Canonical {
  6028. v2 := make([]uint64, len(v))
  6029. var i int
  6030. for k, _ := range v {
  6031. v2[i] = uint64(k)
  6032. i++
  6033. }
  6034. sort.Sort(uintSlice(v2))
  6035. for _, k2 := range v2 {
  6036. if esep {
  6037. ee.WriteMapElemKey()
  6038. }
  6039. ee.EncodeUint(uint64(uint8(k2)))
  6040. if esep {
  6041. ee.WriteMapElemValue()
  6042. }
  6043. ee.EncodeInt(int64(v[uint8(k2)]))
  6044. }
  6045. } else {
  6046. for k2, v2 := range v {
  6047. if esep {
  6048. ee.WriteMapElemKey()
  6049. }
  6050. ee.EncodeUint(uint64(k2))
  6051. if esep {
  6052. ee.WriteMapElemValue()
  6053. }
  6054. ee.EncodeInt(int64(v2))
  6055. }
  6056. }
  6057. ee.WriteMapEnd()
  6058. }
  6059. func (e *Encoder) fastpathEncMapUint8Int8R(f *codecFnInfo, rv reflect.Value) {
  6060. fastpathTV.EncMapUint8Int8V(rv2i(rv).(map[uint8]int8), e)
  6061. }
  6062. func (_ fastpathT) EncMapUint8Int8V(v map[uint8]int8, e *Encoder) {
  6063. if v == nil {
  6064. e.e.EncodeNil()
  6065. return
  6066. }
  6067. ee, esep := e.e, e.hh.hasElemSeparators()
  6068. ee.WriteMapStart(len(v))
  6069. if e.h.Canonical {
  6070. v2 := make([]uint64, len(v))
  6071. var i int
  6072. for k, _ := range v {
  6073. v2[i] = uint64(k)
  6074. i++
  6075. }
  6076. sort.Sort(uintSlice(v2))
  6077. for _, k2 := range v2 {
  6078. if esep {
  6079. ee.WriteMapElemKey()
  6080. }
  6081. ee.EncodeUint(uint64(uint8(k2)))
  6082. if esep {
  6083. ee.WriteMapElemValue()
  6084. }
  6085. ee.EncodeInt(int64(v[uint8(k2)]))
  6086. }
  6087. } else {
  6088. for k2, v2 := range v {
  6089. if esep {
  6090. ee.WriteMapElemKey()
  6091. }
  6092. ee.EncodeUint(uint64(k2))
  6093. if esep {
  6094. ee.WriteMapElemValue()
  6095. }
  6096. ee.EncodeInt(int64(v2))
  6097. }
  6098. }
  6099. ee.WriteMapEnd()
  6100. }
  6101. func (e *Encoder) fastpathEncMapUint8Int16R(f *codecFnInfo, rv reflect.Value) {
  6102. fastpathTV.EncMapUint8Int16V(rv2i(rv).(map[uint8]int16), e)
  6103. }
  6104. func (_ fastpathT) EncMapUint8Int16V(v map[uint8]int16, e *Encoder) {
  6105. if v == nil {
  6106. e.e.EncodeNil()
  6107. return
  6108. }
  6109. ee, esep := e.e, e.hh.hasElemSeparators()
  6110. ee.WriteMapStart(len(v))
  6111. if e.h.Canonical {
  6112. v2 := make([]uint64, len(v))
  6113. var i int
  6114. for k, _ := range v {
  6115. v2[i] = uint64(k)
  6116. i++
  6117. }
  6118. sort.Sort(uintSlice(v2))
  6119. for _, k2 := range v2 {
  6120. if esep {
  6121. ee.WriteMapElemKey()
  6122. }
  6123. ee.EncodeUint(uint64(uint8(k2)))
  6124. if esep {
  6125. ee.WriteMapElemValue()
  6126. }
  6127. ee.EncodeInt(int64(v[uint8(k2)]))
  6128. }
  6129. } else {
  6130. for k2, v2 := range v {
  6131. if esep {
  6132. ee.WriteMapElemKey()
  6133. }
  6134. ee.EncodeUint(uint64(k2))
  6135. if esep {
  6136. ee.WriteMapElemValue()
  6137. }
  6138. ee.EncodeInt(int64(v2))
  6139. }
  6140. }
  6141. ee.WriteMapEnd()
  6142. }
  6143. func (e *Encoder) fastpathEncMapUint8Int32R(f *codecFnInfo, rv reflect.Value) {
  6144. fastpathTV.EncMapUint8Int32V(rv2i(rv).(map[uint8]int32), e)
  6145. }
  6146. func (_ fastpathT) EncMapUint8Int32V(v map[uint8]int32, e *Encoder) {
  6147. if v == nil {
  6148. e.e.EncodeNil()
  6149. return
  6150. }
  6151. ee, esep := e.e, e.hh.hasElemSeparators()
  6152. ee.WriteMapStart(len(v))
  6153. if e.h.Canonical {
  6154. v2 := make([]uint64, len(v))
  6155. var i int
  6156. for k, _ := range v {
  6157. v2[i] = uint64(k)
  6158. i++
  6159. }
  6160. sort.Sort(uintSlice(v2))
  6161. for _, k2 := range v2 {
  6162. if esep {
  6163. ee.WriteMapElemKey()
  6164. }
  6165. ee.EncodeUint(uint64(uint8(k2)))
  6166. if esep {
  6167. ee.WriteMapElemValue()
  6168. }
  6169. ee.EncodeInt(int64(v[uint8(k2)]))
  6170. }
  6171. } else {
  6172. for k2, v2 := range v {
  6173. if esep {
  6174. ee.WriteMapElemKey()
  6175. }
  6176. ee.EncodeUint(uint64(k2))
  6177. if esep {
  6178. ee.WriteMapElemValue()
  6179. }
  6180. ee.EncodeInt(int64(v2))
  6181. }
  6182. }
  6183. ee.WriteMapEnd()
  6184. }
  6185. func (e *Encoder) fastpathEncMapUint8Int64R(f *codecFnInfo, rv reflect.Value) {
  6186. fastpathTV.EncMapUint8Int64V(rv2i(rv).(map[uint8]int64), e)
  6187. }
  6188. func (_ fastpathT) EncMapUint8Int64V(v map[uint8]int64, e *Encoder) {
  6189. if v == nil {
  6190. e.e.EncodeNil()
  6191. return
  6192. }
  6193. ee, esep := e.e, e.hh.hasElemSeparators()
  6194. ee.WriteMapStart(len(v))
  6195. if e.h.Canonical {
  6196. v2 := make([]uint64, len(v))
  6197. var i int
  6198. for k, _ := range v {
  6199. v2[i] = uint64(k)
  6200. i++
  6201. }
  6202. sort.Sort(uintSlice(v2))
  6203. for _, k2 := range v2 {
  6204. if esep {
  6205. ee.WriteMapElemKey()
  6206. }
  6207. ee.EncodeUint(uint64(uint8(k2)))
  6208. if esep {
  6209. ee.WriteMapElemValue()
  6210. }
  6211. ee.EncodeInt(int64(v[uint8(k2)]))
  6212. }
  6213. } else {
  6214. for k2, v2 := range v {
  6215. if esep {
  6216. ee.WriteMapElemKey()
  6217. }
  6218. ee.EncodeUint(uint64(k2))
  6219. if esep {
  6220. ee.WriteMapElemValue()
  6221. }
  6222. ee.EncodeInt(int64(v2))
  6223. }
  6224. }
  6225. ee.WriteMapEnd()
  6226. }
  6227. func (e *Encoder) fastpathEncMapUint8Float32R(f *codecFnInfo, rv reflect.Value) {
  6228. fastpathTV.EncMapUint8Float32V(rv2i(rv).(map[uint8]float32), e)
  6229. }
  6230. func (_ fastpathT) EncMapUint8Float32V(v map[uint8]float32, e *Encoder) {
  6231. if v == nil {
  6232. e.e.EncodeNil()
  6233. return
  6234. }
  6235. ee, esep := e.e, e.hh.hasElemSeparators()
  6236. ee.WriteMapStart(len(v))
  6237. if e.h.Canonical {
  6238. v2 := make([]uint64, len(v))
  6239. var i int
  6240. for k, _ := range v {
  6241. v2[i] = uint64(k)
  6242. i++
  6243. }
  6244. sort.Sort(uintSlice(v2))
  6245. for _, k2 := range v2 {
  6246. if esep {
  6247. ee.WriteMapElemKey()
  6248. }
  6249. ee.EncodeUint(uint64(uint8(k2)))
  6250. if esep {
  6251. ee.WriteMapElemValue()
  6252. }
  6253. ee.EncodeFloat32(v[uint8(k2)])
  6254. }
  6255. } else {
  6256. for k2, v2 := range v {
  6257. if esep {
  6258. ee.WriteMapElemKey()
  6259. }
  6260. ee.EncodeUint(uint64(k2))
  6261. if esep {
  6262. ee.WriteMapElemValue()
  6263. }
  6264. ee.EncodeFloat32(v2)
  6265. }
  6266. }
  6267. ee.WriteMapEnd()
  6268. }
  6269. func (e *Encoder) fastpathEncMapUint8Float64R(f *codecFnInfo, rv reflect.Value) {
  6270. fastpathTV.EncMapUint8Float64V(rv2i(rv).(map[uint8]float64), e)
  6271. }
  6272. func (_ fastpathT) EncMapUint8Float64V(v map[uint8]float64, e *Encoder) {
  6273. if v == nil {
  6274. e.e.EncodeNil()
  6275. return
  6276. }
  6277. ee, esep := e.e, e.hh.hasElemSeparators()
  6278. ee.WriteMapStart(len(v))
  6279. if e.h.Canonical {
  6280. v2 := make([]uint64, len(v))
  6281. var i int
  6282. for k, _ := range v {
  6283. v2[i] = uint64(k)
  6284. i++
  6285. }
  6286. sort.Sort(uintSlice(v2))
  6287. for _, k2 := range v2 {
  6288. if esep {
  6289. ee.WriteMapElemKey()
  6290. }
  6291. ee.EncodeUint(uint64(uint8(k2)))
  6292. if esep {
  6293. ee.WriteMapElemValue()
  6294. }
  6295. ee.EncodeFloat64(v[uint8(k2)])
  6296. }
  6297. } else {
  6298. for k2, v2 := range v {
  6299. if esep {
  6300. ee.WriteMapElemKey()
  6301. }
  6302. ee.EncodeUint(uint64(k2))
  6303. if esep {
  6304. ee.WriteMapElemValue()
  6305. }
  6306. ee.EncodeFloat64(v2)
  6307. }
  6308. }
  6309. ee.WriteMapEnd()
  6310. }
  6311. func (e *Encoder) fastpathEncMapUint8BoolR(f *codecFnInfo, rv reflect.Value) {
  6312. fastpathTV.EncMapUint8BoolV(rv2i(rv).(map[uint8]bool), e)
  6313. }
  6314. func (_ fastpathT) EncMapUint8BoolV(v map[uint8]bool, e *Encoder) {
  6315. if v == nil {
  6316. e.e.EncodeNil()
  6317. return
  6318. }
  6319. ee, esep := e.e, e.hh.hasElemSeparators()
  6320. ee.WriteMapStart(len(v))
  6321. if e.h.Canonical {
  6322. v2 := make([]uint64, len(v))
  6323. var i int
  6324. for k, _ := range v {
  6325. v2[i] = uint64(k)
  6326. i++
  6327. }
  6328. sort.Sort(uintSlice(v2))
  6329. for _, k2 := range v2 {
  6330. if esep {
  6331. ee.WriteMapElemKey()
  6332. }
  6333. ee.EncodeUint(uint64(uint8(k2)))
  6334. if esep {
  6335. ee.WriteMapElemValue()
  6336. }
  6337. ee.EncodeBool(v[uint8(k2)])
  6338. }
  6339. } else {
  6340. for k2, v2 := range v {
  6341. if esep {
  6342. ee.WriteMapElemKey()
  6343. }
  6344. ee.EncodeUint(uint64(k2))
  6345. if esep {
  6346. ee.WriteMapElemValue()
  6347. }
  6348. ee.EncodeBool(v2)
  6349. }
  6350. }
  6351. ee.WriteMapEnd()
  6352. }
  6353. func (e *Encoder) fastpathEncMapUint16IntfR(f *codecFnInfo, rv reflect.Value) {
  6354. fastpathTV.EncMapUint16IntfV(rv2i(rv).(map[uint16]interface{}), e)
  6355. }
  6356. func (_ fastpathT) EncMapUint16IntfV(v map[uint16]interface{}, e *Encoder) {
  6357. if v == nil {
  6358. e.e.EncodeNil()
  6359. return
  6360. }
  6361. ee, esep := e.e, e.hh.hasElemSeparators()
  6362. ee.WriteMapStart(len(v))
  6363. if e.h.Canonical {
  6364. v2 := make([]uint64, len(v))
  6365. var i int
  6366. for k, _ := range v {
  6367. v2[i] = uint64(k)
  6368. i++
  6369. }
  6370. sort.Sort(uintSlice(v2))
  6371. for _, k2 := range v2 {
  6372. if esep {
  6373. ee.WriteMapElemKey()
  6374. }
  6375. ee.EncodeUint(uint64(uint16(k2)))
  6376. if esep {
  6377. ee.WriteMapElemValue()
  6378. }
  6379. e.encode(v[uint16(k2)])
  6380. }
  6381. } else {
  6382. for k2, v2 := range v {
  6383. if esep {
  6384. ee.WriteMapElemKey()
  6385. }
  6386. ee.EncodeUint(uint64(k2))
  6387. if esep {
  6388. ee.WriteMapElemValue()
  6389. }
  6390. e.encode(v2)
  6391. }
  6392. }
  6393. ee.WriteMapEnd()
  6394. }
  6395. func (e *Encoder) fastpathEncMapUint16StringR(f *codecFnInfo, rv reflect.Value) {
  6396. fastpathTV.EncMapUint16StringV(rv2i(rv).(map[uint16]string), e)
  6397. }
  6398. func (_ fastpathT) EncMapUint16StringV(v map[uint16]string, e *Encoder) {
  6399. if v == nil {
  6400. e.e.EncodeNil()
  6401. return
  6402. }
  6403. ee, esep := e.e, e.hh.hasElemSeparators()
  6404. ee.WriteMapStart(len(v))
  6405. if e.h.Canonical {
  6406. v2 := make([]uint64, len(v))
  6407. var i int
  6408. for k, _ := range v {
  6409. v2[i] = uint64(k)
  6410. i++
  6411. }
  6412. sort.Sort(uintSlice(v2))
  6413. for _, k2 := range v2 {
  6414. if esep {
  6415. ee.WriteMapElemKey()
  6416. }
  6417. ee.EncodeUint(uint64(uint16(k2)))
  6418. if esep {
  6419. ee.WriteMapElemValue()
  6420. }
  6421. ee.EncodeString(c_UTF8, v[uint16(k2)])
  6422. }
  6423. } else {
  6424. for k2, v2 := range v {
  6425. if esep {
  6426. ee.WriteMapElemKey()
  6427. }
  6428. ee.EncodeUint(uint64(k2))
  6429. if esep {
  6430. ee.WriteMapElemValue()
  6431. }
  6432. ee.EncodeString(c_UTF8, v2)
  6433. }
  6434. }
  6435. ee.WriteMapEnd()
  6436. }
  6437. func (e *Encoder) fastpathEncMapUint16UintR(f *codecFnInfo, rv reflect.Value) {
  6438. fastpathTV.EncMapUint16UintV(rv2i(rv).(map[uint16]uint), e)
  6439. }
  6440. func (_ fastpathT) EncMapUint16UintV(v map[uint16]uint, e *Encoder) {
  6441. if v == nil {
  6442. e.e.EncodeNil()
  6443. return
  6444. }
  6445. ee, esep := e.e, e.hh.hasElemSeparators()
  6446. ee.WriteMapStart(len(v))
  6447. if e.h.Canonical {
  6448. v2 := make([]uint64, len(v))
  6449. var i int
  6450. for k, _ := range v {
  6451. v2[i] = uint64(k)
  6452. i++
  6453. }
  6454. sort.Sort(uintSlice(v2))
  6455. for _, k2 := range v2 {
  6456. if esep {
  6457. ee.WriteMapElemKey()
  6458. }
  6459. ee.EncodeUint(uint64(uint16(k2)))
  6460. if esep {
  6461. ee.WriteMapElemValue()
  6462. }
  6463. ee.EncodeUint(uint64(v[uint16(k2)]))
  6464. }
  6465. } else {
  6466. for k2, v2 := range v {
  6467. if esep {
  6468. ee.WriteMapElemKey()
  6469. }
  6470. ee.EncodeUint(uint64(k2))
  6471. if esep {
  6472. ee.WriteMapElemValue()
  6473. }
  6474. ee.EncodeUint(uint64(v2))
  6475. }
  6476. }
  6477. ee.WriteMapEnd()
  6478. }
  6479. func (e *Encoder) fastpathEncMapUint16Uint8R(f *codecFnInfo, rv reflect.Value) {
  6480. fastpathTV.EncMapUint16Uint8V(rv2i(rv).(map[uint16]uint8), e)
  6481. }
  6482. func (_ fastpathT) EncMapUint16Uint8V(v map[uint16]uint8, e *Encoder) {
  6483. if v == nil {
  6484. e.e.EncodeNil()
  6485. return
  6486. }
  6487. ee, esep := e.e, e.hh.hasElemSeparators()
  6488. ee.WriteMapStart(len(v))
  6489. if e.h.Canonical {
  6490. v2 := make([]uint64, len(v))
  6491. var i int
  6492. for k, _ := range v {
  6493. v2[i] = uint64(k)
  6494. i++
  6495. }
  6496. sort.Sort(uintSlice(v2))
  6497. for _, k2 := range v2 {
  6498. if esep {
  6499. ee.WriteMapElemKey()
  6500. }
  6501. ee.EncodeUint(uint64(uint16(k2)))
  6502. if esep {
  6503. ee.WriteMapElemValue()
  6504. }
  6505. ee.EncodeUint(uint64(v[uint16(k2)]))
  6506. }
  6507. } else {
  6508. for k2, v2 := range v {
  6509. if esep {
  6510. ee.WriteMapElemKey()
  6511. }
  6512. ee.EncodeUint(uint64(k2))
  6513. if esep {
  6514. ee.WriteMapElemValue()
  6515. }
  6516. ee.EncodeUint(uint64(v2))
  6517. }
  6518. }
  6519. ee.WriteMapEnd()
  6520. }
  6521. func (e *Encoder) fastpathEncMapUint16Uint16R(f *codecFnInfo, rv reflect.Value) {
  6522. fastpathTV.EncMapUint16Uint16V(rv2i(rv).(map[uint16]uint16), e)
  6523. }
  6524. func (_ fastpathT) EncMapUint16Uint16V(v map[uint16]uint16, e *Encoder) {
  6525. if v == nil {
  6526. e.e.EncodeNil()
  6527. return
  6528. }
  6529. ee, esep := e.e, e.hh.hasElemSeparators()
  6530. ee.WriteMapStart(len(v))
  6531. if e.h.Canonical {
  6532. v2 := make([]uint64, len(v))
  6533. var i int
  6534. for k, _ := range v {
  6535. v2[i] = uint64(k)
  6536. i++
  6537. }
  6538. sort.Sort(uintSlice(v2))
  6539. for _, k2 := range v2 {
  6540. if esep {
  6541. ee.WriteMapElemKey()
  6542. }
  6543. ee.EncodeUint(uint64(uint16(k2)))
  6544. if esep {
  6545. ee.WriteMapElemValue()
  6546. }
  6547. ee.EncodeUint(uint64(v[uint16(k2)]))
  6548. }
  6549. } else {
  6550. for k2, v2 := range v {
  6551. if esep {
  6552. ee.WriteMapElemKey()
  6553. }
  6554. ee.EncodeUint(uint64(k2))
  6555. if esep {
  6556. ee.WriteMapElemValue()
  6557. }
  6558. ee.EncodeUint(uint64(v2))
  6559. }
  6560. }
  6561. ee.WriteMapEnd()
  6562. }
  6563. func (e *Encoder) fastpathEncMapUint16Uint32R(f *codecFnInfo, rv reflect.Value) {
  6564. fastpathTV.EncMapUint16Uint32V(rv2i(rv).(map[uint16]uint32), e)
  6565. }
  6566. func (_ fastpathT) EncMapUint16Uint32V(v map[uint16]uint32, e *Encoder) {
  6567. if v == nil {
  6568. e.e.EncodeNil()
  6569. return
  6570. }
  6571. ee, esep := e.e, e.hh.hasElemSeparators()
  6572. ee.WriteMapStart(len(v))
  6573. if e.h.Canonical {
  6574. v2 := make([]uint64, len(v))
  6575. var i int
  6576. for k, _ := range v {
  6577. v2[i] = uint64(k)
  6578. i++
  6579. }
  6580. sort.Sort(uintSlice(v2))
  6581. for _, k2 := range v2 {
  6582. if esep {
  6583. ee.WriteMapElemKey()
  6584. }
  6585. ee.EncodeUint(uint64(uint16(k2)))
  6586. if esep {
  6587. ee.WriteMapElemValue()
  6588. }
  6589. ee.EncodeUint(uint64(v[uint16(k2)]))
  6590. }
  6591. } else {
  6592. for k2, v2 := range v {
  6593. if esep {
  6594. ee.WriteMapElemKey()
  6595. }
  6596. ee.EncodeUint(uint64(k2))
  6597. if esep {
  6598. ee.WriteMapElemValue()
  6599. }
  6600. ee.EncodeUint(uint64(v2))
  6601. }
  6602. }
  6603. ee.WriteMapEnd()
  6604. }
  6605. func (e *Encoder) fastpathEncMapUint16Uint64R(f *codecFnInfo, rv reflect.Value) {
  6606. fastpathTV.EncMapUint16Uint64V(rv2i(rv).(map[uint16]uint64), e)
  6607. }
  6608. func (_ fastpathT) EncMapUint16Uint64V(v map[uint16]uint64, e *Encoder) {
  6609. if v == nil {
  6610. e.e.EncodeNil()
  6611. return
  6612. }
  6613. ee, esep := e.e, e.hh.hasElemSeparators()
  6614. ee.WriteMapStart(len(v))
  6615. if e.h.Canonical {
  6616. v2 := make([]uint64, len(v))
  6617. var i int
  6618. for k, _ := range v {
  6619. v2[i] = uint64(k)
  6620. i++
  6621. }
  6622. sort.Sort(uintSlice(v2))
  6623. for _, k2 := range v2 {
  6624. if esep {
  6625. ee.WriteMapElemKey()
  6626. }
  6627. ee.EncodeUint(uint64(uint16(k2)))
  6628. if esep {
  6629. ee.WriteMapElemValue()
  6630. }
  6631. ee.EncodeUint(uint64(v[uint16(k2)]))
  6632. }
  6633. } else {
  6634. for k2, v2 := range v {
  6635. if esep {
  6636. ee.WriteMapElemKey()
  6637. }
  6638. ee.EncodeUint(uint64(k2))
  6639. if esep {
  6640. ee.WriteMapElemValue()
  6641. }
  6642. ee.EncodeUint(uint64(v2))
  6643. }
  6644. }
  6645. ee.WriteMapEnd()
  6646. }
  6647. func (e *Encoder) fastpathEncMapUint16UintptrR(f *codecFnInfo, rv reflect.Value) {
  6648. fastpathTV.EncMapUint16UintptrV(rv2i(rv).(map[uint16]uintptr), e)
  6649. }
  6650. func (_ fastpathT) EncMapUint16UintptrV(v map[uint16]uintptr, e *Encoder) {
  6651. if v == nil {
  6652. e.e.EncodeNil()
  6653. return
  6654. }
  6655. ee, esep := e.e, e.hh.hasElemSeparators()
  6656. ee.WriteMapStart(len(v))
  6657. if e.h.Canonical {
  6658. v2 := make([]uint64, len(v))
  6659. var i int
  6660. for k, _ := range v {
  6661. v2[i] = uint64(k)
  6662. i++
  6663. }
  6664. sort.Sort(uintSlice(v2))
  6665. for _, k2 := range v2 {
  6666. if esep {
  6667. ee.WriteMapElemKey()
  6668. }
  6669. ee.EncodeUint(uint64(uint16(k2)))
  6670. if esep {
  6671. ee.WriteMapElemValue()
  6672. }
  6673. e.encode(v[uint16(k2)])
  6674. }
  6675. } else {
  6676. for k2, v2 := range v {
  6677. if esep {
  6678. ee.WriteMapElemKey()
  6679. }
  6680. ee.EncodeUint(uint64(k2))
  6681. if esep {
  6682. ee.WriteMapElemValue()
  6683. }
  6684. e.encode(v2)
  6685. }
  6686. }
  6687. ee.WriteMapEnd()
  6688. }
  6689. func (e *Encoder) fastpathEncMapUint16IntR(f *codecFnInfo, rv reflect.Value) {
  6690. fastpathTV.EncMapUint16IntV(rv2i(rv).(map[uint16]int), e)
  6691. }
  6692. func (_ fastpathT) EncMapUint16IntV(v map[uint16]int, e *Encoder) {
  6693. if v == nil {
  6694. e.e.EncodeNil()
  6695. return
  6696. }
  6697. ee, esep := e.e, e.hh.hasElemSeparators()
  6698. ee.WriteMapStart(len(v))
  6699. if e.h.Canonical {
  6700. v2 := make([]uint64, len(v))
  6701. var i int
  6702. for k, _ := range v {
  6703. v2[i] = uint64(k)
  6704. i++
  6705. }
  6706. sort.Sort(uintSlice(v2))
  6707. for _, k2 := range v2 {
  6708. if esep {
  6709. ee.WriteMapElemKey()
  6710. }
  6711. ee.EncodeUint(uint64(uint16(k2)))
  6712. if esep {
  6713. ee.WriteMapElemValue()
  6714. }
  6715. ee.EncodeInt(int64(v[uint16(k2)]))
  6716. }
  6717. } else {
  6718. for k2, v2 := range v {
  6719. if esep {
  6720. ee.WriteMapElemKey()
  6721. }
  6722. ee.EncodeUint(uint64(k2))
  6723. if esep {
  6724. ee.WriteMapElemValue()
  6725. }
  6726. ee.EncodeInt(int64(v2))
  6727. }
  6728. }
  6729. ee.WriteMapEnd()
  6730. }
  6731. func (e *Encoder) fastpathEncMapUint16Int8R(f *codecFnInfo, rv reflect.Value) {
  6732. fastpathTV.EncMapUint16Int8V(rv2i(rv).(map[uint16]int8), e)
  6733. }
  6734. func (_ fastpathT) EncMapUint16Int8V(v map[uint16]int8, e *Encoder) {
  6735. if v == nil {
  6736. e.e.EncodeNil()
  6737. return
  6738. }
  6739. ee, esep := e.e, e.hh.hasElemSeparators()
  6740. ee.WriteMapStart(len(v))
  6741. if e.h.Canonical {
  6742. v2 := make([]uint64, len(v))
  6743. var i int
  6744. for k, _ := range v {
  6745. v2[i] = uint64(k)
  6746. i++
  6747. }
  6748. sort.Sort(uintSlice(v2))
  6749. for _, k2 := range v2 {
  6750. if esep {
  6751. ee.WriteMapElemKey()
  6752. }
  6753. ee.EncodeUint(uint64(uint16(k2)))
  6754. if esep {
  6755. ee.WriteMapElemValue()
  6756. }
  6757. ee.EncodeInt(int64(v[uint16(k2)]))
  6758. }
  6759. } else {
  6760. for k2, v2 := range v {
  6761. if esep {
  6762. ee.WriteMapElemKey()
  6763. }
  6764. ee.EncodeUint(uint64(k2))
  6765. if esep {
  6766. ee.WriteMapElemValue()
  6767. }
  6768. ee.EncodeInt(int64(v2))
  6769. }
  6770. }
  6771. ee.WriteMapEnd()
  6772. }
  6773. func (e *Encoder) fastpathEncMapUint16Int16R(f *codecFnInfo, rv reflect.Value) {
  6774. fastpathTV.EncMapUint16Int16V(rv2i(rv).(map[uint16]int16), e)
  6775. }
  6776. func (_ fastpathT) EncMapUint16Int16V(v map[uint16]int16, e *Encoder) {
  6777. if v == nil {
  6778. e.e.EncodeNil()
  6779. return
  6780. }
  6781. ee, esep := e.e, e.hh.hasElemSeparators()
  6782. ee.WriteMapStart(len(v))
  6783. if e.h.Canonical {
  6784. v2 := make([]uint64, len(v))
  6785. var i int
  6786. for k, _ := range v {
  6787. v2[i] = uint64(k)
  6788. i++
  6789. }
  6790. sort.Sort(uintSlice(v2))
  6791. for _, k2 := range v2 {
  6792. if esep {
  6793. ee.WriteMapElemKey()
  6794. }
  6795. ee.EncodeUint(uint64(uint16(k2)))
  6796. if esep {
  6797. ee.WriteMapElemValue()
  6798. }
  6799. ee.EncodeInt(int64(v[uint16(k2)]))
  6800. }
  6801. } else {
  6802. for k2, v2 := range v {
  6803. if esep {
  6804. ee.WriteMapElemKey()
  6805. }
  6806. ee.EncodeUint(uint64(k2))
  6807. if esep {
  6808. ee.WriteMapElemValue()
  6809. }
  6810. ee.EncodeInt(int64(v2))
  6811. }
  6812. }
  6813. ee.WriteMapEnd()
  6814. }
  6815. func (e *Encoder) fastpathEncMapUint16Int32R(f *codecFnInfo, rv reflect.Value) {
  6816. fastpathTV.EncMapUint16Int32V(rv2i(rv).(map[uint16]int32), e)
  6817. }
  6818. func (_ fastpathT) EncMapUint16Int32V(v map[uint16]int32, e *Encoder) {
  6819. if v == nil {
  6820. e.e.EncodeNil()
  6821. return
  6822. }
  6823. ee, esep := e.e, e.hh.hasElemSeparators()
  6824. ee.WriteMapStart(len(v))
  6825. if e.h.Canonical {
  6826. v2 := make([]uint64, len(v))
  6827. var i int
  6828. for k, _ := range v {
  6829. v2[i] = uint64(k)
  6830. i++
  6831. }
  6832. sort.Sort(uintSlice(v2))
  6833. for _, k2 := range v2 {
  6834. if esep {
  6835. ee.WriteMapElemKey()
  6836. }
  6837. ee.EncodeUint(uint64(uint16(k2)))
  6838. if esep {
  6839. ee.WriteMapElemValue()
  6840. }
  6841. ee.EncodeInt(int64(v[uint16(k2)]))
  6842. }
  6843. } else {
  6844. for k2, v2 := range v {
  6845. if esep {
  6846. ee.WriteMapElemKey()
  6847. }
  6848. ee.EncodeUint(uint64(k2))
  6849. if esep {
  6850. ee.WriteMapElemValue()
  6851. }
  6852. ee.EncodeInt(int64(v2))
  6853. }
  6854. }
  6855. ee.WriteMapEnd()
  6856. }
  6857. func (e *Encoder) fastpathEncMapUint16Int64R(f *codecFnInfo, rv reflect.Value) {
  6858. fastpathTV.EncMapUint16Int64V(rv2i(rv).(map[uint16]int64), e)
  6859. }
  6860. func (_ fastpathT) EncMapUint16Int64V(v map[uint16]int64, e *Encoder) {
  6861. if v == nil {
  6862. e.e.EncodeNil()
  6863. return
  6864. }
  6865. ee, esep := e.e, e.hh.hasElemSeparators()
  6866. ee.WriteMapStart(len(v))
  6867. if e.h.Canonical {
  6868. v2 := make([]uint64, len(v))
  6869. var i int
  6870. for k, _ := range v {
  6871. v2[i] = uint64(k)
  6872. i++
  6873. }
  6874. sort.Sort(uintSlice(v2))
  6875. for _, k2 := range v2 {
  6876. if esep {
  6877. ee.WriteMapElemKey()
  6878. }
  6879. ee.EncodeUint(uint64(uint16(k2)))
  6880. if esep {
  6881. ee.WriteMapElemValue()
  6882. }
  6883. ee.EncodeInt(int64(v[uint16(k2)]))
  6884. }
  6885. } else {
  6886. for k2, v2 := range v {
  6887. if esep {
  6888. ee.WriteMapElemKey()
  6889. }
  6890. ee.EncodeUint(uint64(k2))
  6891. if esep {
  6892. ee.WriteMapElemValue()
  6893. }
  6894. ee.EncodeInt(int64(v2))
  6895. }
  6896. }
  6897. ee.WriteMapEnd()
  6898. }
  6899. func (e *Encoder) fastpathEncMapUint16Float32R(f *codecFnInfo, rv reflect.Value) {
  6900. fastpathTV.EncMapUint16Float32V(rv2i(rv).(map[uint16]float32), e)
  6901. }
  6902. func (_ fastpathT) EncMapUint16Float32V(v map[uint16]float32, e *Encoder) {
  6903. if v == nil {
  6904. e.e.EncodeNil()
  6905. return
  6906. }
  6907. ee, esep := e.e, e.hh.hasElemSeparators()
  6908. ee.WriteMapStart(len(v))
  6909. if e.h.Canonical {
  6910. v2 := make([]uint64, len(v))
  6911. var i int
  6912. for k, _ := range v {
  6913. v2[i] = uint64(k)
  6914. i++
  6915. }
  6916. sort.Sort(uintSlice(v2))
  6917. for _, k2 := range v2 {
  6918. if esep {
  6919. ee.WriteMapElemKey()
  6920. }
  6921. ee.EncodeUint(uint64(uint16(k2)))
  6922. if esep {
  6923. ee.WriteMapElemValue()
  6924. }
  6925. ee.EncodeFloat32(v[uint16(k2)])
  6926. }
  6927. } else {
  6928. for k2, v2 := range v {
  6929. if esep {
  6930. ee.WriteMapElemKey()
  6931. }
  6932. ee.EncodeUint(uint64(k2))
  6933. if esep {
  6934. ee.WriteMapElemValue()
  6935. }
  6936. ee.EncodeFloat32(v2)
  6937. }
  6938. }
  6939. ee.WriteMapEnd()
  6940. }
  6941. func (e *Encoder) fastpathEncMapUint16Float64R(f *codecFnInfo, rv reflect.Value) {
  6942. fastpathTV.EncMapUint16Float64V(rv2i(rv).(map[uint16]float64), e)
  6943. }
  6944. func (_ fastpathT) EncMapUint16Float64V(v map[uint16]float64, e *Encoder) {
  6945. if v == nil {
  6946. e.e.EncodeNil()
  6947. return
  6948. }
  6949. ee, esep := e.e, e.hh.hasElemSeparators()
  6950. ee.WriteMapStart(len(v))
  6951. if e.h.Canonical {
  6952. v2 := make([]uint64, len(v))
  6953. var i int
  6954. for k, _ := range v {
  6955. v2[i] = uint64(k)
  6956. i++
  6957. }
  6958. sort.Sort(uintSlice(v2))
  6959. for _, k2 := range v2 {
  6960. if esep {
  6961. ee.WriteMapElemKey()
  6962. }
  6963. ee.EncodeUint(uint64(uint16(k2)))
  6964. if esep {
  6965. ee.WriteMapElemValue()
  6966. }
  6967. ee.EncodeFloat64(v[uint16(k2)])
  6968. }
  6969. } else {
  6970. for k2, v2 := range v {
  6971. if esep {
  6972. ee.WriteMapElemKey()
  6973. }
  6974. ee.EncodeUint(uint64(k2))
  6975. if esep {
  6976. ee.WriteMapElemValue()
  6977. }
  6978. ee.EncodeFloat64(v2)
  6979. }
  6980. }
  6981. ee.WriteMapEnd()
  6982. }
  6983. func (e *Encoder) fastpathEncMapUint16BoolR(f *codecFnInfo, rv reflect.Value) {
  6984. fastpathTV.EncMapUint16BoolV(rv2i(rv).(map[uint16]bool), e)
  6985. }
  6986. func (_ fastpathT) EncMapUint16BoolV(v map[uint16]bool, e *Encoder) {
  6987. if v == nil {
  6988. e.e.EncodeNil()
  6989. return
  6990. }
  6991. ee, esep := e.e, e.hh.hasElemSeparators()
  6992. ee.WriteMapStart(len(v))
  6993. if e.h.Canonical {
  6994. v2 := make([]uint64, len(v))
  6995. var i int
  6996. for k, _ := range v {
  6997. v2[i] = uint64(k)
  6998. i++
  6999. }
  7000. sort.Sort(uintSlice(v2))
  7001. for _, k2 := range v2 {
  7002. if esep {
  7003. ee.WriteMapElemKey()
  7004. }
  7005. ee.EncodeUint(uint64(uint16(k2)))
  7006. if esep {
  7007. ee.WriteMapElemValue()
  7008. }
  7009. ee.EncodeBool(v[uint16(k2)])
  7010. }
  7011. } else {
  7012. for k2, v2 := range v {
  7013. if esep {
  7014. ee.WriteMapElemKey()
  7015. }
  7016. ee.EncodeUint(uint64(k2))
  7017. if esep {
  7018. ee.WriteMapElemValue()
  7019. }
  7020. ee.EncodeBool(v2)
  7021. }
  7022. }
  7023. ee.WriteMapEnd()
  7024. }
  7025. func (e *Encoder) fastpathEncMapUint32IntfR(f *codecFnInfo, rv reflect.Value) {
  7026. fastpathTV.EncMapUint32IntfV(rv2i(rv).(map[uint32]interface{}), e)
  7027. }
  7028. func (_ fastpathT) EncMapUint32IntfV(v map[uint32]interface{}, e *Encoder) {
  7029. if v == nil {
  7030. e.e.EncodeNil()
  7031. return
  7032. }
  7033. ee, esep := e.e, e.hh.hasElemSeparators()
  7034. ee.WriteMapStart(len(v))
  7035. if e.h.Canonical {
  7036. v2 := make([]uint64, len(v))
  7037. var i int
  7038. for k, _ := range v {
  7039. v2[i] = uint64(k)
  7040. i++
  7041. }
  7042. sort.Sort(uintSlice(v2))
  7043. for _, k2 := range v2 {
  7044. if esep {
  7045. ee.WriteMapElemKey()
  7046. }
  7047. ee.EncodeUint(uint64(uint32(k2)))
  7048. if esep {
  7049. ee.WriteMapElemValue()
  7050. }
  7051. e.encode(v[uint32(k2)])
  7052. }
  7053. } else {
  7054. for k2, v2 := range v {
  7055. if esep {
  7056. ee.WriteMapElemKey()
  7057. }
  7058. ee.EncodeUint(uint64(k2))
  7059. if esep {
  7060. ee.WriteMapElemValue()
  7061. }
  7062. e.encode(v2)
  7063. }
  7064. }
  7065. ee.WriteMapEnd()
  7066. }
  7067. func (e *Encoder) fastpathEncMapUint32StringR(f *codecFnInfo, rv reflect.Value) {
  7068. fastpathTV.EncMapUint32StringV(rv2i(rv).(map[uint32]string), e)
  7069. }
  7070. func (_ fastpathT) EncMapUint32StringV(v map[uint32]string, e *Encoder) {
  7071. if v == nil {
  7072. e.e.EncodeNil()
  7073. return
  7074. }
  7075. ee, esep := e.e, e.hh.hasElemSeparators()
  7076. ee.WriteMapStart(len(v))
  7077. if e.h.Canonical {
  7078. v2 := make([]uint64, len(v))
  7079. var i int
  7080. for k, _ := range v {
  7081. v2[i] = uint64(k)
  7082. i++
  7083. }
  7084. sort.Sort(uintSlice(v2))
  7085. for _, k2 := range v2 {
  7086. if esep {
  7087. ee.WriteMapElemKey()
  7088. }
  7089. ee.EncodeUint(uint64(uint32(k2)))
  7090. if esep {
  7091. ee.WriteMapElemValue()
  7092. }
  7093. ee.EncodeString(c_UTF8, v[uint32(k2)])
  7094. }
  7095. } else {
  7096. for k2, v2 := range v {
  7097. if esep {
  7098. ee.WriteMapElemKey()
  7099. }
  7100. ee.EncodeUint(uint64(k2))
  7101. if esep {
  7102. ee.WriteMapElemValue()
  7103. }
  7104. ee.EncodeString(c_UTF8, v2)
  7105. }
  7106. }
  7107. ee.WriteMapEnd()
  7108. }
  7109. func (e *Encoder) fastpathEncMapUint32UintR(f *codecFnInfo, rv reflect.Value) {
  7110. fastpathTV.EncMapUint32UintV(rv2i(rv).(map[uint32]uint), e)
  7111. }
  7112. func (_ fastpathT) EncMapUint32UintV(v map[uint32]uint, e *Encoder) {
  7113. if v == nil {
  7114. e.e.EncodeNil()
  7115. return
  7116. }
  7117. ee, esep := e.e, e.hh.hasElemSeparators()
  7118. ee.WriteMapStart(len(v))
  7119. if e.h.Canonical {
  7120. v2 := make([]uint64, len(v))
  7121. var i int
  7122. for k, _ := range v {
  7123. v2[i] = uint64(k)
  7124. i++
  7125. }
  7126. sort.Sort(uintSlice(v2))
  7127. for _, k2 := range v2 {
  7128. if esep {
  7129. ee.WriteMapElemKey()
  7130. }
  7131. ee.EncodeUint(uint64(uint32(k2)))
  7132. if esep {
  7133. ee.WriteMapElemValue()
  7134. }
  7135. ee.EncodeUint(uint64(v[uint32(k2)]))
  7136. }
  7137. } else {
  7138. for k2, v2 := range v {
  7139. if esep {
  7140. ee.WriteMapElemKey()
  7141. }
  7142. ee.EncodeUint(uint64(k2))
  7143. if esep {
  7144. ee.WriteMapElemValue()
  7145. }
  7146. ee.EncodeUint(uint64(v2))
  7147. }
  7148. }
  7149. ee.WriteMapEnd()
  7150. }
  7151. func (e *Encoder) fastpathEncMapUint32Uint8R(f *codecFnInfo, rv reflect.Value) {
  7152. fastpathTV.EncMapUint32Uint8V(rv2i(rv).(map[uint32]uint8), e)
  7153. }
  7154. func (_ fastpathT) EncMapUint32Uint8V(v map[uint32]uint8, e *Encoder) {
  7155. if v == nil {
  7156. e.e.EncodeNil()
  7157. return
  7158. }
  7159. ee, esep := e.e, e.hh.hasElemSeparators()
  7160. ee.WriteMapStart(len(v))
  7161. if e.h.Canonical {
  7162. v2 := make([]uint64, len(v))
  7163. var i int
  7164. for k, _ := range v {
  7165. v2[i] = uint64(k)
  7166. i++
  7167. }
  7168. sort.Sort(uintSlice(v2))
  7169. for _, k2 := range v2 {
  7170. if esep {
  7171. ee.WriteMapElemKey()
  7172. }
  7173. ee.EncodeUint(uint64(uint32(k2)))
  7174. if esep {
  7175. ee.WriteMapElemValue()
  7176. }
  7177. ee.EncodeUint(uint64(v[uint32(k2)]))
  7178. }
  7179. } else {
  7180. for k2, v2 := range v {
  7181. if esep {
  7182. ee.WriteMapElemKey()
  7183. }
  7184. ee.EncodeUint(uint64(k2))
  7185. if esep {
  7186. ee.WriteMapElemValue()
  7187. }
  7188. ee.EncodeUint(uint64(v2))
  7189. }
  7190. }
  7191. ee.WriteMapEnd()
  7192. }
  7193. func (e *Encoder) fastpathEncMapUint32Uint16R(f *codecFnInfo, rv reflect.Value) {
  7194. fastpathTV.EncMapUint32Uint16V(rv2i(rv).(map[uint32]uint16), e)
  7195. }
  7196. func (_ fastpathT) EncMapUint32Uint16V(v map[uint32]uint16, e *Encoder) {
  7197. if v == nil {
  7198. e.e.EncodeNil()
  7199. return
  7200. }
  7201. ee, esep := e.e, e.hh.hasElemSeparators()
  7202. ee.WriteMapStart(len(v))
  7203. if e.h.Canonical {
  7204. v2 := make([]uint64, len(v))
  7205. var i int
  7206. for k, _ := range v {
  7207. v2[i] = uint64(k)
  7208. i++
  7209. }
  7210. sort.Sort(uintSlice(v2))
  7211. for _, k2 := range v2 {
  7212. if esep {
  7213. ee.WriteMapElemKey()
  7214. }
  7215. ee.EncodeUint(uint64(uint32(k2)))
  7216. if esep {
  7217. ee.WriteMapElemValue()
  7218. }
  7219. ee.EncodeUint(uint64(v[uint32(k2)]))
  7220. }
  7221. } else {
  7222. for k2, v2 := range v {
  7223. if esep {
  7224. ee.WriteMapElemKey()
  7225. }
  7226. ee.EncodeUint(uint64(k2))
  7227. if esep {
  7228. ee.WriteMapElemValue()
  7229. }
  7230. ee.EncodeUint(uint64(v2))
  7231. }
  7232. }
  7233. ee.WriteMapEnd()
  7234. }
  7235. func (e *Encoder) fastpathEncMapUint32Uint32R(f *codecFnInfo, rv reflect.Value) {
  7236. fastpathTV.EncMapUint32Uint32V(rv2i(rv).(map[uint32]uint32), e)
  7237. }
  7238. func (_ fastpathT) EncMapUint32Uint32V(v map[uint32]uint32, e *Encoder) {
  7239. if v == nil {
  7240. e.e.EncodeNil()
  7241. return
  7242. }
  7243. ee, esep := e.e, e.hh.hasElemSeparators()
  7244. ee.WriteMapStart(len(v))
  7245. if e.h.Canonical {
  7246. v2 := make([]uint64, len(v))
  7247. var i int
  7248. for k, _ := range v {
  7249. v2[i] = uint64(k)
  7250. i++
  7251. }
  7252. sort.Sort(uintSlice(v2))
  7253. for _, k2 := range v2 {
  7254. if esep {
  7255. ee.WriteMapElemKey()
  7256. }
  7257. ee.EncodeUint(uint64(uint32(k2)))
  7258. if esep {
  7259. ee.WriteMapElemValue()
  7260. }
  7261. ee.EncodeUint(uint64(v[uint32(k2)]))
  7262. }
  7263. } else {
  7264. for k2, v2 := range v {
  7265. if esep {
  7266. ee.WriteMapElemKey()
  7267. }
  7268. ee.EncodeUint(uint64(k2))
  7269. if esep {
  7270. ee.WriteMapElemValue()
  7271. }
  7272. ee.EncodeUint(uint64(v2))
  7273. }
  7274. }
  7275. ee.WriteMapEnd()
  7276. }
  7277. func (e *Encoder) fastpathEncMapUint32Uint64R(f *codecFnInfo, rv reflect.Value) {
  7278. fastpathTV.EncMapUint32Uint64V(rv2i(rv).(map[uint32]uint64), e)
  7279. }
  7280. func (_ fastpathT) EncMapUint32Uint64V(v map[uint32]uint64, e *Encoder) {
  7281. if v == nil {
  7282. e.e.EncodeNil()
  7283. return
  7284. }
  7285. ee, esep := e.e, e.hh.hasElemSeparators()
  7286. ee.WriteMapStart(len(v))
  7287. if e.h.Canonical {
  7288. v2 := make([]uint64, len(v))
  7289. var i int
  7290. for k, _ := range v {
  7291. v2[i] = uint64(k)
  7292. i++
  7293. }
  7294. sort.Sort(uintSlice(v2))
  7295. for _, k2 := range v2 {
  7296. if esep {
  7297. ee.WriteMapElemKey()
  7298. }
  7299. ee.EncodeUint(uint64(uint32(k2)))
  7300. if esep {
  7301. ee.WriteMapElemValue()
  7302. }
  7303. ee.EncodeUint(uint64(v[uint32(k2)]))
  7304. }
  7305. } else {
  7306. for k2, v2 := range v {
  7307. if esep {
  7308. ee.WriteMapElemKey()
  7309. }
  7310. ee.EncodeUint(uint64(k2))
  7311. if esep {
  7312. ee.WriteMapElemValue()
  7313. }
  7314. ee.EncodeUint(uint64(v2))
  7315. }
  7316. }
  7317. ee.WriteMapEnd()
  7318. }
  7319. func (e *Encoder) fastpathEncMapUint32UintptrR(f *codecFnInfo, rv reflect.Value) {
  7320. fastpathTV.EncMapUint32UintptrV(rv2i(rv).(map[uint32]uintptr), e)
  7321. }
  7322. func (_ fastpathT) EncMapUint32UintptrV(v map[uint32]uintptr, e *Encoder) {
  7323. if v == nil {
  7324. e.e.EncodeNil()
  7325. return
  7326. }
  7327. ee, esep := e.e, e.hh.hasElemSeparators()
  7328. ee.WriteMapStart(len(v))
  7329. if e.h.Canonical {
  7330. v2 := make([]uint64, len(v))
  7331. var i int
  7332. for k, _ := range v {
  7333. v2[i] = uint64(k)
  7334. i++
  7335. }
  7336. sort.Sort(uintSlice(v2))
  7337. for _, k2 := range v2 {
  7338. if esep {
  7339. ee.WriteMapElemKey()
  7340. }
  7341. ee.EncodeUint(uint64(uint32(k2)))
  7342. if esep {
  7343. ee.WriteMapElemValue()
  7344. }
  7345. e.encode(v[uint32(k2)])
  7346. }
  7347. } else {
  7348. for k2, v2 := range v {
  7349. if esep {
  7350. ee.WriteMapElemKey()
  7351. }
  7352. ee.EncodeUint(uint64(k2))
  7353. if esep {
  7354. ee.WriteMapElemValue()
  7355. }
  7356. e.encode(v2)
  7357. }
  7358. }
  7359. ee.WriteMapEnd()
  7360. }
  7361. func (e *Encoder) fastpathEncMapUint32IntR(f *codecFnInfo, rv reflect.Value) {
  7362. fastpathTV.EncMapUint32IntV(rv2i(rv).(map[uint32]int), e)
  7363. }
  7364. func (_ fastpathT) EncMapUint32IntV(v map[uint32]int, e *Encoder) {
  7365. if v == nil {
  7366. e.e.EncodeNil()
  7367. return
  7368. }
  7369. ee, esep := e.e, e.hh.hasElemSeparators()
  7370. ee.WriteMapStart(len(v))
  7371. if e.h.Canonical {
  7372. v2 := make([]uint64, len(v))
  7373. var i int
  7374. for k, _ := range v {
  7375. v2[i] = uint64(k)
  7376. i++
  7377. }
  7378. sort.Sort(uintSlice(v2))
  7379. for _, k2 := range v2 {
  7380. if esep {
  7381. ee.WriteMapElemKey()
  7382. }
  7383. ee.EncodeUint(uint64(uint32(k2)))
  7384. if esep {
  7385. ee.WriteMapElemValue()
  7386. }
  7387. ee.EncodeInt(int64(v[uint32(k2)]))
  7388. }
  7389. } else {
  7390. for k2, v2 := range v {
  7391. if esep {
  7392. ee.WriteMapElemKey()
  7393. }
  7394. ee.EncodeUint(uint64(k2))
  7395. if esep {
  7396. ee.WriteMapElemValue()
  7397. }
  7398. ee.EncodeInt(int64(v2))
  7399. }
  7400. }
  7401. ee.WriteMapEnd()
  7402. }
  7403. func (e *Encoder) fastpathEncMapUint32Int8R(f *codecFnInfo, rv reflect.Value) {
  7404. fastpathTV.EncMapUint32Int8V(rv2i(rv).(map[uint32]int8), e)
  7405. }
  7406. func (_ fastpathT) EncMapUint32Int8V(v map[uint32]int8, e *Encoder) {
  7407. if v == nil {
  7408. e.e.EncodeNil()
  7409. return
  7410. }
  7411. ee, esep := e.e, e.hh.hasElemSeparators()
  7412. ee.WriteMapStart(len(v))
  7413. if e.h.Canonical {
  7414. v2 := make([]uint64, len(v))
  7415. var i int
  7416. for k, _ := range v {
  7417. v2[i] = uint64(k)
  7418. i++
  7419. }
  7420. sort.Sort(uintSlice(v2))
  7421. for _, k2 := range v2 {
  7422. if esep {
  7423. ee.WriteMapElemKey()
  7424. }
  7425. ee.EncodeUint(uint64(uint32(k2)))
  7426. if esep {
  7427. ee.WriteMapElemValue()
  7428. }
  7429. ee.EncodeInt(int64(v[uint32(k2)]))
  7430. }
  7431. } else {
  7432. for k2, v2 := range v {
  7433. if esep {
  7434. ee.WriteMapElemKey()
  7435. }
  7436. ee.EncodeUint(uint64(k2))
  7437. if esep {
  7438. ee.WriteMapElemValue()
  7439. }
  7440. ee.EncodeInt(int64(v2))
  7441. }
  7442. }
  7443. ee.WriteMapEnd()
  7444. }
  7445. func (e *Encoder) fastpathEncMapUint32Int16R(f *codecFnInfo, rv reflect.Value) {
  7446. fastpathTV.EncMapUint32Int16V(rv2i(rv).(map[uint32]int16), e)
  7447. }
  7448. func (_ fastpathT) EncMapUint32Int16V(v map[uint32]int16, e *Encoder) {
  7449. if v == nil {
  7450. e.e.EncodeNil()
  7451. return
  7452. }
  7453. ee, esep := e.e, e.hh.hasElemSeparators()
  7454. ee.WriteMapStart(len(v))
  7455. if e.h.Canonical {
  7456. v2 := make([]uint64, len(v))
  7457. var i int
  7458. for k, _ := range v {
  7459. v2[i] = uint64(k)
  7460. i++
  7461. }
  7462. sort.Sort(uintSlice(v2))
  7463. for _, k2 := range v2 {
  7464. if esep {
  7465. ee.WriteMapElemKey()
  7466. }
  7467. ee.EncodeUint(uint64(uint32(k2)))
  7468. if esep {
  7469. ee.WriteMapElemValue()
  7470. }
  7471. ee.EncodeInt(int64(v[uint32(k2)]))
  7472. }
  7473. } else {
  7474. for k2, v2 := range v {
  7475. if esep {
  7476. ee.WriteMapElemKey()
  7477. }
  7478. ee.EncodeUint(uint64(k2))
  7479. if esep {
  7480. ee.WriteMapElemValue()
  7481. }
  7482. ee.EncodeInt(int64(v2))
  7483. }
  7484. }
  7485. ee.WriteMapEnd()
  7486. }
  7487. func (e *Encoder) fastpathEncMapUint32Int32R(f *codecFnInfo, rv reflect.Value) {
  7488. fastpathTV.EncMapUint32Int32V(rv2i(rv).(map[uint32]int32), e)
  7489. }
  7490. func (_ fastpathT) EncMapUint32Int32V(v map[uint32]int32, e *Encoder) {
  7491. if v == nil {
  7492. e.e.EncodeNil()
  7493. return
  7494. }
  7495. ee, esep := e.e, e.hh.hasElemSeparators()
  7496. ee.WriteMapStart(len(v))
  7497. if e.h.Canonical {
  7498. v2 := make([]uint64, len(v))
  7499. var i int
  7500. for k, _ := range v {
  7501. v2[i] = uint64(k)
  7502. i++
  7503. }
  7504. sort.Sort(uintSlice(v2))
  7505. for _, k2 := range v2 {
  7506. if esep {
  7507. ee.WriteMapElemKey()
  7508. }
  7509. ee.EncodeUint(uint64(uint32(k2)))
  7510. if esep {
  7511. ee.WriteMapElemValue()
  7512. }
  7513. ee.EncodeInt(int64(v[uint32(k2)]))
  7514. }
  7515. } else {
  7516. for k2, v2 := range v {
  7517. if esep {
  7518. ee.WriteMapElemKey()
  7519. }
  7520. ee.EncodeUint(uint64(k2))
  7521. if esep {
  7522. ee.WriteMapElemValue()
  7523. }
  7524. ee.EncodeInt(int64(v2))
  7525. }
  7526. }
  7527. ee.WriteMapEnd()
  7528. }
  7529. func (e *Encoder) fastpathEncMapUint32Int64R(f *codecFnInfo, rv reflect.Value) {
  7530. fastpathTV.EncMapUint32Int64V(rv2i(rv).(map[uint32]int64), e)
  7531. }
  7532. func (_ fastpathT) EncMapUint32Int64V(v map[uint32]int64, e *Encoder) {
  7533. if v == nil {
  7534. e.e.EncodeNil()
  7535. return
  7536. }
  7537. ee, esep := e.e, e.hh.hasElemSeparators()
  7538. ee.WriteMapStart(len(v))
  7539. if e.h.Canonical {
  7540. v2 := make([]uint64, len(v))
  7541. var i int
  7542. for k, _ := range v {
  7543. v2[i] = uint64(k)
  7544. i++
  7545. }
  7546. sort.Sort(uintSlice(v2))
  7547. for _, k2 := range v2 {
  7548. if esep {
  7549. ee.WriteMapElemKey()
  7550. }
  7551. ee.EncodeUint(uint64(uint32(k2)))
  7552. if esep {
  7553. ee.WriteMapElemValue()
  7554. }
  7555. ee.EncodeInt(int64(v[uint32(k2)]))
  7556. }
  7557. } else {
  7558. for k2, v2 := range v {
  7559. if esep {
  7560. ee.WriteMapElemKey()
  7561. }
  7562. ee.EncodeUint(uint64(k2))
  7563. if esep {
  7564. ee.WriteMapElemValue()
  7565. }
  7566. ee.EncodeInt(int64(v2))
  7567. }
  7568. }
  7569. ee.WriteMapEnd()
  7570. }
  7571. func (e *Encoder) fastpathEncMapUint32Float32R(f *codecFnInfo, rv reflect.Value) {
  7572. fastpathTV.EncMapUint32Float32V(rv2i(rv).(map[uint32]float32), e)
  7573. }
  7574. func (_ fastpathT) EncMapUint32Float32V(v map[uint32]float32, e *Encoder) {
  7575. if v == nil {
  7576. e.e.EncodeNil()
  7577. return
  7578. }
  7579. ee, esep := e.e, e.hh.hasElemSeparators()
  7580. ee.WriteMapStart(len(v))
  7581. if e.h.Canonical {
  7582. v2 := make([]uint64, len(v))
  7583. var i int
  7584. for k, _ := range v {
  7585. v2[i] = uint64(k)
  7586. i++
  7587. }
  7588. sort.Sort(uintSlice(v2))
  7589. for _, k2 := range v2 {
  7590. if esep {
  7591. ee.WriteMapElemKey()
  7592. }
  7593. ee.EncodeUint(uint64(uint32(k2)))
  7594. if esep {
  7595. ee.WriteMapElemValue()
  7596. }
  7597. ee.EncodeFloat32(v[uint32(k2)])
  7598. }
  7599. } else {
  7600. for k2, v2 := range v {
  7601. if esep {
  7602. ee.WriteMapElemKey()
  7603. }
  7604. ee.EncodeUint(uint64(k2))
  7605. if esep {
  7606. ee.WriteMapElemValue()
  7607. }
  7608. ee.EncodeFloat32(v2)
  7609. }
  7610. }
  7611. ee.WriteMapEnd()
  7612. }
  7613. func (e *Encoder) fastpathEncMapUint32Float64R(f *codecFnInfo, rv reflect.Value) {
  7614. fastpathTV.EncMapUint32Float64V(rv2i(rv).(map[uint32]float64), e)
  7615. }
  7616. func (_ fastpathT) EncMapUint32Float64V(v map[uint32]float64, e *Encoder) {
  7617. if v == nil {
  7618. e.e.EncodeNil()
  7619. return
  7620. }
  7621. ee, esep := e.e, e.hh.hasElemSeparators()
  7622. ee.WriteMapStart(len(v))
  7623. if e.h.Canonical {
  7624. v2 := make([]uint64, len(v))
  7625. var i int
  7626. for k, _ := range v {
  7627. v2[i] = uint64(k)
  7628. i++
  7629. }
  7630. sort.Sort(uintSlice(v2))
  7631. for _, k2 := range v2 {
  7632. if esep {
  7633. ee.WriteMapElemKey()
  7634. }
  7635. ee.EncodeUint(uint64(uint32(k2)))
  7636. if esep {
  7637. ee.WriteMapElemValue()
  7638. }
  7639. ee.EncodeFloat64(v[uint32(k2)])
  7640. }
  7641. } else {
  7642. for k2, v2 := range v {
  7643. if esep {
  7644. ee.WriteMapElemKey()
  7645. }
  7646. ee.EncodeUint(uint64(k2))
  7647. if esep {
  7648. ee.WriteMapElemValue()
  7649. }
  7650. ee.EncodeFloat64(v2)
  7651. }
  7652. }
  7653. ee.WriteMapEnd()
  7654. }
  7655. func (e *Encoder) fastpathEncMapUint32BoolR(f *codecFnInfo, rv reflect.Value) {
  7656. fastpathTV.EncMapUint32BoolV(rv2i(rv).(map[uint32]bool), e)
  7657. }
  7658. func (_ fastpathT) EncMapUint32BoolV(v map[uint32]bool, e *Encoder) {
  7659. if v == nil {
  7660. e.e.EncodeNil()
  7661. return
  7662. }
  7663. ee, esep := e.e, e.hh.hasElemSeparators()
  7664. ee.WriteMapStart(len(v))
  7665. if e.h.Canonical {
  7666. v2 := make([]uint64, len(v))
  7667. var i int
  7668. for k, _ := range v {
  7669. v2[i] = uint64(k)
  7670. i++
  7671. }
  7672. sort.Sort(uintSlice(v2))
  7673. for _, k2 := range v2 {
  7674. if esep {
  7675. ee.WriteMapElemKey()
  7676. }
  7677. ee.EncodeUint(uint64(uint32(k2)))
  7678. if esep {
  7679. ee.WriteMapElemValue()
  7680. }
  7681. ee.EncodeBool(v[uint32(k2)])
  7682. }
  7683. } else {
  7684. for k2, v2 := range v {
  7685. if esep {
  7686. ee.WriteMapElemKey()
  7687. }
  7688. ee.EncodeUint(uint64(k2))
  7689. if esep {
  7690. ee.WriteMapElemValue()
  7691. }
  7692. ee.EncodeBool(v2)
  7693. }
  7694. }
  7695. ee.WriteMapEnd()
  7696. }
  7697. func (e *Encoder) fastpathEncMapUint64IntfR(f *codecFnInfo, rv reflect.Value) {
  7698. fastpathTV.EncMapUint64IntfV(rv2i(rv).(map[uint64]interface{}), e)
  7699. }
  7700. func (_ fastpathT) EncMapUint64IntfV(v map[uint64]interface{}, e *Encoder) {
  7701. if v == nil {
  7702. e.e.EncodeNil()
  7703. return
  7704. }
  7705. ee, esep := e.e, e.hh.hasElemSeparators()
  7706. ee.WriteMapStart(len(v))
  7707. if e.h.Canonical {
  7708. v2 := make([]uint64, len(v))
  7709. var i int
  7710. for k, _ := range v {
  7711. v2[i] = uint64(k)
  7712. i++
  7713. }
  7714. sort.Sort(uintSlice(v2))
  7715. for _, k2 := range v2 {
  7716. if esep {
  7717. ee.WriteMapElemKey()
  7718. }
  7719. ee.EncodeUint(uint64(uint64(k2)))
  7720. if esep {
  7721. ee.WriteMapElemValue()
  7722. }
  7723. e.encode(v[uint64(k2)])
  7724. }
  7725. } else {
  7726. for k2, v2 := range v {
  7727. if esep {
  7728. ee.WriteMapElemKey()
  7729. }
  7730. ee.EncodeUint(uint64(k2))
  7731. if esep {
  7732. ee.WriteMapElemValue()
  7733. }
  7734. e.encode(v2)
  7735. }
  7736. }
  7737. ee.WriteMapEnd()
  7738. }
  7739. func (e *Encoder) fastpathEncMapUint64StringR(f *codecFnInfo, rv reflect.Value) {
  7740. fastpathTV.EncMapUint64StringV(rv2i(rv).(map[uint64]string), e)
  7741. }
  7742. func (_ fastpathT) EncMapUint64StringV(v map[uint64]string, e *Encoder) {
  7743. if v == nil {
  7744. e.e.EncodeNil()
  7745. return
  7746. }
  7747. ee, esep := e.e, e.hh.hasElemSeparators()
  7748. ee.WriteMapStart(len(v))
  7749. if e.h.Canonical {
  7750. v2 := make([]uint64, len(v))
  7751. var i int
  7752. for k, _ := range v {
  7753. v2[i] = uint64(k)
  7754. i++
  7755. }
  7756. sort.Sort(uintSlice(v2))
  7757. for _, k2 := range v2 {
  7758. if esep {
  7759. ee.WriteMapElemKey()
  7760. }
  7761. ee.EncodeUint(uint64(uint64(k2)))
  7762. if esep {
  7763. ee.WriteMapElemValue()
  7764. }
  7765. ee.EncodeString(c_UTF8, v[uint64(k2)])
  7766. }
  7767. } else {
  7768. for k2, v2 := range v {
  7769. if esep {
  7770. ee.WriteMapElemKey()
  7771. }
  7772. ee.EncodeUint(uint64(k2))
  7773. if esep {
  7774. ee.WriteMapElemValue()
  7775. }
  7776. ee.EncodeString(c_UTF8, v2)
  7777. }
  7778. }
  7779. ee.WriteMapEnd()
  7780. }
  7781. func (e *Encoder) fastpathEncMapUint64UintR(f *codecFnInfo, rv reflect.Value) {
  7782. fastpathTV.EncMapUint64UintV(rv2i(rv).(map[uint64]uint), e)
  7783. }
  7784. func (_ fastpathT) EncMapUint64UintV(v map[uint64]uint, e *Encoder) {
  7785. if v == nil {
  7786. e.e.EncodeNil()
  7787. return
  7788. }
  7789. ee, esep := e.e, e.hh.hasElemSeparators()
  7790. ee.WriteMapStart(len(v))
  7791. if e.h.Canonical {
  7792. v2 := make([]uint64, len(v))
  7793. var i int
  7794. for k, _ := range v {
  7795. v2[i] = uint64(k)
  7796. i++
  7797. }
  7798. sort.Sort(uintSlice(v2))
  7799. for _, k2 := range v2 {
  7800. if esep {
  7801. ee.WriteMapElemKey()
  7802. }
  7803. ee.EncodeUint(uint64(uint64(k2)))
  7804. if esep {
  7805. ee.WriteMapElemValue()
  7806. }
  7807. ee.EncodeUint(uint64(v[uint64(k2)]))
  7808. }
  7809. } else {
  7810. for k2, v2 := range v {
  7811. if esep {
  7812. ee.WriteMapElemKey()
  7813. }
  7814. ee.EncodeUint(uint64(k2))
  7815. if esep {
  7816. ee.WriteMapElemValue()
  7817. }
  7818. ee.EncodeUint(uint64(v2))
  7819. }
  7820. }
  7821. ee.WriteMapEnd()
  7822. }
  7823. func (e *Encoder) fastpathEncMapUint64Uint8R(f *codecFnInfo, rv reflect.Value) {
  7824. fastpathTV.EncMapUint64Uint8V(rv2i(rv).(map[uint64]uint8), e)
  7825. }
  7826. func (_ fastpathT) EncMapUint64Uint8V(v map[uint64]uint8, e *Encoder) {
  7827. if v == nil {
  7828. e.e.EncodeNil()
  7829. return
  7830. }
  7831. ee, esep := e.e, e.hh.hasElemSeparators()
  7832. ee.WriteMapStart(len(v))
  7833. if e.h.Canonical {
  7834. v2 := make([]uint64, len(v))
  7835. var i int
  7836. for k, _ := range v {
  7837. v2[i] = uint64(k)
  7838. i++
  7839. }
  7840. sort.Sort(uintSlice(v2))
  7841. for _, k2 := range v2 {
  7842. if esep {
  7843. ee.WriteMapElemKey()
  7844. }
  7845. ee.EncodeUint(uint64(uint64(k2)))
  7846. if esep {
  7847. ee.WriteMapElemValue()
  7848. }
  7849. ee.EncodeUint(uint64(v[uint64(k2)]))
  7850. }
  7851. } else {
  7852. for k2, v2 := range v {
  7853. if esep {
  7854. ee.WriteMapElemKey()
  7855. }
  7856. ee.EncodeUint(uint64(k2))
  7857. if esep {
  7858. ee.WriteMapElemValue()
  7859. }
  7860. ee.EncodeUint(uint64(v2))
  7861. }
  7862. }
  7863. ee.WriteMapEnd()
  7864. }
  7865. func (e *Encoder) fastpathEncMapUint64Uint16R(f *codecFnInfo, rv reflect.Value) {
  7866. fastpathTV.EncMapUint64Uint16V(rv2i(rv).(map[uint64]uint16), e)
  7867. }
  7868. func (_ fastpathT) EncMapUint64Uint16V(v map[uint64]uint16, e *Encoder) {
  7869. if v == nil {
  7870. e.e.EncodeNil()
  7871. return
  7872. }
  7873. ee, esep := e.e, e.hh.hasElemSeparators()
  7874. ee.WriteMapStart(len(v))
  7875. if e.h.Canonical {
  7876. v2 := make([]uint64, len(v))
  7877. var i int
  7878. for k, _ := range v {
  7879. v2[i] = uint64(k)
  7880. i++
  7881. }
  7882. sort.Sort(uintSlice(v2))
  7883. for _, k2 := range v2 {
  7884. if esep {
  7885. ee.WriteMapElemKey()
  7886. }
  7887. ee.EncodeUint(uint64(uint64(k2)))
  7888. if esep {
  7889. ee.WriteMapElemValue()
  7890. }
  7891. ee.EncodeUint(uint64(v[uint64(k2)]))
  7892. }
  7893. } else {
  7894. for k2, v2 := range v {
  7895. if esep {
  7896. ee.WriteMapElemKey()
  7897. }
  7898. ee.EncodeUint(uint64(k2))
  7899. if esep {
  7900. ee.WriteMapElemValue()
  7901. }
  7902. ee.EncodeUint(uint64(v2))
  7903. }
  7904. }
  7905. ee.WriteMapEnd()
  7906. }
  7907. func (e *Encoder) fastpathEncMapUint64Uint32R(f *codecFnInfo, rv reflect.Value) {
  7908. fastpathTV.EncMapUint64Uint32V(rv2i(rv).(map[uint64]uint32), e)
  7909. }
  7910. func (_ fastpathT) EncMapUint64Uint32V(v map[uint64]uint32, e *Encoder) {
  7911. if v == nil {
  7912. e.e.EncodeNil()
  7913. return
  7914. }
  7915. ee, esep := e.e, e.hh.hasElemSeparators()
  7916. ee.WriteMapStart(len(v))
  7917. if e.h.Canonical {
  7918. v2 := make([]uint64, len(v))
  7919. var i int
  7920. for k, _ := range v {
  7921. v2[i] = uint64(k)
  7922. i++
  7923. }
  7924. sort.Sort(uintSlice(v2))
  7925. for _, k2 := range v2 {
  7926. if esep {
  7927. ee.WriteMapElemKey()
  7928. }
  7929. ee.EncodeUint(uint64(uint64(k2)))
  7930. if esep {
  7931. ee.WriteMapElemValue()
  7932. }
  7933. ee.EncodeUint(uint64(v[uint64(k2)]))
  7934. }
  7935. } else {
  7936. for k2, v2 := range v {
  7937. if esep {
  7938. ee.WriteMapElemKey()
  7939. }
  7940. ee.EncodeUint(uint64(k2))
  7941. if esep {
  7942. ee.WriteMapElemValue()
  7943. }
  7944. ee.EncodeUint(uint64(v2))
  7945. }
  7946. }
  7947. ee.WriteMapEnd()
  7948. }
  7949. func (e *Encoder) fastpathEncMapUint64Uint64R(f *codecFnInfo, rv reflect.Value) {
  7950. fastpathTV.EncMapUint64Uint64V(rv2i(rv).(map[uint64]uint64), e)
  7951. }
  7952. func (_ fastpathT) EncMapUint64Uint64V(v map[uint64]uint64, e *Encoder) {
  7953. if v == nil {
  7954. e.e.EncodeNil()
  7955. return
  7956. }
  7957. ee, esep := e.e, e.hh.hasElemSeparators()
  7958. ee.WriteMapStart(len(v))
  7959. if e.h.Canonical {
  7960. v2 := make([]uint64, len(v))
  7961. var i int
  7962. for k, _ := range v {
  7963. v2[i] = uint64(k)
  7964. i++
  7965. }
  7966. sort.Sort(uintSlice(v2))
  7967. for _, k2 := range v2 {
  7968. if esep {
  7969. ee.WriteMapElemKey()
  7970. }
  7971. ee.EncodeUint(uint64(uint64(k2)))
  7972. if esep {
  7973. ee.WriteMapElemValue()
  7974. }
  7975. ee.EncodeUint(uint64(v[uint64(k2)]))
  7976. }
  7977. } else {
  7978. for k2, v2 := range v {
  7979. if esep {
  7980. ee.WriteMapElemKey()
  7981. }
  7982. ee.EncodeUint(uint64(k2))
  7983. if esep {
  7984. ee.WriteMapElemValue()
  7985. }
  7986. ee.EncodeUint(uint64(v2))
  7987. }
  7988. }
  7989. ee.WriteMapEnd()
  7990. }
  7991. func (e *Encoder) fastpathEncMapUint64UintptrR(f *codecFnInfo, rv reflect.Value) {
  7992. fastpathTV.EncMapUint64UintptrV(rv2i(rv).(map[uint64]uintptr), e)
  7993. }
  7994. func (_ fastpathT) EncMapUint64UintptrV(v map[uint64]uintptr, e *Encoder) {
  7995. if v == nil {
  7996. e.e.EncodeNil()
  7997. return
  7998. }
  7999. ee, esep := e.e, e.hh.hasElemSeparators()
  8000. ee.WriteMapStart(len(v))
  8001. if e.h.Canonical {
  8002. v2 := make([]uint64, len(v))
  8003. var i int
  8004. for k, _ := range v {
  8005. v2[i] = uint64(k)
  8006. i++
  8007. }
  8008. sort.Sort(uintSlice(v2))
  8009. for _, k2 := range v2 {
  8010. if esep {
  8011. ee.WriteMapElemKey()
  8012. }
  8013. ee.EncodeUint(uint64(uint64(k2)))
  8014. if esep {
  8015. ee.WriteMapElemValue()
  8016. }
  8017. e.encode(v[uint64(k2)])
  8018. }
  8019. } else {
  8020. for k2, v2 := range v {
  8021. if esep {
  8022. ee.WriteMapElemKey()
  8023. }
  8024. ee.EncodeUint(uint64(k2))
  8025. if esep {
  8026. ee.WriteMapElemValue()
  8027. }
  8028. e.encode(v2)
  8029. }
  8030. }
  8031. ee.WriteMapEnd()
  8032. }
  8033. func (e *Encoder) fastpathEncMapUint64IntR(f *codecFnInfo, rv reflect.Value) {
  8034. fastpathTV.EncMapUint64IntV(rv2i(rv).(map[uint64]int), e)
  8035. }
  8036. func (_ fastpathT) EncMapUint64IntV(v map[uint64]int, e *Encoder) {
  8037. if v == nil {
  8038. e.e.EncodeNil()
  8039. return
  8040. }
  8041. ee, esep := e.e, e.hh.hasElemSeparators()
  8042. ee.WriteMapStart(len(v))
  8043. if e.h.Canonical {
  8044. v2 := make([]uint64, len(v))
  8045. var i int
  8046. for k, _ := range v {
  8047. v2[i] = uint64(k)
  8048. i++
  8049. }
  8050. sort.Sort(uintSlice(v2))
  8051. for _, k2 := range v2 {
  8052. if esep {
  8053. ee.WriteMapElemKey()
  8054. }
  8055. ee.EncodeUint(uint64(uint64(k2)))
  8056. if esep {
  8057. ee.WriteMapElemValue()
  8058. }
  8059. ee.EncodeInt(int64(v[uint64(k2)]))
  8060. }
  8061. } else {
  8062. for k2, v2 := range v {
  8063. if esep {
  8064. ee.WriteMapElemKey()
  8065. }
  8066. ee.EncodeUint(uint64(k2))
  8067. if esep {
  8068. ee.WriteMapElemValue()
  8069. }
  8070. ee.EncodeInt(int64(v2))
  8071. }
  8072. }
  8073. ee.WriteMapEnd()
  8074. }
  8075. func (e *Encoder) fastpathEncMapUint64Int8R(f *codecFnInfo, rv reflect.Value) {
  8076. fastpathTV.EncMapUint64Int8V(rv2i(rv).(map[uint64]int8), e)
  8077. }
  8078. func (_ fastpathT) EncMapUint64Int8V(v map[uint64]int8, e *Encoder) {
  8079. if v == nil {
  8080. e.e.EncodeNil()
  8081. return
  8082. }
  8083. ee, esep := e.e, e.hh.hasElemSeparators()
  8084. ee.WriteMapStart(len(v))
  8085. if e.h.Canonical {
  8086. v2 := make([]uint64, len(v))
  8087. var i int
  8088. for k, _ := range v {
  8089. v2[i] = uint64(k)
  8090. i++
  8091. }
  8092. sort.Sort(uintSlice(v2))
  8093. for _, k2 := range v2 {
  8094. if esep {
  8095. ee.WriteMapElemKey()
  8096. }
  8097. ee.EncodeUint(uint64(uint64(k2)))
  8098. if esep {
  8099. ee.WriteMapElemValue()
  8100. }
  8101. ee.EncodeInt(int64(v[uint64(k2)]))
  8102. }
  8103. } else {
  8104. for k2, v2 := range v {
  8105. if esep {
  8106. ee.WriteMapElemKey()
  8107. }
  8108. ee.EncodeUint(uint64(k2))
  8109. if esep {
  8110. ee.WriteMapElemValue()
  8111. }
  8112. ee.EncodeInt(int64(v2))
  8113. }
  8114. }
  8115. ee.WriteMapEnd()
  8116. }
  8117. func (e *Encoder) fastpathEncMapUint64Int16R(f *codecFnInfo, rv reflect.Value) {
  8118. fastpathTV.EncMapUint64Int16V(rv2i(rv).(map[uint64]int16), e)
  8119. }
  8120. func (_ fastpathT) EncMapUint64Int16V(v map[uint64]int16, e *Encoder) {
  8121. if v == nil {
  8122. e.e.EncodeNil()
  8123. return
  8124. }
  8125. ee, esep := e.e, e.hh.hasElemSeparators()
  8126. ee.WriteMapStart(len(v))
  8127. if e.h.Canonical {
  8128. v2 := make([]uint64, len(v))
  8129. var i int
  8130. for k, _ := range v {
  8131. v2[i] = uint64(k)
  8132. i++
  8133. }
  8134. sort.Sort(uintSlice(v2))
  8135. for _, k2 := range v2 {
  8136. if esep {
  8137. ee.WriteMapElemKey()
  8138. }
  8139. ee.EncodeUint(uint64(uint64(k2)))
  8140. if esep {
  8141. ee.WriteMapElemValue()
  8142. }
  8143. ee.EncodeInt(int64(v[uint64(k2)]))
  8144. }
  8145. } else {
  8146. for k2, v2 := range v {
  8147. if esep {
  8148. ee.WriteMapElemKey()
  8149. }
  8150. ee.EncodeUint(uint64(k2))
  8151. if esep {
  8152. ee.WriteMapElemValue()
  8153. }
  8154. ee.EncodeInt(int64(v2))
  8155. }
  8156. }
  8157. ee.WriteMapEnd()
  8158. }
  8159. func (e *Encoder) fastpathEncMapUint64Int32R(f *codecFnInfo, rv reflect.Value) {
  8160. fastpathTV.EncMapUint64Int32V(rv2i(rv).(map[uint64]int32), e)
  8161. }
  8162. func (_ fastpathT) EncMapUint64Int32V(v map[uint64]int32, e *Encoder) {
  8163. if v == nil {
  8164. e.e.EncodeNil()
  8165. return
  8166. }
  8167. ee, esep := e.e, e.hh.hasElemSeparators()
  8168. ee.WriteMapStart(len(v))
  8169. if e.h.Canonical {
  8170. v2 := make([]uint64, len(v))
  8171. var i int
  8172. for k, _ := range v {
  8173. v2[i] = uint64(k)
  8174. i++
  8175. }
  8176. sort.Sort(uintSlice(v2))
  8177. for _, k2 := range v2 {
  8178. if esep {
  8179. ee.WriteMapElemKey()
  8180. }
  8181. ee.EncodeUint(uint64(uint64(k2)))
  8182. if esep {
  8183. ee.WriteMapElemValue()
  8184. }
  8185. ee.EncodeInt(int64(v[uint64(k2)]))
  8186. }
  8187. } else {
  8188. for k2, v2 := range v {
  8189. if esep {
  8190. ee.WriteMapElemKey()
  8191. }
  8192. ee.EncodeUint(uint64(k2))
  8193. if esep {
  8194. ee.WriteMapElemValue()
  8195. }
  8196. ee.EncodeInt(int64(v2))
  8197. }
  8198. }
  8199. ee.WriteMapEnd()
  8200. }
  8201. func (e *Encoder) fastpathEncMapUint64Int64R(f *codecFnInfo, rv reflect.Value) {
  8202. fastpathTV.EncMapUint64Int64V(rv2i(rv).(map[uint64]int64), e)
  8203. }
  8204. func (_ fastpathT) EncMapUint64Int64V(v map[uint64]int64, e *Encoder) {
  8205. if v == nil {
  8206. e.e.EncodeNil()
  8207. return
  8208. }
  8209. ee, esep := e.e, e.hh.hasElemSeparators()
  8210. ee.WriteMapStart(len(v))
  8211. if e.h.Canonical {
  8212. v2 := make([]uint64, len(v))
  8213. var i int
  8214. for k, _ := range v {
  8215. v2[i] = uint64(k)
  8216. i++
  8217. }
  8218. sort.Sort(uintSlice(v2))
  8219. for _, k2 := range v2 {
  8220. if esep {
  8221. ee.WriteMapElemKey()
  8222. }
  8223. ee.EncodeUint(uint64(uint64(k2)))
  8224. if esep {
  8225. ee.WriteMapElemValue()
  8226. }
  8227. ee.EncodeInt(int64(v[uint64(k2)]))
  8228. }
  8229. } else {
  8230. for k2, v2 := range v {
  8231. if esep {
  8232. ee.WriteMapElemKey()
  8233. }
  8234. ee.EncodeUint(uint64(k2))
  8235. if esep {
  8236. ee.WriteMapElemValue()
  8237. }
  8238. ee.EncodeInt(int64(v2))
  8239. }
  8240. }
  8241. ee.WriteMapEnd()
  8242. }
  8243. func (e *Encoder) fastpathEncMapUint64Float32R(f *codecFnInfo, rv reflect.Value) {
  8244. fastpathTV.EncMapUint64Float32V(rv2i(rv).(map[uint64]float32), e)
  8245. }
  8246. func (_ fastpathT) EncMapUint64Float32V(v map[uint64]float32, e *Encoder) {
  8247. if v == nil {
  8248. e.e.EncodeNil()
  8249. return
  8250. }
  8251. ee, esep := e.e, e.hh.hasElemSeparators()
  8252. ee.WriteMapStart(len(v))
  8253. if e.h.Canonical {
  8254. v2 := make([]uint64, len(v))
  8255. var i int
  8256. for k, _ := range v {
  8257. v2[i] = uint64(k)
  8258. i++
  8259. }
  8260. sort.Sort(uintSlice(v2))
  8261. for _, k2 := range v2 {
  8262. if esep {
  8263. ee.WriteMapElemKey()
  8264. }
  8265. ee.EncodeUint(uint64(uint64(k2)))
  8266. if esep {
  8267. ee.WriteMapElemValue()
  8268. }
  8269. ee.EncodeFloat32(v[uint64(k2)])
  8270. }
  8271. } else {
  8272. for k2, v2 := range v {
  8273. if esep {
  8274. ee.WriteMapElemKey()
  8275. }
  8276. ee.EncodeUint(uint64(k2))
  8277. if esep {
  8278. ee.WriteMapElemValue()
  8279. }
  8280. ee.EncodeFloat32(v2)
  8281. }
  8282. }
  8283. ee.WriteMapEnd()
  8284. }
  8285. func (e *Encoder) fastpathEncMapUint64Float64R(f *codecFnInfo, rv reflect.Value) {
  8286. fastpathTV.EncMapUint64Float64V(rv2i(rv).(map[uint64]float64), e)
  8287. }
  8288. func (_ fastpathT) EncMapUint64Float64V(v map[uint64]float64, e *Encoder) {
  8289. if v == nil {
  8290. e.e.EncodeNil()
  8291. return
  8292. }
  8293. ee, esep := e.e, e.hh.hasElemSeparators()
  8294. ee.WriteMapStart(len(v))
  8295. if e.h.Canonical {
  8296. v2 := make([]uint64, len(v))
  8297. var i int
  8298. for k, _ := range v {
  8299. v2[i] = uint64(k)
  8300. i++
  8301. }
  8302. sort.Sort(uintSlice(v2))
  8303. for _, k2 := range v2 {
  8304. if esep {
  8305. ee.WriteMapElemKey()
  8306. }
  8307. ee.EncodeUint(uint64(uint64(k2)))
  8308. if esep {
  8309. ee.WriteMapElemValue()
  8310. }
  8311. ee.EncodeFloat64(v[uint64(k2)])
  8312. }
  8313. } else {
  8314. for k2, v2 := range v {
  8315. if esep {
  8316. ee.WriteMapElemKey()
  8317. }
  8318. ee.EncodeUint(uint64(k2))
  8319. if esep {
  8320. ee.WriteMapElemValue()
  8321. }
  8322. ee.EncodeFloat64(v2)
  8323. }
  8324. }
  8325. ee.WriteMapEnd()
  8326. }
  8327. func (e *Encoder) fastpathEncMapUint64BoolR(f *codecFnInfo, rv reflect.Value) {
  8328. fastpathTV.EncMapUint64BoolV(rv2i(rv).(map[uint64]bool), e)
  8329. }
  8330. func (_ fastpathT) EncMapUint64BoolV(v map[uint64]bool, e *Encoder) {
  8331. if v == nil {
  8332. e.e.EncodeNil()
  8333. return
  8334. }
  8335. ee, esep := e.e, e.hh.hasElemSeparators()
  8336. ee.WriteMapStart(len(v))
  8337. if e.h.Canonical {
  8338. v2 := make([]uint64, len(v))
  8339. var i int
  8340. for k, _ := range v {
  8341. v2[i] = uint64(k)
  8342. i++
  8343. }
  8344. sort.Sort(uintSlice(v2))
  8345. for _, k2 := range v2 {
  8346. if esep {
  8347. ee.WriteMapElemKey()
  8348. }
  8349. ee.EncodeUint(uint64(uint64(k2)))
  8350. if esep {
  8351. ee.WriteMapElemValue()
  8352. }
  8353. ee.EncodeBool(v[uint64(k2)])
  8354. }
  8355. } else {
  8356. for k2, v2 := range v {
  8357. if esep {
  8358. ee.WriteMapElemKey()
  8359. }
  8360. ee.EncodeUint(uint64(k2))
  8361. if esep {
  8362. ee.WriteMapElemValue()
  8363. }
  8364. ee.EncodeBool(v2)
  8365. }
  8366. }
  8367. ee.WriteMapEnd()
  8368. }
  8369. func (e *Encoder) fastpathEncMapUintptrIntfR(f *codecFnInfo, rv reflect.Value) {
  8370. fastpathTV.EncMapUintptrIntfV(rv2i(rv).(map[uintptr]interface{}), e)
  8371. }
  8372. func (_ fastpathT) EncMapUintptrIntfV(v map[uintptr]interface{}, e *Encoder) {
  8373. if v == nil {
  8374. e.e.EncodeNil()
  8375. return
  8376. }
  8377. ee, esep := e.e, e.hh.hasElemSeparators()
  8378. ee.WriteMapStart(len(v))
  8379. if e.h.Canonical {
  8380. v2 := make([]uint64, len(v))
  8381. var i int
  8382. for k, _ := range v {
  8383. v2[i] = uint64(k)
  8384. i++
  8385. }
  8386. sort.Sort(uintSlice(v2))
  8387. for _, k2 := range v2 {
  8388. if esep {
  8389. ee.WriteMapElemKey()
  8390. }
  8391. e.encode(uintptr(k2))
  8392. if esep {
  8393. ee.WriteMapElemValue()
  8394. }
  8395. e.encode(v[uintptr(k2)])
  8396. }
  8397. } else {
  8398. for k2, v2 := range v {
  8399. if esep {
  8400. ee.WriteMapElemKey()
  8401. }
  8402. e.encode(k2)
  8403. if esep {
  8404. ee.WriteMapElemValue()
  8405. }
  8406. e.encode(v2)
  8407. }
  8408. }
  8409. ee.WriteMapEnd()
  8410. }
  8411. func (e *Encoder) fastpathEncMapUintptrStringR(f *codecFnInfo, rv reflect.Value) {
  8412. fastpathTV.EncMapUintptrStringV(rv2i(rv).(map[uintptr]string), e)
  8413. }
  8414. func (_ fastpathT) EncMapUintptrStringV(v map[uintptr]string, e *Encoder) {
  8415. if v == nil {
  8416. e.e.EncodeNil()
  8417. return
  8418. }
  8419. ee, esep := e.e, e.hh.hasElemSeparators()
  8420. ee.WriteMapStart(len(v))
  8421. if e.h.Canonical {
  8422. v2 := make([]uint64, len(v))
  8423. var i int
  8424. for k, _ := range v {
  8425. v2[i] = uint64(k)
  8426. i++
  8427. }
  8428. sort.Sort(uintSlice(v2))
  8429. for _, k2 := range v2 {
  8430. if esep {
  8431. ee.WriteMapElemKey()
  8432. }
  8433. e.encode(uintptr(k2))
  8434. if esep {
  8435. ee.WriteMapElemValue()
  8436. }
  8437. ee.EncodeString(c_UTF8, v[uintptr(k2)])
  8438. }
  8439. } else {
  8440. for k2, v2 := range v {
  8441. if esep {
  8442. ee.WriteMapElemKey()
  8443. }
  8444. e.encode(k2)
  8445. if esep {
  8446. ee.WriteMapElemValue()
  8447. }
  8448. ee.EncodeString(c_UTF8, v2)
  8449. }
  8450. }
  8451. ee.WriteMapEnd()
  8452. }
  8453. func (e *Encoder) fastpathEncMapUintptrUintR(f *codecFnInfo, rv reflect.Value) {
  8454. fastpathTV.EncMapUintptrUintV(rv2i(rv).(map[uintptr]uint), e)
  8455. }
  8456. func (_ fastpathT) EncMapUintptrUintV(v map[uintptr]uint, e *Encoder) {
  8457. if v == nil {
  8458. e.e.EncodeNil()
  8459. return
  8460. }
  8461. ee, esep := e.e, e.hh.hasElemSeparators()
  8462. ee.WriteMapStart(len(v))
  8463. if e.h.Canonical {
  8464. v2 := make([]uint64, len(v))
  8465. var i int
  8466. for k, _ := range v {
  8467. v2[i] = uint64(k)
  8468. i++
  8469. }
  8470. sort.Sort(uintSlice(v2))
  8471. for _, k2 := range v2 {
  8472. if esep {
  8473. ee.WriteMapElemKey()
  8474. }
  8475. e.encode(uintptr(k2))
  8476. if esep {
  8477. ee.WriteMapElemValue()
  8478. }
  8479. ee.EncodeUint(uint64(v[uintptr(k2)]))
  8480. }
  8481. } else {
  8482. for k2, v2 := range v {
  8483. if esep {
  8484. ee.WriteMapElemKey()
  8485. }
  8486. e.encode(k2)
  8487. if esep {
  8488. ee.WriteMapElemValue()
  8489. }
  8490. ee.EncodeUint(uint64(v2))
  8491. }
  8492. }
  8493. ee.WriteMapEnd()
  8494. }
  8495. func (e *Encoder) fastpathEncMapUintptrUint8R(f *codecFnInfo, rv reflect.Value) {
  8496. fastpathTV.EncMapUintptrUint8V(rv2i(rv).(map[uintptr]uint8), e)
  8497. }
  8498. func (_ fastpathT) EncMapUintptrUint8V(v map[uintptr]uint8, e *Encoder) {
  8499. if v == nil {
  8500. e.e.EncodeNil()
  8501. return
  8502. }
  8503. ee, esep := e.e, e.hh.hasElemSeparators()
  8504. ee.WriteMapStart(len(v))
  8505. if e.h.Canonical {
  8506. v2 := make([]uint64, len(v))
  8507. var i int
  8508. for k, _ := range v {
  8509. v2[i] = uint64(k)
  8510. i++
  8511. }
  8512. sort.Sort(uintSlice(v2))
  8513. for _, k2 := range v2 {
  8514. if esep {
  8515. ee.WriteMapElemKey()
  8516. }
  8517. e.encode(uintptr(k2))
  8518. if esep {
  8519. ee.WriteMapElemValue()
  8520. }
  8521. ee.EncodeUint(uint64(v[uintptr(k2)]))
  8522. }
  8523. } else {
  8524. for k2, v2 := range v {
  8525. if esep {
  8526. ee.WriteMapElemKey()
  8527. }
  8528. e.encode(k2)
  8529. if esep {
  8530. ee.WriteMapElemValue()
  8531. }
  8532. ee.EncodeUint(uint64(v2))
  8533. }
  8534. }
  8535. ee.WriteMapEnd()
  8536. }
  8537. func (e *Encoder) fastpathEncMapUintptrUint16R(f *codecFnInfo, rv reflect.Value) {
  8538. fastpathTV.EncMapUintptrUint16V(rv2i(rv).(map[uintptr]uint16), e)
  8539. }
  8540. func (_ fastpathT) EncMapUintptrUint16V(v map[uintptr]uint16, e *Encoder) {
  8541. if v == nil {
  8542. e.e.EncodeNil()
  8543. return
  8544. }
  8545. ee, esep := e.e, e.hh.hasElemSeparators()
  8546. ee.WriteMapStart(len(v))
  8547. if e.h.Canonical {
  8548. v2 := make([]uint64, len(v))
  8549. var i int
  8550. for k, _ := range v {
  8551. v2[i] = uint64(k)
  8552. i++
  8553. }
  8554. sort.Sort(uintSlice(v2))
  8555. for _, k2 := range v2 {
  8556. if esep {
  8557. ee.WriteMapElemKey()
  8558. }
  8559. e.encode(uintptr(k2))
  8560. if esep {
  8561. ee.WriteMapElemValue()
  8562. }
  8563. ee.EncodeUint(uint64(v[uintptr(k2)]))
  8564. }
  8565. } else {
  8566. for k2, v2 := range v {
  8567. if esep {
  8568. ee.WriteMapElemKey()
  8569. }
  8570. e.encode(k2)
  8571. if esep {
  8572. ee.WriteMapElemValue()
  8573. }
  8574. ee.EncodeUint(uint64(v2))
  8575. }
  8576. }
  8577. ee.WriteMapEnd()
  8578. }
  8579. func (e *Encoder) fastpathEncMapUintptrUint32R(f *codecFnInfo, rv reflect.Value) {
  8580. fastpathTV.EncMapUintptrUint32V(rv2i(rv).(map[uintptr]uint32), e)
  8581. }
  8582. func (_ fastpathT) EncMapUintptrUint32V(v map[uintptr]uint32, e *Encoder) {
  8583. if v == nil {
  8584. e.e.EncodeNil()
  8585. return
  8586. }
  8587. ee, esep := e.e, e.hh.hasElemSeparators()
  8588. ee.WriteMapStart(len(v))
  8589. if e.h.Canonical {
  8590. v2 := make([]uint64, len(v))
  8591. var i int
  8592. for k, _ := range v {
  8593. v2[i] = uint64(k)
  8594. i++
  8595. }
  8596. sort.Sort(uintSlice(v2))
  8597. for _, k2 := range v2 {
  8598. if esep {
  8599. ee.WriteMapElemKey()
  8600. }
  8601. e.encode(uintptr(k2))
  8602. if esep {
  8603. ee.WriteMapElemValue()
  8604. }
  8605. ee.EncodeUint(uint64(v[uintptr(k2)]))
  8606. }
  8607. } else {
  8608. for k2, v2 := range v {
  8609. if esep {
  8610. ee.WriteMapElemKey()
  8611. }
  8612. e.encode(k2)
  8613. if esep {
  8614. ee.WriteMapElemValue()
  8615. }
  8616. ee.EncodeUint(uint64(v2))
  8617. }
  8618. }
  8619. ee.WriteMapEnd()
  8620. }
  8621. func (e *Encoder) fastpathEncMapUintptrUint64R(f *codecFnInfo, rv reflect.Value) {
  8622. fastpathTV.EncMapUintptrUint64V(rv2i(rv).(map[uintptr]uint64), e)
  8623. }
  8624. func (_ fastpathT) EncMapUintptrUint64V(v map[uintptr]uint64, e *Encoder) {
  8625. if v == nil {
  8626. e.e.EncodeNil()
  8627. return
  8628. }
  8629. ee, esep := e.e, e.hh.hasElemSeparators()
  8630. ee.WriteMapStart(len(v))
  8631. if e.h.Canonical {
  8632. v2 := make([]uint64, len(v))
  8633. var i int
  8634. for k, _ := range v {
  8635. v2[i] = uint64(k)
  8636. i++
  8637. }
  8638. sort.Sort(uintSlice(v2))
  8639. for _, k2 := range v2 {
  8640. if esep {
  8641. ee.WriteMapElemKey()
  8642. }
  8643. e.encode(uintptr(k2))
  8644. if esep {
  8645. ee.WriteMapElemValue()
  8646. }
  8647. ee.EncodeUint(uint64(v[uintptr(k2)]))
  8648. }
  8649. } else {
  8650. for k2, v2 := range v {
  8651. if esep {
  8652. ee.WriteMapElemKey()
  8653. }
  8654. e.encode(k2)
  8655. if esep {
  8656. ee.WriteMapElemValue()
  8657. }
  8658. ee.EncodeUint(uint64(v2))
  8659. }
  8660. }
  8661. ee.WriteMapEnd()
  8662. }
  8663. func (e *Encoder) fastpathEncMapUintptrUintptrR(f *codecFnInfo, rv reflect.Value) {
  8664. fastpathTV.EncMapUintptrUintptrV(rv2i(rv).(map[uintptr]uintptr), e)
  8665. }
  8666. func (_ fastpathT) EncMapUintptrUintptrV(v map[uintptr]uintptr, e *Encoder) {
  8667. if v == nil {
  8668. e.e.EncodeNil()
  8669. return
  8670. }
  8671. ee, esep := e.e, e.hh.hasElemSeparators()
  8672. ee.WriteMapStart(len(v))
  8673. if e.h.Canonical {
  8674. v2 := make([]uint64, len(v))
  8675. var i int
  8676. for k, _ := range v {
  8677. v2[i] = uint64(k)
  8678. i++
  8679. }
  8680. sort.Sort(uintSlice(v2))
  8681. for _, k2 := range v2 {
  8682. if esep {
  8683. ee.WriteMapElemKey()
  8684. }
  8685. e.encode(uintptr(k2))
  8686. if esep {
  8687. ee.WriteMapElemValue()
  8688. }
  8689. e.encode(v[uintptr(k2)])
  8690. }
  8691. } else {
  8692. for k2, v2 := range v {
  8693. if esep {
  8694. ee.WriteMapElemKey()
  8695. }
  8696. e.encode(k2)
  8697. if esep {
  8698. ee.WriteMapElemValue()
  8699. }
  8700. e.encode(v2)
  8701. }
  8702. }
  8703. ee.WriteMapEnd()
  8704. }
  8705. func (e *Encoder) fastpathEncMapUintptrIntR(f *codecFnInfo, rv reflect.Value) {
  8706. fastpathTV.EncMapUintptrIntV(rv2i(rv).(map[uintptr]int), e)
  8707. }
  8708. func (_ fastpathT) EncMapUintptrIntV(v map[uintptr]int, e *Encoder) {
  8709. if v == nil {
  8710. e.e.EncodeNil()
  8711. return
  8712. }
  8713. ee, esep := e.e, e.hh.hasElemSeparators()
  8714. ee.WriteMapStart(len(v))
  8715. if e.h.Canonical {
  8716. v2 := make([]uint64, len(v))
  8717. var i int
  8718. for k, _ := range v {
  8719. v2[i] = uint64(k)
  8720. i++
  8721. }
  8722. sort.Sort(uintSlice(v2))
  8723. for _, k2 := range v2 {
  8724. if esep {
  8725. ee.WriteMapElemKey()
  8726. }
  8727. e.encode(uintptr(k2))
  8728. if esep {
  8729. ee.WriteMapElemValue()
  8730. }
  8731. ee.EncodeInt(int64(v[uintptr(k2)]))
  8732. }
  8733. } else {
  8734. for k2, v2 := range v {
  8735. if esep {
  8736. ee.WriteMapElemKey()
  8737. }
  8738. e.encode(k2)
  8739. if esep {
  8740. ee.WriteMapElemValue()
  8741. }
  8742. ee.EncodeInt(int64(v2))
  8743. }
  8744. }
  8745. ee.WriteMapEnd()
  8746. }
  8747. func (e *Encoder) fastpathEncMapUintptrInt8R(f *codecFnInfo, rv reflect.Value) {
  8748. fastpathTV.EncMapUintptrInt8V(rv2i(rv).(map[uintptr]int8), e)
  8749. }
  8750. func (_ fastpathT) EncMapUintptrInt8V(v map[uintptr]int8, e *Encoder) {
  8751. if v == nil {
  8752. e.e.EncodeNil()
  8753. return
  8754. }
  8755. ee, esep := e.e, e.hh.hasElemSeparators()
  8756. ee.WriteMapStart(len(v))
  8757. if e.h.Canonical {
  8758. v2 := make([]uint64, len(v))
  8759. var i int
  8760. for k, _ := range v {
  8761. v2[i] = uint64(k)
  8762. i++
  8763. }
  8764. sort.Sort(uintSlice(v2))
  8765. for _, k2 := range v2 {
  8766. if esep {
  8767. ee.WriteMapElemKey()
  8768. }
  8769. e.encode(uintptr(k2))
  8770. if esep {
  8771. ee.WriteMapElemValue()
  8772. }
  8773. ee.EncodeInt(int64(v[uintptr(k2)]))
  8774. }
  8775. } else {
  8776. for k2, v2 := range v {
  8777. if esep {
  8778. ee.WriteMapElemKey()
  8779. }
  8780. e.encode(k2)
  8781. if esep {
  8782. ee.WriteMapElemValue()
  8783. }
  8784. ee.EncodeInt(int64(v2))
  8785. }
  8786. }
  8787. ee.WriteMapEnd()
  8788. }
  8789. func (e *Encoder) fastpathEncMapUintptrInt16R(f *codecFnInfo, rv reflect.Value) {
  8790. fastpathTV.EncMapUintptrInt16V(rv2i(rv).(map[uintptr]int16), e)
  8791. }
  8792. func (_ fastpathT) EncMapUintptrInt16V(v map[uintptr]int16, e *Encoder) {
  8793. if v == nil {
  8794. e.e.EncodeNil()
  8795. return
  8796. }
  8797. ee, esep := e.e, e.hh.hasElemSeparators()
  8798. ee.WriteMapStart(len(v))
  8799. if e.h.Canonical {
  8800. v2 := make([]uint64, len(v))
  8801. var i int
  8802. for k, _ := range v {
  8803. v2[i] = uint64(k)
  8804. i++
  8805. }
  8806. sort.Sort(uintSlice(v2))
  8807. for _, k2 := range v2 {
  8808. if esep {
  8809. ee.WriteMapElemKey()
  8810. }
  8811. e.encode(uintptr(k2))
  8812. if esep {
  8813. ee.WriteMapElemValue()
  8814. }
  8815. ee.EncodeInt(int64(v[uintptr(k2)]))
  8816. }
  8817. } else {
  8818. for k2, v2 := range v {
  8819. if esep {
  8820. ee.WriteMapElemKey()
  8821. }
  8822. e.encode(k2)
  8823. if esep {
  8824. ee.WriteMapElemValue()
  8825. }
  8826. ee.EncodeInt(int64(v2))
  8827. }
  8828. }
  8829. ee.WriteMapEnd()
  8830. }
  8831. func (e *Encoder) fastpathEncMapUintptrInt32R(f *codecFnInfo, rv reflect.Value) {
  8832. fastpathTV.EncMapUintptrInt32V(rv2i(rv).(map[uintptr]int32), e)
  8833. }
  8834. func (_ fastpathT) EncMapUintptrInt32V(v map[uintptr]int32, e *Encoder) {
  8835. if v == nil {
  8836. e.e.EncodeNil()
  8837. return
  8838. }
  8839. ee, esep := e.e, e.hh.hasElemSeparators()
  8840. ee.WriteMapStart(len(v))
  8841. if e.h.Canonical {
  8842. v2 := make([]uint64, len(v))
  8843. var i int
  8844. for k, _ := range v {
  8845. v2[i] = uint64(k)
  8846. i++
  8847. }
  8848. sort.Sort(uintSlice(v2))
  8849. for _, k2 := range v2 {
  8850. if esep {
  8851. ee.WriteMapElemKey()
  8852. }
  8853. e.encode(uintptr(k2))
  8854. if esep {
  8855. ee.WriteMapElemValue()
  8856. }
  8857. ee.EncodeInt(int64(v[uintptr(k2)]))
  8858. }
  8859. } else {
  8860. for k2, v2 := range v {
  8861. if esep {
  8862. ee.WriteMapElemKey()
  8863. }
  8864. e.encode(k2)
  8865. if esep {
  8866. ee.WriteMapElemValue()
  8867. }
  8868. ee.EncodeInt(int64(v2))
  8869. }
  8870. }
  8871. ee.WriteMapEnd()
  8872. }
  8873. func (e *Encoder) fastpathEncMapUintptrInt64R(f *codecFnInfo, rv reflect.Value) {
  8874. fastpathTV.EncMapUintptrInt64V(rv2i(rv).(map[uintptr]int64), e)
  8875. }
  8876. func (_ fastpathT) EncMapUintptrInt64V(v map[uintptr]int64, e *Encoder) {
  8877. if v == nil {
  8878. e.e.EncodeNil()
  8879. return
  8880. }
  8881. ee, esep := e.e, e.hh.hasElemSeparators()
  8882. ee.WriteMapStart(len(v))
  8883. if e.h.Canonical {
  8884. v2 := make([]uint64, len(v))
  8885. var i int
  8886. for k, _ := range v {
  8887. v2[i] = uint64(k)
  8888. i++
  8889. }
  8890. sort.Sort(uintSlice(v2))
  8891. for _, k2 := range v2 {
  8892. if esep {
  8893. ee.WriteMapElemKey()
  8894. }
  8895. e.encode(uintptr(k2))
  8896. if esep {
  8897. ee.WriteMapElemValue()
  8898. }
  8899. ee.EncodeInt(int64(v[uintptr(k2)]))
  8900. }
  8901. } else {
  8902. for k2, v2 := range v {
  8903. if esep {
  8904. ee.WriteMapElemKey()
  8905. }
  8906. e.encode(k2)
  8907. if esep {
  8908. ee.WriteMapElemValue()
  8909. }
  8910. ee.EncodeInt(int64(v2))
  8911. }
  8912. }
  8913. ee.WriteMapEnd()
  8914. }
  8915. func (e *Encoder) fastpathEncMapUintptrFloat32R(f *codecFnInfo, rv reflect.Value) {
  8916. fastpathTV.EncMapUintptrFloat32V(rv2i(rv).(map[uintptr]float32), e)
  8917. }
  8918. func (_ fastpathT) EncMapUintptrFloat32V(v map[uintptr]float32, e *Encoder) {
  8919. if v == nil {
  8920. e.e.EncodeNil()
  8921. return
  8922. }
  8923. ee, esep := e.e, e.hh.hasElemSeparators()
  8924. ee.WriteMapStart(len(v))
  8925. if e.h.Canonical {
  8926. v2 := make([]uint64, len(v))
  8927. var i int
  8928. for k, _ := range v {
  8929. v2[i] = uint64(k)
  8930. i++
  8931. }
  8932. sort.Sort(uintSlice(v2))
  8933. for _, k2 := range v2 {
  8934. if esep {
  8935. ee.WriteMapElemKey()
  8936. }
  8937. e.encode(uintptr(k2))
  8938. if esep {
  8939. ee.WriteMapElemValue()
  8940. }
  8941. ee.EncodeFloat32(v[uintptr(k2)])
  8942. }
  8943. } else {
  8944. for k2, v2 := range v {
  8945. if esep {
  8946. ee.WriteMapElemKey()
  8947. }
  8948. e.encode(k2)
  8949. if esep {
  8950. ee.WriteMapElemValue()
  8951. }
  8952. ee.EncodeFloat32(v2)
  8953. }
  8954. }
  8955. ee.WriteMapEnd()
  8956. }
  8957. func (e *Encoder) fastpathEncMapUintptrFloat64R(f *codecFnInfo, rv reflect.Value) {
  8958. fastpathTV.EncMapUintptrFloat64V(rv2i(rv).(map[uintptr]float64), e)
  8959. }
  8960. func (_ fastpathT) EncMapUintptrFloat64V(v map[uintptr]float64, e *Encoder) {
  8961. if v == nil {
  8962. e.e.EncodeNil()
  8963. return
  8964. }
  8965. ee, esep := e.e, e.hh.hasElemSeparators()
  8966. ee.WriteMapStart(len(v))
  8967. if e.h.Canonical {
  8968. v2 := make([]uint64, len(v))
  8969. var i int
  8970. for k, _ := range v {
  8971. v2[i] = uint64(k)
  8972. i++
  8973. }
  8974. sort.Sort(uintSlice(v2))
  8975. for _, k2 := range v2 {
  8976. if esep {
  8977. ee.WriteMapElemKey()
  8978. }
  8979. e.encode(uintptr(k2))
  8980. if esep {
  8981. ee.WriteMapElemValue()
  8982. }
  8983. ee.EncodeFloat64(v[uintptr(k2)])
  8984. }
  8985. } else {
  8986. for k2, v2 := range v {
  8987. if esep {
  8988. ee.WriteMapElemKey()
  8989. }
  8990. e.encode(k2)
  8991. if esep {
  8992. ee.WriteMapElemValue()
  8993. }
  8994. ee.EncodeFloat64(v2)
  8995. }
  8996. }
  8997. ee.WriteMapEnd()
  8998. }
  8999. func (e *Encoder) fastpathEncMapUintptrBoolR(f *codecFnInfo, rv reflect.Value) {
  9000. fastpathTV.EncMapUintptrBoolV(rv2i(rv).(map[uintptr]bool), e)
  9001. }
  9002. func (_ fastpathT) EncMapUintptrBoolV(v map[uintptr]bool, e *Encoder) {
  9003. if v == nil {
  9004. e.e.EncodeNil()
  9005. return
  9006. }
  9007. ee, esep := e.e, e.hh.hasElemSeparators()
  9008. ee.WriteMapStart(len(v))
  9009. if e.h.Canonical {
  9010. v2 := make([]uint64, len(v))
  9011. var i int
  9012. for k, _ := range v {
  9013. v2[i] = uint64(k)
  9014. i++
  9015. }
  9016. sort.Sort(uintSlice(v2))
  9017. for _, k2 := range v2 {
  9018. if esep {
  9019. ee.WriteMapElemKey()
  9020. }
  9021. e.encode(uintptr(k2))
  9022. if esep {
  9023. ee.WriteMapElemValue()
  9024. }
  9025. ee.EncodeBool(v[uintptr(k2)])
  9026. }
  9027. } else {
  9028. for k2, v2 := range v {
  9029. if esep {
  9030. ee.WriteMapElemKey()
  9031. }
  9032. e.encode(k2)
  9033. if esep {
  9034. ee.WriteMapElemValue()
  9035. }
  9036. ee.EncodeBool(v2)
  9037. }
  9038. }
  9039. ee.WriteMapEnd()
  9040. }
  9041. func (e *Encoder) fastpathEncMapIntIntfR(f *codecFnInfo, rv reflect.Value) {
  9042. fastpathTV.EncMapIntIntfV(rv2i(rv).(map[int]interface{}), e)
  9043. }
  9044. func (_ fastpathT) EncMapIntIntfV(v map[int]interface{}, e *Encoder) {
  9045. if v == nil {
  9046. e.e.EncodeNil()
  9047. return
  9048. }
  9049. ee, esep := e.e, e.hh.hasElemSeparators()
  9050. ee.WriteMapStart(len(v))
  9051. if e.h.Canonical {
  9052. v2 := make([]int64, len(v))
  9053. var i int
  9054. for k, _ := range v {
  9055. v2[i] = int64(k)
  9056. i++
  9057. }
  9058. sort.Sort(intSlice(v2))
  9059. for _, k2 := range v2 {
  9060. if esep {
  9061. ee.WriteMapElemKey()
  9062. }
  9063. ee.EncodeInt(int64(int(k2)))
  9064. if esep {
  9065. ee.WriteMapElemValue()
  9066. }
  9067. e.encode(v[int(k2)])
  9068. }
  9069. } else {
  9070. for k2, v2 := range v {
  9071. if esep {
  9072. ee.WriteMapElemKey()
  9073. }
  9074. ee.EncodeInt(int64(k2))
  9075. if esep {
  9076. ee.WriteMapElemValue()
  9077. }
  9078. e.encode(v2)
  9079. }
  9080. }
  9081. ee.WriteMapEnd()
  9082. }
  9083. func (e *Encoder) fastpathEncMapIntStringR(f *codecFnInfo, rv reflect.Value) {
  9084. fastpathTV.EncMapIntStringV(rv2i(rv).(map[int]string), e)
  9085. }
  9086. func (_ fastpathT) EncMapIntStringV(v map[int]string, e *Encoder) {
  9087. if v == nil {
  9088. e.e.EncodeNil()
  9089. return
  9090. }
  9091. ee, esep := e.e, e.hh.hasElemSeparators()
  9092. ee.WriteMapStart(len(v))
  9093. if e.h.Canonical {
  9094. v2 := make([]int64, len(v))
  9095. var i int
  9096. for k, _ := range v {
  9097. v2[i] = int64(k)
  9098. i++
  9099. }
  9100. sort.Sort(intSlice(v2))
  9101. for _, k2 := range v2 {
  9102. if esep {
  9103. ee.WriteMapElemKey()
  9104. }
  9105. ee.EncodeInt(int64(int(k2)))
  9106. if esep {
  9107. ee.WriteMapElemValue()
  9108. }
  9109. ee.EncodeString(c_UTF8, v[int(k2)])
  9110. }
  9111. } else {
  9112. for k2, v2 := range v {
  9113. if esep {
  9114. ee.WriteMapElemKey()
  9115. }
  9116. ee.EncodeInt(int64(k2))
  9117. if esep {
  9118. ee.WriteMapElemValue()
  9119. }
  9120. ee.EncodeString(c_UTF8, v2)
  9121. }
  9122. }
  9123. ee.WriteMapEnd()
  9124. }
  9125. func (e *Encoder) fastpathEncMapIntUintR(f *codecFnInfo, rv reflect.Value) {
  9126. fastpathTV.EncMapIntUintV(rv2i(rv).(map[int]uint), e)
  9127. }
  9128. func (_ fastpathT) EncMapIntUintV(v map[int]uint, e *Encoder) {
  9129. if v == nil {
  9130. e.e.EncodeNil()
  9131. return
  9132. }
  9133. ee, esep := e.e, e.hh.hasElemSeparators()
  9134. ee.WriteMapStart(len(v))
  9135. if e.h.Canonical {
  9136. v2 := make([]int64, len(v))
  9137. var i int
  9138. for k, _ := range v {
  9139. v2[i] = int64(k)
  9140. i++
  9141. }
  9142. sort.Sort(intSlice(v2))
  9143. for _, k2 := range v2 {
  9144. if esep {
  9145. ee.WriteMapElemKey()
  9146. }
  9147. ee.EncodeInt(int64(int(k2)))
  9148. if esep {
  9149. ee.WriteMapElemValue()
  9150. }
  9151. ee.EncodeUint(uint64(v[int(k2)]))
  9152. }
  9153. } else {
  9154. for k2, v2 := range v {
  9155. if esep {
  9156. ee.WriteMapElemKey()
  9157. }
  9158. ee.EncodeInt(int64(k2))
  9159. if esep {
  9160. ee.WriteMapElemValue()
  9161. }
  9162. ee.EncodeUint(uint64(v2))
  9163. }
  9164. }
  9165. ee.WriteMapEnd()
  9166. }
  9167. func (e *Encoder) fastpathEncMapIntUint8R(f *codecFnInfo, rv reflect.Value) {
  9168. fastpathTV.EncMapIntUint8V(rv2i(rv).(map[int]uint8), e)
  9169. }
  9170. func (_ fastpathT) EncMapIntUint8V(v map[int]uint8, e *Encoder) {
  9171. if v == nil {
  9172. e.e.EncodeNil()
  9173. return
  9174. }
  9175. ee, esep := e.e, e.hh.hasElemSeparators()
  9176. ee.WriteMapStart(len(v))
  9177. if e.h.Canonical {
  9178. v2 := make([]int64, len(v))
  9179. var i int
  9180. for k, _ := range v {
  9181. v2[i] = int64(k)
  9182. i++
  9183. }
  9184. sort.Sort(intSlice(v2))
  9185. for _, k2 := range v2 {
  9186. if esep {
  9187. ee.WriteMapElemKey()
  9188. }
  9189. ee.EncodeInt(int64(int(k2)))
  9190. if esep {
  9191. ee.WriteMapElemValue()
  9192. }
  9193. ee.EncodeUint(uint64(v[int(k2)]))
  9194. }
  9195. } else {
  9196. for k2, v2 := range v {
  9197. if esep {
  9198. ee.WriteMapElemKey()
  9199. }
  9200. ee.EncodeInt(int64(k2))
  9201. if esep {
  9202. ee.WriteMapElemValue()
  9203. }
  9204. ee.EncodeUint(uint64(v2))
  9205. }
  9206. }
  9207. ee.WriteMapEnd()
  9208. }
  9209. func (e *Encoder) fastpathEncMapIntUint16R(f *codecFnInfo, rv reflect.Value) {
  9210. fastpathTV.EncMapIntUint16V(rv2i(rv).(map[int]uint16), e)
  9211. }
  9212. func (_ fastpathT) EncMapIntUint16V(v map[int]uint16, e *Encoder) {
  9213. if v == nil {
  9214. e.e.EncodeNil()
  9215. return
  9216. }
  9217. ee, esep := e.e, e.hh.hasElemSeparators()
  9218. ee.WriteMapStart(len(v))
  9219. if e.h.Canonical {
  9220. v2 := make([]int64, len(v))
  9221. var i int
  9222. for k, _ := range v {
  9223. v2[i] = int64(k)
  9224. i++
  9225. }
  9226. sort.Sort(intSlice(v2))
  9227. for _, k2 := range v2 {
  9228. if esep {
  9229. ee.WriteMapElemKey()
  9230. }
  9231. ee.EncodeInt(int64(int(k2)))
  9232. if esep {
  9233. ee.WriteMapElemValue()
  9234. }
  9235. ee.EncodeUint(uint64(v[int(k2)]))
  9236. }
  9237. } else {
  9238. for k2, v2 := range v {
  9239. if esep {
  9240. ee.WriteMapElemKey()
  9241. }
  9242. ee.EncodeInt(int64(k2))
  9243. if esep {
  9244. ee.WriteMapElemValue()
  9245. }
  9246. ee.EncodeUint(uint64(v2))
  9247. }
  9248. }
  9249. ee.WriteMapEnd()
  9250. }
  9251. func (e *Encoder) fastpathEncMapIntUint32R(f *codecFnInfo, rv reflect.Value) {
  9252. fastpathTV.EncMapIntUint32V(rv2i(rv).(map[int]uint32), e)
  9253. }
  9254. func (_ fastpathT) EncMapIntUint32V(v map[int]uint32, e *Encoder) {
  9255. if v == nil {
  9256. e.e.EncodeNil()
  9257. return
  9258. }
  9259. ee, esep := e.e, e.hh.hasElemSeparators()
  9260. ee.WriteMapStart(len(v))
  9261. if e.h.Canonical {
  9262. v2 := make([]int64, len(v))
  9263. var i int
  9264. for k, _ := range v {
  9265. v2[i] = int64(k)
  9266. i++
  9267. }
  9268. sort.Sort(intSlice(v2))
  9269. for _, k2 := range v2 {
  9270. if esep {
  9271. ee.WriteMapElemKey()
  9272. }
  9273. ee.EncodeInt(int64(int(k2)))
  9274. if esep {
  9275. ee.WriteMapElemValue()
  9276. }
  9277. ee.EncodeUint(uint64(v[int(k2)]))
  9278. }
  9279. } else {
  9280. for k2, v2 := range v {
  9281. if esep {
  9282. ee.WriteMapElemKey()
  9283. }
  9284. ee.EncodeInt(int64(k2))
  9285. if esep {
  9286. ee.WriteMapElemValue()
  9287. }
  9288. ee.EncodeUint(uint64(v2))
  9289. }
  9290. }
  9291. ee.WriteMapEnd()
  9292. }
  9293. func (e *Encoder) fastpathEncMapIntUint64R(f *codecFnInfo, rv reflect.Value) {
  9294. fastpathTV.EncMapIntUint64V(rv2i(rv).(map[int]uint64), e)
  9295. }
  9296. func (_ fastpathT) EncMapIntUint64V(v map[int]uint64, e *Encoder) {
  9297. if v == nil {
  9298. e.e.EncodeNil()
  9299. return
  9300. }
  9301. ee, esep := e.e, e.hh.hasElemSeparators()
  9302. ee.WriteMapStart(len(v))
  9303. if e.h.Canonical {
  9304. v2 := make([]int64, len(v))
  9305. var i int
  9306. for k, _ := range v {
  9307. v2[i] = int64(k)
  9308. i++
  9309. }
  9310. sort.Sort(intSlice(v2))
  9311. for _, k2 := range v2 {
  9312. if esep {
  9313. ee.WriteMapElemKey()
  9314. }
  9315. ee.EncodeInt(int64(int(k2)))
  9316. if esep {
  9317. ee.WriteMapElemValue()
  9318. }
  9319. ee.EncodeUint(uint64(v[int(k2)]))
  9320. }
  9321. } else {
  9322. for k2, v2 := range v {
  9323. if esep {
  9324. ee.WriteMapElemKey()
  9325. }
  9326. ee.EncodeInt(int64(k2))
  9327. if esep {
  9328. ee.WriteMapElemValue()
  9329. }
  9330. ee.EncodeUint(uint64(v2))
  9331. }
  9332. }
  9333. ee.WriteMapEnd()
  9334. }
  9335. func (e *Encoder) fastpathEncMapIntUintptrR(f *codecFnInfo, rv reflect.Value) {
  9336. fastpathTV.EncMapIntUintptrV(rv2i(rv).(map[int]uintptr), e)
  9337. }
  9338. func (_ fastpathT) EncMapIntUintptrV(v map[int]uintptr, e *Encoder) {
  9339. if v == nil {
  9340. e.e.EncodeNil()
  9341. return
  9342. }
  9343. ee, esep := e.e, e.hh.hasElemSeparators()
  9344. ee.WriteMapStart(len(v))
  9345. if e.h.Canonical {
  9346. v2 := make([]int64, len(v))
  9347. var i int
  9348. for k, _ := range v {
  9349. v2[i] = int64(k)
  9350. i++
  9351. }
  9352. sort.Sort(intSlice(v2))
  9353. for _, k2 := range v2 {
  9354. if esep {
  9355. ee.WriteMapElemKey()
  9356. }
  9357. ee.EncodeInt(int64(int(k2)))
  9358. if esep {
  9359. ee.WriteMapElemValue()
  9360. }
  9361. e.encode(v[int(k2)])
  9362. }
  9363. } else {
  9364. for k2, v2 := range v {
  9365. if esep {
  9366. ee.WriteMapElemKey()
  9367. }
  9368. ee.EncodeInt(int64(k2))
  9369. if esep {
  9370. ee.WriteMapElemValue()
  9371. }
  9372. e.encode(v2)
  9373. }
  9374. }
  9375. ee.WriteMapEnd()
  9376. }
  9377. func (e *Encoder) fastpathEncMapIntIntR(f *codecFnInfo, rv reflect.Value) {
  9378. fastpathTV.EncMapIntIntV(rv2i(rv).(map[int]int), e)
  9379. }
  9380. func (_ fastpathT) EncMapIntIntV(v map[int]int, e *Encoder) {
  9381. if v == nil {
  9382. e.e.EncodeNil()
  9383. return
  9384. }
  9385. ee, esep := e.e, e.hh.hasElemSeparators()
  9386. ee.WriteMapStart(len(v))
  9387. if e.h.Canonical {
  9388. v2 := make([]int64, len(v))
  9389. var i int
  9390. for k, _ := range v {
  9391. v2[i] = int64(k)
  9392. i++
  9393. }
  9394. sort.Sort(intSlice(v2))
  9395. for _, k2 := range v2 {
  9396. if esep {
  9397. ee.WriteMapElemKey()
  9398. }
  9399. ee.EncodeInt(int64(int(k2)))
  9400. if esep {
  9401. ee.WriteMapElemValue()
  9402. }
  9403. ee.EncodeInt(int64(v[int(k2)]))
  9404. }
  9405. } else {
  9406. for k2, v2 := range v {
  9407. if esep {
  9408. ee.WriteMapElemKey()
  9409. }
  9410. ee.EncodeInt(int64(k2))
  9411. if esep {
  9412. ee.WriteMapElemValue()
  9413. }
  9414. ee.EncodeInt(int64(v2))
  9415. }
  9416. }
  9417. ee.WriteMapEnd()
  9418. }
  9419. func (e *Encoder) fastpathEncMapIntInt8R(f *codecFnInfo, rv reflect.Value) {
  9420. fastpathTV.EncMapIntInt8V(rv2i(rv).(map[int]int8), e)
  9421. }
  9422. func (_ fastpathT) EncMapIntInt8V(v map[int]int8, e *Encoder) {
  9423. if v == nil {
  9424. e.e.EncodeNil()
  9425. return
  9426. }
  9427. ee, esep := e.e, e.hh.hasElemSeparators()
  9428. ee.WriteMapStart(len(v))
  9429. if e.h.Canonical {
  9430. v2 := make([]int64, len(v))
  9431. var i int
  9432. for k, _ := range v {
  9433. v2[i] = int64(k)
  9434. i++
  9435. }
  9436. sort.Sort(intSlice(v2))
  9437. for _, k2 := range v2 {
  9438. if esep {
  9439. ee.WriteMapElemKey()
  9440. }
  9441. ee.EncodeInt(int64(int(k2)))
  9442. if esep {
  9443. ee.WriteMapElemValue()
  9444. }
  9445. ee.EncodeInt(int64(v[int(k2)]))
  9446. }
  9447. } else {
  9448. for k2, v2 := range v {
  9449. if esep {
  9450. ee.WriteMapElemKey()
  9451. }
  9452. ee.EncodeInt(int64(k2))
  9453. if esep {
  9454. ee.WriteMapElemValue()
  9455. }
  9456. ee.EncodeInt(int64(v2))
  9457. }
  9458. }
  9459. ee.WriteMapEnd()
  9460. }
  9461. func (e *Encoder) fastpathEncMapIntInt16R(f *codecFnInfo, rv reflect.Value) {
  9462. fastpathTV.EncMapIntInt16V(rv2i(rv).(map[int]int16), e)
  9463. }
  9464. func (_ fastpathT) EncMapIntInt16V(v map[int]int16, e *Encoder) {
  9465. if v == nil {
  9466. e.e.EncodeNil()
  9467. return
  9468. }
  9469. ee, esep := e.e, e.hh.hasElemSeparators()
  9470. ee.WriteMapStart(len(v))
  9471. if e.h.Canonical {
  9472. v2 := make([]int64, len(v))
  9473. var i int
  9474. for k, _ := range v {
  9475. v2[i] = int64(k)
  9476. i++
  9477. }
  9478. sort.Sort(intSlice(v2))
  9479. for _, k2 := range v2 {
  9480. if esep {
  9481. ee.WriteMapElemKey()
  9482. }
  9483. ee.EncodeInt(int64(int(k2)))
  9484. if esep {
  9485. ee.WriteMapElemValue()
  9486. }
  9487. ee.EncodeInt(int64(v[int(k2)]))
  9488. }
  9489. } else {
  9490. for k2, v2 := range v {
  9491. if esep {
  9492. ee.WriteMapElemKey()
  9493. }
  9494. ee.EncodeInt(int64(k2))
  9495. if esep {
  9496. ee.WriteMapElemValue()
  9497. }
  9498. ee.EncodeInt(int64(v2))
  9499. }
  9500. }
  9501. ee.WriteMapEnd()
  9502. }
  9503. func (e *Encoder) fastpathEncMapIntInt32R(f *codecFnInfo, rv reflect.Value) {
  9504. fastpathTV.EncMapIntInt32V(rv2i(rv).(map[int]int32), e)
  9505. }
  9506. func (_ fastpathT) EncMapIntInt32V(v map[int]int32, e *Encoder) {
  9507. if v == nil {
  9508. e.e.EncodeNil()
  9509. return
  9510. }
  9511. ee, esep := e.e, e.hh.hasElemSeparators()
  9512. ee.WriteMapStart(len(v))
  9513. if e.h.Canonical {
  9514. v2 := make([]int64, len(v))
  9515. var i int
  9516. for k, _ := range v {
  9517. v2[i] = int64(k)
  9518. i++
  9519. }
  9520. sort.Sort(intSlice(v2))
  9521. for _, k2 := range v2 {
  9522. if esep {
  9523. ee.WriteMapElemKey()
  9524. }
  9525. ee.EncodeInt(int64(int(k2)))
  9526. if esep {
  9527. ee.WriteMapElemValue()
  9528. }
  9529. ee.EncodeInt(int64(v[int(k2)]))
  9530. }
  9531. } else {
  9532. for k2, v2 := range v {
  9533. if esep {
  9534. ee.WriteMapElemKey()
  9535. }
  9536. ee.EncodeInt(int64(k2))
  9537. if esep {
  9538. ee.WriteMapElemValue()
  9539. }
  9540. ee.EncodeInt(int64(v2))
  9541. }
  9542. }
  9543. ee.WriteMapEnd()
  9544. }
  9545. func (e *Encoder) fastpathEncMapIntInt64R(f *codecFnInfo, rv reflect.Value) {
  9546. fastpathTV.EncMapIntInt64V(rv2i(rv).(map[int]int64), e)
  9547. }
  9548. func (_ fastpathT) EncMapIntInt64V(v map[int]int64, e *Encoder) {
  9549. if v == nil {
  9550. e.e.EncodeNil()
  9551. return
  9552. }
  9553. ee, esep := e.e, e.hh.hasElemSeparators()
  9554. ee.WriteMapStart(len(v))
  9555. if e.h.Canonical {
  9556. v2 := make([]int64, len(v))
  9557. var i int
  9558. for k, _ := range v {
  9559. v2[i] = int64(k)
  9560. i++
  9561. }
  9562. sort.Sort(intSlice(v2))
  9563. for _, k2 := range v2 {
  9564. if esep {
  9565. ee.WriteMapElemKey()
  9566. }
  9567. ee.EncodeInt(int64(int(k2)))
  9568. if esep {
  9569. ee.WriteMapElemValue()
  9570. }
  9571. ee.EncodeInt(int64(v[int(k2)]))
  9572. }
  9573. } else {
  9574. for k2, v2 := range v {
  9575. if esep {
  9576. ee.WriteMapElemKey()
  9577. }
  9578. ee.EncodeInt(int64(k2))
  9579. if esep {
  9580. ee.WriteMapElemValue()
  9581. }
  9582. ee.EncodeInt(int64(v2))
  9583. }
  9584. }
  9585. ee.WriteMapEnd()
  9586. }
  9587. func (e *Encoder) fastpathEncMapIntFloat32R(f *codecFnInfo, rv reflect.Value) {
  9588. fastpathTV.EncMapIntFloat32V(rv2i(rv).(map[int]float32), e)
  9589. }
  9590. func (_ fastpathT) EncMapIntFloat32V(v map[int]float32, e *Encoder) {
  9591. if v == nil {
  9592. e.e.EncodeNil()
  9593. return
  9594. }
  9595. ee, esep := e.e, e.hh.hasElemSeparators()
  9596. ee.WriteMapStart(len(v))
  9597. if e.h.Canonical {
  9598. v2 := make([]int64, len(v))
  9599. var i int
  9600. for k, _ := range v {
  9601. v2[i] = int64(k)
  9602. i++
  9603. }
  9604. sort.Sort(intSlice(v2))
  9605. for _, k2 := range v2 {
  9606. if esep {
  9607. ee.WriteMapElemKey()
  9608. }
  9609. ee.EncodeInt(int64(int(k2)))
  9610. if esep {
  9611. ee.WriteMapElemValue()
  9612. }
  9613. ee.EncodeFloat32(v[int(k2)])
  9614. }
  9615. } else {
  9616. for k2, v2 := range v {
  9617. if esep {
  9618. ee.WriteMapElemKey()
  9619. }
  9620. ee.EncodeInt(int64(k2))
  9621. if esep {
  9622. ee.WriteMapElemValue()
  9623. }
  9624. ee.EncodeFloat32(v2)
  9625. }
  9626. }
  9627. ee.WriteMapEnd()
  9628. }
  9629. func (e *Encoder) fastpathEncMapIntFloat64R(f *codecFnInfo, rv reflect.Value) {
  9630. fastpathTV.EncMapIntFloat64V(rv2i(rv).(map[int]float64), e)
  9631. }
  9632. func (_ fastpathT) EncMapIntFloat64V(v map[int]float64, e *Encoder) {
  9633. if v == nil {
  9634. e.e.EncodeNil()
  9635. return
  9636. }
  9637. ee, esep := e.e, e.hh.hasElemSeparators()
  9638. ee.WriteMapStart(len(v))
  9639. if e.h.Canonical {
  9640. v2 := make([]int64, len(v))
  9641. var i int
  9642. for k, _ := range v {
  9643. v2[i] = int64(k)
  9644. i++
  9645. }
  9646. sort.Sort(intSlice(v2))
  9647. for _, k2 := range v2 {
  9648. if esep {
  9649. ee.WriteMapElemKey()
  9650. }
  9651. ee.EncodeInt(int64(int(k2)))
  9652. if esep {
  9653. ee.WriteMapElemValue()
  9654. }
  9655. ee.EncodeFloat64(v[int(k2)])
  9656. }
  9657. } else {
  9658. for k2, v2 := range v {
  9659. if esep {
  9660. ee.WriteMapElemKey()
  9661. }
  9662. ee.EncodeInt(int64(k2))
  9663. if esep {
  9664. ee.WriteMapElemValue()
  9665. }
  9666. ee.EncodeFloat64(v2)
  9667. }
  9668. }
  9669. ee.WriteMapEnd()
  9670. }
  9671. func (e *Encoder) fastpathEncMapIntBoolR(f *codecFnInfo, rv reflect.Value) {
  9672. fastpathTV.EncMapIntBoolV(rv2i(rv).(map[int]bool), e)
  9673. }
  9674. func (_ fastpathT) EncMapIntBoolV(v map[int]bool, e *Encoder) {
  9675. if v == nil {
  9676. e.e.EncodeNil()
  9677. return
  9678. }
  9679. ee, esep := e.e, e.hh.hasElemSeparators()
  9680. ee.WriteMapStart(len(v))
  9681. if e.h.Canonical {
  9682. v2 := make([]int64, len(v))
  9683. var i int
  9684. for k, _ := range v {
  9685. v2[i] = int64(k)
  9686. i++
  9687. }
  9688. sort.Sort(intSlice(v2))
  9689. for _, k2 := range v2 {
  9690. if esep {
  9691. ee.WriteMapElemKey()
  9692. }
  9693. ee.EncodeInt(int64(int(k2)))
  9694. if esep {
  9695. ee.WriteMapElemValue()
  9696. }
  9697. ee.EncodeBool(v[int(k2)])
  9698. }
  9699. } else {
  9700. for k2, v2 := range v {
  9701. if esep {
  9702. ee.WriteMapElemKey()
  9703. }
  9704. ee.EncodeInt(int64(k2))
  9705. if esep {
  9706. ee.WriteMapElemValue()
  9707. }
  9708. ee.EncodeBool(v2)
  9709. }
  9710. }
  9711. ee.WriteMapEnd()
  9712. }
  9713. func (e *Encoder) fastpathEncMapInt8IntfR(f *codecFnInfo, rv reflect.Value) {
  9714. fastpathTV.EncMapInt8IntfV(rv2i(rv).(map[int8]interface{}), e)
  9715. }
  9716. func (_ fastpathT) EncMapInt8IntfV(v map[int8]interface{}, e *Encoder) {
  9717. if v == nil {
  9718. e.e.EncodeNil()
  9719. return
  9720. }
  9721. ee, esep := e.e, e.hh.hasElemSeparators()
  9722. ee.WriteMapStart(len(v))
  9723. if e.h.Canonical {
  9724. v2 := make([]int64, len(v))
  9725. var i int
  9726. for k, _ := range v {
  9727. v2[i] = int64(k)
  9728. i++
  9729. }
  9730. sort.Sort(intSlice(v2))
  9731. for _, k2 := range v2 {
  9732. if esep {
  9733. ee.WriteMapElemKey()
  9734. }
  9735. ee.EncodeInt(int64(int8(k2)))
  9736. if esep {
  9737. ee.WriteMapElemValue()
  9738. }
  9739. e.encode(v[int8(k2)])
  9740. }
  9741. } else {
  9742. for k2, v2 := range v {
  9743. if esep {
  9744. ee.WriteMapElemKey()
  9745. }
  9746. ee.EncodeInt(int64(k2))
  9747. if esep {
  9748. ee.WriteMapElemValue()
  9749. }
  9750. e.encode(v2)
  9751. }
  9752. }
  9753. ee.WriteMapEnd()
  9754. }
  9755. func (e *Encoder) fastpathEncMapInt8StringR(f *codecFnInfo, rv reflect.Value) {
  9756. fastpathTV.EncMapInt8StringV(rv2i(rv).(map[int8]string), e)
  9757. }
  9758. func (_ fastpathT) EncMapInt8StringV(v map[int8]string, e *Encoder) {
  9759. if v == nil {
  9760. e.e.EncodeNil()
  9761. return
  9762. }
  9763. ee, esep := e.e, e.hh.hasElemSeparators()
  9764. ee.WriteMapStart(len(v))
  9765. if e.h.Canonical {
  9766. v2 := make([]int64, len(v))
  9767. var i int
  9768. for k, _ := range v {
  9769. v2[i] = int64(k)
  9770. i++
  9771. }
  9772. sort.Sort(intSlice(v2))
  9773. for _, k2 := range v2 {
  9774. if esep {
  9775. ee.WriteMapElemKey()
  9776. }
  9777. ee.EncodeInt(int64(int8(k2)))
  9778. if esep {
  9779. ee.WriteMapElemValue()
  9780. }
  9781. ee.EncodeString(c_UTF8, v[int8(k2)])
  9782. }
  9783. } else {
  9784. for k2, v2 := range v {
  9785. if esep {
  9786. ee.WriteMapElemKey()
  9787. }
  9788. ee.EncodeInt(int64(k2))
  9789. if esep {
  9790. ee.WriteMapElemValue()
  9791. }
  9792. ee.EncodeString(c_UTF8, v2)
  9793. }
  9794. }
  9795. ee.WriteMapEnd()
  9796. }
  9797. func (e *Encoder) fastpathEncMapInt8UintR(f *codecFnInfo, rv reflect.Value) {
  9798. fastpathTV.EncMapInt8UintV(rv2i(rv).(map[int8]uint), e)
  9799. }
  9800. func (_ fastpathT) EncMapInt8UintV(v map[int8]uint, e *Encoder) {
  9801. if v == nil {
  9802. e.e.EncodeNil()
  9803. return
  9804. }
  9805. ee, esep := e.e, e.hh.hasElemSeparators()
  9806. ee.WriteMapStart(len(v))
  9807. if e.h.Canonical {
  9808. v2 := make([]int64, len(v))
  9809. var i int
  9810. for k, _ := range v {
  9811. v2[i] = int64(k)
  9812. i++
  9813. }
  9814. sort.Sort(intSlice(v2))
  9815. for _, k2 := range v2 {
  9816. if esep {
  9817. ee.WriteMapElemKey()
  9818. }
  9819. ee.EncodeInt(int64(int8(k2)))
  9820. if esep {
  9821. ee.WriteMapElemValue()
  9822. }
  9823. ee.EncodeUint(uint64(v[int8(k2)]))
  9824. }
  9825. } else {
  9826. for k2, v2 := range v {
  9827. if esep {
  9828. ee.WriteMapElemKey()
  9829. }
  9830. ee.EncodeInt(int64(k2))
  9831. if esep {
  9832. ee.WriteMapElemValue()
  9833. }
  9834. ee.EncodeUint(uint64(v2))
  9835. }
  9836. }
  9837. ee.WriteMapEnd()
  9838. }
  9839. func (e *Encoder) fastpathEncMapInt8Uint8R(f *codecFnInfo, rv reflect.Value) {
  9840. fastpathTV.EncMapInt8Uint8V(rv2i(rv).(map[int8]uint8), e)
  9841. }
  9842. func (_ fastpathT) EncMapInt8Uint8V(v map[int8]uint8, e *Encoder) {
  9843. if v == nil {
  9844. e.e.EncodeNil()
  9845. return
  9846. }
  9847. ee, esep := e.e, e.hh.hasElemSeparators()
  9848. ee.WriteMapStart(len(v))
  9849. if e.h.Canonical {
  9850. v2 := make([]int64, len(v))
  9851. var i int
  9852. for k, _ := range v {
  9853. v2[i] = int64(k)
  9854. i++
  9855. }
  9856. sort.Sort(intSlice(v2))
  9857. for _, k2 := range v2 {
  9858. if esep {
  9859. ee.WriteMapElemKey()
  9860. }
  9861. ee.EncodeInt(int64(int8(k2)))
  9862. if esep {
  9863. ee.WriteMapElemValue()
  9864. }
  9865. ee.EncodeUint(uint64(v[int8(k2)]))
  9866. }
  9867. } else {
  9868. for k2, v2 := range v {
  9869. if esep {
  9870. ee.WriteMapElemKey()
  9871. }
  9872. ee.EncodeInt(int64(k2))
  9873. if esep {
  9874. ee.WriteMapElemValue()
  9875. }
  9876. ee.EncodeUint(uint64(v2))
  9877. }
  9878. }
  9879. ee.WriteMapEnd()
  9880. }
  9881. func (e *Encoder) fastpathEncMapInt8Uint16R(f *codecFnInfo, rv reflect.Value) {
  9882. fastpathTV.EncMapInt8Uint16V(rv2i(rv).(map[int8]uint16), e)
  9883. }
  9884. func (_ fastpathT) EncMapInt8Uint16V(v map[int8]uint16, e *Encoder) {
  9885. if v == nil {
  9886. e.e.EncodeNil()
  9887. return
  9888. }
  9889. ee, esep := e.e, e.hh.hasElemSeparators()
  9890. ee.WriteMapStart(len(v))
  9891. if e.h.Canonical {
  9892. v2 := make([]int64, len(v))
  9893. var i int
  9894. for k, _ := range v {
  9895. v2[i] = int64(k)
  9896. i++
  9897. }
  9898. sort.Sort(intSlice(v2))
  9899. for _, k2 := range v2 {
  9900. if esep {
  9901. ee.WriteMapElemKey()
  9902. }
  9903. ee.EncodeInt(int64(int8(k2)))
  9904. if esep {
  9905. ee.WriteMapElemValue()
  9906. }
  9907. ee.EncodeUint(uint64(v[int8(k2)]))
  9908. }
  9909. } else {
  9910. for k2, v2 := range v {
  9911. if esep {
  9912. ee.WriteMapElemKey()
  9913. }
  9914. ee.EncodeInt(int64(k2))
  9915. if esep {
  9916. ee.WriteMapElemValue()
  9917. }
  9918. ee.EncodeUint(uint64(v2))
  9919. }
  9920. }
  9921. ee.WriteMapEnd()
  9922. }
  9923. func (e *Encoder) fastpathEncMapInt8Uint32R(f *codecFnInfo, rv reflect.Value) {
  9924. fastpathTV.EncMapInt8Uint32V(rv2i(rv).(map[int8]uint32), e)
  9925. }
  9926. func (_ fastpathT) EncMapInt8Uint32V(v map[int8]uint32, e *Encoder) {
  9927. if v == nil {
  9928. e.e.EncodeNil()
  9929. return
  9930. }
  9931. ee, esep := e.e, e.hh.hasElemSeparators()
  9932. ee.WriteMapStart(len(v))
  9933. if e.h.Canonical {
  9934. v2 := make([]int64, len(v))
  9935. var i int
  9936. for k, _ := range v {
  9937. v2[i] = int64(k)
  9938. i++
  9939. }
  9940. sort.Sort(intSlice(v2))
  9941. for _, k2 := range v2 {
  9942. if esep {
  9943. ee.WriteMapElemKey()
  9944. }
  9945. ee.EncodeInt(int64(int8(k2)))
  9946. if esep {
  9947. ee.WriteMapElemValue()
  9948. }
  9949. ee.EncodeUint(uint64(v[int8(k2)]))
  9950. }
  9951. } else {
  9952. for k2, v2 := range v {
  9953. if esep {
  9954. ee.WriteMapElemKey()
  9955. }
  9956. ee.EncodeInt(int64(k2))
  9957. if esep {
  9958. ee.WriteMapElemValue()
  9959. }
  9960. ee.EncodeUint(uint64(v2))
  9961. }
  9962. }
  9963. ee.WriteMapEnd()
  9964. }
  9965. func (e *Encoder) fastpathEncMapInt8Uint64R(f *codecFnInfo, rv reflect.Value) {
  9966. fastpathTV.EncMapInt8Uint64V(rv2i(rv).(map[int8]uint64), e)
  9967. }
  9968. func (_ fastpathT) EncMapInt8Uint64V(v map[int8]uint64, e *Encoder) {
  9969. if v == nil {
  9970. e.e.EncodeNil()
  9971. return
  9972. }
  9973. ee, esep := e.e, e.hh.hasElemSeparators()
  9974. ee.WriteMapStart(len(v))
  9975. if e.h.Canonical {
  9976. v2 := make([]int64, len(v))
  9977. var i int
  9978. for k, _ := range v {
  9979. v2[i] = int64(k)
  9980. i++
  9981. }
  9982. sort.Sort(intSlice(v2))
  9983. for _, k2 := range v2 {
  9984. if esep {
  9985. ee.WriteMapElemKey()
  9986. }
  9987. ee.EncodeInt(int64(int8(k2)))
  9988. if esep {
  9989. ee.WriteMapElemValue()
  9990. }
  9991. ee.EncodeUint(uint64(v[int8(k2)]))
  9992. }
  9993. } else {
  9994. for k2, v2 := range v {
  9995. if esep {
  9996. ee.WriteMapElemKey()
  9997. }
  9998. ee.EncodeInt(int64(k2))
  9999. if esep {
  10000. ee.WriteMapElemValue()
  10001. }
  10002. ee.EncodeUint(uint64(v2))
  10003. }
  10004. }
  10005. ee.WriteMapEnd()
  10006. }
  10007. func (e *Encoder) fastpathEncMapInt8UintptrR(f *codecFnInfo, rv reflect.Value) {
  10008. fastpathTV.EncMapInt8UintptrV(rv2i(rv).(map[int8]uintptr), e)
  10009. }
  10010. func (_ fastpathT) EncMapInt8UintptrV(v map[int8]uintptr, e *Encoder) {
  10011. if v == nil {
  10012. e.e.EncodeNil()
  10013. return
  10014. }
  10015. ee, esep := e.e, e.hh.hasElemSeparators()
  10016. ee.WriteMapStart(len(v))
  10017. if e.h.Canonical {
  10018. v2 := make([]int64, len(v))
  10019. var i int
  10020. for k, _ := range v {
  10021. v2[i] = int64(k)
  10022. i++
  10023. }
  10024. sort.Sort(intSlice(v2))
  10025. for _, k2 := range v2 {
  10026. if esep {
  10027. ee.WriteMapElemKey()
  10028. }
  10029. ee.EncodeInt(int64(int8(k2)))
  10030. if esep {
  10031. ee.WriteMapElemValue()
  10032. }
  10033. e.encode(v[int8(k2)])
  10034. }
  10035. } else {
  10036. for k2, v2 := range v {
  10037. if esep {
  10038. ee.WriteMapElemKey()
  10039. }
  10040. ee.EncodeInt(int64(k2))
  10041. if esep {
  10042. ee.WriteMapElemValue()
  10043. }
  10044. e.encode(v2)
  10045. }
  10046. }
  10047. ee.WriteMapEnd()
  10048. }
  10049. func (e *Encoder) fastpathEncMapInt8IntR(f *codecFnInfo, rv reflect.Value) {
  10050. fastpathTV.EncMapInt8IntV(rv2i(rv).(map[int8]int), e)
  10051. }
  10052. func (_ fastpathT) EncMapInt8IntV(v map[int8]int, e *Encoder) {
  10053. if v == nil {
  10054. e.e.EncodeNil()
  10055. return
  10056. }
  10057. ee, esep := e.e, e.hh.hasElemSeparators()
  10058. ee.WriteMapStart(len(v))
  10059. if e.h.Canonical {
  10060. v2 := make([]int64, len(v))
  10061. var i int
  10062. for k, _ := range v {
  10063. v2[i] = int64(k)
  10064. i++
  10065. }
  10066. sort.Sort(intSlice(v2))
  10067. for _, k2 := range v2 {
  10068. if esep {
  10069. ee.WriteMapElemKey()
  10070. }
  10071. ee.EncodeInt(int64(int8(k2)))
  10072. if esep {
  10073. ee.WriteMapElemValue()
  10074. }
  10075. ee.EncodeInt(int64(v[int8(k2)]))
  10076. }
  10077. } else {
  10078. for k2, v2 := range v {
  10079. if esep {
  10080. ee.WriteMapElemKey()
  10081. }
  10082. ee.EncodeInt(int64(k2))
  10083. if esep {
  10084. ee.WriteMapElemValue()
  10085. }
  10086. ee.EncodeInt(int64(v2))
  10087. }
  10088. }
  10089. ee.WriteMapEnd()
  10090. }
  10091. func (e *Encoder) fastpathEncMapInt8Int8R(f *codecFnInfo, rv reflect.Value) {
  10092. fastpathTV.EncMapInt8Int8V(rv2i(rv).(map[int8]int8), e)
  10093. }
  10094. func (_ fastpathT) EncMapInt8Int8V(v map[int8]int8, e *Encoder) {
  10095. if v == nil {
  10096. e.e.EncodeNil()
  10097. return
  10098. }
  10099. ee, esep := e.e, e.hh.hasElemSeparators()
  10100. ee.WriteMapStart(len(v))
  10101. if e.h.Canonical {
  10102. v2 := make([]int64, len(v))
  10103. var i int
  10104. for k, _ := range v {
  10105. v2[i] = int64(k)
  10106. i++
  10107. }
  10108. sort.Sort(intSlice(v2))
  10109. for _, k2 := range v2 {
  10110. if esep {
  10111. ee.WriteMapElemKey()
  10112. }
  10113. ee.EncodeInt(int64(int8(k2)))
  10114. if esep {
  10115. ee.WriteMapElemValue()
  10116. }
  10117. ee.EncodeInt(int64(v[int8(k2)]))
  10118. }
  10119. } else {
  10120. for k2, v2 := range v {
  10121. if esep {
  10122. ee.WriteMapElemKey()
  10123. }
  10124. ee.EncodeInt(int64(k2))
  10125. if esep {
  10126. ee.WriteMapElemValue()
  10127. }
  10128. ee.EncodeInt(int64(v2))
  10129. }
  10130. }
  10131. ee.WriteMapEnd()
  10132. }
  10133. func (e *Encoder) fastpathEncMapInt8Int16R(f *codecFnInfo, rv reflect.Value) {
  10134. fastpathTV.EncMapInt8Int16V(rv2i(rv).(map[int8]int16), e)
  10135. }
  10136. func (_ fastpathT) EncMapInt8Int16V(v map[int8]int16, e *Encoder) {
  10137. if v == nil {
  10138. e.e.EncodeNil()
  10139. return
  10140. }
  10141. ee, esep := e.e, e.hh.hasElemSeparators()
  10142. ee.WriteMapStart(len(v))
  10143. if e.h.Canonical {
  10144. v2 := make([]int64, len(v))
  10145. var i int
  10146. for k, _ := range v {
  10147. v2[i] = int64(k)
  10148. i++
  10149. }
  10150. sort.Sort(intSlice(v2))
  10151. for _, k2 := range v2 {
  10152. if esep {
  10153. ee.WriteMapElemKey()
  10154. }
  10155. ee.EncodeInt(int64(int8(k2)))
  10156. if esep {
  10157. ee.WriteMapElemValue()
  10158. }
  10159. ee.EncodeInt(int64(v[int8(k2)]))
  10160. }
  10161. } else {
  10162. for k2, v2 := range v {
  10163. if esep {
  10164. ee.WriteMapElemKey()
  10165. }
  10166. ee.EncodeInt(int64(k2))
  10167. if esep {
  10168. ee.WriteMapElemValue()
  10169. }
  10170. ee.EncodeInt(int64(v2))
  10171. }
  10172. }
  10173. ee.WriteMapEnd()
  10174. }
  10175. func (e *Encoder) fastpathEncMapInt8Int32R(f *codecFnInfo, rv reflect.Value) {
  10176. fastpathTV.EncMapInt8Int32V(rv2i(rv).(map[int8]int32), e)
  10177. }
  10178. func (_ fastpathT) EncMapInt8Int32V(v map[int8]int32, e *Encoder) {
  10179. if v == nil {
  10180. e.e.EncodeNil()
  10181. return
  10182. }
  10183. ee, esep := e.e, e.hh.hasElemSeparators()
  10184. ee.WriteMapStart(len(v))
  10185. if e.h.Canonical {
  10186. v2 := make([]int64, len(v))
  10187. var i int
  10188. for k, _ := range v {
  10189. v2[i] = int64(k)
  10190. i++
  10191. }
  10192. sort.Sort(intSlice(v2))
  10193. for _, k2 := range v2 {
  10194. if esep {
  10195. ee.WriteMapElemKey()
  10196. }
  10197. ee.EncodeInt(int64(int8(k2)))
  10198. if esep {
  10199. ee.WriteMapElemValue()
  10200. }
  10201. ee.EncodeInt(int64(v[int8(k2)]))
  10202. }
  10203. } else {
  10204. for k2, v2 := range v {
  10205. if esep {
  10206. ee.WriteMapElemKey()
  10207. }
  10208. ee.EncodeInt(int64(k2))
  10209. if esep {
  10210. ee.WriteMapElemValue()
  10211. }
  10212. ee.EncodeInt(int64(v2))
  10213. }
  10214. }
  10215. ee.WriteMapEnd()
  10216. }
  10217. func (e *Encoder) fastpathEncMapInt8Int64R(f *codecFnInfo, rv reflect.Value) {
  10218. fastpathTV.EncMapInt8Int64V(rv2i(rv).(map[int8]int64), e)
  10219. }
  10220. func (_ fastpathT) EncMapInt8Int64V(v map[int8]int64, e *Encoder) {
  10221. if v == nil {
  10222. e.e.EncodeNil()
  10223. return
  10224. }
  10225. ee, esep := e.e, e.hh.hasElemSeparators()
  10226. ee.WriteMapStart(len(v))
  10227. if e.h.Canonical {
  10228. v2 := make([]int64, len(v))
  10229. var i int
  10230. for k, _ := range v {
  10231. v2[i] = int64(k)
  10232. i++
  10233. }
  10234. sort.Sort(intSlice(v2))
  10235. for _, k2 := range v2 {
  10236. if esep {
  10237. ee.WriteMapElemKey()
  10238. }
  10239. ee.EncodeInt(int64(int8(k2)))
  10240. if esep {
  10241. ee.WriteMapElemValue()
  10242. }
  10243. ee.EncodeInt(int64(v[int8(k2)]))
  10244. }
  10245. } else {
  10246. for k2, v2 := range v {
  10247. if esep {
  10248. ee.WriteMapElemKey()
  10249. }
  10250. ee.EncodeInt(int64(k2))
  10251. if esep {
  10252. ee.WriteMapElemValue()
  10253. }
  10254. ee.EncodeInt(int64(v2))
  10255. }
  10256. }
  10257. ee.WriteMapEnd()
  10258. }
  10259. func (e *Encoder) fastpathEncMapInt8Float32R(f *codecFnInfo, rv reflect.Value) {
  10260. fastpathTV.EncMapInt8Float32V(rv2i(rv).(map[int8]float32), e)
  10261. }
  10262. func (_ fastpathT) EncMapInt8Float32V(v map[int8]float32, e *Encoder) {
  10263. if v == nil {
  10264. e.e.EncodeNil()
  10265. return
  10266. }
  10267. ee, esep := e.e, e.hh.hasElemSeparators()
  10268. ee.WriteMapStart(len(v))
  10269. if e.h.Canonical {
  10270. v2 := make([]int64, len(v))
  10271. var i int
  10272. for k, _ := range v {
  10273. v2[i] = int64(k)
  10274. i++
  10275. }
  10276. sort.Sort(intSlice(v2))
  10277. for _, k2 := range v2 {
  10278. if esep {
  10279. ee.WriteMapElemKey()
  10280. }
  10281. ee.EncodeInt(int64(int8(k2)))
  10282. if esep {
  10283. ee.WriteMapElemValue()
  10284. }
  10285. ee.EncodeFloat32(v[int8(k2)])
  10286. }
  10287. } else {
  10288. for k2, v2 := range v {
  10289. if esep {
  10290. ee.WriteMapElemKey()
  10291. }
  10292. ee.EncodeInt(int64(k2))
  10293. if esep {
  10294. ee.WriteMapElemValue()
  10295. }
  10296. ee.EncodeFloat32(v2)
  10297. }
  10298. }
  10299. ee.WriteMapEnd()
  10300. }
  10301. func (e *Encoder) fastpathEncMapInt8Float64R(f *codecFnInfo, rv reflect.Value) {
  10302. fastpathTV.EncMapInt8Float64V(rv2i(rv).(map[int8]float64), e)
  10303. }
  10304. func (_ fastpathT) EncMapInt8Float64V(v map[int8]float64, e *Encoder) {
  10305. if v == nil {
  10306. e.e.EncodeNil()
  10307. return
  10308. }
  10309. ee, esep := e.e, e.hh.hasElemSeparators()
  10310. ee.WriteMapStart(len(v))
  10311. if e.h.Canonical {
  10312. v2 := make([]int64, len(v))
  10313. var i int
  10314. for k, _ := range v {
  10315. v2[i] = int64(k)
  10316. i++
  10317. }
  10318. sort.Sort(intSlice(v2))
  10319. for _, k2 := range v2 {
  10320. if esep {
  10321. ee.WriteMapElemKey()
  10322. }
  10323. ee.EncodeInt(int64(int8(k2)))
  10324. if esep {
  10325. ee.WriteMapElemValue()
  10326. }
  10327. ee.EncodeFloat64(v[int8(k2)])
  10328. }
  10329. } else {
  10330. for k2, v2 := range v {
  10331. if esep {
  10332. ee.WriteMapElemKey()
  10333. }
  10334. ee.EncodeInt(int64(k2))
  10335. if esep {
  10336. ee.WriteMapElemValue()
  10337. }
  10338. ee.EncodeFloat64(v2)
  10339. }
  10340. }
  10341. ee.WriteMapEnd()
  10342. }
  10343. func (e *Encoder) fastpathEncMapInt8BoolR(f *codecFnInfo, rv reflect.Value) {
  10344. fastpathTV.EncMapInt8BoolV(rv2i(rv).(map[int8]bool), e)
  10345. }
  10346. func (_ fastpathT) EncMapInt8BoolV(v map[int8]bool, e *Encoder) {
  10347. if v == nil {
  10348. e.e.EncodeNil()
  10349. return
  10350. }
  10351. ee, esep := e.e, e.hh.hasElemSeparators()
  10352. ee.WriteMapStart(len(v))
  10353. if e.h.Canonical {
  10354. v2 := make([]int64, len(v))
  10355. var i int
  10356. for k, _ := range v {
  10357. v2[i] = int64(k)
  10358. i++
  10359. }
  10360. sort.Sort(intSlice(v2))
  10361. for _, k2 := range v2 {
  10362. if esep {
  10363. ee.WriteMapElemKey()
  10364. }
  10365. ee.EncodeInt(int64(int8(k2)))
  10366. if esep {
  10367. ee.WriteMapElemValue()
  10368. }
  10369. ee.EncodeBool(v[int8(k2)])
  10370. }
  10371. } else {
  10372. for k2, v2 := range v {
  10373. if esep {
  10374. ee.WriteMapElemKey()
  10375. }
  10376. ee.EncodeInt(int64(k2))
  10377. if esep {
  10378. ee.WriteMapElemValue()
  10379. }
  10380. ee.EncodeBool(v2)
  10381. }
  10382. }
  10383. ee.WriteMapEnd()
  10384. }
  10385. func (e *Encoder) fastpathEncMapInt16IntfR(f *codecFnInfo, rv reflect.Value) {
  10386. fastpathTV.EncMapInt16IntfV(rv2i(rv).(map[int16]interface{}), e)
  10387. }
  10388. func (_ fastpathT) EncMapInt16IntfV(v map[int16]interface{}, e *Encoder) {
  10389. if v == nil {
  10390. e.e.EncodeNil()
  10391. return
  10392. }
  10393. ee, esep := e.e, e.hh.hasElemSeparators()
  10394. ee.WriteMapStart(len(v))
  10395. if e.h.Canonical {
  10396. v2 := make([]int64, len(v))
  10397. var i int
  10398. for k, _ := range v {
  10399. v2[i] = int64(k)
  10400. i++
  10401. }
  10402. sort.Sort(intSlice(v2))
  10403. for _, k2 := range v2 {
  10404. if esep {
  10405. ee.WriteMapElemKey()
  10406. }
  10407. ee.EncodeInt(int64(int16(k2)))
  10408. if esep {
  10409. ee.WriteMapElemValue()
  10410. }
  10411. e.encode(v[int16(k2)])
  10412. }
  10413. } else {
  10414. for k2, v2 := range v {
  10415. if esep {
  10416. ee.WriteMapElemKey()
  10417. }
  10418. ee.EncodeInt(int64(k2))
  10419. if esep {
  10420. ee.WriteMapElemValue()
  10421. }
  10422. e.encode(v2)
  10423. }
  10424. }
  10425. ee.WriteMapEnd()
  10426. }
  10427. func (e *Encoder) fastpathEncMapInt16StringR(f *codecFnInfo, rv reflect.Value) {
  10428. fastpathTV.EncMapInt16StringV(rv2i(rv).(map[int16]string), e)
  10429. }
  10430. func (_ fastpathT) EncMapInt16StringV(v map[int16]string, e *Encoder) {
  10431. if v == nil {
  10432. e.e.EncodeNil()
  10433. return
  10434. }
  10435. ee, esep := e.e, e.hh.hasElemSeparators()
  10436. ee.WriteMapStart(len(v))
  10437. if e.h.Canonical {
  10438. v2 := make([]int64, len(v))
  10439. var i int
  10440. for k, _ := range v {
  10441. v2[i] = int64(k)
  10442. i++
  10443. }
  10444. sort.Sort(intSlice(v2))
  10445. for _, k2 := range v2 {
  10446. if esep {
  10447. ee.WriteMapElemKey()
  10448. }
  10449. ee.EncodeInt(int64(int16(k2)))
  10450. if esep {
  10451. ee.WriteMapElemValue()
  10452. }
  10453. ee.EncodeString(c_UTF8, v[int16(k2)])
  10454. }
  10455. } else {
  10456. for k2, v2 := range v {
  10457. if esep {
  10458. ee.WriteMapElemKey()
  10459. }
  10460. ee.EncodeInt(int64(k2))
  10461. if esep {
  10462. ee.WriteMapElemValue()
  10463. }
  10464. ee.EncodeString(c_UTF8, v2)
  10465. }
  10466. }
  10467. ee.WriteMapEnd()
  10468. }
  10469. func (e *Encoder) fastpathEncMapInt16UintR(f *codecFnInfo, rv reflect.Value) {
  10470. fastpathTV.EncMapInt16UintV(rv2i(rv).(map[int16]uint), e)
  10471. }
  10472. func (_ fastpathT) EncMapInt16UintV(v map[int16]uint, e *Encoder) {
  10473. if v == nil {
  10474. e.e.EncodeNil()
  10475. return
  10476. }
  10477. ee, esep := e.e, e.hh.hasElemSeparators()
  10478. ee.WriteMapStart(len(v))
  10479. if e.h.Canonical {
  10480. v2 := make([]int64, len(v))
  10481. var i int
  10482. for k, _ := range v {
  10483. v2[i] = int64(k)
  10484. i++
  10485. }
  10486. sort.Sort(intSlice(v2))
  10487. for _, k2 := range v2 {
  10488. if esep {
  10489. ee.WriteMapElemKey()
  10490. }
  10491. ee.EncodeInt(int64(int16(k2)))
  10492. if esep {
  10493. ee.WriteMapElemValue()
  10494. }
  10495. ee.EncodeUint(uint64(v[int16(k2)]))
  10496. }
  10497. } else {
  10498. for k2, v2 := range v {
  10499. if esep {
  10500. ee.WriteMapElemKey()
  10501. }
  10502. ee.EncodeInt(int64(k2))
  10503. if esep {
  10504. ee.WriteMapElemValue()
  10505. }
  10506. ee.EncodeUint(uint64(v2))
  10507. }
  10508. }
  10509. ee.WriteMapEnd()
  10510. }
  10511. func (e *Encoder) fastpathEncMapInt16Uint8R(f *codecFnInfo, rv reflect.Value) {
  10512. fastpathTV.EncMapInt16Uint8V(rv2i(rv).(map[int16]uint8), e)
  10513. }
  10514. func (_ fastpathT) EncMapInt16Uint8V(v map[int16]uint8, e *Encoder) {
  10515. if v == nil {
  10516. e.e.EncodeNil()
  10517. return
  10518. }
  10519. ee, esep := e.e, e.hh.hasElemSeparators()
  10520. ee.WriteMapStart(len(v))
  10521. if e.h.Canonical {
  10522. v2 := make([]int64, len(v))
  10523. var i int
  10524. for k, _ := range v {
  10525. v2[i] = int64(k)
  10526. i++
  10527. }
  10528. sort.Sort(intSlice(v2))
  10529. for _, k2 := range v2 {
  10530. if esep {
  10531. ee.WriteMapElemKey()
  10532. }
  10533. ee.EncodeInt(int64(int16(k2)))
  10534. if esep {
  10535. ee.WriteMapElemValue()
  10536. }
  10537. ee.EncodeUint(uint64(v[int16(k2)]))
  10538. }
  10539. } else {
  10540. for k2, v2 := range v {
  10541. if esep {
  10542. ee.WriteMapElemKey()
  10543. }
  10544. ee.EncodeInt(int64(k2))
  10545. if esep {
  10546. ee.WriteMapElemValue()
  10547. }
  10548. ee.EncodeUint(uint64(v2))
  10549. }
  10550. }
  10551. ee.WriteMapEnd()
  10552. }
  10553. func (e *Encoder) fastpathEncMapInt16Uint16R(f *codecFnInfo, rv reflect.Value) {
  10554. fastpathTV.EncMapInt16Uint16V(rv2i(rv).(map[int16]uint16), e)
  10555. }
  10556. func (_ fastpathT) EncMapInt16Uint16V(v map[int16]uint16, e *Encoder) {
  10557. if v == nil {
  10558. e.e.EncodeNil()
  10559. return
  10560. }
  10561. ee, esep := e.e, e.hh.hasElemSeparators()
  10562. ee.WriteMapStart(len(v))
  10563. if e.h.Canonical {
  10564. v2 := make([]int64, len(v))
  10565. var i int
  10566. for k, _ := range v {
  10567. v2[i] = int64(k)
  10568. i++
  10569. }
  10570. sort.Sort(intSlice(v2))
  10571. for _, k2 := range v2 {
  10572. if esep {
  10573. ee.WriteMapElemKey()
  10574. }
  10575. ee.EncodeInt(int64(int16(k2)))
  10576. if esep {
  10577. ee.WriteMapElemValue()
  10578. }
  10579. ee.EncodeUint(uint64(v[int16(k2)]))
  10580. }
  10581. } else {
  10582. for k2, v2 := range v {
  10583. if esep {
  10584. ee.WriteMapElemKey()
  10585. }
  10586. ee.EncodeInt(int64(k2))
  10587. if esep {
  10588. ee.WriteMapElemValue()
  10589. }
  10590. ee.EncodeUint(uint64(v2))
  10591. }
  10592. }
  10593. ee.WriteMapEnd()
  10594. }
  10595. func (e *Encoder) fastpathEncMapInt16Uint32R(f *codecFnInfo, rv reflect.Value) {
  10596. fastpathTV.EncMapInt16Uint32V(rv2i(rv).(map[int16]uint32), e)
  10597. }
  10598. func (_ fastpathT) EncMapInt16Uint32V(v map[int16]uint32, e *Encoder) {
  10599. if v == nil {
  10600. e.e.EncodeNil()
  10601. return
  10602. }
  10603. ee, esep := e.e, e.hh.hasElemSeparators()
  10604. ee.WriteMapStart(len(v))
  10605. if e.h.Canonical {
  10606. v2 := make([]int64, len(v))
  10607. var i int
  10608. for k, _ := range v {
  10609. v2[i] = int64(k)
  10610. i++
  10611. }
  10612. sort.Sort(intSlice(v2))
  10613. for _, k2 := range v2 {
  10614. if esep {
  10615. ee.WriteMapElemKey()
  10616. }
  10617. ee.EncodeInt(int64(int16(k2)))
  10618. if esep {
  10619. ee.WriteMapElemValue()
  10620. }
  10621. ee.EncodeUint(uint64(v[int16(k2)]))
  10622. }
  10623. } else {
  10624. for k2, v2 := range v {
  10625. if esep {
  10626. ee.WriteMapElemKey()
  10627. }
  10628. ee.EncodeInt(int64(k2))
  10629. if esep {
  10630. ee.WriteMapElemValue()
  10631. }
  10632. ee.EncodeUint(uint64(v2))
  10633. }
  10634. }
  10635. ee.WriteMapEnd()
  10636. }
  10637. func (e *Encoder) fastpathEncMapInt16Uint64R(f *codecFnInfo, rv reflect.Value) {
  10638. fastpathTV.EncMapInt16Uint64V(rv2i(rv).(map[int16]uint64), e)
  10639. }
  10640. func (_ fastpathT) EncMapInt16Uint64V(v map[int16]uint64, e *Encoder) {
  10641. if v == nil {
  10642. e.e.EncodeNil()
  10643. return
  10644. }
  10645. ee, esep := e.e, e.hh.hasElemSeparators()
  10646. ee.WriteMapStart(len(v))
  10647. if e.h.Canonical {
  10648. v2 := make([]int64, len(v))
  10649. var i int
  10650. for k, _ := range v {
  10651. v2[i] = int64(k)
  10652. i++
  10653. }
  10654. sort.Sort(intSlice(v2))
  10655. for _, k2 := range v2 {
  10656. if esep {
  10657. ee.WriteMapElemKey()
  10658. }
  10659. ee.EncodeInt(int64(int16(k2)))
  10660. if esep {
  10661. ee.WriteMapElemValue()
  10662. }
  10663. ee.EncodeUint(uint64(v[int16(k2)]))
  10664. }
  10665. } else {
  10666. for k2, v2 := range v {
  10667. if esep {
  10668. ee.WriteMapElemKey()
  10669. }
  10670. ee.EncodeInt(int64(k2))
  10671. if esep {
  10672. ee.WriteMapElemValue()
  10673. }
  10674. ee.EncodeUint(uint64(v2))
  10675. }
  10676. }
  10677. ee.WriteMapEnd()
  10678. }
  10679. func (e *Encoder) fastpathEncMapInt16UintptrR(f *codecFnInfo, rv reflect.Value) {
  10680. fastpathTV.EncMapInt16UintptrV(rv2i(rv).(map[int16]uintptr), e)
  10681. }
  10682. func (_ fastpathT) EncMapInt16UintptrV(v map[int16]uintptr, e *Encoder) {
  10683. if v == nil {
  10684. e.e.EncodeNil()
  10685. return
  10686. }
  10687. ee, esep := e.e, e.hh.hasElemSeparators()
  10688. ee.WriteMapStart(len(v))
  10689. if e.h.Canonical {
  10690. v2 := make([]int64, len(v))
  10691. var i int
  10692. for k, _ := range v {
  10693. v2[i] = int64(k)
  10694. i++
  10695. }
  10696. sort.Sort(intSlice(v2))
  10697. for _, k2 := range v2 {
  10698. if esep {
  10699. ee.WriteMapElemKey()
  10700. }
  10701. ee.EncodeInt(int64(int16(k2)))
  10702. if esep {
  10703. ee.WriteMapElemValue()
  10704. }
  10705. e.encode(v[int16(k2)])
  10706. }
  10707. } else {
  10708. for k2, v2 := range v {
  10709. if esep {
  10710. ee.WriteMapElemKey()
  10711. }
  10712. ee.EncodeInt(int64(k2))
  10713. if esep {
  10714. ee.WriteMapElemValue()
  10715. }
  10716. e.encode(v2)
  10717. }
  10718. }
  10719. ee.WriteMapEnd()
  10720. }
  10721. func (e *Encoder) fastpathEncMapInt16IntR(f *codecFnInfo, rv reflect.Value) {
  10722. fastpathTV.EncMapInt16IntV(rv2i(rv).(map[int16]int), e)
  10723. }
  10724. func (_ fastpathT) EncMapInt16IntV(v map[int16]int, e *Encoder) {
  10725. if v == nil {
  10726. e.e.EncodeNil()
  10727. return
  10728. }
  10729. ee, esep := e.e, e.hh.hasElemSeparators()
  10730. ee.WriteMapStart(len(v))
  10731. if e.h.Canonical {
  10732. v2 := make([]int64, len(v))
  10733. var i int
  10734. for k, _ := range v {
  10735. v2[i] = int64(k)
  10736. i++
  10737. }
  10738. sort.Sort(intSlice(v2))
  10739. for _, k2 := range v2 {
  10740. if esep {
  10741. ee.WriteMapElemKey()
  10742. }
  10743. ee.EncodeInt(int64(int16(k2)))
  10744. if esep {
  10745. ee.WriteMapElemValue()
  10746. }
  10747. ee.EncodeInt(int64(v[int16(k2)]))
  10748. }
  10749. } else {
  10750. for k2, v2 := range v {
  10751. if esep {
  10752. ee.WriteMapElemKey()
  10753. }
  10754. ee.EncodeInt(int64(k2))
  10755. if esep {
  10756. ee.WriteMapElemValue()
  10757. }
  10758. ee.EncodeInt(int64(v2))
  10759. }
  10760. }
  10761. ee.WriteMapEnd()
  10762. }
  10763. func (e *Encoder) fastpathEncMapInt16Int8R(f *codecFnInfo, rv reflect.Value) {
  10764. fastpathTV.EncMapInt16Int8V(rv2i(rv).(map[int16]int8), e)
  10765. }
  10766. func (_ fastpathT) EncMapInt16Int8V(v map[int16]int8, e *Encoder) {
  10767. if v == nil {
  10768. e.e.EncodeNil()
  10769. return
  10770. }
  10771. ee, esep := e.e, e.hh.hasElemSeparators()
  10772. ee.WriteMapStart(len(v))
  10773. if e.h.Canonical {
  10774. v2 := make([]int64, len(v))
  10775. var i int
  10776. for k, _ := range v {
  10777. v2[i] = int64(k)
  10778. i++
  10779. }
  10780. sort.Sort(intSlice(v2))
  10781. for _, k2 := range v2 {
  10782. if esep {
  10783. ee.WriteMapElemKey()
  10784. }
  10785. ee.EncodeInt(int64(int16(k2)))
  10786. if esep {
  10787. ee.WriteMapElemValue()
  10788. }
  10789. ee.EncodeInt(int64(v[int16(k2)]))
  10790. }
  10791. } else {
  10792. for k2, v2 := range v {
  10793. if esep {
  10794. ee.WriteMapElemKey()
  10795. }
  10796. ee.EncodeInt(int64(k2))
  10797. if esep {
  10798. ee.WriteMapElemValue()
  10799. }
  10800. ee.EncodeInt(int64(v2))
  10801. }
  10802. }
  10803. ee.WriteMapEnd()
  10804. }
  10805. func (e *Encoder) fastpathEncMapInt16Int16R(f *codecFnInfo, rv reflect.Value) {
  10806. fastpathTV.EncMapInt16Int16V(rv2i(rv).(map[int16]int16), e)
  10807. }
  10808. func (_ fastpathT) EncMapInt16Int16V(v map[int16]int16, e *Encoder) {
  10809. if v == nil {
  10810. e.e.EncodeNil()
  10811. return
  10812. }
  10813. ee, esep := e.e, e.hh.hasElemSeparators()
  10814. ee.WriteMapStart(len(v))
  10815. if e.h.Canonical {
  10816. v2 := make([]int64, len(v))
  10817. var i int
  10818. for k, _ := range v {
  10819. v2[i] = int64(k)
  10820. i++
  10821. }
  10822. sort.Sort(intSlice(v2))
  10823. for _, k2 := range v2 {
  10824. if esep {
  10825. ee.WriteMapElemKey()
  10826. }
  10827. ee.EncodeInt(int64(int16(k2)))
  10828. if esep {
  10829. ee.WriteMapElemValue()
  10830. }
  10831. ee.EncodeInt(int64(v[int16(k2)]))
  10832. }
  10833. } else {
  10834. for k2, v2 := range v {
  10835. if esep {
  10836. ee.WriteMapElemKey()
  10837. }
  10838. ee.EncodeInt(int64(k2))
  10839. if esep {
  10840. ee.WriteMapElemValue()
  10841. }
  10842. ee.EncodeInt(int64(v2))
  10843. }
  10844. }
  10845. ee.WriteMapEnd()
  10846. }
  10847. func (e *Encoder) fastpathEncMapInt16Int32R(f *codecFnInfo, rv reflect.Value) {
  10848. fastpathTV.EncMapInt16Int32V(rv2i(rv).(map[int16]int32), e)
  10849. }
  10850. func (_ fastpathT) EncMapInt16Int32V(v map[int16]int32, e *Encoder) {
  10851. if v == nil {
  10852. e.e.EncodeNil()
  10853. return
  10854. }
  10855. ee, esep := e.e, e.hh.hasElemSeparators()
  10856. ee.WriteMapStart(len(v))
  10857. if e.h.Canonical {
  10858. v2 := make([]int64, len(v))
  10859. var i int
  10860. for k, _ := range v {
  10861. v2[i] = int64(k)
  10862. i++
  10863. }
  10864. sort.Sort(intSlice(v2))
  10865. for _, k2 := range v2 {
  10866. if esep {
  10867. ee.WriteMapElemKey()
  10868. }
  10869. ee.EncodeInt(int64(int16(k2)))
  10870. if esep {
  10871. ee.WriteMapElemValue()
  10872. }
  10873. ee.EncodeInt(int64(v[int16(k2)]))
  10874. }
  10875. } else {
  10876. for k2, v2 := range v {
  10877. if esep {
  10878. ee.WriteMapElemKey()
  10879. }
  10880. ee.EncodeInt(int64(k2))
  10881. if esep {
  10882. ee.WriteMapElemValue()
  10883. }
  10884. ee.EncodeInt(int64(v2))
  10885. }
  10886. }
  10887. ee.WriteMapEnd()
  10888. }
  10889. func (e *Encoder) fastpathEncMapInt16Int64R(f *codecFnInfo, rv reflect.Value) {
  10890. fastpathTV.EncMapInt16Int64V(rv2i(rv).(map[int16]int64), e)
  10891. }
  10892. func (_ fastpathT) EncMapInt16Int64V(v map[int16]int64, e *Encoder) {
  10893. if v == nil {
  10894. e.e.EncodeNil()
  10895. return
  10896. }
  10897. ee, esep := e.e, e.hh.hasElemSeparators()
  10898. ee.WriteMapStart(len(v))
  10899. if e.h.Canonical {
  10900. v2 := make([]int64, len(v))
  10901. var i int
  10902. for k, _ := range v {
  10903. v2[i] = int64(k)
  10904. i++
  10905. }
  10906. sort.Sort(intSlice(v2))
  10907. for _, k2 := range v2 {
  10908. if esep {
  10909. ee.WriteMapElemKey()
  10910. }
  10911. ee.EncodeInt(int64(int16(k2)))
  10912. if esep {
  10913. ee.WriteMapElemValue()
  10914. }
  10915. ee.EncodeInt(int64(v[int16(k2)]))
  10916. }
  10917. } else {
  10918. for k2, v2 := range v {
  10919. if esep {
  10920. ee.WriteMapElemKey()
  10921. }
  10922. ee.EncodeInt(int64(k2))
  10923. if esep {
  10924. ee.WriteMapElemValue()
  10925. }
  10926. ee.EncodeInt(int64(v2))
  10927. }
  10928. }
  10929. ee.WriteMapEnd()
  10930. }
  10931. func (e *Encoder) fastpathEncMapInt16Float32R(f *codecFnInfo, rv reflect.Value) {
  10932. fastpathTV.EncMapInt16Float32V(rv2i(rv).(map[int16]float32), e)
  10933. }
  10934. func (_ fastpathT) EncMapInt16Float32V(v map[int16]float32, e *Encoder) {
  10935. if v == nil {
  10936. e.e.EncodeNil()
  10937. return
  10938. }
  10939. ee, esep := e.e, e.hh.hasElemSeparators()
  10940. ee.WriteMapStart(len(v))
  10941. if e.h.Canonical {
  10942. v2 := make([]int64, len(v))
  10943. var i int
  10944. for k, _ := range v {
  10945. v2[i] = int64(k)
  10946. i++
  10947. }
  10948. sort.Sort(intSlice(v2))
  10949. for _, k2 := range v2 {
  10950. if esep {
  10951. ee.WriteMapElemKey()
  10952. }
  10953. ee.EncodeInt(int64(int16(k2)))
  10954. if esep {
  10955. ee.WriteMapElemValue()
  10956. }
  10957. ee.EncodeFloat32(v[int16(k2)])
  10958. }
  10959. } else {
  10960. for k2, v2 := range v {
  10961. if esep {
  10962. ee.WriteMapElemKey()
  10963. }
  10964. ee.EncodeInt(int64(k2))
  10965. if esep {
  10966. ee.WriteMapElemValue()
  10967. }
  10968. ee.EncodeFloat32(v2)
  10969. }
  10970. }
  10971. ee.WriteMapEnd()
  10972. }
  10973. func (e *Encoder) fastpathEncMapInt16Float64R(f *codecFnInfo, rv reflect.Value) {
  10974. fastpathTV.EncMapInt16Float64V(rv2i(rv).(map[int16]float64), e)
  10975. }
  10976. func (_ fastpathT) EncMapInt16Float64V(v map[int16]float64, e *Encoder) {
  10977. if v == nil {
  10978. e.e.EncodeNil()
  10979. return
  10980. }
  10981. ee, esep := e.e, e.hh.hasElemSeparators()
  10982. ee.WriteMapStart(len(v))
  10983. if e.h.Canonical {
  10984. v2 := make([]int64, len(v))
  10985. var i int
  10986. for k, _ := range v {
  10987. v2[i] = int64(k)
  10988. i++
  10989. }
  10990. sort.Sort(intSlice(v2))
  10991. for _, k2 := range v2 {
  10992. if esep {
  10993. ee.WriteMapElemKey()
  10994. }
  10995. ee.EncodeInt(int64(int16(k2)))
  10996. if esep {
  10997. ee.WriteMapElemValue()
  10998. }
  10999. ee.EncodeFloat64(v[int16(k2)])
  11000. }
  11001. } else {
  11002. for k2, v2 := range v {
  11003. if esep {
  11004. ee.WriteMapElemKey()
  11005. }
  11006. ee.EncodeInt(int64(k2))
  11007. if esep {
  11008. ee.WriteMapElemValue()
  11009. }
  11010. ee.EncodeFloat64(v2)
  11011. }
  11012. }
  11013. ee.WriteMapEnd()
  11014. }
  11015. func (e *Encoder) fastpathEncMapInt16BoolR(f *codecFnInfo, rv reflect.Value) {
  11016. fastpathTV.EncMapInt16BoolV(rv2i(rv).(map[int16]bool), e)
  11017. }
  11018. func (_ fastpathT) EncMapInt16BoolV(v map[int16]bool, e *Encoder) {
  11019. if v == nil {
  11020. e.e.EncodeNil()
  11021. return
  11022. }
  11023. ee, esep := e.e, e.hh.hasElemSeparators()
  11024. ee.WriteMapStart(len(v))
  11025. if e.h.Canonical {
  11026. v2 := make([]int64, len(v))
  11027. var i int
  11028. for k, _ := range v {
  11029. v2[i] = int64(k)
  11030. i++
  11031. }
  11032. sort.Sort(intSlice(v2))
  11033. for _, k2 := range v2 {
  11034. if esep {
  11035. ee.WriteMapElemKey()
  11036. }
  11037. ee.EncodeInt(int64(int16(k2)))
  11038. if esep {
  11039. ee.WriteMapElemValue()
  11040. }
  11041. ee.EncodeBool(v[int16(k2)])
  11042. }
  11043. } else {
  11044. for k2, v2 := range v {
  11045. if esep {
  11046. ee.WriteMapElemKey()
  11047. }
  11048. ee.EncodeInt(int64(k2))
  11049. if esep {
  11050. ee.WriteMapElemValue()
  11051. }
  11052. ee.EncodeBool(v2)
  11053. }
  11054. }
  11055. ee.WriteMapEnd()
  11056. }
  11057. func (e *Encoder) fastpathEncMapInt32IntfR(f *codecFnInfo, rv reflect.Value) {
  11058. fastpathTV.EncMapInt32IntfV(rv2i(rv).(map[int32]interface{}), e)
  11059. }
  11060. func (_ fastpathT) EncMapInt32IntfV(v map[int32]interface{}, e *Encoder) {
  11061. if v == nil {
  11062. e.e.EncodeNil()
  11063. return
  11064. }
  11065. ee, esep := e.e, e.hh.hasElemSeparators()
  11066. ee.WriteMapStart(len(v))
  11067. if e.h.Canonical {
  11068. v2 := make([]int64, len(v))
  11069. var i int
  11070. for k, _ := range v {
  11071. v2[i] = int64(k)
  11072. i++
  11073. }
  11074. sort.Sort(intSlice(v2))
  11075. for _, k2 := range v2 {
  11076. if esep {
  11077. ee.WriteMapElemKey()
  11078. }
  11079. ee.EncodeInt(int64(int32(k2)))
  11080. if esep {
  11081. ee.WriteMapElemValue()
  11082. }
  11083. e.encode(v[int32(k2)])
  11084. }
  11085. } else {
  11086. for k2, v2 := range v {
  11087. if esep {
  11088. ee.WriteMapElemKey()
  11089. }
  11090. ee.EncodeInt(int64(k2))
  11091. if esep {
  11092. ee.WriteMapElemValue()
  11093. }
  11094. e.encode(v2)
  11095. }
  11096. }
  11097. ee.WriteMapEnd()
  11098. }
  11099. func (e *Encoder) fastpathEncMapInt32StringR(f *codecFnInfo, rv reflect.Value) {
  11100. fastpathTV.EncMapInt32StringV(rv2i(rv).(map[int32]string), e)
  11101. }
  11102. func (_ fastpathT) EncMapInt32StringV(v map[int32]string, e *Encoder) {
  11103. if v == nil {
  11104. e.e.EncodeNil()
  11105. return
  11106. }
  11107. ee, esep := e.e, e.hh.hasElemSeparators()
  11108. ee.WriteMapStart(len(v))
  11109. if e.h.Canonical {
  11110. v2 := make([]int64, len(v))
  11111. var i int
  11112. for k, _ := range v {
  11113. v2[i] = int64(k)
  11114. i++
  11115. }
  11116. sort.Sort(intSlice(v2))
  11117. for _, k2 := range v2 {
  11118. if esep {
  11119. ee.WriteMapElemKey()
  11120. }
  11121. ee.EncodeInt(int64(int32(k2)))
  11122. if esep {
  11123. ee.WriteMapElemValue()
  11124. }
  11125. ee.EncodeString(c_UTF8, v[int32(k2)])
  11126. }
  11127. } else {
  11128. for k2, v2 := range v {
  11129. if esep {
  11130. ee.WriteMapElemKey()
  11131. }
  11132. ee.EncodeInt(int64(k2))
  11133. if esep {
  11134. ee.WriteMapElemValue()
  11135. }
  11136. ee.EncodeString(c_UTF8, v2)
  11137. }
  11138. }
  11139. ee.WriteMapEnd()
  11140. }
  11141. func (e *Encoder) fastpathEncMapInt32UintR(f *codecFnInfo, rv reflect.Value) {
  11142. fastpathTV.EncMapInt32UintV(rv2i(rv).(map[int32]uint), e)
  11143. }
  11144. func (_ fastpathT) EncMapInt32UintV(v map[int32]uint, e *Encoder) {
  11145. if v == nil {
  11146. e.e.EncodeNil()
  11147. return
  11148. }
  11149. ee, esep := e.e, e.hh.hasElemSeparators()
  11150. ee.WriteMapStart(len(v))
  11151. if e.h.Canonical {
  11152. v2 := make([]int64, len(v))
  11153. var i int
  11154. for k, _ := range v {
  11155. v2[i] = int64(k)
  11156. i++
  11157. }
  11158. sort.Sort(intSlice(v2))
  11159. for _, k2 := range v2 {
  11160. if esep {
  11161. ee.WriteMapElemKey()
  11162. }
  11163. ee.EncodeInt(int64(int32(k2)))
  11164. if esep {
  11165. ee.WriteMapElemValue()
  11166. }
  11167. ee.EncodeUint(uint64(v[int32(k2)]))
  11168. }
  11169. } else {
  11170. for k2, v2 := range v {
  11171. if esep {
  11172. ee.WriteMapElemKey()
  11173. }
  11174. ee.EncodeInt(int64(k2))
  11175. if esep {
  11176. ee.WriteMapElemValue()
  11177. }
  11178. ee.EncodeUint(uint64(v2))
  11179. }
  11180. }
  11181. ee.WriteMapEnd()
  11182. }
  11183. func (e *Encoder) fastpathEncMapInt32Uint8R(f *codecFnInfo, rv reflect.Value) {
  11184. fastpathTV.EncMapInt32Uint8V(rv2i(rv).(map[int32]uint8), e)
  11185. }
  11186. func (_ fastpathT) EncMapInt32Uint8V(v map[int32]uint8, e *Encoder) {
  11187. if v == nil {
  11188. e.e.EncodeNil()
  11189. return
  11190. }
  11191. ee, esep := e.e, e.hh.hasElemSeparators()
  11192. ee.WriteMapStart(len(v))
  11193. if e.h.Canonical {
  11194. v2 := make([]int64, len(v))
  11195. var i int
  11196. for k, _ := range v {
  11197. v2[i] = int64(k)
  11198. i++
  11199. }
  11200. sort.Sort(intSlice(v2))
  11201. for _, k2 := range v2 {
  11202. if esep {
  11203. ee.WriteMapElemKey()
  11204. }
  11205. ee.EncodeInt(int64(int32(k2)))
  11206. if esep {
  11207. ee.WriteMapElemValue()
  11208. }
  11209. ee.EncodeUint(uint64(v[int32(k2)]))
  11210. }
  11211. } else {
  11212. for k2, v2 := range v {
  11213. if esep {
  11214. ee.WriteMapElemKey()
  11215. }
  11216. ee.EncodeInt(int64(k2))
  11217. if esep {
  11218. ee.WriteMapElemValue()
  11219. }
  11220. ee.EncodeUint(uint64(v2))
  11221. }
  11222. }
  11223. ee.WriteMapEnd()
  11224. }
  11225. func (e *Encoder) fastpathEncMapInt32Uint16R(f *codecFnInfo, rv reflect.Value) {
  11226. fastpathTV.EncMapInt32Uint16V(rv2i(rv).(map[int32]uint16), e)
  11227. }
  11228. func (_ fastpathT) EncMapInt32Uint16V(v map[int32]uint16, e *Encoder) {
  11229. if v == nil {
  11230. e.e.EncodeNil()
  11231. return
  11232. }
  11233. ee, esep := e.e, e.hh.hasElemSeparators()
  11234. ee.WriteMapStart(len(v))
  11235. if e.h.Canonical {
  11236. v2 := make([]int64, len(v))
  11237. var i int
  11238. for k, _ := range v {
  11239. v2[i] = int64(k)
  11240. i++
  11241. }
  11242. sort.Sort(intSlice(v2))
  11243. for _, k2 := range v2 {
  11244. if esep {
  11245. ee.WriteMapElemKey()
  11246. }
  11247. ee.EncodeInt(int64(int32(k2)))
  11248. if esep {
  11249. ee.WriteMapElemValue()
  11250. }
  11251. ee.EncodeUint(uint64(v[int32(k2)]))
  11252. }
  11253. } else {
  11254. for k2, v2 := range v {
  11255. if esep {
  11256. ee.WriteMapElemKey()
  11257. }
  11258. ee.EncodeInt(int64(k2))
  11259. if esep {
  11260. ee.WriteMapElemValue()
  11261. }
  11262. ee.EncodeUint(uint64(v2))
  11263. }
  11264. }
  11265. ee.WriteMapEnd()
  11266. }
  11267. func (e *Encoder) fastpathEncMapInt32Uint32R(f *codecFnInfo, rv reflect.Value) {
  11268. fastpathTV.EncMapInt32Uint32V(rv2i(rv).(map[int32]uint32), e)
  11269. }
  11270. func (_ fastpathT) EncMapInt32Uint32V(v map[int32]uint32, e *Encoder) {
  11271. if v == nil {
  11272. e.e.EncodeNil()
  11273. return
  11274. }
  11275. ee, esep := e.e, e.hh.hasElemSeparators()
  11276. ee.WriteMapStart(len(v))
  11277. if e.h.Canonical {
  11278. v2 := make([]int64, len(v))
  11279. var i int
  11280. for k, _ := range v {
  11281. v2[i] = int64(k)
  11282. i++
  11283. }
  11284. sort.Sort(intSlice(v2))
  11285. for _, k2 := range v2 {
  11286. if esep {
  11287. ee.WriteMapElemKey()
  11288. }
  11289. ee.EncodeInt(int64(int32(k2)))
  11290. if esep {
  11291. ee.WriteMapElemValue()
  11292. }
  11293. ee.EncodeUint(uint64(v[int32(k2)]))
  11294. }
  11295. } else {
  11296. for k2, v2 := range v {
  11297. if esep {
  11298. ee.WriteMapElemKey()
  11299. }
  11300. ee.EncodeInt(int64(k2))
  11301. if esep {
  11302. ee.WriteMapElemValue()
  11303. }
  11304. ee.EncodeUint(uint64(v2))
  11305. }
  11306. }
  11307. ee.WriteMapEnd()
  11308. }
  11309. func (e *Encoder) fastpathEncMapInt32Uint64R(f *codecFnInfo, rv reflect.Value) {
  11310. fastpathTV.EncMapInt32Uint64V(rv2i(rv).(map[int32]uint64), e)
  11311. }
  11312. func (_ fastpathT) EncMapInt32Uint64V(v map[int32]uint64, e *Encoder) {
  11313. if v == nil {
  11314. e.e.EncodeNil()
  11315. return
  11316. }
  11317. ee, esep := e.e, e.hh.hasElemSeparators()
  11318. ee.WriteMapStart(len(v))
  11319. if e.h.Canonical {
  11320. v2 := make([]int64, len(v))
  11321. var i int
  11322. for k, _ := range v {
  11323. v2[i] = int64(k)
  11324. i++
  11325. }
  11326. sort.Sort(intSlice(v2))
  11327. for _, k2 := range v2 {
  11328. if esep {
  11329. ee.WriteMapElemKey()
  11330. }
  11331. ee.EncodeInt(int64(int32(k2)))
  11332. if esep {
  11333. ee.WriteMapElemValue()
  11334. }
  11335. ee.EncodeUint(uint64(v[int32(k2)]))
  11336. }
  11337. } else {
  11338. for k2, v2 := range v {
  11339. if esep {
  11340. ee.WriteMapElemKey()
  11341. }
  11342. ee.EncodeInt(int64(k2))
  11343. if esep {
  11344. ee.WriteMapElemValue()
  11345. }
  11346. ee.EncodeUint(uint64(v2))
  11347. }
  11348. }
  11349. ee.WriteMapEnd()
  11350. }
  11351. func (e *Encoder) fastpathEncMapInt32UintptrR(f *codecFnInfo, rv reflect.Value) {
  11352. fastpathTV.EncMapInt32UintptrV(rv2i(rv).(map[int32]uintptr), e)
  11353. }
  11354. func (_ fastpathT) EncMapInt32UintptrV(v map[int32]uintptr, e *Encoder) {
  11355. if v == nil {
  11356. e.e.EncodeNil()
  11357. return
  11358. }
  11359. ee, esep := e.e, e.hh.hasElemSeparators()
  11360. ee.WriteMapStart(len(v))
  11361. if e.h.Canonical {
  11362. v2 := make([]int64, len(v))
  11363. var i int
  11364. for k, _ := range v {
  11365. v2[i] = int64(k)
  11366. i++
  11367. }
  11368. sort.Sort(intSlice(v2))
  11369. for _, k2 := range v2 {
  11370. if esep {
  11371. ee.WriteMapElemKey()
  11372. }
  11373. ee.EncodeInt(int64(int32(k2)))
  11374. if esep {
  11375. ee.WriteMapElemValue()
  11376. }
  11377. e.encode(v[int32(k2)])
  11378. }
  11379. } else {
  11380. for k2, v2 := range v {
  11381. if esep {
  11382. ee.WriteMapElemKey()
  11383. }
  11384. ee.EncodeInt(int64(k2))
  11385. if esep {
  11386. ee.WriteMapElemValue()
  11387. }
  11388. e.encode(v2)
  11389. }
  11390. }
  11391. ee.WriteMapEnd()
  11392. }
  11393. func (e *Encoder) fastpathEncMapInt32IntR(f *codecFnInfo, rv reflect.Value) {
  11394. fastpathTV.EncMapInt32IntV(rv2i(rv).(map[int32]int), e)
  11395. }
  11396. func (_ fastpathT) EncMapInt32IntV(v map[int32]int, e *Encoder) {
  11397. if v == nil {
  11398. e.e.EncodeNil()
  11399. return
  11400. }
  11401. ee, esep := e.e, e.hh.hasElemSeparators()
  11402. ee.WriteMapStart(len(v))
  11403. if e.h.Canonical {
  11404. v2 := make([]int64, len(v))
  11405. var i int
  11406. for k, _ := range v {
  11407. v2[i] = int64(k)
  11408. i++
  11409. }
  11410. sort.Sort(intSlice(v2))
  11411. for _, k2 := range v2 {
  11412. if esep {
  11413. ee.WriteMapElemKey()
  11414. }
  11415. ee.EncodeInt(int64(int32(k2)))
  11416. if esep {
  11417. ee.WriteMapElemValue()
  11418. }
  11419. ee.EncodeInt(int64(v[int32(k2)]))
  11420. }
  11421. } else {
  11422. for k2, v2 := range v {
  11423. if esep {
  11424. ee.WriteMapElemKey()
  11425. }
  11426. ee.EncodeInt(int64(k2))
  11427. if esep {
  11428. ee.WriteMapElemValue()
  11429. }
  11430. ee.EncodeInt(int64(v2))
  11431. }
  11432. }
  11433. ee.WriteMapEnd()
  11434. }
  11435. func (e *Encoder) fastpathEncMapInt32Int8R(f *codecFnInfo, rv reflect.Value) {
  11436. fastpathTV.EncMapInt32Int8V(rv2i(rv).(map[int32]int8), e)
  11437. }
  11438. func (_ fastpathT) EncMapInt32Int8V(v map[int32]int8, e *Encoder) {
  11439. if v == nil {
  11440. e.e.EncodeNil()
  11441. return
  11442. }
  11443. ee, esep := e.e, e.hh.hasElemSeparators()
  11444. ee.WriteMapStart(len(v))
  11445. if e.h.Canonical {
  11446. v2 := make([]int64, len(v))
  11447. var i int
  11448. for k, _ := range v {
  11449. v2[i] = int64(k)
  11450. i++
  11451. }
  11452. sort.Sort(intSlice(v2))
  11453. for _, k2 := range v2 {
  11454. if esep {
  11455. ee.WriteMapElemKey()
  11456. }
  11457. ee.EncodeInt(int64(int32(k2)))
  11458. if esep {
  11459. ee.WriteMapElemValue()
  11460. }
  11461. ee.EncodeInt(int64(v[int32(k2)]))
  11462. }
  11463. } else {
  11464. for k2, v2 := range v {
  11465. if esep {
  11466. ee.WriteMapElemKey()
  11467. }
  11468. ee.EncodeInt(int64(k2))
  11469. if esep {
  11470. ee.WriteMapElemValue()
  11471. }
  11472. ee.EncodeInt(int64(v2))
  11473. }
  11474. }
  11475. ee.WriteMapEnd()
  11476. }
  11477. func (e *Encoder) fastpathEncMapInt32Int16R(f *codecFnInfo, rv reflect.Value) {
  11478. fastpathTV.EncMapInt32Int16V(rv2i(rv).(map[int32]int16), e)
  11479. }
  11480. func (_ fastpathT) EncMapInt32Int16V(v map[int32]int16, e *Encoder) {
  11481. if v == nil {
  11482. e.e.EncodeNil()
  11483. return
  11484. }
  11485. ee, esep := e.e, e.hh.hasElemSeparators()
  11486. ee.WriteMapStart(len(v))
  11487. if e.h.Canonical {
  11488. v2 := make([]int64, len(v))
  11489. var i int
  11490. for k, _ := range v {
  11491. v2[i] = int64(k)
  11492. i++
  11493. }
  11494. sort.Sort(intSlice(v2))
  11495. for _, k2 := range v2 {
  11496. if esep {
  11497. ee.WriteMapElemKey()
  11498. }
  11499. ee.EncodeInt(int64(int32(k2)))
  11500. if esep {
  11501. ee.WriteMapElemValue()
  11502. }
  11503. ee.EncodeInt(int64(v[int32(k2)]))
  11504. }
  11505. } else {
  11506. for k2, v2 := range v {
  11507. if esep {
  11508. ee.WriteMapElemKey()
  11509. }
  11510. ee.EncodeInt(int64(k2))
  11511. if esep {
  11512. ee.WriteMapElemValue()
  11513. }
  11514. ee.EncodeInt(int64(v2))
  11515. }
  11516. }
  11517. ee.WriteMapEnd()
  11518. }
  11519. func (e *Encoder) fastpathEncMapInt32Int32R(f *codecFnInfo, rv reflect.Value) {
  11520. fastpathTV.EncMapInt32Int32V(rv2i(rv).(map[int32]int32), e)
  11521. }
  11522. func (_ fastpathT) EncMapInt32Int32V(v map[int32]int32, e *Encoder) {
  11523. if v == nil {
  11524. e.e.EncodeNil()
  11525. return
  11526. }
  11527. ee, esep := e.e, e.hh.hasElemSeparators()
  11528. ee.WriteMapStart(len(v))
  11529. if e.h.Canonical {
  11530. v2 := make([]int64, len(v))
  11531. var i int
  11532. for k, _ := range v {
  11533. v2[i] = int64(k)
  11534. i++
  11535. }
  11536. sort.Sort(intSlice(v2))
  11537. for _, k2 := range v2 {
  11538. if esep {
  11539. ee.WriteMapElemKey()
  11540. }
  11541. ee.EncodeInt(int64(int32(k2)))
  11542. if esep {
  11543. ee.WriteMapElemValue()
  11544. }
  11545. ee.EncodeInt(int64(v[int32(k2)]))
  11546. }
  11547. } else {
  11548. for k2, v2 := range v {
  11549. if esep {
  11550. ee.WriteMapElemKey()
  11551. }
  11552. ee.EncodeInt(int64(k2))
  11553. if esep {
  11554. ee.WriteMapElemValue()
  11555. }
  11556. ee.EncodeInt(int64(v2))
  11557. }
  11558. }
  11559. ee.WriteMapEnd()
  11560. }
  11561. func (e *Encoder) fastpathEncMapInt32Int64R(f *codecFnInfo, rv reflect.Value) {
  11562. fastpathTV.EncMapInt32Int64V(rv2i(rv).(map[int32]int64), e)
  11563. }
  11564. func (_ fastpathT) EncMapInt32Int64V(v map[int32]int64, e *Encoder) {
  11565. if v == nil {
  11566. e.e.EncodeNil()
  11567. return
  11568. }
  11569. ee, esep := e.e, e.hh.hasElemSeparators()
  11570. ee.WriteMapStart(len(v))
  11571. if e.h.Canonical {
  11572. v2 := make([]int64, len(v))
  11573. var i int
  11574. for k, _ := range v {
  11575. v2[i] = int64(k)
  11576. i++
  11577. }
  11578. sort.Sort(intSlice(v2))
  11579. for _, k2 := range v2 {
  11580. if esep {
  11581. ee.WriteMapElemKey()
  11582. }
  11583. ee.EncodeInt(int64(int32(k2)))
  11584. if esep {
  11585. ee.WriteMapElemValue()
  11586. }
  11587. ee.EncodeInt(int64(v[int32(k2)]))
  11588. }
  11589. } else {
  11590. for k2, v2 := range v {
  11591. if esep {
  11592. ee.WriteMapElemKey()
  11593. }
  11594. ee.EncodeInt(int64(k2))
  11595. if esep {
  11596. ee.WriteMapElemValue()
  11597. }
  11598. ee.EncodeInt(int64(v2))
  11599. }
  11600. }
  11601. ee.WriteMapEnd()
  11602. }
  11603. func (e *Encoder) fastpathEncMapInt32Float32R(f *codecFnInfo, rv reflect.Value) {
  11604. fastpathTV.EncMapInt32Float32V(rv2i(rv).(map[int32]float32), e)
  11605. }
  11606. func (_ fastpathT) EncMapInt32Float32V(v map[int32]float32, e *Encoder) {
  11607. if v == nil {
  11608. e.e.EncodeNil()
  11609. return
  11610. }
  11611. ee, esep := e.e, e.hh.hasElemSeparators()
  11612. ee.WriteMapStart(len(v))
  11613. if e.h.Canonical {
  11614. v2 := make([]int64, len(v))
  11615. var i int
  11616. for k, _ := range v {
  11617. v2[i] = int64(k)
  11618. i++
  11619. }
  11620. sort.Sort(intSlice(v2))
  11621. for _, k2 := range v2 {
  11622. if esep {
  11623. ee.WriteMapElemKey()
  11624. }
  11625. ee.EncodeInt(int64(int32(k2)))
  11626. if esep {
  11627. ee.WriteMapElemValue()
  11628. }
  11629. ee.EncodeFloat32(v[int32(k2)])
  11630. }
  11631. } else {
  11632. for k2, v2 := range v {
  11633. if esep {
  11634. ee.WriteMapElemKey()
  11635. }
  11636. ee.EncodeInt(int64(k2))
  11637. if esep {
  11638. ee.WriteMapElemValue()
  11639. }
  11640. ee.EncodeFloat32(v2)
  11641. }
  11642. }
  11643. ee.WriteMapEnd()
  11644. }
  11645. func (e *Encoder) fastpathEncMapInt32Float64R(f *codecFnInfo, rv reflect.Value) {
  11646. fastpathTV.EncMapInt32Float64V(rv2i(rv).(map[int32]float64), e)
  11647. }
  11648. func (_ fastpathT) EncMapInt32Float64V(v map[int32]float64, e *Encoder) {
  11649. if v == nil {
  11650. e.e.EncodeNil()
  11651. return
  11652. }
  11653. ee, esep := e.e, e.hh.hasElemSeparators()
  11654. ee.WriteMapStart(len(v))
  11655. if e.h.Canonical {
  11656. v2 := make([]int64, len(v))
  11657. var i int
  11658. for k, _ := range v {
  11659. v2[i] = int64(k)
  11660. i++
  11661. }
  11662. sort.Sort(intSlice(v2))
  11663. for _, k2 := range v2 {
  11664. if esep {
  11665. ee.WriteMapElemKey()
  11666. }
  11667. ee.EncodeInt(int64(int32(k2)))
  11668. if esep {
  11669. ee.WriteMapElemValue()
  11670. }
  11671. ee.EncodeFloat64(v[int32(k2)])
  11672. }
  11673. } else {
  11674. for k2, v2 := range v {
  11675. if esep {
  11676. ee.WriteMapElemKey()
  11677. }
  11678. ee.EncodeInt(int64(k2))
  11679. if esep {
  11680. ee.WriteMapElemValue()
  11681. }
  11682. ee.EncodeFloat64(v2)
  11683. }
  11684. }
  11685. ee.WriteMapEnd()
  11686. }
  11687. func (e *Encoder) fastpathEncMapInt32BoolR(f *codecFnInfo, rv reflect.Value) {
  11688. fastpathTV.EncMapInt32BoolV(rv2i(rv).(map[int32]bool), e)
  11689. }
  11690. func (_ fastpathT) EncMapInt32BoolV(v map[int32]bool, e *Encoder) {
  11691. if v == nil {
  11692. e.e.EncodeNil()
  11693. return
  11694. }
  11695. ee, esep := e.e, e.hh.hasElemSeparators()
  11696. ee.WriteMapStart(len(v))
  11697. if e.h.Canonical {
  11698. v2 := make([]int64, len(v))
  11699. var i int
  11700. for k, _ := range v {
  11701. v2[i] = int64(k)
  11702. i++
  11703. }
  11704. sort.Sort(intSlice(v2))
  11705. for _, k2 := range v2 {
  11706. if esep {
  11707. ee.WriteMapElemKey()
  11708. }
  11709. ee.EncodeInt(int64(int32(k2)))
  11710. if esep {
  11711. ee.WriteMapElemValue()
  11712. }
  11713. ee.EncodeBool(v[int32(k2)])
  11714. }
  11715. } else {
  11716. for k2, v2 := range v {
  11717. if esep {
  11718. ee.WriteMapElemKey()
  11719. }
  11720. ee.EncodeInt(int64(k2))
  11721. if esep {
  11722. ee.WriteMapElemValue()
  11723. }
  11724. ee.EncodeBool(v2)
  11725. }
  11726. }
  11727. ee.WriteMapEnd()
  11728. }
  11729. func (e *Encoder) fastpathEncMapInt64IntfR(f *codecFnInfo, rv reflect.Value) {
  11730. fastpathTV.EncMapInt64IntfV(rv2i(rv).(map[int64]interface{}), e)
  11731. }
  11732. func (_ fastpathT) EncMapInt64IntfV(v map[int64]interface{}, e *Encoder) {
  11733. if v == nil {
  11734. e.e.EncodeNil()
  11735. return
  11736. }
  11737. ee, esep := e.e, e.hh.hasElemSeparators()
  11738. ee.WriteMapStart(len(v))
  11739. if e.h.Canonical {
  11740. v2 := make([]int64, len(v))
  11741. var i int
  11742. for k, _ := range v {
  11743. v2[i] = int64(k)
  11744. i++
  11745. }
  11746. sort.Sort(intSlice(v2))
  11747. for _, k2 := range v2 {
  11748. if esep {
  11749. ee.WriteMapElemKey()
  11750. }
  11751. ee.EncodeInt(int64(int64(k2)))
  11752. if esep {
  11753. ee.WriteMapElemValue()
  11754. }
  11755. e.encode(v[int64(k2)])
  11756. }
  11757. } else {
  11758. for k2, v2 := range v {
  11759. if esep {
  11760. ee.WriteMapElemKey()
  11761. }
  11762. ee.EncodeInt(int64(k2))
  11763. if esep {
  11764. ee.WriteMapElemValue()
  11765. }
  11766. e.encode(v2)
  11767. }
  11768. }
  11769. ee.WriteMapEnd()
  11770. }
  11771. func (e *Encoder) fastpathEncMapInt64StringR(f *codecFnInfo, rv reflect.Value) {
  11772. fastpathTV.EncMapInt64StringV(rv2i(rv).(map[int64]string), e)
  11773. }
  11774. func (_ fastpathT) EncMapInt64StringV(v map[int64]string, e *Encoder) {
  11775. if v == nil {
  11776. e.e.EncodeNil()
  11777. return
  11778. }
  11779. ee, esep := e.e, e.hh.hasElemSeparators()
  11780. ee.WriteMapStart(len(v))
  11781. if e.h.Canonical {
  11782. v2 := make([]int64, len(v))
  11783. var i int
  11784. for k, _ := range v {
  11785. v2[i] = int64(k)
  11786. i++
  11787. }
  11788. sort.Sort(intSlice(v2))
  11789. for _, k2 := range v2 {
  11790. if esep {
  11791. ee.WriteMapElemKey()
  11792. }
  11793. ee.EncodeInt(int64(int64(k2)))
  11794. if esep {
  11795. ee.WriteMapElemValue()
  11796. }
  11797. ee.EncodeString(c_UTF8, v[int64(k2)])
  11798. }
  11799. } else {
  11800. for k2, v2 := range v {
  11801. if esep {
  11802. ee.WriteMapElemKey()
  11803. }
  11804. ee.EncodeInt(int64(k2))
  11805. if esep {
  11806. ee.WriteMapElemValue()
  11807. }
  11808. ee.EncodeString(c_UTF8, v2)
  11809. }
  11810. }
  11811. ee.WriteMapEnd()
  11812. }
  11813. func (e *Encoder) fastpathEncMapInt64UintR(f *codecFnInfo, rv reflect.Value) {
  11814. fastpathTV.EncMapInt64UintV(rv2i(rv).(map[int64]uint), e)
  11815. }
  11816. func (_ fastpathT) EncMapInt64UintV(v map[int64]uint, e *Encoder) {
  11817. if v == nil {
  11818. e.e.EncodeNil()
  11819. return
  11820. }
  11821. ee, esep := e.e, e.hh.hasElemSeparators()
  11822. ee.WriteMapStart(len(v))
  11823. if e.h.Canonical {
  11824. v2 := make([]int64, len(v))
  11825. var i int
  11826. for k, _ := range v {
  11827. v2[i] = int64(k)
  11828. i++
  11829. }
  11830. sort.Sort(intSlice(v2))
  11831. for _, k2 := range v2 {
  11832. if esep {
  11833. ee.WriteMapElemKey()
  11834. }
  11835. ee.EncodeInt(int64(int64(k2)))
  11836. if esep {
  11837. ee.WriteMapElemValue()
  11838. }
  11839. ee.EncodeUint(uint64(v[int64(k2)]))
  11840. }
  11841. } else {
  11842. for k2, v2 := range v {
  11843. if esep {
  11844. ee.WriteMapElemKey()
  11845. }
  11846. ee.EncodeInt(int64(k2))
  11847. if esep {
  11848. ee.WriteMapElemValue()
  11849. }
  11850. ee.EncodeUint(uint64(v2))
  11851. }
  11852. }
  11853. ee.WriteMapEnd()
  11854. }
  11855. func (e *Encoder) fastpathEncMapInt64Uint8R(f *codecFnInfo, rv reflect.Value) {
  11856. fastpathTV.EncMapInt64Uint8V(rv2i(rv).(map[int64]uint8), e)
  11857. }
  11858. func (_ fastpathT) EncMapInt64Uint8V(v map[int64]uint8, e *Encoder) {
  11859. if v == nil {
  11860. e.e.EncodeNil()
  11861. return
  11862. }
  11863. ee, esep := e.e, e.hh.hasElemSeparators()
  11864. ee.WriteMapStart(len(v))
  11865. if e.h.Canonical {
  11866. v2 := make([]int64, len(v))
  11867. var i int
  11868. for k, _ := range v {
  11869. v2[i] = int64(k)
  11870. i++
  11871. }
  11872. sort.Sort(intSlice(v2))
  11873. for _, k2 := range v2 {
  11874. if esep {
  11875. ee.WriteMapElemKey()
  11876. }
  11877. ee.EncodeInt(int64(int64(k2)))
  11878. if esep {
  11879. ee.WriteMapElemValue()
  11880. }
  11881. ee.EncodeUint(uint64(v[int64(k2)]))
  11882. }
  11883. } else {
  11884. for k2, v2 := range v {
  11885. if esep {
  11886. ee.WriteMapElemKey()
  11887. }
  11888. ee.EncodeInt(int64(k2))
  11889. if esep {
  11890. ee.WriteMapElemValue()
  11891. }
  11892. ee.EncodeUint(uint64(v2))
  11893. }
  11894. }
  11895. ee.WriteMapEnd()
  11896. }
  11897. func (e *Encoder) fastpathEncMapInt64Uint16R(f *codecFnInfo, rv reflect.Value) {
  11898. fastpathTV.EncMapInt64Uint16V(rv2i(rv).(map[int64]uint16), e)
  11899. }
  11900. func (_ fastpathT) EncMapInt64Uint16V(v map[int64]uint16, e *Encoder) {
  11901. if v == nil {
  11902. e.e.EncodeNil()
  11903. return
  11904. }
  11905. ee, esep := e.e, e.hh.hasElemSeparators()
  11906. ee.WriteMapStart(len(v))
  11907. if e.h.Canonical {
  11908. v2 := make([]int64, len(v))
  11909. var i int
  11910. for k, _ := range v {
  11911. v2[i] = int64(k)
  11912. i++
  11913. }
  11914. sort.Sort(intSlice(v2))
  11915. for _, k2 := range v2 {
  11916. if esep {
  11917. ee.WriteMapElemKey()
  11918. }
  11919. ee.EncodeInt(int64(int64(k2)))
  11920. if esep {
  11921. ee.WriteMapElemValue()
  11922. }
  11923. ee.EncodeUint(uint64(v[int64(k2)]))
  11924. }
  11925. } else {
  11926. for k2, v2 := range v {
  11927. if esep {
  11928. ee.WriteMapElemKey()
  11929. }
  11930. ee.EncodeInt(int64(k2))
  11931. if esep {
  11932. ee.WriteMapElemValue()
  11933. }
  11934. ee.EncodeUint(uint64(v2))
  11935. }
  11936. }
  11937. ee.WriteMapEnd()
  11938. }
  11939. func (e *Encoder) fastpathEncMapInt64Uint32R(f *codecFnInfo, rv reflect.Value) {
  11940. fastpathTV.EncMapInt64Uint32V(rv2i(rv).(map[int64]uint32), e)
  11941. }
  11942. func (_ fastpathT) EncMapInt64Uint32V(v map[int64]uint32, e *Encoder) {
  11943. if v == nil {
  11944. e.e.EncodeNil()
  11945. return
  11946. }
  11947. ee, esep := e.e, e.hh.hasElemSeparators()
  11948. ee.WriteMapStart(len(v))
  11949. if e.h.Canonical {
  11950. v2 := make([]int64, len(v))
  11951. var i int
  11952. for k, _ := range v {
  11953. v2[i] = int64(k)
  11954. i++
  11955. }
  11956. sort.Sort(intSlice(v2))
  11957. for _, k2 := range v2 {
  11958. if esep {
  11959. ee.WriteMapElemKey()
  11960. }
  11961. ee.EncodeInt(int64(int64(k2)))
  11962. if esep {
  11963. ee.WriteMapElemValue()
  11964. }
  11965. ee.EncodeUint(uint64(v[int64(k2)]))
  11966. }
  11967. } else {
  11968. for k2, v2 := range v {
  11969. if esep {
  11970. ee.WriteMapElemKey()
  11971. }
  11972. ee.EncodeInt(int64(k2))
  11973. if esep {
  11974. ee.WriteMapElemValue()
  11975. }
  11976. ee.EncodeUint(uint64(v2))
  11977. }
  11978. }
  11979. ee.WriteMapEnd()
  11980. }
  11981. func (e *Encoder) fastpathEncMapInt64Uint64R(f *codecFnInfo, rv reflect.Value) {
  11982. fastpathTV.EncMapInt64Uint64V(rv2i(rv).(map[int64]uint64), e)
  11983. }
  11984. func (_ fastpathT) EncMapInt64Uint64V(v map[int64]uint64, e *Encoder) {
  11985. if v == nil {
  11986. e.e.EncodeNil()
  11987. return
  11988. }
  11989. ee, esep := e.e, e.hh.hasElemSeparators()
  11990. ee.WriteMapStart(len(v))
  11991. if e.h.Canonical {
  11992. v2 := make([]int64, len(v))
  11993. var i int
  11994. for k, _ := range v {
  11995. v2[i] = int64(k)
  11996. i++
  11997. }
  11998. sort.Sort(intSlice(v2))
  11999. for _, k2 := range v2 {
  12000. if esep {
  12001. ee.WriteMapElemKey()
  12002. }
  12003. ee.EncodeInt(int64(int64(k2)))
  12004. if esep {
  12005. ee.WriteMapElemValue()
  12006. }
  12007. ee.EncodeUint(uint64(v[int64(k2)]))
  12008. }
  12009. } else {
  12010. for k2, v2 := range v {
  12011. if esep {
  12012. ee.WriteMapElemKey()
  12013. }
  12014. ee.EncodeInt(int64(k2))
  12015. if esep {
  12016. ee.WriteMapElemValue()
  12017. }
  12018. ee.EncodeUint(uint64(v2))
  12019. }
  12020. }
  12021. ee.WriteMapEnd()
  12022. }
  12023. func (e *Encoder) fastpathEncMapInt64UintptrR(f *codecFnInfo, rv reflect.Value) {
  12024. fastpathTV.EncMapInt64UintptrV(rv2i(rv).(map[int64]uintptr), e)
  12025. }
  12026. func (_ fastpathT) EncMapInt64UintptrV(v map[int64]uintptr, e *Encoder) {
  12027. if v == nil {
  12028. e.e.EncodeNil()
  12029. return
  12030. }
  12031. ee, esep := e.e, e.hh.hasElemSeparators()
  12032. ee.WriteMapStart(len(v))
  12033. if e.h.Canonical {
  12034. v2 := make([]int64, len(v))
  12035. var i int
  12036. for k, _ := range v {
  12037. v2[i] = int64(k)
  12038. i++
  12039. }
  12040. sort.Sort(intSlice(v2))
  12041. for _, k2 := range v2 {
  12042. if esep {
  12043. ee.WriteMapElemKey()
  12044. }
  12045. ee.EncodeInt(int64(int64(k2)))
  12046. if esep {
  12047. ee.WriteMapElemValue()
  12048. }
  12049. e.encode(v[int64(k2)])
  12050. }
  12051. } else {
  12052. for k2, v2 := range v {
  12053. if esep {
  12054. ee.WriteMapElemKey()
  12055. }
  12056. ee.EncodeInt(int64(k2))
  12057. if esep {
  12058. ee.WriteMapElemValue()
  12059. }
  12060. e.encode(v2)
  12061. }
  12062. }
  12063. ee.WriteMapEnd()
  12064. }
  12065. func (e *Encoder) fastpathEncMapInt64IntR(f *codecFnInfo, rv reflect.Value) {
  12066. fastpathTV.EncMapInt64IntV(rv2i(rv).(map[int64]int), e)
  12067. }
  12068. func (_ fastpathT) EncMapInt64IntV(v map[int64]int, e *Encoder) {
  12069. if v == nil {
  12070. e.e.EncodeNil()
  12071. return
  12072. }
  12073. ee, esep := e.e, e.hh.hasElemSeparators()
  12074. ee.WriteMapStart(len(v))
  12075. if e.h.Canonical {
  12076. v2 := make([]int64, len(v))
  12077. var i int
  12078. for k, _ := range v {
  12079. v2[i] = int64(k)
  12080. i++
  12081. }
  12082. sort.Sort(intSlice(v2))
  12083. for _, k2 := range v2 {
  12084. if esep {
  12085. ee.WriteMapElemKey()
  12086. }
  12087. ee.EncodeInt(int64(int64(k2)))
  12088. if esep {
  12089. ee.WriteMapElemValue()
  12090. }
  12091. ee.EncodeInt(int64(v[int64(k2)]))
  12092. }
  12093. } else {
  12094. for k2, v2 := range v {
  12095. if esep {
  12096. ee.WriteMapElemKey()
  12097. }
  12098. ee.EncodeInt(int64(k2))
  12099. if esep {
  12100. ee.WriteMapElemValue()
  12101. }
  12102. ee.EncodeInt(int64(v2))
  12103. }
  12104. }
  12105. ee.WriteMapEnd()
  12106. }
  12107. func (e *Encoder) fastpathEncMapInt64Int8R(f *codecFnInfo, rv reflect.Value) {
  12108. fastpathTV.EncMapInt64Int8V(rv2i(rv).(map[int64]int8), e)
  12109. }
  12110. func (_ fastpathT) EncMapInt64Int8V(v map[int64]int8, e *Encoder) {
  12111. if v == nil {
  12112. e.e.EncodeNil()
  12113. return
  12114. }
  12115. ee, esep := e.e, e.hh.hasElemSeparators()
  12116. ee.WriteMapStart(len(v))
  12117. if e.h.Canonical {
  12118. v2 := make([]int64, len(v))
  12119. var i int
  12120. for k, _ := range v {
  12121. v2[i] = int64(k)
  12122. i++
  12123. }
  12124. sort.Sort(intSlice(v2))
  12125. for _, k2 := range v2 {
  12126. if esep {
  12127. ee.WriteMapElemKey()
  12128. }
  12129. ee.EncodeInt(int64(int64(k2)))
  12130. if esep {
  12131. ee.WriteMapElemValue()
  12132. }
  12133. ee.EncodeInt(int64(v[int64(k2)]))
  12134. }
  12135. } else {
  12136. for k2, v2 := range v {
  12137. if esep {
  12138. ee.WriteMapElemKey()
  12139. }
  12140. ee.EncodeInt(int64(k2))
  12141. if esep {
  12142. ee.WriteMapElemValue()
  12143. }
  12144. ee.EncodeInt(int64(v2))
  12145. }
  12146. }
  12147. ee.WriteMapEnd()
  12148. }
  12149. func (e *Encoder) fastpathEncMapInt64Int16R(f *codecFnInfo, rv reflect.Value) {
  12150. fastpathTV.EncMapInt64Int16V(rv2i(rv).(map[int64]int16), e)
  12151. }
  12152. func (_ fastpathT) EncMapInt64Int16V(v map[int64]int16, e *Encoder) {
  12153. if v == nil {
  12154. e.e.EncodeNil()
  12155. return
  12156. }
  12157. ee, esep := e.e, e.hh.hasElemSeparators()
  12158. ee.WriteMapStart(len(v))
  12159. if e.h.Canonical {
  12160. v2 := make([]int64, len(v))
  12161. var i int
  12162. for k, _ := range v {
  12163. v2[i] = int64(k)
  12164. i++
  12165. }
  12166. sort.Sort(intSlice(v2))
  12167. for _, k2 := range v2 {
  12168. if esep {
  12169. ee.WriteMapElemKey()
  12170. }
  12171. ee.EncodeInt(int64(int64(k2)))
  12172. if esep {
  12173. ee.WriteMapElemValue()
  12174. }
  12175. ee.EncodeInt(int64(v[int64(k2)]))
  12176. }
  12177. } else {
  12178. for k2, v2 := range v {
  12179. if esep {
  12180. ee.WriteMapElemKey()
  12181. }
  12182. ee.EncodeInt(int64(k2))
  12183. if esep {
  12184. ee.WriteMapElemValue()
  12185. }
  12186. ee.EncodeInt(int64(v2))
  12187. }
  12188. }
  12189. ee.WriteMapEnd()
  12190. }
  12191. func (e *Encoder) fastpathEncMapInt64Int32R(f *codecFnInfo, rv reflect.Value) {
  12192. fastpathTV.EncMapInt64Int32V(rv2i(rv).(map[int64]int32), e)
  12193. }
  12194. func (_ fastpathT) EncMapInt64Int32V(v map[int64]int32, e *Encoder) {
  12195. if v == nil {
  12196. e.e.EncodeNil()
  12197. return
  12198. }
  12199. ee, esep := e.e, e.hh.hasElemSeparators()
  12200. ee.WriteMapStart(len(v))
  12201. if e.h.Canonical {
  12202. v2 := make([]int64, len(v))
  12203. var i int
  12204. for k, _ := range v {
  12205. v2[i] = int64(k)
  12206. i++
  12207. }
  12208. sort.Sort(intSlice(v2))
  12209. for _, k2 := range v2 {
  12210. if esep {
  12211. ee.WriteMapElemKey()
  12212. }
  12213. ee.EncodeInt(int64(int64(k2)))
  12214. if esep {
  12215. ee.WriteMapElemValue()
  12216. }
  12217. ee.EncodeInt(int64(v[int64(k2)]))
  12218. }
  12219. } else {
  12220. for k2, v2 := range v {
  12221. if esep {
  12222. ee.WriteMapElemKey()
  12223. }
  12224. ee.EncodeInt(int64(k2))
  12225. if esep {
  12226. ee.WriteMapElemValue()
  12227. }
  12228. ee.EncodeInt(int64(v2))
  12229. }
  12230. }
  12231. ee.WriteMapEnd()
  12232. }
  12233. func (e *Encoder) fastpathEncMapInt64Int64R(f *codecFnInfo, rv reflect.Value) {
  12234. fastpathTV.EncMapInt64Int64V(rv2i(rv).(map[int64]int64), e)
  12235. }
  12236. func (_ fastpathT) EncMapInt64Int64V(v map[int64]int64, e *Encoder) {
  12237. if v == nil {
  12238. e.e.EncodeNil()
  12239. return
  12240. }
  12241. ee, esep := e.e, e.hh.hasElemSeparators()
  12242. ee.WriteMapStart(len(v))
  12243. if e.h.Canonical {
  12244. v2 := make([]int64, len(v))
  12245. var i int
  12246. for k, _ := range v {
  12247. v2[i] = int64(k)
  12248. i++
  12249. }
  12250. sort.Sort(intSlice(v2))
  12251. for _, k2 := range v2 {
  12252. if esep {
  12253. ee.WriteMapElemKey()
  12254. }
  12255. ee.EncodeInt(int64(int64(k2)))
  12256. if esep {
  12257. ee.WriteMapElemValue()
  12258. }
  12259. ee.EncodeInt(int64(v[int64(k2)]))
  12260. }
  12261. } else {
  12262. for k2, v2 := range v {
  12263. if esep {
  12264. ee.WriteMapElemKey()
  12265. }
  12266. ee.EncodeInt(int64(k2))
  12267. if esep {
  12268. ee.WriteMapElemValue()
  12269. }
  12270. ee.EncodeInt(int64(v2))
  12271. }
  12272. }
  12273. ee.WriteMapEnd()
  12274. }
  12275. func (e *Encoder) fastpathEncMapInt64Float32R(f *codecFnInfo, rv reflect.Value) {
  12276. fastpathTV.EncMapInt64Float32V(rv2i(rv).(map[int64]float32), e)
  12277. }
  12278. func (_ fastpathT) EncMapInt64Float32V(v map[int64]float32, e *Encoder) {
  12279. if v == nil {
  12280. e.e.EncodeNil()
  12281. return
  12282. }
  12283. ee, esep := e.e, e.hh.hasElemSeparators()
  12284. ee.WriteMapStart(len(v))
  12285. if e.h.Canonical {
  12286. v2 := make([]int64, len(v))
  12287. var i int
  12288. for k, _ := range v {
  12289. v2[i] = int64(k)
  12290. i++
  12291. }
  12292. sort.Sort(intSlice(v2))
  12293. for _, k2 := range v2 {
  12294. if esep {
  12295. ee.WriteMapElemKey()
  12296. }
  12297. ee.EncodeInt(int64(int64(k2)))
  12298. if esep {
  12299. ee.WriteMapElemValue()
  12300. }
  12301. ee.EncodeFloat32(v[int64(k2)])
  12302. }
  12303. } else {
  12304. for k2, v2 := range v {
  12305. if esep {
  12306. ee.WriteMapElemKey()
  12307. }
  12308. ee.EncodeInt(int64(k2))
  12309. if esep {
  12310. ee.WriteMapElemValue()
  12311. }
  12312. ee.EncodeFloat32(v2)
  12313. }
  12314. }
  12315. ee.WriteMapEnd()
  12316. }
  12317. func (e *Encoder) fastpathEncMapInt64Float64R(f *codecFnInfo, rv reflect.Value) {
  12318. fastpathTV.EncMapInt64Float64V(rv2i(rv).(map[int64]float64), e)
  12319. }
  12320. func (_ fastpathT) EncMapInt64Float64V(v map[int64]float64, e *Encoder) {
  12321. if v == nil {
  12322. e.e.EncodeNil()
  12323. return
  12324. }
  12325. ee, esep := e.e, e.hh.hasElemSeparators()
  12326. ee.WriteMapStart(len(v))
  12327. if e.h.Canonical {
  12328. v2 := make([]int64, len(v))
  12329. var i int
  12330. for k, _ := range v {
  12331. v2[i] = int64(k)
  12332. i++
  12333. }
  12334. sort.Sort(intSlice(v2))
  12335. for _, k2 := range v2 {
  12336. if esep {
  12337. ee.WriteMapElemKey()
  12338. }
  12339. ee.EncodeInt(int64(int64(k2)))
  12340. if esep {
  12341. ee.WriteMapElemValue()
  12342. }
  12343. ee.EncodeFloat64(v[int64(k2)])
  12344. }
  12345. } else {
  12346. for k2, v2 := range v {
  12347. if esep {
  12348. ee.WriteMapElemKey()
  12349. }
  12350. ee.EncodeInt(int64(k2))
  12351. if esep {
  12352. ee.WriteMapElemValue()
  12353. }
  12354. ee.EncodeFloat64(v2)
  12355. }
  12356. }
  12357. ee.WriteMapEnd()
  12358. }
  12359. func (e *Encoder) fastpathEncMapInt64BoolR(f *codecFnInfo, rv reflect.Value) {
  12360. fastpathTV.EncMapInt64BoolV(rv2i(rv).(map[int64]bool), e)
  12361. }
  12362. func (_ fastpathT) EncMapInt64BoolV(v map[int64]bool, e *Encoder) {
  12363. if v == nil {
  12364. e.e.EncodeNil()
  12365. return
  12366. }
  12367. ee, esep := e.e, e.hh.hasElemSeparators()
  12368. ee.WriteMapStart(len(v))
  12369. if e.h.Canonical {
  12370. v2 := make([]int64, len(v))
  12371. var i int
  12372. for k, _ := range v {
  12373. v2[i] = int64(k)
  12374. i++
  12375. }
  12376. sort.Sort(intSlice(v2))
  12377. for _, k2 := range v2 {
  12378. if esep {
  12379. ee.WriteMapElemKey()
  12380. }
  12381. ee.EncodeInt(int64(int64(k2)))
  12382. if esep {
  12383. ee.WriteMapElemValue()
  12384. }
  12385. ee.EncodeBool(v[int64(k2)])
  12386. }
  12387. } else {
  12388. for k2, v2 := range v {
  12389. if esep {
  12390. ee.WriteMapElemKey()
  12391. }
  12392. ee.EncodeInt(int64(k2))
  12393. if esep {
  12394. ee.WriteMapElemValue()
  12395. }
  12396. ee.EncodeBool(v2)
  12397. }
  12398. }
  12399. ee.WriteMapEnd()
  12400. }
  12401. func (e *Encoder) fastpathEncMapBoolIntfR(f *codecFnInfo, rv reflect.Value) {
  12402. fastpathTV.EncMapBoolIntfV(rv2i(rv).(map[bool]interface{}), e)
  12403. }
  12404. func (_ fastpathT) EncMapBoolIntfV(v map[bool]interface{}, e *Encoder) {
  12405. if v == nil {
  12406. e.e.EncodeNil()
  12407. return
  12408. }
  12409. ee, esep := e.e, e.hh.hasElemSeparators()
  12410. ee.WriteMapStart(len(v))
  12411. if e.h.Canonical {
  12412. v2 := make([]bool, len(v))
  12413. var i int
  12414. for k, _ := range v {
  12415. v2[i] = bool(k)
  12416. i++
  12417. }
  12418. sort.Sort(boolSlice(v2))
  12419. for _, k2 := range v2 {
  12420. if esep {
  12421. ee.WriteMapElemKey()
  12422. }
  12423. ee.EncodeBool(bool(k2))
  12424. if esep {
  12425. ee.WriteMapElemValue()
  12426. }
  12427. e.encode(v[bool(k2)])
  12428. }
  12429. } else {
  12430. for k2, v2 := range v {
  12431. if esep {
  12432. ee.WriteMapElemKey()
  12433. }
  12434. ee.EncodeBool(k2)
  12435. if esep {
  12436. ee.WriteMapElemValue()
  12437. }
  12438. e.encode(v2)
  12439. }
  12440. }
  12441. ee.WriteMapEnd()
  12442. }
  12443. func (e *Encoder) fastpathEncMapBoolStringR(f *codecFnInfo, rv reflect.Value) {
  12444. fastpathTV.EncMapBoolStringV(rv2i(rv).(map[bool]string), e)
  12445. }
  12446. func (_ fastpathT) EncMapBoolStringV(v map[bool]string, e *Encoder) {
  12447. if v == nil {
  12448. e.e.EncodeNil()
  12449. return
  12450. }
  12451. ee, esep := e.e, e.hh.hasElemSeparators()
  12452. ee.WriteMapStart(len(v))
  12453. if e.h.Canonical {
  12454. v2 := make([]bool, len(v))
  12455. var i int
  12456. for k, _ := range v {
  12457. v2[i] = bool(k)
  12458. i++
  12459. }
  12460. sort.Sort(boolSlice(v2))
  12461. for _, k2 := range v2 {
  12462. if esep {
  12463. ee.WriteMapElemKey()
  12464. }
  12465. ee.EncodeBool(bool(k2))
  12466. if esep {
  12467. ee.WriteMapElemValue()
  12468. }
  12469. ee.EncodeString(c_UTF8, v[bool(k2)])
  12470. }
  12471. } else {
  12472. for k2, v2 := range v {
  12473. if esep {
  12474. ee.WriteMapElemKey()
  12475. }
  12476. ee.EncodeBool(k2)
  12477. if esep {
  12478. ee.WriteMapElemValue()
  12479. }
  12480. ee.EncodeString(c_UTF8, v2)
  12481. }
  12482. }
  12483. ee.WriteMapEnd()
  12484. }
  12485. func (e *Encoder) fastpathEncMapBoolUintR(f *codecFnInfo, rv reflect.Value) {
  12486. fastpathTV.EncMapBoolUintV(rv2i(rv).(map[bool]uint), e)
  12487. }
  12488. func (_ fastpathT) EncMapBoolUintV(v map[bool]uint, e *Encoder) {
  12489. if v == nil {
  12490. e.e.EncodeNil()
  12491. return
  12492. }
  12493. ee, esep := e.e, e.hh.hasElemSeparators()
  12494. ee.WriteMapStart(len(v))
  12495. if e.h.Canonical {
  12496. v2 := make([]bool, len(v))
  12497. var i int
  12498. for k, _ := range v {
  12499. v2[i] = bool(k)
  12500. i++
  12501. }
  12502. sort.Sort(boolSlice(v2))
  12503. for _, k2 := range v2 {
  12504. if esep {
  12505. ee.WriteMapElemKey()
  12506. }
  12507. ee.EncodeBool(bool(k2))
  12508. if esep {
  12509. ee.WriteMapElemValue()
  12510. }
  12511. ee.EncodeUint(uint64(v[bool(k2)]))
  12512. }
  12513. } else {
  12514. for k2, v2 := range v {
  12515. if esep {
  12516. ee.WriteMapElemKey()
  12517. }
  12518. ee.EncodeBool(k2)
  12519. if esep {
  12520. ee.WriteMapElemValue()
  12521. }
  12522. ee.EncodeUint(uint64(v2))
  12523. }
  12524. }
  12525. ee.WriteMapEnd()
  12526. }
  12527. func (e *Encoder) fastpathEncMapBoolUint8R(f *codecFnInfo, rv reflect.Value) {
  12528. fastpathTV.EncMapBoolUint8V(rv2i(rv).(map[bool]uint8), e)
  12529. }
  12530. func (_ fastpathT) EncMapBoolUint8V(v map[bool]uint8, e *Encoder) {
  12531. if v == nil {
  12532. e.e.EncodeNil()
  12533. return
  12534. }
  12535. ee, esep := e.e, e.hh.hasElemSeparators()
  12536. ee.WriteMapStart(len(v))
  12537. if e.h.Canonical {
  12538. v2 := make([]bool, len(v))
  12539. var i int
  12540. for k, _ := range v {
  12541. v2[i] = bool(k)
  12542. i++
  12543. }
  12544. sort.Sort(boolSlice(v2))
  12545. for _, k2 := range v2 {
  12546. if esep {
  12547. ee.WriteMapElemKey()
  12548. }
  12549. ee.EncodeBool(bool(k2))
  12550. if esep {
  12551. ee.WriteMapElemValue()
  12552. }
  12553. ee.EncodeUint(uint64(v[bool(k2)]))
  12554. }
  12555. } else {
  12556. for k2, v2 := range v {
  12557. if esep {
  12558. ee.WriteMapElemKey()
  12559. }
  12560. ee.EncodeBool(k2)
  12561. if esep {
  12562. ee.WriteMapElemValue()
  12563. }
  12564. ee.EncodeUint(uint64(v2))
  12565. }
  12566. }
  12567. ee.WriteMapEnd()
  12568. }
  12569. func (e *Encoder) fastpathEncMapBoolUint16R(f *codecFnInfo, rv reflect.Value) {
  12570. fastpathTV.EncMapBoolUint16V(rv2i(rv).(map[bool]uint16), e)
  12571. }
  12572. func (_ fastpathT) EncMapBoolUint16V(v map[bool]uint16, e *Encoder) {
  12573. if v == nil {
  12574. e.e.EncodeNil()
  12575. return
  12576. }
  12577. ee, esep := e.e, e.hh.hasElemSeparators()
  12578. ee.WriteMapStart(len(v))
  12579. if e.h.Canonical {
  12580. v2 := make([]bool, len(v))
  12581. var i int
  12582. for k, _ := range v {
  12583. v2[i] = bool(k)
  12584. i++
  12585. }
  12586. sort.Sort(boolSlice(v2))
  12587. for _, k2 := range v2 {
  12588. if esep {
  12589. ee.WriteMapElemKey()
  12590. }
  12591. ee.EncodeBool(bool(k2))
  12592. if esep {
  12593. ee.WriteMapElemValue()
  12594. }
  12595. ee.EncodeUint(uint64(v[bool(k2)]))
  12596. }
  12597. } else {
  12598. for k2, v2 := range v {
  12599. if esep {
  12600. ee.WriteMapElemKey()
  12601. }
  12602. ee.EncodeBool(k2)
  12603. if esep {
  12604. ee.WriteMapElemValue()
  12605. }
  12606. ee.EncodeUint(uint64(v2))
  12607. }
  12608. }
  12609. ee.WriteMapEnd()
  12610. }
  12611. func (e *Encoder) fastpathEncMapBoolUint32R(f *codecFnInfo, rv reflect.Value) {
  12612. fastpathTV.EncMapBoolUint32V(rv2i(rv).(map[bool]uint32), e)
  12613. }
  12614. func (_ fastpathT) EncMapBoolUint32V(v map[bool]uint32, e *Encoder) {
  12615. if v == nil {
  12616. e.e.EncodeNil()
  12617. return
  12618. }
  12619. ee, esep := e.e, e.hh.hasElemSeparators()
  12620. ee.WriteMapStart(len(v))
  12621. if e.h.Canonical {
  12622. v2 := make([]bool, len(v))
  12623. var i int
  12624. for k, _ := range v {
  12625. v2[i] = bool(k)
  12626. i++
  12627. }
  12628. sort.Sort(boolSlice(v2))
  12629. for _, k2 := range v2 {
  12630. if esep {
  12631. ee.WriteMapElemKey()
  12632. }
  12633. ee.EncodeBool(bool(k2))
  12634. if esep {
  12635. ee.WriteMapElemValue()
  12636. }
  12637. ee.EncodeUint(uint64(v[bool(k2)]))
  12638. }
  12639. } else {
  12640. for k2, v2 := range v {
  12641. if esep {
  12642. ee.WriteMapElemKey()
  12643. }
  12644. ee.EncodeBool(k2)
  12645. if esep {
  12646. ee.WriteMapElemValue()
  12647. }
  12648. ee.EncodeUint(uint64(v2))
  12649. }
  12650. }
  12651. ee.WriteMapEnd()
  12652. }
  12653. func (e *Encoder) fastpathEncMapBoolUint64R(f *codecFnInfo, rv reflect.Value) {
  12654. fastpathTV.EncMapBoolUint64V(rv2i(rv).(map[bool]uint64), e)
  12655. }
  12656. func (_ fastpathT) EncMapBoolUint64V(v map[bool]uint64, e *Encoder) {
  12657. if v == nil {
  12658. e.e.EncodeNil()
  12659. return
  12660. }
  12661. ee, esep := e.e, e.hh.hasElemSeparators()
  12662. ee.WriteMapStart(len(v))
  12663. if e.h.Canonical {
  12664. v2 := make([]bool, len(v))
  12665. var i int
  12666. for k, _ := range v {
  12667. v2[i] = bool(k)
  12668. i++
  12669. }
  12670. sort.Sort(boolSlice(v2))
  12671. for _, k2 := range v2 {
  12672. if esep {
  12673. ee.WriteMapElemKey()
  12674. }
  12675. ee.EncodeBool(bool(k2))
  12676. if esep {
  12677. ee.WriteMapElemValue()
  12678. }
  12679. ee.EncodeUint(uint64(v[bool(k2)]))
  12680. }
  12681. } else {
  12682. for k2, v2 := range v {
  12683. if esep {
  12684. ee.WriteMapElemKey()
  12685. }
  12686. ee.EncodeBool(k2)
  12687. if esep {
  12688. ee.WriteMapElemValue()
  12689. }
  12690. ee.EncodeUint(uint64(v2))
  12691. }
  12692. }
  12693. ee.WriteMapEnd()
  12694. }
  12695. func (e *Encoder) fastpathEncMapBoolUintptrR(f *codecFnInfo, rv reflect.Value) {
  12696. fastpathTV.EncMapBoolUintptrV(rv2i(rv).(map[bool]uintptr), e)
  12697. }
  12698. func (_ fastpathT) EncMapBoolUintptrV(v map[bool]uintptr, e *Encoder) {
  12699. if v == nil {
  12700. e.e.EncodeNil()
  12701. return
  12702. }
  12703. ee, esep := e.e, e.hh.hasElemSeparators()
  12704. ee.WriteMapStart(len(v))
  12705. if e.h.Canonical {
  12706. v2 := make([]bool, len(v))
  12707. var i int
  12708. for k, _ := range v {
  12709. v2[i] = bool(k)
  12710. i++
  12711. }
  12712. sort.Sort(boolSlice(v2))
  12713. for _, k2 := range v2 {
  12714. if esep {
  12715. ee.WriteMapElemKey()
  12716. }
  12717. ee.EncodeBool(bool(k2))
  12718. if esep {
  12719. ee.WriteMapElemValue()
  12720. }
  12721. e.encode(v[bool(k2)])
  12722. }
  12723. } else {
  12724. for k2, v2 := range v {
  12725. if esep {
  12726. ee.WriteMapElemKey()
  12727. }
  12728. ee.EncodeBool(k2)
  12729. if esep {
  12730. ee.WriteMapElemValue()
  12731. }
  12732. e.encode(v2)
  12733. }
  12734. }
  12735. ee.WriteMapEnd()
  12736. }
  12737. func (e *Encoder) fastpathEncMapBoolIntR(f *codecFnInfo, rv reflect.Value) {
  12738. fastpathTV.EncMapBoolIntV(rv2i(rv).(map[bool]int), e)
  12739. }
  12740. func (_ fastpathT) EncMapBoolIntV(v map[bool]int, e *Encoder) {
  12741. if v == nil {
  12742. e.e.EncodeNil()
  12743. return
  12744. }
  12745. ee, esep := e.e, e.hh.hasElemSeparators()
  12746. ee.WriteMapStart(len(v))
  12747. if e.h.Canonical {
  12748. v2 := make([]bool, len(v))
  12749. var i int
  12750. for k, _ := range v {
  12751. v2[i] = bool(k)
  12752. i++
  12753. }
  12754. sort.Sort(boolSlice(v2))
  12755. for _, k2 := range v2 {
  12756. if esep {
  12757. ee.WriteMapElemKey()
  12758. }
  12759. ee.EncodeBool(bool(k2))
  12760. if esep {
  12761. ee.WriteMapElemValue()
  12762. }
  12763. ee.EncodeInt(int64(v[bool(k2)]))
  12764. }
  12765. } else {
  12766. for k2, v2 := range v {
  12767. if esep {
  12768. ee.WriteMapElemKey()
  12769. }
  12770. ee.EncodeBool(k2)
  12771. if esep {
  12772. ee.WriteMapElemValue()
  12773. }
  12774. ee.EncodeInt(int64(v2))
  12775. }
  12776. }
  12777. ee.WriteMapEnd()
  12778. }
  12779. func (e *Encoder) fastpathEncMapBoolInt8R(f *codecFnInfo, rv reflect.Value) {
  12780. fastpathTV.EncMapBoolInt8V(rv2i(rv).(map[bool]int8), e)
  12781. }
  12782. func (_ fastpathT) EncMapBoolInt8V(v map[bool]int8, e *Encoder) {
  12783. if v == nil {
  12784. e.e.EncodeNil()
  12785. return
  12786. }
  12787. ee, esep := e.e, e.hh.hasElemSeparators()
  12788. ee.WriteMapStart(len(v))
  12789. if e.h.Canonical {
  12790. v2 := make([]bool, len(v))
  12791. var i int
  12792. for k, _ := range v {
  12793. v2[i] = bool(k)
  12794. i++
  12795. }
  12796. sort.Sort(boolSlice(v2))
  12797. for _, k2 := range v2 {
  12798. if esep {
  12799. ee.WriteMapElemKey()
  12800. }
  12801. ee.EncodeBool(bool(k2))
  12802. if esep {
  12803. ee.WriteMapElemValue()
  12804. }
  12805. ee.EncodeInt(int64(v[bool(k2)]))
  12806. }
  12807. } else {
  12808. for k2, v2 := range v {
  12809. if esep {
  12810. ee.WriteMapElemKey()
  12811. }
  12812. ee.EncodeBool(k2)
  12813. if esep {
  12814. ee.WriteMapElemValue()
  12815. }
  12816. ee.EncodeInt(int64(v2))
  12817. }
  12818. }
  12819. ee.WriteMapEnd()
  12820. }
  12821. func (e *Encoder) fastpathEncMapBoolInt16R(f *codecFnInfo, rv reflect.Value) {
  12822. fastpathTV.EncMapBoolInt16V(rv2i(rv).(map[bool]int16), e)
  12823. }
  12824. func (_ fastpathT) EncMapBoolInt16V(v map[bool]int16, e *Encoder) {
  12825. if v == nil {
  12826. e.e.EncodeNil()
  12827. return
  12828. }
  12829. ee, esep := e.e, e.hh.hasElemSeparators()
  12830. ee.WriteMapStart(len(v))
  12831. if e.h.Canonical {
  12832. v2 := make([]bool, len(v))
  12833. var i int
  12834. for k, _ := range v {
  12835. v2[i] = bool(k)
  12836. i++
  12837. }
  12838. sort.Sort(boolSlice(v2))
  12839. for _, k2 := range v2 {
  12840. if esep {
  12841. ee.WriteMapElemKey()
  12842. }
  12843. ee.EncodeBool(bool(k2))
  12844. if esep {
  12845. ee.WriteMapElemValue()
  12846. }
  12847. ee.EncodeInt(int64(v[bool(k2)]))
  12848. }
  12849. } else {
  12850. for k2, v2 := range v {
  12851. if esep {
  12852. ee.WriteMapElemKey()
  12853. }
  12854. ee.EncodeBool(k2)
  12855. if esep {
  12856. ee.WriteMapElemValue()
  12857. }
  12858. ee.EncodeInt(int64(v2))
  12859. }
  12860. }
  12861. ee.WriteMapEnd()
  12862. }
  12863. func (e *Encoder) fastpathEncMapBoolInt32R(f *codecFnInfo, rv reflect.Value) {
  12864. fastpathTV.EncMapBoolInt32V(rv2i(rv).(map[bool]int32), e)
  12865. }
  12866. func (_ fastpathT) EncMapBoolInt32V(v map[bool]int32, e *Encoder) {
  12867. if v == nil {
  12868. e.e.EncodeNil()
  12869. return
  12870. }
  12871. ee, esep := e.e, e.hh.hasElemSeparators()
  12872. ee.WriteMapStart(len(v))
  12873. if e.h.Canonical {
  12874. v2 := make([]bool, len(v))
  12875. var i int
  12876. for k, _ := range v {
  12877. v2[i] = bool(k)
  12878. i++
  12879. }
  12880. sort.Sort(boolSlice(v2))
  12881. for _, k2 := range v2 {
  12882. if esep {
  12883. ee.WriteMapElemKey()
  12884. }
  12885. ee.EncodeBool(bool(k2))
  12886. if esep {
  12887. ee.WriteMapElemValue()
  12888. }
  12889. ee.EncodeInt(int64(v[bool(k2)]))
  12890. }
  12891. } else {
  12892. for k2, v2 := range v {
  12893. if esep {
  12894. ee.WriteMapElemKey()
  12895. }
  12896. ee.EncodeBool(k2)
  12897. if esep {
  12898. ee.WriteMapElemValue()
  12899. }
  12900. ee.EncodeInt(int64(v2))
  12901. }
  12902. }
  12903. ee.WriteMapEnd()
  12904. }
  12905. func (e *Encoder) fastpathEncMapBoolInt64R(f *codecFnInfo, rv reflect.Value) {
  12906. fastpathTV.EncMapBoolInt64V(rv2i(rv).(map[bool]int64), e)
  12907. }
  12908. func (_ fastpathT) EncMapBoolInt64V(v map[bool]int64, e *Encoder) {
  12909. if v == nil {
  12910. e.e.EncodeNil()
  12911. return
  12912. }
  12913. ee, esep := e.e, e.hh.hasElemSeparators()
  12914. ee.WriteMapStart(len(v))
  12915. if e.h.Canonical {
  12916. v2 := make([]bool, len(v))
  12917. var i int
  12918. for k, _ := range v {
  12919. v2[i] = bool(k)
  12920. i++
  12921. }
  12922. sort.Sort(boolSlice(v2))
  12923. for _, k2 := range v2 {
  12924. if esep {
  12925. ee.WriteMapElemKey()
  12926. }
  12927. ee.EncodeBool(bool(k2))
  12928. if esep {
  12929. ee.WriteMapElemValue()
  12930. }
  12931. ee.EncodeInt(int64(v[bool(k2)]))
  12932. }
  12933. } else {
  12934. for k2, v2 := range v {
  12935. if esep {
  12936. ee.WriteMapElemKey()
  12937. }
  12938. ee.EncodeBool(k2)
  12939. if esep {
  12940. ee.WriteMapElemValue()
  12941. }
  12942. ee.EncodeInt(int64(v2))
  12943. }
  12944. }
  12945. ee.WriteMapEnd()
  12946. }
  12947. func (e *Encoder) fastpathEncMapBoolFloat32R(f *codecFnInfo, rv reflect.Value) {
  12948. fastpathTV.EncMapBoolFloat32V(rv2i(rv).(map[bool]float32), e)
  12949. }
  12950. func (_ fastpathT) EncMapBoolFloat32V(v map[bool]float32, e *Encoder) {
  12951. if v == nil {
  12952. e.e.EncodeNil()
  12953. return
  12954. }
  12955. ee, esep := e.e, e.hh.hasElemSeparators()
  12956. ee.WriteMapStart(len(v))
  12957. if e.h.Canonical {
  12958. v2 := make([]bool, len(v))
  12959. var i int
  12960. for k, _ := range v {
  12961. v2[i] = bool(k)
  12962. i++
  12963. }
  12964. sort.Sort(boolSlice(v2))
  12965. for _, k2 := range v2 {
  12966. if esep {
  12967. ee.WriteMapElemKey()
  12968. }
  12969. ee.EncodeBool(bool(k2))
  12970. if esep {
  12971. ee.WriteMapElemValue()
  12972. }
  12973. ee.EncodeFloat32(v[bool(k2)])
  12974. }
  12975. } else {
  12976. for k2, v2 := range v {
  12977. if esep {
  12978. ee.WriteMapElemKey()
  12979. }
  12980. ee.EncodeBool(k2)
  12981. if esep {
  12982. ee.WriteMapElemValue()
  12983. }
  12984. ee.EncodeFloat32(v2)
  12985. }
  12986. }
  12987. ee.WriteMapEnd()
  12988. }
  12989. func (e *Encoder) fastpathEncMapBoolFloat64R(f *codecFnInfo, rv reflect.Value) {
  12990. fastpathTV.EncMapBoolFloat64V(rv2i(rv).(map[bool]float64), e)
  12991. }
  12992. func (_ fastpathT) EncMapBoolFloat64V(v map[bool]float64, e *Encoder) {
  12993. if v == nil {
  12994. e.e.EncodeNil()
  12995. return
  12996. }
  12997. ee, esep := e.e, e.hh.hasElemSeparators()
  12998. ee.WriteMapStart(len(v))
  12999. if e.h.Canonical {
  13000. v2 := make([]bool, len(v))
  13001. var i int
  13002. for k, _ := range v {
  13003. v2[i] = bool(k)
  13004. i++
  13005. }
  13006. sort.Sort(boolSlice(v2))
  13007. for _, k2 := range v2 {
  13008. if esep {
  13009. ee.WriteMapElemKey()
  13010. }
  13011. ee.EncodeBool(bool(k2))
  13012. if esep {
  13013. ee.WriteMapElemValue()
  13014. }
  13015. ee.EncodeFloat64(v[bool(k2)])
  13016. }
  13017. } else {
  13018. for k2, v2 := range v {
  13019. if esep {
  13020. ee.WriteMapElemKey()
  13021. }
  13022. ee.EncodeBool(k2)
  13023. if esep {
  13024. ee.WriteMapElemValue()
  13025. }
  13026. ee.EncodeFloat64(v2)
  13027. }
  13028. }
  13029. ee.WriteMapEnd()
  13030. }
  13031. func (e *Encoder) fastpathEncMapBoolBoolR(f *codecFnInfo, rv reflect.Value) {
  13032. fastpathTV.EncMapBoolBoolV(rv2i(rv).(map[bool]bool), e)
  13033. }
  13034. func (_ fastpathT) EncMapBoolBoolV(v map[bool]bool, e *Encoder) {
  13035. if v == nil {
  13036. e.e.EncodeNil()
  13037. return
  13038. }
  13039. ee, esep := e.e, e.hh.hasElemSeparators()
  13040. ee.WriteMapStart(len(v))
  13041. if e.h.Canonical {
  13042. v2 := make([]bool, len(v))
  13043. var i int
  13044. for k, _ := range v {
  13045. v2[i] = bool(k)
  13046. i++
  13047. }
  13048. sort.Sort(boolSlice(v2))
  13049. for _, k2 := range v2 {
  13050. if esep {
  13051. ee.WriteMapElemKey()
  13052. }
  13053. ee.EncodeBool(bool(k2))
  13054. if esep {
  13055. ee.WriteMapElemValue()
  13056. }
  13057. ee.EncodeBool(v[bool(k2)])
  13058. }
  13059. } else {
  13060. for k2, v2 := range v {
  13061. if esep {
  13062. ee.WriteMapElemKey()
  13063. }
  13064. ee.EncodeBool(k2)
  13065. if esep {
  13066. ee.WriteMapElemValue()
  13067. }
  13068. ee.EncodeBool(v2)
  13069. }
  13070. }
  13071. ee.WriteMapEnd()
  13072. }
  13073. // -- decode
  13074. // -- -- fast path type switch
  13075. func fastpathDecodeTypeSwitch(iv interface{}, d *Decoder) bool {
  13076. switch v := iv.(type) {
  13077. case []interface{}:
  13078. fastpathTV.DecSliceIntfV(v, false, d)
  13079. case *[]interface{}:
  13080. if v2, changed2 := fastpathTV.DecSliceIntfV(*v, true, d); changed2 {
  13081. *v = v2
  13082. }
  13083. case map[interface{}]interface{}:
  13084. fastpathTV.DecMapIntfIntfV(v, false, d)
  13085. case *map[interface{}]interface{}:
  13086. if v2, changed2 := fastpathTV.DecMapIntfIntfV(*v, true, d); changed2 {
  13087. *v = v2
  13088. }
  13089. case map[interface{}]string:
  13090. fastpathTV.DecMapIntfStringV(v, false, d)
  13091. case *map[interface{}]string:
  13092. if v2, changed2 := fastpathTV.DecMapIntfStringV(*v, true, d); changed2 {
  13093. *v = v2
  13094. }
  13095. case map[interface{}]uint:
  13096. fastpathTV.DecMapIntfUintV(v, false, d)
  13097. case *map[interface{}]uint:
  13098. if v2, changed2 := fastpathTV.DecMapIntfUintV(*v, true, d); changed2 {
  13099. *v = v2
  13100. }
  13101. case map[interface{}]uint8:
  13102. fastpathTV.DecMapIntfUint8V(v, false, d)
  13103. case *map[interface{}]uint8:
  13104. if v2, changed2 := fastpathTV.DecMapIntfUint8V(*v, true, d); changed2 {
  13105. *v = v2
  13106. }
  13107. case map[interface{}]uint16:
  13108. fastpathTV.DecMapIntfUint16V(v, false, d)
  13109. case *map[interface{}]uint16:
  13110. if v2, changed2 := fastpathTV.DecMapIntfUint16V(*v, true, d); changed2 {
  13111. *v = v2
  13112. }
  13113. case map[interface{}]uint32:
  13114. fastpathTV.DecMapIntfUint32V(v, false, d)
  13115. case *map[interface{}]uint32:
  13116. if v2, changed2 := fastpathTV.DecMapIntfUint32V(*v, true, d); changed2 {
  13117. *v = v2
  13118. }
  13119. case map[interface{}]uint64:
  13120. fastpathTV.DecMapIntfUint64V(v, false, d)
  13121. case *map[interface{}]uint64:
  13122. if v2, changed2 := fastpathTV.DecMapIntfUint64V(*v, true, d); changed2 {
  13123. *v = v2
  13124. }
  13125. case map[interface{}]uintptr:
  13126. fastpathTV.DecMapIntfUintptrV(v, false, d)
  13127. case *map[interface{}]uintptr:
  13128. if v2, changed2 := fastpathTV.DecMapIntfUintptrV(*v, true, d); changed2 {
  13129. *v = v2
  13130. }
  13131. case map[interface{}]int:
  13132. fastpathTV.DecMapIntfIntV(v, false, d)
  13133. case *map[interface{}]int:
  13134. if v2, changed2 := fastpathTV.DecMapIntfIntV(*v, true, d); changed2 {
  13135. *v = v2
  13136. }
  13137. case map[interface{}]int8:
  13138. fastpathTV.DecMapIntfInt8V(v, false, d)
  13139. case *map[interface{}]int8:
  13140. if v2, changed2 := fastpathTV.DecMapIntfInt8V(*v, true, d); changed2 {
  13141. *v = v2
  13142. }
  13143. case map[interface{}]int16:
  13144. fastpathTV.DecMapIntfInt16V(v, false, d)
  13145. case *map[interface{}]int16:
  13146. if v2, changed2 := fastpathTV.DecMapIntfInt16V(*v, true, d); changed2 {
  13147. *v = v2
  13148. }
  13149. case map[interface{}]int32:
  13150. fastpathTV.DecMapIntfInt32V(v, false, d)
  13151. case *map[interface{}]int32:
  13152. if v2, changed2 := fastpathTV.DecMapIntfInt32V(*v, true, d); changed2 {
  13153. *v = v2
  13154. }
  13155. case map[interface{}]int64:
  13156. fastpathTV.DecMapIntfInt64V(v, false, d)
  13157. case *map[interface{}]int64:
  13158. if v2, changed2 := fastpathTV.DecMapIntfInt64V(*v, true, d); changed2 {
  13159. *v = v2
  13160. }
  13161. case map[interface{}]float32:
  13162. fastpathTV.DecMapIntfFloat32V(v, false, d)
  13163. case *map[interface{}]float32:
  13164. if v2, changed2 := fastpathTV.DecMapIntfFloat32V(*v, true, d); changed2 {
  13165. *v = v2
  13166. }
  13167. case map[interface{}]float64:
  13168. fastpathTV.DecMapIntfFloat64V(v, false, d)
  13169. case *map[interface{}]float64:
  13170. if v2, changed2 := fastpathTV.DecMapIntfFloat64V(*v, true, d); changed2 {
  13171. *v = v2
  13172. }
  13173. case map[interface{}]bool:
  13174. fastpathTV.DecMapIntfBoolV(v, false, d)
  13175. case *map[interface{}]bool:
  13176. if v2, changed2 := fastpathTV.DecMapIntfBoolV(*v, true, d); changed2 {
  13177. *v = v2
  13178. }
  13179. case []string:
  13180. fastpathTV.DecSliceStringV(v, false, d)
  13181. case *[]string:
  13182. if v2, changed2 := fastpathTV.DecSliceStringV(*v, true, d); changed2 {
  13183. *v = v2
  13184. }
  13185. case map[string]interface{}:
  13186. fastpathTV.DecMapStringIntfV(v, false, d)
  13187. case *map[string]interface{}:
  13188. if v2, changed2 := fastpathTV.DecMapStringIntfV(*v, true, d); changed2 {
  13189. *v = v2
  13190. }
  13191. case map[string]string:
  13192. fastpathTV.DecMapStringStringV(v, false, d)
  13193. case *map[string]string:
  13194. if v2, changed2 := fastpathTV.DecMapStringStringV(*v, true, d); changed2 {
  13195. *v = v2
  13196. }
  13197. case map[string]uint:
  13198. fastpathTV.DecMapStringUintV(v, false, d)
  13199. case *map[string]uint:
  13200. if v2, changed2 := fastpathTV.DecMapStringUintV(*v, true, d); changed2 {
  13201. *v = v2
  13202. }
  13203. case map[string]uint8:
  13204. fastpathTV.DecMapStringUint8V(v, false, d)
  13205. case *map[string]uint8:
  13206. if v2, changed2 := fastpathTV.DecMapStringUint8V(*v, true, d); changed2 {
  13207. *v = v2
  13208. }
  13209. case map[string]uint16:
  13210. fastpathTV.DecMapStringUint16V(v, false, d)
  13211. case *map[string]uint16:
  13212. if v2, changed2 := fastpathTV.DecMapStringUint16V(*v, true, d); changed2 {
  13213. *v = v2
  13214. }
  13215. case map[string]uint32:
  13216. fastpathTV.DecMapStringUint32V(v, false, d)
  13217. case *map[string]uint32:
  13218. if v2, changed2 := fastpathTV.DecMapStringUint32V(*v, true, d); changed2 {
  13219. *v = v2
  13220. }
  13221. case map[string]uint64:
  13222. fastpathTV.DecMapStringUint64V(v, false, d)
  13223. case *map[string]uint64:
  13224. if v2, changed2 := fastpathTV.DecMapStringUint64V(*v, true, d); changed2 {
  13225. *v = v2
  13226. }
  13227. case map[string]uintptr:
  13228. fastpathTV.DecMapStringUintptrV(v, false, d)
  13229. case *map[string]uintptr:
  13230. if v2, changed2 := fastpathTV.DecMapStringUintptrV(*v, true, d); changed2 {
  13231. *v = v2
  13232. }
  13233. case map[string]int:
  13234. fastpathTV.DecMapStringIntV(v, false, d)
  13235. case *map[string]int:
  13236. if v2, changed2 := fastpathTV.DecMapStringIntV(*v, true, d); changed2 {
  13237. *v = v2
  13238. }
  13239. case map[string]int8:
  13240. fastpathTV.DecMapStringInt8V(v, false, d)
  13241. case *map[string]int8:
  13242. if v2, changed2 := fastpathTV.DecMapStringInt8V(*v, true, d); changed2 {
  13243. *v = v2
  13244. }
  13245. case map[string]int16:
  13246. fastpathTV.DecMapStringInt16V(v, false, d)
  13247. case *map[string]int16:
  13248. if v2, changed2 := fastpathTV.DecMapStringInt16V(*v, true, d); changed2 {
  13249. *v = v2
  13250. }
  13251. case map[string]int32:
  13252. fastpathTV.DecMapStringInt32V(v, false, d)
  13253. case *map[string]int32:
  13254. if v2, changed2 := fastpathTV.DecMapStringInt32V(*v, true, d); changed2 {
  13255. *v = v2
  13256. }
  13257. case map[string]int64:
  13258. fastpathTV.DecMapStringInt64V(v, false, d)
  13259. case *map[string]int64:
  13260. if v2, changed2 := fastpathTV.DecMapStringInt64V(*v, true, d); changed2 {
  13261. *v = v2
  13262. }
  13263. case map[string]float32:
  13264. fastpathTV.DecMapStringFloat32V(v, false, d)
  13265. case *map[string]float32:
  13266. if v2, changed2 := fastpathTV.DecMapStringFloat32V(*v, true, d); changed2 {
  13267. *v = v2
  13268. }
  13269. case map[string]float64:
  13270. fastpathTV.DecMapStringFloat64V(v, false, d)
  13271. case *map[string]float64:
  13272. if v2, changed2 := fastpathTV.DecMapStringFloat64V(*v, true, d); changed2 {
  13273. *v = v2
  13274. }
  13275. case map[string]bool:
  13276. fastpathTV.DecMapStringBoolV(v, false, d)
  13277. case *map[string]bool:
  13278. if v2, changed2 := fastpathTV.DecMapStringBoolV(*v, true, d); changed2 {
  13279. *v = v2
  13280. }
  13281. case []float32:
  13282. fastpathTV.DecSliceFloat32V(v, false, d)
  13283. case *[]float32:
  13284. if v2, changed2 := fastpathTV.DecSliceFloat32V(*v, true, d); changed2 {
  13285. *v = v2
  13286. }
  13287. case map[float32]interface{}:
  13288. fastpathTV.DecMapFloat32IntfV(v, false, d)
  13289. case *map[float32]interface{}:
  13290. if v2, changed2 := fastpathTV.DecMapFloat32IntfV(*v, true, d); changed2 {
  13291. *v = v2
  13292. }
  13293. case map[float32]string:
  13294. fastpathTV.DecMapFloat32StringV(v, false, d)
  13295. case *map[float32]string:
  13296. if v2, changed2 := fastpathTV.DecMapFloat32StringV(*v, true, d); changed2 {
  13297. *v = v2
  13298. }
  13299. case map[float32]uint:
  13300. fastpathTV.DecMapFloat32UintV(v, false, d)
  13301. case *map[float32]uint:
  13302. if v2, changed2 := fastpathTV.DecMapFloat32UintV(*v, true, d); changed2 {
  13303. *v = v2
  13304. }
  13305. case map[float32]uint8:
  13306. fastpathTV.DecMapFloat32Uint8V(v, false, d)
  13307. case *map[float32]uint8:
  13308. if v2, changed2 := fastpathTV.DecMapFloat32Uint8V(*v, true, d); changed2 {
  13309. *v = v2
  13310. }
  13311. case map[float32]uint16:
  13312. fastpathTV.DecMapFloat32Uint16V(v, false, d)
  13313. case *map[float32]uint16:
  13314. if v2, changed2 := fastpathTV.DecMapFloat32Uint16V(*v, true, d); changed2 {
  13315. *v = v2
  13316. }
  13317. case map[float32]uint32:
  13318. fastpathTV.DecMapFloat32Uint32V(v, false, d)
  13319. case *map[float32]uint32:
  13320. if v2, changed2 := fastpathTV.DecMapFloat32Uint32V(*v, true, d); changed2 {
  13321. *v = v2
  13322. }
  13323. case map[float32]uint64:
  13324. fastpathTV.DecMapFloat32Uint64V(v, false, d)
  13325. case *map[float32]uint64:
  13326. if v2, changed2 := fastpathTV.DecMapFloat32Uint64V(*v, true, d); changed2 {
  13327. *v = v2
  13328. }
  13329. case map[float32]uintptr:
  13330. fastpathTV.DecMapFloat32UintptrV(v, false, d)
  13331. case *map[float32]uintptr:
  13332. if v2, changed2 := fastpathTV.DecMapFloat32UintptrV(*v, true, d); changed2 {
  13333. *v = v2
  13334. }
  13335. case map[float32]int:
  13336. fastpathTV.DecMapFloat32IntV(v, false, d)
  13337. case *map[float32]int:
  13338. if v2, changed2 := fastpathTV.DecMapFloat32IntV(*v, true, d); changed2 {
  13339. *v = v2
  13340. }
  13341. case map[float32]int8:
  13342. fastpathTV.DecMapFloat32Int8V(v, false, d)
  13343. case *map[float32]int8:
  13344. if v2, changed2 := fastpathTV.DecMapFloat32Int8V(*v, true, d); changed2 {
  13345. *v = v2
  13346. }
  13347. case map[float32]int16:
  13348. fastpathTV.DecMapFloat32Int16V(v, false, d)
  13349. case *map[float32]int16:
  13350. if v2, changed2 := fastpathTV.DecMapFloat32Int16V(*v, true, d); changed2 {
  13351. *v = v2
  13352. }
  13353. case map[float32]int32:
  13354. fastpathTV.DecMapFloat32Int32V(v, false, d)
  13355. case *map[float32]int32:
  13356. if v2, changed2 := fastpathTV.DecMapFloat32Int32V(*v, true, d); changed2 {
  13357. *v = v2
  13358. }
  13359. case map[float32]int64:
  13360. fastpathTV.DecMapFloat32Int64V(v, false, d)
  13361. case *map[float32]int64:
  13362. if v2, changed2 := fastpathTV.DecMapFloat32Int64V(*v, true, d); changed2 {
  13363. *v = v2
  13364. }
  13365. case map[float32]float32:
  13366. fastpathTV.DecMapFloat32Float32V(v, false, d)
  13367. case *map[float32]float32:
  13368. if v2, changed2 := fastpathTV.DecMapFloat32Float32V(*v, true, d); changed2 {
  13369. *v = v2
  13370. }
  13371. case map[float32]float64:
  13372. fastpathTV.DecMapFloat32Float64V(v, false, d)
  13373. case *map[float32]float64:
  13374. if v2, changed2 := fastpathTV.DecMapFloat32Float64V(*v, true, d); changed2 {
  13375. *v = v2
  13376. }
  13377. case map[float32]bool:
  13378. fastpathTV.DecMapFloat32BoolV(v, false, d)
  13379. case *map[float32]bool:
  13380. if v2, changed2 := fastpathTV.DecMapFloat32BoolV(*v, true, d); changed2 {
  13381. *v = v2
  13382. }
  13383. case []float64:
  13384. fastpathTV.DecSliceFloat64V(v, false, d)
  13385. case *[]float64:
  13386. if v2, changed2 := fastpathTV.DecSliceFloat64V(*v, true, d); changed2 {
  13387. *v = v2
  13388. }
  13389. case map[float64]interface{}:
  13390. fastpathTV.DecMapFloat64IntfV(v, false, d)
  13391. case *map[float64]interface{}:
  13392. if v2, changed2 := fastpathTV.DecMapFloat64IntfV(*v, true, d); changed2 {
  13393. *v = v2
  13394. }
  13395. case map[float64]string:
  13396. fastpathTV.DecMapFloat64StringV(v, false, d)
  13397. case *map[float64]string:
  13398. if v2, changed2 := fastpathTV.DecMapFloat64StringV(*v, true, d); changed2 {
  13399. *v = v2
  13400. }
  13401. case map[float64]uint:
  13402. fastpathTV.DecMapFloat64UintV(v, false, d)
  13403. case *map[float64]uint:
  13404. if v2, changed2 := fastpathTV.DecMapFloat64UintV(*v, true, d); changed2 {
  13405. *v = v2
  13406. }
  13407. case map[float64]uint8:
  13408. fastpathTV.DecMapFloat64Uint8V(v, false, d)
  13409. case *map[float64]uint8:
  13410. if v2, changed2 := fastpathTV.DecMapFloat64Uint8V(*v, true, d); changed2 {
  13411. *v = v2
  13412. }
  13413. case map[float64]uint16:
  13414. fastpathTV.DecMapFloat64Uint16V(v, false, d)
  13415. case *map[float64]uint16:
  13416. if v2, changed2 := fastpathTV.DecMapFloat64Uint16V(*v, true, d); changed2 {
  13417. *v = v2
  13418. }
  13419. case map[float64]uint32:
  13420. fastpathTV.DecMapFloat64Uint32V(v, false, d)
  13421. case *map[float64]uint32:
  13422. if v2, changed2 := fastpathTV.DecMapFloat64Uint32V(*v, true, d); changed2 {
  13423. *v = v2
  13424. }
  13425. case map[float64]uint64:
  13426. fastpathTV.DecMapFloat64Uint64V(v, false, d)
  13427. case *map[float64]uint64:
  13428. if v2, changed2 := fastpathTV.DecMapFloat64Uint64V(*v, true, d); changed2 {
  13429. *v = v2
  13430. }
  13431. case map[float64]uintptr:
  13432. fastpathTV.DecMapFloat64UintptrV(v, false, d)
  13433. case *map[float64]uintptr:
  13434. if v2, changed2 := fastpathTV.DecMapFloat64UintptrV(*v, true, d); changed2 {
  13435. *v = v2
  13436. }
  13437. case map[float64]int:
  13438. fastpathTV.DecMapFloat64IntV(v, false, d)
  13439. case *map[float64]int:
  13440. if v2, changed2 := fastpathTV.DecMapFloat64IntV(*v, true, d); changed2 {
  13441. *v = v2
  13442. }
  13443. case map[float64]int8:
  13444. fastpathTV.DecMapFloat64Int8V(v, false, d)
  13445. case *map[float64]int8:
  13446. if v2, changed2 := fastpathTV.DecMapFloat64Int8V(*v, true, d); changed2 {
  13447. *v = v2
  13448. }
  13449. case map[float64]int16:
  13450. fastpathTV.DecMapFloat64Int16V(v, false, d)
  13451. case *map[float64]int16:
  13452. if v2, changed2 := fastpathTV.DecMapFloat64Int16V(*v, true, d); changed2 {
  13453. *v = v2
  13454. }
  13455. case map[float64]int32:
  13456. fastpathTV.DecMapFloat64Int32V(v, false, d)
  13457. case *map[float64]int32:
  13458. if v2, changed2 := fastpathTV.DecMapFloat64Int32V(*v, true, d); changed2 {
  13459. *v = v2
  13460. }
  13461. case map[float64]int64:
  13462. fastpathTV.DecMapFloat64Int64V(v, false, d)
  13463. case *map[float64]int64:
  13464. if v2, changed2 := fastpathTV.DecMapFloat64Int64V(*v, true, d); changed2 {
  13465. *v = v2
  13466. }
  13467. case map[float64]float32:
  13468. fastpathTV.DecMapFloat64Float32V(v, false, d)
  13469. case *map[float64]float32:
  13470. if v2, changed2 := fastpathTV.DecMapFloat64Float32V(*v, true, d); changed2 {
  13471. *v = v2
  13472. }
  13473. case map[float64]float64:
  13474. fastpathTV.DecMapFloat64Float64V(v, false, d)
  13475. case *map[float64]float64:
  13476. if v2, changed2 := fastpathTV.DecMapFloat64Float64V(*v, true, d); changed2 {
  13477. *v = v2
  13478. }
  13479. case map[float64]bool:
  13480. fastpathTV.DecMapFloat64BoolV(v, false, d)
  13481. case *map[float64]bool:
  13482. if v2, changed2 := fastpathTV.DecMapFloat64BoolV(*v, true, d); changed2 {
  13483. *v = v2
  13484. }
  13485. case []uint:
  13486. fastpathTV.DecSliceUintV(v, false, d)
  13487. case *[]uint:
  13488. if v2, changed2 := fastpathTV.DecSliceUintV(*v, true, d); changed2 {
  13489. *v = v2
  13490. }
  13491. case map[uint]interface{}:
  13492. fastpathTV.DecMapUintIntfV(v, false, d)
  13493. case *map[uint]interface{}:
  13494. if v2, changed2 := fastpathTV.DecMapUintIntfV(*v, true, d); changed2 {
  13495. *v = v2
  13496. }
  13497. case map[uint]string:
  13498. fastpathTV.DecMapUintStringV(v, false, d)
  13499. case *map[uint]string:
  13500. if v2, changed2 := fastpathTV.DecMapUintStringV(*v, true, d); changed2 {
  13501. *v = v2
  13502. }
  13503. case map[uint]uint:
  13504. fastpathTV.DecMapUintUintV(v, false, d)
  13505. case *map[uint]uint:
  13506. if v2, changed2 := fastpathTV.DecMapUintUintV(*v, true, d); changed2 {
  13507. *v = v2
  13508. }
  13509. case map[uint]uint8:
  13510. fastpathTV.DecMapUintUint8V(v, false, d)
  13511. case *map[uint]uint8:
  13512. if v2, changed2 := fastpathTV.DecMapUintUint8V(*v, true, d); changed2 {
  13513. *v = v2
  13514. }
  13515. case map[uint]uint16:
  13516. fastpathTV.DecMapUintUint16V(v, false, d)
  13517. case *map[uint]uint16:
  13518. if v2, changed2 := fastpathTV.DecMapUintUint16V(*v, true, d); changed2 {
  13519. *v = v2
  13520. }
  13521. case map[uint]uint32:
  13522. fastpathTV.DecMapUintUint32V(v, false, d)
  13523. case *map[uint]uint32:
  13524. if v2, changed2 := fastpathTV.DecMapUintUint32V(*v, true, d); changed2 {
  13525. *v = v2
  13526. }
  13527. case map[uint]uint64:
  13528. fastpathTV.DecMapUintUint64V(v, false, d)
  13529. case *map[uint]uint64:
  13530. if v2, changed2 := fastpathTV.DecMapUintUint64V(*v, true, d); changed2 {
  13531. *v = v2
  13532. }
  13533. case map[uint]uintptr:
  13534. fastpathTV.DecMapUintUintptrV(v, false, d)
  13535. case *map[uint]uintptr:
  13536. if v2, changed2 := fastpathTV.DecMapUintUintptrV(*v, true, d); changed2 {
  13537. *v = v2
  13538. }
  13539. case map[uint]int:
  13540. fastpathTV.DecMapUintIntV(v, false, d)
  13541. case *map[uint]int:
  13542. if v2, changed2 := fastpathTV.DecMapUintIntV(*v, true, d); changed2 {
  13543. *v = v2
  13544. }
  13545. case map[uint]int8:
  13546. fastpathTV.DecMapUintInt8V(v, false, d)
  13547. case *map[uint]int8:
  13548. if v2, changed2 := fastpathTV.DecMapUintInt8V(*v, true, d); changed2 {
  13549. *v = v2
  13550. }
  13551. case map[uint]int16:
  13552. fastpathTV.DecMapUintInt16V(v, false, d)
  13553. case *map[uint]int16:
  13554. if v2, changed2 := fastpathTV.DecMapUintInt16V(*v, true, d); changed2 {
  13555. *v = v2
  13556. }
  13557. case map[uint]int32:
  13558. fastpathTV.DecMapUintInt32V(v, false, d)
  13559. case *map[uint]int32:
  13560. if v2, changed2 := fastpathTV.DecMapUintInt32V(*v, true, d); changed2 {
  13561. *v = v2
  13562. }
  13563. case map[uint]int64:
  13564. fastpathTV.DecMapUintInt64V(v, false, d)
  13565. case *map[uint]int64:
  13566. if v2, changed2 := fastpathTV.DecMapUintInt64V(*v, true, d); changed2 {
  13567. *v = v2
  13568. }
  13569. case map[uint]float32:
  13570. fastpathTV.DecMapUintFloat32V(v, false, d)
  13571. case *map[uint]float32:
  13572. if v2, changed2 := fastpathTV.DecMapUintFloat32V(*v, true, d); changed2 {
  13573. *v = v2
  13574. }
  13575. case map[uint]float64:
  13576. fastpathTV.DecMapUintFloat64V(v, false, d)
  13577. case *map[uint]float64:
  13578. if v2, changed2 := fastpathTV.DecMapUintFloat64V(*v, true, d); changed2 {
  13579. *v = v2
  13580. }
  13581. case map[uint]bool:
  13582. fastpathTV.DecMapUintBoolV(v, false, d)
  13583. case *map[uint]bool:
  13584. if v2, changed2 := fastpathTV.DecMapUintBoolV(*v, true, d); changed2 {
  13585. *v = v2
  13586. }
  13587. case map[uint8]interface{}:
  13588. fastpathTV.DecMapUint8IntfV(v, false, d)
  13589. case *map[uint8]interface{}:
  13590. if v2, changed2 := fastpathTV.DecMapUint8IntfV(*v, true, d); changed2 {
  13591. *v = v2
  13592. }
  13593. case map[uint8]string:
  13594. fastpathTV.DecMapUint8StringV(v, false, d)
  13595. case *map[uint8]string:
  13596. if v2, changed2 := fastpathTV.DecMapUint8StringV(*v, true, d); changed2 {
  13597. *v = v2
  13598. }
  13599. case map[uint8]uint:
  13600. fastpathTV.DecMapUint8UintV(v, false, d)
  13601. case *map[uint8]uint:
  13602. if v2, changed2 := fastpathTV.DecMapUint8UintV(*v, true, d); changed2 {
  13603. *v = v2
  13604. }
  13605. case map[uint8]uint8:
  13606. fastpathTV.DecMapUint8Uint8V(v, false, d)
  13607. case *map[uint8]uint8:
  13608. if v2, changed2 := fastpathTV.DecMapUint8Uint8V(*v, true, d); changed2 {
  13609. *v = v2
  13610. }
  13611. case map[uint8]uint16:
  13612. fastpathTV.DecMapUint8Uint16V(v, false, d)
  13613. case *map[uint8]uint16:
  13614. if v2, changed2 := fastpathTV.DecMapUint8Uint16V(*v, true, d); changed2 {
  13615. *v = v2
  13616. }
  13617. case map[uint8]uint32:
  13618. fastpathTV.DecMapUint8Uint32V(v, false, d)
  13619. case *map[uint8]uint32:
  13620. if v2, changed2 := fastpathTV.DecMapUint8Uint32V(*v, true, d); changed2 {
  13621. *v = v2
  13622. }
  13623. case map[uint8]uint64:
  13624. fastpathTV.DecMapUint8Uint64V(v, false, d)
  13625. case *map[uint8]uint64:
  13626. if v2, changed2 := fastpathTV.DecMapUint8Uint64V(*v, true, d); changed2 {
  13627. *v = v2
  13628. }
  13629. case map[uint8]uintptr:
  13630. fastpathTV.DecMapUint8UintptrV(v, false, d)
  13631. case *map[uint8]uintptr:
  13632. if v2, changed2 := fastpathTV.DecMapUint8UintptrV(*v, true, d); changed2 {
  13633. *v = v2
  13634. }
  13635. case map[uint8]int:
  13636. fastpathTV.DecMapUint8IntV(v, false, d)
  13637. case *map[uint8]int:
  13638. if v2, changed2 := fastpathTV.DecMapUint8IntV(*v, true, d); changed2 {
  13639. *v = v2
  13640. }
  13641. case map[uint8]int8:
  13642. fastpathTV.DecMapUint8Int8V(v, false, d)
  13643. case *map[uint8]int8:
  13644. if v2, changed2 := fastpathTV.DecMapUint8Int8V(*v, true, d); changed2 {
  13645. *v = v2
  13646. }
  13647. case map[uint8]int16:
  13648. fastpathTV.DecMapUint8Int16V(v, false, d)
  13649. case *map[uint8]int16:
  13650. if v2, changed2 := fastpathTV.DecMapUint8Int16V(*v, true, d); changed2 {
  13651. *v = v2
  13652. }
  13653. case map[uint8]int32:
  13654. fastpathTV.DecMapUint8Int32V(v, false, d)
  13655. case *map[uint8]int32:
  13656. if v2, changed2 := fastpathTV.DecMapUint8Int32V(*v, true, d); changed2 {
  13657. *v = v2
  13658. }
  13659. case map[uint8]int64:
  13660. fastpathTV.DecMapUint8Int64V(v, false, d)
  13661. case *map[uint8]int64:
  13662. if v2, changed2 := fastpathTV.DecMapUint8Int64V(*v, true, d); changed2 {
  13663. *v = v2
  13664. }
  13665. case map[uint8]float32:
  13666. fastpathTV.DecMapUint8Float32V(v, false, d)
  13667. case *map[uint8]float32:
  13668. if v2, changed2 := fastpathTV.DecMapUint8Float32V(*v, true, d); changed2 {
  13669. *v = v2
  13670. }
  13671. case map[uint8]float64:
  13672. fastpathTV.DecMapUint8Float64V(v, false, d)
  13673. case *map[uint8]float64:
  13674. if v2, changed2 := fastpathTV.DecMapUint8Float64V(*v, true, d); changed2 {
  13675. *v = v2
  13676. }
  13677. case map[uint8]bool:
  13678. fastpathTV.DecMapUint8BoolV(v, false, d)
  13679. case *map[uint8]bool:
  13680. if v2, changed2 := fastpathTV.DecMapUint8BoolV(*v, true, d); changed2 {
  13681. *v = v2
  13682. }
  13683. case []uint16:
  13684. fastpathTV.DecSliceUint16V(v, false, d)
  13685. case *[]uint16:
  13686. if v2, changed2 := fastpathTV.DecSliceUint16V(*v, true, d); changed2 {
  13687. *v = v2
  13688. }
  13689. case map[uint16]interface{}:
  13690. fastpathTV.DecMapUint16IntfV(v, false, d)
  13691. case *map[uint16]interface{}:
  13692. if v2, changed2 := fastpathTV.DecMapUint16IntfV(*v, true, d); changed2 {
  13693. *v = v2
  13694. }
  13695. case map[uint16]string:
  13696. fastpathTV.DecMapUint16StringV(v, false, d)
  13697. case *map[uint16]string:
  13698. if v2, changed2 := fastpathTV.DecMapUint16StringV(*v, true, d); changed2 {
  13699. *v = v2
  13700. }
  13701. case map[uint16]uint:
  13702. fastpathTV.DecMapUint16UintV(v, false, d)
  13703. case *map[uint16]uint:
  13704. if v2, changed2 := fastpathTV.DecMapUint16UintV(*v, true, d); changed2 {
  13705. *v = v2
  13706. }
  13707. case map[uint16]uint8:
  13708. fastpathTV.DecMapUint16Uint8V(v, false, d)
  13709. case *map[uint16]uint8:
  13710. if v2, changed2 := fastpathTV.DecMapUint16Uint8V(*v, true, d); changed2 {
  13711. *v = v2
  13712. }
  13713. case map[uint16]uint16:
  13714. fastpathTV.DecMapUint16Uint16V(v, false, d)
  13715. case *map[uint16]uint16:
  13716. if v2, changed2 := fastpathTV.DecMapUint16Uint16V(*v, true, d); changed2 {
  13717. *v = v2
  13718. }
  13719. case map[uint16]uint32:
  13720. fastpathTV.DecMapUint16Uint32V(v, false, d)
  13721. case *map[uint16]uint32:
  13722. if v2, changed2 := fastpathTV.DecMapUint16Uint32V(*v, true, d); changed2 {
  13723. *v = v2
  13724. }
  13725. case map[uint16]uint64:
  13726. fastpathTV.DecMapUint16Uint64V(v, false, d)
  13727. case *map[uint16]uint64:
  13728. if v2, changed2 := fastpathTV.DecMapUint16Uint64V(*v, true, d); changed2 {
  13729. *v = v2
  13730. }
  13731. case map[uint16]uintptr:
  13732. fastpathTV.DecMapUint16UintptrV(v, false, d)
  13733. case *map[uint16]uintptr:
  13734. if v2, changed2 := fastpathTV.DecMapUint16UintptrV(*v, true, d); changed2 {
  13735. *v = v2
  13736. }
  13737. case map[uint16]int:
  13738. fastpathTV.DecMapUint16IntV(v, false, d)
  13739. case *map[uint16]int:
  13740. if v2, changed2 := fastpathTV.DecMapUint16IntV(*v, true, d); changed2 {
  13741. *v = v2
  13742. }
  13743. case map[uint16]int8:
  13744. fastpathTV.DecMapUint16Int8V(v, false, d)
  13745. case *map[uint16]int8:
  13746. if v2, changed2 := fastpathTV.DecMapUint16Int8V(*v, true, d); changed2 {
  13747. *v = v2
  13748. }
  13749. case map[uint16]int16:
  13750. fastpathTV.DecMapUint16Int16V(v, false, d)
  13751. case *map[uint16]int16:
  13752. if v2, changed2 := fastpathTV.DecMapUint16Int16V(*v, true, d); changed2 {
  13753. *v = v2
  13754. }
  13755. case map[uint16]int32:
  13756. fastpathTV.DecMapUint16Int32V(v, false, d)
  13757. case *map[uint16]int32:
  13758. if v2, changed2 := fastpathTV.DecMapUint16Int32V(*v, true, d); changed2 {
  13759. *v = v2
  13760. }
  13761. case map[uint16]int64:
  13762. fastpathTV.DecMapUint16Int64V(v, false, d)
  13763. case *map[uint16]int64:
  13764. if v2, changed2 := fastpathTV.DecMapUint16Int64V(*v, true, d); changed2 {
  13765. *v = v2
  13766. }
  13767. case map[uint16]float32:
  13768. fastpathTV.DecMapUint16Float32V(v, false, d)
  13769. case *map[uint16]float32:
  13770. if v2, changed2 := fastpathTV.DecMapUint16Float32V(*v, true, d); changed2 {
  13771. *v = v2
  13772. }
  13773. case map[uint16]float64:
  13774. fastpathTV.DecMapUint16Float64V(v, false, d)
  13775. case *map[uint16]float64:
  13776. if v2, changed2 := fastpathTV.DecMapUint16Float64V(*v, true, d); changed2 {
  13777. *v = v2
  13778. }
  13779. case map[uint16]bool:
  13780. fastpathTV.DecMapUint16BoolV(v, false, d)
  13781. case *map[uint16]bool:
  13782. if v2, changed2 := fastpathTV.DecMapUint16BoolV(*v, true, d); changed2 {
  13783. *v = v2
  13784. }
  13785. case []uint32:
  13786. fastpathTV.DecSliceUint32V(v, false, d)
  13787. case *[]uint32:
  13788. if v2, changed2 := fastpathTV.DecSliceUint32V(*v, true, d); changed2 {
  13789. *v = v2
  13790. }
  13791. case map[uint32]interface{}:
  13792. fastpathTV.DecMapUint32IntfV(v, false, d)
  13793. case *map[uint32]interface{}:
  13794. if v2, changed2 := fastpathTV.DecMapUint32IntfV(*v, true, d); changed2 {
  13795. *v = v2
  13796. }
  13797. case map[uint32]string:
  13798. fastpathTV.DecMapUint32StringV(v, false, d)
  13799. case *map[uint32]string:
  13800. if v2, changed2 := fastpathTV.DecMapUint32StringV(*v, true, d); changed2 {
  13801. *v = v2
  13802. }
  13803. case map[uint32]uint:
  13804. fastpathTV.DecMapUint32UintV(v, false, d)
  13805. case *map[uint32]uint:
  13806. if v2, changed2 := fastpathTV.DecMapUint32UintV(*v, true, d); changed2 {
  13807. *v = v2
  13808. }
  13809. case map[uint32]uint8:
  13810. fastpathTV.DecMapUint32Uint8V(v, false, d)
  13811. case *map[uint32]uint8:
  13812. if v2, changed2 := fastpathTV.DecMapUint32Uint8V(*v, true, d); changed2 {
  13813. *v = v2
  13814. }
  13815. case map[uint32]uint16:
  13816. fastpathTV.DecMapUint32Uint16V(v, false, d)
  13817. case *map[uint32]uint16:
  13818. if v2, changed2 := fastpathTV.DecMapUint32Uint16V(*v, true, d); changed2 {
  13819. *v = v2
  13820. }
  13821. case map[uint32]uint32:
  13822. fastpathTV.DecMapUint32Uint32V(v, false, d)
  13823. case *map[uint32]uint32:
  13824. if v2, changed2 := fastpathTV.DecMapUint32Uint32V(*v, true, d); changed2 {
  13825. *v = v2
  13826. }
  13827. case map[uint32]uint64:
  13828. fastpathTV.DecMapUint32Uint64V(v, false, d)
  13829. case *map[uint32]uint64:
  13830. if v2, changed2 := fastpathTV.DecMapUint32Uint64V(*v, true, d); changed2 {
  13831. *v = v2
  13832. }
  13833. case map[uint32]uintptr:
  13834. fastpathTV.DecMapUint32UintptrV(v, false, d)
  13835. case *map[uint32]uintptr:
  13836. if v2, changed2 := fastpathTV.DecMapUint32UintptrV(*v, true, d); changed2 {
  13837. *v = v2
  13838. }
  13839. case map[uint32]int:
  13840. fastpathTV.DecMapUint32IntV(v, false, d)
  13841. case *map[uint32]int:
  13842. if v2, changed2 := fastpathTV.DecMapUint32IntV(*v, true, d); changed2 {
  13843. *v = v2
  13844. }
  13845. case map[uint32]int8:
  13846. fastpathTV.DecMapUint32Int8V(v, false, d)
  13847. case *map[uint32]int8:
  13848. if v2, changed2 := fastpathTV.DecMapUint32Int8V(*v, true, d); changed2 {
  13849. *v = v2
  13850. }
  13851. case map[uint32]int16:
  13852. fastpathTV.DecMapUint32Int16V(v, false, d)
  13853. case *map[uint32]int16:
  13854. if v2, changed2 := fastpathTV.DecMapUint32Int16V(*v, true, d); changed2 {
  13855. *v = v2
  13856. }
  13857. case map[uint32]int32:
  13858. fastpathTV.DecMapUint32Int32V(v, false, d)
  13859. case *map[uint32]int32:
  13860. if v2, changed2 := fastpathTV.DecMapUint32Int32V(*v, true, d); changed2 {
  13861. *v = v2
  13862. }
  13863. case map[uint32]int64:
  13864. fastpathTV.DecMapUint32Int64V(v, false, d)
  13865. case *map[uint32]int64:
  13866. if v2, changed2 := fastpathTV.DecMapUint32Int64V(*v, true, d); changed2 {
  13867. *v = v2
  13868. }
  13869. case map[uint32]float32:
  13870. fastpathTV.DecMapUint32Float32V(v, false, d)
  13871. case *map[uint32]float32:
  13872. if v2, changed2 := fastpathTV.DecMapUint32Float32V(*v, true, d); changed2 {
  13873. *v = v2
  13874. }
  13875. case map[uint32]float64:
  13876. fastpathTV.DecMapUint32Float64V(v, false, d)
  13877. case *map[uint32]float64:
  13878. if v2, changed2 := fastpathTV.DecMapUint32Float64V(*v, true, d); changed2 {
  13879. *v = v2
  13880. }
  13881. case map[uint32]bool:
  13882. fastpathTV.DecMapUint32BoolV(v, false, d)
  13883. case *map[uint32]bool:
  13884. if v2, changed2 := fastpathTV.DecMapUint32BoolV(*v, true, d); changed2 {
  13885. *v = v2
  13886. }
  13887. case []uint64:
  13888. fastpathTV.DecSliceUint64V(v, false, d)
  13889. case *[]uint64:
  13890. if v2, changed2 := fastpathTV.DecSliceUint64V(*v, true, d); changed2 {
  13891. *v = v2
  13892. }
  13893. case map[uint64]interface{}:
  13894. fastpathTV.DecMapUint64IntfV(v, false, d)
  13895. case *map[uint64]interface{}:
  13896. if v2, changed2 := fastpathTV.DecMapUint64IntfV(*v, true, d); changed2 {
  13897. *v = v2
  13898. }
  13899. case map[uint64]string:
  13900. fastpathTV.DecMapUint64StringV(v, false, d)
  13901. case *map[uint64]string:
  13902. if v2, changed2 := fastpathTV.DecMapUint64StringV(*v, true, d); changed2 {
  13903. *v = v2
  13904. }
  13905. case map[uint64]uint:
  13906. fastpathTV.DecMapUint64UintV(v, false, d)
  13907. case *map[uint64]uint:
  13908. if v2, changed2 := fastpathTV.DecMapUint64UintV(*v, true, d); changed2 {
  13909. *v = v2
  13910. }
  13911. case map[uint64]uint8:
  13912. fastpathTV.DecMapUint64Uint8V(v, false, d)
  13913. case *map[uint64]uint8:
  13914. if v2, changed2 := fastpathTV.DecMapUint64Uint8V(*v, true, d); changed2 {
  13915. *v = v2
  13916. }
  13917. case map[uint64]uint16:
  13918. fastpathTV.DecMapUint64Uint16V(v, false, d)
  13919. case *map[uint64]uint16:
  13920. if v2, changed2 := fastpathTV.DecMapUint64Uint16V(*v, true, d); changed2 {
  13921. *v = v2
  13922. }
  13923. case map[uint64]uint32:
  13924. fastpathTV.DecMapUint64Uint32V(v, false, d)
  13925. case *map[uint64]uint32:
  13926. if v2, changed2 := fastpathTV.DecMapUint64Uint32V(*v, true, d); changed2 {
  13927. *v = v2
  13928. }
  13929. case map[uint64]uint64:
  13930. fastpathTV.DecMapUint64Uint64V(v, false, d)
  13931. case *map[uint64]uint64:
  13932. if v2, changed2 := fastpathTV.DecMapUint64Uint64V(*v, true, d); changed2 {
  13933. *v = v2
  13934. }
  13935. case map[uint64]uintptr:
  13936. fastpathTV.DecMapUint64UintptrV(v, false, d)
  13937. case *map[uint64]uintptr:
  13938. if v2, changed2 := fastpathTV.DecMapUint64UintptrV(*v, true, d); changed2 {
  13939. *v = v2
  13940. }
  13941. case map[uint64]int:
  13942. fastpathTV.DecMapUint64IntV(v, false, d)
  13943. case *map[uint64]int:
  13944. if v2, changed2 := fastpathTV.DecMapUint64IntV(*v, true, d); changed2 {
  13945. *v = v2
  13946. }
  13947. case map[uint64]int8:
  13948. fastpathTV.DecMapUint64Int8V(v, false, d)
  13949. case *map[uint64]int8:
  13950. if v2, changed2 := fastpathTV.DecMapUint64Int8V(*v, true, d); changed2 {
  13951. *v = v2
  13952. }
  13953. case map[uint64]int16:
  13954. fastpathTV.DecMapUint64Int16V(v, false, d)
  13955. case *map[uint64]int16:
  13956. if v2, changed2 := fastpathTV.DecMapUint64Int16V(*v, true, d); changed2 {
  13957. *v = v2
  13958. }
  13959. case map[uint64]int32:
  13960. fastpathTV.DecMapUint64Int32V(v, false, d)
  13961. case *map[uint64]int32:
  13962. if v2, changed2 := fastpathTV.DecMapUint64Int32V(*v, true, d); changed2 {
  13963. *v = v2
  13964. }
  13965. case map[uint64]int64:
  13966. fastpathTV.DecMapUint64Int64V(v, false, d)
  13967. case *map[uint64]int64:
  13968. if v2, changed2 := fastpathTV.DecMapUint64Int64V(*v, true, d); changed2 {
  13969. *v = v2
  13970. }
  13971. case map[uint64]float32:
  13972. fastpathTV.DecMapUint64Float32V(v, false, d)
  13973. case *map[uint64]float32:
  13974. if v2, changed2 := fastpathTV.DecMapUint64Float32V(*v, true, d); changed2 {
  13975. *v = v2
  13976. }
  13977. case map[uint64]float64:
  13978. fastpathTV.DecMapUint64Float64V(v, false, d)
  13979. case *map[uint64]float64:
  13980. if v2, changed2 := fastpathTV.DecMapUint64Float64V(*v, true, d); changed2 {
  13981. *v = v2
  13982. }
  13983. case map[uint64]bool:
  13984. fastpathTV.DecMapUint64BoolV(v, false, d)
  13985. case *map[uint64]bool:
  13986. if v2, changed2 := fastpathTV.DecMapUint64BoolV(*v, true, d); changed2 {
  13987. *v = v2
  13988. }
  13989. case []uintptr:
  13990. fastpathTV.DecSliceUintptrV(v, false, d)
  13991. case *[]uintptr:
  13992. if v2, changed2 := fastpathTV.DecSliceUintptrV(*v, true, d); changed2 {
  13993. *v = v2
  13994. }
  13995. case map[uintptr]interface{}:
  13996. fastpathTV.DecMapUintptrIntfV(v, false, d)
  13997. case *map[uintptr]interface{}:
  13998. if v2, changed2 := fastpathTV.DecMapUintptrIntfV(*v, true, d); changed2 {
  13999. *v = v2
  14000. }
  14001. case map[uintptr]string:
  14002. fastpathTV.DecMapUintptrStringV(v, false, d)
  14003. case *map[uintptr]string:
  14004. if v2, changed2 := fastpathTV.DecMapUintptrStringV(*v, true, d); changed2 {
  14005. *v = v2
  14006. }
  14007. case map[uintptr]uint:
  14008. fastpathTV.DecMapUintptrUintV(v, false, d)
  14009. case *map[uintptr]uint:
  14010. if v2, changed2 := fastpathTV.DecMapUintptrUintV(*v, true, d); changed2 {
  14011. *v = v2
  14012. }
  14013. case map[uintptr]uint8:
  14014. fastpathTV.DecMapUintptrUint8V(v, false, d)
  14015. case *map[uintptr]uint8:
  14016. if v2, changed2 := fastpathTV.DecMapUintptrUint8V(*v, true, d); changed2 {
  14017. *v = v2
  14018. }
  14019. case map[uintptr]uint16:
  14020. fastpathTV.DecMapUintptrUint16V(v, false, d)
  14021. case *map[uintptr]uint16:
  14022. if v2, changed2 := fastpathTV.DecMapUintptrUint16V(*v, true, d); changed2 {
  14023. *v = v2
  14024. }
  14025. case map[uintptr]uint32:
  14026. fastpathTV.DecMapUintptrUint32V(v, false, d)
  14027. case *map[uintptr]uint32:
  14028. if v2, changed2 := fastpathTV.DecMapUintptrUint32V(*v, true, d); changed2 {
  14029. *v = v2
  14030. }
  14031. case map[uintptr]uint64:
  14032. fastpathTV.DecMapUintptrUint64V(v, false, d)
  14033. case *map[uintptr]uint64:
  14034. if v2, changed2 := fastpathTV.DecMapUintptrUint64V(*v, true, d); changed2 {
  14035. *v = v2
  14036. }
  14037. case map[uintptr]uintptr:
  14038. fastpathTV.DecMapUintptrUintptrV(v, false, d)
  14039. case *map[uintptr]uintptr:
  14040. if v2, changed2 := fastpathTV.DecMapUintptrUintptrV(*v, true, d); changed2 {
  14041. *v = v2
  14042. }
  14043. case map[uintptr]int:
  14044. fastpathTV.DecMapUintptrIntV(v, false, d)
  14045. case *map[uintptr]int:
  14046. if v2, changed2 := fastpathTV.DecMapUintptrIntV(*v, true, d); changed2 {
  14047. *v = v2
  14048. }
  14049. case map[uintptr]int8:
  14050. fastpathTV.DecMapUintptrInt8V(v, false, d)
  14051. case *map[uintptr]int8:
  14052. if v2, changed2 := fastpathTV.DecMapUintptrInt8V(*v, true, d); changed2 {
  14053. *v = v2
  14054. }
  14055. case map[uintptr]int16:
  14056. fastpathTV.DecMapUintptrInt16V(v, false, d)
  14057. case *map[uintptr]int16:
  14058. if v2, changed2 := fastpathTV.DecMapUintptrInt16V(*v, true, d); changed2 {
  14059. *v = v2
  14060. }
  14061. case map[uintptr]int32:
  14062. fastpathTV.DecMapUintptrInt32V(v, false, d)
  14063. case *map[uintptr]int32:
  14064. if v2, changed2 := fastpathTV.DecMapUintptrInt32V(*v, true, d); changed2 {
  14065. *v = v2
  14066. }
  14067. case map[uintptr]int64:
  14068. fastpathTV.DecMapUintptrInt64V(v, false, d)
  14069. case *map[uintptr]int64:
  14070. if v2, changed2 := fastpathTV.DecMapUintptrInt64V(*v, true, d); changed2 {
  14071. *v = v2
  14072. }
  14073. case map[uintptr]float32:
  14074. fastpathTV.DecMapUintptrFloat32V(v, false, d)
  14075. case *map[uintptr]float32:
  14076. if v2, changed2 := fastpathTV.DecMapUintptrFloat32V(*v, true, d); changed2 {
  14077. *v = v2
  14078. }
  14079. case map[uintptr]float64:
  14080. fastpathTV.DecMapUintptrFloat64V(v, false, d)
  14081. case *map[uintptr]float64:
  14082. if v2, changed2 := fastpathTV.DecMapUintptrFloat64V(*v, true, d); changed2 {
  14083. *v = v2
  14084. }
  14085. case map[uintptr]bool:
  14086. fastpathTV.DecMapUintptrBoolV(v, false, d)
  14087. case *map[uintptr]bool:
  14088. if v2, changed2 := fastpathTV.DecMapUintptrBoolV(*v, true, d); changed2 {
  14089. *v = v2
  14090. }
  14091. case []int:
  14092. fastpathTV.DecSliceIntV(v, false, d)
  14093. case *[]int:
  14094. if v2, changed2 := fastpathTV.DecSliceIntV(*v, true, d); changed2 {
  14095. *v = v2
  14096. }
  14097. case map[int]interface{}:
  14098. fastpathTV.DecMapIntIntfV(v, false, d)
  14099. case *map[int]interface{}:
  14100. if v2, changed2 := fastpathTV.DecMapIntIntfV(*v, true, d); changed2 {
  14101. *v = v2
  14102. }
  14103. case map[int]string:
  14104. fastpathTV.DecMapIntStringV(v, false, d)
  14105. case *map[int]string:
  14106. if v2, changed2 := fastpathTV.DecMapIntStringV(*v, true, d); changed2 {
  14107. *v = v2
  14108. }
  14109. case map[int]uint:
  14110. fastpathTV.DecMapIntUintV(v, false, d)
  14111. case *map[int]uint:
  14112. if v2, changed2 := fastpathTV.DecMapIntUintV(*v, true, d); changed2 {
  14113. *v = v2
  14114. }
  14115. case map[int]uint8:
  14116. fastpathTV.DecMapIntUint8V(v, false, d)
  14117. case *map[int]uint8:
  14118. if v2, changed2 := fastpathTV.DecMapIntUint8V(*v, true, d); changed2 {
  14119. *v = v2
  14120. }
  14121. case map[int]uint16:
  14122. fastpathTV.DecMapIntUint16V(v, false, d)
  14123. case *map[int]uint16:
  14124. if v2, changed2 := fastpathTV.DecMapIntUint16V(*v, true, d); changed2 {
  14125. *v = v2
  14126. }
  14127. case map[int]uint32:
  14128. fastpathTV.DecMapIntUint32V(v, false, d)
  14129. case *map[int]uint32:
  14130. if v2, changed2 := fastpathTV.DecMapIntUint32V(*v, true, d); changed2 {
  14131. *v = v2
  14132. }
  14133. case map[int]uint64:
  14134. fastpathTV.DecMapIntUint64V(v, false, d)
  14135. case *map[int]uint64:
  14136. if v2, changed2 := fastpathTV.DecMapIntUint64V(*v, true, d); changed2 {
  14137. *v = v2
  14138. }
  14139. case map[int]uintptr:
  14140. fastpathTV.DecMapIntUintptrV(v, false, d)
  14141. case *map[int]uintptr:
  14142. if v2, changed2 := fastpathTV.DecMapIntUintptrV(*v, true, d); changed2 {
  14143. *v = v2
  14144. }
  14145. case map[int]int:
  14146. fastpathTV.DecMapIntIntV(v, false, d)
  14147. case *map[int]int:
  14148. if v2, changed2 := fastpathTV.DecMapIntIntV(*v, true, d); changed2 {
  14149. *v = v2
  14150. }
  14151. case map[int]int8:
  14152. fastpathTV.DecMapIntInt8V(v, false, d)
  14153. case *map[int]int8:
  14154. if v2, changed2 := fastpathTV.DecMapIntInt8V(*v, true, d); changed2 {
  14155. *v = v2
  14156. }
  14157. case map[int]int16:
  14158. fastpathTV.DecMapIntInt16V(v, false, d)
  14159. case *map[int]int16:
  14160. if v2, changed2 := fastpathTV.DecMapIntInt16V(*v, true, d); changed2 {
  14161. *v = v2
  14162. }
  14163. case map[int]int32:
  14164. fastpathTV.DecMapIntInt32V(v, false, d)
  14165. case *map[int]int32:
  14166. if v2, changed2 := fastpathTV.DecMapIntInt32V(*v, true, d); changed2 {
  14167. *v = v2
  14168. }
  14169. case map[int]int64:
  14170. fastpathTV.DecMapIntInt64V(v, false, d)
  14171. case *map[int]int64:
  14172. if v2, changed2 := fastpathTV.DecMapIntInt64V(*v, true, d); changed2 {
  14173. *v = v2
  14174. }
  14175. case map[int]float32:
  14176. fastpathTV.DecMapIntFloat32V(v, false, d)
  14177. case *map[int]float32:
  14178. if v2, changed2 := fastpathTV.DecMapIntFloat32V(*v, true, d); changed2 {
  14179. *v = v2
  14180. }
  14181. case map[int]float64:
  14182. fastpathTV.DecMapIntFloat64V(v, false, d)
  14183. case *map[int]float64:
  14184. if v2, changed2 := fastpathTV.DecMapIntFloat64V(*v, true, d); changed2 {
  14185. *v = v2
  14186. }
  14187. case map[int]bool:
  14188. fastpathTV.DecMapIntBoolV(v, false, d)
  14189. case *map[int]bool:
  14190. if v2, changed2 := fastpathTV.DecMapIntBoolV(*v, true, d); changed2 {
  14191. *v = v2
  14192. }
  14193. case []int8:
  14194. fastpathTV.DecSliceInt8V(v, false, d)
  14195. case *[]int8:
  14196. if v2, changed2 := fastpathTV.DecSliceInt8V(*v, true, d); changed2 {
  14197. *v = v2
  14198. }
  14199. case map[int8]interface{}:
  14200. fastpathTV.DecMapInt8IntfV(v, false, d)
  14201. case *map[int8]interface{}:
  14202. if v2, changed2 := fastpathTV.DecMapInt8IntfV(*v, true, d); changed2 {
  14203. *v = v2
  14204. }
  14205. case map[int8]string:
  14206. fastpathTV.DecMapInt8StringV(v, false, d)
  14207. case *map[int8]string:
  14208. if v2, changed2 := fastpathTV.DecMapInt8StringV(*v, true, d); changed2 {
  14209. *v = v2
  14210. }
  14211. case map[int8]uint:
  14212. fastpathTV.DecMapInt8UintV(v, false, d)
  14213. case *map[int8]uint:
  14214. if v2, changed2 := fastpathTV.DecMapInt8UintV(*v, true, d); changed2 {
  14215. *v = v2
  14216. }
  14217. case map[int8]uint8:
  14218. fastpathTV.DecMapInt8Uint8V(v, false, d)
  14219. case *map[int8]uint8:
  14220. if v2, changed2 := fastpathTV.DecMapInt8Uint8V(*v, true, d); changed2 {
  14221. *v = v2
  14222. }
  14223. case map[int8]uint16:
  14224. fastpathTV.DecMapInt8Uint16V(v, false, d)
  14225. case *map[int8]uint16:
  14226. if v2, changed2 := fastpathTV.DecMapInt8Uint16V(*v, true, d); changed2 {
  14227. *v = v2
  14228. }
  14229. case map[int8]uint32:
  14230. fastpathTV.DecMapInt8Uint32V(v, false, d)
  14231. case *map[int8]uint32:
  14232. if v2, changed2 := fastpathTV.DecMapInt8Uint32V(*v, true, d); changed2 {
  14233. *v = v2
  14234. }
  14235. case map[int8]uint64:
  14236. fastpathTV.DecMapInt8Uint64V(v, false, d)
  14237. case *map[int8]uint64:
  14238. if v2, changed2 := fastpathTV.DecMapInt8Uint64V(*v, true, d); changed2 {
  14239. *v = v2
  14240. }
  14241. case map[int8]uintptr:
  14242. fastpathTV.DecMapInt8UintptrV(v, false, d)
  14243. case *map[int8]uintptr:
  14244. if v2, changed2 := fastpathTV.DecMapInt8UintptrV(*v, true, d); changed2 {
  14245. *v = v2
  14246. }
  14247. case map[int8]int:
  14248. fastpathTV.DecMapInt8IntV(v, false, d)
  14249. case *map[int8]int:
  14250. if v2, changed2 := fastpathTV.DecMapInt8IntV(*v, true, d); changed2 {
  14251. *v = v2
  14252. }
  14253. case map[int8]int8:
  14254. fastpathTV.DecMapInt8Int8V(v, false, d)
  14255. case *map[int8]int8:
  14256. if v2, changed2 := fastpathTV.DecMapInt8Int8V(*v, true, d); changed2 {
  14257. *v = v2
  14258. }
  14259. case map[int8]int16:
  14260. fastpathTV.DecMapInt8Int16V(v, false, d)
  14261. case *map[int8]int16:
  14262. if v2, changed2 := fastpathTV.DecMapInt8Int16V(*v, true, d); changed2 {
  14263. *v = v2
  14264. }
  14265. case map[int8]int32:
  14266. fastpathTV.DecMapInt8Int32V(v, false, d)
  14267. case *map[int8]int32:
  14268. if v2, changed2 := fastpathTV.DecMapInt8Int32V(*v, true, d); changed2 {
  14269. *v = v2
  14270. }
  14271. case map[int8]int64:
  14272. fastpathTV.DecMapInt8Int64V(v, false, d)
  14273. case *map[int8]int64:
  14274. if v2, changed2 := fastpathTV.DecMapInt8Int64V(*v, true, d); changed2 {
  14275. *v = v2
  14276. }
  14277. case map[int8]float32:
  14278. fastpathTV.DecMapInt8Float32V(v, false, d)
  14279. case *map[int8]float32:
  14280. if v2, changed2 := fastpathTV.DecMapInt8Float32V(*v, true, d); changed2 {
  14281. *v = v2
  14282. }
  14283. case map[int8]float64:
  14284. fastpathTV.DecMapInt8Float64V(v, false, d)
  14285. case *map[int8]float64:
  14286. if v2, changed2 := fastpathTV.DecMapInt8Float64V(*v, true, d); changed2 {
  14287. *v = v2
  14288. }
  14289. case map[int8]bool:
  14290. fastpathTV.DecMapInt8BoolV(v, false, d)
  14291. case *map[int8]bool:
  14292. if v2, changed2 := fastpathTV.DecMapInt8BoolV(*v, true, d); changed2 {
  14293. *v = v2
  14294. }
  14295. case []int16:
  14296. fastpathTV.DecSliceInt16V(v, false, d)
  14297. case *[]int16:
  14298. if v2, changed2 := fastpathTV.DecSliceInt16V(*v, true, d); changed2 {
  14299. *v = v2
  14300. }
  14301. case map[int16]interface{}:
  14302. fastpathTV.DecMapInt16IntfV(v, false, d)
  14303. case *map[int16]interface{}:
  14304. if v2, changed2 := fastpathTV.DecMapInt16IntfV(*v, true, d); changed2 {
  14305. *v = v2
  14306. }
  14307. case map[int16]string:
  14308. fastpathTV.DecMapInt16StringV(v, false, d)
  14309. case *map[int16]string:
  14310. if v2, changed2 := fastpathTV.DecMapInt16StringV(*v, true, d); changed2 {
  14311. *v = v2
  14312. }
  14313. case map[int16]uint:
  14314. fastpathTV.DecMapInt16UintV(v, false, d)
  14315. case *map[int16]uint:
  14316. if v2, changed2 := fastpathTV.DecMapInt16UintV(*v, true, d); changed2 {
  14317. *v = v2
  14318. }
  14319. case map[int16]uint8:
  14320. fastpathTV.DecMapInt16Uint8V(v, false, d)
  14321. case *map[int16]uint8:
  14322. if v2, changed2 := fastpathTV.DecMapInt16Uint8V(*v, true, d); changed2 {
  14323. *v = v2
  14324. }
  14325. case map[int16]uint16:
  14326. fastpathTV.DecMapInt16Uint16V(v, false, d)
  14327. case *map[int16]uint16:
  14328. if v2, changed2 := fastpathTV.DecMapInt16Uint16V(*v, true, d); changed2 {
  14329. *v = v2
  14330. }
  14331. case map[int16]uint32:
  14332. fastpathTV.DecMapInt16Uint32V(v, false, d)
  14333. case *map[int16]uint32:
  14334. if v2, changed2 := fastpathTV.DecMapInt16Uint32V(*v, true, d); changed2 {
  14335. *v = v2
  14336. }
  14337. case map[int16]uint64:
  14338. fastpathTV.DecMapInt16Uint64V(v, false, d)
  14339. case *map[int16]uint64:
  14340. if v2, changed2 := fastpathTV.DecMapInt16Uint64V(*v, true, d); changed2 {
  14341. *v = v2
  14342. }
  14343. case map[int16]uintptr:
  14344. fastpathTV.DecMapInt16UintptrV(v, false, d)
  14345. case *map[int16]uintptr:
  14346. if v2, changed2 := fastpathTV.DecMapInt16UintptrV(*v, true, d); changed2 {
  14347. *v = v2
  14348. }
  14349. case map[int16]int:
  14350. fastpathTV.DecMapInt16IntV(v, false, d)
  14351. case *map[int16]int:
  14352. if v2, changed2 := fastpathTV.DecMapInt16IntV(*v, true, d); changed2 {
  14353. *v = v2
  14354. }
  14355. case map[int16]int8:
  14356. fastpathTV.DecMapInt16Int8V(v, false, d)
  14357. case *map[int16]int8:
  14358. if v2, changed2 := fastpathTV.DecMapInt16Int8V(*v, true, d); changed2 {
  14359. *v = v2
  14360. }
  14361. case map[int16]int16:
  14362. fastpathTV.DecMapInt16Int16V(v, false, d)
  14363. case *map[int16]int16:
  14364. if v2, changed2 := fastpathTV.DecMapInt16Int16V(*v, true, d); changed2 {
  14365. *v = v2
  14366. }
  14367. case map[int16]int32:
  14368. fastpathTV.DecMapInt16Int32V(v, false, d)
  14369. case *map[int16]int32:
  14370. if v2, changed2 := fastpathTV.DecMapInt16Int32V(*v, true, d); changed2 {
  14371. *v = v2
  14372. }
  14373. case map[int16]int64:
  14374. fastpathTV.DecMapInt16Int64V(v, false, d)
  14375. case *map[int16]int64:
  14376. if v2, changed2 := fastpathTV.DecMapInt16Int64V(*v, true, d); changed2 {
  14377. *v = v2
  14378. }
  14379. case map[int16]float32:
  14380. fastpathTV.DecMapInt16Float32V(v, false, d)
  14381. case *map[int16]float32:
  14382. if v2, changed2 := fastpathTV.DecMapInt16Float32V(*v, true, d); changed2 {
  14383. *v = v2
  14384. }
  14385. case map[int16]float64:
  14386. fastpathTV.DecMapInt16Float64V(v, false, d)
  14387. case *map[int16]float64:
  14388. if v2, changed2 := fastpathTV.DecMapInt16Float64V(*v, true, d); changed2 {
  14389. *v = v2
  14390. }
  14391. case map[int16]bool:
  14392. fastpathTV.DecMapInt16BoolV(v, false, d)
  14393. case *map[int16]bool:
  14394. if v2, changed2 := fastpathTV.DecMapInt16BoolV(*v, true, d); changed2 {
  14395. *v = v2
  14396. }
  14397. case []int32:
  14398. fastpathTV.DecSliceInt32V(v, false, d)
  14399. case *[]int32:
  14400. if v2, changed2 := fastpathTV.DecSliceInt32V(*v, true, d); changed2 {
  14401. *v = v2
  14402. }
  14403. case map[int32]interface{}:
  14404. fastpathTV.DecMapInt32IntfV(v, false, d)
  14405. case *map[int32]interface{}:
  14406. if v2, changed2 := fastpathTV.DecMapInt32IntfV(*v, true, d); changed2 {
  14407. *v = v2
  14408. }
  14409. case map[int32]string:
  14410. fastpathTV.DecMapInt32StringV(v, false, d)
  14411. case *map[int32]string:
  14412. if v2, changed2 := fastpathTV.DecMapInt32StringV(*v, true, d); changed2 {
  14413. *v = v2
  14414. }
  14415. case map[int32]uint:
  14416. fastpathTV.DecMapInt32UintV(v, false, d)
  14417. case *map[int32]uint:
  14418. if v2, changed2 := fastpathTV.DecMapInt32UintV(*v, true, d); changed2 {
  14419. *v = v2
  14420. }
  14421. case map[int32]uint8:
  14422. fastpathTV.DecMapInt32Uint8V(v, false, d)
  14423. case *map[int32]uint8:
  14424. if v2, changed2 := fastpathTV.DecMapInt32Uint8V(*v, true, d); changed2 {
  14425. *v = v2
  14426. }
  14427. case map[int32]uint16:
  14428. fastpathTV.DecMapInt32Uint16V(v, false, d)
  14429. case *map[int32]uint16:
  14430. if v2, changed2 := fastpathTV.DecMapInt32Uint16V(*v, true, d); changed2 {
  14431. *v = v2
  14432. }
  14433. case map[int32]uint32:
  14434. fastpathTV.DecMapInt32Uint32V(v, false, d)
  14435. case *map[int32]uint32:
  14436. if v2, changed2 := fastpathTV.DecMapInt32Uint32V(*v, true, d); changed2 {
  14437. *v = v2
  14438. }
  14439. case map[int32]uint64:
  14440. fastpathTV.DecMapInt32Uint64V(v, false, d)
  14441. case *map[int32]uint64:
  14442. if v2, changed2 := fastpathTV.DecMapInt32Uint64V(*v, true, d); changed2 {
  14443. *v = v2
  14444. }
  14445. case map[int32]uintptr:
  14446. fastpathTV.DecMapInt32UintptrV(v, false, d)
  14447. case *map[int32]uintptr:
  14448. if v2, changed2 := fastpathTV.DecMapInt32UintptrV(*v, true, d); changed2 {
  14449. *v = v2
  14450. }
  14451. case map[int32]int:
  14452. fastpathTV.DecMapInt32IntV(v, false, d)
  14453. case *map[int32]int:
  14454. if v2, changed2 := fastpathTV.DecMapInt32IntV(*v, true, d); changed2 {
  14455. *v = v2
  14456. }
  14457. case map[int32]int8:
  14458. fastpathTV.DecMapInt32Int8V(v, false, d)
  14459. case *map[int32]int8:
  14460. if v2, changed2 := fastpathTV.DecMapInt32Int8V(*v, true, d); changed2 {
  14461. *v = v2
  14462. }
  14463. case map[int32]int16:
  14464. fastpathTV.DecMapInt32Int16V(v, false, d)
  14465. case *map[int32]int16:
  14466. if v2, changed2 := fastpathTV.DecMapInt32Int16V(*v, true, d); changed2 {
  14467. *v = v2
  14468. }
  14469. case map[int32]int32:
  14470. fastpathTV.DecMapInt32Int32V(v, false, d)
  14471. case *map[int32]int32:
  14472. if v2, changed2 := fastpathTV.DecMapInt32Int32V(*v, true, d); changed2 {
  14473. *v = v2
  14474. }
  14475. case map[int32]int64:
  14476. fastpathTV.DecMapInt32Int64V(v, false, d)
  14477. case *map[int32]int64:
  14478. if v2, changed2 := fastpathTV.DecMapInt32Int64V(*v, true, d); changed2 {
  14479. *v = v2
  14480. }
  14481. case map[int32]float32:
  14482. fastpathTV.DecMapInt32Float32V(v, false, d)
  14483. case *map[int32]float32:
  14484. if v2, changed2 := fastpathTV.DecMapInt32Float32V(*v, true, d); changed2 {
  14485. *v = v2
  14486. }
  14487. case map[int32]float64:
  14488. fastpathTV.DecMapInt32Float64V(v, false, d)
  14489. case *map[int32]float64:
  14490. if v2, changed2 := fastpathTV.DecMapInt32Float64V(*v, true, d); changed2 {
  14491. *v = v2
  14492. }
  14493. case map[int32]bool:
  14494. fastpathTV.DecMapInt32BoolV(v, false, d)
  14495. case *map[int32]bool:
  14496. if v2, changed2 := fastpathTV.DecMapInt32BoolV(*v, true, d); changed2 {
  14497. *v = v2
  14498. }
  14499. case []int64:
  14500. fastpathTV.DecSliceInt64V(v, false, d)
  14501. case *[]int64:
  14502. if v2, changed2 := fastpathTV.DecSliceInt64V(*v, true, d); changed2 {
  14503. *v = v2
  14504. }
  14505. case map[int64]interface{}:
  14506. fastpathTV.DecMapInt64IntfV(v, false, d)
  14507. case *map[int64]interface{}:
  14508. if v2, changed2 := fastpathTV.DecMapInt64IntfV(*v, true, d); changed2 {
  14509. *v = v2
  14510. }
  14511. case map[int64]string:
  14512. fastpathTV.DecMapInt64StringV(v, false, d)
  14513. case *map[int64]string:
  14514. if v2, changed2 := fastpathTV.DecMapInt64StringV(*v, true, d); changed2 {
  14515. *v = v2
  14516. }
  14517. case map[int64]uint:
  14518. fastpathTV.DecMapInt64UintV(v, false, d)
  14519. case *map[int64]uint:
  14520. if v2, changed2 := fastpathTV.DecMapInt64UintV(*v, true, d); changed2 {
  14521. *v = v2
  14522. }
  14523. case map[int64]uint8:
  14524. fastpathTV.DecMapInt64Uint8V(v, false, d)
  14525. case *map[int64]uint8:
  14526. if v2, changed2 := fastpathTV.DecMapInt64Uint8V(*v, true, d); changed2 {
  14527. *v = v2
  14528. }
  14529. case map[int64]uint16:
  14530. fastpathTV.DecMapInt64Uint16V(v, false, d)
  14531. case *map[int64]uint16:
  14532. if v2, changed2 := fastpathTV.DecMapInt64Uint16V(*v, true, d); changed2 {
  14533. *v = v2
  14534. }
  14535. case map[int64]uint32:
  14536. fastpathTV.DecMapInt64Uint32V(v, false, d)
  14537. case *map[int64]uint32:
  14538. if v2, changed2 := fastpathTV.DecMapInt64Uint32V(*v, true, d); changed2 {
  14539. *v = v2
  14540. }
  14541. case map[int64]uint64:
  14542. fastpathTV.DecMapInt64Uint64V(v, false, d)
  14543. case *map[int64]uint64:
  14544. if v2, changed2 := fastpathTV.DecMapInt64Uint64V(*v, true, d); changed2 {
  14545. *v = v2
  14546. }
  14547. case map[int64]uintptr:
  14548. fastpathTV.DecMapInt64UintptrV(v, false, d)
  14549. case *map[int64]uintptr:
  14550. if v2, changed2 := fastpathTV.DecMapInt64UintptrV(*v, true, d); changed2 {
  14551. *v = v2
  14552. }
  14553. case map[int64]int:
  14554. fastpathTV.DecMapInt64IntV(v, false, d)
  14555. case *map[int64]int:
  14556. if v2, changed2 := fastpathTV.DecMapInt64IntV(*v, true, d); changed2 {
  14557. *v = v2
  14558. }
  14559. case map[int64]int8:
  14560. fastpathTV.DecMapInt64Int8V(v, false, d)
  14561. case *map[int64]int8:
  14562. if v2, changed2 := fastpathTV.DecMapInt64Int8V(*v, true, d); changed2 {
  14563. *v = v2
  14564. }
  14565. case map[int64]int16:
  14566. fastpathTV.DecMapInt64Int16V(v, false, d)
  14567. case *map[int64]int16:
  14568. if v2, changed2 := fastpathTV.DecMapInt64Int16V(*v, true, d); changed2 {
  14569. *v = v2
  14570. }
  14571. case map[int64]int32:
  14572. fastpathTV.DecMapInt64Int32V(v, false, d)
  14573. case *map[int64]int32:
  14574. if v2, changed2 := fastpathTV.DecMapInt64Int32V(*v, true, d); changed2 {
  14575. *v = v2
  14576. }
  14577. case map[int64]int64:
  14578. fastpathTV.DecMapInt64Int64V(v, false, d)
  14579. case *map[int64]int64:
  14580. if v2, changed2 := fastpathTV.DecMapInt64Int64V(*v, true, d); changed2 {
  14581. *v = v2
  14582. }
  14583. case map[int64]float32:
  14584. fastpathTV.DecMapInt64Float32V(v, false, d)
  14585. case *map[int64]float32:
  14586. if v2, changed2 := fastpathTV.DecMapInt64Float32V(*v, true, d); changed2 {
  14587. *v = v2
  14588. }
  14589. case map[int64]float64:
  14590. fastpathTV.DecMapInt64Float64V(v, false, d)
  14591. case *map[int64]float64:
  14592. if v2, changed2 := fastpathTV.DecMapInt64Float64V(*v, true, d); changed2 {
  14593. *v = v2
  14594. }
  14595. case map[int64]bool:
  14596. fastpathTV.DecMapInt64BoolV(v, false, d)
  14597. case *map[int64]bool:
  14598. if v2, changed2 := fastpathTV.DecMapInt64BoolV(*v, true, d); changed2 {
  14599. *v = v2
  14600. }
  14601. case []bool:
  14602. fastpathTV.DecSliceBoolV(v, false, d)
  14603. case *[]bool:
  14604. if v2, changed2 := fastpathTV.DecSliceBoolV(*v, true, d); changed2 {
  14605. *v = v2
  14606. }
  14607. case map[bool]interface{}:
  14608. fastpathTV.DecMapBoolIntfV(v, false, d)
  14609. case *map[bool]interface{}:
  14610. if v2, changed2 := fastpathTV.DecMapBoolIntfV(*v, true, d); changed2 {
  14611. *v = v2
  14612. }
  14613. case map[bool]string:
  14614. fastpathTV.DecMapBoolStringV(v, false, d)
  14615. case *map[bool]string:
  14616. if v2, changed2 := fastpathTV.DecMapBoolStringV(*v, true, d); changed2 {
  14617. *v = v2
  14618. }
  14619. case map[bool]uint:
  14620. fastpathTV.DecMapBoolUintV(v, false, d)
  14621. case *map[bool]uint:
  14622. if v2, changed2 := fastpathTV.DecMapBoolUintV(*v, true, d); changed2 {
  14623. *v = v2
  14624. }
  14625. case map[bool]uint8:
  14626. fastpathTV.DecMapBoolUint8V(v, false, d)
  14627. case *map[bool]uint8:
  14628. if v2, changed2 := fastpathTV.DecMapBoolUint8V(*v, true, d); changed2 {
  14629. *v = v2
  14630. }
  14631. case map[bool]uint16:
  14632. fastpathTV.DecMapBoolUint16V(v, false, d)
  14633. case *map[bool]uint16:
  14634. if v2, changed2 := fastpathTV.DecMapBoolUint16V(*v, true, d); changed2 {
  14635. *v = v2
  14636. }
  14637. case map[bool]uint32:
  14638. fastpathTV.DecMapBoolUint32V(v, false, d)
  14639. case *map[bool]uint32:
  14640. if v2, changed2 := fastpathTV.DecMapBoolUint32V(*v, true, d); changed2 {
  14641. *v = v2
  14642. }
  14643. case map[bool]uint64:
  14644. fastpathTV.DecMapBoolUint64V(v, false, d)
  14645. case *map[bool]uint64:
  14646. if v2, changed2 := fastpathTV.DecMapBoolUint64V(*v, true, d); changed2 {
  14647. *v = v2
  14648. }
  14649. case map[bool]uintptr:
  14650. fastpathTV.DecMapBoolUintptrV(v, false, d)
  14651. case *map[bool]uintptr:
  14652. if v2, changed2 := fastpathTV.DecMapBoolUintptrV(*v, true, d); changed2 {
  14653. *v = v2
  14654. }
  14655. case map[bool]int:
  14656. fastpathTV.DecMapBoolIntV(v, false, d)
  14657. case *map[bool]int:
  14658. if v2, changed2 := fastpathTV.DecMapBoolIntV(*v, true, d); changed2 {
  14659. *v = v2
  14660. }
  14661. case map[bool]int8:
  14662. fastpathTV.DecMapBoolInt8V(v, false, d)
  14663. case *map[bool]int8:
  14664. if v2, changed2 := fastpathTV.DecMapBoolInt8V(*v, true, d); changed2 {
  14665. *v = v2
  14666. }
  14667. case map[bool]int16:
  14668. fastpathTV.DecMapBoolInt16V(v, false, d)
  14669. case *map[bool]int16:
  14670. if v2, changed2 := fastpathTV.DecMapBoolInt16V(*v, true, d); changed2 {
  14671. *v = v2
  14672. }
  14673. case map[bool]int32:
  14674. fastpathTV.DecMapBoolInt32V(v, false, d)
  14675. case *map[bool]int32:
  14676. if v2, changed2 := fastpathTV.DecMapBoolInt32V(*v, true, d); changed2 {
  14677. *v = v2
  14678. }
  14679. case map[bool]int64:
  14680. fastpathTV.DecMapBoolInt64V(v, false, d)
  14681. case *map[bool]int64:
  14682. if v2, changed2 := fastpathTV.DecMapBoolInt64V(*v, true, d); changed2 {
  14683. *v = v2
  14684. }
  14685. case map[bool]float32:
  14686. fastpathTV.DecMapBoolFloat32V(v, false, d)
  14687. case *map[bool]float32:
  14688. if v2, changed2 := fastpathTV.DecMapBoolFloat32V(*v, true, d); changed2 {
  14689. *v = v2
  14690. }
  14691. case map[bool]float64:
  14692. fastpathTV.DecMapBoolFloat64V(v, false, d)
  14693. case *map[bool]float64:
  14694. if v2, changed2 := fastpathTV.DecMapBoolFloat64V(*v, true, d); changed2 {
  14695. *v = v2
  14696. }
  14697. case map[bool]bool:
  14698. fastpathTV.DecMapBoolBoolV(v, false, d)
  14699. case *map[bool]bool:
  14700. if v2, changed2 := fastpathTV.DecMapBoolBoolV(*v, true, d); changed2 {
  14701. *v = v2
  14702. }
  14703. default:
  14704. _ = v // TODO: workaround https://github.com/golang/go/issues/12927 (remove after go 1.6 release)
  14705. return false
  14706. }
  14707. return true
  14708. }
  14709. func fastpathDecodeSetZeroTypeSwitch(iv interface{}, d *Decoder) bool {
  14710. switch v := iv.(type) {
  14711. case *[]interface{}:
  14712. *v = nil
  14713. case *map[interface{}]interface{}:
  14714. *v = nil
  14715. case *map[interface{}]string:
  14716. *v = nil
  14717. case *map[interface{}]uint:
  14718. *v = nil
  14719. case *map[interface{}]uint8:
  14720. *v = nil
  14721. case *map[interface{}]uint16:
  14722. *v = nil
  14723. case *map[interface{}]uint32:
  14724. *v = nil
  14725. case *map[interface{}]uint64:
  14726. *v = nil
  14727. case *map[interface{}]uintptr:
  14728. *v = nil
  14729. case *map[interface{}]int:
  14730. *v = nil
  14731. case *map[interface{}]int8:
  14732. *v = nil
  14733. case *map[interface{}]int16:
  14734. *v = nil
  14735. case *map[interface{}]int32:
  14736. *v = nil
  14737. case *map[interface{}]int64:
  14738. *v = nil
  14739. case *map[interface{}]float32:
  14740. *v = nil
  14741. case *map[interface{}]float64:
  14742. *v = nil
  14743. case *map[interface{}]bool:
  14744. *v = nil
  14745. case *[]string:
  14746. *v = nil
  14747. case *map[string]interface{}:
  14748. *v = nil
  14749. case *map[string]string:
  14750. *v = nil
  14751. case *map[string]uint:
  14752. *v = nil
  14753. case *map[string]uint8:
  14754. *v = nil
  14755. case *map[string]uint16:
  14756. *v = nil
  14757. case *map[string]uint32:
  14758. *v = nil
  14759. case *map[string]uint64:
  14760. *v = nil
  14761. case *map[string]uintptr:
  14762. *v = nil
  14763. case *map[string]int:
  14764. *v = nil
  14765. case *map[string]int8:
  14766. *v = nil
  14767. case *map[string]int16:
  14768. *v = nil
  14769. case *map[string]int32:
  14770. *v = nil
  14771. case *map[string]int64:
  14772. *v = nil
  14773. case *map[string]float32:
  14774. *v = nil
  14775. case *map[string]float64:
  14776. *v = nil
  14777. case *map[string]bool:
  14778. *v = nil
  14779. case *[]float32:
  14780. *v = nil
  14781. case *map[float32]interface{}:
  14782. *v = nil
  14783. case *map[float32]string:
  14784. *v = nil
  14785. case *map[float32]uint:
  14786. *v = nil
  14787. case *map[float32]uint8:
  14788. *v = nil
  14789. case *map[float32]uint16:
  14790. *v = nil
  14791. case *map[float32]uint32:
  14792. *v = nil
  14793. case *map[float32]uint64:
  14794. *v = nil
  14795. case *map[float32]uintptr:
  14796. *v = nil
  14797. case *map[float32]int:
  14798. *v = nil
  14799. case *map[float32]int8:
  14800. *v = nil
  14801. case *map[float32]int16:
  14802. *v = nil
  14803. case *map[float32]int32:
  14804. *v = nil
  14805. case *map[float32]int64:
  14806. *v = nil
  14807. case *map[float32]float32:
  14808. *v = nil
  14809. case *map[float32]float64:
  14810. *v = nil
  14811. case *map[float32]bool:
  14812. *v = nil
  14813. case *[]float64:
  14814. *v = nil
  14815. case *map[float64]interface{}:
  14816. *v = nil
  14817. case *map[float64]string:
  14818. *v = nil
  14819. case *map[float64]uint:
  14820. *v = nil
  14821. case *map[float64]uint8:
  14822. *v = nil
  14823. case *map[float64]uint16:
  14824. *v = nil
  14825. case *map[float64]uint32:
  14826. *v = nil
  14827. case *map[float64]uint64:
  14828. *v = nil
  14829. case *map[float64]uintptr:
  14830. *v = nil
  14831. case *map[float64]int:
  14832. *v = nil
  14833. case *map[float64]int8:
  14834. *v = nil
  14835. case *map[float64]int16:
  14836. *v = nil
  14837. case *map[float64]int32:
  14838. *v = nil
  14839. case *map[float64]int64:
  14840. *v = nil
  14841. case *map[float64]float32:
  14842. *v = nil
  14843. case *map[float64]float64:
  14844. *v = nil
  14845. case *map[float64]bool:
  14846. *v = nil
  14847. case *[]uint:
  14848. *v = nil
  14849. case *map[uint]interface{}:
  14850. *v = nil
  14851. case *map[uint]string:
  14852. *v = nil
  14853. case *map[uint]uint:
  14854. *v = nil
  14855. case *map[uint]uint8:
  14856. *v = nil
  14857. case *map[uint]uint16:
  14858. *v = nil
  14859. case *map[uint]uint32:
  14860. *v = nil
  14861. case *map[uint]uint64:
  14862. *v = nil
  14863. case *map[uint]uintptr:
  14864. *v = nil
  14865. case *map[uint]int:
  14866. *v = nil
  14867. case *map[uint]int8:
  14868. *v = nil
  14869. case *map[uint]int16:
  14870. *v = nil
  14871. case *map[uint]int32:
  14872. *v = nil
  14873. case *map[uint]int64:
  14874. *v = nil
  14875. case *map[uint]float32:
  14876. *v = nil
  14877. case *map[uint]float64:
  14878. *v = nil
  14879. case *map[uint]bool:
  14880. *v = nil
  14881. case *map[uint8]interface{}:
  14882. *v = nil
  14883. case *map[uint8]string:
  14884. *v = nil
  14885. case *map[uint8]uint:
  14886. *v = nil
  14887. case *map[uint8]uint8:
  14888. *v = nil
  14889. case *map[uint8]uint16:
  14890. *v = nil
  14891. case *map[uint8]uint32:
  14892. *v = nil
  14893. case *map[uint8]uint64:
  14894. *v = nil
  14895. case *map[uint8]uintptr:
  14896. *v = nil
  14897. case *map[uint8]int:
  14898. *v = nil
  14899. case *map[uint8]int8:
  14900. *v = nil
  14901. case *map[uint8]int16:
  14902. *v = nil
  14903. case *map[uint8]int32:
  14904. *v = nil
  14905. case *map[uint8]int64:
  14906. *v = nil
  14907. case *map[uint8]float32:
  14908. *v = nil
  14909. case *map[uint8]float64:
  14910. *v = nil
  14911. case *map[uint8]bool:
  14912. *v = nil
  14913. case *[]uint16:
  14914. *v = nil
  14915. case *map[uint16]interface{}:
  14916. *v = nil
  14917. case *map[uint16]string:
  14918. *v = nil
  14919. case *map[uint16]uint:
  14920. *v = nil
  14921. case *map[uint16]uint8:
  14922. *v = nil
  14923. case *map[uint16]uint16:
  14924. *v = nil
  14925. case *map[uint16]uint32:
  14926. *v = nil
  14927. case *map[uint16]uint64:
  14928. *v = nil
  14929. case *map[uint16]uintptr:
  14930. *v = nil
  14931. case *map[uint16]int:
  14932. *v = nil
  14933. case *map[uint16]int8:
  14934. *v = nil
  14935. case *map[uint16]int16:
  14936. *v = nil
  14937. case *map[uint16]int32:
  14938. *v = nil
  14939. case *map[uint16]int64:
  14940. *v = nil
  14941. case *map[uint16]float32:
  14942. *v = nil
  14943. case *map[uint16]float64:
  14944. *v = nil
  14945. case *map[uint16]bool:
  14946. *v = nil
  14947. case *[]uint32:
  14948. *v = nil
  14949. case *map[uint32]interface{}:
  14950. *v = nil
  14951. case *map[uint32]string:
  14952. *v = nil
  14953. case *map[uint32]uint:
  14954. *v = nil
  14955. case *map[uint32]uint8:
  14956. *v = nil
  14957. case *map[uint32]uint16:
  14958. *v = nil
  14959. case *map[uint32]uint32:
  14960. *v = nil
  14961. case *map[uint32]uint64:
  14962. *v = nil
  14963. case *map[uint32]uintptr:
  14964. *v = nil
  14965. case *map[uint32]int:
  14966. *v = nil
  14967. case *map[uint32]int8:
  14968. *v = nil
  14969. case *map[uint32]int16:
  14970. *v = nil
  14971. case *map[uint32]int32:
  14972. *v = nil
  14973. case *map[uint32]int64:
  14974. *v = nil
  14975. case *map[uint32]float32:
  14976. *v = nil
  14977. case *map[uint32]float64:
  14978. *v = nil
  14979. case *map[uint32]bool:
  14980. *v = nil
  14981. case *[]uint64:
  14982. *v = nil
  14983. case *map[uint64]interface{}:
  14984. *v = nil
  14985. case *map[uint64]string:
  14986. *v = nil
  14987. case *map[uint64]uint:
  14988. *v = nil
  14989. case *map[uint64]uint8:
  14990. *v = nil
  14991. case *map[uint64]uint16:
  14992. *v = nil
  14993. case *map[uint64]uint32:
  14994. *v = nil
  14995. case *map[uint64]uint64:
  14996. *v = nil
  14997. case *map[uint64]uintptr:
  14998. *v = nil
  14999. case *map[uint64]int:
  15000. *v = nil
  15001. case *map[uint64]int8:
  15002. *v = nil
  15003. case *map[uint64]int16:
  15004. *v = nil
  15005. case *map[uint64]int32:
  15006. *v = nil
  15007. case *map[uint64]int64:
  15008. *v = nil
  15009. case *map[uint64]float32:
  15010. *v = nil
  15011. case *map[uint64]float64:
  15012. *v = nil
  15013. case *map[uint64]bool:
  15014. *v = nil
  15015. case *[]uintptr:
  15016. *v = nil
  15017. case *map[uintptr]interface{}:
  15018. *v = nil
  15019. case *map[uintptr]string:
  15020. *v = nil
  15021. case *map[uintptr]uint:
  15022. *v = nil
  15023. case *map[uintptr]uint8:
  15024. *v = nil
  15025. case *map[uintptr]uint16:
  15026. *v = nil
  15027. case *map[uintptr]uint32:
  15028. *v = nil
  15029. case *map[uintptr]uint64:
  15030. *v = nil
  15031. case *map[uintptr]uintptr:
  15032. *v = nil
  15033. case *map[uintptr]int:
  15034. *v = nil
  15035. case *map[uintptr]int8:
  15036. *v = nil
  15037. case *map[uintptr]int16:
  15038. *v = nil
  15039. case *map[uintptr]int32:
  15040. *v = nil
  15041. case *map[uintptr]int64:
  15042. *v = nil
  15043. case *map[uintptr]float32:
  15044. *v = nil
  15045. case *map[uintptr]float64:
  15046. *v = nil
  15047. case *map[uintptr]bool:
  15048. *v = nil
  15049. case *[]int:
  15050. *v = nil
  15051. case *map[int]interface{}:
  15052. *v = nil
  15053. case *map[int]string:
  15054. *v = nil
  15055. case *map[int]uint:
  15056. *v = nil
  15057. case *map[int]uint8:
  15058. *v = nil
  15059. case *map[int]uint16:
  15060. *v = nil
  15061. case *map[int]uint32:
  15062. *v = nil
  15063. case *map[int]uint64:
  15064. *v = nil
  15065. case *map[int]uintptr:
  15066. *v = nil
  15067. case *map[int]int:
  15068. *v = nil
  15069. case *map[int]int8:
  15070. *v = nil
  15071. case *map[int]int16:
  15072. *v = nil
  15073. case *map[int]int32:
  15074. *v = nil
  15075. case *map[int]int64:
  15076. *v = nil
  15077. case *map[int]float32:
  15078. *v = nil
  15079. case *map[int]float64:
  15080. *v = nil
  15081. case *map[int]bool:
  15082. *v = nil
  15083. case *[]int8:
  15084. *v = nil
  15085. case *map[int8]interface{}:
  15086. *v = nil
  15087. case *map[int8]string:
  15088. *v = nil
  15089. case *map[int8]uint:
  15090. *v = nil
  15091. case *map[int8]uint8:
  15092. *v = nil
  15093. case *map[int8]uint16:
  15094. *v = nil
  15095. case *map[int8]uint32:
  15096. *v = nil
  15097. case *map[int8]uint64:
  15098. *v = nil
  15099. case *map[int8]uintptr:
  15100. *v = nil
  15101. case *map[int8]int:
  15102. *v = nil
  15103. case *map[int8]int8:
  15104. *v = nil
  15105. case *map[int8]int16:
  15106. *v = nil
  15107. case *map[int8]int32:
  15108. *v = nil
  15109. case *map[int8]int64:
  15110. *v = nil
  15111. case *map[int8]float32:
  15112. *v = nil
  15113. case *map[int8]float64:
  15114. *v = nil
  15115. case *map[int8]bool:
  15116. *v = nil
  15117. case *[]int16:
  15118. *v = nil
  15119. case *map[int16]interface{}:
  15120. *v = nil
  15121. case *map[int16]string:
  15122. *v = nil
  15123. case *map[int16]uint:
  15124. *v = nil
  15125. case *map[int16]uint8:
  15126. *v = nil
  15127. case *map[int16]uint16:
  15128. *v = nil
  15129. case *map[int16]uint32:
  15130. *v = nil
  15131. case *map[int16]uint64:
  15132. *v = nil
  15133. case *map[int16]uintptr:
  15134. *v = nil
  15135. case *map[int16]int:
  15136. *v = nil
  15137. case *map[int16]int8:
  15138. *v = nil
  15139. case *map[int16]int16:
  15140. *v = nil
  15141. case *map[int16]int32:
  15142. *v = nil
  15143. case *map[int16]int64:
  15144. *v = nil
  15145. case *map[int16]float32:
  15146. *v = nil
  15147. case *map[int16]float64:
  15148. *v = nil
  15149. case *map[int16]bool:
  15150. *v = nil
  15151. case *[]int32:
  15152. *v = nil
  15153. case *map[int32]interface{}:
  15154. *v = nil
  15155. case *map[int32]string:
  15156. *v = nil
  15157. case *map[int32]uint:
  15158. *v = nil
  15159. case *map[int32]uint8:
  15160. *v = nil
  15161. case *map[int32]uint16:
  15162. *v = nil
  15163. case *map[int32]uint32:
  15164. *v = nil
  15165. case *map[int32]uint64:
  15166. *v = nil
  15167. case *map[int32]uintptr:
  15168. *v = nil
  15169. case *map[int32]int:
  15170. *v = nil
  15171. case *map[int32]int8:
  15172. *v = nil
  15173. case *map[int32]int16:
  15174. *v = nil
  15175. case *map[int32]int32:
  15176. *v = nil
  15177. case *map[int32]int64:
  15178. *v = nil
  15179. case *map[int32]float32:
  15180. *v = nil
  15181. case *map[int32]float64:
  15182. *v = nil
  15183. case *map[int32]bool:
  15184. *v = nil
  15185. case *[]int64:
  15186. *v = nil
  15187. case *map[int64]interface{}:
  15188. *v = nil
  15189. case *map[int64]string:
  15190. *v = nil
  15191. case *map[int64]uint:
  15192. *v = nil
  15193. case *map[int64]uint8:
  15194. *v = nil
  15195. case *map[int64]uint16:
  15196. *v = nil
  15197. case *map[int64]uint32:
  15198. *v = nil
  15199. case *map[int64]uint64:
  15200. *v = nil
  15201. case *map[int64]uintptr:
  15202. *v = nil
  15203. case *map[int64]int:
  15204. *v = nil
  15205. case *map[int64]int8:
  15206. *v = nil
  15207. case *map[int64]int16:
  15208. *v = nil
  15209. case *map[int64]int32:
  15210. *v = nil
  15211. case *map[int64]int64:
  15212. *v = nil
  15213. case *map[int64]float32:
  15214. *v = nil
  15215. case *map[int64]float64:
  15216. *v = nil
  15217. case *map[int64]bool:
  15218. *v = nil
  15219. case *[]bool:
  15220. *v = nil
  15221. case *map[bool]interface{}:
  15222. *v = nil
  15223. case *map[bool]string:
  15224. *v = nil
  15225. case *map[bool]uint:
  15226. *v = nil
  15227. case *map[bool]uint8:
  15228. *v = nil
  15229. case *map[bool]uint16:
  15230. *v = nil
  15231. case *map[bool]uint32:
  15232. *v = nil
  15233. case *map[bool]uint64:
  15234. *v = nil
  15235. case *map[bool]uintptr:
  15236. *v = nil
  15237. case *map[bool]int:
  15238. *v = nil
  15239. case *map[bool]int8:
  15240. *v = nil
  15241. case *map[bool]int16:
  15242. *v = nil
  15243. case *map[bool]int32:
  15244. *v = nil
  15245. case *map[bool]int64:
  15246. *v = nil
  15247. case *map[bool]float32:
  15248. *v = nil
  15249. case *map[bool]float64:
  15250. *v = nil
  15251. case *map[bool]bool:
  15252. *v = nil
  15253. default:
  15254. _ = v // TODO: workaround https://github.com/golang/go/issues/12927 (remove after go 1.6 release)
  15255. return false
  15256. }
  15257. return true
  15258. }
  15259. // -- -- fast path functions
  15260. func (d *Decoder) fastpathDecSliceIntfR(f *codecFnInfo, rv reflect.Value) {
  15261. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15262. var vp = rv2i(rv).(*[]interface{})
  15263. if v, changed := fastpathTV.DecSliceIntfV(*vp, !array, d); changed {
  15264. *vp = v
  15265. }
  15266. } else {
  15267. fastpathTV.DecSliceIntfV(rv2i(rv).([]interface{}), !array, d)
  15268. }
  15269. }
  15270. func (f fastpathT) DecSliceIntfX(vp *[]interface{}, d *Decoder) {
  15271. if v, changed := f.DecSliceIntfV(*vp, true, d); changed {
  15272. *vp = v
  15273. }
  15274. }
  15275. func (_ fastpathT) DecSliceIntfV(v []interface{}, canChange bool, d *Decoder) (_ []interface{}, changed bool) {
  15276. dd := d.d
  15277. slh, containerLenS := d.decSliceHelperStart()
  15278. if containerLenS == 0 {
  15279. if canChange {
  15280. if v == nil {
  15281. v = []interface{}{}
  15282. } else if len(v) != 0 {
  15283. v = v[:0]
  15284. }
  15285. changed = true
  15286. }
  15287. slh.End()
  15288. return v, changed
  15289. }
  15290. hasLen := containerLenS > 0
  15291. var xlen int
  15292. if hasLen && canChange {
  15293. if containerLenS > cap(v) {
  15294. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 16)
  15295. if xlen <= cap(v) {
  15296. v = v[:xlen]
  15297. } else {
  15298. v = make([]interface{}, xlen)
  15299. }
  15300. changed = true
  15301. } else if containerLenS != len(v) {
  15302. v = v[:containerLenS]
  15303. changed = true
  15304. }
  15305. }
  15306. j := 0
  15307. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15308. if j == 0 && len(v) == 0 {
  15309. if hasLen {
  15310. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 16)
  15311. } else {
  15312. xlen = 8
  15313. }
  15314. v = make([]interface{}, xlen)
  15315. changed = true
  15316. }
  15317. // if indefinite, etc, then expand the slice if necessary
  15318. var decodeIntoBlank bool
  15319. if j >= len(v) {
  15320. if canChange {
  15321. v = append(v, nil)
  15322. changed = true
  15323. } else {
  15324. d.arrayCannotExpand(len(v), j+1)
  15325. decodeIntoBlank = true
  15326. }
  15327. }
  15328. slh.ElemContainerState(j)
  15329. if decodeIntoBlank {
  15330. d.swallow()
  15331. } else {
  15332. d.decode(&v[j])
  15333. }
  15334. }
  15335. if canChange {
  15336. if j < len(v) {
  15337. v = v[:j]
  15338. changed = true
  15339. } else if j == 0 && v == nil {
  15340. v = make([]interface{}, 0)
  15341. changed = true
  15342. }
  15343. }
  15344. slh.End()
  15345. return v, changed
  15346. }
  15347. func (d *Decoder) fastpathDecSliceStringR(f *codecFnInfo, rv reflect.Value) {
  15348. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15349. var vp = rv2i(rv).(*[]string)
  15350. if v, changed := fastpathTV.DecSliceStringV(*vp, !array, d); changed {
  15351. *vp = v
  15352. }
  15353. } else {
  15354. fastpathTV.DecSliceStringV(rv2i(rv).([]string), !array, d)
  15355. }
  15356. }
  15357. func (f fastpathT) DecSliceStringX(vp *[]string, d *Decoder) {
  15358. if v, changed := f.DecSliceStringV(*vp, true, d); changed {
  15359. *vp = v
  15360. }
  15361. }
  15362. func (_ fastpathT) DecSliceStringV(v []string, canChange bool, d *Decoder) (_ []string, changed bool) {
  15363. dd := d.d
  15364. slh, containerLenS := d.decSliceHelperStart()
  15365. if containerLenS == 0 {
  15366. if canChange {
  15367. if v == nil {
  15368. v = []string{}
  15369. } else if len(v) != 0 {
  15370. v = v[:0]
  15371. }
  15372. changed = true
  15373. }
  15374. slh.End()
  15375. return v, changed
  15376. }
  15377. hasLen := containerLenS > 0
  15378. var xlen int
  15379. if hasLen && canChange {
  15380. if containerLenS > cap(v) {
  15381. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 16)
  15382. if xlen <= cap(v) {
  15383. v = v[:xlen]
  15384. } else {
  15385. v = make([]string, xlen)
  15386. }
  15387. changed = true
  15388. } else if containerLenS != len(v) {
  15389. v = v[:containerLenS]
  15390. changed = true
  15391. }
  15392. }
  15393. j := 0
  15394. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15395. if j == 0 && len(v) == 0 {
  15396. if hasLen {
  15397. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 16)
  15398. } else {
  15399. xlen = 8
  15400. }
  15401. v = make([]string, xlen)
  15402. changed = true
  15403. }
  15404. // if indefinite, etc, then expand the slice if necessary
  15405. var decodeIntoBlank bool
  15406. if j >= len(v) {
  15407. if canChange {
  15408. v = append(v, "")
  15409. changed = true
  15410. } else {
  15411. d.arrayCannotExpand(len(v), j+1)
  15412. decodeIntoBlank = true
  15413. }
  15414. }
  15415. slh.ElemContainerState(j)
  15416. if decodeIntoBlank {
  15417. d.swallow()
  15418. } else {
  15419. v[j] = dd.DecodeString()
  15420. }
  15421. }
  15422. if canChange {
  15423. if j < len(v) {
  15424. v = v[:j]
  15425. changed = true
  15426. } else if j == 0 && v == nil {
  15427. v = make([]string, 0)
  15428. changed = true
  15429. }
  15430. }
  15431. slh.End()
  15432. return v, changed
  15433. }
  15434. func (d *Decoder) fastpathDecSliceFloat32R(f *codecFnInfo, rv reflect.Value) {
  15435. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15436. var vp = rv2i(rv).(*[]float32)
  15437. if v, changed := fastpathTV.DecSliceFloat32V(*vp, !array, d); changed {
  15438. *vp = v
  15439. }
  15440. } else {
  15441. fastpathTV.DecSliceFloat32V(rv2i(rv).([]float32), !array, d)
  15442. }
  15443. }
  15444. func (f fastpathT) DecSliceFloat32X(vp *[]float32, d *Decoder) {
  15445. if v, changed := f.DecSliceFloat32V(*vp, true, d); changed {
  15446. *vp = v
  15447. }
  15448. }
  15449. func (_ fastpathT) DecSliceFloat32V(v []float32, canChange bool, d *Decoder) (_ []float32, changed bool) {
  15450. dd := d.d
  15451. slh, containerLenS := d.decSliceHelperStart()
  15452. if containerLenS == 0 {
  15453. if canChange {
  15454. if v == nil {
  15455. v = []float32{}
  15456. } else if len(v) != 0 {
  15457. v = v[:0]
  15458. }
  15459. changed = true
  15460. }
  15461. slh.End()
  15462. return v, changed
  15463. }
  15464. hasLen := containerLenS > 0
  15465. var xlen int
  15466. if hasLen && canChange {
  15467. if containerLenS > cap(v) {
  15468. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 4)
  15469. if xlen <= cap(v) {
  15470. v = v[:xlen]
  15471. } else {
  15472. v = make([]float32, xlen)
  15473. }
  15474. changed = true
  15475. } else if containerLenS != len(v) {
  15476. v = v[:containerLenS]
  15477. changed = true
  15478. }
  15479. }
  15480. j := 0
  15481. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15482. if j == 0 && len(v) == 0 {
  15483. if hasLen {
  15484. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 4)
  15485. } else {
  15486. xlen = 8
  15487. }
  15488. v = make([]float32, xlen)
  15489. changed = true
  15490. }
  15491. // if indefinite, etc, then expand the slice if necessary
  15492. var decodeIntoBlank bool
  15493. if j >= len(v) {
  15494. if canChange {
  15495. v = append(v, 0)
  15496. changed = true
  15497. } else {
  15498. d.arrayCannotExpand(len(v), j+1)
  15499. decodeIntoBlank = true
  15500. }
  15501. }
  15502. slh.ElemContainerState(j)
  15503. if decodeIntoBlank {
  15504. d.swallow()
  15505. } else {
  15506. v[j] = float32(dd.DecodeFloat(true))
  15507. }
  15508. }
  15509. if canChange {
  15510. if j < len(v) {
  15511. v = v[:j]
  15512. changed = true
  15513. } else if j == 0 && v == nil {
  15514. v = make([]float32, 0)
  15515. changed = true
  15516. }
  15517. }
  15518. slh.End()
  15519. return v, changed
  15520. }
  15521. func (d *Decoder) fastpathDecSliceFloat64R(f *codecFnInfo, rv reflect.Value) {
  15522. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15523. var vp = rv2i(rv).(*[]float64)
  15524. if v, changed := fastpathTV.DecSliceFloat64V(*vp, !array, d); changed {
  15525. *vp = v
  15526. }
  15527. } else {
  15528. fastpathTV.DecSliceFloat64V(rv2i(rv).([]float64), !array, d)
  15529. }
  15530. }
  15531. func (f fastpathT) DecSliceFloat64X(vp *[]float64, d *Decoder) {
  15532. if v, changed := f.DecSliceFloat64V(*vp, true, d); changed {
  15533. *vp = v
  15534. }
  15535. }
  15536. func (_ fastpathT) DecSliceFloat64V(v []float64, canChange bool, d *Decoder) (_ []float64, changed bool) {
  15537. dd := d.d
  15538. slh, containerLenS := d.decSliceHelperStart()
  15539. if containerLenS == 0 {
  15540. if canChange {
  15541. if v == nil {
  15542. v = []float64{}
  15543. } else if len(v) != 0 {
  15544. v = v[:0]
  15545. }
  15546. changed = true
  15547. }
  15548. slh.End()
  15549. return v, changed
  15550. }
  15551. hasLen := containerLenS > 0
  15552. var xlen int
  15553. if hasLen && canChange {
  15554. if containerLenS > cap(v) {
  15555. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  15556. if xlen <= cap(v) {
  15557. v = v[:xlen]
  15558. } else {
  15559. v = make([]float64, xlen)
  15560. }
  15561. changed = true
  15562. } else if containerLenS != len(v) {
  15563. v = v[:containerLenS]
  15564. changed = true
  15565. }
  15566. }
  15567. j := 0
  15568. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15569. if j == 0 && len(v) == 0 {
  15570. if hasLen {
  15571. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  15572. } else {
  15573. xlen = 8
  15574. }
  15575. v = make([]float64, xlen)
  15576. changed = true
  15577. }
  15578. // if indefinite, etc, then expand the slice if necessary
  15579. var decodeIntoBlank bool
  15580. if j >= len(v) {
  15581. if canChange {
  15582. v = append(v, 0)
  15583. changed = true
  15584. } else {
  15585. d.arrayCannotExpand(len(v), j+1)
  15586. decodeIntoBlank = true
  15587. }
  15588. }
  15589. slh.ElemContainerState(j)
  15590. if decodeIntoBlank {
  15591. d.swallow()
  15592. } else {
  15593. v[j] = dd.DecodeFloat(false)
  15594. }
  15595. }
  15596. if canChange {
  15597. if j < len(v) {
  15598. v = v[:j]
  15599. changed = true
  15600. } else if j == 0 && v == nil {
  15601. v = make([]float64, 0)
  15602. changed = true
  15603. }
  15604. }
  15605. slh.End()
  15606. return v, changed
  15607. }
  15608. func (d *Decoder) fastpathDecSliceUintR(f *codecFnInfo, rv reflect.Value) {
  15609. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15610. var vp = rv2i(rv).(*[]uint)
  15611. if v, changed := fastpathTV.DecSliceUintV(*vp, !array, d); changed {
  15612. *vp = v
  15613. }
  15614. } else {
  15615. fastpathTV.DecSliceUintV(rv2i(rv).([]uint), !array, d)
  15616. }
  15617. }
  15618. func (f fastpathT) DecSliceUintX(vp *[]uint, d *Decoder) {
  15619. if v, changed := f.DecSliceUintV(*vp, true, d); changed {
  15620. *vp = v
  15621. }
  15622. }
  15623. func (_ fastpathT) DecSliceUintV(v []uint, canChange bool, d *Decoder) (_ []uint, changed bool) {
  15624. dd := d.d
  15625. slh, containerLenS := d.decSliceHelperStart()
  15626. if containerLenS == 0 {
  15627. if canChange {
  15628. if v == nil {
  15629. v = []uint{}
  15630. } else if len(v) != 0 {
  15631. v = v[:0]
  15632. }
  15633. changed = true
  15634. }
  15635. slh.End()
  15636. return v, changed
  15637. }
  15638. hasLen := containerLenS > 0
  15639. var xlen int
  15640. if hasLen && canChange {
  15641. if containerLenS > cap(v) {
  15642. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  15643. if xlen <= cap(v) {
  15644. v = v[:xlen]
  15645. } else {
  15646. v = make([]uint, xlen)
  15647. }
  15648. changed = true
  15649. } else if containerLenS != len(v) {
  15650. v = v[:containerLenS]
  15651. changed = true
  15652. }
  15653. }
  15654. j := 0
  15655. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15656. if j == 0 && len(v) == 0 {
  15657. if hasLen {
  15658. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  15659. } else {
  15660. xlen = 8
  15661. }
  15662. v = make([]uint, xlen)
  15663. changed = true
  15664. }
  15665. // if indefinite, etc, then expand the slice if necessary
  15666. var decodeIntoBlank bool
  15667. if j >= len(v) {
  15668. if canChange {
  15669. v = append(v, 0)
  15670. changed = true
  15671. } else {
  15672. d.arrayCannotExpand(len(v), j+1)
  15673. decodeIntoBlank = true
  15674. }
  15675. }
  15676. slh.ElemContainerState(j)
  15677. if decodeIntoBlank {
  15678. d.swallow()
  15679. } else {
  15680. v[j] = uint(dd.DecodeUint(uintBitsize))
  15681. }
  15682. }
  15683. if canChange {
  15684. if j < len(v) {
  15685. v = v[:j]
  15686. changed = true
  15687. } else if j == 0 && v == nil {
  15688. v = make([]uint, 0)
  15689. changed = true
  15690. }
  15691. }
  15692. slh.End()
  15693. return v, changed
  15694. }
  15695. func (d *Decoder) fastpathDecSliceUint16R(f *codecFnInfo, rv reflect.Value) {
  15696. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15697. var vp = rv2i(rv).(*[]uint16)
  15698. if v, changed := fastpathTV.DecSliceUint16V(*vp, !array, d); changed {
  15699. *vp = v
  15700. }
  15701. } else {
  15702. fastpathTV.DecSliceUint16V(rv2i(rv).([]uint16), !array, d)
  15703. }
  15704. }
  15705. func (f fastpathT) DecSliceUint16X(vp *[]uint16, d *Decoder) {
  15706. if v, changed := f.DecSliceUint16V(*vp, true, d); changed {
  15707. *vp = v
  15708. }
  15709. }
  15710. func (_ fastpathT) DecSliceUint16V(v []uint16, canChange bool, d *Decoder) (_ []uint16, changed bool) {
  15711. dd := d.d
  15712. slh, containerLenS := d.decSliceHelperStart()
  15713. if containerLenS == 0 {
  15714. if canChange {
  15715. if v == nil {
  15716. v = []uint16{}
  15717. } else if len(v) != 0 {
  15718. v = v[:0]
  15719. }
  15720. changed = true
  15721. }
  15722. slh.End()
  15723. return v, changed
  15724. }
  15725. hasLen := containerLenS > 0
  15726. var xlen int
  15727. if hasLen && canChange {
  15728. if containerLenS > cap(v) {
  15729. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 2)
  15730. if xlen <= cap(v) {
  15731. v = v[:xlen]
  15732. } else {
  15733. v = make([]uint16, xlen)
  15734. }
  15735. changed = true
  15736. } else if containerLenS != len(v) {
  15737. v = v[:containerLenS]
  15738. changed = true
  15739. }
  15740. }
  15741. j := 0
  15742. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15743. if j == 0 && len(v) == 0 {
  15744. if hasLen {
  15745. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 2)
  15746. } else {
  15747. xlen = 8
  15748. }
  15749. v = make([]uint16, xlen)
  15750. changed = true
  15751. }
  15752. // if indefinite, etc, then expand the slice if necessary
  15753. var decodeIntoBlank bool
  15754. if j >= len(v) {
  15755. if canChange {
  15756. v = append(v, 0)
  15757. changed = true
  15758. } else {
  15759. d.arrayCannotExpand(len(v), j+1)
  15760. decodeIntoBlank = true
  15761. }
  15762. }
  15763. slh.ElemContainerState(j)
  15764. if decodeIntoBlank {
  15765. d.swallow()
  15766. } else {
  15767. v[j] = uint16(dd.DecodeUint(16))
  15768. }
  15769. }
  15770. if canChange {
  15771. if j < len(v) {
  15772. v = v[:j]
  15773. changed = true
  15774. } else if j == 0 && v == nil {
  15775. v = make([]uint16, 0)
  15776. changed = true
  15777. }
  15778. }
  15779. slh.End()
  15780. return v, changed
  15781. }
  15782. func (d *Decoder) fastpathDecSliceUint32R(f *codecFnInfo, rv reflect.Value) {
  15783. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15784. var vp = rv2i(rv).(*[]uint32)
  15785. if v, changed := fastpathTV.DecSliceUint32V(*vp, !array, d); changed {
  15786. *vp = v
  15787. }
  15788. } else {
  15789. fastpathTV.DecSliceUint32V(rv2i(rv).([]uint32), !array, d)
  15790. }
  15791. }
  15792. func (f fastpathT) DecSliceUint32X(vp *[]uint32, d *Decoder) {
  15793. if v, changed := f.DecSliceUint32V(*vp, true, d); changed {
  15794. *vp = v
  15795. }
  15796. }
  15797. func (_ fastpathT) DecSliceUint32V(v []uint32, canChange bool, d *Decoder) (_ []uint32, changed bool) {
  15798. dd := d.d
  15799. slh, containerLenS := d.decSliceHelperStart()
  15800. if containerLenS == 0 {
  15801. if canChange {
  15802. if v == nil {
  15803. v = []uint32{}
  15804. } else if len(v) != 0 {
  15805. v = v[:0]
  15806. }
  15807. changed = true
  15808. }
  15809. slh.End()
  15810. return v, changed
  15811. }
  15812. hasLen := containerLenS > 0
  15813. var xlen int
  15814. if hasLen && canChange {
  15815. if containerLenS > cap(v) {
  15816. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 4)
  15817. if xlen <= cap(v) {
  15818. v = v[:xlen]
  15819. } else {
  15820. v = make([]uint32, xlen)
  15821. }
  15822. changed = true
  15823. } else if containerLenS != len(v) {
  15824. v = v[:containerLenS]
  15825. changed = true
  15826. }
  15827. }
  15828. j := 0
  15829. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15830. if j == 0 && len(v) == 0 {
  15831. if hasLen {
  15832. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 4)
  15833. } else {
  15834. xlen = 8
  15835. }
  15836. v = make([]uint32, xlen)
  15837. changed = true
  15838. }
  15839. // if indefinite, etc, then expand the slice if necessary
  15840. var decodeIntoBlank bool
  15841. if j >= len(v) {
  15842. if canChange {
  15843. v = append(v, 0)
  15844. changed = true
  15845. } else {
  15846. d.arrayCannotExpand(len(v), j+1)
  15847. decodeIntoBlank = true
  15848. }
  15849. }
  15850. slh.ElemContainerState(j)
  15851. if decodeIntoBlank {
  15852. d.swallow()
  15853. } else {
  15854. v[j] = uint32(dd.DecodeUint(32))
  15855. }
  15856. }
  15857. if canChange {
  15858. if j < len(v) {
  15859. v = v[:j]
  15860. changed = true
  15861. } else if j == 0 && v == nil {
  15862. v = make([]uint32, 0)
  15863. changed = true
  15864. }
  15865. }
  15866. slh.End()
  15867. return v, changed
  15868. }
  15869. func (d *Decoder) fastpathDecSliceUint64R(f *codecFnInfo, rv reflect.Value) {
  15870. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15871. var vp = rv2i(rv).(*[]uint64)
  15872. if v, changed := fastpathTV.DecSliceUint64V(*vp, !array, d); changed {
  15873. *vp = v
  15874. }
  15875. } else {
  15876. fastpathTV.DecSliceUint64V(rv2i(rv).([]uint64), !array, d)
  15877. }
  15878. }
  15879. func (f fastpathT) DecSliceUint64X(vp *[]uint64, d *Decoder) {
  15880. if v, changed := f.DecSliceUint64V(*vp, true, d); changed {
  15881. *vp = v
  15882. }
  15883. }
  15884. func (_ fastpathT) DecSliceUint64V(v []uint64, canChange bool, d *Decoder) (_ []uint64, changed bool) {
  15885. dd := d.d
  15886. slh, containerLenS := d.decSliceHelperStart()
  15887. if containerLenS == 0 {
  15888. if canChange {
  15889. if v == nil {
  15890. v = []uint64{}
  15891. } else if len(v) != 0 {
  15892. v = v[:0]
  15893. }
  15894. changed = true
  15895. }
  15896. slh.End()
  15897. return v, changed
  15898. }
  15899. hasLen := containerLenS > 0
  15900. var xlen int
  15901. if hasLen && canChange {
  15902. if containerLenS > cap(v) {
  15903. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  15904. if xlen <= cap(v) {
  15905. v = v[:xlen]
  15906. } else {
  15907. v = make([]uint64, xlen)
  15908. }
  15909. changed = true
  15910. } else if containerLenS != len(v) {
  15911. v = v[:containerLenS]
  15912. changed = true
  15913. }
  15914. }
  15915. j := 0
  15916. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  15917. if j == 0 && len(v) == 0 {
  15918. if hasLen {
  15919. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  15920. } else {
  15921. xlen = 8
  15922. }
  15923. v = make([]uint64, xlen)
  15924. changed = true
  15925. }
  15926. // if indefinite, etc, then expand the slice if necessary
  15927. var decodeIntoBlank bool
  15928. if j >= len(v) {
  15929. if canChange {
  15930. v = append(v, 0)
  15931. changed = true
  15932. } else {
  15933. d.arrayCannotExpand(len(v), j+1)
  15934. decodeIntoBlank = true
  15935. }
  15936. }
  15937. slh.ElemContainerState(j)
  15938. if decodeIntoBlank {
  15939. d.swallow()
  15940. } else {
  15941. v[j] = dd.DecodeUint(64)
  15942. }
  15943. }
  15944. if canChange {
  15945. if j < len(v) {
  15946. v = v[:j]
  15947. changed = true
  15948. } else if j == 0 && v == nil {
  15949. v = make([]uint64, 0)
  15950. changed = true
  15951. }
  15952. }
  15953. slh.End()
  15954. return v, changed
  15955. }
  15956. func (d *Decoder) fastpathDecSliceUintptrR(f *codecFnInfo, rv reflect.Value) {
  15957. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  15958. var vp = rv2i(rv).(*[]uintptr)
  15959. if v, changed := fastpathTV.DecSliceUintptrV(*vp, !array, d); changed {
  15960. *vp = v
  15961. }
  15962. } else {
  15963. fastpathTV.DecSliceUintptrV(rv2i(rv).([]uintptr), !array, d)
  15964. }
  15965. }
  15966. func (f fastpathT) DecSliceUintptrX(vp *[]uintptr, d *Decoder) {
  15967. if v, changed := f.DecSliceUintptrV(*vp, true, d); changed {
  15968. *vp = v
  15969. }
  15970. }
  15971. func (_ fastpathT) DecSliceUintptrV(v []uintptr, canChange bool, d *Decoder) (_ []uintptr, changed bool) {
  15972. dd := d.d
  15973. slh, containerLenS := d.decSliceHelperStart()
  15974. if containerLenS == 0 {
  15975. if canChange {
  15976. if v == nil {
  15977. v = []uintptr{}
  15978. } else if len(v) != 0 {
  15979. v = v[:0]
  15980. }
  15981. changed = true
  15982. }
  15983. slh.End()
  15984. return v, changed
  15985. }
  15986. hasLen := containerLenS > 0
  15987. var xlen int
  15988. if hasLen && canChange {
  15989. if containerLenS > cap(v) {
  15990. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  15991. if xlen <= cap(v) {
  15992. v = v[:xlen]
  15993. } else {
  15994. v = make([]uintptr, xlen)
  15995. }
  15996. changed = true
  15997. } else if containerLenS != len(v) {
  15998. v = v[:containerLenS]
  15999. changed = true
  16000. }
  16001. }
  16002. j := 0
  16003. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  16004. if j == 0 && len(v) == 0 {
  16005. if hasLen {
  16006. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  16007. } else {
  16008. xlen = 8
  16009. }
  16010. v = make([]uintptr, xlen)
  16011. changed = true
  16012. }
  16013. // if indefinite, etc, then expand the slice if necessary
  16014. var decodeIntoBlank bool
  16015. if j >= len(v) {
  16016. if canChange {
  16017. v = append(v, 0)
  16018. changed = true
  16019. } else {
  16020. d.arrayCannotExpand(len(v), j+1)
  16021. decodeIntoBlank = true
  16022. }
  16023. }
  16024. slh.ElemContainerState(j)
  16025. if decodeIntoBlank {
  16026. d.swallow()
  16027. } else {
  16028. v[j] = uintptr(dd.DecodeUint(uintBitsize))
  16029. }
  16030. }
  16031. if canChange {
  16032. if j < len(v) {
  16033. v = v[:j]
  16034. changed = true
  16035. } else if j == 0 && v == nil {
  16036. v = make([]uintptr, 0)
  16037. changed = true
  16038. }
  16039. }
  16040. slh.End()
  16041. return v, changed
  16042. }
  16043. func (d *Decoder) fastpathDecSliceIntR(f *codecFnInfo, rv reflect.Value) {
  16044. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  16045. var vp = rv2i(rv).(*[]int)
  16046. if v, changed := fastpathTV.DecSliceIntV(*vp, !array, d); changed {
  16047. *vp = v
  16048. }
  16049. } else {
  16050. fastpathTV.DecSliceIntV(rv2i(rv).([]int), !array, d)
  16051. }
  16052. }
  16053. func (f fastpathT) DecSliceIntX(vp *[]int, d *Decoder) {
  16054. if v, changed := f.DecSliceIntV(*vp, true, d); changed {
  16055. *vp = v
  16056. }
  16057. }
  16058. func (_ fastpathT) DecSliceIntV(v []int, canChange bool, d *Decoder) (_ []int, changed bool) {
  16059. dd := d.d
  16060. slh, containerLenS := d.decSliceHelperStart()
  16061. if containerLenS == 0 {
  16062. if canChange {
  16063. if v == nil {
  16064. v = []int{}
  16065. } else if len(v) != 0 {
  16066. v = v[:0]
  16067. }
  16068. changed = true
  16069. }
  16070. slh.End()
  16071. return v, changed
  16072. }
  16073. hasLen := containerLenS > 0
  16074. var xlen int
  16075. if hasLen && canChange {
  16076. if containerLenS > cap(v) {
  16077. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  16078. if xlen <= cap(v) {
  16079. v = v[:xlen]
  16080. } else {
  16081. v = make([]int, xlen)
  16082. }
  16083. changed = true
  16084. } else if containerLenS != len(v) {
  16085. v = v[:containerLenS]
  16086. changed = true
  16087. }
  16088. }
  16089. j := 0
  16090. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  16091. if j == 0 && len(v) == 0 {
  16092. if hasLen {
  16093. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  16094. } else {
  16095. xlen = 8
  16096. }
  16097. v = make([]int, xlen)
  16098. changed = true
  16099. }
  16100. // if indefinite, etc, then expand the slice if necessary
  16101. var decodeIntoBlank bool
  16102. if j >= len(v) {
  16103. if canChange {
  16104. v = append(v, 0)
  16105. changed = true
  16106. } else {
  16107. d.arrayCannotExpand(len(v), j+1)
  16108. decodeIntoBlank = true
  16109. }
  16110. }
  16111. slh.ElemContainerState(j)
  16112. if decodeIntoBlank {
  16113. d.swallow()
  16114. } else {
  16115. v[j] = int(dd.DecodeInt(intBitsize))
  16116. }
  16117. }
  16118. if canChange {
  16119. if j < len(v) {
  16120. v = v[:j]
  16121. changed = true
  16122. } else if j == 0 && v == nil {
  16123. v = make([]int, 0)
  16124. changed = true
  16125. }
  16126. }
  16127. slh.End()
  16128. return v, changed
  16129. }
  16130. func (d *Decoder) fastpathDecSliceInt8R(f *codecFnInfo, rv reflect.Value) {
  16131. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  16132. var vp = rv2i(rv).(*[]int8)
  16133. if v, changed := fastpathTV.DecSliceInt8V(*vp, !array, d); changed {
  16134. *vp = v
  16135. }
  16136. } else {
  16137. fastpathTV.DecSliceInt8V(rv2i(rv).([]int8), !array, d)
  16138. }
  16139. }
  16140. func (f fastpathT) DecSliceInt8X(vp *[]int8, d *Decoder) {
  16141. if v, changed := f.DecSliceInt8V(*vp, true, d); changed {
  16142. *vp = v
  16143. }
  16144. }
  16145. func (_ fastpathT) DecSliceInt8V(v []int8, canChange bool, d *Decoder) (_ []int8, changed bool) {
  16146. dd := d.d
  16147. slh, containerLenS := d.decSliceHelperStart()
  16148. if containerLenS == 0 {
  16149. if canChange {
  16150. if v == nil {
  16151. v = []int8{}
  16152. } else if len(v) != 0 {
  16153. v = v[:0]
  16154. }
  16155. changed = true
  16156. }
  16157. slh.End()
  16158. return v, changed
  16159. }
  16160. hasLen := containerLenS > 0
  16161. var xlen int
  16162. if hasLen && canChange {
  16163. if containerLenS > cap(v) {
  16164. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 1)
  16165. if xlen <= cap(v) {
  16166. v = v[:xlen]
  16167. } else {
  16168. v = make([]int8, xlen)
  16169. }
  16170. changed = true
  16171. } else if containerLenS != len(v) {
  16172. v = v[:containerLenS]
  16173. changed = true
  16174. }
  16175. }
  16176. j := 0
  16177. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  16178. if j == 0 && len(v) == 0 {
  16179. if hasLen {
  16180. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 1)
  16181. } else {
  16182. xlen = 8
  16183. }
  16184. v = make([]int8, xlen)
  16185. changed = true
  16186. }
  16187. // if indefinite, etc, then expand the slice if necessary
  16188. var decodeIntoBlank bool
  16189. if j >= len(v) {
  16190. if canChange {
  16191. v = append(v, 0)
  16192. changed = true
  16193. } else {
  16194. d.arrayCannotExpand(len(v), j+1)
  16195. decodeIntoBlank = true
  16196. }
  16197. }
  16198. slh.ElemContainerState(j)
  16199. if decodeIntoBlank {
  16200. d.swallow()
  16201. } else {
  16202. v[j] = int8(dd.DecodeInt(8))
  16203. }
  16204. }
  16205. if canChange {
  16206. if j < len(v) {
  16207. v = v[:j]
  16208. changed = true
  16209. } else if j == 0 && v == nil {
  16210. v = make([]int8, 0)
  16211. changed = true
  16212. }
  16213. }
  16214. slh.End()
  16215. return v, changed
  16216. }
  16217. func (d *Decoder) fastpathDecSliceInt16R(f *codecFnInfo, rv reflect.Value) {
  16218. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  16219. var vp = rv2i(rv).(*[]int16)
  16220. if v, changed := fastpathTV.DecSliceInt16V(*vp, !array, d); changed {
  16221. *vp = v
  16222. }
  16223. } else {
  16224. fastpathTV.DecSliceInt16V(rv2i(rv).([]int16), !array, d)
  16225. }
  16226. }
  16227. func (f fastpathT) DecSliceInt16X(vp *[]int16, d *Decoder) {
  16228. if v, changed := f.DecSliceInt16V(*vp, true, d); changed {
  16229. *vp = v
  16230. }
  16231. }
  16232. func (_ fastpathT) DecSliceInt16V(v []int16, canChange bool, d *Decoder) (_ []int16, changed bool) {
  16233. dd := d.d
  16234. slh, containerLenS := d.decSliceHelperStart()
  16235. if containerLenS == 0 {
  16236. if canChange {
  16237. if v == nil {
  16238. v = []int16{}
  16239. } else if len(v) != 0 {
  16240. v = v[:0]
  16241. }
  16242. changed = true
  16243. }
  16244. slh.End()
  16245. return v, changed
  16246. }
  16247. hasLen := containerLenS > 0
  16248. var xlen int
  16249. if hasLen && canChange {
  16250. if containerLenS > cap(v) {
  16251. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 2)
  16252. if xlen <= cap(v) {
  16253. v = v[:xlen]
  16254. } else {
  16255. v = make([]int16, xlen)
  16256. }
  16257. changed = true
  16258. } else if containerLenS != len(v) {
  16259. v = v[:containerLenS]
  16260. changed = true
  16261. }
  16262. }
  16263. j := 0
  16264. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  16265. if j == 0 && len(v) == 0 {
  16266. if hasLen {
  16267. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 2)
  16268. } else {
  16269. xlen = 8
  16270. }
  16271. v = make([]int16, xlen)
  16272. changed = true
  16273. }
  16274. // if indefinite, etc, then expand the slice if necessary
  16275. var decodeIntoBlank bool
  16276. if j >= len(v) {
  16277. if canChange {
  16278. v = append(v, 0)
  16279. changed = true
  16280. } else {
  16281. d.arrayCannotExpand(len(v), j+1)
  16282. decodeIntoBlank = true
  16283. }
  16284. }
  16285. slh.ElemContainerState(j)
  16286. if decodeIntoBlank {
  16287. d.swallow()
  16288. } else {
  16289. v[j] = int16(dd.DecodeInt(16))
  16290. }
  16291. }
  16292. if canChange {
  16293. if j < len(v) {
  16294. v = v[:j]
  16295. changed = true
  16296. } else if j == 0 && v == nil {
  16297. v = make([]int16, 0)
  16298. changed = true
  16299. }
  16300. }
  16301. slh.End()
  16302. return v, changed
  16303. }
  16304. func (d *Decoder) fastpathDecSliceInt32R(f *codecFnInfo, rv reflect.Value) {
  16305. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  16306. var vp = rv2i(rv).(*[]int32)
  16307. if v, changed := fastpathTV.DecSliceInt32V(*vp, !array, d); changed {
  16308. *vp = v
  16309. }
  16310. } else {
  16311. fastpathTV.DecSliceInt32V(rv2i(rv).([]int32), !array, d)
  16312. }
  16313. }
  16314. func (f fastpathT) DecSliceInt32X(vp *[]int32, d *Decoder) {
  16315. if v, changed := f.DecSliceInt32V(*vp, true, d); changed {
  16316. *vp = v
  16317. }
  16318. }
  16319. func (_ fastpathT) DecSliceInt32V(v []int32, canChange bool, d *Decoder) (_ []int32, changed bool) {
  16320. dd := d.d
  16321. slh, containerLenS := d.decSliceHelperStart()
  16322. if containerLenS == 0 {
  16323. if canChange {
  16324. if v == nil {
  16325. v = []int32{}
  16326. } else if len(v) != 0 {
  16327. v = v[:0]
  16328. }
  16329. changed = true
  16330. }
  16331. slh.End()
  16332. return v, changed
  16333. }
  16334. hasLen := containerLenS > 0
  16335. var xlen int
  16336. if hasLen && canChange {
  16337. if containerLenS > cap(v) {
  16338. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 4)
  16339. if xlen <= cap(v) {
  16340. v = v[:xlen]
  16341. } else {
  16342. v = make([]int32, xlen)
  16343. }
  16344. changed = true
  16345. } else if containerLenS != len(v) {
  16346. v = v[:containerLenS]
  16347. changed = true
  16348. }
  16349. }
  16350. j := 0
  16351. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  16352. if j == 0 && len(v) == 0 {
  16353. if hasLen {
  16354. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 4)
  16355. } else {
  16356. xlen = 8
  16357. }
  16358. v = make([]int32, xlen)
  16359. changed = true
  16360. }
  16361. // if indefinite, etc, then expand the slice if necessary
  16362. var decodeIntoBlank bool
  16363. if j >= len(v) {
  16364. if canChange {
  16365. v = append(v, 0)
  16366. changed = true
  16367. } else {
  16368. d.arrayCannotExpand(len(v), j+1)
  16369. decodeIntoBlank = true
  16370. }
  16371. }
  16372. slh.ElemContainerState(j)
  16373. if decodeIntoBlank {
  16374. d.swallow()
  16375. } else {
  16376. v[j] = int32(dd.DecodeInt(32))
  16377. }
  16378. }
  16379. if canChange {
  16380. if j < len(v) {
  16381. v = v[:j]
  16382. changed = true
  16383. } else if j == 0 && v == nil {
  16384. v = make([]int32, 0)
  16385. changed = true
  16386. }
  16387. }
  16388. slh.End()
  16389. return v, changed
  16390. }
  16391. func (d *Decoder) fastpathDecSliceInt64R(f *codecFnInfo, rv reflect.Value) {
  16392. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  16393. var vp = rv2i(rv).(*[]int64)
  16394. if v, changed := fastpathTV.DecSliceInt64V(*vp, !array, d); changed {
  16395. *vp = v
  16396. }
  16397. } else {
  16398. fastpathTV.DecSliceInt64V(rv2i(rv).([]int64), !array, d)
  16399. }
  16400. }
  16401. func (f fastpathT) DecSliceInt64X(vp *[]int64, d *Decoder) {
  16402. if v, changed := f.DecSliceInt64V(*vp, true, d); changed {
  16403. *vp = v
  16404. }
  16405. }
  16406. func (_ fastpathT) DecSliceInt64V(v []int64, canChange bool, d *Decoder) (_ []int64, changed bool) {
  16407. dd := d.d
  16408. slh, containerLenS := d.decSliceHelperStart()
  16409. if containerLenS == 0 {
  16410. if canChange {
  16411. if v == nil {
  16412. v = []int64{}
  16413. } else if len(v) != 0 {
  16414. v = v[:0]
  16415. }
  16416. changed = true
  16417. }
  16418. slh.End()
  16419. return v, changed
  16420. }
  16421. hasLen := containerLenS > 0
  16422. var xlen int
  16423. if hasLen && canChange {
  16424. if containerLenS > cap(v) {
  16425. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  16426. if xlen <= cap(v) {
  16427. v = v[:xlen]
  16428. } else {
  16429. v = make([]int64, xlen)
  16430. }
  16431. changed = true
  16432. } else if containerLenS != len(v) {
  16433. v = v[:containerLenS]
  16434. changed = true
  16435. }
  16436. }
  16437. j := 0
  16438. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  16439. if j == 0 && len(v) == 0 {
  16440. if hasLen {
  16441. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 8)
  16442. } else {
  16443. xlen = 8
  16444. }
  16445. v = make([]int64, xlen)
  16446. changed = true
  16447. }
  16448. // if indefinite, etc, then expand the slice if necessary
  16449. var decodeIntoBlank bool
  16450. if j >= len(v) {
  16451. if canChange {
  16452. v = append(v, 0)
  16453. changed = true
  16454. } else {
  16455. d.arrayCannotExpand(len(v), j+1)
  16456. decodeIntoBlank = true
  16457. }
  16458. }
  16459. slh.ElemContainerState(j)
  16460. if decodeIntoBlank {
  16461. d.swallow()
  16462. } else {
  16463. v[j] = dd.DecodeInt(64)
  16464. }
  16465. }
  16466. if canChange {
  16467. if j < len(v) {
  16468. v = v[:j]
  16469. changed = true
  16470. } else if j == 0 && v == nil {
  16471. v = make([]int64, 0)
  16472. changed = true
  16473. }
  16474. }
  16475. slh.End()
  16476. return v, changed
  16477. }
  16478. func (d *Decoder) fastpathDecSliceBoolR(f *codecFnInfo, rv reflect.Value) {
  16479. if array := f.seq == seqTypeArray; !array && rv.Kind() == reflect.Ptr {
  16480. var vp = rv2i(rv).(*[]bool)
  16481. if v, changed := fastpathTV.DecSliceBoolV(*vp, !array, d); changed {
  16482. *vp = v
  16483. }
  16484. } else {
  16485. fastpathTV.DecSliceBoolV(rv2i(rv).([]bool), !array, d)
  16486. }
  16487. }
  16488. func (f fastpathT) DecSliceBoolX(vp *[]bool, d *Decoder) {
  16489. if v, changed := f.DecSliceBoolV(*vp, true, d); changed {
  16490. *vp = v
  16491. }
  16492. }
  16493. func (_ fastpathT) DecSliceBoolV(v []bool, canChange bool, d *Decoder) (_ []bool, changed bool) {
  16494. dd := d.d
  16495. slh, containerLenS := d.decSliceHelperStart()
  16496. if containerLenS == 0 {
  16497. if canChange {
  16498. if v == nil {
  16499. v = []bool{}
  16500. } else if len(v) != 0 {
  16501. v = v[:0]
  16502. }
  16503. changed = true
  16504. }
  16505. slh.End()
  16506. return v, changed
  16507. }
  16508. hasLen := containerLenS > 0
  16509. var xlen int
  16510. if hasLen && canChange {
  16511. if containerLenS > cap(v) {
  16512. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 1)
  16513. if xlen <= cap(v) {
  16514. v = v[:xlen]
  16515. } else {
  16516. v = make([]bool, xlen)
  16517. }
  16518. changed = true
  16519. } else if containerLenS != len(v) {
  16520. v = v[:containerLenS]
  16521. changed = true
  16522. }
  16523. }
  16524. j := 0
  16525. for ; (hasLen && j < containerLenS) || !(hasLen || dd.CheckBreak()); j++ {
  16526. if j == 0 && len(v) == 0 {
  16527. if hasLen {
  16528. xlen = decInferLen(containerLenS, d.h.MaxInitLen, 1)
  16529. } else {
  16530. xlen = 8
  16531. }
  16532. v = make([]bool, xlen)
  16533. changed = true
  16534. }
  16535. // if indefinite, etc, then expand the slice if necessary
  16536. var decodeIntoBlank bool
  16537. if j >= len(v) {
  16538. if canChange {
  16539. v = append(v, false)
  16540. changed = true
  16541. } else {
  16542. d.arrayCannotExpand(len(v), j+1)
  16543. decodeIntoBlank = true
  16544. }
  16545. }
  16546. slh.ElemContainerState(j)
  16547. if decodeIntoBlank {
  16548. d.swallow()
  16549. } else {
  16550. v[j] = dd.DecodeBool()
  16551. }
  16552. }
  16553. if canChange {
  16554. if j < len(v) {
  16555. v = v[:j]
  16556. changed = true
  16557. } else if j == 0 && v == nil {
  16558. v = make([]bool, 0)
  16559. changed = true
  16560. }
  16561. }
  16562. slh.End()
  16563. return v, changed
  16564. }
  16565. func (d *Decoder) fastpathDecMapIntfIntfR(f *codecFnInfo, rv reflect.Value) {
  16566. if rv.Kind() == reflect.Ptr {
  16567. vp := rv2i(rv).(*map[interface{}]interface{})
  16568. if v, changed := fastpathTV.DecMapIntfIntfV(*vp, true, d); changed {
  16569. *vp = v
  16570. }
  16571. return
  16572. }
  16573. fastpathTV.DecMapIntfIntfV(rv2i(rv).(map[interface{}]interface{}), false, d)
  16574. }
  16575. func (f fastpathT) DecMapIntfIntfX(vp *map[interface{}]interface{}, d *Decoder) {
  16576. if v, changed := f.DecMapIntfIntfV(*vp, true, d); changed {
  16577. *vp = v
  16578. }
  16579. }
  16580. func (_ fastpathT) DecMapIntfIntfV(v map[interface{}]interface{}, canChange bool,
  16581. d *Decoder) (_ map[interface{}]interface{}, changed bool) {
  16582. dd, esep := d.d, d.hh.hasElemSeparators()
  16583. containerLen := dd.ReadMapStart()
  16584. if canChange && v == nil {
  16585. xlen := decInferLen(containerLen, d.h.MaxInitLen, 32)
  16586. v = make(map[interface{}]interface{}, xlen)
  16587. changed = true
  16588. }
  16589. if containerLen == 0 {
  16590. dd.ReadMapEnd()
  16591. return v, changed
  16592. }
  16593. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  16594. var mk interface{}
  16595. var mv interface{}
  16596. hasLen := containerLen > 0
  16597. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  16598. if esep {
  16599. dd.ReadMapElemKey()
  16600. }
  16601. mk = nil
  16602. d.decode(&mk)
  16603. if bv, bok := mk.([]byte); bok {
  16604. mk = d.string(bv)
  16605. }
  16606. if esep {
  16607. dd.ReadMapElemValue()
  16608. }
  16609. if dd.TryDecodeAsNil() {
  16610. if d.h.DeleteOnNilMapValue {
  16611. delete(v, mk)
  16612. } else {
  16613. v[mk] = nil
  16614. }
  16615. continue
  16616. }
  16617. if mapGet {
  16618. mv = v[mk]
  16619. } else {
  16620. mv = nil
  16621. }
  16622. d.decode(&mv)
  16623. if v != nil {
  16624. v[mk] = mv
  16625. }
  16626. }
  16627. dd.ReadMapEnd()
  16628. return v, changed
  16629. }
  16630. func (d *Decoder) fastpathDecMapIntfStringR(f *codecFnInfo, rv reflect.Value) {
  16631. if rv.Kind() == reflect.Ptr {
  16632. vp := rv2i(rv).(*map[interface{}]string)
  16633. if v, changed := fastpathTV.DecMapIntfStringV(*vp, true, d); changed {
  16634. *vp = v
  16635. }
  16636. return
  16637. }
  16638. fastpathTV.DecMapIntfStringV(rv2i(rv).(map[interface{}]string), false, d)
  16639. }
  16640. func (f fastpathT) DecMapIntfStringX(vp *map[interface{}]string, d *Decoder) {
  16641. if v, changed := f.DecMapIntfStringV(*vp, true, d); changed {
  16642. *vp = v
  16643. }
  16644. }
  16645. func (_ fastpathT) DecMapIntfStringV(v map[interface{}]string, canChange bool,
  16646. d *Decoder) (_ map[interface{}]string, changed bool) {
  16647. dd, esep := d.d, d.hh.hasElemSeparators()
  16648. containerLen := dd.ReadMapStart()
  16649. if canChange && v == nil {
  16650. xlen := decInferLen(containerLen, d.h.MaxInitLen, 32)
  16651. v = make(map[interface{}]string, xlen)
  16652. changed = true
  16653. }
  16654. if containerLen == 0 {
  16655. dd.ReadMapEnd()
  16656. return v, changed
  16657. }
  16658. var mk interface{}
  16659. var mv string
  16660. hasLen := containerLen > 0
  16661. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  16662. if esep {
  16663. dd.ReadMapElemKey()
  16664. }
  16665. mk = nil
  16666. d.decode(&mk)
  16667. if bv, bok := mk.([]byte); bok {
  16668. mk = d.string(bv)
  16669. }
  16670. if esep {
  16671. dd.ReadMapElemValue()
  16672. }
  16673. if dd.TryDecodeAsNil() {
  16674. if d.h.DeleteOnNilMapValue {
  16675. delete(v, mk)
  16676. } else {
  16677. v[mk] = ""
  16678. }
  16679. continue
  16680. }
  16681. mv = dd.DecodeString()
  16682. if v != nil {
  16683. v[mk] = mv
  16684. }
  16685. }
  16686. dd.ReadMapEnd()
  16687. return v, changed
  16688. }
  16689. func (d *Decoder) fastpathDecMapIntfUintR(f *codecFnInfo, rv reflect.Value) {
  16690. if rv.Kind() == reflect.Ptr {
  16691. vp := rv2i(rv).(*map[interface{}]uint)
  16692. if v, changed := fastpathTV.DecMapIntfUintV(*vp, true, d); changed {
  16693. *vp = v
  16694. }
  16695. return
  16696. }
  16697. fastpathTV.DecMapIntfUintV(rv2i(rv).(map[interface{}]uint), false, d)
  16698. }
  16699. func (f fastpathT) DecMapIntfUintX(vp *map[interface{}]uint, d *Decoder) {
  16700. if v, changed := f.DecMapIntfUintV(*vp, true, d); changed {
  16701. *vp = v
  16702. }
  16703. }
  16704. func (_ fastpathT) DecMapIntfUintV(v map[interface{}]uint, canChange bool,
  16705. d *Decoder) (_ map[interface{}]uint, changed bool) {
  16706. dd, esep := d.d, d.hh.hasElemSeparators()
  16707. containerLen := dd.ReadMapStart()
  16708. if canChange && v == nil {
  16709. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  16710. v = make(map[interface{}]uint, xlen)
  16711. changed = true
  16712. }
  16713. if containerLen == 0 {
  16714. dd.ReadMapEnd()
  16715. return v, changed
  16716. }
  16717. var mk interface{}
  16718. var mv uint
  16719. hasLen := containerLen > 0
  16720. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  16721. if esep {
  16722. dd.ReadMapElemKey()
  16723. }
  16724. mk = nil
  16725. d.decode(&mk)
  16726. if bv, bok := mk.([]byte); bok {
  16727. mk = d.string(bv)
  16728. }
  16729. if esep {
  16730. dd.ReadMapElemValue()
  16731. }
  16732. if dd.TryDecodeAsNil() {
  16733. if d.h.DeleteOnNilMapValue {
  16734. delete(v, mk)
  16735. } else {
  16736. v[mk] = 0
  16737. }
  16738. continue
  16739. }
  16740. mv = uint(dd.DecodeUint(uintBitsize))
  16741. if v != nil {
  16742. v[mk] = mv
  16743. }
  16744. }
  16745. dd.ReadMapEnd()
  16746. return v, changed
  16747. }
  16748. func (d *Decoder) fastpathDecMapIntfUint8R(f *codecFnInfo, rv reflect.Value) {
  16749. if rv.Kind() == reflect.Ptr {
  16750. vp := rv2i(rv).(*map[interface{}]uint8)
  16751. if v, changed := fastpathTV.DecMapIntfUint8V(*vp, true, d); changed {
  16752. *vp = v
  16753. }
  16754. return
  16755. }
  16756. fastpathTV.DecMapIntfUint8V(rv2i(rv).(map[interface{}]uint8), false, d)
  16757. }
  16758. func (f fastpathT) DecMapIntfUint8X(vp *map[interface{}]uint8, d *Decoder) {
  16759. if v, changed := f.DecMapIntfUint8V(*vp, true, d); changed {
  16760. *vp = v
  16761. }
  16762. }
  16763. func (_ fastpathT) DecMapIntfUint8V(v map[interface{}]uint8, canChange bool,
  16764. d *Decoder) (_ map[interface{}]uint8, changed bool) {
  16765. dd, esep := d.d, d.hh.hasElemSeparators()
  16766. containerLen := dd.ReadMapStart()
  16767. if canChange && v == nil {
  16768. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  16769. v = make(map[interface{}]uint8, xlen)
  16770. changed = true
  16771. }
  16772. if containerLen == 0 {
  16773. dd.ReadMapEnd()
  16774. return v, changed
  16775. }
  16776. var mk interface{}
  16777. var mv uint8
  16778. hasLen := containerLen > 0
  16779. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  16780. if esep {
  16781. dd.ReadMapElemKey()
  16782. }
  16783. mk = nil
  16784. d.decode(&mk)
  16785. if bv, bok := mk.([]byte); bok {
  16786. mk = d.string(bv)
  16787. }
  16788. if esep {
  16789. dd.ReadMapElemValue()
  16790. }
  16791. if dd.TryDecodeAsNil() {
  16792. if d.h.DeleteOnNilMapValue {
  16793. delete(v, mk)
  16794. } else {
  16795. v[mk] = 0
  16796. }
  16797. continue
  16798. }
  16799. mv = uint8(dd.DecodeUint(8))
  16800. if v != nil {
  16801. v[mk] = mv
  16802. }
  16803. }
  16804. dd.ReadMapEnd()
  16805. return v, changed
  16806. }
  16807. func (d *Decoder) fastpathDecMapIntfUint16R(f *codecFnInfo, rv reflect.Value) {
  16808. if rv.Kind() == reflect.Ptr {
  16809. vp := rv2i(rv).(*map[interface{}]uint16)
  16810. if v, changed := fastpathTV.DecMapIntfUint16V(*vp, true, d); changed {
  16811. *vp = v
  16812. }
  16813. return
  16814. }
  16815. fastpathTV.DecMapIntfUint16V(rv2i(rv).(map[interface{}]uint16), false, d)
  16816. }
  16817. func (f fastpathT) DecMapIntfUint16X(vp *map[interface{}]uint16, d *Decoder) {
  16818. if v, changed := f.DecMapIntfUint16V(*vp, true, d); changed {
  16819. *vp = v
  16820. }
  16821. }
  16822. func (_ fastpathT) DecMapIntfUint16V(v map[interface{}]uint16, canChange bool,
  16823. d *Decoder) (_ map[interface{}]uint16, changed bool) {
  16824. dd, esep := d.d, d.hh.hasElemSeparators()
  16825. containerLen := dd.ReadMapStart()
  16826. if canChange && v == nil {
  16827. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  16828. v = make(map[interface{}]uint16, xlen)
  16829. changed = true
  16830. }
  16831. if containerLen == 0 {
  16832. dd.ReadMapEnd()
  16833. return v, changed
  16834. }
  16835. var mk interface{}
  16836. var mv uint16
  16837. hasLen := containerLen > 0
  16838. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  16839. if esep {
  16840. dd.ReadMapElemKey()
  16841. }
  16842. mk = nil
  16843. d.decode(&mk)
  16844. if bv, bok := mk.([]byte); bok {
  16845. mk = d.string(bv)
  16846. }
  16847. if esep {
  16848. dd.ReadMapElemValue()
  16849. }
  16850. if dd.TryDecodeAsNil() {
  16851. if d.h.DeleteOnNilMapValue {
  16852. delete(v, mk)
  16853. } else {
  16854. v[mk] = 0
  16855. }
  16856. continue
  16857. }
  16858. mv = uint16(dd.DecodeUint(16))
  16859. if v != nil {
  16860. v[mk] = mv
  16861. }
  16862. }
  16863. dd.ReadMapEnd()
  16864. return v, changed
  16865. }
  16866. func (d *Decoder) fastpathDecMapIntfUint32R(f *codecFnInfo, rv reflect.Value) {
  16867. if rv.Kind() == reflect.Ptr {
  16868. vp := rv2i(rv).(*map[interface{}]uint32)
  16869. if v, changed := fastpathTV.DecMapIntfUint32V(*vp, true, d); changed {
  16870. *vp = v
  16871. }
  16872. return
  16873. }
  16874. fastpathTV.DecMapIntfUint32V(rv2i(rv).(map[interface{}]uint32), false, d)
  16875. }
  16876. func (f fastpathT) DecMapIntfUint32X(vp *map[interface{}]uint32, d *Decoder) {
  16877. if v, changed := f.DecMapIntfUint32V(*vp, true, d); changed {
  16878. *vp = v
  16879. }
  16880. }
  16881. func (_ fastpathT) DecMapIntfUint32V(v map[interface{}]uint32, canChange bool,
  16882. d *Decoder) (_ map[interface{}]uint32, changed bool) {
  16883. dd, esep := d.d, d.hh.hasElemSeparators()
  16884. containerLen := dd.ReadMapStart()
  16885. if canChange && v == nil {
  16886. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  16887. v = make(map[interface{}]uint32, xlen)
  16888. changed = true
  16889. }
  16890. if containerLen == 0 {
  16891. dd.ReadMapEnd()
  16892. return v, changed
  16893. }
  16894. var mk interface{}
  16895. var mv uint32
  16896. hasLen := containerLen > 0
  16897. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  16898. if esep {
  16899. dd.ReadMapElemKey()
  16900. }
  16901. mk = nil
  16902. d.decode(&mk)
  16903. if bv, bok := mk.([]byte); bok {
  16904. mk = d.string(bv)
  16905. }
  16906. if esep {
  16907. dd.ReadMapElemValue()
  16908. }
  16909. if dd.TryDecodeAsNil() {
  16910. if d.h.DeleteOnNilMapValue {
  16911. delete(v, mk)
  16912. } else {
  16913. v[mk] = 0
  16914. }
  16915. continue
  16916. }
  16917. mv = uint32(dd.DecodeUint(32))
  16918. if v != nil {
  16919. v[mk] = mv
  16920. }
  16921. }
  16922. dd.ReadMapEnd()
  16923. return v, changed
  16924. }
  16925. func (d *Decoder) fastpathDecMapIntfUint64R(f *codecFnInfo, rv reflect.Value) {
  16926. if rv.Kind() == reflect.Ptr {
  16927. vp := rv2i(rv).(*map[interface{}]uint64)
  16928. if v, changed := fastpathTV.DecMapIntfUint64V(*vp, true, d); changed {
  16929. *vp = v
  16930. }
  16931. return
  16932. }
  16933. fastpathTV.DecMapIntfUint64V(rv2i(rv).(map[interface{}]uint64), false, d)
  16934. }
  16935. func (f fastpathT) DecMapIntfUint64X(vp *map[interface{}]uint64, d *Decoder) {
  16936. if v, changed := f.DecMapIntfUint64V(*vp, true, d); changed {
  16937. *vp = v
  16938. }
  16939. }
  16940. func (_ fastpathT) DecMapIntfUint64V(v map[interface{}]uint64, canChange bool,
  16941. d *Decoder) (_ map[interface{}]uint64, changed bool) {
  16942. dd, esep := d.d, d.hh.hasElemSeparators()
  16943. containerLen := dd.ReadMapStart()
  16944. if canChange && v == nil {
  16945. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  16946. v = make(map[interface{}]uint64, xlen)
  16947. changed = true
  16948. }
  16949. if containerLen == 0 {
  16950. dd.ReadMapEnd()
  16951. return v, changed
  16952. }
  16953. var mk interface{}
  16954. var mv uint64
  16955. hasLen := containerLen > 0
  16956. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  16957. if esep {
  16958. dd.ReadMapElemKey()
  16959. }
  16960. mk = nil
  16961. d.decode(&mk)
  16962. if bv, bok := mk.([]byte); bok {
  16963. mk = d.string(bv)
  16964. }
  16965. if esep {
  16966. dd.ReadMapElemValue()
  16967. }
  16968. if dd.TryDecodeAsNil() {
  16969. if d.h.DeleteOnNilMapValue {
  16970. delete(v, mk)
  16971. } else {
  16972. v[mk] = 0
  16973. }
  16974. continue
  16975. }
  16976. mv = dd.DecodeUint(64)
  16977. if v != nil {
  16978. v[mk] = mv
  16979. }
  16980. }
  16981. dd.ReadMapEnd()
  16982. return v, changed
  16983. }
  16984. func (d *Decoder) fastpathDecMapIntfUintptrR(f *codecFnInfo, rv reflect.Value) {
  16985. if rv.Kind() == reflect.Ptr {
  16986. vp := rv2i(rv).(*map[interface{}]uintptr)
  16987. if v, changed := fastpathTV.DecMapIntfUintptrV(*vp, true, d); changed {
  16988. *vp = v
  16989. }
  16990. return
  16991. }
  16992. fastpathTV.DecMapIntfUintptrV(rv2i(rv).(map[interface{}]uintptr), false, d)
  16993. }
  16994. func (f fastpathT) DecMapIntfUintptrX(vp *map[interface{}]uintptr, d *Decoder) {
  16995. if v, changed := f.DecMapIntfUintptrV(*vp, true, d); changed {
  16996. *vp = v
  16997. }
  16998. }
  16999. func (_ fastpathT) DecMapIntfUintptrV(v map[interface{}]uintptr, canChange bool,
  17000. d *Decoder) (_ map[interface{}]uintptr, changed bool) {
  17001. dd, esep := d.d, d.hh.hasElemSeparators()
  17002. containerLen := dd.ReadMapStart()
  17003. if canChange && v == nil {
  17004. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  17005. v = make(map[interface{}]uintptr, xlen)
  17006. changed = true
  17007. }
  17008. if containerLen == 0 {
  17009. dd.ReadMapEnd()
  17010. return v, changed
  17011. }
  17012. var mk interface{}
  17013. var mv uintptr
  17014. hasLen := containerLen > 0
  17015. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17016. if esep {
  17017. dd.ReadMapElemKey()
  17018. }
  17019. mk = nil
  17020. d.decode(&mk)
  17021. if bv, bok := mk.([]byte); bok {
  17022. mk = d.string(bv)
  17023. }
  17024. if esep {
  17025. dd.ReadMapElemValue()
  17026. }
  17027. if dd.TryDecodeAsNil() {
  17028. if d.h.DeleteOnNilMapValue {
  17029. delete(v, mk)
  17030. } else {
  17031. v[mk] = 0
  17032. }
  17033. continue
  17034. }
  17035. mv = uintptr(dd.DecodeUint(uintBitsize))
  17036. if v != nil {
  17037. v[mk] = mv
  17038. }
  17039. }
  17040. dd.ReadMapEnd()
  17041. return v, changed
  17042. }
  17043. func (d *Decoder) fastpathDecMapIntfIntR(f *codecFnInfo, rv reflect.Value) {
  17044. if rv.Kind() == reflect.Ptr {
  17045. vp := rv2i(rv).(*map[interface{}]int)
  17046. if v, changed := fastpathTV.DecMapIntfIntV(*vp, true, d); changed {
  17047. *vp = v
  17048. }
  17049. return
  17050. }
  17051. fastpathTV.DecMapIntfIntV(rv2i(rv).(map[interface{}]int), false, d)
  17052. }
  17053. func (f fastpathT) DecMapIntfIntX(vp *map[interface{}]int, d *Decoder) {
  17054. if v, changed := f.DecMapIntfIntV(*vp, true, d); changed {
  17055. *vp = v
  17056. }
  17057. }
  17058. func (_ fastpathT) DecMapIntfIntV(v map[interface{}]int, canChange bool,
  17059. d *Decoder) (_ map[interface{}]int, changed bool) {
  17060. dd, esep := d.d, d.hh.hasElemSeparators()
  17061. containerLen := dd.ReadMapStart()
  17062. if canChange && v == nil {
  17063. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  17064. v = make(map[interface{}]int, xlen)
  17065. changed = true
  17066. }
  17067. if containerLen == 0 {
  17068. dd.ReadMapEnd()
  17069. return v, changed
  17070. }
  17071. var mk interface{}
  17072. var mv int
  17073. hasLen := containerLen > 0
  17074. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17075. if esep {
  17076. dd.ReadMapElemKey()
  17077. }
  17078. mk = nil
  17079. d.decode(&mk)
  17080. if bv, bok := mk.([]byte); bok {
  17081. mk = d.string(bv)
  17082. }
  17083. if esep {
  17084. dd.ReadMapElemValue()
  17085. }
  17086. if dd.TryDecodeAsNil() {
  17087. if d.h.DeleteOnNilMapValue {
  17088. delete(v, mk)
  17089. } else {
  17090. v[mk] = 0
  17091. }
  17092. continue
  17093. }
  17094. mv = int(dd.DecodeInt(intBitsize))
  17095. if v != nil {
  17096. v[mk] = mv
  17097. }
  17098. }
  17099. dd.ReadMapEnd()
  17100. return v, changed
  17101. }
  17102. func (d *Decoder) fastpathDecMapIntfInt8R(f *codecFnInfo, rv reflect.Value) {
  17103. if rv.Kind() == reflect.Ptr {
  17104. vp := rv2i(rv).(*map[interface{}]int8)
  17105. if v, changed := fastpathTV.DecMapIntfInt8V(*vp, true, d); changed {
  17106. *vp = v
  17107. }
  17108. return
  17109. }
  17110. fastpathTV.DecMapIntfInt8V(rv2i(rv).(map[interface{}]int8), false, d)
  17111. }
  17112. func (f fastpathT) DecMapIntfInt8X(vp *map[interface{}]int8, d *Decoder) {
  17113. if v, changed := f.DecMapIntfInt8V(*vp, true, d); changed {
  17114. *vp = v
  17115. }
  17116. }
  17117. func (_ fastpathT) DecMapIntfInt8V(v map[interface{}]int8, canChange bool,
  17118. d *Decoder) (_ map[interface{}]int8, changed bool) {
  17119. dd, esep := d.d, d.hh.hasElemSeparators()
  17120. containerLen := dd.ReadMapStart()
  17121. if canChange && v == nil {
  17122. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  17123. v = make(map[interface{}]int8, xlen)
  17124. changed = true
  17125. }
  17126. if containerLen == 0 {
  17127. dd.ReadMapEnd()
  17128. return v, changed
  17129. }
  17130. var mk interface{}
  17131. var mv int8
  17132. hasLen := containerLen > 0
  17133. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17134. if esep {
  17135. dd.ReadMapElemKey()
  17136. }
  17137. mk = nil
  17138. d.decode(&mk)
  17139. if bv, bok := mk.([]byte); bok {
  17140. mk = d.string(bv)
  17141. }
  17142. if esep {
  17143. dd.ReadMapElemValue()
  17144. }
  17145. if dd.TryDecodeAsNil() {
  17146. if d.h.DeleteOnNilMapValue {
  17147. delete(v, mk)
  17148. } else {
  17149. v[mk] = 0
  17150. }
  17151. continue
  17152. }
  17153. mv = int8(dd.DecodeInt(8))
  17154. if v != nil {
  17155. v[mk] = mv
  17156. }
  17157. }
  17158. dd.ReadMapEnd()
  17159. return v, changed
  17160. }
  17161. func (d *Decoder) fastpathDecMapIntfInt16R(f *codecFnInfo, rv reflect.Value) {
  17162. if rv.Kind() == reflect.Ptr {
  17163. vp := rv2i(rv).(*map[interface{}]int16)
  17164. if v, changed := fastpathTV.DecMapIntfInt16V(*vp, true, d); changed {
  17165. *vp = v
  17166. }
  17167. return
  17168. }
  17169. fastpathTV.DecMapIntfInt16V(rv2i(rv).(map[interface{}]int16), false, d)
  17170. }
  17171. func (f fastpathT) DecMapIntfInt16X(vp *map[interface{}]int16, d *Decoder) {
  17172. if v, changed := f.DecMapIntfInt16V(*vp, true, d); changed {
  17173. *vp = v
  17174. }
  17175. }
  17176. func (_ fastpathT) DecMapIntfInt16V(v map[interface{}]int16, canChange bool,
  17177. d *Decoder) (_ map[interface{}]int16, changed bool) {
  17178. dd, esep := d.d, d.hh.hasElemSeparators()
  17179. containerLen := dd.ReadMapStart()
  17180. if canChange && v == nil {
  17181. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  17182. v = make(map[interface{}]int16, xlen)
  17183. changed = true
  17184. }
  17185. if containerLen == 0 {
  17186. dd.ReadMapEnd()
  17187. return v, changed
  17188. }
  17189. var mk interface{}
  17190. var mv int16
  17191. hasLen := containerLen > 0
  17192. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17193. if esep {
  17194. dd.ReadMapElemKey()
  17195. }
  17196. mk = nil
  17197. d.decode(&mk)
  17198. if bv, bok := mk.([]byte); bok {
  17199. mk = d.string(bv)
  17200. }
  17201. if esep {
  17202. dd.ReadMapElemValue()
  17203. }
  17204. if dd.TryDecodeAsNil() {
  17205. if d.h.DeleteOnNilMapValue {
  17206. delete(v, mk)
  17207. } else {
  17208. v[mk] = 0
  17209. }
  17210. continue
  17211. }
  17212. mv = int16(dd.DecodeInt(16))
  17213. if v != nil {
  17214. v[mk] = mv
  17215. }
  17216. }
  17217. dd.ReadMapEnd()
  17218. return v, changed
  17219. }
  17220. func (d *Decoder) fastpathDecMapIntfInt32R(f *codecFnInfo, rv reflect.Value) {
  17221. if rv.Kind() == reflect.Ptr {
  17222. vp := rv2i(rv).(*map[interface{}]int32)
  17223. if v, changed := fastpathTV.DecMapIntfInt32V(*vp, true, d); changed {
  17224. *vp = v
  17225. }
  17226. return
  17227. }
  17228. fastpathTV.DecMapIntfInt32V(rv2i(rv).(map[interface{}]int32), false, d)
  17229. }
  17230. func (f fastpathT) DecMapIntfInt32X(vp *map[interface{}]int32, d *Decoder) {
  17231. if v, changed := f.DecMapIntfInt32V(*vp, true, d); changed {
  17232. *vp = v
  17233. }
  17234. }
  17235. func (_ fastpathT) DecMapIntfInt32V(v map[interface{}]int32, canChange bool,
  17236. d *Decoder) (_ map[interface{}]int32, changed bool) {
  17237. dd, esep := d.d, d.hh.hasElemSeparators()
  17238. containerLen := dd.ReadMapStart()
  17239. if canChange && v == nil {
  17240. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  17241. v = make(map[interface{}]int32, xlen)
  17242. changed = true
  17243. }
  17244. if containerLen == 0 {
  17245. dd.ReadMapEnd()
  17246. return v, changed
  17247. }
  17248. var mk interface{}
  17249. var mv int32
  17250. hasLen := containerLen > 0
  17251. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17252. if esep {
  17253. dd.ReadMapElemKey()
  17254. }
  17255. mk = nil
  17256. d.decode(&mk)
  17257. if bv, bok := mk.([]byte); bok {
  17258. mk = d.string(bv)
  17259. }
  17260. if esep {
  17261. dd.ReadMapElemValue()
  17262. }
  17263. if dd.TryDecodeAsNil() {
  17264. if d.h.DeleteOnNilMapValue {
  17265. delete(v, mk)
  17266. } else {
  17267. v[mk] = 0
  17268. }
  17269. continue
  17270. }
  17271. mv = int32(dd.DecodeInt(32))
  17272. if v != nil {
  17273. v[mk] = mv
  17274. }
  17275. }
  17276. dd.ReadMapEnd()
  17277. return v, changed
  17278. }
  17279. func (d *Decoder) fastpathDecMapIntfInt64R(f *codecFnInfo, rv reflect.Value) {
  17280. if rv.Kind() == reflect.Ptr {
  17281. vp := rv2i(rv).(*map[interface{}]int64)
  17282. if v, changed := fastpathTV.DecMapIntfInt64V(*vp, true, d); changed {
  17283. *vp = v
  17284. }
  17285. return
  17286. }
  17287. fastpathTV.DecMapIntfInt64V(rv2i(rv).(map[interface{}]int64), false, d)
  17288. }
  17289. func (f fastpathT) DecMapIntfInt64X(vp *map[interface{}]int64, d *Decoder) {
  17290. if v, changed := f.DecMapIntfInt64V(*vp, true, d); changed {
  17291. *vp = v
  17292. }
  17293. }
  17294. func (_ fastpathT) DecMapIntfInt64V(v map[interface{}]int64, canChange bool,
  17295. d *Decoder) (_ map[interface{}]int64, changed bool) {
  17296. dd, esep := d.d, d.hh.hasElemSeparators()
  17297. containerLen := dd.ReadMapStart()
  17298. if canChange && v == nil {
  17299. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  17300. v = make(map[interface{}]int64, xlen)
  17301. changed = true
  17302. }
  17303. if containerLen == 0 {
  17304. dd.ReadMapEnd()
  17305. return v, changed
  17306. }
  17307. var mk interface{}
  17308. var mv int64
  17309. hasLen := containerLen > 0
  17310. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17311. if esep {
  17312. dd.ReadMapElemKey()
  17313. }
  17314. mk = nil
  17315. d.decode(&mk)
  17316. if bv, bok := mk.([]byte); bok {
  17317. mk = d.string(bv)
  17318. }
  17319. if esep {
  17320. dd.ReadMapElemValue()
  17321. }
  17322. if dd.TryDecodeAsNil() {
  17323. if d.h.DeleteOnNilMapValue {
  17324. delete(v, mk)
  17325. } else {
  17326. v[mk] = 0
  17327. }
  17328. continue
  17329. }
  17330. mv = dd.DecodeInt(64)
  17331. if v != nil {
  17332. v[mk] = mv
  17333. }
  17334. }
  17335. dd.ReadMapEnd()
  17336. return v, changed
  17337. }
  17338. func (d *Decoder) fastpathDecMapIntfFloat32R(f *codecFnInfo, rv reflect.Value) {
  17339. if rv.Kind() == reflect.Ptr {
  17340. vp := rv2i(rv).(*map[interface{}]float32)
  17341. if v, changed := fastpathTV.DecMapIntfFloat32V(*vp, true, d); changed {
  17342. *vp = v
  17343. }
  17344. return
  17345. }
  17346. fastpathTV.DecMapIntfFloat32V(rv2i(rv).(map[interface{}]float32), false, d)
  17347. }
  17348. func (f fastpathT) DecMapIntfFloat32X(vp *map[interface{}]float32, d *Decoder) {
  17349. if v, changed := f.DecMapIntfFloat32V(*vp, true, d); changed {
  17350. *vp = v
  17351. }
  17352. }
  17353. func (_ fastpathT) DecMapIntfFloat32V(v map[interface{}]float32, canChange bool,
  17354. d *Decoder) (_ map[interface{}]float32, changed bool) {
  17355. dd, esep := d.d, d.hh.hasElemSeparators()
  17356. containerLen := dd.ReadMapStart()
  17357. if canChange && v == nil {
  17358. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  17359. v = make(map[interface{}]float32, xlen)
  17360. changed = true
  17361. }
  17362. if containerLen == 0 {
  17363. dd.ReadMapEnd()
  17364. return v, changed
  17365. }
  17366. var mk interface{}
  17367. var mv float32
  17368. hasLen := containerLen > 0
  17369. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17370. if esep {
  17371. dd.ReadMapElemKey()
  17372. }
  17373. mk = nil
  17374. d.decode(&mk)
  17375. if bv, bok := mk.([]byte); bok {
  17376. mk = d.string(bv)
  17377. }
  17378. if esep {
  17379. dd.ReadMapElemValue()
  17380. }
  17381. if dd.TryDecodeAsNil() {
  17382. if d.h.DeleteOnNilMapValue {
  17383. delete(v, mk)
  17384. } else {
  17385. v[mk] = 0
  17386. }
  17387. continue
  17388. }
  17389. mv = float32(dd.DecodeFloat(true))
  17390. if v != nil {
  17391. v[mk] = mv
  17392. }
  17393. }
  17394. dd.ReadMapEnd()
  17395. return v, changed
  17396. }
  17397. func (d *Decoder) fastpathDecMapIntfFloat64R(f *codecFnInfo, rv reflect.Value) {
  17398. if rv.Kind() == reflect.Ptr {
  17399. vp := rv2i(rv).(*map[interface{}]float64)
  17400. if v, changed := fastpathTV.DecMapIntfFloat64V(*vp, true, d); changed {
  17401. *vp = v
  17402. }
  17403. return
  17404. }
  17405. fastpathTV.DecMapIntfFloat64V(rv2i(rv).(map[interface{}]float64), false, d)
  17406. }
  17407. func (f fastpathT) DecMapIntfFloat64X(vp *map[interface{}]float64, d *Decoder) {
  17408. if v, changed := f.DecMapIntfFloat64V(*vp, true, d); changed {
  17409. *vp = v
  17410. }
  17411. }
  17412. func (_ fastpathT) DecMapIntfFloat64V(v map[interface{}]float64, canChange bool,
  17413. d *Decoder) (_ map[interface{}]float64, changed bool) {
  17414. dd, esep := d.d, d.hh.hasElemSeparators()
  17415. containerLen := dd.ReadMapStart()
  17416. if canChange && v == nil {
  17417. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  17418. v = make(map[interface{}]float64, xlen)
  17419. changed = true
  17420. }
  17421. if containerLen == 0 {
  17422. dd.ReadMapEnd()
  17423. return v, changed
  17424. }
  17425. var mk interface{}
  17426. var mv float64
  17427. hasLen := containerLen > 0
  17428. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17429. if esep {
  17430. dd.ReadMapElemKey()
  17431. }
  17432. mk = nil
  17433. d.decode(&mk)
  17434. if bv, bok := mk.([]byte); bok {
  17435. mk = d.string(bv)
  17436. }
  17437. if esep {
  17438. dd.ReadMapElemValue()
  17439. }
  17440. if dd.TryDecodeAsNil() {
  17441. if d.h.DeleteOnNilMapValue {
  17442. delete(v, mk)
  17443. } else {
  17444. v[mk] = 0
  17445. }
  17446. continue
  17447. }
  17448. mv = dd.DecodeFloat(false)
  17449. if v != nil {
  17450. v[mk] = mv
  17451. }
  17452. }
  17453. dd.ReadMapEnd()
  17454. return v, changed
  17455. }
  17456. func (d *Decoder) fastpathDecMapIntfBoolR(f *codecFnInfo, rv reflect.Value) {
  17457. if rv.Kind() == reflect.Ptr {
  17458. vp := rv2i(rv).(*map[interface{}]bool)
  17459. if v, changed := fastpathTV.DecMapIntfBoolV(*vp, true, d); changed {
  17460. *vp = v
  17461. }
  17462. return
  17463. }
  17464. fastpathTV.DecMapIntfBoolV(rv2i(rv).(map[interface{}]bool), false, d)
  17465. }
  17466. func (f fastpathT) DecMapIntfBoolX(vp *map[interface{}]bool, d *Decoder) {
  17467. if v, changed := f.DecMapIntfBoolV(*vp, true, d); changed {
  17468. *vp = v
  17469. }
  17470. }
  17471. func (_ fastpathT) DecMapIntfBoolV(v map[interface{}]bool, canChange bool,
  17472. d *Decoder) (_ map[interface{}]bool, changed bool) {
  17473. dd, esep := d.d, d.hh.hasElemSeparators()
  17474. containerLen := dd.ReadMapStart()
  17475. if canChange && v == nil {
  17476. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  17477. v = make(map[interface{}]bool, xlen)
  17478. changed = true
  17479. }
  17480. if containerLen == 0 {
  17481. dd.ReadMapEnd()
  17482. return v, changed
  17483. }
  17484. var mk interface{}
  17485. var mv bool
  17486. hasLen := containerLen > 0
  17487. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17488. if esep {
  17489. dd.ReadMapElemKey()
  17490. }
  17491. mk = nil
  17492. d.decode(&mk)
  17493. if bv, bok := mk.([]byte); bok {
  17494. mk = d.string(bv)
  17495. }
  17496. if esep {
  17497. dd.ReadMapElemValue()
  17498. }
  17499. if dd.TryDecodeAsNil() {
  17500. if d.h.DeleteOnNilMapValue {
  17501. delete(v, mk)
  17502. } else {
  17503. v[mk] = false
  17504. }
  17505. continue
  17506. }
  17507. mv = dd.DecodeBool()
  17508. if v != nil {
  17509. v[mk] = mv
  17510. }
  17511. }
  17512. dd.ReadMapEnd()
  17513. return v, changed
  17514. }
  17515. func (d *Decoder) fastpathDecMapStringIntfR(f *codecFnInfo, rv reflect.Value) {
  17516. if rv.Kind() == reflect.Ptr {
  17517. vp := rv2i(rv).(*map[string]interface{})
  17518. if v, changed := fastpathTV.DecMapStringIntfV(*vp, true, d); changed {
  17519. *vp = v
  17520. }
  17521. return
  17522. }
  17523. fastpathTV.DecMapStringIntfV(rv2i(rv).(map[string]interface{}), false, d)
  17524. }
  17525. func (f fastpathT) DecMapStringIntfX(vp *map[string]interface{}, d *Decoder) {
  17526. if v, changed := f.DecMapStringIntfV(*vp, true, d); changed {
  17527. *vp = v
  17528. }
  17529. }
  17530. func (_ fastpathT) DecMapStringIntfV(v map[string]interface{}, canChange bool,
  17531. d *Decoder) (_ map[string]interface{}, changed bool) {
  17532. dd, esep := d.d, d.hh.hasElemSeparators()
  17533. containerLen := dd.ReadMapStart()
  17534. if canChange && v == nil {
  17535. xlen := decInferLen(containerLen, d.h.MaxInitLen, 32)
  17536. v = make(map[string]interface{}, xlen)
  17537. changed = true
  17538. }
  17539. if containerLen == 0 {
  17540. dd.ReadMapEnd()
  17541. return v, changed
  17542. }
  17543. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  17544. var mk string
  17545. var mv interface{}
  17546. hasLen := containerLen > 0
  17547. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17548. if esep {
  17549. dd.ReadMapElemKey()
  17550. }
  17551. mk = dd.DecodeString()
  17552. if esep {
  17553. dd.ReadMapElemValue()
  17554. }
  17555. if dd.TryDecodeAsNil() {
  17556. if d.h.DeleteOnNilMapValue {
  17557. delete(v, mk)
  17558. } else {
  17559. v[mk] = nil
  17560. }
  17561. continue
  17562. }
  17563. if mapGet {
  17564. mv = v[mk]
  17565. } else {
  17566. mv = nil
  17567. }
  17568. d.decode(&mv)
  17569. if v != nil {
  17570. v[mk] = mv
  17571. }
  17572. }
  17573. dd.ReadMapEnd()
  17574. return v, changed
  17575. }
  17576. func (d *Decoder) fastpathDecMapStringStringR(f *codecFnInfo, rv reflect.Value) {
  17577. if rv.Kind() == reflect.Ptr {
  17578. vp := rv2i(rv).(*map[string]string)
  17579. if v, changed := fastpathTV.DecMapStringStringV(*vp, true, d); changed {
  17580. *vp = v
  17581. }
  17582. return
  17583. }
  17584. fastpathTV.DecMapStringStringV(rv2i(rv).(map[string]string), false, d)
  17585. }
  17586. func (f fastpathT) DecMapStringStringX(vp *map[string]string, d *Decoder) {
  17587. if v, changed := f.DecMapStringStringV(*vp, true, d); changed {
  17588. *vp = v
  17589. }
  17590. }
  17591. func (_ fastpathT) DecMapStringStringV(v map[string]string, canChange bool,
  17592. d *Decoder) (_ map[string]string, changed bool) {
  17593. dd, esep := d.d, d.hh.hasElemSeparators()
  17594. containerLen := dd.ReadMapStart()
  17595. if canChange && v == nil {
  17596. xlen := decInferLen(containerLen, d.h.MaxInitLen, 32)
  17597. v = make(map[string]string, xlen)
  17598. changed = true
  17599. }
  17600. if containerLen == 0 {
  17601. dd.ReadMapEnd()
  17602. return v, changed
  17603. }
  17604. var mk string
  17605. var mv string
  17606. hasLen := containerLen > 0
  17607. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17608. if esep {
  17609. dd.ReadMapElemKey()
  17610. }
  17611. mk = dd.DecodeString()
  17612. if esep {
  17613. dd.ReadMapElemValue()
  17614. }
  17615. if dd.TryDecodeAsNil() {
  17616. if d.h.DeleteOnNilMapValue {
  17617. delete(v, mk)
  17618. } else {
  17619. v[mk] = ""
  17620. }
  17621. continue
  17622. }
  17623. mv = dd.DecodeString()
  17624. if v != nil {
  17625. v[mk] = mv
  17626. }
  17627. }
  17628. dd.ReadMapEnd()
  17629. return v, changed
  17630. }
  17631. func (d *Decoder) fastpathDecMapStringUintR(f *codecFnInfo, rv reflect.Value) {
  17632. if rv.Kind() == reflect.Ptr {
  17633. vp := rv2i(rv).(*map[string]uint)
  17634. if v, changed := fastpathTV.DecMapStringUintV(*vp, true, d); changed {
  17635. *vp = v
  17636. }
  17637. return
  17638. }
  17639. fastpathTV.DecMapStringUintV(rv2i(rv).(map[string]uint), false, d)
  17640. }
  17641. func (f fastpathT) DecMapStringUintX(vp *map[string]uint, d *Decoder) {
  17642. if v, changed := f.DecMapStringUintV(*vp, true, d); changed {
  17643. *vp = v
  17644. }
  17645. }
  17646. func (_ fastpathT) DecMapStringUintV(v map[string]uint, canChange bool,
  17647. d *Decoder) (_ map[string]uint, changed bool) {
  17648. dd, esep := d.d, d.hh.hasElemSeparators()
  17649. containerLen := dd.ReadMapStart()
  17650. if canChange && v == nil {
  17651. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  17652. v = make(map[string]uint, xlen)
  17653. changed = true
  17654. }
  17655. if containerLen == 0 {
  17656. dd.ReadMapEnd()
  17657. return v, changed
  17658. }
  17659. var mk string
  17660. var mv uint
  17661. hasLen := containerLen > 0
  17662. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17663. if esep {
  17664. dd.ReadMapElemKey()
  17665. }
  17666. mk = dd.DecodeString()
  17667. if esep {
  17668. dd.ReadMapElemValue()
  17669. }
  17670. if dd.TryDecodeAsNil() {
  17671. if d.h.DeleteOnNilMapValue {
  17672. delete(v, mk)
  17673. } else {
  17674. v[mk] = 0
  17675. }
  17676. continue
  17677. }
  17678. mv = uint(dd.DecodeUint(uintBitsize))
  17679. if v != nil {
  17680. v[mk] = mv
  17681. }
  17682. }
  17683. dd.ReadMapEnd()
  17684. return v, changed
  17685. }
  17686. func (d *Decoder) fastpathDecMapStringUint8R(f *codecFnInfo, rv reflect.Value) {
  17687. if rv.Kind() == reflect.Ptr {
  17688. vp := rv2i(rv).(*map[string]uint8)
  17689. if v, changed := fastpathTV.DecMapStringUint8V(*vp, true, d); changed {
  17690. *vp = v
  17691. }
  17692. return
  17693. }
  17694. fastpathTV.DecMapStringUint8V(rv2i(rv).(map[string]uint8), false, d)
  17695. }
  17696. func (f fastpathT) DecMapStringUint8X(vp *map[string]uint8, d *Decoder) {
  17697. if v, changed := f.DecMapStringUint8V(*vp, true, d); changed {
  17698. *vp = v
  17699. }
  17700. }
  17701. func (_ fastpathT) DecMapStringUint8V(v map[string]uint8, canChange bool,
  17702. d *Decoder) (_ map[string]uint8, changed bool) {
  17703. dd, esep := d.d, d.hh.hasElemSeparators()
  17704. containerLen := dd.ReadMapStart()
  17705. if canChange && v == nil {
  17706. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  17707. v = make(map[string]uint8, xlen)
  17708. changed = true
  17709. }
  17710. if containerLen == 0 {
  17711. dd.ReadMapEnd()
  17712. return v, changed
  17713. }
  17714. var mk string
  17715. var mv uint8
  17716. hasLen := containerLen > 0
  17717. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17718. if esep {
  17719. dd.ReadMapElemKey()
  17720. }
  17721. mk = dd.DecodeString()
  17722. if esep {
  17723. dd.ReadMapElemValue()
  17724. }
  17725. if dd.TryDecodeAsNil() {
  17726. if d.h.DeleteOnNilMapValue {
  17727. delete(v, mk)
  17728. } else {
  17729. v[mk] = 0
  17730. }
  17731. continue
  17732. }
  17733. mv = uint8(dd.DecodeUint(8))
  17734. if v != nil {
  17735. v[mk] = mv
  17736. }
  17737. }
  17738. dd.ReadMapEnd()
  17739. return v, changed
  17740. }
  17741. func (d *Decoder) fastpathDecMapStringUint16R(f *codecFnInfo, rv reflect.Value) {
  17742. if rv.Kind() == reflect.Ptr {
  17743. vp := rv2i(rv).(*map[string]uint16)
  17744. if v, changed := fastpathTV.DecMapStringUint16V(*vp, true, d); changed {
  17745. *vp = v
  17746. }
  17747. return
  17748. }
  17749. fastpathTV.DecMapStringUint16V(rv2i(rv).(map[string]uint16), false, d)
  17750. }
  17751. func (f fastpathT) DecMapStringUint16X(vp *map[string]uint16, d *Decoder) {
  17752. if v, changed := f.DecMapStringUint16V(*vp, true, d); changed {
  17753. *vp = v
  17754. }
  17755. }
  17756. func (_ fastpathT) DecMapStringUint16V(v map[string]uint16, canChange bool,
  17757. d *Decoder) (_ map[string]uint16, changed bool) {
  17758. dd, esep := d.d, d.hh.hasElemSeparators()
  17759. containerLen := dd.ReadMapStart()
  17760. if canChange && v == nil {
  17761. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  17762. v = make(map[string]uint16, xlen)
  17763. changed = true
  17764. }
  17765. if containerLen == 0 {
  17766. dd.ReadMapEnd()
  17767. return v, changed
  17768. }
  17769. var mk string
  17770. var mv uint16
  17771. hasLen := containerLen > 0
  17772. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17773. if esep {
  17774. dd.ReadMapElemKey()
  17775. }
  17776. mk = dd.DecodeString()
  17777. if esep {
  17778. dd.ReadMapElemValue()
  17779. }
  17780. if dd.TryDecodeAsNil() {
  17781. if d.h.DeleteOnNilMapValue {
  17782. delete(v, mk)
  17783. } else {
  17784. v[mk] = 0
  17785. }
  17786. continue
  17787. }
  17788. mv = uint16(dd.DecodeUint(16))
  17789. if v != nil {
  17790. v[mk] = mv
  17791. }
  17792. }
  17793. dd.ReadMapEnd()
  17794. return v, changed
  17795. }
  17796. func (d *Decoder) fastpathDecMapStringUint32R(f *codecFnInfo, rv reflect.Value) {
  17797. if rv.Kind() == reflect.Ptr {
  17798. vp := rv2i(rv).(*map[string]uint32)
  17799. if v, changed := fastpathTV.DecMapStringUint32V(*vp, true, d); changed {
  17800. *vp = v
  17801. }
  17802. return
  17803. }
  17804. fastpathTV.DecMapStringUint32V(rv2i(rv).(map[string]uint32), false, d)
  17805. }
  17806. func (f fastpathT) DecMapStringUint32X(vp *map[string]uint32, d *Decoder) {
  17807. if v, changed := f.DecMapStringUint32V(*vp, true, d); changed {
  17808. *vp = v
  17809. }
  17810. }
  17811. func (_ fastpathT) DecMapStringUint32V(v map[string]uint32, canChange bool,
  17812. d *Decoder) (_ map[string]uint32, changed bool) {
  17813. dd, esep := d.d, d.hh.hasElemSeparators()
  17814. containerLen := dd.ReadMapStart()
  17815. if canChange && v == nil {
  17816. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  17817. v = make(map[string]uint32, xlen)
  17818. changed = true
  17819. }
  17820. if containerLen == 0 {
  17821. dd.ReadMapEnd()
  17822. return v, changed
  17823. }
  17824. var mk string
  17825. var mv uint32
  17826. hasLen := containerLen > 0
  17827. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17828. if esep {
  17829. dd.ReadMapElemKey()
  17830. }
  17831. mk = dd.DecodeString()
  17832. if esep {
  17833. dd.ReadMapElemValue()
  17834. }
  17835. if dd.TryDecodeAsNil() {
  17836. if d.h.DeleteOnNilMapValue {
  17837. delete(v, mk)
  17838. } else {
  17839. v[mk] = 0
  17840. }
  17841. continue
  17842. }
  17843. mv = uint32(dd.DecodeUint(32))
  17844. if v != nil {
  17845. v[mk] = mv
  17846. }
  17847. }
  17848. dd.ReadMapEnd()
  17849. return v, changed
  17850. }
  17851. func (d *Decoder) fastpathDecMapStringUint64R(f *codecFnInfo, rv reflect.Value) {
  17852. if rv.Kind() == reflect.Ptr {
  17853. vp := rv2i(rv).(*map[string]uint64)
  17854. if v, changed := fastpathTV.DecMapStringUint64V(*vp, true, d); changed {
  17855. *vp = v
  17856. }
  17857. return
  17858. }
  17859. fastpathTV.DecMapStringUint64V(rv2i(rv).(map[string]uint64), false, d)
  17860. }
  17861. func (f fastpathT) DecMapStringUint64X(vp *map[string]uint64, d *Decoder) {
  17862. if v, changed := f.DecMapStringUint64V(*vp, true, d); changed {
  17863. *vp = v
  17864. }
  17865. }
  17866. func (_ fastpathT) DecMapStringUint64V(v map[string]uint64, canChange bool,
  17867. d *Decoder) (_ map[string]uint64, changed bool) {
  17868. dd, esep := d.d, d.hh.hasElemSeparators()
  17869. containerLen := dd.ReadMapStart()
  17870. if canChange && v == nil {
  17871. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  17872. v = make(map[string]uint64, xlen)
  17873. changed = true
  17874. }
  17875. if containerLen == 0 {
  17876. dd.ReadMapEnd()
  17877. return v, changed
  17878. }
  17879. var mk string
  17880. var mv uint64
  17881. hasLen := containerLen > 0
  17882. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17883. if esep {
  17884. dd.ReadMapElemKey()
  17885. }
  17886. mk = dd.DecodeString()
  17887. if esep {
  17888. dd.ReadMapElemValue()
  17889. }
  17890. if dd.TryDecodeAsNil() {
  17891. if d.h.DeleteOnNilMapValue {
  17892. delete(v, mk)
  17893. } else {
  17894. v[mk] = 0
  17895. }
  17896. continue
  17897. }
  17898. mv = dd.DecodeUint(64)
  17899. if v != nil {
  17900. v[mk] = mv
  17901. }
  17902. }
  17903. dd.ReadMapEnd()
  17904. return v, changed
  17905. }
  17906. func (d *Decoder) fastpathDecMapStringUintptrR(f *codecFnInfo, rv reflect.Value) {
  17907. if rv.Kind() == reflect.Ptr {
  17908. vp := rv2i(rv).(*map[string]uintptr)
  17909. if v, changed := fastpathTV.DecMapStringUintptrV(*vp, true, d); changed {
  17910. *vp = v
  17911. }
  17912. return
  17913. }
  17914. fastpathTV.DecMapStringUintptrV(rv2i(rv).(map[string]uintptr), false, d)
  17915. }
  17916. func (f fastpathT) DecMapStringUintptrX(vp *map[string]uintptr, d *Decoder) {
  17917. if v, changed := f.DecMapStringUintptrV(*vp, true, d); changed {
  17918. *vp = v
  17919. }
  17920. }
  17921. func (_ fastpathT) DecMapStringUintptrV(v map[string]uintptr, canChange bool,
  17922. d *Decoder) (_ map[string]uintptr, changed bool) {
  17923. dd, esep := d.d, d.hh.hasElemSeparators()
  17924. containerLen := dd.ReadMapStart()
  17925. if canChange && v == nil {
  17926. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  17927. v = make(map[string]uintptr, xlen)
  17928. changed = true
  17929. }
  17930. if containerLen == 0 {
  17931. dd.ReadMapEnd()
  17932. return v, changed
  17933. }
  17934. var mk string
  17935. var mv uintptr
  17936. hasLen := containerLen > 0
  17937. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17938. if esep {
  17939. dd.ReadMapElemKey()
  17940. }
  17941. mk = dd.DecodeString()
  17942. if esep {
  17943. dd.ReadMapElemValue()
  17944. }
  17945. if dd.TryDecodeAsNil() {
  17946. if d.h.DeleteOnNilMapValue {
  17947. delete(v, mk)
  17948. } else {
  17949. v[mk] = 0
  17950. }
  17951. continue
  17952. }
  17953. mv = uintptr(dd.DecodeUint(uintBitsize))
  17954. if v != nil {
  17955. v[mk] = mv
  17956. }
  17957. }
  17958. dd.ReadMapEnd()
  17959. return v, changed
  17960. }
  17961. func (d *Decoder) fastpathDecMapStringIntR(f *codecFnInfo, rv reflect.Value) {
  17962. if rv.Kind() == reflect.Ptr {
  17963. vp := rv2i(rv).(*map[string]int)
  17964. if v, changed := fastpathTV.DecMapStringIntV(*vp, true, d); changed {
  17965. *vp = v
  17966. }
  17967. return
  17968. }
  17969. fastpathTV.DecMapStringIntV(rv2i(rv).(map[string]int), false, d)
  17970. }
  17971. func (f fastpathT) DecMapStringIntX(vp *map[string]int, d *Decoder) {
  17972. if v, changed := f.DecMapStringIntV(*vp, true, d); changed {
  17973. *vp = v
  17974. }
  17975. }
  17976. func (_ fastpathT) DecMapStringIntV(v map[string]int, canChange bool,
  17977. d *Decoder) (_ map[string]int, changed bool) {
  17978. dd, esep := d.d, d.hh.hasElemSeparators()
  17979. containerLen := dd.ReadMapStart()
  17980. if canChange && v == nil {
  17981. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  17982. v = make(map[string]int, xlen)
  17983. changed = true
  17984. }
  17985. if containerLen == 0 {
  17986. dd.ReadMapEnd()
  17987. return v, changed
  17988. }
  17989. var mk string
  17990. var mv int
  17991. hasLen := containerLen > 0
  17992. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  17993. if esep {
  17994. dd.ReadMapElemKey()
  17995. }
  17996. mk = dd.DecodeString()
  17997. if esep {
  17998. dd.ReadMapElemValue()
  17999. }
  18000. if dd.TryDecodeAsNil() {
  18001. if d.h.DeleteOnNilMapValue {
  18002. delete(v, mk)
  18003. } else {
  18004. v[mk] = 0
  18005. }
  18006. continue
  18007. }
  18008. mv = int(dd.DecodeInt(intBitsize))
  18009. if v != nil {
  18010. v[mk] = mv
  18011. }
  18012. }
  18013. dd.ReadMapEnd()
  18014. return v, changed
  18015. }
  18016. func (d *Decoder) fastpathDecMapStringInt8R(f *codecFnInfo, rv reflect.Value) {
  18017. if rv.Kind() == reflect.Ptr {
  18018. vp := rv2i(rv).(*map[string]int8)
  18019. if v, changed := fastpathTV.DecMapStringInt8V(*vp, true, d); changed {
  18020. *vp = v
  18021. }
  18022. return
  18023. }
  18024. fastpathTV.DecMapStringInt8V(rv2i(rv).(map[string]int8), false, d)
  18025. }
  18026. func (f fastpathT) DecMapStringInt8X(vp *map[string]int8, d *Decoder) {
  18027. if v, changed := f.DecMapStringInt8V(*vp, true, d); changed {
  18028. *vp = v
  18029. }
  18030. }
  18031. func (_ fastpathT) DecMapStringInt8V(v map[string]int8, canChange bool,
  18032. d *Decoder) (_ map[string]int8, changed bool) {
  18033. dd, esep := d.d, d.hh.hasElemSeparators()
  18034. containerLen := dd.ReadMapStart()
  18035. if canChange && v == nil {
  18036. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  18037. v = make(map[string]int8, xlen)
  18038. changed = true
  18039. }
  18040. if containerLen == 0 {
  18041. dd.ReadMapEnd()
  18042. return v, changed
  18043. }
  18044. var mk string
  18045. var mv int8
  18046. hasLen := containerLen > 0
  18047. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18048. if esep {
  18049. dd.ReadMapElemKey()
  18050. }
  18051. mk = dd.DecodeString()
  18052. if esep {
  18053. dd.ReadMapElemValue()
  18054. }
  18055. if dd.TryDecodeAsNil() {
  18056. if d.h.DeleteOnNilMapValue {
  18057. delete(v, mk)
  18058. } else {
  18059. v[mk] = 0
  18060. }
  18061. continue
  18062. }
  18063. mv = int8(dd.DecodeInt(8))
  18064. if v != nil {
  18065. v[mk] = mv
  18066. }
  18067. }
  18068. dd.ReadMapEnd()
  18069. return v, changed
  18070. }
  18071. func (d *Decoder) fastpathDecMapStringInt16R(f *codecFnInfo, rv reflect.Value) {
  18072. if rv.Kind() == reflect.Ptr {
  18073. vp := rv2i(rv).(*map[string]int16)
  18074. if v, changed := fastpathTV.DecMapStringInt16V(*vp, true, d); changed {
  18075. *vp = v
  18076. }
  18077. return
  18078. }
  18079. fastpathTV.DecMapStringInt16V(rv2i(rv).(map[string]int16), false, d)
  18080. }
  18081. func (f fastpathT) DecMapStringInt16X(vp *map[string]int16, d *Decoder) {
  18082. if v, changed := f.DecMapStringInt16V(*vp, true, d); changed {
  18083. *vp = v
  18084. }
  18085. }
  18086. func (_ fastpathT) DecMapStringInt16V(v map[string]int16, canChange bool,
  18087. d *Decoder) (_ map[string]int16, changed bool) {
  18088. dd, esep := d.d, d.hh.hasElemSeparators()
  18089. containerLen := dd.ReadMapStart()
  18090. if canChange && v == nil {
  18091. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  18092. v = make(map[string]int16, xlen)
  18093. changed = true
  18094. }
  18095. if containerLen == 0 {
  18096. dd.ReadMapEnd()
  18097. return v, changed
  18098. }
  18099. var mk string
  18100. var mv int16
  18101. hasLen := containerLen > 0
  18102. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18103. if esep {
  18104. dd.ReadMapElemKey()
  18105. }
  18106. mk = dd.DecodeString()
  18107. if esep {
  18108. dd.ReadMapElemValue()
  18109. }
  18110. if dd.TryDecodeAsNil() {
  18111. if d.h.DeleteOnNilMapValue {
  18112. delete(v, mk)
  18113. } else {
  18114. v[mk] = 0
  18115. }
  18116. continue
  18117. }
  18118. mv = int16(dd.DecodeInt(16))
  18119. if v != nil {
  18120. v[mk] = mv
  18121. }
  18122. }
  18123. dd.ReadMapEnd()
  18124. return v, changed
  18125. }
  18126. func (d *Decoder) fastpathDecMapStringInt32R(f *codecFnInfo, rv reflect.Value) {
  18127. if rv.Kind() == reflect.Ptr {
  18128. vp := rv2i(rv).(*map[string]int32)
  18129. if v, changed := fastpathTV.DecMapStringInt32V(*vp, true, d); changed {
  18130. *vp = v
  18131. }
  18132. return
  18133. }
  18134. fastpathTV.DecMapStringInt32V(rv2i(rv).(map[string]int32), false, d)
  18135. }
  18136. func (f fastpathT) DecMapStringInt32X(vp *map[string]int32, d *Decoder) {
  18137. if v, changed := f.DecMapStringInt32V(*vp, true, d); changed {
  18138. *vp = v
  18139. }
  18140. }
  18141. func (_ fastpathT) DecMapStringInt32V(v map[string]int32, canChange bool,
  18142. d *Decoder) (_ map[string]int32, changed bool) {
  18143. dd, esep := d.d, d.hh.hasElemSeparators()
  18144. containerLen := dd.ReadMapStart()
  18145. if canChange && v == nil {
  18146. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  18147. v = make(map[string]int32, xlen)
  18148. changed = true
  18149. }
  18150. if containerLen == 0 {
  18151. dd.ReadMapEnd()
  18152. return v, changed
  18153. }
  18154. var mk string
  18155. var mv int32
  18156. hasLen := containerLen > 0
  18157. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18158. if esep {
  18159. dd.ReadMapElemKey()
  18160. }
  18161. mk = dd.DecodeString()
  18162. if esep {
  18163. dd.ReadMapElemValue()
  18164. }
  18165. if dd.TryDecodeAsNil() {
  18166. if d.h.DeleteOnNilMapValue {
  18167. delete(v, mk)
  18168. } else {
  18169. v[mk] = 0
  18170. }
  18171. continue
  18172. }
  18173. mv = int32(dd.DecodeInt(32))
  18174. if v != nil {
  18175. v[mk] = mv
  18176. }
  18177. }
  18178. dd.ReadMapEnd()
  18179. return v, changed
  18180. }
  18181. func (d *Decoder) fastpathDecMapStringInt64R(f *codecFnInfo, rv reflect.Value) {
  18182. if rv.Kind() == reflect.Ptr {
  18183. vp := rv2i(rv).(*map[string]int64)
  18184. if v, changed := fastpathTV.DecMapStringInt64V(*vp, true, d); changed {
  18185. *vp = v
  18186. }
  18187. return
  18188. }
  18189. fastpathTV.DecMapStringInt64V(rv2i(rv).(map[string]int64), false, d)
  18190. }
  18191. func (f fastpathT) DecMapStringInt64X(vp *map[string]int64, d *Decoder) {
  18192. if v, changed := f.DecMapStringInt64V(*vp, true, d); changed {
  18193. *vp = v
  18194. }
  18195. }
  18196. func (_ fastpathT) DecMapStringInt64V(v map[string]int64, canChange bool,
  18197. d *Decoder) (_ map[string]int64, changed bool) {
  18198. dd, esep := d.d, d.hh.hasElemSeparators()
  18199. containerLen := dd.ReadMapStart()
  18200. if canChange && v == nil {
  18201. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  18202. v = make(map[string]int64, xlen)
  18203. changed = true
  18204. }
  18205. if containerLen == 0 {
  18206. dd.ReadMapEnd()
  18207. return v, changed
  18208. }
  18209. var mk string
  18210. var mv int64
  18211. hasLen := containerLen > 0
  18212. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18213. if esep {
  18214. dd.ReadMapElemKey()
  18215. }
  18216. mk = dd.DecodeString()
  18217. if esep {
  18218. dd.ReadMapElemValue()
  18219. }
  18220. if dd.TryDecodeAsNil() {
  18221. if d.h.DeleteOnNilMapValue {
  18222. delete(v, mk)
  18223. } else {
  18224. v[mk] = 0
  18225. }
  18226. continue
  18227. }
  18228. mv = dd.DecodeInt(64)
  18229. if v != nil {
  18230. v[mk] = mv
  18231. }
  18232. }
  18233. dd.ReadMapEnd()
  18234. return v, changed
  18235. }
  18236. func (d *Decoder) fastpathDecMapStringFloat32R(f *codecFnInfo, rv reflect.Value) {
  18237. if rv.Kind() == reflect.Ptr {
  18238. vp := rv2i(rv).(*map[string]float32)
  18239. if v, changed := fastpathTV.DecMapStringFloat32V(*vp, true, d); changed {
  18240. *vp = v
  18241. }
  18242. return
  18243. }
  18244. fastpathTV.DecMapStringFloat32V(rv2i(rv).(map[string]float32), false, d)
  18245. }
  18246. func (f fastpathT) DecMapStringFloat32X(vp *map[string]float32, d *Decoder) {
  18247. if v, changed := f.DecMapStringFloat32V(*vp, true, d); changed {
  18248. *vp = v
  18249. }
  18250. }
  18251. func (_ fastpathT) DecMapStringFloat32V(v map[string]float32, canChange bool,
  18252. d *Decoder) (_ map[string]float32, changed bool) {
  18253. dd, esep := d.d, d.hh.hasElemSeparators()
  18254. containerLen := dd.ReadMapStart()
  18255. if canChange && v == nil {
  18256. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  18257. v = make(map[string]float32, xlen)
  18258. changed = true
  18259. }
  18260. if containerLen == 0 {
  18261. dd.ReadMapEnd()
  18262. return v, changed
  18263. }
  18264. var mk string
  18265. var mv float32
  18266. hasLen := containerLen > 0
  18267. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18268. if esep {
  18269. dd.ReadMapElemKey()
  18270. }
  18271. mk = dd.DecodeString()
  18272. if esep {
  18273. dd.ReadMapElemValue()
  18274. }
  18275. if dd.TryDecodeAsNil() {
  18276. if d.h.DeleteOnNilMapValue {
  18277. delete(v, mk)
  18278. } else {
  18279. v[mk] = 0
  18280. }
  18281. continue
  18282. }
  18283. mv = float32(dd.DecodeFloat(true))
  18284. if v != nil {
  18285. v[mk] = mv
  18286. }
  18287. }
  18288. dd.ReadMapEnd()
  18289. return v, changed
  18290. }
  18291. func (d *Decoder) fastpathDecMapStringFloat64R(f *codecFnInfo, rv reflect.Value) {
  18292. if rv.Kind() == reflect.Ptr {
  18293. vp := rv2i(rv).(*map[string]float64)
  18294. if v, changed := fastpathTV.DecMapStringFloat64V(*vp, true, d); changed {
  18295. *vp = v
  18296. }
  18297. return
  18298. }
  18299. fastpathTV.DecMapStringFloat64V(rv2i(rv).(map[string]float64), false, d)
  18300. }
  18301. func (f fastpathT) DecMapStringFloat64X(vp *map[string]float64, d *Decoder) {
  18302. if v, changed := f.DecMapStringFloat64V(*vp, true, d); changed {
  18303. *vp = v
  18304. }
  18305. }
  18306. func (_ fastpathT) DecMapStringFloat64V(v map[string]float64, canChange bool,
  18307. d *Decoder) (_ map[string]float64, changed bool) {
  18308. dd, esep := d.d, d.hh.hasElemSeparators()
  18309. containerLen := dd.ReadMapStart()
  18310. if canChange && v == nil {
  18311. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  18312. v = make(map[string]float64, xlen)
  18313. changed = true
  18314. }
  18315. if containerLen == 0 {
  18316. dd.ReadMapEnd()
  18317. return v, changed
  18318. }
  18319. var mk string
  18320. var mv float64
  18321. hasLen := containerLen > 0
  18322. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18323. if esep {
  18324. dd.ReadMapElemKey()
  18325. }
  18326. mk = dd.DecodeString()
  18327. if esep {
  18328. dd.ReadMapElemValue()
  18329. }
  18330. if dd.TryDecodeAsNil() {
  18331. if d.h.DeleteOnNilMapValue {
  18332. delete(v, mk)
  18333. } else {
  18334. v[mk] = 0
  18335. }
  18336. continue
  18337. }
  18338. mv = dd.DecodeFloat(false)
  18339. if v != nil {
  18340. v[mk] = mv
  18341. }
  18342. }
  18343. dd.ReadMapEnd()
  18344. return v, changed
  18345. }
  18346. func (d *Decoder) fastpathDecMapStringBoolR(f *codecFnInfo, rv reflect.Value) {
  18347. if rv.Kind() == reflect.Ptr {
  18348. vp := rv2i(rv).(*map[string]bool)
  18349. if v, changed := fastpathTV.DecMapStringBoolV(*vp, true, d); changed {
  18350. *vp = v
  18351. }
  18352. return
  18353. }
  18354. fastpathTV.DecMapStringBoolV(rv2i(rv).(map[string]bool), false, d)
  18355. }
  18356. func (f fastpathT) DecMapStringBoolX(vp *map[string]bool, d *Decoder) {
  18357. if v, changed := f.DecMapStringBoolV(*vp, true, d); changed {
  18358. *vp = v
  18359. }
  18360. }
  18361. func (_ fastpathT) DecMapStringBoolV(v map[string]bool, canChange bool,
  18362. d *Decoder) (_ map[string]bool, changed bool) {
  18363. dd, esep := d.d, d.hh.hasElemSeparators()
  18364. containerLen := dd.ReadMapStart()
  18365. if canChange && v == nil {
  18366. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  18367. v = make(map[string]bool, xlen)
  18368. changed = true
  18369. }
  18370. if containerLen == 0 {
  18371. dd.ReadMapEnd()
  18372. return v, changed
  18373. }
  18374. var mk string
  18375. var mv bool
  18376. hasLen := containerLen > 0
  18377. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18378. if esep {
  18379. dd.ReadMapElemKey()
  18380. }
  18381. mk = dd.DecodeString()
  18382. if esep {
  18383. dd.ReadMapElemValue()
  18384. }
  18385. if dd.TryDecodeAsNil() {
  18386. if d.h.DeleteOnNilMapValue {
  18387. delete(v, mk)
  18388. } else {
  18389. v[mk] = false
  18390. }
  18391. continue
  18392. }
  18393. mv = dd.DecodeBool()
  18394. if v != nil {
  18395. v[mk] = mv
  18396. }
  18397. }
  18398. dd.ReadMapEnd()
  18399. return v, changed
  18400. }
  18401. func (d *Decoder) fastpathDecMapFloat32IntfR(f *codecFnInfo, rv reflect.Value) {
  18402. if rv.Kind() == reflect.Ptr {
  18403. vp := rv2i(rv).(*map[float32]interface{})
  18404. if v, changed := fastpathTV.DecMapFloat32IntfV(*vp, true, d); changed {
  18405. *vp = v
  18406. }
  18407. return
  18408. }
  18409. fastpathTV.DecMapFloat32IntfV(rv2i(rv).(map[float32]interface{}), false, d)
  18410. }
  18411. func (f fastpathT) DecMapFloat32IntfX(vp *map[float32]interface{}, d *Decoder) {
  18412. if v, changed := f.DecMapFloat32IntfV(*vp, true, d); changed {
  18413. *vp = v
  18414. }
  18415. }
  18416. func (_ fastpathT) DecMapFloat32IntfV(v map[float32]interface{}, canChange bool,
  18417. d *Decoder) (_ map[float32]interface{}, changed bool) {
  18418. dd, esep := d.d, d.hh.hasElemSeparators()
  18419. containerLen := dd.ReadMapStart()
  18420. if canChange && v == nil {
  18421. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  18422. v = make(map[float32]interface{}, xlen)
  18423. changed = true
  18424. }
  18425. if containerLen == 0 {
  18426. dd.ReadMapEnd()
  18427. return v, changed
  18428. }
  18429. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  18430. var mk float32
  18431. var mv interface{}
  18432. hasLen := containerLen > 0
  18433. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18434. if esep {
  18435. dd.ReadMapElemKey()
  18436. }
  18437. mk = float32(dd.DecodeFloat(true))
  18438. if esep {
  18439. dd.ReadMapElemValue()
  18440. }
  18441. if dd.TryDecodeAsNil() {
  18442. if d.h.DeleteOnNilMapValue {
  18443. delete(v, mk)
  18444. } else {
  18445. v[mk] = nil
  18446. }
  18447. continue
  18448. }
  18449. if mapGet {
  18450. mv = v[mk]
  18451. } else {
  18452. mv = nil
  18453. }
  18454. d.decode(&mv)
  18455. if v != nil {
  18456. v[mk] = mv
  18457. }
  18458. }
  18459. dd.ReadMapEnd()
  18460. return v, changed
  18461. }
  18462. func (d *Decoder) fastpathDecMapFloat32StringR(f *codecFnInfo, rv reflect.Value) {
  18463. if rv.Kind() == reflect.Ptr {
  18464. vp := rv2i(rv).(*map[float32]string)
  18465. if v, changed := fastpathTV.DecMapFloat32StringV(*vp, true, d); changed {
  18466. *vp = v
  18467. }
  18468. return
  18469. }
  18470. fastpathTV.DecMapFloat32StringV(rv2i(rv).(map[float32]string), false, d)
  18471. }
  18472. func (f fastpathT) DecMapFloat32StringX(vp *map[float32]string, d *Decoder) {
  18473. if v, changed := f.DecMapFloat32StringV(*vp, true, d); changed {
  18474. *vp = v
  18475. }
  18476. }
  18477. func (_ fastpathT) DecMapFloat32StringV(v map[float32]string, canChange bool,
  18478. d *Decoder) (_ map[float32]string, changed bool) {
  18479. dd, esep := d.d, d.hh.hasElemSeparators()
  18480. containerLen := dd.ReadMapStart()
  18481. if canChange && v == nil {
  18482. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  18483. v = make(map[float32]string, xlen)
  18484. changed = true
  18485. }
  18486. if containerLen == 0 {
  18487. dd.ReadMapEnd()
  18488. return v, changed
  18489. }
  18490. var mk float32
  18491. var mv string
  18492. hasLen := containerLen > 0
  18493. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18494. if esep {
  18495. dd.ReadMapElemKey()
  18496. }
  18497. mk = float32(dd.DecodeFloat(true))
  18498. if esep {
  18499. dd.ReadMapElemValue()
  18500. }
  18501. if dd.TryDecodeAsNil() {
  18502. if d.h.DeleteOnNilMapValue {
  18503. delete(v, mk)
  18504. } else {
  18505. v[mk] = ""
  18506. }
  18507. continue
  18508. }
  18509. mv = dd.DecodeString()
  18510. if v != nil {
  18511. v[mk] = mv
  18512. }
  18513. }
  18514. dd.ReadMapEnd()
  18515. return v, changed
  18516. }
  18517. func (d *Decoder) fastpathDecMapFloat32UintR(f *codecFnInfo, rv reflect.Value) {
  18518. if rv.Kind() == reflect.Ptr {
  18519. vp := rv2i(rv).(*map[float32]uint)
  18520. if v, changed := fastpathTV.DecMapFloat32UintV(*vp, true, d); changed {
  18521. *vp = v
  18522. }
  18523. return
  18524. }
  18525. fastpathTV.DecMapFloat32UintV(rv2i(rv).(map[float32]uint), false, d)
  18526. }
  18527. func (f fastpathT) DecMapFloat32UintX(vp *map[float32]uint, d *Decoder) {
  18528. if v, changed := f.DecMapFloat32UintV(*vp, true, d); changed {
  18529. *vp = v
  18530. }
  18531. }
  18532. func (_ fastpathT) DecMapFloat32UintV(v map[float32]uint, canChange bool,
  18533. d *Decoder) (_ map[float32]uint, changed bool) {
  18534. dd, esep := d.d, d.hh.hasElemSeparators()
  18535. containerLen := dd.ReadMapStart()
  18536. if canChange && v == nil {
  18537. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  18538. v = make(map[float32]uint, xlen)
  18539. changed = true
  18540. }
  18541. if containerLen == 0 {
  18542. dd.ReadMapEnd()
  18543. return v, changed
  18544. }
  18545. var mk float32
  18546. var mv uint
  18547. hasLen := containerLen > 0
  18548. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18549. if esep {
  18550. dd.ReadMapElemKey()
  18551. }
  18552. mk = float32(dd.DecodeFloat(true))
  18553. if esep {
  18554. dd.ReadMapElemValue()
  18555. }
  18556. if dd.TryDecodeAsNil() {
  18557. if d.h.DeleteOnNilMapValue {
  18558. delete(v, mk)
  18559. } else {
  18560. v[mk] = 0
  18561. }
  18562. continue
  18563. }
  18564. mv = uint(dd.DecodeUint(uintBitsize))
  18565. if v != nil {
  18566. v[mk] = mv
  18567. }
  18568. }
  18569. dd.ReadMapEnd()
  18570. return v, changed
  18571. }
  18572. func (d *Decoder) fastpathDecMapFloat32Uint8R(f *codecFnInfo, rv reflect.Value) {
  18573. if rv.Kind() == reflect.Ptr {
  18574. vp := rv2i(rv).(*map[float32]uint8)
  18575. if v, changed := fastpathTV.DecMapFloat32Uint8V(*vp, true, d); changed {
  18576. *vp = v
  18577. }
  18578. return
  18579. }
  18580. fastpathTV.DecMapFloat32Uint8V(rv2i(rv).(map[float32]uint8), false, d)
  18581. }
  18582. func (f fastpathT) DecMapFloat32Uint8X(vp *map[float32]uint8, d *Decoder) {
  18583. if v, changed := f.DecMapFloat32Uint8V(*vp, true, d); changed {
  18584. *vp = v
  18585. }
  18586. }
  18587. func (_ fastpathT) DecMapFloat32Uint8V(v map[float32]uint8, canChange bool,
  18588. d *Decoder) (_ map[float32]uint8, changed bool) {
  18589. dd, esep := d.d, d.hh.hasElemSeparators()
  18590. containerLen := dd.ReadMapStart()
  18591. if canChange && v == nil {
  18592. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  18593. v = make(map[float32]uint8, xlen)
  18594. changed = true
  18595. }
  18596. if containerLen == 0 {
  18597. dd.ReadMapEnd()
  18598. return v, changed
  18599. }
  18600. var mk float32
  18601. var mv uint8
  18602. hasLen := containerLen > 0
  18603. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18604. if esep {
  18605. dd.ReadMapElemKey()
  18606. }
  18607. mk = float32(dd.DecodeFloat(true))
  18608. if esep {
  18609. dd.ReadMapElemValue()
  18610. }
  18611. if dd.TryDecodeAsNil() {
  18612. if d.h.DeleteOnNilMapValue {
  18613. delete(v, mk)
  18614. } else {
  18615. v[mk] = 0
  18616. }
  18617. continue
  18618. }
  18619. mv = uint8(dd.DecodeUint(8))
  18620. if v != nil {
  18621. v[mk] = mv
  18622. }
  18623. }
  18624. dd.ReadMapEnd()
  18625. return v, changed
  18626. }
  18627. func (d *Decoder) fastpathDecMapFloat32Uint16R(f *codecFnInfo, rv reflect.Value) {
  18628. if rv.Kind() == reflect.Ptr {
  18629. vp := rv2i(rv).(*map[float32]uint16)
  18630. if v, changed := fastpathTV.DecMapFloat32Uint16V(*vp, true, d); changed {
  18631. *vp = v
  18632. }
  18633. return
  18634. }
  18635. fastpathTV.DecMapFloat32Uint16V(rv2i(rv).(map[float32]uint16), false, d)
  18636. }
  18637. func (f fastpathT) DecMapFloat32Uint16X(vp *map[float32]uint16, d *Decoder) {
  18638. if v, changed := f.DecMapFloat32Uint16V(*vp, true, d); changed {
  18639. *vp = v
  18640. }
  18641. }
  18642. func (_ fastpathT) DecMapFloat32Uint16V(v map[float32]uint16, canChange bool,
  18643. d *Decoder) (_ map[float32]uint16, changed bool) {
  18644. dd, esep := d.d, d.hh.hasElemSeparators()
  18645. containerLen := dd.ReadMapStart()
  18646. if canChange && v == nil {
  18647. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  18648. v = make(map[float32]uint16, xlen)
  18649. changed = true
  18650. }
  18651. if containerLen == 0 {
  18652. dd.ReadMapEnd()
  18653. return v, changed
  18654. }
  18655. var mk float32
  18656. var mv uint16
  18657. hasLen := containerLen > 0
  18658. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18659. if esep {
  18660. dd.ReadMapElemKey()
  18661. }
  18662. mk = float32(dd.DecodeFloat(true))
  18663. if esep {
  18664. dd.ReadMapElemValue()
  18665. }
  18666. if dd.TryDecodeAsNil() {
  18667. if d.h.DeleteOnNilMapValue {
  18668. delete(v, mk)
  18669. } else {
  18670. v[mk] = 0
  18671. }
  18672. continue
  18673. }
  18674. mv = uint16(dd.DecodeUint(16))
  18675. if v != nil {
  18676. v[mk] = mv
  18677. }
  18678. }
  18679. dd.ReadMapEnd()
  18680. return v, changed
  18681. }
  18682. func (d *Decoder) fastpathDecMapFloat32Uint32R(f *codecFnInfo, rv reflect.Value) {
  18683. if rv.Kind() == reflect.Ptr {
  18684. vp := rv2i(rv).(*map[float32]uint32)
  18685. if v, changed := fastpathTV.DecMapFloat32Uint32V(*vp, true, d); changed {
  18686. *vp = v
  18687. }
  18688. return
  18689. }
  18690. fastpathTV.DecMapFloat32Uint32V(rv2i(rv).(map[float32]uint32), false, d)
  18691. }
  18692. func (f fastpathT) DecMapFloat32Uint32X(vp *map[float32]uint32, d *Decoder) {
  18693. if v, changed := f.DecMapFloat32Uint32V(*vp, true, d); changed {
  18694. *vp = v
  18695. }
  18696. }
  18697. func (_ fastpathT) DecMapFloat32Uint32V(v map[float32]uint32, canChange bool,
  18698. d *Decoder) (_ map[float32]uint32, changed bool) {
  18699. dd, esep := d.d, d.hh.hasElemSeparators()
  18700. containerLen := dd.ReadMapStart()
  18701. if canChange && v == nil {
  18702. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  18703. v = make(map[float32]uint32, xlen)
  18704. changed = true
  18705. }
  18706. if containerLen == 0 {
  18707. dd.ReadMapEnd()
  18708. return v, changed
  18709. }
  18710. var mk float32
  18711. var mv uint32
  18712. hasLen := containerLen > 0
  18713. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18714. if esep {
  18715. dd.ReadMapElemKey()
  18716. }
  18717. mk = float32(dd.DecodeFloat(true))
  18718. if esep {
  18719. dd.ReadMapElemValue()
  18720. }
  18721. if dd.TryDecodeAsNil() {
  18722. if d.h.DeleteOnNilMapValue {
  18723. delete(v, mk)
  18724. } else {
  18725. v[mk] = 0
  18726. }
  18727. continue
  18728. }
  18729. mv = uint32(dd.DecodeUint(32))
  18730. if v != nil {
  18731. v[mk] = mv
  18732. }
  18733. }
  18734. dd.ReadMapEnd()
  18735. return v, changed
  18736. }
  18737. func (d *Decoder) fastpathDecMapFloat32Uint64R(f *codecFnInfo, rv reflect.Value) {
  18738. if rv.Kind() == reflect.Ptr {
  18739. vp := rv2i(rv).(*map[float32]uint64)
  18740. if v, changed := fastpathTV.DecMapFloat32Uint64V(*vp, true, d); changed {
  18741. *vp = v
  18742. }
  18743. return
  18744. }
  18745. fastpathTV.DecMapFloat32Uint64V(rv2i(rv).(map[float32]uint64), false, d)
  18746. }
  18747. func (f fastpathT) DecMapFloat32Uint64X(vp *map[float32]uint64, d *Decoder) {
  18748. if v, changed := f.DecMapFloat32Uint64V(*vp, true, d); changed {
  18749. *vp = v
  18750. }
  18751. }
  18752. func (_ fastpathT) DecMapFloat32Uint64V(v map[float32]uint64, canChange bool,
  18753. d *Decoder) (_ map[float32]uint64, changed bool) {
  18754. dd, esep := d.d, d.hh.hasElemSeparators()
  18755. containerLen := dd.ReadMapStart()
  18756. if canChange && v == nil {
  18757. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  18758. v = make(map[float32]uint64, xlen)
  18759. changed = true
  18760. }
  18761. if containerLen == 0 {
  18762. dd.ReadMapEnd()
  18763. return v, changed
  18764. }
  18765. var mk float32
  18766. var mv uint64
  18767. hasLen := containerLen > 0
  18768. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18769. if esep {
  18770. dd.ReadMapElemKey()
  18771. }
  18772. mk = float32(dd.DecodeFloat(true))
  18773. if esep {
  18774. dd.ReadMapElemValue()
  18775. }
  18776. if dd.TryDecodeAsNil() {
  18777. if d.h.DeleteOnNilMapValue {
  18778. delete(v, mk)
  18779. } else {
  18780. v[mk] = 0
  18781. }
  18782. continue
  18783. }
  18784. mv = dd.DecodeUint(64)
  18785. if v != nil {
  18786. v[mk] = mv
  18787. }
  18788. }
  18789. dd.ReadMapEnd()
  18790. return v, changed
  18791. }
  18792. func (d *Decoder) fastpathDecMapFloat32UintptrR(f *codecFnInfo, rv reflect.Value) {
  18793. if rv.Kind() == reflect.Ptr {
  18794. vp := rv2i(rv).(*map[float32]uintptr)
  18795. if v, changed := fastpathTV.DecMapFloat32UintptrV(*vp, true, d); changed {
  18796. *vp = v
  18797. }
  18798. return
  18799. }
  18800. fastpathTV.DecMapFloat32UintptrV(rv2i(rv).(map[float32]uintptr), false, d)
  18801. }
  18802. func (f fastpathT) DecMapFloat32UintptrX(vp *map[float32]uintptr, d *Decoder) {
  18803. if v, changed := f.DecMapFloat32UintptrV(*vp, true, d); changed {
  18804. *vp = v
  18805. }
  18806. }
  18807. func (_ fastpathT) DecMapFloat32UintptrV(v map[float32]uintptr, canChange bool,
  18808. d *Decoder) (_ map[float32]uintptr, changed bool) {
  18809. dd, esep := d.d, d.hh.hasElemSeparators()
  18810. containerLen := dd.ReadMapStart()
  18811. if canChange && v == nil {
  18812. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  18813. v = make(map[float32]uintptr, xlen)
  18814. changed = true
  18815. }
  18816. if containerLen == 0 {
  18817. dd.ReadMapEnd()
  18818. return v, changed
  18819. }
  18820. var mk float32
  18821. var mv uintptr
  18822. hasLen := containerLen > 0
  18823. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18824. if esep {
  18825. dd.ReadMapElemKey()
  18826. }
  18827. mk = float32(dd.DecodeFloat(true))
  18828. if esep {
  18829. dd.ReadMapElemValue()
  18830. }
  18831. if dd.TryDecodeAsNil() {
  18832. if d.h.DeleteOnNilMapValue {
  18833. delete(v, mk)
  18834. } else {
  18835. v[mk] = 0
  18836. }
  18837. continue
  18838. }
  18839. mv = uintptr(dd.DecodeUint(uintBitsize))
  18840. if v != nil {
  18841. v[mk] = mv
  18842. }
  18843. }
  18844. dd.ReadMapEnd()
  18845. return v, changed
  18846. }
  18847. func (d *Decoder) fastpathDecMapFloat32IntR(f *codecFnInfo, rv reflect.Value) {
  18848. if rv.Kind() == reflect.Ptr {
  18849. vp := rv2i(rv).(*map[float32]int)
  18850. if v, changed := fastpathTV.DecMapFloat32IntV(*vp, true, d); changed {
  18851. *vp = v
  18852. }
  18853. return
  18854. }
  18855. fastpathTV.DecMapFloat32IntV(rv2i(rv).(map[float32]int), false, d)
  18856. }
  18857. func (f fastpathT) DecMapFloat32IntX(vp *map[float32]int, d *Decoder) {
  18858. if v, changed := f.DecMapFloat32IntV(*vp, true, d); changed {
  18859. *vp = v
  18860. }
  18861. }
  18862. func (_ fastpathT) DecMapFloat32IntV(v map[float32]int, canChange bool,
  18863. d *Decoder) (_ map[float32]int, changed bool) {
  18864. dd, esep := d.d, d.hh.hasElemSeparators()
  18865. containerLen := dd.ReadMapStart()
  18866. if canChange && v == nil {
  18867. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  18868. v = make(map[float32]int, xlen)
  18869. changed = true
  18870. }
  18871. if containerLen == 0 {
  18872. dd.ReadMapEnd()
  18873. return v, changed
  18874. }
  18875. var mk float32
  18876. var mv int
  18877. hasLen := containerLen > 0
  18878. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18879. if esep {
  18880. dd.ReadMapElemKey()
  18881. }
  18882. mk = float32(dd.DecodeFloat(true))
  18883. if esep {
  18884. dd.ReadMapElemValue()
  18885. }
  18886. if dd.TryDecodeAsNil() {
  18887. if d.h.DeleteOnNilMapValue {
  18888. delete(v, mk)
  18889. } else {
  18890. v[mk] = 0
  18891. }
  18892. continue
  18893. }
  18894. mv = int(dd.DecodeInt(intBitsize))
  18895. if v != nil {
  18896. v[mk] = mv
  18897. }
  18898. }
  18899. dd.ReadMapEnd()
  18900. return v, changed
  18901. }
  18902. func (d *Decoder) fastpathDecMapFloat32Int8R(f *codecFnInfo, rv reflect.Value) {
  18903. if rv.Kind() == reflect.Ptr {
  18904. vp := rv2i(rv).(*map[float32]int8)
  18905. if v, changed := fastpathTV.DecMapFloat32Int8V(*vp, true, d); changed {
  18906. *vp = v
  18907. }
  18908. return
  18909. }
  18910. fastpathTV.DecMapFloat32Int8V(rv2i(rv).(map[float32]int8), false, d)
  18911. }
  18912. func (f fastpathT) DecMapFloat32Int8X(vp *map[float32]int8, d *Decoder) {
  18913. if v, changed := f.DecMapFloat32Int8V(*vp, true, d); changed {
  18914. *vp = v
  18915. }
  18916. }
  18917. func (_ fastpathT) DecMapFloat32Int8V(v map[float32]int8, canChange bool,
  18918. d *Decoder) (_ map[float32]int8, changed bool) {
  18919. dd, esep := d.d, d.hh.hasElemSeparators()
  18920. containerLen := dd.ReadMapStart()
  18921. if canChange && v == nil {
  18922. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  18923. v = make(map[float32]int8, xlen)
  18924. changed = true
  18925. }
  18926. if containerLen == 0 {
  18927. dd.ReadMapEnd()
  18928. return v, changed
  18929. }
  18930. var mk float32
  18931. var mv int8
  18932. hasLen := containerLen > 0
  18933. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18934. if esep {
  18935. dd.ReadMapElemKey()
  18936. }
  18937. mk = float32(dd.DecodeFloat(true))
  18938. if esep {
  18939. dd.ReadMapElemValue()
  18940. }
  18941. if dd.TryDecodeAsNil() {
  18942. if d.h.DeleteOnNilMapValue {
  18943. delete(v, mk)
  18944. } else {
  18945. v[mk] = 0
  18946. }
  18947. continue
  18948. }
  18949. mv = int8(dd.DecodeInt(8))
  18950. if v != nil {
  18951. v[mk] = mv
  18952. }
  18953. }
  18954. dd.ReadMapEnd()
  18955. return v, changed
  18956. }
  18957. func (d *Decoder) fastpathDecMapFloat32Int16R(f *codecFnInfo, rv reflect.Value) {
  18958. if rv.Kind() == reflect.Ptr {
  18959. vp := rv2i(rv).(*map[float32]int16)
  18960. if v, changed := fastpathTV.DecMapFloat32Int16V(*vp, true, d); changed {
  18961. *vp = v
  18962. }
  18963. return
  18964. }
  18965. fastpathTV.DecMapFloat32Int16V(rv2i(rv).(map[float32]int16), false, d)
  18966. }
  18967. func (f fastpathT) DecMapFloat32Int16X(vp *map[float32]int16, d *Decoder) {
  18968. if v, changed := f.DecMapFloat32Int16V(*vp, true, d); changed {
  18969. *vp = v
  18970. }
  18971. }
  18972. func (_ fastpathT) DecMapFloat32Int16V(v map[float32]int16, canChange bool,
  18973. d *Decoder) (_ map[float32]int16, changed bool) {
  18974. dd, esep := d.d, d.hh.hasElemSeparators()
  18975. containerLen := dd.ReadMapStart()
  18976. if canChange && v == nil {
  18977. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  18978. v = make(map[float32]int16, xlen)
  18979. changed = true
  18980. }
  18981. if containerLen == 0 {
  18982. dd.ReadMapEnd()
  18983. return v, changed
  18984. }
  18985. var mk float32
  18986. var mv int16
  18987. hasLen := containerLen > 0
  18988. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  18989. if esep {
  18990. dd.ReadMapElemKey()
  18991. }
  18992. mk = float32(dd.DecodeFloat(true))
  18993. if esep {
  18994. dd.ReadMapElemValue()
  18995. }
  18996. if dd.TryDecodeAsNil() {
  18997. if d.h.DeleteOnNilMapValue {
  18998. delete(v, mk)
  18999. } else {
  19000. v[mk] = 0
  19001. }
  19002. continue
  19003. }
  19004. mv = int16(dd.DecodeInt(16))
  19005. if v != nil {
  19006. v[mk] = mv
  19007. }
  19008. }
  19009. dd.ReadMapEnd()
  19010. return v, changed
  19011. }
  19012. func (d *Decoder) fastpathDecMapFloat32Int32R(f *codecFnInfo, rv reflect.Value) {
  19013. if rv.Kind() == reflect.Ptr {
  19014. vp := rv2i(rv).(*map[float32]int32)
  19015. if v, changed := fastpathTV.DecMapFloat32Int32V(*vp, true, d); changed {
  19016. *vp = v
  19017. }
  19018. return
  19019. }
  19020. fastpathTV.DecMapFloat32Int32V(rv2i(rv).(map[float32]int32), false, d)
  19021. }
  19022. func (f fastpathT) DecMapFloat32Int32X(vp *map[float32]int32, d *Decoder) {
  19023. if v, changed := f.DecMapFloat32Int32V(*vp, true, d); changed {
  19024. *vp = v
  19025. }
  19026. }
  19027. func (_ fastpathT) DecMapFloat32Int32V(v map[float32]int32, canChange bool,
  19028. d *Decoder) (_ map[float32]int32, changed bool) {
  19029. dd, esep := d.d, d.hh.hasElemSeparators()
  19030. containerLen := dd.ReadMapStart()
  19031. if canChange && v == nil {
  19032. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  19033. v = make(map[float32]int32, xlen)
  19034. changed = true
  19035. }
  19036. if containerLen == 0 {
  19037. dd.ReadMapEnd()
  19038. return v, changed
  19039. }
  19040. var mk float32
  19041. var mv int32
  19042. hasLen := containerLen > 0
  19043. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19044. if esep {
  19045. dd.ReadMapElemKey()
  19046. }
  19047. mk = float32(dd.DecodeFloat(true))
  19048. if esep {
  19049. dd.ReadMapElemValue()
  19050. }
  19051. if dd.TryDecodeAsNil() {
  19052. if d.h.DeleteOnNilMapValue {
  19053. delete(v, mk)
  19054. } else {
  19055. v[mk] = 0
  19056. }
  19057. continue
  19058. }
  19059. mv = int32(dd.DecodeInt(32))
  19060. if v != nil {
  19061. v[mk] = mv
  19062. }
  19063. }
  19064. dd.ReadMapEnd()
  19065. return v, changed
  19066. }
  19067. func (d *Decoder) fastpathDecMapFloat32Int64R(f *codecFnInfo, rv reflect.Value) {
  19068. if rv.Kind() == reflect.Ptr {
  19069. vp := rv2i(rv).(*map[float32]int64)
  19070. if v, changed := fastpathTV.DecMapFloat32Int64V(*vp, true, d); changed {
  19071. *vp = v
  19072. }
  19073. return
  19074. }
  19075. fastpathTV.DecMapFloat32Int64V(rv2i(rv).(map[float32]int64), false, d)
  19076. }
  19077. func (f fastpathT) DecMapFloat32Int64X(vp *map[float32]int64, d *Decoder) {
  19078. if v, changed := f.DecMapFloat32Int64V(*vp, true, d); changed {
  19079. *vp = v
  19080. }
  19081. }
  19082. func (_ fastpathT) DecMapFloat32Int64V(v map[float32]int64, canChange bool,
  19083. d *Decoder) (_ map[float32]int64, changed bool) {
  19084. dd, esep := d.d, d.hh.hasElemSeparators()
  19085. containerLen := dd.ReadMapStart()
  19086. if canChange && v == nil {
  19087. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  19088. v = make(map[float32]int64, xlen)
  19089. changed = true
  19090. }
  19091. if containerLen == 0 {
  19092. dd.ReadMapEnd()
  19093. return v, changed
  19094. }
  19095. var mk float32
  19096. var mv int64
  19097. hasLen := containerLen > 0
  19098. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19099. if esep {
  19100. dd.ReadMapElemKey()
  19101. }
  19102. mk = float32(dd.DecodeFloat(true))
  19103. if esep {
  19104. dd.ReadMapElemValue()
  19105. }
  19106. if dd.TryDecodeAsNil() {
  19107. if d.h.DeleteOnNilMapValue {
  19108. delete(v, mk)
  19109. } else {
  19110. v[mk] = 0
  19111. }
  19112. continue
  19113. }
  19114. mv = dd.DecodeInt(64)
  19115. if v != nil {
  19116. v[mk] = mv
  19117. }
  19118. }
  19119. dd.ReadMapEnd()
  19120. return v, changed
  19121. }
  19122. func (d *Decoder) fastpathDecMapFloat32Float32R(f *codecFnInfo, rv reflect.Value) {
  19123. if rv.Kind() == reflect.Ptr {
  19124. vp := rv2i(rv).(*map[float32]float32)
  19125. if v, changed := fastpathTV.DecMapFloat32Float32V(*vp, true, d); changed {
  19126. *vp = v
  19127. }
  19128. return
  19129. }
  19130. fastpathTV.DecMapFloat32Float32V(rv2i(rv).(map[float32]float32), false, d)
  19131. }
  19132. func (f fastpathT) DecMapFloat32Float32X(vp *map[float32]float32, d *Decoder) {
  19133. if v, changed := f.DecMapFloat32Float32V(*vp, true, d); changed {
  19134. *vp = v
  19135. }
  19136. }
  19137. func (_ fastpathT) DecMapFloat32Float32V(v map[float32]float32, canChange bool,
  19138. d *Decoder) (_ map[float32]float32, changed bool) {
  19139. dd, esep := d.d, d.hh.hasElemSeparators()
  19140. containerLen := dd.ReadMapStart()
  19141. if canChange && v == nil {
  19142. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  19143. v = make(map[float32]float32, xlen)
  19144. changed = true
  19145. }
  19146. if containerLen == 0 {
  19147. dd.ReadMapEnd()
  19148. return v, changed
  19149. }
  19150. var mk float32
  19151. var mv float32
  19152. hasLen := containerLen > 0
  19153. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19154. if esep {
  19155. dd.ReadMapElemKey()
  19156. }
  19157. mk = float32(dd.DecodeFloat(true))
  19158. if esep {
  19159. dd.ReadMapElemValue()
  19160. }
  19161. if dd.TryDecodeAsNil() {
  19162. if d.h.DeleteOnNilMapValue {
  19163. delete(v, mk)
  19164. } else {
  19165. v[mk] = 0
  19166. }
  19167. continue
  19168. }
  19169. mv = float32(dd.DecodeFloat(true))
  19170. if v != nil {
  19171. v[mk] = mv
  19172. }
  19173. }
  19174. dd.ReadMapEnd()
  19175. return v, changed
  19176. }
  19177. func (d *Decoder) fastpathDecMapFloat32Float64R(f *codecFnInfo, rv reflect.Value) {
  19178. if rv.Kind() == reflect.Ptr {
  19179. vp := rv2i(rv).(*map[float32]float64)
  19180. if v, changed := fastpathTV.DecMapFloat32Float64V(*vp, true, d); changed {
  19181. *vp = v
  19182. }
  19183. return
  19184. }
  19185. fastpathTV.DecMapFloat32Float64V(rv2i(rv).(map[float32]float64), false, d)
  19186. }
  19187. func (f fastpathT) DecMapFloat32Float64X(vp *map[float32]float64, d *Decoder) {
  19188. if v, changed := f.DecMapFloat32Float64V(*vp, true, d); changed {
  19189. *vp = v
  19190. }
  19191. }
  19192. func (_ fastpathT) DecMapFloat32Float64V(v map[float32]float64, canChange bool,
  19193. d *Decoder) (_ map[float32]float64, changed bool) {
  19194. dd, esep := d.d, d.hh.hasElemSeparators()
  19195. containerLen := dd.ReadMapStart()
  19196. if canChange && v == nil {
  19197. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  19198. v = make(map[float32]float64, xlen)
  19199. changed = true
  19200. }
  19201. if containerLen == 0 {
  19202. dd.ReadMapEnd()
  19203. return v, changed
  19204. }
  19205. var mk float32
  19206. var mv float64
  19207. hasLen := containerLen > 0
  19208. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19209. if esep {
  19210. dd.ReadMapElemKey()
  19211. }
  19212. mk = float32(dd.DecodeFloat(true))
  19213. if esep {
  19214. dd.ReadMapElemValue()
  19215. }
  19216. if dd.TryDecodeAsNil() {
  19217. if d.h.DeleteOnNilMapValue {
  19218. delete(v, mk)
  19219. } else {
  19220. v[mk] = 0
  19221. }
  19222. continue
  19223. }
  19224. mv = dd.DecodeFloat(false)
  19225. if v != nil {
  19226. v[mk] = mv
  19227. }
  19228. }
  19229. dd.ReadMapEnd()
  19230. return v, changed
  19231. }
  19232. func (d *Decoder) fastpathDecMapFloat32BoolR(f *codecFnInfo, rv reflect.Value) {
  19233. if rv.Kind() == reflect.Ptr {
  19234. vp := rv2i(rv).(*map[float32]bool)
  19235. if v, changed := fastpathTV.DecMapFloat32BoolV(*vp, true, d); changed {
  19236. *vp = v
  19237. }
  19238. return
  19239. }
  19240. fastpathTV.DecMapFloat32BoolV(rv2i(rv).(map[float32]bool), false, d)
  19241. }
  19242. func (f fastpathT) DecMapFloat32BoolX(vp *map[float32]bool, d *Decoder) {
  19243. if v, changed := f.DecMapFloat32BoolV(*vp, true, d); changed {
  19244. *vp = v
  19245. }
  19246. }
  19247. func (_ fastpathT) DecMapFloat32BoolV(v map[float32]bool, canChange bool,
  19248. d *Decoder) (_ map[float32]bool, changed bool) {
  19249. dd, esep := d.d, d.hh.hasElemSeparators()
  19250. containerLen := dd.ReadMapStart()
  19251. if canChange && v == nil {
  19252. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  19253. v = make(map[float32]bool, xlen)
  19254. changed = true
  19255. }
  19256. if containerLen == 0 {
  19257. dd.ReadMapEnd()
  19258. return v, changed
  19259. }
  19260. var mk float32
  19261. var mv bool
  19262. hasLen := containerLen > 0
  19263. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19264. if esep {
  19265. dd.ReadMapElemKey()
  19266. }
  19267. mk = float32(dd.DecodeFloat(true))
  19268. if esep {
  19269. dd.ReadMapElemValue()
  19270. }
  19271. if dd.TryDecodeAsNil() {
  19272. if d.h.DeleteOnNilMapValue {
  19273. delete(v, mk)
  19274. } else {
  19275. v[mk] = false
  19276. }
  19277. continue
  19278. }
  19279. mv = dd.DecodeBool()
  19280. if v != nil {
  19281. v[mk] = mv
  19282. }
  19283. }
  19284. dd.ReadMapEnd()
  19285. return v, changed
  19286. }
  19287. func (d *Decoder) fastpathDecMapFloat64IntfR(f *codecFnInfo, rv reflect.Value) {
  19288. if rv.Kind() == reflect.Ptr {
  19289. vp := rv2i(rv).(*map[float64]interface{})
  19290. if v, changed := fastpathTV.DecMapFloat64IntfV(*vp, true, d); changed {
  19291. *vp = v
  19292. }
  19293. return
  19294. }
  19295. fastpathTV.DecMapFloat64IntfV(rv2i(rv).(map[float64]interface{}), false, d)
  19296. }
  19297. func (f fastpathT) DecMapFloat64IntfX(vp *map[float64]interface{}, d *Decoder) {
  19298. if v, changed := f.DecMapFloat64IntfV(*vp, true, d); changed {
  19299. *vp = v
  19300. }
  19301. }
  19302. func (_ fastpathT) DecMapFloat64IntfV(v map[float64]interface{}, canChange bool,
  19303. d *Decoder) (_ map[float64]interface{}, changed bool) {
  19304. dd, esep := d.d, d.hh.hasElemSeparators()
  19305. containerLen := dd.ReadMapStart()
  19306. if canChange && v == nil {
  19307. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  19308. v = make(map[float64]interface{}, xlen)
  19309. changed = true
  19310. }
  19311. if containerLen == 0 {
  19312. dd.ReadMapEnd()
  19313. return v, changed
  19314. }
  19315. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  19316. var mk float64
  19317. var mv interface{}
  19318. hasLen := containerLen > 0
  19319. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19320. if esep {
  19321. dd.ReadMapElemKey()
  19322. }
  19323. mk = dd.DecodeFloat(false)
  19324. if esep {
  19325. dd.ReadMapElemValue()
  19326. }
  19327. if dd.TryDecodeAsNil() {
  19328. if d.h.DeleteOnNilMapValue {
  19329. delete(v, mk)
  19330. } else {
  19331. v[mk] = nil
  19332. }
  19333. continue
  19334. }
  19335. if mapGet {
  19336. mv = v[mk]
  19337. } else {
  19338. mv = nil
  19339. }
  19340. d.decode(&mv)
  19341. if v != nil {
  19342. v[mk] = mv
  19343. }
  19344. }
  19345. dd.ReadMapEnd()
  19346. return v, changed
  19347. }
  19348. func (d *Decoder) fastpathDecMapFloat64StringR(f *codecFnInfo, rv reflect.Value) {
  19349. if rv.Kind() == reflect.Ptr {
  19350. vp := rv2i(rv).(*map[float64]string)
  19351. if v, changed := fastpathTV.DecMapFloat64StringV(*vp, true, d); changed {
  19352. *vp = v
  19353. }
  19354. return
  19355. }
  19356. fastpathTV.DecMapFloat64StringV(rv2i(rv).(map[float64]string), false, d)
  19357. }
  19358. func (f fastpathT) DecMapFloat64StringX(vp *map[float64]string, d *Decoder) {
  19359. if v, changed := f.DecMapFloat64StringV(*vp, true, d); changed {
  19360. *vp = v
  19361. }
  19362. }
  19363. func (_ fastpathT) DecMapFloat64StringV(v map[float64]string, canChange bool,
  19364. d *Decoder) (_ map[float64]string, changed bool) {
  19365. dd, esep := d.d, d.hh.hasElemSeparators()
  19366. containerLen := dd.ReadMapStart()
  19367. if canChange && v == nil {
  19368. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  19369. v = make(map[float64]string, xlen)
  19370. changed = true
  19371. }
  19372. if containerLen == 0 {
  19373. dd.ReadMapEnd()
  19374. return v, changed
  19375. }
  19376. var mk float64
  19377. var mv string
  19378. hasLen := containerLen > 0
  19379. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19380. if esep {
  19381. dd.ReadMapElemKey()
  19382. }
  19383. mk = dd.DecodeFloat(false)
  19384. if esep {
  19385. dd.ReadMapElemValue()
  19386. }
  19387. if dd.TryDecodeAsNil() {
  19388. if d.h.DeleteOnNilMapValue {
  19389. delete(v, mk)
  19390. } else {
  19391. v[mk] = ""
  19392. }
  19393. continue
  19394. }
  19395. mv = dd.DecodeString()
  19396. if v != nil {
  19397. v[mk] = mv
  19398. }
  19399. }
  19400. dd.ReadMapEnd()
  19401. return v, changed
  19402. }
  19403. func (d *Decoder) fastpathDecMapFloat64UintR(f *codecFnInfo, rv reflect.Value) {
  19404. if rv.Kind() == reflect.Ptr {
  19405. vp := rv2i(rv).(*map[float64]uint)
  19406. if v, changed := fastpathTV.DecMapFloat64UintV(*vp, true, d); changed {
  19407. *vp = v
  19408. }
  19409. return
  19410. }
  19411. fastpathTV.DecMapFloat64UintV(rv2i(rv).(map[float64]uint), false, d)
  19412. }
  19413. func (f fastpathT) DecMapFloat64UintX(vp *map[float64]uint, d *Decoder) {
  19414. if v, changed := f.DecMapFloat64UintV(*vp, true, d); changed {
  19415. *vp = v
  19416. }
  19417. }
  19418. func (_ fastpathT) DecMapFloat64UintV(v map[float64]uint, canChange bool,
  19419. d *Decoder) (_ map[float64]uint, changed bool) {
  19420. dd, esep := d.d, d.hh.hasElemSeparators()
  19421. containerLen := dd.ReadMapStart()
  19422. if canChange && v == nil {
  19423. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  19424. v = make(map[float64]uint, xlen)
  19425. changed = true
  19426. }
  19427. if containerLen == 0 {
  19428. dd.ReadMapEnd()
  19429. return v, changed
  19430. }
  19431. var mk float64
  19432. var mv uint
  19433. hasLen := containerLen > 0
  19434. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19435. if esep {
  19436. dd.ReadMapElemKey()
  19437. }
  19438. mk = dd.DecodeFloat(false)
  19439. if esep {
  19440. dd.ReadMapElemValue()
  19441. }
  19442. if dd.TryDecodeAsNil() {
  19443. if d.h.DeleteOnNilMapValue {
  19444. delete(v, mk)
  19445. } else {
  19446. v[mk] = 0
  19447. }
  19448. continue
  19449. }
  19450. mv = uint(dd.DecodeUint(uintBitsize))
  19451. if v != nil {
  19452. v[mk] = mv
  19453. }
  19454. }
  19455. dd.ReadMapEnd()
  19456. return v, changed
  19457. }
  19458. func (d *Decoder) fastpathDecMapFloat64Uint8R(f *codecFnInfo, rv reflect.Value) {
  19459. if rv.Kind() == reflect.Ptr {
  19460. vp := rv2i(rv).(*map[float64]uint8)
  19461. if v, changed := fastpathTV.DecMapFloat64Uint8V(*vp, true, d); changed {
  19462. *vp = v
  19463. }
  19464. return
  19465. }
  19466. fastpathTV.DecMapFloat64Uint8V(rv2i(rv).(map[float64]uint8), false, d)
  19467. }
  19468. func (f fastpathT) DecMapFloat64Uint8X(vp *map[float64]uint8, d *Decoder) {
  19469. if v, changed := f.DecMapFloat64Uint8V(*vp, true, d); changed {
  19470. *vp = v
  19471. }
  19472. }
  19473. func (_ fastpathT) DecMapFloat64Uint8V(v map[float64]uint8, canChange bool,
  19474. d *Decoder) (_ map[float64]uint8, changed bool) {
  19475. dd, esep := d.d, d.hh.hasElemSeparators()
  19476. containerLen := dd.ReadMapStart()
  19477. if canChange && v == nil {
  19478. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  19479. v = make(map[float64]uint8, xlen)
  19480. changed = true
  19481. }
  19482. if containerLen == 0 {
  19483. dd.ReadMapEnd()
  19484. return v, changed
  19485. }
  19486. var mk float64
  19487. var mv uint8
  19488. hasLen := containerLen > 0
  19489. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19490. if esep {
  19491. dd.ReadMapElemKey()
  19492. }
  19493. mk = dd.DecodeFloat(false)
  19494. if esep {
  19495. dd.ReadMapElemValue()
  19496. }
  19497. if dd.TryDecodeAsNil() {
  19498. if d.h.DeleteOnNilMapValue {
  19499. delete(v, mk)
  19500. } else {
  19501. v[mk] = 0
  19502. }
  19503. continue
  19504. }
  19505. mv = uint8(dd.DecodeUint(8))
  19506. if v != nil {
  19507. v[mk] = mv
  19508. }
  19509. }
  19510. dd.ReadMapEnd()
  19511. return v, changed
  19512. }
  19513. func (d *Decoder) fastpathDecMapFloat64Uint16R(f *codecFnInfo, rv reflect.Value) {
  19514. if rv.Kind() == reflect.Ptr {
  19515. vp := rv2i(rv).(*map[float64]uint16)
  19516. if v, changed := fastpathTV.DecMapFloat64Uint16V(*vp, true, d); changed {
  19517. *vp = v
  19518. }
  19519. return
  19520. }
  19521. fastpathTV.DecMapFloat64Uint16V(rv2i(rv).(map[float64]uint16), false, d)
  19522. }
  19523. func (f fastpathT) DecMapFloat64Uint16X(vp *map[float64]uint16, d *Decoder) {
  19524. if v, changed := f.DecMapFloat64Uint16V(*vp, true, d); changed {
  19525. *vp = v
  19526. }
  19527. }
  19528. func (_ fastpathT) DecMapFloat64Uint16V(v map[float64]uint16, canChange bool,
  19529. d *Decoder) (_ map[float64]uint16, changed bool) {
  19530. dd, esep := d.d, d.hh.hasElemSeparators()
  19531. containerLen := dd.ReadMapStart()
  19532. if canChange && v == nil {
  19533. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  19534. v = make(map[float64]uint16, xlen)
  19535. changed = true
  19536. }
  19537. if containerLen == 0 {
  19538. dd.ReadMapEnd()
  19539. return v, changed
  19540. }
  19541. var mk float64
  19542. var mv uint16
  19543. hasLen := containerLen > 0
  19544. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19545. if esep {
  19546. dd.ReadMapElemKey()
  19547. }
  19548. mk = dd.DecodeFloat(false)
  19549. if esep {
  19550. dd.ReadMapElemValue()
  19551. }
  19552. if dd.TryDecodeAsNil() {
  19553. if d.h.DeleteOnNilMapValue {
  19554. delete(v, mk)
  19555. } else {
  19556. v[mk] = 0
  19557. }
  19558. continue
  19559. }
  19560. mv = uint16(dd.DecodeUint(16))
  19561. if v != nil {
  19562. v[mk] = mv
  19563. }
  19564. }
  19565. dd.ReadMapEnd()
  19566. return v, changed
  19567. }
  19568. func (d *Decoder) fastpathDecMapFloat64Uint32R(f *codecFnInfo, rv reflect.Value) {
  19569. if rv.Kind() == reflect.Ptr {
  19570. vp := rv2i(rv).(*map[float64]uint32)
  19571. if v, changed := fastpathTV.DecMapFloat64Uint32V(*vp, true, d); changed {
  19572. *vp = v
  19573. }
  19574. return
  19575. }
  19576. fastpathTV.DecMapFloat64Uint32V(rv2i(rv).(map[float64]uint32), false, d)
  19577. }
  19578. func (f fastpathT) DecMapFloat64Uint32X(vp *map[float64]uint32, d *Decoder) {
  19579. if v, changed := f.DecMapFloat64Uint32V(*vp, true, d); changed {
  19580. *vp = v
  19581. }
  19582. }
  19583. func (_ fastpathT) DecMapFloat64Uint32V(v map[float64]uint32, canChange bool,
  19584. d *Decoder) (_ map[float64]uint32, changed bool) {
  19585. dd, esep := d.d, d.hh.hasElemSeparators()
  19586. containerLen := dd.ReadMapStart()
  19587. if canChange && v == nil {
  19588. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  19589. v = make(map[float64]uint32, xlen)
  19590. changed = true
  19591. }
  19592. if containerLen == 0 {
  19593. dd.ReadMapEnd()
  19594. return v, changed
  19595. }
  19596. var mk float64
  19597. var mv uint32
  19598. hasLen := containerLen > 0
  19599. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19600. if esep {
  19601. dd.ReadMapElemKey()
  19602. }
  19603. mk = dd.DecodeFloat(false)
  19604. if esep {
  19605. dd.ReadMapElemValue()
  19606. }
  19607. if dd.TryDecodeAsNil() {
  19608. if d.h.DeleteOnNilMapValue {
  19609. delete(v, mk)
  19610. } else {
  19611. v[mk] = 0
  19612. }
  19613. continue
  19614. }
  19615. mv = uint32(dd.DecodeUint(32))
  19616. if v != nil {
  19617. v[mk] = mv
  19618. }
  19619. }
  19620. dd.ReadMapEnd()
  19621. return v, changed
  19622. }
  19623. func (d *Decoder) fastpathDecMapFloat64Uint64R(f *codecFnInfo, rv reflect.Value) {
  19624. if rv.Kind() == reflect.Ptr {
  19625. vp := rv2i(rv).(*map[float64]uint64)
  19626. if v, changed := fastpathTV.DecMapFloat64Uint64V(*vp, true, d); changed {
  19627. *vp = v
  19628. }
  19629. return
  19630. }
  19631. fastpathTV.DecMapFloat64Uint64V(rv2i(rv).(map[float64]uint64), false, d)
  19632. }
  19633. func (f fastpathT) DecMapFloat64Uint64X(vp *map[float64]uint64, d *Decoder) {
  19634. if v, changed := f.DecMapFloat64Uint64V(*vp, true, d); changed {
  19635. *vp = v
  19636. }
  19637. }
  19638. func (_ fastpathT) DecMapFloat64Uint64V(v map[float64]uint64, canChange bool,
  19639. d *Decoder) (_ map[float64]uint64, changed bool) {
  19640. dd, esep := d.d, d.hh.hasElemSeparators()
  19641. containerLen := dd.ReadMapStart()
  19642. if canChange && v == nil {
  19643. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  19644. v = make(map[float64]uint64, xlen)
  19645. changed = true
  19646. }
  19647. if containerLen == 0 {
  19648. dd.ReadMapEnd()
  19649. return v, changed
  19650. }
  19651. var mk float64
  19652. var mv uint64
  19653. hasLen := containerLen > 0
  19654. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19655. if esep {
  19656. dd.ReadMapElemKey()
  19657. }
  19658. mk = dd.DecodeFloat(false)
  19659. if esep {
  19660. dd.ReadMapElemValue()
  19661. }
  19662. if dd.TryDecodeAsNil() {
  19663. if d.h.DeleteOnNilMapValue {
  19664. delete(v, mk)
  19665. } else {
  19666. v[mk] = 0
  19667. }
  19668. continue
  19669. }
  19670. mv = dd.DecodeUint(64)
  19671. if v != nil {
  19672. v[mk] = mv
  19673. }
  19674. }
  19675. dd.ReadMapEnd()
  19676. return v, changed
  19677. }
  19678. func (d *Decoder) fastpathDecMapFloat64UintptrR(f *codecFnInfo, rv reflect.Value) {
  19679. if rv.Kind() == reflect.Ptr {
  19680. vp := rv2i(rv).(*map[float64]uintptr)
  19681. if v, changed := fastpathTV.DecMapFloat64UintptrV(*vp, true, d); changed {
  19682. *vp = v
  19683. }
  19684. return
  19685. }
  19686. fastpathTV.DecMapFloat64UintptrV(rv2i(rv).(map[float64]uintptr), false, d)
  19687. }
  19688. func (f fastpathT) DecMapFloat64UintptrX(vp *map[float64]uintptr, d *Decoder) {
  19689. if v, changed := f.DecMapFloat64UintptrV(*vp, true, d); changed {
  19690. *vp = v
  19691. }
  19692. }
  19693. func (_ fastpathT) DecMapFloat64UintptrV(v map[float64]uintptr, canChange bool,
  19694. d *Decoder) (_ map[float64]uintptr, changed bool) {
  19695. dd, esep := d.d, d.hh.hasElemSeparators()
  19696. containerLen := dd.ReadMapStart()
  19697. if canChange && v == nil {
  19698. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  19699. v = make(map[float64]uintptr, xlen)
  19700. changed = true
  19701. }
  19702. if containerLen == 0 {
  19703. dd.ReadMapEnd()
  19704. return v, changed
  19705. }
  19706. var mk float64
  19707. var mv uintptr
  19708. hasLen := containerLen > 0
  19709. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19710. if esep {
  19711. dd.ReadMapElemKey()
  19712. }
  19713. mk = dd.DecodeFloat(false)
  19714. if esep {
  19715. dd.ReadMapElemValue()
  19716. }
  19717. if dd.TryDecodeAsNil() {
  19718. if d.h.DeleteOnNilMapValue {
  19719. delete(v, mk)
  19720. } else {
  19721. v[mk] = 0
  19722. }
  19723. continue
  19724. }
  19725. mv = uintptr(dd.DecodeUint(uintBitsize))
  19726. if v != nil {
  19727. v[mk] = mv
  19728. }
  19729. }
  19730. dd.ReadMapEnd()
  19731. return v, changed
  19732. }
  19733. func (d *Decoder) fastpathDecMapFloat64IntR(f *codecFnInfo, rv reflect.Value) {
  19734. if rv.Kind() == reflect.Ptr {
  19735. vp := rv2i(rv).(*map[float64]int)
  19736. if v, changed := fastpathTV.DecMapFloat64IntV(*vp, true, d); changed {
  19737. *vp = v
  19738. }
  19739. return
  19740. }
  19741. fastpathTV.DecMapFloat64IntV(rv2i(rv).(map[float64]int), false, d)
  19742. }
  19743. func (f fastpathT) DecMapFloat64IntX(vp *map[float64]int, d *Decoder) {
  19744. if v, changed := f.DecMapFloat64IntV(*vp, true, d); changed {
  19745. *vp = v
  19746. }
  19747. }
  19748. func (_ fastpathT) DecMapFloat64IntV(v map[float64]int, canChange bool,
  19749. d *Decoder) (_ map[float64]int, changed bool) {
  19750. dd, esep := d.d, d.hh.hasElemSeparators()
  19751. containerLen := dd.ReadMapStart()
  19752. if canChange && v == nil {
  19753. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  19754. v = make(map[float64]int, xlen)
  19755. changed = true
  19756. }
  19757. if containerLen == 0 {
  19758. dd.ReadMapEnd()
  19759. return v, changed
  19760. }
  19761. var mk float64
  19762. var mv int
  19763. hasLen := containerLen > 0
  19764. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19765. if esep {
  19766. dd.ReadMapElemKey()
  19767. }
  19768. mk = dd.DecodeFloat(false)
  19769. if esep {
  19770. dd.ReadMapElemValue()
  19771. }
  19772. if dd.TryDecodeAsNil() {
  19773. if d.h.DeleteOnNilMapValue {
  19774. delete(v, mk)
  19775. } else {
  19776. v[mk] = 0
  19777. }
  19778. continue
  19779. }
  19780. mv = int(dd.DecodeInt(intBitsize))
  19781. if v != nil {
  19782. v[mk] = mv
  19783. }
  19784. }
  19785. dd.ReadMapEnd()
  19786. return v, changed
  19787. }
  19788. func (d *Decoder) fastpathDecMapFloat64Int8R(f *codecFnInfo, rv reflect.Value) {
  19789. if rv.Kind() == reflect.Ptr {
  19790. vp := rv2i(rv).(*map[float64]int8)
  19791. if v, changed := fastpathTV.DecMapFloat64Int8V(*vp, true, d); changed {
  19792. *vp = v
  19793. }
  19794. return
  19795. }
  19796. fastpathTV.DecMapFloat64Int8V(rv2i(rv).(map[float64]int8), false, d)
  19797. }
  19798. func (f fastpathT) DecMapFloat64Int8X(vp *map[float64]int8, d *Decoder) {
  19799. if v, changed := f.DecMapFloat64Int8V(*vp, true, d); changed {
  19800. *vp = v
  19801. }
  19802. }
  19803. func (_ fastpathT) DecMapFloat64Int8V(v map[float64]int8, canChange bool,
  19804. d *Decoder) (_ map[float64]int8, changed bool) {
  19805. dd, esep := d.d, d.hh.hasElemSeparators()
  19806. containerLen := dd.ReadMapStart()
  19807. if canChange && v == nil {
  19808. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  19809. v = make(map[float64]int8, xlen)
  19810. changed = true
  19811. }
  19812. if containerLen == 0 {
  19813. dd.ReadMapEnd()
  19814. return v, changed
  19815. }
  19816. var mk float64
  19817. var mv int8
  19818. hasLen := containerLen > 0
  19819. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19820. if esep {
  19821. dd.ReadMapElemKey()
  19822. }
  19823. mk = dd.DecodeFloat(false)
  19824. if esep {
  19825. dd.ReadMapElemValue()
  19826. }
  19827. if dd.TryDecodeAsNil() {
  19828. if d.h.DeleteOnNilMapValue {
  19829. delete(v, mk)
  19830. } else {
  19831. v[mk] = 0
  19832. }
  19833. continue
  19834. }
  19835. mv = int8(dd.DecodeInt(8))
  19836. if v != nil {
  19837. v[mk] = mv
  19838. }
  19839. }
  19840. dd.ReadMapEnd()
  19841. return v, changed
  19842. }
  19843. func (d *Decoder) fastpathDecMapFloat64Int16R(f *codecFnInfo, rv reflect.Value) {
  19844. if rv.Kind() == reflect.Ptr {
  19845. vp := rv2i(rv).(*map[float64]int16)
  19846. if v, changed := fastpathTV.DecMapFloat64Int16V(*vp, true, d); changed {
  19847. *vp = v
  19848. }
  19849. return
  19850. }
  19851. fastpathTV.DecMapFloat64Int16V(rv2i(rv).(map[float64]int16), false, d)
  19852. }
  19853. func (f fastpathT) DecMapFloat64Int16X(vp *map[float64]int16, d *Decoder) {
  19854. if v, changed := f.DecMapFloat64Int16V(*vp, true, d); changed {
  19855. *vp = v
  19856. }
  19857. }
  19858. func (_ fastpathT) DecMapFloat64Int16V(v map[float64]int16, canChange bool,
  19859. d *Decoder) (_ map[float64]int16, changed bool) {
  19860. dd, esep := d.d, d.hh.hasElemSeparators()
  19861. containerLen := dd.ReadMapStart()
  19862. if canChange && v == nil {
  19863. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  19864. v = make(map[float64]int16, xlen)
  19865. changed = true
  19866. }
  19867. if containerLen == 0 {
  19868. dd.ReadMapEnd()
  19869. return v, changed
  19870. }
  19871. var mk float64
  19872. var mv int16
  19873. hasLen := containerLen > 0
  19874. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19875. if esep {
  19876. dd.ReadMapElemKey()
  19877. }
  19878. mk = dd.DecodeFloat(false)
  19879. if esep {
  19880. dd.ReadMapElemValue()
  19881. }
  19882. if dd.TryDecodeAsNil() {
  19883. if d.h.DeleteOnNilMapValue {
  19884. delete(v, mk)
  19885. } else {
  19886. v[mk] = 0
  19887. }
  19888. continue
  19889. }
  19890. mv = int16(dd.DecodeInt(16))
  19891. if v != nil {
  19892. v[mk] = mv
  19893. }
  19894. }
  19895. dd.ReadMapEnd()
  19896. return v, changed
  19897. }
  19898. func (d *Decoder) fastpathDecMapFloat64Int32R(f *codecFnInfo, rv reflect.Value) {
  19899. if rv.Kind() == reflect.Ptr {
  19900. vp := rv2i(rv).(*map[float64]int32)
  19901. if v, changed := fastpathTV.DecMapFloat64Int32V(*vp, true, d); changed {
  19902. *vp = v
  19903. }
  19904. return
  19905. }
  19906. fastpathTV.DecMapFloat64Int32V(rv2i(rv).(map[float64]int32), false, d)
  19907. }
  19908. func (f fastpathT) DecMapFloat64Int32X(vp *map[float64]int32, d *Decoder) {
  19909. if v, changed := f.DecMapFloat64Int32V(*vp, true, d); changed {
  19910. *vp = v
  19911. }
  19912. }
  19913. func (_ fastpathT) DecMapFloat64Int32V(v map[float64]int32, canChange bool,
  19914. d *Decoder) (_ map[float64]int32, changed bool) {
  19915. dd, esep := d.d, d.hh.hasElemSeparators()
  19916. containerLen := dd.ReadMapStart()
  19917. if canChange && v == nil {
  19918. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  19919. v = make(map[float64]int32, xlen)
  19920. changed = true
  19921. }
  19922. if containerLen == 0 {
  19923. dd.ReadMapEnd()
  19924. return v, changed
  19925. }
  19926. var mk float64
  19927. var mv int32
  19928. hasLen := containerLen > 0
  19929. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19930. if esep {
  19931. dd.ReadMapElemKey()
  19932. }
  19933. mk = dd.DecodeFloat(false)
  19934. if esep {
  19935. dd.ReadMapElemValue()
  19936. }
  19937. if dd.TryDecodeAsNil() {
  19938. if d.h.DeleteOnNilMapValue {
  19939. delete(v, mk)
  19940. } else {
  19941. v[mk] = 0
  19942. }
  19943. continue
  19944. }
  19945. mv = int32(dd.DecodeInt(32))
  19946. if v != nil {
  19947. v[mk] = mv
  19948. }
  19949. }
  19950. dd.ReadMapEnd()
  19951. return v, changed
  19952. }
  19953. func (d *Decoder) fastpathDecMapFloat64Int64R(f *codecFnInfo, rv reflect.Value) {
  19954. if rv.Kind() == reflect.Ptr {
  19955. vp := rv2i(rv).(*map[float64]int64)
  19956. if v, changed := fastpathTV.DecMapFloat64Int64V(*vp, true, d); changed {
  19957. *vp = v
  19958. }
  19959. return
  19960. }
  19961. fastpathTV.DecMapFloat64Int64V(rv2i(rv).(map[float64]int64), false, d)
  19962. }
  19963. func (f fastpathT) DecMapFloat64Int64X(vp *map[float64]int64, d *Decoder) {
  19964. if v, changed := f.DecMapFloat64Int64V(*vp, true, d); changed {
  19965. *vp = v
  19966. }
  19967. }
  19968. func (_ fastpathT) DecMapFloat64Int64V(v map[float64]int64, canChange bool,
  19969. d *Decoder) (_ map[float64]int64, changed bool) {
  19970. dd, esep := d.d, d.hh.hasElemSeparators()
  19971. containerLen := dd.ReadMapStart()
  19972. if canChange && v == nil {
  19973. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  19974. v = make(map[float64]int64, xlen)
  19975. changed = true
  19976. }
  19977. if containerLen == 0 {
  19978. dd.ReadMapEnd()
  19979. return v, changed
  19980. }
  19981. var mk float64
  19982. var mv int64
  19983. hasLen := containerLen > 0
  19984. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  19985. if esep {
  19986. dd.ReadMapElemKey()
  19987. }
  19988. mk = dd.DecodeFloat(false)
  19989. if esep {
  19990. dd.ReadMapElemValue()
  19991. }
  19992. if dd.TryDecodeAsNil() {
  19993. if d.h.DeleteOnNilMapValue {
  19994. delete(v, mk)
  19995. } else {
  19996. v[mk] = 0
  19997. }
  19998. continue
  19999. }
  20000. mv = dd.DecodeInt(64)
  20001. if v != nil {
  20002. v[mk] = mv
  20003. }
  20004. }
  20005. dd.ReadMapEnd()
  20006. return v, changed
  20007. }
  20008. func (d *Decoder) fastpathDecMapFloat64Float32R(f *codecFnInfo, rv reflect.Value) {
  20009. if rv.Kind() == reflect.Ptr {
  20010. vp := rv2i(rv).(*map[float64]float32)
  20011. if v, changed := fastpathTV.DecMapFloat64Float32V(*vp, true, d); changed {
  20012. *vp = v
  20013. }
  20014. return
  20015. }
  20016. fastpathTV.DecMapFloat64Float32V(rv2i(rv).(map[float64]float32), false, d)
  20017. }
  20018. func (f fastpathT) DecMapFloat64Float32X(vp *map[float64]float32, d *Decoder) {
  20019. if v, changed := f.DecMapFloat64Float32V(*vp, true, d); changed {
  20020. *vp = v
  20021. }
  20022. }
  20023. func (_ fastpathT) DecMapFloat64Float32V(v map[float64]float32, canChange bool,
  20024. d *Decoder) (_ map[float64]float32, changed bool) {
  20025. dd, esep := d.d, d.hh.hasElemSeparators()
  20026. containerLen := dd.ReadMapStart()
  20027. if canChange && v == nil {
  20028. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  20029. v = make(map[float64]float32, xlen)
  20030. changed = true
  20031. }
  20032. if containerLen == 0 {
  20033. dd.ReadMapEnd()
  20034. return v, changed
  20035. }
  20036. var mk float64
  20037. var mv float32
  20038. hasLen := containerLen > 0
  20039. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20040. if esep {
  20041. dd.ReadMapElemKey()
  20042. }
  20043. mk = dd.DecodeFloat(false)
  20044. if esep {
  20045. dd.ReadMapElemValue()
  20046. }
  20047. if dd.TryDecodeAsNil() {
  20048. if d.h.DeleteOnNilMapValue {
  20049. delete(v, mk)
  20050. } else {
  20051. v[mk] = 0
  20052. }
  20053. continue
  20054. }
  20055. mv = float32(dd.DecodeFloat(true))
  20056. if v != nil {
  20057. v[mk] = mv
  20058. }
  20059. }
  20060. dd.ReadMapEnd()
  20061. return v, changed
  20062. }
  20063. func (d *Decoder) fastpathDecMapFloat64Float64R(f *codecFnInfo, rv reflect.Value) {
  20064. if rv.Kind() == reflect.Ptr {
  20065. vp := rv2i(rv).(*map[float64]float64)
  20066. if v, changed := fastpathTV.DecMapFloat64Float64V(*vp, true, d); changed {
  20067. *vp = v
  20068. }
  20069. return
  20070. }
  20071. fastpathTV.DecMapFloat64Float64V(rv2i(rv).(map[float64]float64), false, d)
  20072. }
  20073. func (f fastpathT) DecMapFloat64Float64X(vp *map[float64]float64, d *Decoder) {
  20074. if v, changed := f.DecMapFloat64Float64V(*vp, true, d); changed {
  20075. *vp = v
  20076. }
  20077. }
  20078. func (_ fastpathT) DecMapFloat64Float64V(v map[float64]float64, canChange bool,
  20079. d *Decoder) (_ map[float64]float64, changed bool) {
  20080. dd, esep := d.d, d.hh.hasElemSeparators()
  20081. containerLen := dd.ReadMapStart()
  20082. if canChange && v == nil {
  20083. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  20084. v = make(map[float64]float64, xlen)
  20085. changed = true
  20086. }
  20087. if containerLen == 0 {
  20088. dd.ReadMapEnd()
  20089. return v, changed
  20090. }
  20091. var mk float64
  20092. var mv float64
  20093. hasLen := containerLen > 0
  20094. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20095. if esep {
  20096. dd.ReadMapElemKey()
  20097. }
  20098. mk = dd.DecodeFloat(false)
  20099. if esep {
  20100. dd.ReadMapElemValue()
  20101. }
  20102. if dd.TryDecodeAsNil() {
  20103. if d.h.DeleteOnNilMapValue {
  20104. delete(v, mk)
  20105. } else {
  20106. v[mk] = 0
  20107. }
  20108. continue
  20109. }
  20110. mv = dd.DecodeFloat(false)
  20111. if v != nil {
  20112. v[mk] = mv
  20113. }
  20114. }
  20115. dd.ReadMapEnd()
  20116. return v, changed
  20117. }
  20118. func (d *Decoder) fastpathDecMapFloat64BoolR(f *codecFnInfo, rv reflect.Value) {
  20119. if rv.Kind() == reflect.Ptr {
  20120. vp := rv2i(rv).(*map[float64]bool)
  20121. if v, changed := fastpathTV.DecMapFloat64BoolV(*vp, true, d); changed {
  20122. *vp = v
  20123. }
  20124. return
  20125. }
  20126. fastpathTV.DecMapFloat64BoolV(rv2i(rv).(map[float64]bool), false, d)
  20127. }
  20128. func (f fastpathT) DecMapFloat64BoolX(vp *map[float64]bool, d *Decoder) {
  20129. if v, changed := f.DecMapFloat64BoolV(*vp, true, d); changed {
  20130. *vp = v
  20131. }
  20132. }
  20133. func (_ fastpathT) DecMapFloat64BoolV(v map[float64]bool, canChange bool,
  20134. d *Decoder) (_ map[float64]bool, changed bool) {
  20135. dd, esep := d.d, d.hh.hasElemSeparators()
  20136. containerLen := dd.ReadMapStart()
  20137. if canChange && v == nil {
  20138. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  20139. v = make(map[float64]bool, xlen)
  20140. changed = true
  20141. }
  20142. if containerLen == 0 {
  20143. dd.ReadMapEnd()
  20144. return v, changed
  20145. }
  20146. var mk float64
  20147. var mv bool
  20148. hasLen := containerLen > 0
  20149. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20150. if esep {
  20151. dd.ReadMapElemKey()
  20152. }
  20153. mk = dd.DecodeFloat(false)
  20154. if esep {
  20155. dd.ReadMapElemValue()
  20156. }
  20157. if dd.TryDecodeAsNil() {
  20158. if d.h.DeleteOnNilMapValue {
  20159. delete(v, mk)
  20160. } else {
  20161. v[mk] = false
  20162. }
  20163. continue
  20164. }
  20165. mv = dd.DecodeBool()
  20166. if v != nil {
  20167. v[mk] = mv
  20168. }
  20169. }
  20170. dd.ReadMapEnd()
  20171. return v, changed
  20172. }
  20173. func (d *Decoder) fastpathDecMapUintIntfR(f *codecFnInfo, rv reflect.Value) {
  20174. if rv.Kind() == reflect.Ptr {
  20175. vp := rv2i(rv).(*map[uint]interface{})
  20176. if v, changed := fastpathTV.DecMapUintIntfV(*vp, true, d); changed {
  20177. *vp = v
  20178. }
  20179. return
  20180. }
  20181. fastpathTV.DecMapUintIntfV(rv2i(rv).(map[uint]interface{}), false, d)
  20182. }
  20183. func (f fastpathT) DecMapUintIntfX(vp *map[uint]interface{}, d *Decoder) {
  20184. if v, changed := f.DecMapUintIntfV(*vp, true, d); changed {
  20185. *vp = v
  20186. }
  20187. }
  20188. func (_ fastpathT) DecMapUintIntfV(v map[uint]interface{}, canChange bool,
  20189. d *Decoder) (_ map[uint]interface{}, changed bool) {
  20190. dd, esep := d.d, d.hh.hasElemSeparators()
  20191. containerLen := dd.ReadMapStart()
  20192. if canChange && v == nil {
  20193. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  20194. v = make(map[uint]interface{}, xlen)
  20195. changed = true
  20196. }
  20197. if containerLen == 0 {
  20198. dd.ReadMapEnd()
  20199. return v, changed
  20200. }
  20201. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  20202. var mk uint
  20203. var mv interface{}
  20204. hasLen := containerLen > 0
  20205. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20206. if esep {
  20207. dd.ReadMapElemKey()
  20208. }
  20209. mk = uint(dd.DecodeUint(uintBitsize))
  20210. if esep {
  20211. dd.ReadMapElemValue()
  20212. }
  20213. if dd.TryDecodeAsNil() {
  20214. if d.h.DeleteOnNilMapValue {
  20215. delete(v, mk)
  20216. } else {
  20217. v[mk] = nil
  20218. }
  20219. continue
  20220. }
  20221. if mapGet {
  20222. mv = v[mk]
  20223. } else {
  20224. mv = nil
  20225. }
  20226. d.decode(&mv)
  20227. if v != nil {
  20228. v[mk] = mv
  20229. }
  20230. }
  20231. dd.ReadMapEnd()
  20232. return v, changed
  20233. }
  20234. func (d *Decoder) fastpathDecMapUintStringR(f *codecFnInfo, rv reflect.Value) {
  20235. if rv.Kind() == reflect.Ptr {
  20236. vp := rv2i(rv).(*map[uint]string)
  20237. if v, changed := fastpathTV.DecMapUintStringV(*vp, true, d); changed {
  20238. *vp = v
  20239. }
  20240. return
  20241. }
  20242. fastpathTV.DecMapUintStringV(rv2i(rv).(map[uint]string), false, d)
  20243. }
  20244. func (f fastpathT) DecMapUintStringX(vp *map[uint]string, d *Decoder) {
  20245. if v, changed := f.DecMapUintStringV(*vp, true, d); changed {
  20246. *vp = v
  20247. }
  20248. }
  20249. func (_ fastpathT) DecMapUintStringV(v map[uint]string, canChange bool,
  20250. d *Decoder) (_ map[uint]string, changed bool) {
  20251. dd, esep := d.d, d.hh.hasElemSeparators()
  20252. containerLen := dd.ReadMapStart()
  20253. if canChange && v == nil {
  20254. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  20255. v = make(map[uint]string, xlen)
  20256. changed = true
  20257. }
  20258. if containerLen == 0 {
  20259. dd.ReadMapEnd()
  20260. return v, changed
  20261. }
  20262. var mk uint
  20263. var mv string
  20264. hasLen := containerLen > 0
  20265. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20266. if esep {
  20267. dd.ReadMapElemKey()
  20268. }
  20269. mk = uint(dd.DecodeUint(uintBitsize))
  20270. if esep {
  20271. dd.ReadMapElemValue()
  20272. }
  20273. if dd.TryDecodeAsNil() {
  20274. if d.h.DeleteOnNilMapValue {
  20275. delete(v, mk)
  20276. } else {
  20277. v[mk] = ""
  20278. }
  20279. continue
  20280. }
  20281. mv = dd.DecodeString()
  20282. if v != nil {
  20283. v[mk] = mv
  20284. }
  20285. }
  20286. dd.ReadMapEnd()
  20287. return v, changed
  20288. }
  20289. func (d *Decoder) fastpathDecMapUintUintR(f *codecFnInfo, rv reflect.Value) {
  20290. if rv.Kind() == reflect.Ptr {
  20291. vp := rv2i(rv).(*map[uint]uint)
  20292. if v, changed := fastpathTV.DecMapUintUintV(*vp, true, d); changed {
  20293. *vp = v
  20294. }
  20295. return
  20296. }
  20297. fastpathTV.DecMapUintUintV(rv2i(rv).(map[uint]uint), false, d)
  20298. }
  20299. func (f fastpathT) DecMapUintUintX(vp *map[uint]uint, d *Decoder) {
  20300. if v, changed := f.DecMapUintUintV(*vp, true, d); changed {
  20301. *vp = v
  20302. }
  20303. }
  20304. func (_ fastpathT) DecMapUintUintV(v map[uint]uint, canChange bool,
  20305. d *Decoder) (_ map[uint]uint, changed bool) {
  20306. dd, esep := d.d, d.hh.hasElemSeparators()
  20307. containerLen := dd.ReadMapStart()
  20308. if canChange && v == nil {
  20309. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  20310. v = make(map[uint]uint, xlen)
  20311. changed = true
  20312. }
  20313. if containerLen == 0 {
  20314. dd.ReadMapEnd()
  20315. return v, changed
  20316. }
  20317. var mk uint
  20318. var mv uint
  20319. hasLen := containerLen > 0
  20320. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20321. if esep {
  20322. dd.ReadMapElemKey()
  20323. }
  20324. mk = uint(dd.DecodeUint(uintBitsize))
  20325. if esep {
  20326. dd.ReadMapElemValue()
  20327. }
  20328. if dd.TryDecodeAsNil() {
  20329. if d.h.DeleteOnNilMapValue {
  20330. delete(v, mk)
  20331. } else {
  20332. v[mk] = 0
  20333. }
  20334. continue
  20335. }
  20336. mv = uint(dd.DecodeUint(uintBitsize))
  20337. if v != nil {
  20338. v[mk] = mv
  20339. }
  20340. }
  20341. dd.ReadMapEnd()
  20342. return v, changed
  20343. }
  20344. func (d *Decoder) fastpathDecMapUintUint8R(f *codecFnInfo, rv reflect.Value) {
  20345. if rv.Kind() == reflect.Ptr {
  20346. vp := rv2i(rv).(*map[uint]uint8)
  20347. if v, changed := fastpathTV.DecMapUintUint8V(*vp, true, d); changed {
  20348. *vp = v
  20349. }
  20350. return
  20351. }
  20352. fastpathTV.DecMapUintUint8V(rv2i(rv).(map[uint]uint8), false, d)
  20353. }
  20354. func (f fastpathT) DecMapUintUint8X(vp *map[uint]uint8, d *Decoder) {
  20355. if v, changed := f.DecMapUintUint8V(*vp, true, d); changed {
  20356. *vp = v
  20357. }
  20358. }
  20359. func (_ fastpathT) DecMapUintUint8V(v map[uint]uint8, canChange bool,
  20360. d *Decoder) (_ map[uint]uint8, changed bool) {
  20361. dd, esep := d.d, d.hh.hasElemSeparators()
  20362. containerLen := dd.ReadMapStart()
  20363. if canChange && v == nil {
  20364. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  20365. v = make(map[uint]uint8, xlen)
  20366. changed = true
  20367. }
  20368. if containerLen == 0 {
  20369. dd.ReadMapEnd()
  20370. return v, changed
  20371. }
  20372. var mk uint
  20373. var mv uint8
  20374. hasLen := containerLen > 0
  20375. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20376. if esep {
  20377. dd.ReadMapElemKey()
  20378. }
  20379. mk = uint(dd.DecodeUint(uintBitsize))
  20380. if esep {
  20381. dd.ReadMapElemValue()
  20382. }
  20383. if dd.TryDecodeAsNil() {
  20384. if d.h.DeleteOnNilMapValue {
  20385. delete(v, mk)
  20386. } else {
  20387. v[mk] = 0
  20388. }
  20389. continue
  20390. }
  20391. mv = uint8(dd.DecodeUint(8))
  20392. if v != nil {
  20393. v[mk] = mv
  20394. }
  20395. }
  20396. dd.ReadMapEnd()
  20397. return v, changed
  20398. }
  20399. func (d *Decoder) fastpathDecMapUintUint16R(f *codecFnInfo, rv reflect.Value) {
  20400. if rv.Kind() == reflect.Ptr {
  20401. vp := rv2i(rv).(*map[uint]uint16)
  20402. if v, changed := fastpathTV.DecMapUintUint16V(*vp, true, d); changed {
  20403. *vp = v
  20404. }
  20405. return
  20406. }
  20407. fastpathTV.DecMapUintUint16V(rv2i(rv).(map[uint]uint16), false, d)
  20408. }
  20409. func (f fastpathT) DecMapUintUint16X(vp *map[uint]uint16, d *Decoder) {
  20410. if v, changed := f.DecMapUintUint16V(*vp, true, d); changed {
  20411. *vp = v
  20412. }
  20413. }
  20414. func (_ fastpathT) DecMapUintUint16V(v map[uint]uint16, canChange bool,
  20415. d *Decoder) (_ map[uint]uint16, changed bool) {
  20416. dd, esep := d.d, d.hh.hasElemSeparators()
  20417. containerLen := dd.ReadMapStart()
  20418. if canChange && v == nil {
  20419. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  20420. v = make(map[uint]uint16, xlen)
  20421. changed = true
  20422. }
  20423. if containerLen == 0 {
  20424. dd.ReadMapEnd()
  20425. return v, changed
  20426. }
  20427. var mk uint
  20428. var mv uint16
  20429. hasLen := containerLen > 0
  20430. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20431. if esep {
  20432. dd.ReadMapElemKey()
  20433. }
  20434. mk = uint(dd.DecodeUint(uintBitsize))
  20435. if esep {
  20436. dd.ReadMapElemValue()
  20437. }
  20438. if dd.TryDecodeAsNil() {
  20439. if d.h.DeleteOnNilMapValue {
  20440. delete(v, mk)
  20441. } else {
  20442. v[mk] = 0
  20443. }
  20444. continue
  20445. }
  20446. mv = uint16(dd.DecodeUint(16))
  20447. if v != nil {
  20448. v[mk] = mv
  20449. }
  20450. }
  20451. dd.ReadMapEnd()
  20452. return v, changed
  20453. }
  20454. func (d *Decoder) fastpathDecMapUintUint32R(f *codecFnInfo, rv reflect.Value) {
  20455. if rv.Kind() == reflect.Ptr {
  20456. vp := rv2i(rv).(*map[uint]uint32)
  20457. if v, changed := fastpathTV.DecMapUintUint32V(*vp, true, d); changed {
  20458. *vp = v
  20459. }
  20460. return
  20461. }
  20462. fastpathTV.DecMapUintUint32V(rv2i(rv).(map[uint]uint32), false, d)
  20463. }
  20464. func (f fastpathT) DecMapUintUint32X(vp *map[uint]uint32, d *Decoder) {
  20465. if v, changed := f.DecMapUintUint32V(*vp, true, d); changed {
  20466. *vp = v
  20467. }
  20468. }
  20469. func (_ fastpathT) DecMapUintUint32V(v map[uint]uint32, canChange bool,
  20470. d *Decoder) (_ map[uint]uint32, changed bool) {
  20471. dd, esep := d.d, d.hh.hasElemSeparators()
  20472. containerLen := dd.ReadMapStart()
  20473. if canChange && v == nil {
  20474. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  20475. v = make(map[uint]uint32, xlen)
  20476. changed = true
  20477. }
  20478. if containerLen == 0 {
  20479. dd.ReadMapEnd()
  20480. return v, changed
  20481. }
  20482. var mk uint
  20483. var mv uint32
  20484. hasLen := containerLen > 0
  20485. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20486. if esep {
  20487. dd.ReadMapElemKey()
  20488. }
  20489. mk = uint(dd.DecodeUint(uintBitsize))
  20490. if esep {
  20491. dd.ReadMapElemValue()
  20492. }
  20493. if dd.TryDecodeAsNil() {
  20494. if d.h.DeleteOnNilMapValue {
  20495. delete(v, mk)
  20496. } else {
  20497. v[mk] = 0
  20498. }
  20499. continue
  20500. }
  20501. mv = uint32(dd.DecodeUint(32))
  20502. if v != nil {
  20503. v[mk] = mv
  20504. }
  20505. }
  20506. dd.ReadMapEnd()
  20507. return v, changed
  20508. }
  20509. func (d *Decoder) fastpathDecMapUintUint64R(f *codecFnInfo, rv reflect.Value) {
  20510. if rv.Kind() == reflect.Ptr {
  20511. vp := rv2i(rv).(*map[uint]uint64)
  20512. if v, changed := fastpathTV.DecMapUintUint64V(*vp, true, d); changed {
  20513. *vp = v
  20514. }
  20515. return
  20516. }
  20517. fastpathTV.DecMapUintUint64V(rv2i(rv).(map[uint]uint64), false, d)
  20518. }
  20519. func (f fastpathT) DecMapUintUint64X(vp *map[uint]uint64, d *Decoder) {
  20520. if v, changed := f.DecMapUintUint64V(*vp, true, d); changed {
  20521. *vp = v
  20522. }
  20523. }
  20524. func (_ fastpathT) DecMapUintUint64V(v map[uint]uint64, canChange bool,
  20525. d *Decoder) (_ map[uint]uint64, changed bool) {
  20526. dd, esep := d.d, d.hh.hasElemSeparators()
  20527. containerLen := dd.ReadMapStart()
  20528. if canChange && v == nil {
  20529. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  20530. v = make(map[uint]uint64, xlen)
  20531. changed = true
  20532. }
  20533. if containerLen == 0 {
  20534. dd.ReadMapEnd()
  20535. return v, changed
  20536. }
  20537. var mk uint
  20538. var mv uint64
  20539. hasLen := containerLen > 0
  20540. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20541. if esep {
  20542. dd.ReadMapElemKey()
  20543. }
  20544. mk = uint(dd.DecodeUint(uintBitsize))
  20545. if esep {
  20546. dd.ReadMapElemValue()
  20547. }
  20548. if dd.TryDecodeAsNil() {
  20549. if d.h.DeleteOnNilMapValue {
  20550. delete(v, mk)
  20551. } else {
  20552. v[mk] = 0
  20553. }
  20554. continue
  20555. }
  20556. mv = dd.DecodeUint(64)
  20557. if v != nil {
  20558. v[mk] = mv
  20559. }
  20560. }
  20561. dd.ReadMapEnd()
  20562. return v, changed
  20563. }
  20564. func (d *Decoder) fastpathDecMapUintUintptrR(f *codecFnInfo, rv reflect.Value) {
  20565. if rv.Kind() == reflect.Ptr {
  20566. vp := rv2i(rv).(*map[uint]uintptr)
  20567. if v, changed := fastpathTV.DecMapUintUintptrV(*vp, true, d); changed {
  20568. *vp = v
  20569. }
  20570. return
  20571. }
  20572. fastpathTV.DecMapUintUintptrV(rv2i(rv).(map[uint]uintptr), false, d)
  20573. }
  20574. func (f fastpathT) DecMapUintUintptrX(vp *map[uint]uintptr, d *Decoder) {
  20575. if v, changed := f.DecMapUintUintptrV(*vp, true, d); changed {
  20576. *vp = v
  20577. }
  20578. }
  20579. func (_ fastpathT) DecMapUintUintptrV(v map[uint]uintptr, canChange bool,
  20580. d *Decoder) (_ map[uint]uintptr, changed bool) {
  20581. dd, esep := d.d, d.hh.hasElemSeparators()
  20582. containerLen := dd.ReadMapStart()
  20583. if canChange && v == nil {
  20584. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  20585. v = make(map[uint]uintptr, xlen)
  20586. changed = true
  20587. }
  20588. if containerLen == 0 {
  20589. dd.ReadMapEnd()
  20590. return v, changed
  20591. }
  20592. var mk uint
  20593. var mv uintptr
  20594. hasLen := containerLen > 0
  20595. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20596. if esep {
  20597. dd.ReadMapElemKey()
  20598. }
  20599. mk = uint(dd.DecodeUint(uintBitsize))
  20600. if esep {
  20601. dd.ReadMapElemValue()
  20602. }
  20603. if dd.TryDecodeAsNil() {
  20604. if d.h.DeleteOnNilMapValue {
  20605. delete(v, mk)
  20606. } else {
  20607. v[mk] = 0
  20608. }
  20609. continue
  20610. }
  20611. mv = uintptr(dd.DecodeUint(uintBitsize))
  20612. if v != nil {
  20613. v[mk] = mv
  20614. }
  20615. }
  20616. dd.ReadMapEnd()
  20617. return v, changed
  20618. }
  20619. func (d *Decoder) fastpathDecMapUintIntR(f *codecFnInfo, rv reflect.Value) {
  20620. if rv.Kind() == reflect.Ptr {
  20621. vp := rv2i(rv).(*map[uint]int)
  20622. if v, changed := fastpathTV.DecMapUintIntV(*vp, true, d); changed {
  20623. *vp = v
  20624. }
  20625. return
  20626. }
  20627. fastpathTV.DecMapUintIntV(rv2i(rv).(map[uint]int), false, d)
  20628. }
  20629. func (f fastpathT) DecMapUintIntX(vp *map[uint]int, d *Decoder) {
  20630. if v, changed := f.DecMapUintIntV(*vp, true, d); changed {
  20631. *vp = v
  20632. }
  20633. }
  20634. func (_ fastpathT) DecMapUintIntV(v map[uint]int, canChange bool,
  20635. d *Decoder) (_ map[uint]int, changed bool) {
  20636. dd, esep := d.d, d.hh.hasElemSeparators()
  20637. containerLen := dd.ReadMapStart()
  20638. if canChange && v == nil {
  20639. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  20640. v = make(map[uint]int, xlen)
  20641. changed = true
  20642. }
  20643. if containerLen == 0 {
  20644. dd.ReadMapEnd()
  20645. return v, changed
  20646. }
  20647. var mk uint
  20648. var mv int
  20649. hasLen := containerLen > 0
  20650. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20651. if esep {
  20652. dd.ReadMapElemKey()
  20653. }
  20654. mk = uint(dd.DecodeUint(uintBitsize))
  20655. if esep {
  20656. dd.ReadMapElemValue()
  20657. }
  20658. if dd.TryDecodeAsNil() {
  20659. if d.h.DeleteOnNilMapValue {
  20660. delete(v, mk)
  20661. } else {
  20662. v[mk] = 0
  20663. }
  20664. continue
  20665. }
  20666. mv = int(dd.DecodeInt(intBitsize))
  20667. if v != nil {
  20668. v[mk] = mv
  20669. }
  20670. }
  20671. dd.ReadMapEnd()
  20672. return v, changed
  20673. }
  20674. func (d *Decoder) fastpathDecMapUintInt8R(f *codecFnInfo, rv reflect.Value) {
  20675. if rv.Kind() == reflect.Ptr {
  20676. vp := rv2i(rv).(*map[uint]int8)
  20677. if v, changed := fastpathTV.DecMapUintInt8V(*vp, true, d); changed {
  20678. *vp = v
  20679. }
  20680. return
  20681. }
  20682. fastpathTV.DecMapUintInt8V(rv2i(rv).(map[uint]int8), false, d)
  20683. }
  20684. func (f fastpathT) DecMapUintInt8X(vp *map[uint]int8, d *Decoder) {
  20685. if v, changed := f.DecMapUintInt8V(*vp, true, d); changed {
  20686. *vp = v
  20687. }
  20688. }
  20689. func (_ fastpathT) DecMapUintInt8V(v map[uint]int8, canChange bool,
  20690. d *Decoder) (_ map[uint]int8, changed bool) {
  20691. dd, esep := d.d, d.hh.hasElemSeparators()
  20692. containerLen := dd.ReadMapStart()
  20693. if canChange && v == nil {
  20694. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  20695. v = make(map[uint]int8, xlen)
  20696. changed = true
  20697. }
  20698. if containerLen == 0 {
  20699. dd.ReadMapEnd()
  20700. return v, changed
  20701. }
  20702. var mk uint
  20703. var mv int8
  20704. hasLen := containerLen > 0
  20705. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20706. if esep {
  20707. dd.ReadMapElemKey()
  20708. }
  20709. mk = uint(dd.DecodeUint(uintBitsize))
  20710. if esep {
  20711. dd.ReadMapElemValue()
  20712. }
  20713. if dd.TryDecodeAsNil() {
  20714. if d.h.DeleteOnNilMapValue {
  20715. delete(v, mk)
  20716. } else {
  20717. v[mk] = 0
  20718. }
  20719. continue
  20720. }
  20721. mv = int8(dd.DecodeInt(8))
  20722. if v != nil {
  20723. v[mk] = mv
  20724. }
  20725. }
  20726. dd.ReadMapEnd()
  20727. return v, changed
  20728. }
  20729. func (d *Decoder) fastpathDecMapUintInt16R(f *codecFnInfo, rv reflect.Value) {
  20730. if rv.Kind() == reflect.Ptr {
  20731. vp := rv2i(rv).(*map[uint]int16)
  20732. if v, changed := fastpathTV.DecMapUintInt16V(*vp, true, d); changed {
  20733. *vp = v
  20734. }
  20735. return
  20736. }
  20737. fastpathTV.DecMapUintInt16V(rv2i(rv).(map[uint]int16), false, d)
  20738. }
  20739. func (f fastpathT) DecMapUintInt16X(vp *map[uint]int16, d *Decoder) {
  20740. if v, changed := f.DecMapUintInt16V(*vp, true, d); changed {
  20741. *vp = v
  20742. }
  20743. }
  20744. func (_ fastpathT) DecMapUintInt16V(v map[uint]int16, canChange bool,
  20745. d *Decoder) (_ map[uint]int16, changed bool) {
  20746. dd, esep := d.d, d.hh.hasElemSeparators()
  20747. containerLen := dd.ReadMapStart()
  20748. if canChange && v == nil {
  20749. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  20750. v = make(map[uint]int16, xlen)
  20751. changed = true
  20752. }
  20753. if containerLen == 0 {
  20754. dd.ReadMapEnd()
  20755. return v, changed
  20756. }
  20757. var mk uint
  20758. var mv int16
  20759. hasLen := containerLen > 0
  20760. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20761. if esep {
  20762. dd.ReadMapElemKey()
  20763. }
  20764. mk = uint(dd.DecodeUint(uintBitsize))
  20765. if esep {
  20766. dd.ReadMapElemValue()
  20767. }
  20768. if dd.TryDecodeAsNil() {
  20769. if d.h.DeleteOnNilMapValue {
  20770. delete(v, mk)
  20771. } else {
  20772. v[mk] = 0
  20773. }
  20774. continue
  20775. }
  20776. mv = int16(dd.DecodeInt(16))
  20777. if v != nil {
  20778. v[mk] = mv
  20779. }
  20780. }
  20781. dd.ReadMapEnd()
  20782. return v, changed
  20783. }
  20784. func (d *Decoder) fastpathDecMapUintInt32R(f *codecFnInfo, rv reflect.Value) {
  20785. if rv.Kind() == reflect.Ptr {
  20786. vp := rv2i(rv).(*map[uint]int32)
  20787. if v, changed := fastpathTV.DecMapUintInt32V(*vp, true, d); changed {
  20788. *vp = v
  20789. }
  20790. return
  20791. }
  20792. fastpathTV.DecMapUintInt32V(rv2i(rv).(map[uint]int32), false, d)
  20793. }
  20794. func (f fastpathT) DecMapUintInt32X(vp *map[uint]int32, d *Decoder) {
  20795. if v, changed := f.DecMapUintInt32V(*vp, true, d); changed {
  20796. *vp = v
  20797. }
  20798. }
  20799. func (_ fastpathT) DecMapUintInt32V(v map[uint]int32, canChange bool,
  20800. d *Decoder) (_ map[uint]int32, changed bool) {
  20801. dd, esep := d.d, d.hh.hasElemSeparators()
  20802. containerLen := dd.ReadMapStart()
  20803. if canChange && v == nil {
  20804. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  20805. v = make(map[uint]int32, xlen)
  20806. changed = true
  20807. }
  20808. if containerLen == 0 {
  20809. dd.ReadMapEnd()
  20810. return v, changed
  20811. }
  20812. var mk uint
  20813. var mv int32
  20814. hasLen := containerLen > 0
  20815. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20816. if esep {
  20817. dd.ReadMapElemKey()
  20818. }
  20819. mk = uint(dd.DecodeUint(uintBitsize))
  20820. if esep {
  20821. dd.ReadMapElemValue()
  20822. }
  20823. if dd.TryDecodeAsNil() {
  20824. if d.h.DeleteOnNilMapValue {
  20825. delete(v, mk)
  20826. } else {
  20827. v[mk] = 0
  20828. }
  20829. continue
  20830. }
  20831. mv = int32(dd.DecodeInt(32))
  20832. if v != nil {
  20833. v[mk] = mv
  20834. }
  20835. }
  20836. dd.ReadMapEnd()
  20837. return v, changed
  20838. }
  20839. func (d *Decoder) fastpathDecMapUintInt64R(f *codecFnInfo, rv reflect.Value) {
  20840. if rv.Kind() == reflect.Ptr {
  20841. vp := rv2i(rv).(*map[uint]int64)
  20842. if v, changed := fastpathTV.DecMapUintInt64V(*vp, true, d); changed {
  20843. *vp = v
  20844. }
  20845. return
  20846. }
  20847. fastpathTV.DecMapUintInt64V(rv2i(rv).(map[uint]int64), false, d)
  20848. }
  20849. func (f fastpathT) DecMapUintInt64X(vp *map[uint]int64, d *Decoder) {
  20850. if v, changed := f.DecMapUintInt64V(*vp, true, d); changed {
  20851. *vp = v
  20852. }
  20853. }
  20854. func (_ fastpathT) DecMapUintInt64V(v map[uint]int64, canChange bool,
  20855. d *Decoder) (_ map[uint]int64, changed bool) {
  20856. dd, esep := d.d, d.hh.hasElemSeparators()
  20857. containerLen := dd.ReadMapStart()
  20858. if canChange && v == nil {
  20859. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  20860. v = make(map[uint]int64, xlen)
  20861. changed = true
  20862. }
  20863. if containerLen == 0 {
  20864. dd.ReadMapEnd()
  20865. return v, changed
  20866. }
  20867. var mk uint
  20868. var mv int64
  20869. hasLen := containerLen > 0
  20870. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20871. if esep {
  20872. dd.ReadMapElemKey()
  20873. }
  20874. mk = uint(dd.DecodeUint(uintBitsize))
  20875. if esep {
  20876. dd.ReadMapElemValue()
  20877. }
  20878. if dd.TryDecodeAsNil() {
  20879. if d.h.DeleteOnNilMapValue {
  20880. delete(v, mk)
  20881. } else {
  20882. v[mk] = 0
  20883. }
  20884. continue
  20885. }
  20886. mv = dd.DecodeInt(64)
  20887. if v != nil {
  20888. v[mk] = mv
  20889. }
  20890. }
  20891. dd.ReadMapEnd()
  20892. return v, changed
  20893. }
  20894. func (d *Decoder) fastpathDecMapUintFloat32R(f *codecFnInfo, rv reflect.Value) {
  20895. if rv.Kind() == reflect.Ptr {
  20896. vp := rv2i(rv).(*map[uint]float32)
  20897. if v, changed := fastpathTV.DecMapUintFloat32V(*vp, true, d); changed {
  20898. *vp = v
  20899. }
  20900. return
  20901. }
  20902. fastpathTV.DecMapUintFloat32V(rv2i(rv).(map[uint]float32), false, d)
  20903. }
  20904. func (f fastpathT) DecMapUintFloat32X(vp *map[uint]float32, d *Decoder) {
  20905. if v, changed := f.DecMapUintFloat32V(*vp, true, d); changed {
  20906. *vp = v
  20907. }
  20908. }
  20909. func (_ fastpathT) DecMapUintFloat32V(v map[uint]float32, canChange bool,
  20910. d *Decoder) (_ map[uint]float32, changed bool) {
  20911. dd, esep := d.d, d.hh.hasElemSeparators()
  20912. containerLen := dd.ReadMapStart()
  20913. if canChange && v == nil {
  20914. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  20915. v = make(map[uint]float32, xlen)
  20916. changed = true
  20917. }
  20918. if containerLen == 0 {
  20919. dd.ReadMapEnd()
  20920. return v, changed
  20921. }
  20922. var mk uint
  20923. var mv float32
  20924. hasLen := containerLen > 0
  20925. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20926. if esep {
  20927. dd.ReadMapElemKey()
  20928. }
  20929. mk = uint(dd.DecodeUint(uintBitsize))
  20930. if esep {
  20931. dd.ReadMapElemValue()
  20932. }
  20933. if dd.TryDecodeAsNil() {
  20934. if d.h.DeleteOnNilMapValue {
  20935. delete(v, mk)
  20936. } else {
  20937. v[mk] = 0
  20938. }
  20939. continue
  20940. }
  20941. mv = float32(dd.DecodeFloat(true))
  20942. if v != nil {
  20943. v[mk] = mv
  20944. }
  20945. }
  20946. dd.ReadMapEnd()
  20947. return v, changed
  20948. }
  20949. func (d *Decoder) fastpathDecMapUintFloat64R(f *codecFnInfo, rv reflect.Value) {
  20950. if rv.Kind() == reflect.Ptr {
  20951. vp := rv2i(rv).(*map[uint]float64)
  20952. if v, changed := fastpathTV.DecMapUintFloat64V(*vp, true, d); changed {
  20953. *vp = v
  20954. }
  20955. return
  20956. }
  20957. fastpathTV.DecMapUintFloat64V(rv2i(rv).(map[uint]float64), false, d)
  20958. }
  20959. func (f fastpathT) DecMapUintFloat64X(vp *map[uint]float64, d *Decoder) {
  20960. if v, changed := f.DecMapUintFloat64V(*vp, true, d); changed {
  20961. *vp = v
  20962. }
  20963. }
  20964. func (_ fastpathT) DecMapUintFloat64V(v map[uint]float64, canChange bool,
  20965. d *Decoder) (_ map[uint]float64, changed bool) {
  20966. dd, esep := d.d, d.hh.hasElemSeparators()
  20967. containerLen := dd.ReadMapStart()
  20968. if canChange && v == nil {
  20969. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  20970. v = make(map[uint]float64, xlen)
  20971. changed = true
  20972. }
  20973. if containerLen == 0 {
  20974. dd.ReadMapEnd()
  20975. return v, changed
  20976. }
  20977. var mk uint
  20978. var mv float64
  20979. hasLen := containerLen > 0
  20980. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  20981. if esep {
  20982. dd.ReadMapElemKey()
  20983. }
  20984. mk = uint(dd.DecodeUint(uintBitsize))
  20985. if esep {
  20986. dd.ReadMapElemValue()
  20987. }
  20988. if dd.TryDecodeAsNil() {
  20989. if d.h.DeleteOnNilMapValue {
  20990. delete(v, mk)
  20991. } else {
  20992. v[mk] = 0
  20993. }
  20994. continue
  20995. }
  20996. mv = dd.DecodeFloat(false)
  20997. if v != nil {
  20998. v[mk] = mv
  20999. }
  21000. }
  21001. dd.ReadMapEnd()
  21002. return v, changed
  21003. }
  21004. func (d *Decoder) fastpathDecMapUintBoolR(f *codecFnInfo, rv reflect.Value) {
  21005. if rv.Kind() == reflect.Ptr {
  21006. vp := rv2i(rv).(*map[uint]bool)
  21007. if v, changed := fastpathTV.DecMapUintBoolV(*vp, true, d); changed {
  21008. *vp = v
  21009. }
  21010. return
  21011. }
  21012. fastpathTV.DecMapUintBoolV(rv2i(rv).(map[uint]bool), false, d)
  21013. }
  21014. func (f fastpathT) DecMapUintBoolX(vp *map[uint]bool, d *Decoder) {
  21015. if v, changed := f.DecMapUintBoolV(*vp, true, d); changed {
  21016. *vp = v
  21017. }
  21018. }
  21019. func (_ fastpathT) DecMapUintBoolV(v map[uint]bool, canChange bool,
  21020. d *Decoder) (_ map[uint]bool, changed bool) {
  21021. dd, esep := d.d, d.hh.hasElemSeparators()
  21022. containerLen := dd.ReadMapStart()
  21023. if canChange && v == nil {
  21024. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  21025. v = make(map[uint]bool, xlen)
  21026. changed = true
  21027. }
  21028. if containerLen == 0 {
  21029. dd.ReadMapEnd()
  21030. return v, changed
  21031. }
  21032. var mk uint
  21033. var mv bool
  21034. hasLen := containerLen > 0
  21035. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21036. if esep {
  21037. dd.ReadMapElemKey()
  21038. }
  21039. mk = uint(dd.DecodeUint(uintBitsize))
  21040. if esep {
  21041. dd.ReadMapElemValue()
  21042. }
  21043. if dd.TryDecodeAsNil() {
  21044. if d.h.DeleteOnNilMapValue {
  21045. delete(v, mk)
  21046. } else {
  21047. v[mk] = false
  21048. }
  21049. continue
  21050. }
  21051. mv = dd.DecodeBool()
  21052. if v != nil {
  21053. v[mk] = mv
  21054. }
  21055. }
  21056. dd.ReadMapEnd()
  21057. return v, changed
  21058. }
  21059. func (d *Decoder) fastpathDecMapUint8IntfR(f *codecFnInfo, rv reflect.Value) {
  21060. if rv.Kind() == reflect.Ptr {
  21061. vp := rv2i(rv).(*map[uint8]interface{})
  21062. if v, changed := fastpathTV.DecMapUint8IntfV(*vp, true, d); changed {
  21063. *vp = v
  21064. }
  21065. return
  21066. }
  21067. fastpathTV.DecMapUint8IntfV(rv2i(rv).(map[uint8]interface{}), false, d)
  21068. }
  21069. func (f fastpathT) DecMapUint8IntfX(vp *map[uint8]interface{}, d *Decoder) {
  21070. if v, changed := f.DecMapUint8IntfV(*vp, true, d); changed {
  21071. *vp = v
  21072. }
  21073. }
  21074. func (_ fastpathT) DecMapUint8IntfV(v map[uint8]interface{}, canChange bool,
  21075. d *Decoder) (_ map[uint8]interface{}, changed bool) {
  21076. dd, esep := d.d, d.hh.hasElemSeparators()
  21077. containerLen := dd.ReadMapStart()
  21078. if canChange && v == nil {
  21079. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  21080. v = make(map[uint8]interface{}, xlen)
  21081. changed = true
  21082. }
  21083. if containerLen == 0 {
  21084. dd.ReadMapEnd()
  21085. return v, changed
  21086. }
  21087. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  21088. var mk uint8
  21089. var mv interface{}
  21090. hasLen := containerLen > 0
  21091. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21092. if esep {
  21093. dd.ReadMapElemKey()
  21094. }
  21095. mk = uint8(dd.DecodeUint(8))
  21096. if esep {
  21097. dd.ReadMapElemValue()
  21098. }
  21099. if dd.TryDecodeAsNil() {
  21100. if d.h.DeleteOnNilMapValue {
  21101. delete(v, mk)
  21102. } else {
  21103. v[mk] = nil
  21104. }
  21105. continue
  21106. }
  21107. if mapGet {
  21108. mv = v[mk]
  21109. } else {
  21110. mv = nil
  21111. }
  21112. d.decode(&mv)
  21113. if v != nil {
  21114. v[mk] = mv
  21115. }
  21116. }
  21117. dd.ReadMapEnd()
  21118. return v, changed
  21119. }
  21120. func (d *Decoder) fastpathDecMapUint8StringR(f *codecFnInfo, rv reflect.Value) {
  21121. if rv.Kind() == reflect.Ptr {
  21122. vp := rv2i(rv).(*map[uint8]string)
  21123. if v, changed := fastpathTV.DecMapUint8StringV(*vp, true, d); changed {
  21124. *vp = v
  21125. }
  21126. return
  21127. }
  21128. fastpathTV.DecMapUint8StringV(rv2i(rv).(map[uint8]string), false, d)
  21129. }
  21130. func (f fastpathT) DecMapUint8StringX(vp *map[uint8]string, d *Decoder) {
  21131. if v, changed := f.DecMapUint8StringV(*vp, true, d); changed {
  21132. *vp = v
  21133. }
  21134. }
  21135. func (_ fastpathT) DecMapUint8StringV(v map[uint8]string, canChange bool,
  21136. d *Decoder) (_ map[uint8]string, changed bool) {
  21137. dd, esep := d.d, d.hh.hasElemSeparators()
  21138. containerLen := dd.ReadMapStart()
  21139. if canChange && v == nil {
  21140. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  21141. v = make(map[uint8]string, xlen)
  21142. changed = true
  21143. }
  21144. if containerLen == 0 {
  21145. dd.ReadMapEnd()
  21146. return v, changed
  21147. }
  21148. var mk uint8
  21149. var mv string
  21150. hasLen := containerLen > 0
  21151. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21152. if esep {
  21153. dd.ReadMapElemKey()
  21154. }
  21155. mk = uint8(dd.DecodeUint(8))
  21156. if esep {
  21157. dd.ReadMapElemValue()
  21158. }
  21159. if dd.TryDecodeAsNil() {
  21160. if d.h.DeleteOnNilMapValue {
  21161. delete(v, mk)
  21162. } else {
  21163. v[mk] = ""
  21164. }
  21165. continue
  21166. }
  21167. mv = dd.DecodeString()
  21168. if v != nil {
  21169. v[mk] = mv
  21170. }
  21171. }
  21172. dd.ReadMapEnd()
  21173. return v, changed
  21174. }
  21175. func (d *Decoder) fastpathDecMapUint8UintR(f *codecFnInfo, rv reflect.Value) {
  21176. if rv.Kind() == reflect.Ptr {
  21177. vp := rv2i(rv).(*map[uint8]uint)
  21178. if v, changed := fastpathTV.DecMapUint8UintV(*vp, true, d); changed {
  21179. *vp = v
  21180. }
  21181. return
  21182. }
  21183. fastpathTV.DecMapUint8UintV(rv2i(rv).(map[uint8]uint), false, d)
  21184. }
  21185. func (f fastpathT) DecMapUint8UintX(vp *map[uint8]uint, d *Decoder) {
  21186. if v, changed := f.DecMapUint8UintV(*vp, true, d); changed {
  21187. *vp = v
  21188. }
  21189. }
  21190. func (_ fastpathT) DecMapUint8UintV(v map[uint8]uint, canChange bool,
  21191. d *Decoder) (_ map[uint8]uint, changed bool) {
  21192. dd, esep := d.d, d.hh.hasElemSeparators()
  21193. containerLen := dd.ReadMapStart()
  21194. if canChange && v == nil {
  21195. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  21196. v = make(map[uint8]uint, xlen)
  21197. changed = true
  21198. }
  21199. if containerLen == 0 {
  21200. dd.ReadMapEnd()
  21201. return v, changed
  21202. }
  21203. var mk uint8
  21204. var mv uint
  21205. hasLen := containerLen > 0
  21206. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21207. if esep {
  21208. dd.ReadMapElemKey()
  21209. }
  21210. mk = uint8(dd.DecodeUint(8))
  21211. if esep {
  21212. dd.ReadMapElemValue()
  21213. }
  21214. if dd.TryDecodeAsNil() {
  21215. if d.h.DeleteOnNilMapValue {
  21216. delete(v, mk)
  21217. } else {
  21218. v[mk] = 0
  21219. }
  21220. continue
  21221. }
  21222. mv = uint(dd.DecodeUint(uintBitsize))
  21223. if v != nil {
  21224. v[mk] = mv
  21225. }
  21226. }
  21227. dd.ReadMapEnd()
  21228. return v, changed
  21229. }
  21230. func (d *Decoder) fastpathDecMapUint8Uint8R(f *codecFnInfo, rv reflect.Value) {
  21231. if rv.Kind() == reflect.Ptr {
  21232. vp := rv2i(rv).(*map[uint8]uint8)
  21233. if v, changed := fastpathTV.DecMapUint8Uint8V(*vp, true, d); changed {
  21234. *vp = v
  21235. }
  21236. return
  21237. }
  21238. fastpathTV.DecMapUint8Uint8V(rv2i(rv).(map[uint8]uint8), false, d)
  21239. }
  21240. func (f fastpathT) DecMapUint8Uint8X(vp *map[uint8]uint8, d *Decoder) {
  21241. if v, changed := f.DecMapUint8Uint8V(*vp, true, d); changed {
  21242. *vp = v
  21243. }
  21244. }
  21245. func (_ fastpathT) DecMapUint8Uint8V(v map[uint8]uint8, canChange bool,
  21246. d *Decoder) (_ map[uint8]uint8, changed bool) {
  21247. dd, esep := d.d, d.hh.hasElemSeparators()
  21248. containerLen := dd.ReadMapStart()
  21249. if canChange && v == nil {
  21250. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  21251. v = make(map[uint8]uint8, xlen)
  21252. changed = true
  21253. }
  21254. if containerLen == 0 {
  21255. dd.ReadMapEnd()
  21256. return v, changed
  21257. }
  21258. var mk uint8
  21259. var mv uint8
  21260. hasLen := containerLen > 0
  21261. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21262. if esep {
  21263. dd.ReadMapElemKey()
  21264. }
  21265. mk = uint8(dd.DecodeUint(8))
  21266. if esep {
  21267. dd.ReadMapElemValue()
  21268. }
  21269. if dd.TryDecodeAsNil() {
  21270. if d.h.DeleteOnNilMapValue {
  21271. delete(v, mk)
  21272. } else {
  21273. v[mk] = 0
  21274. }
  21275. continue
  21276. }
  21277. mv = uint8(dd.DecodeUint(8))
  21278. if v != nil {
  21279. v[mk] = mv
  21280. }
  21281. }
  21282. dd.ReadMapEnd()
  21283. return v, changed
  21284. }
  21285. func (d *Decoder) fastpathDecMapUint8Uint16R(f *codecFnInfo, rv reflect.Value) {
  21286. if rv.Kind() == reflect.Ptr {
  21287. vp := rv2i(rv).(*map[uint8]uint16)
  21288. if v, changed := fastpathTV.DecMapUint8Uint16V(*vp, true, d); changed {
  21289. *vp = v
  21290. }
  21291. return
  21292. }
  21293. fastpathTV.DecMapUint8Uint16V(rv2i(rv).(map[uint8]uint16), false, d)
  21294. }
  21295. func (f fastpathT) DecMapUint8Uint16X(vp *map[uint8]uint16, d *Decoder) {
  21296. if v, changed := f.DecMapUint8Uint16V(*vp, true, d); changed {
  21297. *vp = v
  21298. }
  21299. }
  21300. func (_ fastpathT) DecMapUint8Uint16V(v map[uint8]uint16, canChange bool,
  21301. d *Decoder) (_ map[uint8]uint16, changed bool) {
  21302. dd, esep := d.d, d.hh.hasElemSeparators()
  21303. containerLen := dd.ReadMapStart()
  21304. if canChange && v == nil {
  21305. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  21306. v = make(map[uint8]uint16, xlen)
  21307. changed = true
  21308. }
  21309. if containerLen == 0 {
  21310. dd.ReadMapEnd()
  21311. return v, changed
  21312. }
  21313. var mk uint8
  21314. var mv uint16
  21315. hasLen := containerLen > 0
  21316. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21317. if esep {
  21318. dd.ReadMapElemKey()
  21319. }
  21320. mk = uint8(dd.DecodeUint(8))
  21321. if esep {
  21322. dd.ReadMapElemValue()
  21323. }
  21324. if dd.TryDecodeAsNil() {
  21325. if d.h.DeleteOnNilMapValue {
  21326. delete(v, mk)
  21327. } else {
  21328. v[mk] = 0
  21329. }
  21330. continue
  21331. }
  21332. mv = uint16(dd.DecodeUint(16))
  21333. if v != nil {
  21334. v[mk] = mv
  21335. }
  21336. }
  21337. dd.ReadMapEnd()
  21338. return v, changed
  21339. }
  21340. func (d *Decoder) fastpathDecMapUint8Uint32R(f *codecFnInfo, rv reflect.Value) {
  21341. if rv.Kind() == reflect.Ptr {
  21342. vp := rv2i(rv).(*map[uint8]uint32)
  21343. if v, changed := fastpathTV.DecMapUint8Uint32V(*vp, true, d); changed {
  21344. *vp = v
  21345. }
  21346. return
  21347. }
  21348. fastpathTV.DecMapUint8Uint32V(rv2i(rv).(map[uint8]uint32), false, d)
  21349. }
  21350. func (f fastpathT) DecMapUint8Uint32X(vp *map[uint8]uint32, d *Decoder) {
  21351. if v, changed := f.DecMapUint8Uint32V(*vp, true, d); changed {
  21352. *vp = v
  21353. }
  21354. }
  21355. func (_ fastpathT) DecMapUint8Uint32V(v map[uint8]uint32, canChange bool,
  21356. d *Decoder) (_ map[uint8]uint32, changed bool) {
  21357. dd, esep := d.d, d.hh.hasElemSeparators()
  21358. containerLen := dd.ReadMapStart()
  21359. if canChange && v == nil {
  21360. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  21361. v = make(map[uint8]uint32, xlen)
  21362. changed = true
  21363. }
  21364. if containerLen == 0 {
  21365. dd.ReadMapEnd()
  21366. return v, changed
  21367. }
  21368. var mk uint8
  21369. var mv uint32
  21370. hasLen := containerLen > 0
  21371. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21372. if esep {
  21373. dd.ReadMapElemKey()
  21374. }
  21375. mk = uint8(dd.DecodeUint(8))
  21376. if esep {
  21377. dd.ReadMapElemValue()
  21378. }
  21379. if dd.TryDecodeAsNil() {
  21380. if d.h.DeleteOnNilMapValue {
  21381. delete(v, mk)
  21382. } else {
  21383. v[mk] = 0
  21384. }
  21385. continue
  21386. }
  21387. mv = uint32(dd.DecodeUint(32))
  21388. if v != nil {
  21389. v[mk] = mv
  21390. }
  21391. }
  21392. dd.ReadMapEnd()
  21393. return v, changed
  21394. }
  21395. func (d *Decoder) fastpathDecMapUint8Uint64R(f *codecFnInfo, rv reflect.Value) {
  21396. if rv.Kind() == reflect.Ptr {
  21397. vp := rv2i(rv).(*map[uint8]uint64)
  21398. if v, changed := fastpathTV.DecMapUint8Uint64V(*vp, true, d); changed {
  21399. *vp = v
  21400. }
  21401. return
  21402. }
  21403. fastpathTV.DecMapUint8Uint64V(rv2i(rv).(map[uint8]uint64), false, d)
  21404. }
  21405. func (f fastpathT) DecMapUint8Uint64X(vp *map[uint8]uint64, d *Decoder) {
  21406. if v, changed := f.DecMapUint8Uint64V(*vp, true, d); changed {
  21407. *vp = v
  21408. }
  21409. }
  21410. func (_ fastpathT) DecMapUint8Uint64V(v map[uint8]uint64, canChange bool,
  21411. d *Decoder) (_ map[uint8]uint64, changed bool) {
  21412. dd, esep := d.d, d.hh.hasElemSeparators()
  21413. containerLen := dd.ReadMapStart()
  21414. if canChange && v == nil {
  21415. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  21416. v = make(map[uint8]uint64, xlen)
  21417. changed = true
  21418. }
  21419. if containerLen == 0 {
  21420. dd.ReadMapEnd()
  21421. return v, changed
  21422. }
  21423. var mk uint8
  21424. var mv uint64
  21425. hasLen := containerLen > 0
  21426. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21427. if esep {
  21428. dd.ReadMapElemKey()
  21429. }
  21430. mk = uint8(dd.DecodeUint(8))
  21431. if esep {
  21432. dd.ReadMapElemValue()
  21433. }
  21434. if dd.TryDecodeAsNil() {
  21435. if d.h.DeleteOnNilMapValue {
  21436. delete(v, mk)
  21437. } else {
  21438. v[mk] = 0
  21439. }
  21440. continue
  21441. }
  21442. mv = dd.DecodeUint(64)
  21443. if v != nil {
  21444. v[mk] = mv
  21445. }
  21446. }
  21447. dd.ReadMapEnd()
  21448. return v, changed
  21449. }
  21450. func (d *Decoder) fastpathDecMapUint8UintptrR(f *codecFnInfo, rv reflect.Value) {
  21451. if rv.Kind() == reflect.Ptr {
  21452. vp := rv2i(rv).(*map[uint8]uintptr)
  21453. if v, changed := fastpathTV.DecMapUint8UintptrV(*vp, true, d); changed {
  21454. *vp = v
  21455. }
  21456. return
  21457. }
  21458. fastpathTV.DecMapUint8UintptrV(rv2i(rv).(map[uint8]uintptr), false, d)
  21459. }
  21460. func (f fastpathT) DecMapUint8UintptrX(vp *map[uint8]uintptr, d *Decoder) {
  21461. if v, changed := f.DecMapUint8UintptrV(*vp, true, d); changed {
  21462. *vp = v
  21463. }
  21464. }
  21465. func (_ fastpathT) DecMapUint8UintptrV(v map[uint8]uintptr, canChange bool,
  21466. d *Decoder) (_ map[uint8]uintptr, changed bool) {
  21467. dd, esep := d.d, d.hh.hasElemSeparators()
  21468. containerLen := dd.ReadMapStart()
  21469. if canChange && v == nil {
  21470. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  21471. v = make(map[uint8]uintptr, xlen)
  21472. changed = true
  21473. }
  21474. if containerLen == 0 {
  21475. dd.ReadMapEnd()
  21476. return v, changed
  21477. }
  21478. var mk uint8
  21479. var mv uintptr
  21480. hasLen := containerLen > 0
  21481. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21482. if esep {
  21483. dd.ReadMapElemKey()
  21484. }
  21485. mk = uint8(dd.DecodeUint(8))
  21486. if esep {
  21487. dd.ReadMapElemValue()
  21488. }
  21489. if dd.TryDecodeAsNil() {
  21490. if d.h.DeleteOnNilMapValue {
  21491. delete(v, mk)
  21492. } else {
  21493. v[mk] = 0
  21494. }
  21495. continue
  21496. }
  21497. mv = uintptr(dd.DecodeUint(uintBitsize))
  21498. if v != nil {
  21499. v[mk] = mv
  21500. }
  21501. }
  21502. dd.ReadMapEnd()
  21503. return v, changed
  21504. }
  21505. func (d *Decoder) fastpathDecMapUint8IntR(f *codecFnInfo, rv reflect.Value) {
  21506. if rv.Kind() == reflect.Ptr {
  21507. vp := rv2i(rv).(*map[uint8]int)
  21508. if v, changed := fastpathTV.DecMapUint8IntV(*vp, true, d); changed {
  21509. *vp = v
  21510. }
  21511. return
  21512. }
  21513. fastpathTV.DecMapUint8IntV(rv2i(rv).(map[uint8]int), false, d)
  21514. }
  21515. func (f fastpathT) DecMapUint8IntX(vp *map[uint8]int, d *Decoder) {
  21516. if v, changed := f.DecMapUint8IntV(*vp, true, d); changed {
  21517. *vp = v
  21518. }
  21519. }
  21520. func (_ fastpathT) DecMapUint8IntV(v map[uint8]int, canChange bool,
  21521. d *Decoder) (_ map[uint8]int, changed bool) {
  21522. dd, esep := d.d, d.hh.hasElemSeparators()
  21523. containerLen := dd.ReadMapStart()
  21524. if canChange && v == nil {
  21525. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  21526. v = make(map[uint8]int, xlen)
  21527. changed = true
  21528. }
  21529. if containerLen == 0 {
  21530. dd.ReadMapEnd()
  21531. return v, changed
  21532. }
  21533. var mk uint8
  21534. var mv int
  21535. hasLen := containerLen > 0
  21536. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21537. if esep {
  21538. dd.ReadMapElemKey()
  21539. }
  21540. mk = uint8(dd.DecodeUint(8))
  21541. if esep {
  21542. dd.ReadMapElemValue()
  21543. }
  21544. if dd.TryDecodeAsNil() {
  21545. if d.h.DeleteOnNilMapValue {
  21546. delete(v, mk)
  21547. } else {
  21548. v[mk] = 0
  21549. }
  21550. continue
  21551. }
  21552. mv = int(dd.DecodeInt(intBitsize))
  21553. if v != nil {
  21554. v[mk] = mv
  21555. }
  21556. }
  21557. dd.ReadMapEnd()
  21558. return v, changed
  21559. }
  21560. func (d *Decoder) fastpathDecMapUint8Int8R(f *codecFnInfo, rv reflect.Value) {
  21561. if rv.Kind() == reflect.Ptr {
  21562. vp := rv2i(rv).(*map[uint8]int8)
  21563. if v, changed := fastpathTV.DecMapUint8Int8V(*vp, true, d); changed {
  21564. *vp = v
  21565. }
  21566. return
  21567. }
  21568. fastpathTV.DecMapUint8Int8V(rv2i(rv).(map[uint8]int8), false, d)
  21569. }
  21570. func (f fastpathT) DecMapUint8Int8X(vp *map[uint8]int8, d *Decoder) {
  21571. if v, changed := f.DecMapUint8Int8V(*vp, true, d); changed {
  21572. *vp = v
  21573. }
  21574. }
  21575. func (_ fastpathT) DecMapUint8Int8V(v map[uint8]int8, canChange bool,
  21576. d *Decoder) (_ map[uint8]int8, changed bool) {
  21577. dd, esep := d.d, d.hh.hasElemSeparators()
  21578. containerLen := dd.ReadMapStart()
  21579. if canChange && v == nil {
  21580. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  21581. v = make(map[uint8]int8, xlen)
  21582. changed = true
  21583. }
  21584. if containerLen == 0 {
  21585. dd.ReadMapEnd()
  21586. return v, changed
  21587. }
  21588. var mk uint8
  21589. var mv int8
  21590. hasLen := containerLen > 0
  21591. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21592. if esep {
  21593. dd.ReadMapElemKey()
  21594. }
  21595. mk = uint8(dd.DecodeUint(8))
  21596. if esep {
  21597. dd.ReadMapElemValue()
  21598. }
  21599. if dd.TryDecodeAsNil() {
  21600. if d.h.DeleteOnNilMapValue {
  21601. delete(v, mk)
  21602. } else {
  21603. v[mk] = 0
  21604. }
  21605. continue
  21606. }
  21607. mv = int8(dd.DecodeInt(8))
  21608. if v != nil {
  21609. v[mk] = mv
  21610. }
  21611. }
  21612. dd.ReadMapEnd()
  21613. return v, changed
  21614. }
  21615. func (d *Decoder) fastpathDecMapUint8Int16R(f *codecFnInfo, rv reflect.Value) {
  21616. if rv.Kind() == reflect.Ptr {
  21617. vp := rv2i(rv).(*map[uint8]int16)
  21618. if v, changed := fastpathTV.DecMapUint8Int16V(*vp, true, d); changed {
  21619. *vp = v
  21620. }
  21621. return
  21622. }
  21623. fastpathTV.DecMapUint8Int16V(rv2i(rv).(map[uint8]int16), false, d)
  21624. }
  21625. func (f fastpathT) DecMapUint8Int16X(vp *map[uint8]int16, d *Decoder) {
  21626. if v, changed := f.DecMapUint8Int16V(*vp, true, d); changed {
  21627. *vp = v
  21628. }
  21629. }
  21630. func (_ fastpathT) DecMapUint8Int16V(v map[uint8]int16, canChange bool,
  21631. d *Decoder) (_ map[uint8]int16, changed bool) {
  21632. dd, esep := d.d, d.hh.hasElemSeparators()
  21633. containerLen := dd.ReadMapStart()
  21634. if canChange && v == nil {
  21635. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  21636. v = make(map[uint8]int16, xlen)
  21637. changed = true
  21638. }
  21639. if containerLen == 0 {
  21640. dd.ReadMapEnd()
  21641. return v, changed
  21642. }
  21643. var mk uint8
  21644. var mv int16
  21645. hasLen := containerLen > 0
  21646. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21647. if esep {
  21648. dd.ReadMapElemKey()
  21649. }
  21650. mk = uint8(dd.DecodeUint(8))
  21651. if esep {
  21652. dd.ReadMapElemValue()
  21653. }
  21654. if dd.TryDecodeAsNil() {
  21655. if d.h.DeleteOnNilMapValue {
  21656. delete(v, mk)
  21657. } else {
  21658. v[mk] = 0
  21659. }
  21660. continue
  21661. }
  21662. mv = int16(dd.DecodeInt(16))
  21663. if v != nil {
  21664. v[mk] = mv
  21665. }
  21666. }
  21667. dd.ReadMapEnd()
  21668. return v, changed
  21669. }
  21670. func (d *Decoder) fastpathDecMapUint8Int32R(f *codecFnInfo, rv reflect.Value) {
  21671. if rv.Kind() == reflect.Ptr {
  21672. vp := rv2i(rv).(*map[uint8]int32)
  21673. if v, changed := fastpathTV.DecMapUint8Int32V(*vp, true, d); changed {
  21674. *vp = v
  21675. }
  21676. return
  21677. }
  21678. fastpathTV.DecMapUint8Int32V(rv2i(rv).(map[uint8]int32), false, d)
  21679. }
  21680. func (f fastpathT) DecMapUint8Int32X(vp *map[uint8]int32, d *Decoder) {
  21681. if v, changed := f.DecMapUint8Int32V(*vp, true, d); changed {
  21682. *vp = v
  21683. }
  21684. }
  21685. func (_ fastpathT) DecMapUint8Int32V(v map[uint8]int32, canChange bool,
  21686. d *Decoder) (_ map[uint8]int32, changed bool) {
  21687. dd, esep := d.d, d.hh.hasElemSeparators()
  21688. containerLen := dd.ReadMapStart()
  21689. if canChange && v == nil {
  21690. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  21691. v = make(map[uint8]int32, xlen)
  21692. changed = true
  21693. }
  21694. if containerLen == 0 {
  21695. dd.ReadMapEnd()
  21696. return v, changed
  21697. }
  21698. var mk uint8
  21699. var mv int32
  21700. hasLen := containerLen > 0
  21701. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21702. if esep {
  21703. dd.ReadMapElemKey()
  21704. }
  21705. mk = uint8(dd.DecodeUint(8))
  21706. if esep {
  21707. dd.ReadMapElemValue()
  21708. }
  21709. if dd.TryDecodeAsNil() {
  21710. if d.h.DeleteOnNilMapValue {
  21711. delete(v, mk)
  21712. } else {
  21713. v[mk] = 0
  21714. }
  21715. continue
  21716. }
  21717. mv = int32(dd.DecodeInt(32))
  21718. if v != nil {
  21719. v[mk] = mv
  21720. }
  21721. }
  21722. dd.ReadMapEnd()
  21723. return v, changed
  21724. }
  21725. func (d *Decoder) fastpathDecMapUint8Int64R(f *codecFnInfo, rv reflect.Value) {
  21726. if rv.Kind() == reflect.Ptr {
  21727. vp := rv2i(rv).(*map[uint8]int64)
  21728. if v, changed := fastpathTV.DecMapUint8Int64V(*vp, true, d); changed {
  21729. *vp = v
  21730. }
  21731. return
  21732. }
  21733. fastpathTV.DecMapUint8Int64V(rv2i(rv).(map[uint8]int64), false, d)
  21734. }
  21735. func (f fastpathT) DecMapUint8Int64X(vp *map[uint8]int64, d *Decoder) {
  21736. if v, changed := f.DecMapUint8Int64V(*vp, true, d); changed {
  21737. *vp = v
  21738. }
  21739. }
  21740. func (_ fastpathT) DecMapUint8Int64V(v map[uint8]int64, canChange bool,
  21741. d *Decoder) (_ map[uint8]int64, changed bool) {
  21742. dd, esep := d.d, d.hh.hasElemSeparators()
  21743. containerLen := dd.ReadMapStart()
  21744. if canChange && v == nil {
  21745. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  21746. v = make(map[uint8]int64, xlen)
  21747. changed = true
  21748. }
  21749. if containerLen == 0 {
  21750. dd.ReadMapEnd()
  21751. return v, changed
  21752. }
  21753. var mk uint8
  21754. var mv int64
  21755. hasLen := containerLen > 0
  21756. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21757. if esep {
  21758. dd.ReadMapElemKey()
  21759. }
  21760. mk = uint8(dd.DecodeUint(8))
  21761. if esep {
  21762. dd.ReadMapElemValue()
  21763. }
  21764. if dd.TryDecodeAsNil() {
  21765. if d.h.DeleteOnNilMapValue {
  21766. delete(v, mk)
  21767. } else {
  21768. v[mk] = 0
  21769. }
  21770. continue
  21771. }
  21772. mv = dd.DecodeInt(64)
  21773. if v != nil {
  21774. v[mk] = mv
  21775. }
  21776. }
  21777. dd.ReadMapEnd()
  21778. return v, changed
  21779. }
  21780. func (d *Decoder) fastpathDecMapUint8Float32R(f *codecFnInfo, rv reflect.Value) {
  21781. if rv.Kind() == reflect.Ptr {
  21782. vp := rv2i(rv).(*map[uint8]float32)
  21783. if v, changed := fastpathTV.DecMapUint8Float32V(*vp, true, d); changed {
  21784. *vp = v
  21785. }
  21786. return
  21787. }
  21788. fastpathTV.DecMapUint8Float32V(rv2i(rv).(map[uint8]float32), false, d)
  21789. }
  21790. func (f fastpathT) DecMapUint8Float32X(vp *map[uint8]float32, d *Decoder) {
  21791. if v, changed := f.DecMapUint8Float32V(*vp, true, d); changed {
  21792. *vp = v
  21793. }
  21794. }
  21795. func (_ fastpathT) DecMapUint8Float32V(v map[uint8]float32, canChange bool,
  21796. d *Decoder) (_ map[uint8]float32, changed bool) {
  21797. dd, esep := d.d, d.hh.hasElemSeparators()
  21798. containerLen := dd.ReadMapStart()
  21799. if canChange && v == nil {
  21800. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  21801. v = make(map[uint8]float32, xlen)
  21802. changed = true
  21803. }
  21804. if containerLen == 0 {
  21805. dd.ReadMapEnd()
  21806. return v, changed
  21807. }
  21808. var mk uint8
  21809. var mv float32
  21810. hasLen := containerLen > 0
  21811. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21812. if esep {
  21813. dd.ReadMapElemKey()
  21814. }
  21815. mk = uint8(dd.DecodeUint(8))
  21816. if esep {
  21817. dd.ReadMapElemValue()
  21818. }
  21819. if dd.TryDecodeAsNil() {
  21820. if d.h.DeleteOnNilMapValue {
  21821. delete(v, mk)
  21822. } else {
  21823. v[mk] = 0
  21824. }
  21825. continue
  21826. }
  21827. mv = float32(dd.DecodeFloat(true))
  21828. if v != nil {
  21829. v[mk] = mv
  21830. }
  21831. }
  21832. dd.ReadMapEnd()
  21833. return v, changed
  21834. }
  21835. func (d *Decoder) fastpathDecMapUint8Float64R(f *codecFnInfo, rv reflect.Value) {
  21836. if rv.Kind() == reflect.Ptr {
  21837. vp := rv2i(rv).(*map[uint8]float64)
  21838. if v, changed := fastpathTV.DecMapUint8Float64V(*vp, true, d); changed {
  21839. *vp = v
  21840. }
  21841. return
  21842. }
  21843. fastpathTV.DecMapUint8Float64V(rv2i(rv).(map[uint8]float64), false, d)
  21844. }
  21845. func (f fastpathT) DecMapUint8Float64X(vp *map[uint8]float64, d *Decoder) {
  21846. if v, changed := f.DecMapUint8Float64V(*vp, true, d); changed {
  21847. *vp = v
  21848. }
  21849. }
  21850. func (_ fastpathT) DecMapUint8Float64V(v map[uint8]float64, canChange bool,
  21851. d *Decoder) (_ map[uint8]float64, changed bool) {
  21852. dd, esep := d.d, d.hh.hasElemSeparators()
  21853. containerLen := dd.ReadMapStart()
  21854. if canChange && v == nil {
  21855. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  21856. v = make(map[uint8]float64, xlen)
  21857. changed = true
  21858. }
  21859. if containerLen == 0 {
  21860. dd.ReadMapEnd()
  21861. return v, changed
  21862. }
  21863. var mk uint8
  21864. var mv float64
  21865. hasLen := containerLen > 0
  21866. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21867. if esep {
  21868. dd.ReadMapElemKey()
  21869. }
  21870. mk = uint8(dd.DecodeUint(8))
  21871. if esep {
  21872. dd.ReadMapElemValue()
  21873. }
  21874. if dd.TryDecodeAsNil() {
  21875. if d.h.DeleteOnNilMapValue {
  21876. delete(v, mk)
  21877. } else {
  21878. v[mk] = 0
  21879. }
  21880. continue
  21881. }
  21882. mv = dd.DecodeFloat(false)
  21883. if v != nil {
  21884. v[mk] = mv
  21885. }
  21886. }
  21887. dd.ReadMapEnd()
  21888. return v, changed
  21889. }
  21890. func (d *Decoder) fastpathDecMapUint8BoolR(f *codecFnInfo, rv reflect.Value) {
  21891. if rv.Kind() == reflect.Ptr {
  21892. vp := rv2i(rv).(*map[uint8]bool)
  21893. if v, changed := fastpathTV.DecMapUint8BoolV(*vp, true, d); changed {
  21894. *vp = v
  21895. }
  21896. return
  21897. }
  21898. fastpathTV.DecMapUint8BoolV(rv2i(rv).(map[uint8]bool), false, d)
  21899. }
  21900. func (f fastpathT) DecMapUint8BoolX(vp *map[uint8]bool, d *Decoder) {
  21901. if v, changed := f.DecMapUint8BoolV(*vp, true, d); changed {
  21902. *vp = v
  21903. }
  21904. }
  21905. func (_ fastpathT) DecMapUint8BoolV(v map[uint8]bool, canChange bool,
  21906. d *Decoder) (_ map[uint8]bool, changed bool) {
  21907. dd, esep := d.d, d.hh.hasElemSeparators()
  21908. containerLen := dd.ReadMapStart()
  21909. if canChange && v == nil {
  21910. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  21911. v = make(map[uint8]bool, xlen)
  21912. changed = true
  21913. }
  21914. if containerLen == 0 {
  21915. dd.ReadMapEnd()
  21916. return v, changed
  21917. }
  21918. var mk uint8
  21919. var mv bool
  21920. hasLen := containerLen > 0
  21921. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21922. if esep {
  21923. dd.ReadMapElemKey()
  21924. }
  21925. mk = uint8(dd.DecodeUint(8))
  21926. if esep {
  21927. dd.ReadMapElemValue()
  21928. }
  21929. if dd.TryDecodeAsNil() {
  21930. if d.h.DeleteOnNilMapValue {
  21931. delete(v, mk)
  21932. } else {
  21933. v[mk] = false
  21934. }
  21935. continue
  21936. }
  21937. mv = dd.DecodeBool()
  21938. if v != nil {
  21939. v[mk] = mv
  21940. }
  21941. }
  21942. dd.ReadMapEnd()
  21943. return v, changed
  21944. }
  21945. func (d *Decoder) fastpathDecMapUint16IntfR(f *codecFnInfo, rv reflect.Value) {
  21946. if rv.Kind() == reflect.Ptr {
  21947. vp := rv2i(rv).(*map[uint16]interface{})
  21948. if v, changed := fastpathTV.DecMapUint16IntfV(*vp, true, d); changed {
  21949. *vp = v
  21950. }
  21951. return
  21952. }
  21953. fastpathTV.DecMapUint16IntfV(rv2i(rv).(map[uint16]interface{}), false, d)
  21954. }
  21955. func (f fastpathT) DecMapUint16IntfX(vp *map[uint16]interface{}, d *Decoder) {
  21956. if v, changed := f.DecMapUint16IntfV(*vp, true, d); changed {
  21957. *vp = v
  21958. }
  21959. }
  21960. func (_ fastpathT) DecMapUint16IntfV(v map[uint16]interface{}, canChange bool,
  21961. d *Decoder) (_ map[uint16]interface{}, changed bool) {
  21962. dd, esep := d.d, d.hh.hasElemSeparators()
  21963. containerLen := dd.ReadMapStart()
  21964. if canChange && v == nil {
  21965. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  21966. v = make(map[uint16]interface{}, xlen)
  21967. changed = true
  21968. }
  21969. if containerLen == 0 {
  21970. dd.ReadMapEnd()
  21971. return v, changed
  21972. }
  21973. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  21974. var mk uint16
  21975. var mv interface{}
  21976. hasLen := containerLen > 0
  21977. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  21978. if esep {
  21979. dd.ReadMapElemKey()
  21980. }
  21981. mk = uint16(dd.DecodeUint(16))
  21982. if esep {
  21983. dd.ReadMapElemValue()
  21984. }
  21985. if dd.TryDecodeAsNil() {
  21986. if d.h.DeleteOnNilMapValue {
  21987. delete(v, mk)
  21988. } else {
  21989. v[mk] = nil
  21990. }
  21991. continue
  21992. }
  21993. if mapGet {
  21994. mv = v[mk]
  21995. } else {
  21996. mv = nil
  21997. }
  21998. d.decode(&mv)
  21999. if v != nil {
  22000. v[mk] = mv
  22001. }
  22002. }
  22003. dd.ReadMapEnd()
  22004. return v, changed
  22005. }
  22006. func (d *Decoder) fastpathDecMapUint16StringR(f *codecFnInfo, rv reflect.Value) {
  22007. if rv.Kind() == reflect.Ptr {
  22008. vp := rv2i(rv).(*map[uint16]string)
  22009. if v, changed := fastpathTV.DecMapUint16StringV(*vp, true, d); changed {
  22010. *vp = v
  22011. }
  22012. return
  22013. }
  22014. fastpathTV.DecMapUint16StringV(rv2i(rv).(map[uint16]string), false, d)
  22015. }
  22016. func (f fastpathT) DecMapUint16StringX(vp *map[uint16]string, d *Decoder) {
  22017. if v, changed := f.DecMapUint16StringV(*vp, true, d); changed {
  22018. *vp = v
  22019. }
  22020. }
  22021. func (_ fastpathT) DecMapUint16StringV(v map[uint16]string, canChange bool,
  22022. d *Decoder) (_ map[uint16]string, changed bool) {
  22023. dd, esep := d.d, d.hh.hasElemSeparators()
  22024. containerLen := dd.ReadMapStart()
  22025. if canChange && v == nil {
  22026. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  22027. v = make(map[uint16]string, xlen)
  22028. changed = true
  22029. }
  22030. if containerLen == 0 {
  22031. dd.ReadMapEnd()
  22032. return v, changed
  22033. }
  22034. var mk uint16
  22035. var mv string
  22036. hasLen := containerLen > 0
  22037. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22038. if esep {
  22039. dd.ReadMapElemKey()
  22040. }
  22041. mk = uint16(dd.DecodeUint(16))
  22042. if esep {
  22043. dd.ReadMapElemValue()
  22044. }
  22045. if dd.TryDecodeAsNil() {
  22046. if d.h.DeleteOnNilMapValue {
  22047. delete(v, mk)
  22048. } else {
  22049. v[mk] = ""
  22050. }
  22051. continue
  22052. }
  22053. mv = dd.DecodeString()
  22054. if v != nil {
  22055. v[mk] = mv
  22056. }
  22057. }
  22058. dd.ReadMapEnd()
  22059. return v, changed
  22060. }
  22061. func (d *Decoder) fastpathDecMapUint16UintR(f *codecFnInfo, rv reflect.Value) {
  22062. if rv.Kind() == reflect.Ptr {
  22063. vp := rv2i(rv).(*map[uint16]uint)
  22064. if v, changed := fastpathTV.DecMapUint16UintV(*vp, true, d); changed {
  22065. *vp = v
  22066. }
  22067. return
  22068. }
  22069. fastpathTV.DecMapUint16UintV(rv2i(rv).(map[uint16]uint), false, d)
  22070. }
  22071. func (f fastpathT) DecMapUint16UintX(vp *map[uint16]uint, d *Decoder) {
  22072. if v, changed := f.DecMapUint16UintV(*vp, true, d); changed {
  22073. *vp = v
  22074. }
  22075. }
  22076. func (_ fastpathT) DecMapUint16UintV(v map[uint16]uint, canChange bool,
  22077. d *Decoder) (_ map[uint16]uint, changed bool) {
  22078. dd, esep := d.d, d.hh.hasElemSeparators()
  22079. containerLen := dd.ReadMapStart()
  22080. if canChange && v == nil {
  22081. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  22082. v = make(map[uint16]uint, xlen)
  22083. changed = true
  22084. }
  22085. if containerLen == 0 {
  22086. dd.ReadMapEnd()
  22087. return v, changed
  22088. }
  22089. var mk uint16
  22090. var mv uint
  22091. hasLen := containerLen > 0
  22092. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22093. if esep {
  22094. dd.ReadMapElemKey()
  22095. }
  22096. mk = uint16(dd.DecodeUint(16))
  22097. if esep {
  22098. dd.ReadMapElemValue()
  22099. }
  22100. if dd.TryDecodeAsNil() {
  22101. if d.h.DeleteOnNilMapValue {
  22102. delete(v, mk)
  22103. } else {
  22104. v[mk] = 0
  22105. }
  22106. continue
  22107. }
  22108. mv = uint(dd.DecodeUint(uintBitsize))
  22109. if v != nil {
  22110. v[mk] = mv
  22111. }
  22112. }
  22113. dd.ReadMapEnd()
  22114. return v, changed
  22115. }
  22116. func (d *Decoder) fastpathDecMapUint16Uint8R(f *codecFnInfo, rv reflect.Value) {
  22117. if rv.Kind() == reflect.Ptr {
  22118. vp := rv2i(rv).(*map[uint16]uint8)
  22119. if v, changed := fastpathTV.DecMapUint16Uint8V(*vp, true, d); changed {
  22120. *vp = v
  22121. }
  22122. return
  22123. }
  22124. fastpathTV.DecMapUint16Uint8V(rv2i(rv).(map[uint16]uint8), false, d)
  22125. }
  22126. func (f fastpathT) DecMapUint16Uint8X(vp *map[uint16]uint8, d *Decoder) {
  22127. if v, changed := f.DecMapUint16Uint8V(*vp, true, d); changed {
  22128. *vp = v
  22129. }
  22130. }
  22131. func (_ fastpathT) DecMapUint16Uint8V(v map[uint16]uint8, canChange bool,
  22132. d *Decoder) (_ map[uint16]uint8, changed bool) {
  22133. dd, esep := d.d, d.hh.hasElemSeparators()
  22134. containerLen := dd.ReadMapStart()
  22135. if canChange && v == nil {
  22136. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  22137. v = make(map[uint16]uint8, xlen)
  22138. changed = true
  22139. }
  22140. if containerLen == 0 {
  22141. dd.ReadMapEnd()
  22142. return v, changed
  22143. }
  22144. var mk uint16
  22145. var mv uint8
  22146. hasLen := containerLen > 0
  22147. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22148. if esep {
  22149. dd.ReadMapElemKey()
  22150. }
  22151. mk = uint16(dd.DecodeUint(16))
  22152. if esep {
  22153. dd.ReadMapElemValue()
  22154. }
  22155. if dd.TryDecodeAsNil() {
  22156. if d.h.DeleteOnNilMapValue {
  22157. delete(v, mk)
  22158. } else {
  22159. v[mk] = 0
  22160. }
  22161. continue
  22162. }
  22163. mv = uint8(dd.DecodeUint(8))
  22164. if v != nil {
  22165. v[mk] = mv
  22166. }
  22167. }
  22168. dd.ReadMapEnd()
  22169. return v, changed
  22170. }
  22171. func (d *Decoder) fastpathDecMapUint16Uint16R(f *codecFnInfo, rv reflect.Value) {
  22172. if rv.Kind() == reflect.Ptr {
  22173. vp := rv2i(rv).(*map[uint16]uint16)
  22174. if v, changed := fastpathTV.DecMapUint16Uint16V(*vp, true, d); changed {
  22175. *vp = v
  22176. }
  22177. return
  22178. }
  22179. fastpathTV.DecMapUint16Uint16V(rv2i(rv).(map[uint16]uint16), false, d)
  22180. }
  22181. func (f fastpathT) DecMapUint16Uint16X(vp *map[uint16]uint16, d *Decoder) {
  22182. if v, changed := f.DecMapUint16Uint16V(*vp, true, d); changed {
  22183. *vp = v
  22184. }
  22185. }
  22186. func (_ fastpathT) DecMapUint16Uint16V(v map[uint16]uint16, canChange bool,
  22187. d *Decoder) (_ map[uint16]uint16, changed bool) {
  22188. dd, esep := d.d, d.hh.hasElemSeparators()
  22189. containerLen := dd.ReadMapStart()
  22190. if canChange && v == nil {
  22191. xlen := decInferLen(containerLen, d.h.MaxInitLen, 4)
  22192. v = make(map[uint16]uint16, xlen)
  22193. changed = true
  22194. }
  22195. if containerLen == 0 {
  22196. dd.ReadMapEnd()
  22197. return v, changed
  22198. }
  22199. var mk uint16
  22200. var mv uint16
  22201. hasLen := containerLen > 0
  22202. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22203. if esep {
  22204. dd.ReadMapElemKey()
  22205. }
  22206. mk = uint16(dd.DecodeUint(16))
  22207. if esep {
  22208. dd.ReadMapElemValue()
  22209. }
  22210. if dd.TryDecodeAsNil() {
  22211. if d.h.DeleteOnNilMapValue {
  22212. delete(v, mk)
  22213. } else {
  22214. v[mk] = 0
  22215. }
  22216. continue
  22217. }
  22218. mv = uint16(dd.DecodeUint(16))
  22219. if v != nil {
  22220. v[mk] = mv
  22221. }
  22222. }
  22223. dd.ReadMapEnd()
  22224. return v, changed
  22225. }
  22226. func (d *Decoder) fastpathDecMapUint16Uint32R(f *codecFnInfo, rv reflect.Value) {
  22227. if rv.Kind() == reflect.Ptr {
  22228. vp := rv2i(rv).(*map[uint16]uint32)
  22229. if v, changed := fastpathTV.DecMapUint16Uint32V(*vp, true, d); changed {
  22230. *vp = v
  22231. }
  22232. return
  22233. }
  22234. fastpathTV.DecMapUint16Uint32V(rv2i(rv).(map[uint16]uint32), false, d)
  22235. }
  22236. func (f fastpathT) DecMapUint16Uint32X(vp *map[uint16]uint32, d *Decoder) {
  22237. if v, changed := f.DecMapUint16Uint32V(*vp, true, d); changed {
  22238. *vp = v
  22239. }
  22240. }
  22241. func (_ fastpathT) DecMapUint16Uint32V(v map[uint16]uint32, canChange bool,
  22242. d *Decoder) (_ map[uint16]uint32, changed bool) {
  22243. dd, esep := d.d, d.hh.hasElemSeparators()
  22244. containerLen := dd.ReadMapStart()
  22245. if canChange && v == nil {
  22246. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  22247. v = make(map[uint16]uint32, xlen)
  22248. changed = true
  22249. }
  22250. if containerLen == 0 {
  22251. dd.ReadMapEnd()
  22252. return v, changed
  22253. }
  22254. var mk uint16
  22255. var mv uint32
  22256. hasLen := containerLen > 0
  22257. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22258. if esep {
  22259. dd.ReadMapElemKey()
  22260. }
  22261. mk = uint16(dd.DecodeUint(16))
  22262. if esep {
  22263. dd.ReadMapElemValue()
  22264. }
  22265. if dd.TryDecodeAsNil() {
  22266. if d.h.DeleteOnNilMapValue {
  22267. delete(v, mk)
  22268. } else {
  22269. v[mk] = 0
  22270. }
  22271. continue
  22272. }
  22273. mv = uint32(dd.DecodeUint(32))
  22274. if v != nil {
  22275. v[mk] = mv
  22276. }
  22277. }
  22278. dd.ReadMapEnd()
  22279. return v, changed
  22280. }
  22281. func (d *Decoder) fastpathDecMapUint16Uint64R(f *codecFnInfo, rv reflect.Value) {
  22282. if rv.Kind() == reflect.Ptr {
  22283. vp := rv2i(rv).(*map[uint16]uint64)
  22284. if v, changed := fastpathTV.DecMapUint16Uint64V(*vp, true, d); changed {
  22285. *vp = v
  22286. }
  22287. return
  22288. }
  22289. fastpathTV.DecMapUint16Uint64V(rv2i(rv).(map[uint16]uint64), false, d)
  22290. }
  22291. func (f fastpathT) DecMapUint16Uint64X(vp *map[uint16]uint64, d *Decoder) {
  22292. if v, changed := f.DecMapUint16Uint64V(*vp, true, d); changed {
  22293. *vp = v
  22294. }
  22295. }
  22296. func (_ fastpathT) DecMapUint16Uint64V(v map[uint16]uint64, canChange bool,
  22297. d *Decoder) (_ map[uint16]uint64, changed bool) {
  22298. dd, esep := d.d, d.hh.hasElemSeparators()
  22299. containerLen := dd.ReadMapStart()
  22300. if canChange && v == nil {
  22301. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  22302. v = make(map[uint16]uint64, xlen)
  22303. changed = true
  22304. }
  22305. if containerLen == 0 {
  22306. dd.ReadMapEnd()
  22307. return v, changed
  22308. }
  22309. var mk uint16
  22310. var mv uint64
  22311. hasLen := containerLen > 0
  22312. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22313. if esep {
  22314. dd.ReadMapElemKey()
  22315. }
  22316. mk = uint16(dd.DecodeUint(16))
  22317. if esep {
  22318. dd.ReadMapElemValue()
  22319. }
  22320. if dd.TryDecodeAsNil() {
  22321. if d.h.DeleteOnNilMapValue {
  22322. delete(v, mk)
  22323. } else {
  22324. v[mk] = 0
  22325. }
  22326. continue
  22327. }
  22328. mv = dd.DecodeUint(64)
  22329. if v != nil {
  22330. v[mk] = mv
  22331. }
  22332. }
  22333. dd.ReadMapEnd()
  22334. return v, changed
  22335. }
  22336. func (d *Decoder) fastpathDecMapUint16UintptrR(f *codecFnInfo, rv reflect.Value) {
  22337. if rv.Kind() == reflect.Ptr {
  22338. vp := rv2i(rv).(*map[uint16]uintptr)
  22339. if v, changed := fastpathTV.DecMapUint16UintptrV(*vp, true, d); changed {
  22340. *vp = v
  22341. }
  22342. return
  22343. }
  22344. fastpathTV.DecMapUint16UintptrV(rv2i(rv).(map[uint16]uintptr), false, d)
  22345. }
  22346. func (f fastpathT) DecMapUint16UintptrX(vp *map[uint16]uintptr, d *Decoder) {
  22347. if v, changed := f.DecMapUint16UintptrV(*vp, true, d); changed {
  22348. *vp = v
  22349. }
  22350. }
  22351. func (_ fastpathT) DecMapUint16UintptrV(v map[uint16]uintptr, canChange bool,
  22352. d *Decoder) (_ map[uint16]uintptr, changed bool) {
  22353. dd, esep := d.d, d.hh.hasElemSeparators()
  22354. containerLen := dd.ReadMapStart()
  22355. if canChange && v == nil {
  22356. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  22357. v = make(map[uint16]uintptr, xlen)
  22358. changed = true
  22359. }
  22360. if containerLen == 0 {
  22361. dd.ReadMapEnd()
  22362. return v, changed
  22363. }
  22364. var mk uint16
  22365. var mv uintptr
  22366. hasLen := containerLen > 0
  22367. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22368. if esep {
  22369. dd.ReadMapElemKey()
  22370. }
  22371. mk = uint16(dd.DecodeUint(16))
  22372. if esep {
  22373. dd.ReadMapElemValue()
  22374. }
  22375. if dd.TryDecodeAsNil() {
  22376. if d.h.DeleteOnNilMapValue {
  22377. delete(v, mk)
  22378. } else {
  22379. v[mk] = 0
  22380. }
  22381. continue
  22382. }
  22383. mv = uintptr(dd.DecodeUint(uintBitsize))
  22384. if v != nil {
  22385. v[mk] = mv
  22386. }
  22387. }
  22388. dd.ReadMapEnd()
  22389. return v, changed
  22390. }
  22391. func (d *Decoder) fastpathDecMapUint16IntR(f *codecFnInfo, rv reflect.Value) {
  22392. if rv.Kind() == reflect.Ptr {
  22393. vp := rv2i(rv).(*map[uint16]int)
  22394. if v, changed := fastpathTV.DecMapUint16IntV(*vp, true, d); changed {
  22395. *vp = v
  22396. }
  22397. return
  22398. }
  22399. fastpathTV.DecMapUint16IntV(rv2i(rv).(map[uint16]int), false, d)
  22400. }
  22401. func (f fastpathT) DecMapUint16IntX(vp *map[uint16]int, d *Decoder) {
  22402. if v, changed := f.DecMapUint16IntV(*vp, true, d); changed {
  22403. *vp = v
  22404. }
  22405. }
  22406. func (_ fastpathT) DecMapUint16IntV(v map[uint16]int, canChange bool,
  22407. d *Decoder) (_ map[uint16]int, changed bool) {
  22408. dd, esep := d.d, d.hh.hasElemSeparators()
  22409. containerLen := dd.ReadMapStart()
  22410. if canChange && v == nil {
  22411. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  22412. v = make(map[uint16]int, xlen)
  22413. changed = true
  22414. }
  22415. if containerLen == 0 {
  22416. dd.ReadMapEnd()
  22417. return v, changed
  22418. }
  22419. var mk uint16
  22420. var mv int
  22421. hasLen := containerLen > 0
  22422. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22423. if esep {
  22424. dd.ReadMapElemKey()
  22425. }
  22426. mk = uint16(dd.DecodeUint(16))
  22427. if esep {
  22428. dd.ReadMapElemValue()
  22429. }
  22430. if dd.TryDecodeAsNil() {
  22431. if d.h.DeleteOnNilMapValue {
  22432. delete(v, mk)
  22433. } else {
  22434. v[mk] = 0
  22435. }
  22436. continue
  22437. }
  22438. mv = int(dd.DecodeInt(intBitsize))
  22439. if v != nil {
  22440. v[mk] = mv
  22441. }
  22442. }
  22443. dd.ReadMapEnd()
  22444. return v, changed
  22445. }
  22446. func (d *Decoder) fastpathDecMapUint16Int8R(f *codecFnInfo, rv reflect.Value) {
  22447. if rv.Kind() == reflect.Ptr {
  22448. vp := rv2i(rv).(*map[uint16]int8)
  22449. if v, changed := fastpathTV.DecMapUint16Int8V(*vp, true, d); changed {
  22450. *vp = v
  22451. }
  22452. return
  22453. }
  22454. fastpathTV.DecMapUint16Int8V(rv2i(rv).(map[uint16]int8), false, d)
  22455. }
  22456. func (f fastpathT) DecMapUint16Int8X(vp *map[uint16]int8, d *Decoder) {
  22457. if v, changed := f.DecMapUint16Int8V(*vp, true, d); changed {
  22458. *vp = v
  22459. }
  22460. }
  22461. func (_ fastpathT) DecMapUint16Int8V(v map[uint16]int8, canChange bool,
  22462. d *Decoder) (_ map[uint16]int8, changed bool) {
  22463. dd, esep := d.d, d.hh.hasElemSeparators()
  22464. containerLen := dd.ReadMapStart()
  22465. if canChange && v == nil {
  22466. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  22467. v = make(map[uint16]int8, xlen)
  22468. changed = true
  22469. }
  22470. if containerLen == 0 {
  22471. dd.ReadMapEnd()
  22472. return v, changed
  22473. }
  22474. var mk uint16
  22475. var mv int8
  22476. hasLen := containerLen > 0
  22477. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22478. if esep {
  22479. dd.ReadMapElemKey()
  22480. }
  22481. mk = uint16(dd.DecodeUint(16))
  22482. if esep {
  22483. dd.ReadMapElemValue()
  22484. }
  22485. if dd.TryDecodeAsNil() {
  22486. if d.h.DeleteOnNilMapValue {
  22487. delete(v, mk)
  22488. } else {
  22489. v[mk] = 0
  22490. }
  22491. continue
  22492. }
  22493. mv = int8(dd.DecodeInt(8))
  22494. if v != nil {
  22495. v[mk] = mv
  22496. }
  22497. }
  22498. dd.ReadMapEnd()
  22499. return v, changed
  22500. }
  22501. func (d *Decoder) fastpathDecMapUint16Int16R(f *codecFnInfo, rv reflect.Value) {
  22502. if rv.Kind() == reflect.Ptr {
  22503. vp := rv2i(rv).(*map[uint16]int16)
  22504. if v, changed := fastpathTV.DecMapUint16Int16V(*vp, true, d); changed {
  22505. *vp = v
  22506. }
  22507. return
  22508. }
  22509. fastpathTV.DecMapUint16Int16V(rv2i(rv).(map[uint16]int16), false, d)
  22510. }
  22511. func (f fastpathT) DecMapUint16Int16X(vp *map[uint16]int16, d *Decoder) {
  22512. if v, changed := f.DecMapUint16Int16V(*vp, true, d); changed {
  22513. *vp = v
  22514. }
  22515. }
  22516. func (_ fastpathT) DecMapUint16Int16V(v map[uint16]int16, canChange bool,
  22517. d *Decoder) (_ map[uint16]int16, changed bool) {
  22518. dd, esep := d.d, d.hh.hasElemSeparators()
  22519. containerLen := dd.ReadMapStart()
  22520. if canChange && v == nil {
  22521. xlen := decInferLen(containerLen, d.h.MaxInitLen, 4)
  22522. v = make(map[uint16]int16, xlen)
  22523. changed = true
  22524. }
  22525. if containerLen == 0 {
  22526. dd.ReadMapEnd()
  22527. return v, changed
  22528. }
  22529. var mk uint16
  22530. var mv int16
  22531. hasLen := containerLen > 0
  22532. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22533. if esep {
  22534. dd.ReadMapElemKey()
  22535. }
  22536. mk = uint16(dd.DecodeUint(16))
  22537. if esep {
  22538. dd.ReadMapElemValue()
  22539. }
  22540. if dd.TryDecodeAsNil() {
  22541. if d.h.DeleteOnNilMapValue {
  22542. delete(v, mk)
  22543. } else {
  22544. v[mk] = 0
  22545. }
  22546. continue
  22547. }
  22548. mv = int16(dd.DecodeInt(16))
  22549. if v != nil {
  22550. v[mk] = mv
  22551. }
  22552. }
  22553. dd.ReadMapEnd()
  22554. return v, changed
  22555. }
  22556. func (d *Decoder) fastpathDecMapUint16Int32R(f *codecFnInfo, rv reflect.Value) {
  22557. if rv.Kind() == reflect.Ptr {
  22558. vp := rv2i(rv).(*map[uint16]int32)
  22559. if v, changed := fastpathTV.DecMapUint16Int32V(*vp, true, d); changed {
  22560. *vp = v
  22561. }
  22562. return
  22563. }
  22564. fastpathTV.DecMapUint16Int32V(rv2i(rv).(map[uint16]int32), false, d)
  22565. }
  22566. func (f fastpathT) DecMapUint16Int32X(vp *map[uint16]int32, d *Decoder) {
  22567. if v, changed := f.DecMapUint16Int32V(*vp, true, d); changed {
  22568. *vp = v
  22569. }
  22570. }
  22571. func (_ fastpathT) DecMapUint16Int32V(v map[uint16]int32, canChange bool,
  22572. d *Decoder) (_ map[uint16]int32, changed bool) {
  22573. dd, esep := d.d, d.hh.hasElemSeparators()
  22574. containerLen := dd.ReadMapStart()
  22575. if canChange && v == nil {
  22576. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  22577. v = make(map[uint16]int32, xlen)
  22578. changed = true
  22579. }
  22580. if containerLen == 0 {
  22581. dd.ReadMapEnd()
  22582. return v, changed
  22583. }
  22584. var mk uint16
  22585. var mv int32
  22586. hasLen := containerLen > 0
  22587. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22588. if esep {
  22589. dd.ReadMapElemKey()
  22590. }
  22591. mk = uint16(dd.DecodeUint(16))
  22592. if esep {
  22593. dd.ReadMapElemValue()
  22594. }
  22595. if dd.TryDecodeAsNil() {
  22596. if d.h.DeleteOnNilMapValue {
  22597. delete(v, mk)
  22598. } else {
  22599. v[mk] = 0
  22600. }
  22601. continue
  22602. }
  22603. mv = int32(dd.DecodeInt(32))
  22604. if v != nil {
  22605. v[mk] = mv
  22606. }
  22607. }
  22608. dd.ReadMapEnd()
  22609. return v, changed
  22610. }
  22611. func (d *Decoder) fastpathDecMapUint16Int64R(f *codecFnInfo, rv reflect.Value) {
  22612. if rv.Kind() == reflect.Ptr {
  22613. vp := rv2i(rv).(*map[uint16]int64)
  22614. if v, changed := fastpathTV.DecMapUint16Int64V(*vp, true, d); changed {
  22615. *vp = v
  22616. }
  22617. return
  22618. }
  22619. fastpathTV.DecMapUint16Int64V(rv2i(rv).(map[uint16]int64), false, d)
  22620. }
  22621. func (f fastpathT) DecMapUint16Int64X(vp *map[uint16]int64, d *Decoder) {
  22622. if v, changed := f.DecMapUint16Int64V(*vp, true, d); changed {
  22623. *vp = v
  22624. }
  22625. }
  22626. func (_ fastpathT) DecMapUint16Int64V(v map[uint16]int64, canChange bool,
  22627. d *Decoder) (_ map[uint16]int64, changed bool) {
  22628. dd, esep := d.d, d.hh.hasElemSeparators()
  22629. containerLen := dd.ReadMapStart()
  22630. if canChange && v == nil {
  22631. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  22632. v = make(map[uint16]int64, xlen)
  22633. changed = true
  22634. }
  22635. if containerLen == 0 {
  22636. dd.ReadMapEnd()
  22637. return v, changed
  22638. }
  22639. var mk uint16
  22640. var mv int64
  22641. hasLen := containerLen > 0
  22642. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22643. if esep {
  22644. dd.ReadMapElemKey()
  22645. }
  22646. mk = uint16(dd.DecodeUint(16))
  22647. if esep {
  22648. dd.ReadMapElemValue()
  22649. }
  22650. if dd.TryDecodeAsNil() {
  22651. if d.h.DeleteOnNilMapValue {
  22652. delete(v, mk)
  22653. } else {
  22654. v[mk] = 0
  22655. }
  22656. continue
  22657. }
  22658. mv = dd.DecodeInt(64)
  22659. if v != nil {
  22660. v[mk] = mv
  22661. }
  22662. }
  22663. dd.ReadMapEnd()
  22664. return v, changed
  22665. }
  22666. func (d *Decoder) fastpathDecMapUint16Float32R(f *codecFnInfo, rv reflect.Value) {
  22667. if rv.Kind() == reflect.Ptr {
  22668. vp := rv2i(rv).(*map[uint16]float32)
  22669. if v, changed := fastpathTV.DecMapUint16Float32V(*vp, true, d); changed {
  22670. *vp = v
  22671. }
  22672. return
  22673. }
  22674. fastpathTV.DecMapUint16Float32V(rv2i(rv).(map[uint16]float32), false, d)
  22675. }
  22676. func (f fastpathT) DecMapUint16Float32X(vp *map[uint16]float32, d *Decoder) {
  22677. if v, changed := f.DecMapUint16Float32V(*vp, true, d); changed {
  22678. *vp = v
  22679. }
  22680. }
  22681. func (_ fastpathT) DecMapUint16Float32V(v map[uint16]float32, canChange bool,
  22682. d *Decoder) (_ map[uint16]float32, changed bool) {
  22683. dd, esep := d.d, d.hh.hasElemSeparators()
  22684. containerLen := dd.ReadMapStart()
  22685. if canChange && v == nil {
  22686. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  22687. v = make(map[uint16]float32, xlen)
  22688. changed = true
  22689. }
  22690. if containerLen == 0 {
  22691. dd.ReadMapEnd()
  22692. return v, changed
  22693. }
  22694. var mk uint16
  22695. var mv float32
  22696. hasLen := containerLen > 0
  22697. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22698. if esep {
  22699. dd.ReadMapElemKey()
  22700. }
  22701. mk = uint16(dd.DecodeUint(16))
  22702. if esep {
  22703. dd.ReadMapElemValue()
  22704. }
  22705. if dd.TryDecodeAsNil() {
  22706. if d.h.DeleteOnNilMapValue {
  22707. delete(v, mk)
  22708. } else {
  22709. v[mk] = 0
  22710. }
  22711. continue
  22712. }
  22713. mv = float32(dd.DecodeFloat(true))
  22714. if v != nil {
  22715. v[mk] = mv
  22716. }
  22717. }
  22718. dd.ReadMapEnd()
  22719. return v, changed
  22720. }
  22721. func (d *Decoder) fastpathDecMapUint16Float64R(f *codecFnInfo, rv reflect.Value) {
  22722. if rv.Kind() == reflect.Ptr {
  22723. vp := rv2i(rv).(*map[uint16]float64)
  22724. if v, changed := fastpathTV.DecMapUint16Float64V(*vp, true, d); changed {
  22725. *vp = v
  22726. }
  22727. return
  22728. }
  22729. fastpathTV.DecMapUint16Float64V(rv2i(rv).(map[uint16]float64), false, d)
  22730. }
  22731. func (f fastpathT) DecMapUint16Float64X(vp *map[uint16]float64, d *Decoder) {
  22732. if v, changed := f.DecMapUint16Float64V(*vp, true, d); changed {
  22733. *vp = v
  22734. }
  22735. }
  22736. func (_ fastpathT) DecMapUint16Float64V(v map[uint16]float64, canChange bool,
  22737. d *Decoder) (_ map[uint16]float64, changed bool) {
  22738. dd, esep := d.d, d.hh.hasElemSeparators()
  22739. containerLen := dd.ReadMapStart()
  22740. if canChange && v == nil {
  22741. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  22742. v = make(map[uint16]float64, xlen)
  22743. changed = true
  22744. }
  22745. if containerLen == 0 {
  22746. dd.ReadMapEnd()
  22747. return v, changed
  22748. }
  22749. var mk uint16
  22750. var mv float64
  22751. hasLen := containerLen > 0
  22752. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22753. if esep {
  22754. dd.ReadMapElemKey()
  22755. }
  22756. mk = uint16(dd.DecodeUint(16))
  22757. if esep {
  22758. dd.ReadMapElemValue()
  22759. }
  22760. if dd.TryDecodeAsNil() {
  22761. if d.h.DeleteOnNilMapValue {
  22762. delete(v, mk)
  22763. } else {
  22764. v[mk] = 0
  22765. }
  22766. continue
  22767. }
  22768. mv = dd.DecodeFloat(false)
  22769. if v != nil {
  22770. v[mk] = mv
  22771. }
  22772. }
  22773. dd.ReadMapEnd()
  22774. return v, changed
  22775. }
  22776. func (d *Decoder) fastpathDecMapUint16BoolR(f *codecFnInfo, rv reflect.Value) {
  22777. if rv.Kind() == reflect.Ptr {
  22778. vp := rv2i(rv).(*map[uint16]bool)
  22779. if v, changed := fastpathTV.DecMapUint16BoolV(*vp, true, d); changed {
  22780. *vp = v
  22781. }
  22782. return
  22783. }
  22784. fastpathTV.DecMapUint16BoolV(rv2i(rv).(map[uint16]bool), false, d)
  22785. }
  22786. func (f fastpathT) DecMapUint16BoolX(vp *map[uint16]bool, d *Decoder) {
  22787. if v, changed := f.DecMapUint16BoolV(*vp, true, d); changed {
  22788. *vp = v
  22789. }
  22790. }
  22791. func (_ fastpathT) DecMapUint16BoolV(v map[uint16]bool, canChange bool,
  22792. d *Decoder) (_ map[uint16]bool, changed bool) {
  22793. dd, esep := d.d, d.hh.hasElemSeparators()
  22794. containerLen := dd.ReadMapStart()
  22795. if canChange && v == nil {
  22796. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  22797. v = make(map[uint16]bool, xlen)
  22798. changed = true
  22799. }
  22800. if containerLen == 0 {
  22801. dd.ReadMapEnd()
  22802. return v, changed
  22803. }
  22804. var mk uint16
  22805. var mv bool
  22806. hasLen := containerLen > 0
  22807. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22808. if esep {
  22809. dd.ReadMapElemKey()
  22810. }
  22811. mk = uint16(dd.DecodeUint(16))
  22812. if esep {
  22813. dd.ReadMapElemValue()
  22814. }
  22815. if dd.TryDecodeAsNil() {
  22816. if d.h.DeleteOnNilMapValue {
  22817. delete(v, mk)
  22818. } else {
  22819. v[mk] = false
  22820. }
  22821. continue
  22822. }
  22823. mv = dd.DecodeBool()
  22824. if v != nil {
  22825. v[mk] = mv
  22826. }
  22827. }
  22828. dd.ReadMapEnd()
  22829. return v, changed
  22830. }
  22831. func (d *Decoder) fastpathDecMapUint32IntfR(f *codecFnInfo, rv reflect.Value) {
  22832. if rv.Kind() == reflect.Ptr {
  22833. vp := rv2i(rv).(*map[uint32]interface{})
  22834. if v, changed := fastpathTV.DecMapUint32IntfV(*vp, true, d); changed {
  22835. *vp = v
  22836. }
  22837. return
  22838. }
  22839. fastpathTV.DecMapUint32IntfV(rv2i(rv).(map[uint32]interface{}), false, d)
  22840. }
  22841. func (f fastpathT) DecMapUint32IntfX(vp *map[uint32]interface{}, d *Decoder) {
  22842. if v, changed := f.DecMapUint32IntfV(*vp, true, d); changed {
  22843. *vp = v
  22844. }
  22845. }
  22846. func (_ fastpathT) DecMapUint32IntfV(v map[uint32]interface{}, canChange bool,
  22847. d *Decoder) (_ map[uint32]interface{}, changed bool) {
  22848. dd, esep := d.d, d.hh.hasElemSeparators()
  22849. containerLen := dd.ReadMapStart()
  22850. if canChange && v == nil {
  22851. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  22852. v = make(map[uint32]interface{}, xlen)
  22853. changed = true
  22854. }
  22855. if containerLen == 0 {
  22856. dd.ReadMapEnd()
  22857. return v, changed
  22858. }
  22859. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  22860. var mk uint32
  22861. var mv interface{}
  22862. hasLen := containerLen > 0
  22863. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22864. if esep {
  22865. dd.ReadMapElemKey()
  22866. }
  22867. mk = uint32(dd.DecodeUint(32))
  22868. if esep {
  22869. dd.ReadMapElemValue()
  22870. }
  22871. if dd.TryDecodeAsNil() {
  22872. if d.h.DeleteOnNilMapValue {
  22873. delete(v, mk)
  22874. } else {
  22875. v[mk] = nil
  22876. }
  22877. continue
  22878. }
  22879. if mapGet {
  22880. mv = v[mk]
  22881. } else {
  22882. mv = nil
  22883. }
  22884. d.decode(&mv)
  22885. if v != nil {
  22886. v[mk] = mv
  22887. }
  22888. }
  22889. dd.ReadMapEnd()
  22890. return v, changed
  22891. }
  22892. func (d *Decoder) fastpathDecMapUint32StringR(f *codecFnInfo, rv reflect.Value) {
  22893. if rv.Kind() == reflect.Ptr {
  22894. vp := rv2i(rv).(*map[uint32]string)
  22895. if v, changed := fastpathTV.DecMapUint32StringV(*vp, true, d); changed {
  22896. *vp = v
  22897. }
  22898. return
  22899. }
  22900. fastpathTV.DecMapUint32StringV(rv2i(rv).(map[uint32]string), false, d)
  22901. }
  22902. func (f fastpathT) DecMapUint32StringX(vp *map[uint32]string, d *Decoder) {
  22903. if v, changed := f.DecMapUint32StringV(*vp, true, d); changed {
  22904. *vp = v
  22905. }
  22906. }
  22907. func (_ fastpathT) DecMapUint32StringV(v map[uint32]string, canChange bool,
  22908. d *Decoder) (_ map[uint32]string, changed bool) {
  22909. dd, esep := d.d, d.hh.hasElemSeparators()
  22910. containerLen := dd.ReadMapStart()
  22911. if canChange && v == nil {
  22912. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  22913. v = make(map[uint32]string, xlen)
  22914. changed = true
  22915. }
  22916. if containerLen == 0 {
  22917. dd.ReadMapEnd()
  22918. return v, changed
  22919. }
  22920. var mk uint32
  22921. var mv string
  22922. hasLen := containerLen > 0
  22923. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22924. if esep {
  22925. dd.ReadMapElemKey()
  22926. }
  22927. mk = uint32(dd.DecodeUint(32))
  22928. if esep {
  22929. dd.ReadMapElemValue()
  22930. }
  22931. if dd.TryDecodeAsNil() {
  22932. if d.h.DeleteOnNilMapValue {
  22933. delete(v, mk)
  22934. } else {
  22935. v[mk] = ""
  22936. }
  22937. continue
  22938. }
  22939. mv = dd.DecodeString()
  22940. if v != nil {
  22941. v[mk] = mv
  22942. }
  22943. }
  22944. dd.ReadMapEnd()
  22945. return v, changed
  22946. }
  22947. func (d *Decoder) fastpathDecMapUint32UintR(f *codecFnInfo, rv reflect.Value) {
  22948. if rv.Kind() == reflect.Ptr {
  22949. vp := rv2i(rv).(*map[uint32]uint)
  22950. if v, changed := fastpathTV.DecMapUint32UintV(*vp, true, d); changed {
  22951. *vp = v
  22952. }
  22953. return
  22954. }
  22955. fastpathTV.DecMapUint32UintV(rv2i(rv).(map[uint32]uint), false, d)
  22956. }
  22957. func (f fastpathT) DecMapUint32UintX(vp *map[uint32]uint, d *Decoder) {
  22958. if v, changed := f.DecMapUint32UintV(*vp, true, d); changed {
  22959. *vp = v
  22960. }
  22961. }
  22962. func (_ fastpathT) DecMapUint32UintV(v map[uint32]uint, canChange bool,
  22963. d *Decoder) (_ map[uint32]uint, changed bool) {
  22964. dd, esep := d.d, d.hh.hasElemSeparators()
  22965. containerLen := dd.ReadMapStart()
  22966. if canChange && v == nil {
  22967. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  22968. v = make(map[uint32]uint, xlen)
  22969. changed = true
  22970. }
  22971. if containerLen == 0 {
  22972. dd.ReadMapEnd()
  22973. return v, changed
  22974. }
  22975. var mk uint32
  22976. var mv uint
  22977. hasLen := containerLen > 0
  22978. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  22979. if esep {
  22980. dd.ReadMapElemKey()
  22981. }
  22982. mk = uint32(dd.DecodeUint(32))
  22983. if esep {
  22984. dd.ReadMapElemValue()
  22985. }
  22986. if dd.TryDecodeAsNil() {
  22987. if d.h.DeleteOnNilMapValue {
  22988. delete(v, mk)
  22989. } else {
  22990. v[mk] = 0
  22991. }
  22992. continue
  22993. }
  22994. mv = uint(dd.DecodeUint(uintBitsize))
  22995. if v != nil {
  22996. v[mk] = mv
  22997. }
  22998. }
  22999. dd.ReadMapEnd()
  23000. return v, changed
  23001. }
  23002. func (d *Decoder) fastpathDecMapUint32Uint8R(f *codecFnInfo, rv reflect.Value) {
  23003. if rv.Kind() == reflect.Ptr {
  23004. vp := rv2i(rv).(*map[uint32]uint8)
  23005. if v, changed := fastpathTV.DecMapUint32Uint8V(*vp, true, d); changed {
  23006. *vp = v
  23007. }
  23008. return
  23009. }
  23010. fastpathTV.DecMapUint32Uint8V(rv2i(rv).(map[uint32]uint8), false, d)
  23011. }
  23012. func (f fastpathT) DecMapUint32Uint8X(vp *map[uint32]uint8, d *Decoder) {
  23013. if v, changed := f.DecMapUint32Uint8V(*vp, true, d); changed {
  23014. *vp = v
  23015. }
  23016. }
  23017. func (_ fastpathT) DecMapUint32Uint8V(v map[uint32]uint8, canChange bool,
  23018. d *Decoder) (_ map[uint32]uint8, changed bool) {
  23019. dd, esep := d.d, d.hh.hasElemSeparators()
  23020. containerLen := dd.ReadMapStart()
  23021. if canChange && v == nil {
  23022. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  23023. v = make(map[uint32]uint8, xlen)
  23024. changed = true
  23025. }
  23026. if containerLen == 0 {
  23027. dd.ReadMapEnd()
  23028. return v, changed
  23029. }
  23030. var mk uint32
  23031. var mv uint8
  23032. hasLen := containerLen > 0
  23033. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23034. if esep {
  23035. dd.ReadMapElemKey()
  23036. }
  23037. mk = uint32(dd.DecodeUint(32))
  23038. if esep {
  23039. dd.ReadMapElemValue()
  23040. }
  23041. if dd.TryDecodeAsNil() {
  23042. if d.h.DeleteOnNilMapValue {
  23043. delete(v, mk)
  23044. } else {
  23045. v[mk] = 0
  23046. }
  23047. continue
  23048. }
  23049. mv = uint8(dd.DecodeUint(8))
  23050. if v != nil {
  23051. v[mk] = mv
  23052. }
  23053. }
  23054. dd.ReadMapEnd()
  23055. return v, changed
  23056. }
  23057. func (d *Decoder) fastpathDecMapUint32Uint16R(f *codecFnInfo, rv reflect.Value) {
  23058. if rv.Kind() == reflect.Ptr {
  23059. vp := rv2i(rv).(*map[uint32]uint16)
  23060. if v, changed := fastpathTV.DecMapUint32Uint16V(*vp, true, d); changed {
  23061. *vp = v
  23062. }
  23063. return
  23064. }
  23065. fastpathTV.DecMapUint32Uint16V(rv2i(rv).(map[uint32]uint16), false, d)
  23066. }
  23067. func (f fastpathT) DecMapUint32Uint16X(vp *map[uint32]uint16, d *Decoder) {
  23068. if v, changed := f.DecMapUint32Uint16V(*vp, true, d); changed {
  23069. *vp = v
  23070. }
  23071. }
  23072. func (_ fastpathT) DecMapUint32Uint16V(v map[uint32]uint16, canChange bool,
  23073. d *Decoder) (_ map[uint32]uint16, changed bool) {
  23074. dd, esep := d.d, d.hh.hasElemSeparators()
  23075. containerLen := dd.ReadMapStart()
  23076. if canChange && v == nil {
  23077. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  23078. v = make(map[uint32]uint16, xlen)
  23079. changed = true
  23080. }
  23081. if containerLen == 0 {
  23082. dd.ReadMapEnd()
  23083. return v, changed
  23084. }
  23085. var mk uint32
  23086. var mv uint16
  23087. hasLen := containerLen > 0
  23088. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23089. if esep {
  23090. dd.ReadMapElemKey()
  23091. }
  23092. mk = uint32(dd.DecodeUint(32))
  23093. if esep {
  23094. dd.ReadMapElemValue()
  23095. }
  23096. if dd.TryDecodeAsNil() {
  23097. if d.h.DeleteOnNilMapValue {
  23098. delete(v, mk)
  23099. } else {
  23100. v[mk] = 0
  23101. }
  23102. continue
  23103. }
  23104. mv = uint16(dd.DecodeUint(16))
  23105. if v != nil {
  23106. v[mk] = mv
  23107. }
  23108. }
  23109. dd.ReadMapEnd()
  23110. return v, changed
  23111. }
  23112. func (d *Decoder) fastpathDecMapUint32Uint32R(f *codecFnInfo, rv reflect.Value) {
  23113. if rv.Kind() == reflect.Ptr {
  23114. vp := rv2i(rv).(*map[uint32]uint32)
  23115. if v, changed := fastpathTV.DecMapUint32Uint32V(*vp, true, d); changed {
  23116. *vp = v
  23117. }
  23118. return
  23119. }
  23120. fastpathTV.DecMapUint32Uint32V(rv2i(rv).(map[uint32]uint32), false, d)
  23121. }
  23122. func (f fastpathT) DecMapUint32Uint32X(vp *map[uint32]uint32, d *Decoder) {
  23123. if v, changed := f.DecMapUint32Uint32V(*vp, true, d); changed {
  23124. *vp = v
  23125. }
  23126. }
  23127. func (_ fastpathT) DecMapUint32Uint32V(v map[uint32]uint32, canChange bool,
  23128. d *Decoder) (_ map[uint32]uint32, changed bool) {
  23129. dd, esep := d.d, d.hh.hasElemSeparators()
  23130. containerLen := dd.ReadMapStart()
  23131. if canChange && v == nil {
  23132. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  23133. v = make(map[uint32]uint32, xlen)
  23134. changed = true
  23135. }
  23136. if containerLen == 0 {
  23137. dd.ReadMapEnd()
  23138. return v, changed
  23139. }
  23140. var mk uint32
  23141. var mv uint32
  23142. hasLen := containerLen > 0
  23143. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23144. if esep {
  23145. dd.ReadMapElemKey()
  23146. }
  23147. mk = uint32(dd.DecodeUint(32))
  23148. if esep {
  23149. dd.ReadMapElemValue()
  23150. }
  23151. if dd.TryDecodeAsNil() {
  23152. if d.h.DeleteOnNilMapValue {
  23153. delete(v, mk)
  23154. } else {
  23155. v[mk] = 0
  23156. }
  23157. continue
  23158. }
  23159. mv = uint32(dd.DecodeUint(32))
  23160. if v != nil {
  23161. v[mk] = mv
  23162. }
  23163. }
  23164. dd.ReadMapEnd()
  23165. return v, changed
  23166. }
  23167. func (d *Decoder) fastpathDecMapUint32Uint64R(f *codecFnInfo, rv reflect.Value) {
  23168. if rv.Kind() == reflect.Ptr {
  23169. vp := rv2i(rv).(*map[uint32]uint64)
  23170. if v, changed := fastpathTV.DecMapUint32Uint64V(*vp, true, d); changed {
  23171. *vp = v
  23172. }
  23173. return
  23174. }
  23175. fastpathTV.DecMapUint32Uint64V(rv2i(rv).(map[uint32]uint64), false, d)
  23176. }
  23177. func (f fastpathT) DecMapUint32Uint64X(vp *map[uint32]uint64, d *Decoder) {
  23178. if v, changed := f.DecMapUint32Uint64V(*vp, true, d); changed {
  23179. *vp = v
  23180. }
  23181. }
  23182. func (_ fastpathT) DecMapUint32Uint64V(v map[uint32]uint64, canChange bool,
  23183. d *Decoder) (_ map[uint32]uint64, changed bool) {
  23184. dd, esep := d.d, d.hh.hasElemSeparators()
  23185. containerLen := dd.ReadMapStart()
  23186. if canChange && v == nil {
  23187. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  23188. v = make(map[uint32]uint64, xlen)
  23189. changed = true
  23190. }
  23191. if containerLen == 0 {
  23192. dd.ReadMapEnd()
  23193. return v, changed
  23194. }
  23195. var mk uint32
  23196. var mv uint64
  23197. hasLen := containerLen > 0
  23198. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23199. if esep {
  23200. dd.ReadMapElemKey()
  23201. }
  23202. mk = uint32(dd.DecodeUint(32))
  23203. if esep {
  23204. dd.ReadMapElemValue()
  23205. }
  23206. if dd.TryDecodeAsNil() {
  23207. if d.h.DeleteOnNilMapValue {
  23208. delete(v, mk)
  23209. } else {
  23210. v[mk] = 0
  23211. }
  23212. continue
  23213. }
  23214. mv = dd.DecodeUint(64)
  23215. if v != nil {
  23216. v[mk] = mv
  23217. }
  23218. }
  23219. dd.ReadMapEnd()
  23220. return v, changed
  23221. }
  23222. func (d *Decoder) fastpathDecMapUint32UintptrR(f *codecFnInfo, rv reflect.Value) {
  23223. if rv.Kind() == reflect.Ptr {
  23224. vp := rv2i(rv).(*map[uint32]uintptr)
  23225. if v, changed := fastpathTV.DecMapUint32UintptrV(*vp, true, d); changed {
  23226. *vp = v
  23227. }
  23228. return
  23229. }
  23230. fastpathTV.DecMapUint32UintptrV(rv2i(rv).(map[uint32]uintptr), false, d)
  23231. }
  23232. func (f fastpathT) DecMapUint32UintptrX(vp *map[uint32]uintptr, d *Decoder) {
  23233. if v, changed := f.DecMapUint32UintptrV(*vp, true, d); changed {
  23234. *vp = v
  23235. }
  23236. }
  23237. func (_ fastpathT) DecMapUint32UintptrV(v map[uint32]uintptr, canChange bool,
  23238. d *Decoder) (_ map[uint32]uintptr, changed bool) {
  23239. dd, esep := d.d, d.hh.hasElemSeparators()
  23240. containerLen := dd.ReadMapStart()
  23241. if canChange && v == nil {
  23242. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  23243. v = make(map[uint32]uintptr, xlen)
  23244. changed = true
  23245. }
  23246. if containerLen == 0 {
  23247. dd.ReadMapEnd()
  23248. return v, changed
  23249. }
  23250. var mk uint32
  23251. var mv uintptr
  23252. hasLen := containerLen > 0
  23253. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23254. if esep {
  23255. dd.ReadMapElemKey()
  23256. }
  23257. mk = uint32(dd.DecodeUint(32))
  23258. if esep {
  23259. dd.ReadMapElemValue()
  23260. }
  23261. if dd.TryDecodeAsNil() {
  23262. if d.h.DeleteOnNilMapValue {
  23263. delete(v, mk)
  23264. } else {
  23265. v[mk] = 0
  23266. }
  23267. continue
  23268. }
  23269. mv = uintptr(dd.DecodeUint(uintBitsize))
  23270. if v != nil {
  23271. v[mk] = mv
  23272. }
  23273. }
  23274. dd.ReadMapEnd()
  23275. return v, changed
  23276. }
  23277. func (d *Decoder) fastpathDecMapUint32IntR(f *codecFnInfo, rv reflect.Value) {
  23278. if rv.Kind() == reflect.Ptr {
  23279. vp := rv2i(rv).(*map[uint32]int)
  23280. if v, changed := fastpathTV.DecMapUint32IntV(*vp, true, d); changed {
  23281. *vp = v
  23282. }
  23283. return
  23284. }
  23285. fastpathTV.DecMapUint32IntV(rv2i(rv).(map[uint32]int), false, d)
  23286. }
  23287. func (f fastpathT) DecMapUint32IntX(vp *map[uint32]int, d *Decoder) {
  23288. if v, changed := f.DecMapUint32IntV(*vp, true, d); changed {
  23289. *vp = v
  23290. }
  23291. }
  23292. func (_ fastpathT) DecMapUint32IntV(v map[uint32]int, canChange bool,
  23293. d *Decoder) (_ map[uint32]int, changed bool) {
  23294. dd, esep := d.d, d.hh.hasElemSeparators()
  23295. containerLen := dd.ReadMapStart()
  23296. if canChange && v == nil {
  23297. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  23298. v = make(map[uint32]int, xlen)
  23299. changed = true
  23300. }
  23301. if containerLen == 0 {
  23302. dd.ReadMapEnd()
  23303. return v, changed
  23304. }
  23305. var mk uint32
  23306. var mv int
  23307. hasLen := containerLen > 0
  23308. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23309. if esep {
  23310. dd.ReadMapElemKey()
  23311. }
  23312. mk = uint32(dd.DecodeUint(32))
  23313. if esep {
  23314. dd.ReadMapElemValue()
  23315. }
  23316. if dd.TryDecodeAsNil() {
  23317. if d.h.DeleteOnNilMapValue {
  23318. delete(v, mk)
  23319. } else {
  23320. v[mk] = 0
  23321. }
  23322. continue
  23323. }
  23324. mv = int(dd.DecodeInt(intBitsize))
  23325. if v != nil {
  23326. v[mk] = mv
  23327. }
  23328. }
  23329. dd.ReadMapEnd()
  23330. return v, changed
  23331. }
  23332. func (d *Decoder) fastpathDecMapUint32Int8R(f *codecFnInfo, rv reflect.Value) {
  23333. if rv.Kind() == reflect.Ptr {
  23334. vp := rv2i(rv).(*map[uint32]int8)
  23335. if v, changed := fastpathTV.DecMapUint32Int8V(*vp, true, d); changed {
  23336. *vp = v
  23337. }
  23338. return
  23339. }
  23340. fastpathTV.DecMapUint32Int8V(rv2i(rv).(map[uint32]int8), false, d)
  23341. }
  23342. func (f fastpathT) DecMapUint32Int8X(vp *map[uint32]int8, d *Decoder) {
  23343. if v, changed := f.DecMapUint32Int8V(*vp, true, d); changed {
  23344. *vp = v
  23345. }
  23346. }
  23347. func (_ fastpathT) DecMapUint32Int8V(v map[uint32]int8, canChange bool,
  23348. d *Decoder) (_ map[uint32]int8, changed bool) {
  23349. dd, esep := d.d, d.hh.hasElemSeparators()
  23350. containerLen := dd.ReadMapStart()
  23351. if canChange && v == nil {
  23352. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  23353. v = make(map[uint32]int8, xlen)
  23354. changed = true
  23355. }
  23356. if containerLen == 0 {
  23357. dd.ReadMapEnd()
  23358. return v, changed
  23359. }
  23360. var mk uint32
  23361. var mv int8
  23362. hasLen := containerLen > 0
  23363. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23364. if esep {
  23365. dd.ReadMapElemKey()
  23366. }
  23367. mk = uint32(dd.DecodeUint(32))
  23368. if esep {
  23369. dd.ReadMapElemValue()
  23370. }
  23371. if dd.TryDecodeAsNil() {
  23372. if d.h.DeleteOnNilMapValue {
  23373. delete(v, mk)
  23374. } else {
  23375. v[mk] = 0
  23376. }
  23377. continue
  23378. }
  23379. mv = int8(dd.DecodeInt(8))
  23380. if v != nil {
  23381. v[mk] = mv
  23382. }
  23383. }
  23384. dd.ReadMapEnd()
  23385. return v, changed
  23386. }
  23387. func (d *Decoder) fastpathDecMapUint32Int16R(f *codecFnInfo, rv reflect.Value) {
  23388. if rv.Kind() == reflect.Ptr {
  23389. vp := rv2i(rv).(*map[uint32]int16)
  23390. if v, changed := fastpathTV.DecMapUint32Int16V(*vp, true, d); changed {
  23391. *vp = v
  23392. }
  23393. return
  23394. }
  23395. fastpathTV.DecMapUint32Int16V(rv2i(rv).(map[uint32]int16), false, d)
  23396. }
  23397. func (f fastpathT) DecMapUint32Int16X(vp *map[uint32]int16, d *Decoder) {
  23398. if v, changed := f.DecMapUint32Int16V(*vp, true, d); changed {
  23399. *vp = v
  23400. }
  23401. }
  23402. func (_ fastpathT) DecMapUint32Int16V(v map[uint32]int16, canChange bool,
  23403. d *Decoder) (_ map[uint32]int16, changed bool) {
  23404. dd, esep := d.d, d.hh.hasElemSeparators()
  23405. containerLen := dd.ReadMapStart()
  23406. if canChange && v == nil {
  23407. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  23408. v = make(map[uint32]int16, xlen)
  23409. changed = true
  23410. }
  23411. if containerLen == 0 {
  23412. dd.ReadMapEnd()
  23413. return v, changed
  23414. }
  23415. var mk uint32
  23416. var mv int16
  23417. hasLen := containerLen > 0
  23418. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23419. if esep {
  23420. dd.ReadMapElemKey()
  23421. }
  23422. mk = uint32(dd.DecodeUint(32))
  23423. if esep {
  23424. dd.ReadMapElemValue()
  23425. }
  23426. if dd.TryDecodeAsNil() {
  23427. if d.h.DeleteOnNilMapValue {
  23428. delete(v, mk)
  23429. } else {
  23430. v[mk] = 0
  23431. }
  23432. continue
  23433. }
  23434. mv = int16(dd.DecodeInt(16))
  23435. if v != nil {
  23436. v[mk] = mv
  23437. }
  23438. }
  23439. dd.ReadMapEnd()
  23440. return v, changed
  23441. }
  23442. func (d *Decoder) fastpathDecMapUint32Int32R(f *codecFnInfo, rv reflect.Value) {
  23443. if rv.Kind() == reflect.Ptr {
  23444. vp := rv2i(rv).(*map[uint32]int32)
  23445. if v, changed := fastpathTV.DecMapUint32Int32V(*vp, true, d); changed {
  23446. *vp = v
  23447. }
  23448. return
  23449. }
  23450. fastpathTV.DecMapUint32Int32V(rv2i(rv).(map[uint32]int32), false, d)
  23451. }
  23452. func (f fastpathT) DecMapUint32Int32X(vp *map[uint32]int32, d *Decoder) {
  23453. if v, changed := f.DecMapUint32Int32V(*vp, true, d); changed {
  23454. *vp = v
  23455. }
  23456. }
  23457. func (_ fastpathT) DecMapUint32Int32V(v map[uint32]int32, canChange bool,
  23458. d *Decoder) (_ map[uint32]int32, changed bool) {
  23459. dd, esep := d.d, d.hh.hasElemSeparators()
  23460. containerLen := dd.ReadMapStart()
  23461. if canChange && v == nil {
  23462. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  23463. v = make(map[uint32]int32, xlen)
  23464. changed = true
  23465. }
  23466. if containerLen == 0 {
  23467. dd.ReadMapEnd()
  23468. return v, changed
  23469. }
  23470. var mk uint32
  23471. var mv int32
  23472. hasLen := containerLen > 0
  23473. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23474. if esep {
  23475. dd.ReadMapElemKey()
  23476. }
  23477. mk = uint32(dd.DecodeUint(32))
  23478. if esep {
  23479. dd.ReadMapElemValue()
  23480. }
  23481. if dd.TryDecodeAsNil() {
  23482. if d.h.DeleteOnNilMapValue {
  23483. delete(v, mk)
  23484. } else {
  23485. v[mk] = 0
  23486. }
  23487. continue
  23488. }
  23489. mv = int32(dd.DecodeInt(32))
  23490. if v != nil {
  23491. v[mk] = mv
  23492. }
  23493. }
  23494. dd.ReadMapEnd()
  23495. return v, changed
  23496. }
  23497. func (d *Decoder) fastpathDecMapUint32Int64R(f *codecFnInfo, rv reflect.Value) {
  23498. if rv.Kind() == reflect.Ptr {
  23499. vp := rv2i(rv).(*map[uint32]int64)
  23500. if v, changed := fastpathTV.DecMapUint32Int64V(*vp, true, d); changed {
  23501. *vp = v
  23502. }
  23503. return
  23504. }
  23505. fastpathTV.DecMapUint32Int64V(rv2i(rv).(map[uint32]int64), false, d)
  23506. }
  23507. func (f fastpathT) DecMapUint32Int64X(vp *map[uint32]int64, d *Decoder) {
  23508. if v, changed := f.DecMapUint32Int64V(*vp, true, d); changed {
  23509. *vp = v
  23510. }
  23511. }
  23512. func (_ fastpathT) DecMapUint32Int64V(v map[uint32]int64, canChange bool,
  23513. d *Decoder) (_ map[uint32]int64, changed bool) {
  23514. dd, esep := d.d, d.hh.hasElemSeparators()
  23515. containerLen := dd.ReadMapStart()
  23516. if canChange && v == nil {
  23517. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  23518. v = make(map[uint32]int64, xlen)
  23519. changed = true
  23520. }
  23521. if containerLen == 0 {
  23522. dd.ReadMapEnd()
  23523. return v, changed
  23524. }
  23525. var mk uint32
  23526. var mv int64
  23527. hasLen := containerLen > 0
  23528. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23529. if esep {
  23530. dd.ReadMapElemKey()
  23531. }
  23532. mk = uint32(dd.DecodeUint(32))
  23533. if esep {
  23534. dd.ReadMapElemValue()
  23535. }
  23536. if dd.TryDecodeAsNil() {
  23537. if d.h.DeleteOnNilMapValue {
  23538. delete(v, mk)
  23539. } else {
  23540. v[mk] = 0
  23541. }
  23542. continue
  23543. }
  23544. mv = dd.DecodeInt(64)
  23545. if v != nil {
  23546. v[mk] = mv
  23547. }
  23548. }
  23549. dd.ReadMapEnd()
  23550. return v, changed
  23551. }
  23552. func (d *Decoder) fastpathDecMapUint32Float32R(f *codecFnInfo, rv reflect.Value) {
  23553. if rv.Kind() == reflect.Ptr {
  23554. vp := rv2i(rv).(*map[uint32]float32)
  23555. if v, changed := fastpathTV.DecMapUint32Float32V(*vp, true, d); changed {
  23556. *vp = v
  23557. }
  23558. return
  23559. }
  23560. fastpathTV.DecMapUint32Float32V(rv2i(rv).(map[uint32]float32), false, d)
  23561. }
  23562. func (f fastpathT) DecMapUint32Float32X(vp *map[uint32]float32, d *Decoder) {
  23563. if v, changed := f.DecMapUint32Float32V(*vp, true, d); changed {
  23564. *vp = v
  23565. }
  23566. }
  23567. func (_ fastpathT) DecMapUint32Float32V(v map[uint32]float32, canChange bool,
  23568. d *Decoder) (_ map[uint32]float32, changed bool) {
  23569. dd, esep := d.d, d.hh.hasElemSeparators()
  23570. containerLen := dd.ReadMapStart()
  23571. if canChange && v == nil {
  23572. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  23573. v = make(map[uint32]float32, xlen)
  23574. changed = true
  23575. }
  23576. if containerLen == 0 {
  23577. dd.ReadMapEnd()
  23578. return v, changed
  23579. }
  23580. var mk uint32
  23581. var mv float32
  23582. hasLen := containerLen > 0
  23583. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23584. if esep {
  23585. dd.ReadMapElemKey()
  23586. }
  23587. mk = uint32(dd.DecodeUint(32))
  23588. if esep {
  23589. dd.ReadMapElemValue()
  23590. }
  23591. if dd.TryDecodeAsNil() {
  23592. if d.h.DeleteOnNilMapValue {
  23593. delete(v, mk)
  23594. } else {
  23595. v[mk] = 0
  23596. }
  23597. continue
  23598. }
  23599. mv = float32(dd.DecodeFloat(true))
  23600. if v != nil {
  23601. v[mk] = mv
  23602. }
  23603. }
  23604. dd.ReadMapEnd()
  23605. return v, changed
  23606. }
  23607. func (d *Decoder) fastpathDecMapUint32Float64R(f *codecFnInfo, rv reflect.Value) {
  23608. if rv.Kind() == reflect.Ptr {
  23609. vp := rv2i(rv).(*map[uint32]float64)
  23610. if v, changed := fastpathTV.DecMapUint32Float64V(*vp, true, d); changed {
  23611. *vp = v
  23612. }
  23613. return
  23614. }
  23615. fastpathTV.DecMapUint32Float64V(rv2i(rv).(map[uint32]float64), false, d)
  23616. }
  23617. func (f fastpathT) DecMapUint32Float64X(vp *map[uint32]float64, d *Decoder) {
  23618. if v, changed := f.DecMapUint32Float64V(*vp, true, d); changed {
  23619. *vp = v
  23620. }
  23621. }
  23622. func (_ fastpathT) DecMapUint32Float64V(v map[uint32]float64, canChange bool,
  23623. d *Decoder) (_ map[uint32]float64, changed bool) {
  23624. dd, esep := d.d, d.hh.hasElemSeparators()
  23625. containerLen := dd.ReadMapStart()
  23626. if canChange && v == nil {
  23627. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  23628. v = make(map[uint32]float64, xlen)
  23629. changed = true
  23630. }
  23631. if containerLen == 0 {
  23632. dd.ReadMapEnd()
  23633. return v, changed
  23634. }
  23635. var mk uint32
  23636. var mv float64
  23637. hasLen := containerLen > 0
  23638. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23639. if esep {
  23640. dd.ReadMapElemKey()
  23641. }
  23642. mk = uint32(dd.DecodeUint(32))
  23643. if esep {
  23644. dd.ReadMapElemValue()
  23645. }
  23646. if dd.TryDecodeAsNil() {
  23647. if d.h.DeleteOnNilMapValue {
  23648. delete(v, mk)
  23649. } else {
  23650. v[mk] = 0
  23651. }
  23652. continue
  23653. }
  23654. mv = dd.DecodeFloat(false)
  23655. if v != nil {
  23656. v[mk] = mv
  23657. }
  23658. }
  23659. dd.ReadMapEnd()
  23660. return v, changed
  23661. }
  23662. func (d *Decoder) fastpathDecMapUint32BoolR(f *codecFnInfo, rv reflect.Value) {
  23663. if rv.Kind() == reflect.Ptr {
  23664. vp := rv2i(rv).(*map[uint32]bool)
  23665. if v, changed := fastpathTV.DecMapUint32BoolV(*vp, true, d); changed {
  23666. *vp = v
  23667. }
  23668. return
  23669. }
  23670. fastpathTV.DecMapUint32BoolV(rv2i(rv).(map[uint32]bool), false, d)
  23671. }
  23672. func (f fastpathT) DecMapUint32BoolX(vp *map[uint32]bool, d *Decoder) {
  23673. if v, changed := f.DecMapUint32BoolV(*vp, true, d); changed {
  23674. *vp = v
  23675. }
  23676. }
  23677. func (_ fastpathT) DecMapUint32BoolV(v map[uint32]bool, canChange bool,
  23678. d *Decoder) (_ map[uint32]bool, changed bool) {
  23679. dd, esep := d.d, d.hh.hasElemSeparators()
  23680. containerLen := dd.ReadMapStart()
  23681. if canChange && v == nil {
  23682. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  23683. v = make(map[uint32]bool, xlen)
  23684. changed = true
  23685. }
  23686. if containerLen == 0 {
  23687. dd.ReadMapEnd()
  23688. return v, changed
  23689. }
  23690. var mk uint32
  23691. var mv bool
  23692. hasLen := containerLen > 0
  23693. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23694. if esep {
  23695. dd.ReadMapElemKey()
  23696. }
  23697. mk = uint32(dd.DecodeUint(32))
  23698. if esep {
  23699. dd.ReadMapElemValue()
  23700. }
  23701. if dd.TryDecodeAsNil() {
  23702. if d.h.DeleteOnNilMapValue {
  23703. delete(v, mk)
  23704. } else {
  23705. v[mk] = false
  23706. }
  23707. continue
  23708. }
  23709. mv = dd.DecodeBool()
  23710. if v != nil {
  23711. v[mk] = mv
  23712. }
  23713. }
  23714. dd.ReadMapEnd()
  23715. return v, changed
  23716. }
  23717. func (d *Decoder) fastpathDecMapUint64IntfR(f *codecFnInfo, rv reflect.Value) {
  23718. if rv.Kind() == reflect.Ptr {
  23719. vp := rv2i(rv).(*map[uint64]interface{})
  23720. if v, changed := fastpathTV.DecMapUint64IntfV(*vp, true, d); changed {
  23721. *vp = v
  23722. }
  23723. return
  23724. }
  23725. fastpathTV.DecMapUint64IntfV(rv2i(rv).(map[uint64]interface{}), false, d)
  23726. }
  23727. func (f fastpathT) DecMapUint64IntfX(vp *map[uint64]interface{}, d *Decoder) {
  23728. if v, changed := f.DecMapUint64IntfV(*vp, true, d); changed {
  23729. *vp = v
  23730. }
  23731. }
  23732. func (_ fastpathT) DecMapUint64IntfV(v map[uint64]interface{}, canChange bool,
  23733. d *Decoder) (_ map[uint64]interface{}, changed bool) {
  23734. dd, esep := d.d, d.hh.hasElemSeparators()
  23735. containerLen := dd.ReadMapStart()
  23736. if canChange && v == nil {
  23737. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  23738. v = make(map[uint64]interface{}, xlen)
  23739. changed = true
  23740. }
  23741. if containerLen == 0 {
  23742. dd.ReadMapEnd()
  23743. return v, changed
  23744. }
  23745. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  23746. var mk uint64
  23747. var mv interface{}
  23748. hasLen := containerLen > 0
  23749. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23750. if esep {
  23751. dd.ReadMapElemKey()
  23752. }
  23753. mk = dd.DecodeUint(64)
  23754. if esep {
  23755. dd.ReadMapElemValue()
  23756. }
  23757. if dd.TryDecodeAsNil() {
  23758. if d.h.DeleteOnNilMapValue {
  23759. delete(v, mk)
  23760. } else {
  23761. v[mk] = nil
  23762. }
  23763. continue
  23764. }
  23765. if mapGet {
  23766. mv = v[mk]
  23767. } else {
  23768. mv = nil
  23769. }
  23770. d.decode(&mv)
  23771. if v != nil {
  23772. v[mk] = mv
  23773. }
  23774. }
  23775. dd.ReadMapEnd()
  23776. return v, changed
  23777. }
  23778. func (d *Decoder) fastpathDecMapUint64StringR(f *codecFnInfo, rv reflect.Value) {
  23779. if rv.Kind() == reflect.Ptr {
  23780. vp := rv2i(rv).(*map[uint64]string)
  23781. if v, changed := fastpathTV.DecMapUint64StringV(*vp, true, d); changed {
  23782. *vp = v
  23783. }
  23784. return
  23785. }
  23786. fastpathTV.DecMapUint64StringV(rv2i(rv).(map[uint64]string), false, d)
  23787. }
  23788. func (f fastpathT) DecMapUint64StringX(vp *map[uint64]string, d *Decoder) {
  23789. if v, changed := f.DecMapUint64StringV(*vp, true, d); changed {
  23790. *vp = v
  23791. }
  23792. }
  23793. func (_ fastpathT) DecMapUint64StringV(v map[uint64]string, canChange bool,
  23794. d *Decoder) (_ map[uint64]string, changed bool) {
  23795. dd, esep := d.d, d.hh.hasElemSeparators()
  23796. containerLen := dd.ReadMapStart()
  23797. if canChange && v == nil {
  23798. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  23799. v = make(map[uint64]string, xlen)
  23800. changed = true
  23801. }
  23802. if containerLen == 0 {
  23803. dd.ReadMapEnd()
  23804. return v, changed
  23805. }
  23806. var mk uint64
  23807. var mv string
  23808. hasLen := containerLen > 0
  23809. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23810. if esep {
  23811. dd.ReadMapElemKey()
  23812. }
  23813. mk = dd.DecodeUint(64)
  23814. if esep {
  23815. dd.ReadMapElemValue()
  23816. }
  23817. if dd.TryDecodeAsNil() {
  23818. if d.h.DeleteOnNilMapValue {
  23819. delete(v, mk)
  23820. } else {
  23821. v[mk] = ""
  23822. }
  23823. continue
  23824. }
  23825. mv = dd.DecodeString()
  23826. if v != nil {
  23827. v[mk] = mv
  23828. }
  23829. }
  23830. dd.ReadMapEnd()
  23831. return v, changed
  23832. }
  23833. func (d *Decoder) fastpathDecMapUint64UintR(f *codecFnInfo, rv reflect.Value) {
  23834. if rv.Kind() == reflect.Ptr {
  23835. vp := rv2i(rv).(*map[uint64]uint)
  23836. if v, changed := fastpathTV.DecMapUint64UintV(*vp, true, d); changed {
  23837. *vp = v
  23838. }
  23839. return
  23840. }
  23841. fastpathTV.DecMapUint64UintV(rv2i(rv).(map[uint64]uint), false, d)
  23842. }
  23843. func (f fastpathT) DecMapUint64UintX(vp *map[uint64]uint, d *Decoder) {
  23844. if v, changed := f.DecMapUint64UintV(*vp, true, d); changed {
  23845. *vp = v
  23846. }
  23847. }
  23848. func (_ fastpathT) DecMapUint64UintV(v map[uint64]uint, canChange bool,
  23849. d *Decoder) (_ map[uint64]uint, changed bool) {
  23850. dd, esep := d.d, d.hh.hasElemSeparators()
  23851. containerLen := dd.ReadMapStart()
  23852. if canChange && v == nil {
  23853. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  23854. v = make(map[uint64]uint, xlen)
  23855. changed = true
  23856. }
  23857. if containerLen == 0 {
  23858. dd.ReadMapEnd()
  23859. return v, changed
  23860. }
  23861. var mk uint64
  23862. var mv uint
  23863. hasLen := containerLen > 0
  23864. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23865. if esep {
  23866. dd.ReadMapElemKey()
  23867. }
  23868. mk = dd.DecodeUint(64)
  23869. if esep {
  23870. dd.ReadMapElemValue()
  23871. }
  23872. if dd.TryDecodeAsNil() {
  23873. if d.h.DeleteOnNilMapValue {
  23874. delete(v, mk)
  23875. } else {
  23876. v[mk] = 0
  23877. }
  23878. continue
  23879. }
  23880. mv = uint(dd.DecodeUint(uintBitsize))
  23881. if v != nil {
  23882. v[mk] = mv
  23883. }
  23884. }
  23885. dd.ReadMapEnd()
  23886. return v, changed
  23887. }
  23888. func (d *Decoder) fastpathDecMapUint64Uint8R(f *codecFnInfo, rv reflect.Value) {
  23889. if rv.Kind() == reflect.Ptr {
  23890. vp := rv2i(rv).(*map[uint64]uint8)
  23891. if v, changed := fastpathTV.DecMapUint64Uint8V(*vp, true, d); changed {
  23892. *vp = v
  23893. }
  23894. return
  23895. }
  23896. fastpathTV.DecMapUint64Uint8V(rv2i(rv).(map[uint64]uint8), false, d)
  23897. }
  23898. func (f fastpathT) DecMapUint64Uint8X(vp *map[uint64]uint8, d *Decoder) {
  23899. if v, changed := f.DecMapUint64Uint8V(*vp, true, d); changed {
  23900. *vp = v
  23901. }
  23902. }
  23903. func (_ fastpathT) DecMapUint64Uint8V(v map[uint64]uint8, canChange bool,
  23904. d *Decoder) (_ map[uint64]uint8, changed bool) {
  23905. dd, esep := d.d, d.hh.hasElemSeparators()
  23906. containerLen := dd.ReadMapStart()
  23907. if canChange && v == nil {
  23908. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  23909. v = make(map[uint64]uint8, xlen)
  23910. changed = true
  23911. }
  23912. if containerLen == 0 {
  23913. dd.ReadMapEnd()
  23914. return v, changed
  23915. }
  23916. var mk uint64
  23917. var mv uint8
  23918. hasLen := containerLen > 0
  23919. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23920. if esep {
  23921. dd.ReadMapElemKey()
  23922. }
  23923. mk = dd.DecodeUint(64)
  23924. if esep {
  23925. dd.ReadMapElemValue()
  23926. }
  23927. if dd.TryDecodeAsNil() {
  23928. if d.h.DeleteOnNilMapValue {
  23929. delete(v, mk)
  23930. } else {
  23931. v[mk] = 0
  23932. }
  23933. continue
  23934. }
  23935. mv = uint8(dd.DecodeUint(8))
  23936. if v != nil {
  23937. v[mk] = mv
  23938. }
  23939. }
  23940. dd.ReadMapEnd()
  23941. return v, changed
  23942. }
  23943. func (d *Decoder) fastpathDecMapUint64Uint16R(f *codecFnInfo, rv reflect.Value) {
  23944. if rv.Kind() == reflect.Ptr {
  23945. vp := rv2i(rv).(*map[uint64]uint16)
  23946. if v, changed := fastpathTV.DecMapUint64Uint16V(*vp, true, d); changed {
  23947. *vp = v
  23948. }
  23949. return
  23950. }
  23951. fastpathTV.DecMapUint64Uint16V(rv2i(rv).(map[uint64]uint16), false, d)
  23952. }
  23953. func (f fastpathT) DecMapUint64Uint16X(vp *map[uint64]uint16, d *Decoder) {
  23954. if v, changed := f.DecMapUint64Uint16V(*vp, true, d); changed {
  23955. *vp = v
  23956. }
  23957. }
  23958. func (_ fastpathT) DecMapUint64Uint16V(v map[uint64]uint16, canChange bool,
  23959. d *Decoder) (_ map[uint64]uint16, changed bool) {
  23960. dd, esep := d.d, d.hh.hasElemSeparators()
  23961. containerLen := dd.ReadMapStart()
  23962. if canChange && v == nil {
  23963. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  23964. v = make(map[uint64]uint16, xlen)
  23965. changed = true
  23966. }
  23967. if containerLen == 0 {
  23968. dd.ReadMapEnd()
  23969. return v, changed
  23970. }
  23971. var mk uint64
  23972. var mv uint16
  23973. hasLen := containerLen > 0
  23974. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  23975. if esep {
  23976. dd.ReadMapElemKey()
  23977. }
  23978. mk = dd.DecodeUint(64)
  23979. if esep {
  23980. dd.ReadMapElemValue()
  23981. }
  23982. if dd.TryDecodeAsNil() {
  23983. if d.h.DeleteOnNilMapValue {
  23984. delete(v, mk)
  23985. } else {
  23986. v[mk] = 0
  23987. }
  23988. continue
  23989. }
  23990. mv = uint16(dd.DecodeUint(16))
  23991. if v != nil {
  23992. v[mk] = mv
  23993. }
  23994. }
  23995. dd.ReadMapEnd()
  23996. return v, changed
  23997. }
  23998. func (d *Decoder) fastpathDecMapUint64Uint32R(f *codecFnInfo, rv reflect.Value) {
  23999. if rv.Kind() == reflect.Ptr {
  24000. vp := rv2i(rv).(*map[uint64]uint32)
  24001. if v, changed := fastpathTV.DecMapUint64Uint32V(*vp, true, d); changed {
  24002. *vp = v
  24003. }
  24004. return
  24005. }
  24006. fastpathTV.DecMapUint64Uint32V(rv2i(rv).(map[uint64]uint32), false, d)
  24007. }
  24008. func (f fastpathT) DecMapUint64Uint32X(vp *map[uint64]uint32, d *Decoder) {
  24009. if v, changed := f.DecMapUint64Uint32V(*vp, true, d); changed {
  24010. *vp = v
  24011. }
  24012. }
  24013. func (_ fastpathT) DecMapUint64Uint32V(v map[uint64]uint32, canChange bool,
  24014. d *Decoder) (_ map[uint64]uint32, changed bool) {
  24015. dd, esep := d.d, d.hh.hasElemSeparators()
  24016. containerLen := dd.ReadMapStart()
  24017. if canChange && v == nil {
  24018. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  24019. v = make(map[uint64]uint32, xlen)
  24020. changed = true
  24021. }
  24022. if containerLen == 0 {
  24023. dd.ReadMapEnd()
  24024. return v, changed
  24025. }
  24026. var mk uint64
  24027. var mv uint32
  24028. hasLen := containerLen > 0
  24029. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24030. if esep {
  24031. dd.ReadMapElemKey()
  24032. }
  24033. mk = dd.DecodeUint(64)
  24034. if esep {
  24035. dd.ReadMapElemValue()
  24036. }
  24037. if dd.TryDecodeAsNil() {
  24038. if d.h.DeleteOnNilMapValue {
  24039. delete(v, mk)
  24040. } else {
  24041. v[mk] = 0
  24042. }
  24043. continue
  24044. }
  24045. mv = uint32(dd.DecodeUint(32))
  24046. if v != nil {
  24047. v[mk] = mv
  24048. }
  24049. }
  24050. dd.ReadMapEnd()
  24051. return v, changed
  24052. }
  24053. func (d *Decoder) fastpathDecMapUint64Uint64R(f *codecFnInfo, rv reflect.Value) {
  24054. if rv.Kind() == reflect.Ptr {
  24055. vp := rv2i(rv).(*map[uint64]uint64)
  24056. if v, changed := fastpathTV.DecMapUint64Uint64V(*vp, true, d); changed {
  24057. *vp = v
  24058. }
  24059. return
  24060. }
  24061. fastpathTV.DecMapUint64Uint64V(rv2i(rv).(map[uint64]uint64), false, d)
  24062. }
  24063. func (f fastpathT) DecMapUint64Uint64X(vp *map[uint64]uint64, d *Decoder) {
  24064. if v, changed := f.DecMapUint64Uint64V(*vp, true, d); changed {
  24065. *vp = v
  24066. }
  24067. }
  24068. func (_ fastpathT) DecMapUint64Uint64V(v map[uint64]uint64, canChange bool,
  24069. d *Decoder) (_ map[uint64]uint64, changed bool) {
  24070. dd, esep := d.d, d.hh.hasElemSeparators()
  24071. containerLen := dd.ReadMapStart()
  24072. if canChange && v == nil {
  24073. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  24074. v = make(map[uint64]uint64, xlen)
  24075. changed = true
  24076. }
  24077. if containerLen == 0 {
  24078. dd.ReadMapEnd()
  24079. return v, changed
  24080. }
  24081. var mk uint64
  24082. var mv uint64
  24083. hasLen := containerLen > 0
  24084. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24085. if esep {
  24086. dd.ReadMapElemKey()
  24087. }
  24088. mk = dd.DecodeUint(64)
  24089. if esep {
  24090. dd.ReadMapElemValue()
  24091. }
  24092. if dd.TryDecodeAsNil() {
  24093. if d.h.DeleteOnNilMapValue {
  24094. delete(v, mk)
  24095. } else {
  24096. v[mk] = 0
  24097. }
  24098. continue
  24099. }
  24100. mv = dd.DecodeUint(64)
  24101. if v != nil {
  24102. v[mk] = mv
  24103. }
  24104. }
  24105. dd.ReadMapEnd()
  24106. return v, changed
  24107. }
  24108. func (d *Decoder) fastpathDecMapUint64UintptrR(f *codecFnInfo, rv reflect.Value) {
  24109. if rv.Kind() == reflect.Ptr {
  24110. vp := rv2i(rv).(*map[uint64]uintptr)
  24111. if v, changed := fastpathTV.DecMapUint64UintptrV(*vp, true, d); changed {
  24112. *vp = v
  24113. }
  24114. return
  24115. }
  24116. fastpathTV.DecMapUint64UintptrV(rv2i(rv).(map[uint64]uintptr), false, d)
  24117. }
  24118. func (f fastpathT) DecMapUint64UintptrX(vp *map[uint64]uintptr, d *Decoder) {
  24119. if v, changed := f.DecMapUint64UintptrV(*vp, true, d); changed {
  24120. *vp = v
  24121. }
  24122. }
  24123. func (_ fastpathT) DecMapUint64UintptrV(v map[uint64]uintptr, canChange bool,
  24124. d *Decoder) (_ map[uint64]uintptr, changed bool) {
  24125. dd, esep := d.d, d.hh.hasElemSeparators()
  24126. containerLen := dd.ReadMapStart()
  24127. if canChange && v == nil {
  24128. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  24129. v = make(map[uint64]uintptr, xlen)
  24130. changed = true
  24131. }
  24132. if containerLen == 0 {
  24133. dd.ReadMapEnd()
  24134. return v, changed
  24135. }
  24136. var mk uint64
  24137. var mv uintptr
  24138. hasLen := containerLen > 0
  24139. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24140. if esep {
  24141. dd.ReadMapElemKey()
  24142. }
  24143. mk = dd.DecodeUint(64)
  24144. if esep {
  24145. dd.ReadMapElemValue()
  24146. }
  24147. if dd.TryDecodeAsNil() {
  24148. if d.h.DeleteOnNilMapValue {
  24149. delete(v, mk)
  24150. } else {
  24151. v[mk] = 0
  24152. }
  24153. continue
  24154. }
  24155. mv = uintptr(dd.DecodeUint(uintBitsize))
  24156. if v != nil {
  24157. v[mk] = mv
  24158. }
  24159. }
  24160. dd.ReadMapEnd()
  24161. return v, changed
  24162. }
  24163. func (d *Decoder) fastpathDecMapUint64IntR(f *codecFnInfo, rv reflect.Value) {
  24164. if rv.Kind() == reflect.Ptr {
  24165. vp := rv2i(rv).(*map[uint64]int)
  24166. if v, changed := fastpathTV.DecMapUint64IntV(*vp, true, d); changed {
  24167. *vp = v
  24168. }
  24169. return
  24170. }
  24171. fastpathTV.DecMapUint64IntV(rv2i(rv).(map[uint64]int), false, d)
  24172. }
  24173. func (f fastpathT) DecMapUint64IntX(vp *map[uint64]int, d *Decoder) {
  24174. if v, changed := f.DecMapUint64IntV(*vp, true, d); changed {
  24175. *vp = v
  24176. }
  24177. }
  24178. func (_ fastpathT) DecMapUint64IntV(v map[uint64]int, canChange bool,
  24179. d *Decoder) (_ map[uint64]int, changed bool) {
  24180. dd, esep := d.d, d.hh.hasElemSeparators()
  24181. containerLen := dd.ReadMapStart()
  24182. if canChange && v == nil {
  24183. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  24184. v = make(map[uint64]int, xlen)
  24185. changed = true
  24186. }
  24187. if containerLen == 0 {
  24188. dd.ReadMapEnd()
  24189. return v, changed
  24190. }
  24191. var mk uint64
  24192. var mv int
  24193. hasLen := containerLen > 0
  24194. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24195. if esep {
  24196. dd.ReadMapElemKey()
  24197. }
  24198. mk = dd.DecodeUint(64)
  24199. if esep {
  24200. dd.ReadMapElemValue()
  24201. }
  24202. if dd.TryDecodeAsNil() {
  24203. if d.h.DeleteOnNilMapValue {
  24204. delete(v, mk)
  24205. } else {
  24206. v[mk] = 0
  24207. }
  24208. continue
  24209. }
  24210. mv = int(dd.DecodeInt(intBitsize))
  24211. if v != nil {
  24212. v[mk] = mv
  24213. }
  24214. }
  24215. dd.ReadMapEnd()
  24216. return v, changed
  24217. }
  24218. func (d *Decoder) fastpathDecMapUint64Int8R(f *codecFnInfo, rv reflect.Value) {
  24219. if rv.Kind() == reflect.Ptr {
  24220. vp := rv2i(rv).(*map[uint64]int8)
  24221. if v, changed := fastpathTV.DecMapUint64Int8V(*vp, true, d); changed {
  24222. *vp = v
  24223. }
  24224. return
  24225. }
  24226. fastpathTV.DecMapUint64Int8V(rv2i(rv).(map[uint64]int8), false, d)
  24227. }
  24228. func (f fastpathT) DecMapUint64Int8X(vp *map[uint64]int8, d *Decoder) {
  24229. if v, changed := f.DecMapUint64Int8V(*vp, true, d); changed {
  24230. *vp = v
  24231. }
  24232. }
  24233. func (_ fastpathT) DecMapUint64Int8V(v map[uint64]int8, canChange bool,
  24234. d *Decoder) (_ map[uint64]int8, changed bool) {
  24235. dd, esep := d.d, d.hh.hasElemSeparators()
  24236. containerLen := dd.ReadMapStart()
  24237. if canChange && v == nil {
  24238. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  24239. v = make(map[uint64]int8, xlen)
  24240. changed = true
  24241. }
  24242. if containerLen == 0 {
  24243. dd.ReadMapEnd()
  24244. return v, changed
  24245. }
  24246. var mk uint64
  24247. var mv int8
  24248. hasLen := containerLen > 0
  24249. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24250. if esep {
  24251. dd.ReadMapElemKey()
  24252. }
  24253. mk = dd.DecodeUint(64)
  24254. if esep {
  24255. dd.ReadMapElemValue()
  24256. }
  24257. if dd.TryDecodeAsNil() {
  24258. if d.h.DeleteOnNilMapValue {
  24259. delete(v, mk)
  24260. } else {
  24261. v[mk] = 0
  24262. }
  24263. continue
  24264. }
  24265. mv = int8(dd.DecodeInt(8))
  24266. if v != nil {
  24267. v[mk] = mv
  24268. }
  24269. }
  24270. dd.ReadMapEnd()
  24271. return v, changed
  24272. }
  24273. func (d *Decoder) fastpathDecMapUint64Int16R(f *codecFnInfo, rv reflect.Value) {
  24274. if rv.Kind() == reflect.Ptr {
  24275. vp := rv2i(rv).(*map[uint64]int16)
  24276. if v, changed := fastpathTV.DecMapUint64Int16V(*vp, true, d); changed {
  24277. *vp = v
  24278. }
  24279. return
  24280. }
  24281. fastpathTV.DecMapUint64Int16V(rv2i(rv).(map[uint64]int16), false, d)
  24282. }
  24283. func (f fastpathT) DecMapUint64Int16X(vp *map[uint64]int16, d *Decoder) {
  24284. if v, changed := f.DecMapUint64Int16V(*vp, true, d); changed {
  24285. *vp = v
  24286. }
  24287. }
  24288. func (_ fastpathT) DecMapUint64Int16V(v map[uint64]int16, canChange bool,
  24289. d *Decoder) (_ map[uint64]int16, changed bool) {
  24290. dd, esep := d.d, d.hh.hasElemSeparators()
  24291. containerLen := dd.ReadMapStart()
  24292. if canChange && v == nil {
  24293. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  24294. v = make(map[uint64]int16, xlen)
  24295. changed = true
  24296. }
  24297. if containerLen == 0 {
  24298. dd.ReadMapEnd()
  24299. return v, changed
  24300. }
  24301. var mk uint64
  24302. var mv int16
  24303. hasLen := containerLen > 0
  24304. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24305. if esep {
  24306. dd.ReadMapElemKey()
  24307. }
  24308. mk = dd.DecodeUint(64)
  24309. if esep {
  24310. dd.ReadMapElemValue()
  24311. }
  24312. if dd.TryDecodeAsNil() {
  24313. if d.h.DeleteOnNilMapValue {
  24314. delete(v, mk)
  24315. } else {
  24316. v[mk] = 0
  24317. }
  24318. continue
  24319. }
  24320. mv = int16(dd.DecodeInt(16))
  24321. if v != nil {
  24322. v[mk] = mv
  24323. }
  24324. }
  24325. dd.ReadMapEnd()
  24326. return v, changed
  24327. }
  24328. func (d *Decoder) fastpathDecMapUint64Int32R(f *codecFnInfo, rv reflect.Value) {
  24329. if rv.Kind() == reflect.Ptr {
  24330. vp := rv2i(rv).(*map[uint64]int32)
  24331. if v, changed := fastpathTV.DecMapUint64Int32V(*vp, true, d); changed {
  24332. *vp = v
  24333. }
  24334. return
  24335. }
  24336. fastpathTV.DecMapUint64Int32V(rv2i(rv).(map[uint64]int32), false, d)
  24337. }
  24338. func (f fastpathT) DecMapUint64Int32X(vp *map[uint64]int32, d *Decoder) {
  24339. if v, changed := f.DecMapUint64Int32V(*vp, true, d); changed {
  24340. *vp = v
  24341. }
  24342. }
  24343. func (_ fastpathT) DecMapUint64Int32V(v map[uint64]int32, canChange bool,
  24344. d *Decoder) (_ map[uint64]int32, changed bool) {
  24345. dd, esep := d.d, d.hh.hasElemSeparators()
  24346. containerLen := dd.ReadMapStart()
  24347. if canChange && v == nil {
  24348. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  24349. v = make(map[uint64]int32, xlen)
  24350. changed = true
  24351. }
  24352. if containerLen == 0 {
  24353. dd.ReadMapEnd()
  24354. return v, changed
  24355. }
  24356. var mk uint64
  24357. var mv int32
  24358. hasLen := containerLen > 0
  24359. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24360. if esep {
  24361. dd.ReadMapElemKey()
  24362. }
  24363. mk = dd.DecodeUint(64)
  24364. if esep {
  24365. dd.ReadMapElemValue()
  24366. }
  24367. if dd.TryDecodeAsNil() {
  24368. if d.h.DeleteOnNilMapValue {
  24369. delete(v, mk)
  24370. } else {
  24371. v[mk] = 0
  24372. }
  24373. continue
  24374. }
  24375. mv = int32(dd.DecodeInt(32))
  24376. if v != nil {
  24377. v[mk] = mv
  24378. }
  24379. }
  24380. dd.ReadMapEnd()
  24381. return v, changed
  24382. }
  24383. func (d *Decoder) fastpathDecMapUint64Int64R(f *codecFnInfo, rv reflect.Value) {
  24384. if rv.Kind() == reflect.Ptr {
  24385. vp := rv2i(rv).(*map[uint64]int64)
  24386. if v, changed := fastpathTV.DecMapUint64Int64V(*vp, true, d); changed {
  24387. *vp = v
  24388. }
  24389. return
  24390. }
  24391. fastpathTV.DecMapUint64Int64V(rv2i(rv).(map[uint64]int64), false, d)
  24392. }
  24393. func (f fastpathT) DecMapUint64Int64X(vp *map[uint64]int64, d *Decoder) {
  24394. if v, changed := f.DecMapUint64Int64V(*vp, true, d); changed {
  24395. *vp = v
  24396. }
  24397. }
  24398. func (_ fastpathT) DecMapUint64Int64V(v map[uint64]int64, canChange bool,
  24399. d *Decoder) (_ map[uint64]int64, changed bool) {
  24400. dd, esep := d.d, d.hh.hasElemSeparators()
  24401. containerLen := dd.ReadMapStart()
  24402. if canChange && v == nil {
  24403. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  24404. v = make(map[uint64]int64, xlen)
  24405. changed = true
  24406. }
  24407. if containerLen == 0 {
  24408. dd.ReadMapEnd()
  24409. return v, changed
  24410. }
  24411. var mk uint64
  24412. var mv int64
  24413. hasLen := containerLen > 0
  24414. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24415. if esep {
  24416. dd.ReadMapElemKey()
  24417. }
  24418. mk = dd.DecodeUint(64)
  24419. if esep {
  24420. dd.ReadMapElemValue()
  24421. }
  24422. if dd.TryDecodeAsNil() {
  24423. if d.h.DeleteOnNilMapValue {
  24424. delete(v, mk)
  24425. } else {
  24426. v[mk] = 0
  24427. }
  24428. continue
  24429. }
  24430. mv = dd.DecodeInt(64)
  24431. if v != nil {
  24432. v[mk] = mv
  24433. }
  24434. }
  24435. dd.ReadMapEnd()
  24436. return v, changed
  24437. }
  24438. func (d *Decoder) fastpathDecMapUint64Float32R(f *codecFnInfo, rv reflect.Value) {
  24439. if rv.Kind() == reflect.Ptr {
  24440. vp := rv2i(rv).(*map[uint64]float32)
  24441. if v, changed := fastpathTV.DecMapUint64Float32V(*vp, true, d); changed {
  24442. *vp = v
  24443. }
  24444. return
  24445. }
  24446. fastpathTV.DecMapUint64Float32V(rv2i(rv).(map[uint64]float32), false, d)
  24447. }
  24448. func (f fastpathT) DecMapUint64Float32X(vp *map[uint64]float32, d *Decoder) {
  24449. if v, changed := f.DecMapUint64Float32V(*vp, true, d); changed {
  24450. *vp = v
  24451. }
  24452. }
  24453. func (_ fastpathT) DecMapUint64Float32V(v map[uint64]float32, canChange bool,
  24454. d *Decoder) (_ map[uint64]float32, changed bool) {
  24455. dd, esep := d.d, d.hh.hasElemSeparators()
  24456. containerLen := dd.ReadMapStart()
  24457. if canChange && v == nil {
  24458. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  24459. v = make(map[uint64]float32, xlen)
  24460. changed = true
  24461. }
  24462. if containerLen == 0 {
  24463. dd.ReadMapEnd()
  24464. return v, changed
  24465. }
  24466. var mk uint64
  24467. var mv float32
  24468. hasLen := containerLen > 0
  24469. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24470. if esep {
  24471. dd.ReadMapElemKey()
  24472. }
  24473. mk = dd.DecodeUint(64)
  24474. if esep {
  24475. dd.ReadMapElemValue()
  24476. }
  24477. if dd.TryDecodeAsNil() {
  24478. if d.h.DeleteOnNilMapValue {
  24479. delete(v, mk)
  24480. } else {
  24481. v[mk] = 0
  24482. }
  24483. continue
  24484. }
  24485. mv = float32(dd.DecodeFloat(true))
  24486. if v != nil {
  24487. v[mk] = mv
  24488. }
  24489. }
  24490. dd.ReadMapEnd()
  24491. return v, changed
  24492. }
  24493. func (d *Decoder) fastpathDecMapUint64Float64R(f *codecFnInfo, rv reflect.Value) {
  24494. if rv.Kind() == reflect.Ptr {
  24495. vp := rv2i(rv).(*map[uint64]float64)
  24496. if v, changed := fastpathTV.DecMapUint64Float64V(*vp, true, d); changed {
  24497. *vp = v
  24498. }
  24499. return
  24500. }
  24501. fastpathTV.DecMapUint64Float64V(rv2i(rv).(map[uint64]float64), false, d)
  24502. }
  24503. func (f fastpathT) DecMapUint64Float64X(vp *map[uint64]float64, d *Decoder) {
  24504. if v, changed := f.DecMapUint64Float64V(*vp, true, d); changed {
  24505. *vp = v
  24506. }
  24507. }
  24508. func (_ fastpathT) DecMapUint64Float64V(v map[uint64]float64, canChange bool,
  24509. d *Decoder) (_ map[uint64]float64, changed bool) {
  24510. dd, esep := d.d, d.hh.hasElemSeparators()
  24511. containerLen := dd.ReadMapStart()
  24512. if canChange && v == nil {
  24513. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  24514. v = make(map[uint64]float64, xlen)
  24515. changed = true
  24516. }
  24517. if containerLen == 0 {
  24518. dd.ReadMapEnd()
  24519. return v, changed
  24520. }
  24521. var mk uint64
  24522. var mv float64
  24523. hasLen := containerLen > 0
  24524. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24525. if esep {
  24526. dd.ReadMapElemKey()
  24527. }
  24528. mk = dd.DecodeUint(64)
  24529. if esep {
  24530. dd.ReadMapElemValue()
  24531. }
  24532. if dd.TryDecodeAsNil() {
  24533. if d.h.DeleteOnNilMapValue {
  24534. delete(v, mk)
  24535. } else {
  24536. v[mk] = 0
  24537. }
  24538. continue
  24539. }
  24540. mv = dd.DecodeFloat(false)
  24541. if v != nil {
  24542. v[mk] = mv
  24543. }
  24544. }
  24545. dd.ReadMapEnd()
  24546. return v, changed
  24547. }
  24548. func (d *Decoder) fastpathDecMapUint64BoolR(f *codecFnInfo, rv reflect.Value) {
  24549. if rv.Kind() == reflect.Ptr {
  24550. vp := rv2i(rv).(*map[uint64]bool)
  24551. if v, changed := fastpathTV.DecMapUint64BoolV(*vp, true, d); changed {
  24552. *vp = v
  24553. }
  24554. return
  24555. }
  24556. fastpathTV.DecMapUint64BoolV(rv2i(rv).(map[uint64]bool), false, d)
  24557. }
  24558. func (f fastpathT) DecMapUint64BoolX(vp *map[uint64]bool, d *Decoder) {
  24559. if v, changed := f.DecMapUint64BoolV(*vp, true, d); changed {
  24560. *vp = v
  24561. }
  24562. }
  24563. func (_ fastpathT) DecMapUint64BoolV(v map[uint64]bool, canChange bool,
  24564. d *Decoder) (_ map[uint64]bool, changed bool) {
  24565. dd, esep := d.d, d.hh.hasElemSeparators()
  24566. containerLen := dd.ReadMapStart()
  24567. if canChange && v == nil {
  24568. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  24569. v = make(map[uint64]bool, xlen)
  24570. changed = true
  24571. }
  24572. if containerLen == 0 {
  24573. dd.ReadMapEnd()
  24574. return v, changed
  24575. }
  24576. var mk uint64
  24577. var mv bool
  24578. hasLen := containerLen > 0
  24579. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24580. if esep {
  24581. dd.ReadMapElemKey()
  24582. }
  24583. mk = dd.DecodeUint(64)
  24584. if esep {
  24585. dd.ReadMapElemValue()
  24586. }
  24587. if dd.TryDecodeAsNil() {
  24588. if d.h.DeleteOnNilMapValue {
  24589. delete(v, mk)
  24590. } else {
  24591. v[mk] = false
  24592. }
  24593. continue
  24594. }
  24595. mv = dd.DecodeBool()
  24596. if v != nil {
  24597. v[mk] = mv
  24598. }
  24599. }
  24600. dd.ReadMapEnd()
  24601. return v, changed
  24602. }
  24603. func (d *Decoder) fastpathDecMapUintptrIntfR(f *codecFnInfo, rv reflect.Value) {
  24604. if rv.Kind() == reflect.Ptr {
  24605. vp := rv2i(rv).(*map[uintptr]interface{})
  24606. if v, changed := fastpathTV.DecMapUintptrIntfV(*vp, true, d); changed {
  24607. *vp = v
  24608. }
  24609. return
  24610. }
  24611. fastpathTV.DecMapUintptrIntfV(rv2i(rv).(map[uintptr]interface{}), false, d)
  24612. }
  24613. func (f fastpathT) DecMapUintptrIntfX(vp *map[uintptr]interface{}, d *Decoder) {
  24614. if v, changed := f.DecMapUintptrIntfV(*vp, true, d); changed {
  24615. *vp = v
  24616. }
  24617. }
  24618. func (_ fastpathT) DecMapUintptrIntfV(v map[uintptr]interface{}, canChange bool,
  24619. d *Decoder) (_ map[uintptr]interface{}, changed bool) {
  24620. dd, esep := d.d, d.hh.hasElemSeparators()
  24621. containerLen := dd.ReadMapStart()
  24622. if canChange && v == nil {
  24623. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  24624. v = make(map[uintptr]interface{}, xlen)
  24625. changed = true
  24626. }
  24627. if containerLen == 0 {
  24628. dd.ReadMapEnd()
  24629. return v, changed
  24630. }
  24631. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  24632. var mk uintptr
  24633. var mv interface{}
  24634. hasLen := containerLen > 0
  24635. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24636. if esep {
  24637. dd.ReadMapElemKey()
  24638. }
  24639. mk = uintptr(dd.DecodeUint(uintBitsize))
  24640. if esep {
  24641. dd.ReadMapElemValue()
  24642. }
  24643. if dd.TryDecodeAsNil() {
  24644. if d.h.DeleteOnNilMapValue {
  24645. delete(v, mk)
  24646. } else {
  24647. v[mk] = nil
  24648. }
  24649. continue
  24650. }
  24651. if mapGet {
  24652. mv = v[mk]
  24653. } else {
  24654. mv = nil
  24655. }
  24656. d.decode(&mv)
  24657. if v != nil {
  24658. v[mk] = mv
  24659. }
  24660. }
  24661. dd.ReadMapEnd()
  24662. return v, changed
  24663. }
  24664. func (d *Decoder) fastpathDecMapUintptrStringR(f *codecFnInfo, rv reflect.Value) {
  24665. if rv.Kind() == reflect.Ptr {
  24666. vp := rv2i(rv).(*map[uintptr]string)
  24667. if v, changed := fastpathTV.DecMapUintptrStringV(*vp, true, d); changed {
  24668. *vp = v
  24669. }
  24670. return
  24671. }
  24672. fastpathTV.DecMapUintptrStringV(rv2i(rv).(map[uintptr]string), false, d)
  24673. }
  24674. func (f fastpathT) DecMapUintptrStringX(vp *map[uintptr]string, d *Decoder) {
  24675. if v, changed := f.DecMapUintptrStringV(*vp, true, d); changed {
  24676. *vp = v
  24677. }
  24678. }
  24679. func (_ fastpathT) DecMapUintptrStringV(v map[uintptr]string, canChange bool,
  24680. d *Decoder) (_ map[uintptr]string, changed bool) {
  24681. dd, esep := d.d, d.hh.hasElemSeparators()
  24682. containerLen := dd.ReadMapStart()
  24683. if canChange && v == nil {
  24684. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  24685. v = make(map[uintptr]string, xlen)
  24686. changed = true
  24687. }
  24688. if containerLen == 0 {
  24689. dd.ReadMapEnd()
  24690. return v, changed
  24691. }
  24692. var mk uintptr
  24693. var mv string
  24694. hasLen := containerLen > 0
  24695. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24696. if esep {
  24697. dd.ReadMapElemKey()
  24698. }
  24699. mk = uintptr(dd.DecodeUint(uintBitsize))
  24700. if esep {
  24701. dd.ReadMapElemValue()
  24702. }
  24703. if dd.TryDecodeAsNil() {
  24704. if d.h.DeleteOnNilMapValue {
  24705. delete(v, mk)
  24706. } else {
  24707. v[mk] = ""
  24708. }
  24709. continue
  24710. }
  24711. mv = dd.DecodeString()
  24712. if v != nil {
  24713. v[mk] = mv
  24714. }
  24715. }
  24716. dd.ReadMapEnd()
  24717. return v, changed
  24718. }
  24719. func (d *Decoder) fastpathDecMapUintptrUintR(f *codecFnInfo, rv reflect.Value) {
  24720. if rv.Kind() == reflect.Ptr {
  24721. vp := rv2i(rv).(*map[uintptr]uint)
  24722. if v, changed := fastpathTV.DecMapUintptrUintV(*vp, true, d); changed {
  24723. *vp = v
  24724. }
  24725. return
  24726. }
  24727. fastpathTV.DecMapUintptrUintV(rv2i(rv).(map[uintptr]uint), false, d)
  24728. }
  24729. func (f fastpathT) DecMapUintptrUintX(vp *map[uintptr]uint, d *Decoder) {
  24730. if v, changed := f.DecMapUintptrUintV(*vp, true, d); changed {
  24731. *vp = v
  24732. }
  24733. }
  24734. func (_ fastpathT) DecMapUintptrUintV(v map[uintptr]uint, canChange bool,
  24735. d *Decoder) (_ map[uintptr]uint, changed bool) {
  24736. dd, esep := d.d, d.hh.hasElemSeparators()
  24737. containerLen := dd.ReadMapStart()
  24738. if canChange && v == nil {
  24739. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  24740. v = make(map[uintptr]uint, xlen)
  24741. changed = true
  24742. }
  24743. if containerLen == 0 {
  24744. dd.ReadMapEnd()
  24745. return v, changed
  24746. }
  24747. var mk uintptr
  24748. var mv uint
  24749. hasLen := containerLen > 0
  24750. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24751. if esep {
  24752. dd.ReadMapElemKey()
  24753. }
  24754. mk = uintptr(dd.DecodeUint(uintBitsize))
  24755. if esep {
  24756. dd.ReadMapElemValue()
  24757. }
  24758. if dd.TryDecodeAsNil() {
  24759. if d.h.DeleteOnNilMapValue {
  24760. delete(v, mk)
  24761. } else {
  24762. v[mk] = 0
  24763. }
  24764. continue
  24765. }
  24766. mv = uint(dd.DecodeUint(uintBitsize))
  24767. if v != nil {
  24768. v[mk] = mv
  24769. }
  24770. }
  24771. dd.ReadMapEnd()
  24772. return v, changed
  24773. }
  24774. func (d *Decoder) fastpathDecMapUintptrUint8R(f *codecFnInfo, rv reflect.Value) {
  24775. if rv.Kind() == reflect.Ptr {
  24776. vp := rv2i(rv).(*map[uintptr]uint8)
  24777. if v, changed := fastpathTV.DecMapUintptrUint8V(*vp, true, d); changed {
  24778. *vp = v
  24779. }
  24780. return
  24781. }
  24782. fastpathTV.DecMapUintptrUint8V(rv2i(rv).(map[uintptr]uint8), false, d)
  24783. }
  24784. func (f fastpathT) DecMapUintptrUint8X(vp *map[uintptr]uint8, d *Decoder) {
  24785. if v, changed := f.DecMapUintptrUint8V(*vp, true, d); changed {
  24786. *vp = v
  24787. }
  24788. }
  24789. func (_ fastpathT) DecMapUintptrUint8V(v map[uintptr]uint8, canChange bool,
  24790. d *Decoder) (_ map[uintptr]uint8, changed bool) {
  24791. dd, esep := d.d, d.hh.hasElemSeparators()
  24792. containerLen := dd.ReadMapStart()
  24793. if canChange && v == nil {
  24794. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  24795. v = make(map[uintptr]uint8, xlen)
  24796. changed = true
  24797. }
  24798. if containerLen == 0 {
  24799. dd.ReadMapEnd()
  24800. return v, changed
  24801. }
  24802. var mk uintptr
  24803. var mv uint8
  24804. hasLen := containerLen > 0
  24805. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24806. if esep {
  24807. dd.ReadMapElemKey()
  24808. }
  24809. mk = uintptr(dd.DecodeUint(uintBitsize))
  24810. if esep {
  24811. dd.ReadMapElemValue()
  24812. }
  24813. if dd.TryDecodeAsNil() {
  24814. if d.h.DeleteOnNilMapValue {
  24815. delete(v, mk)
  24816. } else {
  24817. v[mk] = 0
  24818. }
  24819. continue
  24820. }
  24821. mv = uint8(dd.DecodeUint(8))
  24822. if v != nil {
  24823. v[mk] = mv
  24824. }
  24825. }
  24826. dd.ReadMapEnd()
  24827. return v, changed
  24828. }
  24829. func (d *Decoder) fastpathDecMapUintptrUint16R(f *codecFnInfo, rv reflect.Value) {
  24830. if rv.Kind() == reflect.Ptr {
  24831. vp := rv2i(rv).(*map[uintptr]uint16)
  24832. if v, changed := fastpathTV.DecMapUintptrUint16V(*vp, true, d); changed {
  24833. *vp = v
  24834. }
  24835. return
  24836. }
  24837. fastpathTV.DecMapUintptrUint16V(rv2i(rv).(map[uintptr]uint16), false, d)
  24838. }
  24839. func (f fastpathT) DecMapUintptrUint16X(vp *map[uintptr]uint16, d *Decoder) {
  24840. if v, changed := f.DecMapUintptrUint16V(*vp, true, d); changed {
  24841. *vp = v
  24842. }
  24843. }
  24844. func (_ fastpathT) DecMapUintptrUint16V(v map[uintptr]uint16, canChange bool,
  24845. d *Decoder) (_ map[uintptr]uint16, changed bool) {
  24846. dd, esep := d.d, d.hh.hasElemSeparators()
  24847. containerLen := dd.ReadMapStart()
  24848. if canChange && v == nil {
  24849. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  24850. v = make(map[uintptr]uint16, xlen)
  24851. changed = true
  24852. }
  24853. if containerLen == 0 {
  24854. dd.ReadMapEnd()
  24855. return v, changed
  24856. }
  24857. var mk uintptr
  24858. var mv uint16
  24859. hasLen := containerLen > 0
  24860. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24861. if esep {
  24862. dd.ReadMapElemKey()
  24863. }
  24864. mk = uintptr(dd.DecodeUint(uintBitsize))
  24865. if esep {
  24866. dd.ReadMapElemValue()
  24867. }
  24868. if dd.TryDecodeAsNil() {
  24869. if d.h.DeleteOnNilMapValue {
  24870. delete(v, mk)
  24871. } else {
  24872. v[mk] = 0
  24873. }
  24874. continue
  24875. }
  24876. mv = uint16(dd.DecodeUint(16))
  24877. if v != nil {
  24878. v[mk] = mv
  24879. }
  24880. }
  24881. dd.ReadMapEnd()
  24882. return v, changed
  24883. }
  24884. func (d *Decoder) fastpathDecMapUintptrUint32R(f *codecFnInfo, rv reflect.Value) {
  24885. if rv.Kind() == reflect.Ptr {
  24886. vp := rv2i(rv).(*map[uintptr]uint32)
  24887. if v, changed := fastpathTV.DecMapUintptrUint32V(*vp, true, d); changed {
  24888. *vp = v
  24889. }
  24890. return
  24891. }
  24892. fastpathTV.DecMapUintptrUint32V(rv2i(rv).(map[uintptr]uint32), false, d)
  24893. }
  24894. func (f fastpathT) DecMapUintptrUint32X(vp *map[uintptr]uint32, d *Decoder) {
  24895. if v, changed := f.DecMapUintptrUint32V(*vp, true, d); changed {
  24896. *vp = v
  24897. }
  24898. }
  24899. func (_ fastpathT) DecMapUintptrUint32V(v map[uintptr]uint32, canChange bool,
  24900. d *Decoder) (_ map[uintptr]uint32, changed bool) {
  24901. dd, esep := d.d, d.hh.hasElemSeparators()
  24902. containerLen := dd.ReadMapStart()
  24903. if canChange && v == nil {
  24904. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  24905. v = make(map[uintptr]uint32, xlen)
  24906. changed = true
  24907. }
  24908. if containerLen == 0 {
  24909. dd.ReadMapEnd()
  24910. return v, changed
  24911. }
  24912. var mk uintptr
  24913. var mv uint32
  24914. hasLen := containerLen > 0
  24915. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24916. if esep {
  24917. dd.ReadMapElemKey()
  24918. }
  24919. mk = uintptr(dd.DecodeUint(uintBitsize))
  24920. if esep {
  24921. dd.ReadMapElemValue()
  24922. }
  24923. if dd.TryDecodeAsNil() {
  24924. if d.h.DeleteOnNilMapValue {
  24925. delete(v, mk)
  24926. } else {
  24927. v[mk] = 0
  24928. }
  24929. continue
  24930. }
  24931. mv = uint32(dd.DecodeUint(32))
  24932. if v != nil {
  24933. v[mk] = mv
  24934. }
  24935. }
  24936. dd.ReadMapEnd()
  24937. return v, changed
  24938. }
  24939. func (d *Decoder) fastpathDecMapUintptrUint64R(f *codecFnInfo, rv reflect.Value) {
  24940. if rv.Kind() == reflect.Ptr {
  24941. vp := rv2i(rv).(*map[uintptr]uint64)
  24942. if v, changed := fastpathTV.DecMapUintptrUint64V(*vp, true, d); changed {
  24943. *vp = v
  24944. }
  24945. return
  24946. }
  24947. fastpathTV.DecMapUintptrUint64V(rv2i(rv).(map[uintptr]uint64), false, d)
  24948. }
  24949. func (f fastpathT) DecMapUintptrUint64X(vp *map[uintptr]uint64, d *Decoder) {
  24950. if v, changed := f.DecMapUintptrUint64V(*vp, true, d); changed {
  24951. *vp = v
  24952. }
  24953. }
  24954. func (_ fastpathT) DecMapUintptrUint64V(v map[uintptr]uint64, canChange bool,
  24955. d *Decoder) (_ map[uintptr]uint64, changed bool) {
  24956. dd, esep := d.d, d.hh.hasElemSeparators()
  24957. containerLen := dd.ReadMapStart()
  24958. if canChange && v == nil {
  24959. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  24960. v = make(map[uintptr]uint64, xlen)
  24961. changed = true
  24962. }
  24963. if containerLen == 0 {
  24964. dd.ReadMapEnd()
  24965. return v, changed
  24966. }
  24967. var mk uintptr
  24968. var mv uint64
  24969. hasLen := containerLen > 0
  24970. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  24971. if esep {
  24972. dd.ReadMapElemKey()
  24973. }
  24974. mk = uintptr(dd.DecodeUint(uintBitsize))
  24975. if esep {
  24976. dd.ReadMapElemValue()
  24977. }
  24978. if dd.TryDecodeAsNil() {
  24979. if d.h.DeleteOnNilMapValue {
  24980. delete(v, mk)
  24981. } else {
  24982. v[mk] = 0
  24983. }
  24984. continue
  24985. }
  24986. mv = dd.DecodeUint(64)
  24987. if v != nil {
  24988. v[mk] = mv
  24989. }
  24990. }
  24991. dd.ReadMapEnd()
  24992. return v, changed
  24993. }
  24994. func (d *Decoder) fastpathDecMapUintptrUintptrR(f *codecFnInfo, rv reflect.Value) {
  24995. if rv.Kind() == reflect.Ptr {
  24996. vp := rv2i(rv).(*map[uintptr]uintptr)
  24997. if v, changed := fastpathTV.DecMapUintptrUintptrV(*vp, true, d); changed {
  24998. *vp = v
  24999. }
  25000. return
  25001. }
  25002. fastpathTV.DecMapUintptrUintptrV(rv2i(rv).(map[uintptr]uintptr), false, d)
  25003. }
  25004. func (f fastpathT) DecMapUintptrUintptrX(vp *map[uintptr]uintptr, d *Decoder) {
  25005. if v, changed := f.DecMapUintptrUintptrV(*vp, true, d); changed {
  25006. *vp = v
  25007. }
  25008. }
  25009. func (_ fastpathT) DecMapUintptrUintptrV(v map[uintptr]uintptr, canChange bool,
  25010. d *Decoder) (_ map[uintptr]uintptr, changed bool) {
  25011. dd, esep := d.d, d.hh.hasElemSeparators()
  25012. containerLen := dd.ReadMapStart()
  25013. if canChange && v == nil {
  25014. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25015. v = make(map[uintptr]uintptr, xlen)
  25016. changed = true
  25017. }
  25018. if containerLen == 0 {
  25019. dd.ReadMapEnd()
  25020. return v, changed
  25021. }
  25022. var mk uintptr
  25023. var mv uintptr
  25024. hasLen := containerLen > 0
  25025. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25026. if esep {
  25027. dd.ReadMapElemKey()
  25028. }
  25029. mk = uintptr(dd.DecodeUint(uintBitsize))
  25030. if esep {
  25031. dd.ReadMapElemValue()
  25032. }
  25033. if dd.TryDecodeAsNil() {
  25034. if d.h.DeleteOnNilMapValue {
  25035. delete(v, mk)
  25036. } else {
  25037. v[mk] = 0
  25038. }
  25039. continue
  25040. }
  25041. mv = uintptr(dd.DecodeUint(uintBitsize))
  25042. if v != nil {
  25043. v[mk] = mv
  25044. }
  25045. }
  25046. dd.ReadMapEnd()
  25047. return v, changed
  25048. }
  25049. func (d *Decoder) fastpathDecMapUintptrIntR(f *codecFnInfo, rv reflect.Value) {
  25050. if rv.Kind() == reflect.Ptr {
  25051. vp := rv2i(rv).(*map[uintptr]int)
  25052. if v, changed := fastpathTV.DecMapUintptrIntV(*vp, true, d); changed {
  25053. *vp = v
  25054. }
  25055. return
  25056. }
  25057. fastpathTV.DecMapUintptrIntV(rv2i(rv).(map[uintptr]int), false, d)
  25058. }
  25059. func (f fastpathT) DecMapUintptrIntX(vp *map[uintptr]int, d *Decoder) {
  25060. if v, changed := f.DecMapUintptrIntV(*vp, true, d); changed {
  25061. *vp = v
  25062. }
  25063. }
  25064. func (_ fastpathT) DecMapUintptrIntV(v map[uintptr]int, canChange bool,
  25065. d *Decoder) (_ map[uintptr]int, changed bool) {
  25066. dd, esep := d.d, d.hh.hasElemSeparators()
  25067. containerLen := dd.ReadMapStart()
  25068. if canChange && v == nil {
  25069. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25070. v = make(map[uintptr]int, xlen)
  25071. changed = true
  25072. }
  25073. if containerLen == 0 {
  25074. dd.ReadMapEnd()
  25075. return v, changed
  25076. }
  25077. var mk uintptr
  25078. var mv int
  25079. hasLen := containerLen > 0
  25080. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25081. if esep {
  25082. dd.ReadMapElemKey()
  25083. }
  25084. mk = uintptr(dd.DecodeUint(uintBitsize))
  25085. if esep {
  25086. dd.ReadMapElemValue()
  25087. }
  25088. if dd.TryDecodeAsNil() {
  25089. if d.h.DeleteOnNilMapValue {
  25090. delete(v, mk)
  25091. } else {
  25092. v[mk] = 0
  25093. }
  25094. continue
  25095. }
  25096. mv = int(dd.DecodeInt(intBitsize))
  25097. if v != nil {
  25098. v[mk] = mv
  25099. }
  25100. }
  25101. dd.ReadMapEnd()
  25102. return v, changed
  25103. }
  25104. func (d *Decoder) fastpathDecMapUintptrInt8R(f *codecFnInfo, rv reflect.Value) {
  25105. if rv.Kind() == reflect.Ptr {
  25106. vp := rv2i(rv).(*map[uintptr]int8)
  25107. if v, changed := fastpathTV.DecMapUintptrInt8V(*vp, true, d); changed {
  25108. *vp = v
  25109. }
  25110. return
  25111. }
  25112. fastpathTV.DecMapUintptrInt8V(rv2i(rv).(map[uintptr]int8), false, d)
  25113. }
  25114. func (f fastpathT) DecMapUintptrInt8X(vp *map[uintptr]int8, d *Decoder) {
  25115. if v, changed := f.DecMapUintptrInt8V(*vp, true, d); changed {
  25116. *vp = v
  25117. }
  25118. }
  25119. func (_ fastpathT) DecMapUintptrInt8V(v map[uintptr]int8, canChange bool,
  25120. d *Decoder) (_ map[uintptr]int8, changed bool) {
  25121. dd, esep := d.d, d.hh.hasElemSeparators()
  25122. containerLen := dd.ReadMapStart()
  25123. if canChange && v == nil {
  25124. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  25125. v = make(map[uintptr]int8, xlen)
  25126. changed = true
  25127. }
  25128. if containerLen == 0 {
  25129. dd.ReadMapEnd()
  25130. return v, changed
  25131. }
  25132. var mk uintptr
  25133. var mv int8
  25134. hasLen := containerLen > 0
  25135. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25136. if esep {
  25137. dd.ReadMapElemKey()
  25138. }
  25139. mk = uintptr(dd.DecodeUint(uintBitsize))
  25140. if esep {
  25141. dd.ReadMapElemValue()
  25142. }
  25143. if dd.TryDecodeAsNil() {
  25144. if d.h.DeleteOnNilMapValue {
  25145. delete(v, mk)
  25146. } else {
  25147. v[mk] = 0
  25148. }
  25149. continue
  25150. }
  25151. mv = int8(dd.DecodeInt(8))
  25152. if v != nil {
  25153. v[mk] = mv
  25154. }
  25155. }
  25156. dd.ReadMapEnd()
  25157. return v, changed
  25158. }
  25159. func (d *Decoder) fastpathDecMapUintptrInt16R(f *codecFnInfo, rv reflect.Value) {
  25160. if rv.Kind() == reflect.Ptr {
  25161. vp := rv2i(rv).(*map[uintptr]int16)
  25162. if v, changed := fastpathTV.DecMapUintptrInt16V(*vp, true, d); changed {
  25163. *vp = v
  25164. }
  25165. return
  25166. }
  25167. fastpathTV.DecMapUintptrInt16V(rv2i(rv).(map[uintptr]int16), false, d)
  25168. }
  25169. func (f fastpathT) DecMapUintptrInt16X(vp *map[uintptr]int16, d *Decoder) {
  25170. if v, changed := f.DecMapUintptrInt16V(*vp, true, d); changed {
  25171. *vp = v
  25172. }
  25173. }
  25174. func (_ fastpathT) DecMapUintptrInt16V(v map[uintptr]int16, canChange bool,
  25175. d *Decoder) (_ map[uintptr]int16, changed bool) {
  25176. dd, esep := d.d, d.hh.hasElemSeparators()
  25177. containerLen := dd.ReadMapStart()
  25178. if canChange && v == nil {
  25179. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  25180. v = make(map[uintptr]int16, xlen)
  25181. changed = true
  25182. }
  25183. if containerLen == 0 {
  25184. dd.ReadMapEnd()
  25185. return v, changed
  25186. }
  25187. var mk uintptr
  25188. var mv int16
  25189. hasLen := containerLen > 0
  25190. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25191. if esep {
  25192. dd.ReadMapElemKey()
  25193. }
  25194. mk = uintptr(dd.DecodeUint(uintBitsize))
  25195. if esep {
  25196. dd.ReadMapElemValue()
  25197. }
  25198. if dd.TryDecodeAsNil() {
  25199. if d.h.DeleteOnNilMapValue {
  25200. delete(v, mk)
  25201. } else {
  25202. v[mk] = 0
  25203. }
  25204. continue
  25205. }
  25206. mv = int16(dd.DecodeInt(16))
  25207. if v != nil {
  25208. v[mk] = mv
  25209. }
  25210. }
  25211. dd.ReadMapEnd()
  25212. return v, changed
  25213. }
  25214. func (d *Decoder) fastpathDecMapUintptrInt32R(f *codecFnInfo, rv reflect.Value) {
  25215. if rv.Kind() == reflect.Ptr {
  25216. vp := rv2i(rv).(*map[uintptr]int32)
  25217. if v, changed := fastpathTV.DecMapUintptrInt32V(*vp, true, d); changed {
  25218. *vp = v
  25219. }
  25220. return
  25221. }
  25222. fastpathTV.DecMapUintptrInt32V(rv2i(rv).(map[uintptr]int32), false, d)
  25223. }
  25224. func (f fastpathT) DecMapUintptrInt32X(vp *map[uintptr]int32, d *Decoder) {
  25225. if v, changed := f.DecMapUintptrInt32V(*vp, true, d); changed {
  25226. *vp = v
  25227. }
  25228. }
  25229. func (_ fastpathT) DecMapUintptrInt32V(v map[uintptr]int32, canChange bool,
  25230. d *Decoder) (_ map[uintptr]int32, changed bool) {
  25231. dd, esep := d.d, d.hh.hasElemSeparators()
  25232. containerLen := dd.ReadMapStart()
  25233. if canChange && v == nil {
  25234. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  25235. v = make(map[uintptr]int32, xlen)
  25236. changed = true
  25237. }
  25238. if containerLen == 0 {
  25239. dd.ReadMapEnd()
  25240. return v, changed
  25241. }
  25242. var mk uintptr
  25243. var mv int32
  25244. hasLen := containerLen > 0
  25245. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25246. if esep {
  25247. dd.ReadMapElemKey()
  25248. }
  25249. mk = uintptr(dd.DecodeUint(uintBitsize))
  25250. if esep {
  25251. dd.ReadMapElemValue()
  25252. }
  25253. if dd.TryDecodeAsNil() {
  25254. if d.h.DeleteOnNilMapValue {
  25255. delete(v, mk)
  25256. } else {
  25257. v[mk] = 0
  25258. }
  25259. continue
  25260. }
  25261. mv = int32(dd.DecodeInt(32))
  25262. if v != nil {
  25263. v[mk] = mv
  25264. }
  25265. }
  25266. dd.ReadMapEnd()
  25267. return v, changed
  25268. }
  25269. func (d *Decoder) fastpathDecMapUintptrInt64R(f *codecFnInfo, rv reflect.Value) {
  25270. if rv.Kind() == reflect.Ptr {
  25271. vp := rv2i(rv).(*map[uintptr]int64)
  25272. if v, changed := fastpathTV.DecMapUintptrInt64V(*vp, true, d); changed {
  25273. *vp = v
  25274. }
  25275. return
  25276. }
  25277. fastpathTV.DecMapUintptrInt64V(rv2i(rv).(map[uintptr]int64), false, d)
  25278. }
  25279. func (f fastpathT) DecMapUintptrInt64X(vp *map[uintptr]int64, d *Decoder) {
  25280. if v, changed := f.DecMapUintptrInt64V(*vp, true, d); changed {
  25281. *vp = v
  25282. }
  25283. }
  25284. func (_ fastpathT) DecMapUintptrInt64V(v map[uintptr]int64, canChange bool,
  25285. d *Decoder) (_ map[uintptr]int64, changed bool) {
  25286. dd, esep := d.d, d.hh.hasElemSeparators()
  25287. containerLen := dd.ReadMapStart()
  25288. if canChange && v == nil {
  25289. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25290. v = make(map[uintptr]int64, xlen)
  25291. changed = true
  25292. }
  25293. if containerLen == 0 {
  25294. dd.ReadMapEnd()
  25295. return v, changed
  25296. }
  25297. var mk uintptr
  25298. var mv int64
  25299. hasLen := containerLen > 0
  25300. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25301. if esep {
  25302. dd.ReadMapElemKey()
  25303. }
  25304. mk = uintptr(dd.DecodeUint(uintBitsize))
  25305. if esep {
  25306. dd.ReadMapElemValue()
  25307. }
  25308. if dd.TryDecodeAsNil() {
  25309. if d.h.DeleteOnNilMapValue {
  25310. delete(v, mk)
  25311. } else {
  25312. v[mk] = 0
  25313. }
  25314. continue
  25315. }
  25316. mv = dd.DecodeInt(64)
  25317. if v != nil {
  25318. v[mk] = mv
  25319. }
  25320. }
  25321. dd.ReadMapEnd()
  25322. return v, changed
  25323. }
  25324. func (d *Decoder) fastpathDecMapUintptrFloat32R(f *codecFnInfo, rv reflect.Value) {
  25325. if rv.Kind() == reflect.Ptr {
  25326. vp := rv2i(rv).(*map[uintptr]float32)
  25327. if v, changed := fastpathTV.DecMapUintptrFloat32V(*vp, true, d); changed {
  25328. *vp = v
  25329. }
  25330. return
  25331. }
  25332. fastpathTV.DecMapUintptrFloat32V(rv2i(rv).(map[uintptr]float32), false, d)
  25333. }
  25334. func (f fastpathT) DecMapUintptrFloat32X(vp *map[uintptr]float32, d *Decoder) {
  25335. if v, changed := f.DecMapUintptrFloat32V(*vp, true, d); changed {
  25336. *vp = v
  25337. }
  25338. }
  25339. func (_ fastpathT) DecMapUintptrFloat32V(v map[uintptr]float32, canChange bool,
  25340. d *Decoder) (_ map[uintptr]float32, changed bool) {
  25341. dd, esep := d.d, d.hh.hasElemSeparators()
  25342. containerLen := dd.ReadMapStart()
  25343. if canChange && v == nil {
  25344. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  25345. v = make(map[uintptr]float32, xlen)
  25346. changed = true
  25347. }
  25348. if containerLen == 0 {
  25349. dd.ReadMapEnd()
  25350. return v, changed
  25351. }
  25352. var mk uintptr
  25353. var mv float32
  25354. hasLen := containerLen > 0
  25355. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25356. if esep {
  25357. dd.ReadMapElemKey()
  25358. }
  25359. mk = uintptr(dd.DecodeUint(uintBitsize))
  25360. if esep {
  25361. dd.ReadMapElemValue()
  25362. }
  25363. if dd.TryDecodeAsNil() {
  25364. if d.h.DeleteOnNilMapValue {
  25365. delete(v, mk)
  25366. } else {
  25367. v[mk] = 0
  25368. }
  25369. continue
  25370. }
  25371. mv = float32(dd.DecodeFloat(true))
  25372. if v != nil {
  25373. v[mk] = mv
  25374. }
  25375. }
  25376. dd.ReadMapEnd()
  25377. return v, changed
  25378. }
  25379. func (d *Decoder) fastpathDecMapUintptrFloat64R(f *codecFnInfo, rv reflect.Value) {
  25380. if rv.Kind() == reflect.Ptr {
  25381. vp := rv2i(rv).(*map[uintptr]float64)
  25382. if v, changed := fastpathTV.DecMapUintptrFloat64V(*vp, true, d); changed {
  25383. *vp = v
  25384. }
  25385. return
  25386. }
  25387. fastpathTV.DecMapUintptrFloat64V(rv2i(rv).(map[uintptr]float64), false, d)
  25388. }
  25389. func (f fastpathT) DecMapUintptrFloat64X(vp *map[uintptr]float64, d *Decoder) {
  25390. if v, changed := f.DecMapUintptrFloat64V(*vp, true, d); changed {
  25391. *vp = v
  25392. }
  25393. }
  25394. func (_ fastpathT) DecMapUintptrFloat64V(v map[uintptr]float64, canChange bool,
  25395. d *Decoder) (_ map[uintptr]float64, changed bool) {
  25396. dd, esep := d.d, d.hh.hasElemSeparators()
  25397. containerLen := dd.ReadMapStart()
  25398. if canChange && v == nil {
  25399. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25400. v = make(map[uintptr]float64, xlen)
  25401. changed = true
  25402. }
  25403. if containerLen == 0 {
  25404. dd.ReadMapEnd()
  25405. return v, changed
  25406. }
  25407. var mk uintptr
  25408. var mv float64
  25409. hasLen := containerLen > 0
  25410. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25411. if esep {
  25412. dd.ReadMapElemKey()
  25413. }
  25414. mk = uintptr(dd.DecodeUint(uintBitsize))
  25415. if esep {
  25416. dd.ReadMapElemValue()
  25417. }
  25418. if dd.TryDecodeAsNil() {
  25419. if d.h.DeleteOnNilMapValue {
  25420. delete(v, mk)
  25421. } else {
  25422. v[mk] = 0
  25423. }
  25424. continue
  25425. }
  25426. mv = dd.DecodeFloat(false)
  25427. if v != nil {
  25428. v[mk] = mv
  25429. }
  25430. }
  25431. dd.ReadMapEnd()
  25432. return v, changed
  25433. }
  25434. func (d *Decoder) fastpathDecMapUintptrBoolR(f *codecFnInfo, rv reflect.Value) {
  25435. if rv.Kind() == reflect.Ptr {
  25436. vp := rv2i(rv).(*map[uintptr]bool)
  25437. if v, changed := fastpathTV.DecMapUintptrBoolV(*vp, true, d); changed {
  25438. *vp = v
  25439. }
  25440. return
  25441. }
  25442. fastpathTV.DecMapUintptrBoolV(rv2i(rv).(map[uintptr]bool), false, d)
  25443. }
  25444. func (f fastpathT) DecMapUintptrBoolX(vp *map[uintptr]bool, d *Decoder) {
  25445. if v, changed := f.DecMapUintptrBoolV(*vp, true, d); changed {
  25446. *vp = v
  25447. }
  25448. }
  25449. func (_ fastpathT) DecMapUintptrBoolV(v map[uintptr]bool, canChange bool,
  25450. d *Decoder) (_ map[uintptr]bool, changed bool) {
  25451. dd, esep := d.d, d.hh.hasElemSeparators()
  25452. containerLen := dd.ReadMapStart()
  25453. if canChange && v == nil {
  25454. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  25455. v = make(map[uintptr]bool, xlen)
  25456. changed = true
  25457. }
  25458. if containerLen == 0 {
  25459. dd.ReadMapEnd()
  25460. return v, changed
  25461. }
  25462. var mk uintptr
  25463. var mv bool
  25464. hasLen := containerLen > 0
  25465. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25466. if esep {
  25467. dd.ReadMapElemKey()
  25468. }
  25469. mk = uintptr(dd.DecodeUint(uintBitsize))
  25470. if esep {
  25471. dd.ReadMapElemValue()
  25472. }
  25473. if dd.TryDecodeAsNil() {
  25474. if d.h.DeleteOnNilMapValue {
  25475. delete(v, mk)
  25476. } else {
  25477. v[mk] = false
  25478. }
  25479. continue
  25480. }
  25481. mv = dd.DecodeBool()
  25482. if v != nil {
  25483. v[mk] = mv
  25484. }
  25485. }
  25486. dd.ReadMapEnd()
  25487. return v, changed
  25488. }
  25489. func (d *Decoder) fastpathDecMapIntIntfR(f *codecFnInfo, rv reflect.Value) {
  25490. if rv.Kind() == reflect.Ptr {
  25491. vp := rv2i(rv).(*map[int]interface{})
  25492. if v, changed := fastpathTV.DecMapIntIntfV(*vp, true, d); changed {
  25493. *vp = v
  25494. }
  25495. return
  25496. }
  25497. fastpathTV.DecMapIntIntfV(rv2i(rv).(map[int]interface{}), false, d)
  25498. }
  25499. func (f fastpathT) DecMapIntIntfX(vp *map[int]interface{}, d *Decoder) {
  25500. if v, changed := f.DecMapIntIntfV(*vp, true, d); changed {
  25501. *vp = v
  25502. }
  25503. }
  25504. func (_ fastpathT) DecMapIntIntfV(v map[int]interface{}, canChange bool,
  25505. d *Decoder) (_ map[int]interface{}, changed bool) {
  25506. dd, esep := d.d, d.hh.hasElemSeparators()
  25507. containerLen := dd.ReadMapStart()
  25508. if canChange && v == nil {
  25509. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  25510. v = make(map[int]interface{}, xlen)
  25511. changed = true
  25512. }
  25513. if containerLen == 0 {
  25514. dd.ReadMapEnd()
  25515. return v, changed
  25516. }
  25517. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  25518. var mk int
  25519. var mv interface{}
  25520. hasLen := containerLen > 0
  25521. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25522. if esep {
  25523. dd.ReadMapElemKey()
  25524. }
  25525. mk = int(dd.DecodeInt(intBitsize))
  25526. if esep {
  25527. dd.ReadMapElemValue()
  25528. }
  25529. if dd.TryDecodeAsNil() {
  25530. if d.h.DeleteOnNilMapValue {
  25531. delete(v, mk)
  25532. } else {
  25533. v[mk] = nil
  25534. }
  25535. continue
  25536. }
  25537. if mapGet {
  25538. mv = v[mk]
  25539. } else {
  25540. mv = nil
  25541. }
  25542. d.decode(&mv)
  25543. if v != nil {
  25544. v[mk] = mv
  25545. }
  25546. }
  25547. dd.ReadMapEnd()
  25548. return v, changed
  25549. }
  25550. func (d *Decoder) fastpathDecMapIntStringR(f *codecFnInfo, rv reflect.Value) {
  25551. if rv.Kind() == reflect.Ptr {
  25552. vp := rv2i(rv).(*map[int]string)
  25553. if v, changed := fastpathTV.DecMapIntStringV(*vp, true, d); changed {
  25554. *vp = v
  25555. }
  25556. return
  25557. }
  25558. fastpathTV.DecMapIntStringV(rv2i(rv).(map[int]string), false, d)
  25559. }
  25560. func (f fastpathT) DecMapIntStringX(vp *map[int]string, d *Decoder) {
  25561. if v, changed := f.DecMapIntStringV(*vp, true, d); changed {
  25562. *vp = v
  25563. }
  25564. }
  25565. func (_ fastpathT) DecMapIntStringV(v map[int]string, canChange bool,
  25566. d *Decoder) (_ map[int]string, changed bool) {
  25567. dd, esep := d.d, d.hh.hasElemSeparators()
  25568. containerLen := dd.ReadMapStart()
  25569. if canChange && v == nil {
  25570. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  25571. v = make(map[int]string, xlen)
  25572. changed = true
  25573. }
  25574. if containerLen == 0 {
  25575. dd.ReadMapEnd()
  25576. return v, changed
  25577. }
  25578. var mk int
  25579. var mv string
  25580. hasLen := containerLen > 0
  25581. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25582. if esep {
  25583. dd.ReadMapElemKey()
  25584. }
  25585. mk = int(dd.DecodeInt(intBitsize))
  25586. if esep {
  25587. dd.ReadMapElemValue()
  25588. }
  25589. if dd.TryDecodeAsNil() {
  25590. if d.h.DeleteOnNilMapValue {
  25591. delete(v, mk)
  25592. } else {
  25593. v[mk] = ""
  25594. }
  25595. continue
  25596. }
  25597. mv = dd.DecodeString()
  25598. if v != nil {
  25599. v[mk] = mv
  25600. }
  25601. }
  25602. dd.ReadMapEnd()
  25603. return v, changed
  25604. }
  25605. func (d *Decoder) fastpathDecMapIntUintR(f *codecFnInfo, rv reflect.Value) {
  25606. if rv.Kind() == reflect.Ptr {
  25607. vp := rv2i(rv).(*map[int]uint)
  25608. if v, changed := fastpathTV.DecMapIntUintV(*vp, true, d); changed {
  25609. *vp = v
  25610. }
  25611. return
  25612. }
  25613. fastpathTV.DecMapIntUintV(rv2i(rv).(map[int]uint), false, d)
  25614. }
  25615. func (f fastpathT) DecMapIntUintX(vp *map[int]uint, d *Decoder) {
  25616. if v, changed := f.DecMapIntUintV(*vp, true, d); changed {
  25617. *vp = v
  25618. }
  25619. }
  25620. func (_ fastpathT) DecMapIntUintV(v map[int]uint, canChange bool,
  25621. d *Decoder) (_ map[int]uint, changed bool) {
  25622. dd, esep := d.d, d.hh.hasElemSeparators()
  25623. containerLen := dd.ReadMapStart()
  25624. if canChange && v == nil {
  25625. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25626. v = make(map[int]uint, xlen)
  25627. changed = true
  25628. }
  25629. if containerLen == 0 {
  25630. dd.ReadMapEnd()
  25631. return v, changed
  25632. }
  25633. var mk int
  25634. var mv uint
  25635. hasLen := containerLen > 0
  25636. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25637. if esep {
  25638. dd.ReadMapElemKey()
  25639. }
  25640. mk = int(dd.DecodeInt(intBitsize))
  25641. if esep {
  25642. dd.ReadMapElemValue()
  25643. }
  25644. if dd.TryDecodeAsNil() {
  25645. if d.h.DeleteOnNilMapValue {
  25646. delete(v, mk)
  25647. } else {
  25648. v[mk] = 0
  25649. }
  25650. continue
  25651. }
  25652. mv = uint(dd.DecodeUint(uintBitsize))
  25653. if v != nil {
  25654. v[mk] = mv
  25655. }
  25656. }
  25657. dd.ReadMapEnd()
  25658. return v, changed
  25659. }
  25660. func (d *Decoder) fastpathDecMapIntUint8R(f *codecFnInfo, rv reflect.Value) {
  25661. if rv.Kind() == reflect.Ptr {
  25662. vp := rv2i(rv).(*map[int]uint8)
  25663. if v, changed := fastpathTV.DecMapIntUint8V(*vp, true, d); changed {
  25664. *vp = v
  25665. }
  25666. return
  25667. }
  25668. fastpathTV.DecMapIntUint8V(rv2i(rv).(map[int]uint8), false, d)
  25669. }
  25670. func (f fastpathT) DecMapIntUint8X(vp *map[int]uint8, d *Decoder) {
  25671. if v, changed := f.DecMapIntUint8V(*vp, true, d); changed {
  25672. *vp = v
  25673. }
  25674. }
  25675. func (_ fastpathT) DecMapIntUint8V(v map[int]uint8, canChange bool,
  25676. d *Decoder) (_ map[int]uint8, changed bool) {
  25677. dd, esep := d.d, d.hh.hasElemSeparators()
  25678. containerLen := dd.ReadMapStart()
  25679. if canChange && v == nil {
  25680. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  25681. v = make(map[int]uint8, xlen)
  25682. changed = true
  25683. }
  25684. if containerLen == 0 {
  25685. dd.ReadMapEnd()
  25686. return v, changed
  25687. }
  25688. var mk int
  25689. var mv uint8
  25690. hasLen := containerLen > 0
  25691. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25692. if esep {
  25693. dd.ReadMapElemKey()
  25694. }
  25695. mk = int(dd.DecodeInt(intBitsize))
  25696. if esep {
  25697. dd.ReadMapElemValue()
  25698. }
  25699. if dd.TryDecodeAsNil() {
  25700. if d.h.DeleteOnNilMapValue {
  25701. delete(v, mk)
  25702. } else {
  25703. v[mk] = 0
  25704. }
  25705. continue
  25706. }
  25707. mv = uint8(dd.DecodeUint(8))
  25708. if v != nil {
  25709. v[mk] = mv
  25710. }
  25711. }
  25712. dd.ReadMapEnd()
  25713. return v, changed
  25714. }
  25715. func (d *Decoder) fastpathDecMapIntUint16R(f *codecFnInfo, rv reflect.Value) {
  25716. if rv.Kind() == reflect.Ptr {
  25717. vp := rv2i(rv).(*map[int]uint16)
  25718. if v, changed := fastpathTV.DecMapIntUint16V(*vp, true, d); changed {
  25719. *vp = v
  25720. }
  25721. return
  25722. }
  25723. fastpathTV.DecMapIntUint16V(rv2i(rv).(map[int]uint16), false, d)
  25724. }
  25725. func (f fastpathT) DecMapIntUint16X(vp *map[int]uint16, d *Decoder) {
  25726. if v, changed := f.DecMapIntUint16V(*vp, true, d); changed {
  25727. *vp = v
  25728. }
  25729. }
  25730. func (_ fastpathT) DecMapIntUint16V(v map[int]uint16, canChange bool,
  25731. d *Decoder) (_ map[int]uint16, changed bool) {
  25732. dd, esep := d.d, d.hh.hasElemSeparators()
  25733. containerLen := dd.ReadMapStart()
  25734. if canChange && v == nil {
  25735. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  25736. v = make(map[int]uint16, xlen)
  25737. changed = true
  25738. }
  25739. if containerLen == 0 {
  25740. dd.ReadMapEnd()
  25741. return v, changed
  25742. }
  25743. var mk int
  25744. var mv uint16
  25745. hasLen := containerLen > 0
  25746. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25747. if esep {
  25748. dd.ReadMapElemKey()
  25749. }
  25750. mk = int(dd.DecodeInt(intBitsize))
  25751. if esep {
  25752. dd.ReadMapElemValue()
  25753. }
  25754. if dd.TryDecodeAsNil() {
  25755. if d.h.DeleteOnNilMapValue {
  25756. delete(v, mk)
  25757. } else {
  25758. v[mk] = 0
  25759. }
  25760. continue
  25761. }
  25762. mv = uint16(dd.DecodeUint(16))
  25763. if v != nil {
  25764. v[mk] = mv
  25765. }
  25766. }
  25767. dd.ReadMapEnd()
  25768. return v, changed
  25769. }
  25770. func (d *Decoder) fastpathDecMapIntUint32R(f *codecFnInfo, rv reflect.Value) {
  25771. if rv.Kind() == reflect.Ptr {
  25772. vp := rv2i(rv).(*map[int]uint32)
  25773. if v, changed := fastpathTV.DecMapIntUint32V(*vp, true, d); changed {
  25774. *vp = v
  25775. }
  25776. return
  25777. }
  25778. fastpathTV.DecMapIntUint32V(rv2i(rv).(map[int]uint32), false, d)
  25779. }
  25780. func (f fastpathT) DecMapIntUint32X(vp *map[int]uint32, d *Decoder) {
  25781. if v, changed := f.DecMapIntUint32V(*vp, true, d); changed {
  25782. *vp = v
  25783. }
  25784. }
  25785. func (_ fastpathT) DecMapIntUint32V(v map[int]uint32, canChange bool,
  25786. d *Decoder) (_ map[int]uint32, changed bool) {
  25787. dd, esep := d.d, d.hh.hasElemSeparators()
  25788. containerLen := dd.ReadMapStart()
  25789. if canChange && v == nil {
  25790. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  25791. v = make(map[int]uint32, xlen)
  25792. changed = true
  25793. }
  25794. if containerLen == 0 {
  25795. dd.ReadMapEnd()
  25796. return v, changed
  25797. }
  25798. var mk int
  25799. var mv uint32
  25800. hasLen := containerLen > 0
  25801. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25802. if esep {
  25803. dd.ReadMapElemKey()
  25804. }
  25805. mk = int(dd.DecodeInt(intBitsize))
  25806. if esep {
  25807. dd.ReadMapElemValue()
  25808. }
  25809. if dd.TryDecodeAsNil() {
  25810. if d.h.DeleteOnNilMapValue {
  25811. delete(v, mk)
  25812. } else {
  25813. v[mk] = 0
  25814. }
  25815. continue
  25816. }
  25817. mv = uint32(dd.DecodeUint(32))
  25818. if v != nil {
  25819. v[mk] = mv
  25820. }
  25821. }
  25822. dd.ReadMapEnd()
  25823. return v, changed
  25824. }
  25825. func (d *Decoder) fastpathDecMapIntUint64R(f *codecFnInfo, rv reflect.Value) {
  25826. if rv.Kind() == reflect.Ptr {
  25827. vp := rv2i(rv).(*map[int]uint64)
  25828. if v, changed := fastpathTV.DecMapIntUint64V(*vp, true, d); changed {
  25829. *vp = v
  25830. }
  25831. return
  25832. }
  25833. fastpathTV.DecMapIntUint64V(rv2i(rv).(map[int]uint64), false, d)
  25834. }
  25835. func (f fastpathT) DecMapIntUint64X(vp *map[int]uint64, d *Decoder) {
  25836. if v, changed := f.DecMapIntUint64V(*vp, true, d); changed {
  25837. *vp = v
  25838. }
  25839. }
  25840. func (_ fastpathT) DecMapIntUint64V(v map[int]uint64, canChange bool,
  25841. d *Decoder) (_ map[int]uint64, changed bool) {
  25842. dd, esep := d.d, d.hh.hasElemSeparators()
  25843. containerLen := dd.ReadMapStart()
  25844. if canChange && v == nil {
  25845. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25846. v = make(map[int]uint64, xlen)
  25847. changed = true
  25848. }
  25849. if containerLen == 0 {
  25850. dd.ReadMapEnd()
  25851. return v, changed
  25852. }
  25853. var mk int
  25854. var mv uint64
  25855. hasLen := containerLen > 0
  25856. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25857. if esep {
  25858. dd.ReadMapElemKey()
  25859. }
  25860. mk = int(dd.DecodeInt(intBitsize))
  25861. if esep {
  25862. dd.ReadMapElemValue()
  25863. }
  25864. if dd.TryDecodeAsNil() {
  25865. if d.h.DeleteOnNilMapValue {
  25866. delete(v, mk)
  25867. } else {
  25868. v[mk] = 0
  25869. }
  25870. continue
  25871. }
  25872. mv = dd.DecodeUint(64)
  25873. if v != nil {
  25874. v[mk] = mv
  25875. }
  25876. }
  25877. dd.ReadMapEnd()
  25878. return v, changed
  25879. }
  25880. func (d *Decoder) fastpathDecMapIntUintptrR(f *codecFnInfo, rv reflect.Value) {
  25881. if rv.Kind() == reflect.Ptr {
  25882. vp := rv2i(rv).(*map[int]uintptr)
  25883. if v, changed := fastpathTV.DecMapIntUintptrV(*vp, true, d); changed {
  25884. *vp = v
  25885. }
  25886. return
  25887. }
  25888. fastpathTV.DecMapIntUintptrV(rv2i(rv).(map[int]uintptr), false, d)
  25889. }
  25890. func (f fastpathT) DecMapIntUintptrX(vp *map[int]uintptr, d *Decoder) {
  25891. if v, changed := f.DecMapIntUintptrV(*vp, true, d); changed {
  25892. *vp = v
  25893. }
  25894. }
  25895. func (_ fastpathT) DecMapIntUintptrV(v map[int]uintptr, canChange bool,
  25896. d *Decoder) (_ map[int]uintptr, changed bool) {
  25897. dd, esep := d.d, d.hh.hasElemSeparators()
  25898. containerLen := dd.ReadMapStart()
  25899. if canChange && v == nil {
  25900. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25901. v = make(map[int]uintptr, xlen)
  25902. changed = true
  25903. }
  25904. if containerLen == 0 {
  25905. dd.ReadMapEnd()
  25906. return v, changed
  25907. }
  25908. var mk int
  25909. var mv uintptr
  25910. hasLen := containerLen > 0
  25911. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25912. if esep {
  25913. dd.ReadMapElemKey()
  25914. }
  25915. mk = int(dd.DecodeInt(intBitsize))
  25916. if esep {
  25917. dd.ReadMapElemValue()
  25918. }
  25919. if dd.TryDecodeAsNil() {
  25920. if d.h.DeleteOnNilMapValue {
  25921. delete(v, mk)
  25922. } else {
  25923. v[mk] = 0
  25924. }
  25925. continue
  25926. }
  25927. mv = uintptr(dd.DecodeUint(uintBitsize))
  25928. if v != nil {
  25929. v[mk] = mv
  25930. }
  25931. }
  25932. dd.ReadMapEnd()
  25933. return v, changed
  25934. }
  25935. func (d *Decoder) fastpathDecMapIntIntR(f *codecFnInfo, rv reflect.Value) {
  25936. if rv.Kind() == reflect.Ptr {
  25937. vp := rv2i(rv).(*map[int]int)
  25938. if v, changed := fastpathTV.DecMapIntIntV(*vp, true, d); changed {
  25939. *vp = v
  25940. }
  25941. return
  25942. }
  25943. fastpathTV.DecMapIntIntV(rv2i(rv).(map[int]int), false, d)
  25944. }
  25945. func (f fastpathT) DecMapIntIntX(vp *map[int]int, d *Decoder) {
  25946. if v, changed := f.DecMapIntIntV(*vp, true, d); changed {
  25947. *vp = v
  25948. }
  25949. }
  25950. func (_ fastpathT) DecMapIntIntV(v map[int]int, canChange bool,
  25951. d *Decoder) (_ map[int]int, changed bool) {
  25952. dd, esep := d.d, d.hh.hasElemSeparators()
  25953. containerLen := dd.ReadMapStart()
  25954. if canChange && v == nil {
  25955. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  25956. v = make(map[int]int, xlen)
  25957. changed = true
  25958. }
  25959. if containerLen == 0 {
  25960. dd.ReadMapEnd()
  25961. return v, changed
  25962. }
  25963. var mk int
  25964. var mv int
  25965. hasLen := containerLen > 0
  25966. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  25967. if esep {
  25968. dd.ReadMapElemKey()
  25969. }
  25970. mk = int(dd.DecodeInt(intBitsize))
  25971. if esep {
  25972. dd.ReadMapElemValue()
  25973. }
  25974. if dd.TryDecodeAsNil() {
  25975. if d.h.DeleteOnNilMapValue {
  25976. delete(v, mk)
  25977. } else {
  25978. v[mk] = 0
  25979. }
  25980. continue
  25981. }
  25982. mv = int(dd.DecodeInt(intBitsize))
  25983. if v != nil {
  25984. v[mk] = mv
  25985. }
  25986. }
  25987. dd.ReadMapEnd()
  25988. return v, changed
  25989. }
  25990. func (d *Decoder) fastpathDecMapIntInt8R(f *codecFnInfo, rv reflect.Value) {
  25991. if rv.Kind() == reflect.Ptr {
  25992. vp := rv2i(rv).(*map[int]int8)
  25993. if v, changed := fastpathTV.DecMapIntInt8V(*vp, true, d); changed {
  25994. *vp = v
  25995. }
  25996. return
  25997. }
  25998. fastpathTV.DecMapIntInt8V(rv2i(rv).(map[int]int8), false, d)
  25999. }
  26000. func (f fastpathT) DecMapIntInt8X(vp *map[int]int8, d *Decoder) {
  26001. if v, changed := f.DecMapIntInt8V(*vp, true, d); changed {
  26002. *vp = v
  26003. }
  26004. }
  26005. func (_ fastpathT) DecMapIntInt8V(v map[int]int8, canChange bool,
  26006. d *Decoder) (_ map[int]int8, changed bool) {
  26007. dd, esep := d.d, d.hh.hasElemSeparators()
  26008. containerLen := dd.ReadMapStart()
  26009. if canChange && v == nil {
  26010. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  26011. v = make(map[int]int8, xlen)
  26012. changed = true
  26013. }
  26014. if containerLen == 0 {
  26015. dd.ReadMapEnd()
  26016. return v, changed
  26017. }
  26018. var mk int
  26019. var mv int8
  26020. hasLen := containerLen > 0
  26021. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26022. if esep {
  26023. dd.ReadMapElemKey()
  26024. }
  26025. mk = int(dd.DecodeInt(intBitsize))
  26026. if esep {
  26027. dd.ReadMapElemValue()
  26028. }
  26029. if dd.TryDecodeAsNil() {
  26030. if d.h.DeleteOnNilMapValue {
  26031. delete(v, mk)
  26032. } else {
  26033. v[mk] = 0
  26034. }
  26035. continue
  26036. }
  26037. mv = int8(dd.DecodeInt(8))
  26038. if v != nil {
  26039. v[mk] = mv
  26040. }
  26041. }
  26042. dd.ReadMapEnd()
  26043. return v, changed
  26044. }
  26045. func (d *Decoder) fastpathDecMapIntInt16R(f *codecFnInfo, rv reflect.Value) {
  26046. if rv.Kind() == reflect.Ptr {
  26047. vp := rv2i(rv).(*map[int]int16)
  26048. if v, changed := fastpathTV.DecMapIntInt16V(*vp, true, d); changed {
  26049. *vp = v
  26050. }
  26051. return
  26052. }
  26053. fastpathTV.DecMapIntInt16V(rv2i(rv).(map[int]int16), false, d)
  26054. }
  26055. func (f fastpathT) DecMapIntInt16X(vp *map[int]int16, d *Decoder) {
  26056. if v, changed := f.DecMapIntInt16V(*vp, true, d); changed {
  26057. *vp = v
  26058. }
  26059. }
  26060. func (_ fastpathT) DecMapIntInt16V(v map[int]int16, canChange bool,
  26061. d *Decoder) (_ map[int]int16, changed bool) {
  26062. dd, esep := d.d, d.hh.hasElemSeparators()
  26063. containerLen := dd.ReadMapStart()
  26064. if canChange && v == nil {
  26065. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  26066. v = make(map[int]int16, xlen)
  26067. changed = true
  26068. }
  26069. if containerLen == 0 {
  26070. dd.ReadMapEnd()
  26071. return v, changed
  26072. }
  26073. var mk int
  26074. var mv int16
  26075. hasLen := containerLen > 0
  26076. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26077. if esep {
  26078. dd.ReadMapElemKey()
  26079. }
  26080. mk = int(dd.DecodeInt(intBitsize))
  26081. if esep {
  26082. dd.ReadMapElemValue()
  26083. }
  26084. if dd.TryDecodeAsNil() {
  26085. if d.h.DeleteOnNilMapValue {
  26086. delete(v, mk)
  26087. } else {
  26088. v[mk] = 0
  26089. }
  26090. continue
  26091. }
  26092. mv = int16(dd.DecodeInt(16))
  26093. if v != nil {
  26094. v[mk] = mv
  26095. }
  26096. }
  26097. dd.ReadMapEnd()
  26098. return v, changed
  26099. }
  26100. func (d *Decoder) fastpathDecMapIntInt32R(f *codecFnInfo, rv reflect.Value) {
  26101. if rv.Kind() == reflect.Ptr {
  26102. vp := rv2i(rv).(*map[int]int32)
  26103. if v, changed := fastpathTV.DecMapIntInt32V(*vp, true, d); changed {
  26104. *vp = v
  26105. }
  26106. return
  26107. }
  26108. fastpathTV.DecMapIntInt32V(rv2i(rv).(map[int]int32), false, d)
  26109. }
  26110. func (f fastpathT) DecMapIntInt32X(vp *map[int]int32, d *Decoder) {
  26111. if v, changed := f.DecMapIntInt32V(*vp, true, d); changed {
  26112. *vp = v
  26113. }
  26114. }
  26115. func (_ fastpathT) DecMapIntInt32V(v map[int]int32, canChange bool,
  26116. d *Decoder) (_ map[int]int32, changed bool) {
  26117. dd, esep := d.d, d.hh.hasElemSeparators()
  26118. containerLen := dd.ReadMapStart()
  26119. if canChange && v == nil {
  26120. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  26121. v = make(map[int]int32, xlen)
  26122. changed = true
  26123. }
  26124. if containerLen == 0 {
  26125. dd.ReadMapEnd()
  26126. return v, changed
  26127. }
  26128. var mk int
  26129. var mv int32
  26130. hasLen := containerLen > 0
  26131. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26132. if esep {
  26133. dd.ReadMapElemKey()
  26134. }
  26135. mk = int(dd.DecodeInt(intBitsize))
  26136. if esep {
  26137. dd.ReadMapElemValue()
  26138. }
  26139. if dd.TryDecodeAsNil() {
  26140. if d.h.DeleteOnNilMapValue {
  26141. delete(v, mk)
  26142. } else {
  26143. v[mk] = 0
  26144. }
  26145. continue
  26146. }
  26147. mv = int32(dd.DecodeInt(32))
  26148. if v != nil {
  26149. v[mk] = mv
  26150. }
  26151. }
  26152. dd.ReadMapEnd()
  26153. return v, changed
  26154. }
  26155. func (d *Decoder) fastpathDecMapIntInt64R(f *codecFnInfo, rv reflect.Value) {
  26156. if rv.Kind() == reflect.Ptr {
  26157. vp := rv2i(rv).(*map[int]int64)
  26158. if v, changed := fastpathTV.DecMapIntInt64V(*vp, true, d); changed {
  26159. *vp = v
  26160. }
  26161. return
  26162. }
  26163. fastpathTV.DecMapIntInt64V(rv2i(rv).(map[int]int64), false, d)
  26164. }
  26165. func (f fastpathT) DecMapIntInt64X(vp *map[int]int64, d *Decoder) {
  26166. if v, changed := f.DecMapIntInt64V(*vp, true, d); changed {
  26167. *vp = v
  26168. }
  26169. }
  26170. func (_ fastpathT) DecMapIntInt64V(v map[int]int64, canChange bool,
  26171. d *Decoder) (_ map[int]int64, changed bool) {
  26172. dd, esep := d.d, d.hh.hasElemSeparators()
  26173. containerLen := dd.ReadMapStart()
  26174. if canChange && v == nil {
  26175. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  26176. v = make(map[int]int64, xlen)
  26177. changed = true
  26178. }
  26179. if containerLen == 0 {
  26180. dd.ReadMapEnd()
  26181. return v, changed
  26182. }
  26183. var mk int
  26184. var mv int64
  26185. hasLen := containerLen > 0
  26186. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26187. if esep {
  26188. dd.ReadMapElemKey()
  26189. }
  26190. mk = int(dd.DecodeInt(intBitsize))
  26191. if esep {
  26192. dd.ReadMapElemValue()
  26193. }
  26194. if dd.TryDecodeAsNil() {
  26195. if d.h.DeleteOnNilMapValue {
  26196. delete(v, mk)
  26197. } else {
  26198. v[mk] = 0
  26199. }
  26200. continue
  26201. }
  26202. mv = dd.DecodeInt(64)
  26203. if v != nil {
  26204. v[mk] = mv
  26205. }
  26206. }
  26207. dd.ReadMapEnd()
  26208. return v, changed
  26209. }
  26210. func (d *Decoder) fastpathDecMapIntFloat32R(f *codecFnInfo, rv reflect.Value) {
  26211. if rv.Kind() == reflect.Ptr {
  26212. vp := rv2i(rv).(*map[int]float32)
  26213. if v, changed := fastpathTV.DecMapIntFloat32V(*vp, true, d); changed {
  26214. *vp = v
  26215. }
  26216. return
  26217. }
  26218. fastpathTV.DecMapIntFloat32V(rv2i(rv).(map[int]float32), false, d)
  26219. }
  26220. func (f fastpathT) DecMapIntFloat32X(vp *map[int]float32, d *Decoder) {
  26221. if v, changed := f.DecMapIntFloat32V(*vp, true, d); changed {
  26222. *vp = v
  26223. }
  26224. }
  26225. func (_ fastpathT) DecMapIntFloat32V(v map[int]float32, canChange bool,
  26226. d *Decoder) (_ map[int]float32, changed bool) {
  26227. dd, esep := d.d, d.hh.hasElemSeparators()
  26228. containerLen := dd.ReadMapStart()
  26229. if canChange && v == nil {
  26230. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  26231. v = make(map[int]float32, xlen)
  26232. changed = true
  26233. }
  26234. if containerLen == 0 {
  26235. dd.ReadMapEnd()
  26236. return v, changed
  26237. }
  26238. var mk int
  26239. var mv float32
  26240. hasLen := containerLen > 0
  26241. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26242. if esep {
  26243. dd.ReadMapElemKey()
  26244. }
  26245. mk = int(dd.DecodeInt(intBitsize))
  26246. if esep {
  26247. dd.ReadMapElemValue()
  26248. }
  26249. if dd.TryDecodeAsNil() {
  26250. if d.h.DeleteOnNilMapValue {
  26251. delete(v, mk)
  26252. } else {
  26253. v[mk] = 0
  26254. }
  26255. continue
  26256. }
  26257. mv = float32(dd.DecodeFloat(true))
  26258. if v != nil {
  26259. v[mk] = mv
  26260. }
  26261. }
  26262. dd.ReadMapEnd()
  26263. return v, changed
  26264. }
  26265. func (d *Decoder) fastpathDecMapIntFloat64R(f *codecFnInfo, rv reflect.Value) {
  26266. if rv.Kind() == reflect.Ptr {
  26267. vp := rv2i(rv).(*map[int]float64)
  26268. if v, changed := fastpathTV.DecMapIntFloat64V(*vp, true, d); changed {
  26269. *vp = v
  26270. }
  26271. return
  26272. }
  26273. fastpathTV.DecMapIntFloat64V(rv2i(rv).(map[int]float64), false, d)
  26274. }
  26275. func (f fastpathT) DecMapIntFloat64X(vp *map[int]float64, d *Decoder) {
  26276. if v, changed := f.DecMapIntFloat64V(*vp, true, d); changed {
  26277. *vp = v
  26278. }
  26279. }
  26280. func (_ fastpathT) DecMapIntFloat64V(v map[int]float64, canChange bool,
  26281. d *Decoder) (_ map[int]float64, changed bool) {
  26282. dd, esep := d.d, d.hh.hasElemSeparators()
  26283. containerLen := dd.ReadMapStart()
  26284. if canChange && v == nil {
  26285. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  26286. v = make(map[int]float64, xlen)
  26287. changed = true
  26288. }
  26289. if containerLen == 0 {
  26290. dd.ReadMapEnd()
  26291. return v, changed
  26292. }
  26293. var mk int
  26294. var mv float64
  26295. hasLen := containerLen > 0
  26296. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26297. if esep {
  26298. dd.ReadMapElemKey()
  26299. }
  26300. mk = int(dd.DecodeInt(intBitsize))
  26301. if esep {
  26302. dd.ReadMapElemValue()
  26303. }
  26304. if dd.TryDecodeAsNil() {
  26305. if d.h.DeleteOnNilMapValue {
  26306. delete(v, mk)
  26307. } else {
  26308. v[mk] = 0
  26309. }
  26310. continue
  26311. }
  26312. mv = dd.DecodeFloat(false)
  26313. if v != nil {
  26314. v[mk] = mv
  26315. }
  26316. }
  26317. dd.ReadMapEnd()
  26318. return v, changed
  26319. }
  26320. func (d *Decoder) fastpathDecMapIntBoolR(f *codecFnInfo, rv reflect.Value) {
  26321. if rv.Kind() == reflect.Ptr {
  26322. vp := rv2i(rv).(*map[int]bool)
  26323. if v, changed := fastpathTV.DecMapIntBoolV(*vp, true, d); changed {
  26324. *vp = v
  26325. }
  26326. return
  26327. }
  26328. fastpathTV.DecMapIntBoolV(rv2i(rv).(map[int]bool), false, d)
  26329. }
  26330. func (f fastpathT) DecMapIntBoolX(vp *map[int]bool, d *Decoder) {
  26331. if v, changed := f.DecMapIntBoolV(*vp, true, d); changed {
  26332. *vp = v
  26333. }
  26334. }
  26335. func (_ fastpathT) DecMapIntBoolV(v map[int]bool, canChange bool,
  26336. d *Decoder) (_ map[int]bool, changed bool) {
  26337. dd, esep := d.d, d.hh.hasElemSeparators()
  26338. containerLen := dd.ReadMapStart()
  26339. if canChange && v == nil {
  26340. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  26341. v = make(map[int]bool, xlen)
  26342. changed = true
  26343. }
  26344. if containerLen == 0 {
  26345. dd.ReadMapEnd()
  26346. return v, changed
  26347. }
  26348. var mk int
  26349. var mv bool
  26350. hasLen := containerLen > 0
  26351. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26352. if esep {
  26353. dd.ReadMapElemKey()
  26354. }
  26355. mk = int(dd.DecodeInt(intBitsize))
  26356. if esep {
  26357. dd.ReadMapElemValue()
  26358. }
  26359. if dd.TryDecodeAsNil() {
  26360. if d.h.DeleteOnNilMapValue {
  26361. delete(v, mk)
  26362. } else {
  26363. v[mk] = false
  26364. }
  26365. continue
  26366. }
  26367. mv = dd.DecodeBool()
  26368. if v != nil {
  26369. v[mk] = mv
  26370. }
  26371. }
  26372. dd.ReadMapEnd()
  26373. return v, changed
  26374. }
  26375. func (d *Decoder) fastpathDecMapInt8IntfR(f *codecFnInfo, rv reflect.Value) {
  26376. if rv.Kind() == reflect.Ptr {
  26377. vp := rv2i(rv).(*map[int8]interface{})
  26378. if v, changed := fastpathTV.DecMapInt8IntfV(*vp, true, d); changed {
  26379. *vp = v
  26380. }
  26381. return
  26382. }
  26383. fastpathTV.DecMapInt8IntfV(rv2i(rv).(map[int8]interface{}), false, d)
  26384. }
  26385. func (f fastpathT) DecMapInt8IntfX(vp *map[int8]interface{}, d *Decoder) {
  26386. if v, changed := f.DecMapInt8IntfV(*vp, true, d); changed {
  26387. *vp = v
  26388. }
  26389. }
  26390. func (_ fastpathT) DecMapInt8IntfV(v map[int8]interface{}, canChange bool,
  26391. d *Decoder) (_ map[int8]interface{}, changed bool) {
  26392. dd, esep := d.d, d.hh.hasElemSeparators()
  26393. containerLen := dd.ReadMapStart()
  26394. if canChange && v == nil {
  26395. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  26396. v = make(map[int8]interface{}, xlen)
  26397. changed = true
  26398. }
  26399. if containerLen == 0 {
  26400. dd.ReadMapEnd()
  26401. return v, changed
  26402. }
  26403. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  26404. var mk int8
  26405. var mv interface{}
  26406. hasLen := containerLen > 0
  26407. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26408. if esep {
  26409. dd.ReadMapElemKey()
  26410. }
  26411. mk = int8(dd.DecodeInt(8))
  26412. if esep {
  26413. dd.ReadMapElemValue()
  26414. }
  26415. if dd.TryDecodeAsNil() {
  26416. if d.h.DeleteOnNilMapValue {
  26417. delete(v, mk)
  26418. } else {
  26419. v[mk] = nil
  26420. }
  26421. continue
  26422. }
  26423. if mapGet {
  26424. mv = v[mk]
  26425. } else {
  26426. mv = nil
  26427. }
  26428. d.decode(&mv)
  26429. if v != nil {
  26430. v[mk] = mv
  26431. }
  26432. }
  26433. dd.ReadMapEnd()
  26434. return v, changed
  26435. }
  26436. func (d *Decoder) fastpathDecMapInt8StringR(f *codecFnInfo, rv reflect.Value) {
  26437. if rv.Kind() == reflect.Ptr {
  26438. vp := rv2i(rv).(*map[int8]string)
  26439. if v, changed := fastpathTV.DecMapInt8StringV(*vp, true, d); changed {
  26440. *vp = v
  26441. }
  26442. return
  26443. }
  26444. fastpathTV.DecMapInt8StringV(rv2i(rv).(map[int8]string), false, d)
  26445. }
  26446. func (f fastpathT) DecMapInt8StringX(vp *map[int8]string, d *Decoder) {
  26447. if v, changed := f.DecMapInt8StringV(*vp, true, d); changed {
  26448. *vp = v
  26449. }
  26450. }
  26451. func (_ fastpathT) DecMapInt8StringV(v map[int8]string, canChange bool,
  26452. d *Decoder) (_ map[int8]string, changed bool) {
  26453. dd, esep := d.d, d.hh.hasElemSeparators()
  26454. containerLen := dd.ReadMapStart()
  26455. if canChange && v == nil {
  26456. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  26457. v = make(map[int8]string, xlen)
  26458. changed = true
  26459. }
  26460. if containerLen == 0 {
  26461. dd.ReadMapEnd()
  26462. return v, changed
  26463. }
  26464. var mk int8
  26465. var mv string
  26466. hasLen := containerLen > 0
  26467. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26468. if esep {
  26469. dd.ReadMapElemKey()
  26470. }
  26471. mk = int8(dd.DecodeInt(8))
  26472. if esep {
  26473. dd.ReadMapElemValue()
  26474. }
  26475. if dd.TryDecodeAsNil() {
  26476. if d.h.DeleteOnNilMapValue {
  26477. delete(v, mk)
  26478. } else {
  26479. v[mk] = ""
  26480. }
  26481. continue
  26482. }
  26483. mv = dd.DecodeString()
  26484. if v != nil {
  26485. v[mk] = mv
  26486. }
  26487. }
  26488. dd.ReadMapEnd()
  26489. return v, changed
  26490. }
  26491. func (d *Decoder) fastpathDecMapInt8UintR(f *codecFnInfo, rv reflect.Value) {
  26492. if rv.Kind() == reflect.Ptr {
  26493. vp := rv2i(rv).(*map[int8]uint)
  26494. if v, changed := fastpathTV.DecMapInt8UintV(*vp, true, d); changed {
  26495. *vp = v
  26496. }
  26497. return
  26498. }
  26499. fastpathTV.DecMapInt8UintV(rv2i(rv).(map[int8]uint), false, d)
  26500. }
  26501. func (f fastpathT) DecMapInt8UintX(vp *map[int8]uint, d *Decoder) {
  26502. if v, changed := f.DecMapInt8UintV(*vp, true, d); changed {
  26503. *vp = v
  26504. }
  26505. }
  26506. func (_ fastpathT) DecMapInt8UintV(v map[int8]uint, canChange bool,
  26507. d *Decoder) (_ map[int8]uint, changed bool) {
  26508. dd, esep := d.d, d.hh.hasElemSeparators()
  26509. containerLen := dd.ReadMapStart()
  26510. if canChange && v == nil {
  26511. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  26512. v = make(map[int8]uint, xlen)
  26513. changed = true
  26514. }
  26515. if containerLen == 0 {
  26516. dd.ReadMapEnd()
  26517. return v, changed
  26518. }
  26519. var mk int8
  26520. var mv uint
  26521. hasLen := containerLen > 0
  26522. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26523. if esep {
  26524. dd.ReadMapElemKey()
  26525. }
  26526. mk = int8(dd.DecodeInt(8))
  26527. if esep {
  26528. dd.ReadMapElemValue()
  26529. }
  26530. if dd.TryDecodeAsNil() {
  26531. if d.h.DeleteOnNilMapValue {
  26532. delete(v, mk)
  26533. } else {
  26534. v[mk] = 0
  26535. }
  26536. continue
  26537. }
  26538. mv = uint(dd.DecodeUint(uintBitsize))
  26539. if v != nil {
  26540. v[mk] = mv
  26541. }
  26542. }
  26543. dd.ReadMapEnd()
  26544. return v, changed
  26545. }
  26546. func (d *Decoder) fastpathDecMapInt8Uint8R(f *codecFnInfo, rv reflect.Value) {
  26547. if rv.Kind() == reflect.Ptr {
  26548. vp := rv2i(rv).(*map[int8]uint8)
  26549. if v, changed := fastpathTV.DecMapInt8Uint8V(*vp, true, d); changed {
  26550. *vp = v
  26551. }
  26552. return
  26553. }
  26554. fastpathTV.DecMapInt8Uint8V(rv2i(rv).(map[int8]uint8), false, d)
  26555. }
  26556. func (f fastpathT) DecMapInt8Uint8X(vp *map[int8]uint8, d *Decoder) {
  26557. if v, changed := f.DecMapInt8Uint8V(*vp, true, d); changed {
  26558. *vp = v
  26559. }
  26560. }
  26561. func (_ fastpathT) DecMapInt8Uint8V(v map[int8]uint8, canChange bool,
  26562. d *Decoder) (_ map[int8]uint8, changed bool) {
  26563. dd, esep := d.d, d.hh.hasElemSeparators()
  26564. containerLen := dd.ReadMapStart()
  26565. if canChange && v == nil {
  26566. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  26567. v = make(map[int8]uint8, xlen)
  26568. changed = true
  26569. }
  26570. if containerLen == 0 {
  26571. dd.ReadMapEnd()
  26572. return v, changed
  26573. }
  26574. var mk int8
  26575. var mv uint8
  26576. hasLen := containerLen > 0
  26577. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26578. if esep {
  26579. dd.ReadMapElemKey()
  26580. }
  26581. mk = int8(dd.DecodeInt(8))
  26582. if esep {
  26583. dd.ReadMapElemValue()
  26584. }
  26585. if dd.TryDecodeAsNil() {
  26586. if d.h.DeleteOnNilMapValue {
  26587. delete(v, mk)
  26588. } else {
  26589. v[mk] = 0
  26590. }
  26591. continue
  26592. }
  26593. mv = uint8(dd.DecodeUint(8))
  26594. if v != nil {
  26595. v[mk] = mv
  26596. }
  26597. }
  26598. dd.ReadMapEnd()
  26599. return v, changed
  26600. }
  26601. func (d *Decoder) fastpathDecMapInt8Uint16R(f *codecFnInfo, rv reflect.Value) {
  26602. if rv.Kind() == reflect.Ptr {
  26603. vp := rv2i(rv).(*map[int8]uint16)
  26604. if v, changed := fastpathTV.DecMapInt8Uint16V(*vp, true, d); changed {
  26605. *vp = v
  26606. }
  26607. return
  26608. }
  26609. fastpathTV.DecMapInt8Uint16V(rv2i(rv).(map[int8]uint16), false, d)
  26610. }
  26611. func (f fastpathT) DecMapInt8Uint16X(vp *map[int8]uint16, d *Decoder) {
  26612. if v, changed := f.DecMapInt8Uint16V(*vp, true, d); changed {
  26613. *vp = v
  26614. }
  26615. }
  26616. func (_ fastpathT) DecMapInt8Uint16V(v map[int8]uint16, canChange bool,
  26617. d *Decoder) (_ map[int8]uint16, changed bool) {
  26618. dd, esep := d.d, d.hh.hasElemSeparators()
  26619. containerLen := dd.ReadMapStart()
  26620. if canChange && v == nil {
  26621. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  26622. v = make(map[int8]uint16, xlen)
  26623. changed = true
  26624. }
  26625. if containerLen == 0 {
  26626. dd.ReadMapEnd()
  26627. return v, changed
  26628. }
  26629. var mk int8
  26630. var mv uint16
  26631. hasLen := containerLen > 0
  26632. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26633. if esep {
  26634. dd.ReadMapElemKey()
  26635. }
  26636. mk = int8(dd.DecodeInt(8))
  26637. if esep {
  26638. dd.ReadMapElemValue()
  26639. }
  26640. if dd.TryDecodeAsNil() {
  26641. if d.h.DeleteOnNilMapValue {
  26642. delete(v, mk)
  26643. } else {
  26644. v[mk] = 0
  26645. }
  26646. continue
  26647. }
  26648. mv = uint16(dd.DecodeUint(16))
  26649. if v != nil {
  26650. v[mk] = mv
  26651. }
  26652. }
  26653. dd.ReadMapEnd()
  26654. return v, changed
  26655. }
  26656. func (d *Decoder) fastpathDecMapInt8Uint32R(f *codecFnInfo, rv reflect.Value) {
  26657. if rv.Kind() == reflect.Ptr {
  26658. vp := rv2i(rv).(*map[int8]uint32)
  26659. if v, changed := fastpathTV.DecMapInt8Uint32V(*vp, true, d); changed {
  26660. *vp = v
  26661. }
  26662. return
  26663. }
  26664. fastpathTV.DecMapInt8Uint32V(rv2i(rv).(map[int8]uint32), false, d)
  26665. }
  26666. func (f fastpathT) DecMapInt8Uint32X(vp *map[int8]uint32, d *Decoder) {
  26667. if v, changed := f.DecMapInt8Uint32V(*vp, true, d); changed {
  26668. *vp = v
  26669. }
  26670. }
  26671. func (_ fastpathT) DecMapInt8Uint32V(v map[int8]uint32, canChange bool,
  26672. d *Decoder) (_ map[int8]uint32, changed bool) {
  26673. dd, esep := d.d, d.hh.hasElemSeparators()
  26674. containerLen := dd.ReadMapStart()
  26675. if canChange && v == nil {
  26676. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  26677. v = make(map[int8]uint32, xlen)
  26678. changed = true
  26679. }
  26680. if containerLen == 0 {
  26681. dd.ReadMapEnd()
  26682. return v, changed
  26683. }
  26684. var mk int8
  26685. var mv uint32
  26686. hasLen := containerLen > 0
  26687. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26688. if esep {
  26689. dd.ReadMapElemKey()
  26690. }
  26691. mk = int8(dd.DecodeInt(8))
  26692. if esep {
  26693. dd.ReadMapElemValue()
  26694. }
  26695. if dd.TryDecodeAsNil() {
  26696. if d.h.DeleteOnNilMapValue {
  26697. delete(v, mk)
  26698. } else {
  26699. v[mk] = 0
  26700. }
  26701. continue
  26702. }
  26703. mv = uint32(dd.DecodeUint(32))
  26704. if v != nil {
  26705. v[mk] = mv
  26706. }
  26707. }
  26708. dd.ReadMapEnd()
  26709. return v, changed
  26710. }
  26711. func (d *Decoder) fastpathDecMapInt8Uint64R(f *codecFnInfo, rv reflect.Value) {
  26712. if rv.Kind() == reflect.Ptr {
  26713. vp := rv2i(rv).(*map[int8]uint64)
  26714. if v, changed := fastpathTV.DecMapInt8Uint64V(*vp, true, d); changed {
  26715. *vp = v
  26716. }
  26717. return
  26718. }
  26719. fastpathTV.DecMapInt8Uint64V(rv2i(rv).(map[int8]uint64), false, d)
  26720. }
  26721. func (f fastpathT) DecMapInt8Uint64X(vp *map[int8]uint64, d *Decoder) {
  26722. if v, changed := f.DecMapInt8Uint64V(*vp, true, d); changed {
  26723. *vp = v
  26724. }
  26725. }
  26726. func (_ fastpathT) DecMapInt8Uint64V(v map[int8]uint64, canChange bool,
  26727. d *Decoder) (_ map[int8]uint64, changed bool) {
  26728. dd, esep := d.d, d.hh.hasElemSeparators()
  26729. containerLen := dd.ReadMapStart()
  26730. if canChange && v == nil {
  26731. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  26732. v = make(map[int8]uint64, xlen)
  26733. changed = true
  26734. }
  26735. if containerLen == 0 {
  26736. dd.ReadMapEnd()
  26737. return v, changed
  26738. }
  26739. var mk int8
  26740. var mv uint64
  26741. hasLen := containerLen > 0
  26742. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26743. if esep {
  26744. dd.ReadMapElemKey()
  26745. }
  26746. mk = int8(dd.DecodeInt(8))
  26747. if esep {
  26748. dd.ReadMapElemValue()
  26749. }
  26750. if dd.TryDecodeAsNil() {
  26751. if d.h.DeleteOnNilMapValue {
  26752. delete(v, mk)
  26753. } else {
  26754. v[mk] = 0
  26755. }
  26756. continue
  26757. }
  26758. mv = dd.DecodeUint(64)
  26759. if v != nil {
  26760. v[mk] = mv
  26761. }
  26762. }
  26763. dd.ReadMapEnd()
  26764. return v, changed
  26765. }
  26766. func (d *Decoder) fastpathDecMapInt8UintptrR(f *codecFnInfo, rv reflect.Value) {
  26767. if rv.Kind() == reflect.Ptr {
  26768. vp := rv2i(rv).(*map[int8]uintptr)
  26769. if v, changed := fastpathTV.DecMapInt8UintptrV(*vp, true, d); changed {
  26770. *vp = v
  26771. }
  26772. return
  26773. }
  26774. fastpathTV.DecMapInt8UintptrV(rv2i(rv).(map[int8]uintptr), false, d)
  26775. }
  26776. func (f fastpathT) DecMapInt8UintptrX(vp *map[int8]uintptr, d *Decoder) {
  26777. if v, changed := f.DecMapInt8UintptrV(*vp, true, d); changed {
  26778. *vp = v
  26779. }
  26780. }
  26781. func (_ fastpathT) DecMapInt8UintptrV(v map[int8]uintptr, canChange bool,
  26782. d *Decoder) (_ map[int8]uintptr, changed bool) {
  26783. dd, esep := d.d, d.hh.hasElemSeparators()
  26784. containerLen := dd.ReadMapStart()
  26785. if canChange && v == nil {
  26786. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  26787. v = make(map[int8]uintptr, xlen)
  26788. changed = true
  26789. }
  26790. if containerLen == 0 {
  26791. dd.ReadMapEnd()
  26792. return v, changed
  26793. }
  26794. var mk int8
  26795. var mv uintptr
  26796. hasLen := containerLen > 0
  26797. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26798. if esep {
  26799. dd.ReadMapElemKey()
  26800. }
  26801. mk = int8(dd.DecodeInt(8))
  26802. if esep {
  26803. dd.ReadMapElemValue()
  26804. }
  26805. if dd.TryDecodeAsNil() {
  26806. if d.h.DeleteOnNilMapValue {
  26807. delete(v, mk)
  26808. } else {
  26809. v[mk] = 0
  26810. }
  26811. continue
  26812. }
  26813. mv = uintptr(dd.DecodeUint(uintBitsize))
  26814. if v != nil {
  26815. v[mk] = mv
  26816. }
  26817. }
  26818. dd.ReadMapEnd()
  26819. return v, changed
  26820. }
  26821. func (d *Decoder) fastpathDecMapInt8IntR(f *codecFnInfo, rv reflect.Value) {
  26822. if rv.Kind() == reflect.Ptr {
  26823. vp := rv2i(rv).(*map[int8]int)
  26824. if v, changed := fastpathTV.DecMapInt8IntV(*vp, true, d); changed {
  26825. *vp = v
  26826. }
  26827. return
  26828. }
  26829. fastpathTV.DecMapInt8IntV(rv2i(rv).(map[int8]int), false, d)
  26830. }
  26831. func (f fastpathT) DecMapInt8IntX(vp *map[int8]int, d *Decoder) {
  26832. if v, changed := f.DecMapInt8IntV(*vp, true, d); changed {
  26833. *vp = v
  26834. }
  26835. }
  26836. func (_ fastpathT) DecMapInt8IntV(v map[int8]int, canChange bool,
  26837. d *Decoder) (_ map[int8]int, changed bool) {
  26838. dd, esep := d.d, d.hh.hasElemSeparators()
  26839. containerLen := dd.ReadMapStart()
  26840. if canChange && v == nil {
  26841. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  26842. v = make(map[int8]int, xlen)
  26843. changed = true
  26844. }
  26845. if containerLen == 0 {
  26846. dd.ReadMapEnd()
  26847. return v, changed
  26848. }
  26849. var mk int8
  26850. var mv int
  26851. hasLen := containerLen > 0
  26852. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26853. if esep {
  26854. dd.ReadMapElemKey()
  26855. }
  26856. mk = int8(dd.DecodeInt(8))
  26857. if esep {
  26858. dd.ReadMapElemValue()
  26859. }
  26860. if dd.TryDecodeAsNil() {
  26861. if d.h.DeleteOnNilMapValue {
  26862. delete(v, mk)
  26863. } else {
  26864. v[mk] = 0
  26865. }
  26866. continue
  26867. }
  26868. mv = int(dd.DecodeInt(intBitsize))
  26869. if v != nil {
  26870. v[mk] = mv
  26871. }
  26872. }
  26873. dd.ReadMapEnd()
  26874. return v, changed
  26875. }
  26876. func (d *Decoder) fastpathDecMapInt8Int8R(f *codecFnInfo, rv reflect.Value) {
  26877. if rv.Kind() == reflect.Ptr {
  26878. vp := rv2i(rv).(*map[int8]int8)
  26879. if v, changed := fastpathTV.DecMapInt8Int8V(*vp, true, d); changed {
  26880. *vp = v
  26881. }
  26882. return
  26883. }
  26884. fastpathTV.DecMapInt8Int8V(rv2i(rv).(map[int8]int8), false, d)
  26885. }
  26886. func (f fastpathT) DecMapInt8Int8X(vp *map[int8]int8, d *Decoder) {
  26887. if v, changed := f.DecMapInt8Int8V(*vp, true, d); changed {
  26888. *vp = v
  26889. }
  26890. }
  26891. func (_ fastpathT) DecMapInt8Int8V(v map[int8]int8, canChange bool,
  26892. d *Decoder) (_ map[int8]int8, changed bool) {
  26893. dd, esep := d.d, d.hh.hasElemSeparators()
  26894. containerLen := dd.ReadMapStart()
  26895. if canChange && v == nil {
  26896. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  26897. v = make(map[int8]int8, xlen)
  26898. changed = true
  26899. }
  26900. if containerLen == 0 {
  26901. dd.ReadMapEnd()
  26902. return v, changed
  26903. }
  26904. var mk int8
  26905. var mv int8
  26906. hasLen := containerLen > 0
  26907. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26908. if esep {
  26909. dd.ReadMapElemKey()
  26910. }
  26911. mk = int8(dd.DecodeInt(8))
  26912. if esep {
  26913. dd.ReadMapElemValue()
  26914. }
  26915. if dd.TryDecodeAsNil() {
  26916. if d.h.DeleteOnNilMapValue {
  26917. delete(v, mk)
  26918. } else {
  26919. v[mk] = 0
  26920. }
  26921. continue
  26922. }
  26923. mv = int8(dd.DecodeInt(8))
  26924. if v != nil {
  26925. v[mk] = mv
  26926. }
  26927. }
  26928. dd.ReadMapEnd()
  26929. return v, changed
  26930. }
  26931. func (d *Decoder) fastpathDecMapInt8Int16R(f *codecFnInfo, rv reflect.Value) {
  26932. if rv.Kind() == reflect.Ptr {
  26933. vp := rv2i(rv).(*map[int8]int16)
  26934. if v, changed := fastpathTV.DecMapInt8Int16V(*vp, true, d); changed {
  26935. *vp = v
  26936. }
  26937. return
  26938. }
  26939. fastpathTV.DecMapInt8Int16V(rv2i(rv).(map[int8]int16), false, d)
  26940. }
  26941. func (f fastpathT) DecMapInt8Int16X(vp *map[int8]int16, d *Decoder) {
  26942. if v, changed := f.DecMapInt8Int16V(*vp, true, d); changed {
  26943. *vp = v
  26944. }
  26945. }
  26946. func (_ fastpathT) DecMapInt8Int16V(v map[int8]int16, canChange bool,
  26947. d *Decoder) (_ map[int8]int16, changed bool) {
  26948. dd, esep := d.d, d.hh.hasElemSeparators()
  26949. containerLen := dd.ReadMapStart()
  26950. if canChange && v == nil {
  26951. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  26952. v = make(map[int8]int16, xlen)
  26953. changed = true
  26954. }
  26955. if containerLen == 0 {
  26956. dd.ReadMapEnd()
  26957. return v, changed
  26958. }
  26959. var mk int8
  26960. var mv int16
  26961. hasLen := containerLen > 0
  26962. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  26963. if esep {
  26964. dd.ReadMapElemKey()
  26965. }
  26966. mk = int8(dd.DecodeInt(8))
  26967. if esep {
  26968. dd.ReadMapElemValue()
  26969. }
  26970. if dd.TryDecodeAsNil() {
  26971. if d.h.DeleteOnNilMapValue {
  26972. delete(v, mk)
  26973. } else {
  26974. v[mk] = 0
  26975. }
  26976. continue
  26977. }
  26978. mv = int16(dd.DecodeInt(16))
  26979. if v != nil {
  26980. v[mk] = mv
  26981. }
  26982. }
  26983. dd.ReadMapEnd()
  26984. return v, changed
  26985. }
  26986. func (d *Decoder) fastpathDecMapInt8Int32R(f *codecFnInfo, rv reflect.Value) {
  26987. if rv.Kind() == reflect.Ptr {
  26988. vp := rv2i(rv).(*map[int8]int32)
  26989. if v, changed := fastpathTV.DecMapInt8Int32V(*vp, true, d); changed {
  26990. *vp = v
  26991. }
  26992. return
  26993. }
  26994. fastpathTV.DecMapInt8Int32V(rv2i(rv).(map[int8]int32), false, d)
  26995. }
  26996. func (f fastpathT) DecMapInt8Int32X(vp *map[int8]int32, d *Decoder) {
  26997. if v, changed := f.DecMapInt8Int32V(*vp, true, d); changed {
  26998. *vp = v
  26999. }
  27000. }
  27001. func (_ fastpathT) DecMapInt8Int32V(v map[int8]int32, canChange bool,
  27002. d *Decoder) (_ map[int8]int32, changed bool) {
  27003. dd, esep := d.d, d.hh.hasElemSeparators()
  27004. containerLen := dd.ReadMapStart()
  27005. if canChange && v == nil {
  27006. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  27007. v = make(map[int8]int32, xlen)
  27008. changed = true
  27009. }
  27010. if containerLen == 0 {
  27011. dd.ReadMapEnd()
  27012. return v, changed
  27013. }
  27014. var mk int8
  27015. var mv int32
  27016. hasLen := containerLen > 0
  27017. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27018. if esep {
  27019. dd.ReadMapElemKey()
  27020. }
  27021. mk = int8(dd.DecodeInt(8))
  27022. if esep {
  27023. dd.ReadMapElemValue()
  27024. }
  27025. if dd.TryDecodeAsNil() {
  27026. if d.h.DeleteOnNilMapValue {
  27027. delete(v, mk)
  27028. } else {
  27029. v[mk] = 0
  27030. }
  27031. continue
  27032. }
  27033. mv = int32(dd.DecodeInt(32))
  27034. if v != nil {
  27035. v[mk] = mv
  27036. }
  27037. }
  27038. dd.ReadMapEnd()
  27039. return v, changed
  27040. }
  27041. func (d *Decoder) fastpathDecMapInt8Int64R(f *codecFnInfo, rv reflect.Value) {
  27042. if rv.Kind() == reflect.Ptr {
  27043. vp := rv2i(rv).(*map[int8]int64)
  27044. if v, changed := fastpathTV.DecMapInt8Int64V(*vp, true, d); changed {
  27045. *vp = v
  27046. }
  27047. return
  27048. }
  27049. fastpathTV.DecMapInt8Int64V(rv2i(rv).(map[int8]int64), false, d)
  27050. }
  27051. func (f fastpathT) DecMapInt8Int64X(vp *map[int8]int64, d *Decoder) {
  27052. if v, changed := f.DecMapInt8Int64V(*vp, true, d); changed {
  27053. *vp = v
  27054. }
  27055. }
  27056. func (_ fastpathT) DecMapInt8Int64V(v map[int8]int64, canChange bool,
  27057. d *Decoder) (_ map[int8]int64, changed bool) {
  27058. dd, esep := d.d, d.hh.hasElemSeparators()
  27059. containerLen := dd.ReadMapStart()
  27060. if canChange && v == nil {
  27061. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  27062. v = make(map[int8]int64, xlen)
  27063. changed = true
  27064. }
  27065. if containerLen == 0 {
  27066. dd.ReadMapEnd()
  27067. return v, changed
  27068. }
  27069. var mk int8
  27070. var mv int64
  27071. hasLen := containerLen > 0
  27072. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27073. if esep {
  27074. dd.ReadMapElemKey()
  27075. }
  27076. mk = int8(dd.DecodeInt(8))
  27077. if esep {
  27078. dd.ReadMapElemValue()
  27079. }
  27080. if dd.TryDecodeAsNil() {
  27081. if d.h.DeleteOnNilMapValue {
  27082. delete(v, mk)
  27083. } else {
  27084. v[mk] = 0
  27085. }
  27086. continue
  27087. }
  27088. mv = dd.DecodeInt(64)
  27089. if v != nil {
  27090. v[mk] = mv
  27091. }
  27092. }
  27093. dd.ReadMapEnd()
  27094. return v, changed
  27095. }
  27096. func (d *Decoder) fastpathDecMapInt8Float32R(f *codecFnInfo, rv reflect.Value) {
  27097. if rv.Kind() == reflect.Ptr {
  27098. vp := rv2i(rv).(*map[int8]float32)
  27099. if v, changed := fastpathTV.DecMapInt8Float32V(*vp, true, d); changed {
  27100. *vp = v
  27101. }
  27102. return
  27103. }
  27104. fastpathTV.DecMapInt8Float32V(rv2i(rv).(map[int8]float32), false, d)
  27105. }
  27106. func (f fastpathT) DecMapInt8Float32X(vp *map[int8]float32, d *Decoder) {
  27107. if v, changed := f.DecMapInt8Float32V(*vp, true, d); changed {
  27108. *vp = v
  27109. }
  27110. }
  27111. func (_ fastpathT) DecMapInt8Float32V(v map[int8]float32, canChange bool,
  27112. d *Decoder) (_ map[int8]float32, changed bool) {
  27113. dd, esep := d.d, d.hh.hasElemSeparators()
  27114. containerLen := dd.ReadMapStart()
  27115. if canChange && v == nil {
  27116. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  27117. v = make(map[int8]float32, xlen)
  27118. changed = true
  27119. }
  27120. if containerLen == 0 {
  27121. dd.ReadMapEnd()
  27122. return v, changed
  27123. }
  27124. var mk int8
  27125. var mv float32
  27126. hasLen := containerLen > 0
  27127. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27128. if esep {
  27129. dd.ReadMapElemKey()
  27130. }
  27131. mk = int8(dd.DecodeInt(8))
  27132. if esep {
  27133. dd.ReadMapElemValue()
  27134. }
  27135. if dd.TryDecodeAsNil() {
  27136. if d.h.DeleteOnNilMapValue {
  27137. delete(v, mk)
  27138. } else {
  27139. v[mk] = 0
  27140. }
  27141. continue
  27142. }
  27143. mv = float32(dd.DecodeFloat(true))
  27144. if v != nil {
  27145. v[mk] = mv
  27146. }
  27147. }
  27148. dd.ReadMapEnd()
  27149. return v, changed
  27150. }
  27151. func (d *Decoder) fastpathDecMapInt8Float64R(f *codecFnInfo, rv reflect.Value) {
  27152. if rv.Kind() == reflect.Ptr {
  27153. vp := rv2i(rv).(*map[int8]float64)
  27154. if v, changed := fastpathTV.DecMapInt8Float64V(*vp, true, d); changed {
  27155. *vp = v
  27156. }
  27157. return
  27158. }
  27159. fastpathTV.DecMapInt8Float64V(rv2i(rv).(map[int8]float64), false, d)
  27160. }
  27161. func (f fastpathT) DecMapInt8Float64X(vp *map[int8]float64, d *Decoder) {
  27162. if v, changed := f.DecMapInt8Float64V(*vp, true, d); changed {
  27163. *vp = v
  27164. }
  27165. }
  27166. func (_ fastpathT) DecMapInt8Float64V(v map[int8]float64, canChange bool,
  27167. d *Decoder) (_ map[int8]float64, changed bool) {
  27168. dd, esep := d.d, d.hh.hasElemSeparators()
  27169. containerLen := dd.ReadMapStart()
  27170. if canChange && v == nil {
  27171. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  27172. v = make(map[int8]float64, xlen)
  27173. changed = true
  27174. }
  27175. if containerLen == 0 {
  27176. dd.ReadMapEnd()
  27177. return v, changed
  27178. }
  27179. var mk int8
  27180. var mv float64
  27181. hasLen := containerLen > 0
  27182. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27183. if esep {
  27184. dd.ReadMapElemKey()
  27185. }
  27186. mk = int8(dd.DecodeInt(8))
  27187. if esep {
  27188. dd.ReadMapElemValue()
  27189. }
  27190. if dd.TryDecodeAsNil() {
  27191. if d.h.DeleteOnNilMapValue {
  27192. delete(v, mk)
  27193. } else {
  27194. v[mk] = 0
  27195. }
  27196. continue
  27197. }
  27198. mv = dd.DecodeFloat(false)
  27199. if v != nil {
  27200. v[mk] = mv
  27201. }
  27202. }
  27203. dd.ReadMapEnd()
  27204. return v, changed
  27205. }
  27206. func (d *Decoder) fastpathDecMapInt8BoolR(f *codecFnInfo, rv reflect.Value) {
  27207. if rv.Kind() == reflect.Ptr {
  27208. vp := rv2i(rv).(*map[int8]bool)
  27209. if v, changed := fastpathTV.DecMapInt8BoolV(*vp, true, d); changed {
  27210. *vp = v
  27211. }
  27212. return
  27213. }
  27214. fastpathTV.DecMapInt8BoolV(rv2i(rv).(map[int8]bool), false, d)
  27215. }
  27216. func (f fastpathT) DecMapInt8BoolX(vp *map[int8]bool, d *Decoder) {
  27217. if v, changed := f.DecMapInt8BoolV(*vp, true, d); changed {
  27218. *vp = v
  27219. }
  27220. }
  27221. func (_ fastpathT) DecMapInt8BoolV(v map[int8]bool, canChange bool,
  27222. d *Decoder) (_ map[int8]bool, changed bool) {
  27223. dd, esep := d.d, d.hh.hasElemSeparators()
  27224. containerLen := dd.ReadMapStart()
  27225. if canChange && v == nil {
  27226. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  27227. v = make(map[int8]bool, xlen)
  27228. changed = true
  27229. }
  27230. if containerLen == 0 {
  27231. dd.ReadMapEnd()
  27232. return v, changed
  27233. }
  27234. var mk int8
  27235. var mv bool
  27236. hasLen := containerLen > 0
  27237. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27238. if esep {
  27239. dd.ReadMapElemKey()
  27240. }
  27241. mk = int8(dd.DecodeInt(8))
  27242. if esep {
  27243. dd.ReadMapElemValue()
  27244. }
  27245. if dd.TryDecodeAsNil() {
  27246. if d.h.DeleteOnNilMapValue {
  27247. delete(v, mk)
  27248. } else {
  27249. v[mk] = false
  27250. }
  27251. continue
  27252. }
  27253. mv = dd.DecodeBool()
  27254. if v != nil {
  27255. v[mk] = mv
  27256. }
  27257. }
  27258. dd.ReadMapEnd()
  27259. return v, changed
  27260. }
  27261. func (d *Decoder) fastpathDecMapInt16IntfR(f *codecFnInfo, rv reflect.Value) {
  27262. if rv.Kind() == reflect.Ptr {
  27263. vp := rv2i(rv).(*map[int16]interface{})
  27264. if v, changed := fastpathTV.DecMapInt16IntfV(*vp, true, d); changed {
  27265. *vp = v
  27266. }
  27267. return
  27268. }
  27269. fastpathTV.DecMapInt16IntfV(rv2i(rv).(map[int16]interface{}), false, d)
  27270. }
  27271. func (f fastpathT) DecMapInt16IntfX(vp *map[int16]interface{}, d *Decoder) {
  27272. if v, changed := f.DecMapInt16IntfV(*vp, true, d); changed {
  27273. *vp = v
  27274. }
  27275. }
  27276. func (_ fastpathT) DecMapInt16IntfV(v map[int16]interface{}, canChange bool,
  27277. d *Decoder) (_ map[int16]interface{}, changed bool) {
  27278. dd, esep := d.d, d.hh.hasElemSeparators()
  27279. containerLen := dd.ReadMapStart()
  27280. if canChange && v == nil {
  27281. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  27282. v = make(map[int16]interface{}, xlen)
  27283. changed = true
  27284. }
  27285. if containerLen == 0 {
  27286. dd.ReadMapEnd()
  27287. return v, changed
  27288. }
  27289. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  27290. var mk int16
  27291. var mv interface{}
  27292. hasLen := containerLen > 0
  27293. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27294. if esep {
  27295. dd.ReadMapElemKey()
  27296. }
  27297. mk = int16(dd.DecodeInt(16))
  27298. if esep {
  27299. dd.ReadMapElemValue()
  27300. }
  27301. if dd.TryDecodeAsNil() {
  27302. if d.h.DeleteOnNilMapValue {
  27303. delete(v, mk)
  27304. } else {
  27305. v[mk] = nil
  27306. }
  27307. continue
  27308. }
  27309. if mapGet {
  27310. mv = v[mk]
  27311. } else {
  27312. mv = nil
  27313. }
  27314. d.decode(&mv)
  27315. if v != nil {
  27316. v[mk] = mv
  27317. }
  27318. }
  27319. dd.ReadMapEnd()
  27320. return v, changed
  27321. }
  27322. func (d *Decoder) fastpathDecMapInt16StringR(f *codecFnInfo, rv reflect.Value) {
  27323. if rv.Kind() == reflect.Ptr {
  27324. vp := rv2i(rv).(*map[int16]string)
  27325. if v, changed := fastpathTV.DecMapInt16StringV(*vp, true, d); changed {
  27326. *vp = v
  27327. }
  27328. return
  27329. }
  27330. fastpathTV.DecMapInt16StringV(rv2i(rv).(map[int16]string), false, d)
  27331. }
  27332. func (f fastpathT) DecMapInt16StringX(vp *map[int16]string, d *Decoder) {
  27333. if v, changed := f.DecMapInt16StringV(*vp, true, d); changed {
  27334. *vp = v
  27335. }
  27336. }
  27337. func (_ fastpathT) DecMapInt16StringV(v map[int16]string, canChange bool,
  27338. d *Decoder) (_ map[int16]string, changed bool) {
  27339. dd, esep := d.d, d.hh.hasElemSeparators()
  27340. containerLen := dd.ReadMapStart()
  27341. if canChange && v == nil {
  27342. xlen := decInferLen(containerLen, d.h.MaxInitLen, 18)
  27343. v = make(map[int16]string, xlen)
  27344. changed = true
  27345. }
  27346. if containerLen == 0 {
  27347. dd.ReadMapEnd()
  27348. return v, changed
  27349. }
  27350. var mk int16
  27351. var mv string
  27352. hasLen := containerLen > 0
  27353. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27354. if esep {
  27355. dd.ReadMapElemKey()
  27356. }
  27357. mk = int16(dd.DecodeInt(16))
  27358. if esep {
  27359. dd.ReadMapElemValue()
  27360. }
  27361. if dd.TryDecodeAsNil() {
  27362. if d.h.DeleteOnNilMapValue {
  27363. delete(v, mk)
  27364. } else {
  27365. v[mk] = ""
  27366. }
  27367. continue
  27368. }
  27369. mv = dd.DecodeString()
  27370. if v != nil {
  27371. v[mk] = mv
  27372. }
  27373. }
  27374. dd.ReadMapEnd()
  27375. return v, changed
  27376. }
  27377. func (d *Decoder) fastpathDecMapInt16UintR(f *codecFnInfo, rv reflect.Value) {
  27378. if rv.Kind() == reflect.Ptr {
  27379. vp := rv2i(rv).(*map[int16]uint)
  27380. if v, changed := fastpathTV.DecMapInt16UintV(*vp, true, d); changed {
  27381. *vp = v
  27382. }
  27383. return
  27384. }
  27385. fastpathTV.DecMapInt16UintV(rv2i(rv).(map[int16]uint), false, d)
  27386. }
  27387. func (f fastpathT) DecMapInt16UintX(vp *map[int16]uint, d *Decoder) {
  27388. if v, changed := f.DecMapInt16UintV(*vp, true, d); changed {
  27389. *vp = v
  27390. }
  27391. }
  27392. func (_ fastpathT) DecMapInt16UintV(v map[int16]uint, canChange bool,
  27393. d *Decoder) (_ map[int16]uint, changed bool) {
  27394. dd, esep := d.d, d.hh.hasElemSeparators()
  27395. containerLen := dd.ReadMapStart()
  27396. if canChange && v == nil {
  27397. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  27398. v = make(map[int16]uint, xlen)
  27399. changed = true
  27400. }
  27401. if containerLen == 0 {
  27402. dd.ReadMapEnd()
  27403. return v, changed
  27404. }
  27405. var mk int16
  27406. var mv uint
  27407. hasLen := containerLen > 0
  27408. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27409. if esep {
  27410. dd.ReadMapElemKey()
  27411. }
  27412. mk = int16(dd.DecodeInt(16))
  27413. if esep {
  27414. dd.ReadMapElemValue()
  27415. }
  27416. if dd.TryDecodeAsNil() {
  27417. if d.h.DeleteOnNilMapValue {
  27418. delete(v, mk)
  27419. } else {
  27420. v[mk] = 0
  27421. }
  27422. continue
  27423. }
  27424. mv = uint(dd.DecodeUint(uintBitsize))
  27425. if v != nil {
  27426. v[mk] = mv
  27427. }
  27428. }
  27429. dd.ReadMapEnd()
  27430. return v, changed
  27431. }
  27432. func (d *Decoder) fastpathDecMapInt16Uint8R(f *codecFnInfo, rv reflect.Value) {
  27433. if rv.Kind() == reflect.Ptr {
  27434. vp := rv2i(rv).(*map[int16]uint8)
  27435. if v, changed := fastpathTV.DecMapInt16Uint8V(*vp, true, d); changed {
  27436. *vp = v
  27437. }
  27438. return
  27439. }
  27440. fastpathTV.DecMapInt16Uint8V(rv2i(rv).(map[int16]uint8), false, d)
  27441. }
  27442. func (f fastpathT) DecMapInt16Uint8X(vp *map[int16]uint8, d *Decoder) {
  27443. if v, changed := f.DecMapInt16Uint8V(*vp, true, d); changed {
  27444. *vp = v
  27445. }
  27446. }
  27447. func (_ fastpathT) DecMapInt16Uint8V(v map[int16]uint8, canChange bool,
  27448. d *Decoder) (_ map[int16]uint8, changed bool) {
  27449. dd, esep := d.d, d.hh.hasElemSeparators()
  27450. containerLen := dd.ReadMapStart()
  27451. if canChange && v == nil {
  27452. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  27453. v = make(map[int16]uint8, xlen)
  27454. changed = true
  27455. }
  27456. if containerLen == 0 {
  27457. dd.ReadMapEnd()
  27458. return v, changed
  27459. }
  27460. var mk int16
  27461. var mv uint8
  27462. hasLen := containerLen > 0
  27463. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27464. if esep {
  27465. dd.ReadMapElemKey()
  27466. }
  27467. mk = int16(dd.DecodeInt(16))
  27468. if esep {
  27469. dd.ReadMapElemValue()
  27470. }
  27471. if dd.TryDecodeAsNil() {
  27472. if d.h.DeleteOnNilMapValue {
  27473. delete(v, mk)
  27474. } else {
  27475. v[mk] = 0
  27476. }
  27477. continue
  27478. }
  27479. mv = uint8(dd.DecodeUint(8))
  27480. if v != nil {
  27481. v[mk] = mv
  27482. }
  27483. }
  27484. dd.ReadMapEnd()
  27485. return v, changed
  27486. }
  27487. func (d *Decoder) fastpathDecMapInt16Uint16R(f *codecFnInfo, rv reflect.Value) {
  27488. if rv.Kind() == reflect.Ptr {
  27489. vp := rv2i(rv).(*map[int16]uint16)
  27490. if v, changed := fastpathTV.DecMapInt16Uint16V(*vp, true, d); changed {
  27491. *vp = v
  27492. }
  27493. return
  27494. }
  27495. fastpathTV.DecMapInt16Uint16V(rv2i(rv).(map[int16]uint16), false, d)
  27496. }
  27497. func (f fastpathT) DecMapInt16Uint16X(vp *map[int16]uint16, d *Decoder) {
  27498. if v, changed := f.DecMapInt16Uint16V(*vp, true, d); changed {
  27499. *vp = v
  27500. }
  27501. }
  27502. func (_ fastpathT) DecMapInt16Uint16V(v map[int16]uint16, canChange bool,
  27503. d *Decoder) (_ map[int16]uint16, changed bool) {
  27504. dd, esep := d.d, d.hh.hasElemSeparators()
  27505. containerLen := dd.ReadMapStart()
  27506. if canChange && v == nil {
  27507. xlen := decInferLen(containerLen, d.h.MaxInitLen, 4)
  27508. v = make(map[int16]uint16, xlen)
  27509. changed = true
  27510. }
  27511. if containerLen == 0 {
  27512. dd.ReadMapEnd()
  27513. return v, changed
  27514. }
  27515. var mk int16
  27516. var mv uint16
  27517. hasLen := containerLen > 0
  27518. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27519. if esep {
  27520. dd.ReadMapElemKey()
  27521. }
  27522. mk = int16(dd.DecodeInt(16))
  27523. if esep {
  27524. dd.ReadMapElemValue()
  27525. }
  27526. if dd.TryDecodeAsNil() {
  27527. if d.h.DeleteOnNilMapValue {
  27528. delete(v, mk)
  27529. } else {
  27530. v[mk] = 0
  27531. }
  27532. continue
  27533. }
  27534. mv = uint16(dd.DecodeUint(16))
  27535. if v != nil {
  27536. v[mk] = mv
  27537. }
  27538. }
  27539. dd.ReadMapEnd()
  27540. return v, changed
  27541. }
  27542. func (d *Decoder) fastpathDecMapInt16Uint32R(f *codecFnInfo, rv reflect.Value) {
  27543. if rv.Kind() == reflect.Ptr {
  27544. vp := rv2i(rv).(*map[int16]uint32)
  27545. if v, changed := fastpathTV.DecMapInt16Uint32V(*vp, true, d); changed {
  27546. *vp = v
  27547. }
  27548. return
  27549. }
  27550. fastpathTV.DecMapInt16Uint32V(rv2i(rv).(map[int16]uint32), false, d)
  27551. }
  27552. func (f fastpathT) DecMapInt16Uint32X(vp *map[int16]uint32, d *Decoder) {
  27553. if v, changed := f.DecMapInt16Uint32V(*vp, true, d); changed {
  27554. *vp = v
  27555. }
  27556. }
  27557. func (_ fastpathT) DecMapInt16Uint32V(v map[int16]uint32, canChange bool,
  27558. d *Decoder) (_ map[int16]uint32, changed bool) {
  27559. dd, esep := d.d, d.hh.hasElemSeparators()
  27560. containerLen := dd.ReadMapStart()
  27561. if canChange && v == nil {
  27562. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  27563. v = make(map[int16]uint32, xlen)
  27564. changed = true
  27565. }
  27566. if containerLen == 0 {
  27567. dd.ReadMapEnd()
  27568. return v, changed
  27569. }
  27570. var mk int16
  27571. var mv uint32
  27572. hasLen := containerLen > 0
  27573. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27574. if esep {
  27575. dd.ReadMapElemKey()
  27576. }
  27577. mk = int16(dd.DecodeInt(16))
  27578. if esep {
  27579. dd.ReadMapElemValue()
  27580. }
  27581. if dd.TryDecodeAsNil() {
  27582. if d.h.DeleteOnNilMapValue {
  27583. delete(v, mk)
  27584. } else {
  27585. v[mk] = 0
  27586. }
  27587. continue
  27588. }
  27589. mv = uint32(dd.DecodeUint(32))
  27590. if v != nil {
  27591. v[mk] = mv
  27592. }
  27593. }
  27594. dd.ReadMapEnd()
  27595. return v, changed
  27596. }
  27597. func (d *Decoder) fastpathDecMapInt16Uint64R(f *codecFnInfo, rv reflect.Value) {
  27598. if rv.Kind() == reflect.Ptr {
  27599. vp := rv2i(rv).(*map[int16]uint64)
  27600. if v, changed := fastpathTV.DecMapInt16Uint64V(*vp, true, d); changed {
  27601. *vp = v
  27602. }
  27603. return
  27604. }
  27605. fastpathTV.DecMapInt16Uint64V(rv2i(rv).(map[int16]uint64), false, d)
  27606. }
  27607. func (f fastpathT) DecMapInt16Uint64X(vp *map[int16]uint64, d *Decoder) {
  27608. if v, changed := f.DecMapInt16Uint64V(*vp, true, d); changed {
  27609. *vp = v
  27610. }
  27611. }
  27612. func (_ fastpathT) DecMapInt16Uint64V(v map[int16]uint64, canChange bool,
  27613. d *Decoder) (_ map[int16]uint64, changed bool) {
  27614. dd, esep := d.d, d.hh.hasElemSeparators()
  27615. containerLen := dd.ReadMapStart()
  27616. if canChange && v == nil {
  27617. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  27618. v = make(map[int16]uint64, xlen)
  27619. changed = true
  27620. }
  27621. if containerLen == 0 {
  27622. dd.ReadMapEnd()
  27623. return v, changed
  27624. }
  27625. var mk int16
  27626. var mv uint64
  27627. hasLen := containerLen > 0
  27628. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27629. if esep {
  27630. dd.ReadMapElemKey()
  27631. }
  27632. mk = int16(dd.DecodeInt(16))
  27633. if esep {
  27634. dd.ReadMapElemValue()
  27635. }
  27636. if dd.TryDecodeAsNil() {
  27637. if d.h.DeleteOnNilMapValue {
  27638. delete(v, mk)
  27639. } else {
  27640. v[mk] = 0
  27641. }
  27642. continue
  27643. }
  27644. mv = dd.DecodeUint(64)
  27645. if v != nil {
  27646. v[mk] = mv
  27647. }
  27648. }
  27649. dd.ReadMapEnd()
  27650. return v, changed
  27651. }
  27652. func (d *Decoder) fastpathDecMapInt16UintptrR(f *codecFnInfo, rv reflect.Value) {
  27653. if rv.Kind() == reflect.Ptr {
  27654. vp := rv2i(rv).(*map[int16]uintptr)
  27655. if v, changed := fastpathTV.DecMapInt16UintptrV(*vp, true, d); changed {
  27656. *vp = v
  27657. }
  27658. return
  27659. }
  27660. fastpathTV.DecMapInt16UintptrV(rv2i(rv).(map[int16]uintptr), false, d)
  27661. }
  27662. func (f fastpathT) DecMapInt16UintptrX(vp *map[int16]uintptr, d *Decoder) {
  27663. if v, changed := f.DecMapInt16UintptrV(*vp, true, d); changed {
  27664. *vp = v
  27665. }
  27666. }
  27667. func (_ fastpathT) DecMapInt16UintptrV(v map[int16]uintptr, canChange bool,
  27668. d *Decoder) (_ map[int16]uintptr, changed bool) {
  27669. dd, esep := d.d, d.hh.hasElemSeparators()
  27670. containerLen := dd.ReadMapStart()
  27671. if canChange && v == nil {
  27672. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  27673. v = make(map[int16]uintptr, xlen)
  27674. changed = true
  27675. }
  27676. if containerLen == 0 {
  27677. dd.ReadMapEnd()
  27678. return v, changed
  27679. }
  27680. var mk int16
  27681. var mv uintptr
  27682. hasLen := containerLen > 0
  27683. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27684. if esep {
  27685. dd.ReadMapElemKey()
  27686. }
  27687. mk = int16(dd.DecodeInt(16))
  27688. if esep {
  27689. dd.ReadMapElemValue()
  27690. }
  27691. if dd.TryDecodeAsNil() {
  27692. if d.h.DeleteOnNilMapValue {
  27693. delete(v, mk)
  27694. } else {
  27695. v[mk] = 0
  27696. }
  27697. continue
  27698. }
  27699. mv = uintptr(dd.DecodeUint(uintBitsize))
  27700. if v != nil {
  27701. v[mk] = mv
  27702. }
  27703. }
  27704. dd.ReadMapEnd()
  27705. return v, changed
  27706. }
  27707. func (d *Decoder) fastpathDecMapInt16IntR(f *codecFnInfo, rv reflect.Value) {
  27708. if rv.Kind() == reflect.Ptr {
  27709. vp := rv2i(rv).(*map[int16]int)
  27710. if v, changed := fastpathTV.DecMapInt16IntV(*vp, true, d); changed {
  27711. *vp = v
  27712. }
  27713. return
  27714. }
  27715. fastpathTV.DecMapInt16IntV(rv2i(rv).(map[int16]int), false, d)
  27716. }
  27717. func (f fastpathT) DecMapInt16IntX(vp *map[int16]int, d *Decoder) {
  27718. if v, changed := f.DecMapInt16IntV(*vp, true, d); changed {
  27719. *vp = v
  27720. }
  27721. }
  27722. func (_ fastpathT) DecMapInt16IntV(v map[int16]int, canChange bool,
  27723. d *Decoder) (_ map[int16]int, changed bool) {
  27724. dd, esep := d.d, d.hh.hasElemSeparators()
  27725. containerLen := dd.ReadMapStart()
  27726. if canChange && v == nil {
  27727. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  27728. v = make(map[int16]int, xlen)
  27729. changed = true
  27730. }
  27731. if containerLen == 0 {
  27732. dd.ReadMapEnd()
  27733. return v, changed
  27734. }
  27735. var mk int16
  27736. var mv int
  27737. hasLen := containerLen > 0
  27738. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27739. if esep {
  27740. dd.ReadMapElemKey()
  27741. }
  27742. mk = int16(dd.DecodeInt(16))
  27743. if esep {
  27744. dd.ReadMapElemValue()
  27745. }
  27746. if dd.TryDecodeAsNil() {
  27747. if d.h.DeleteOnNilMapValue {
  27748. delete(v, mk)
  27749. } else {
  27750. v[mk] = 0
  27751. }
  27752. continue
  27753. }
  27754. mv = int(dd.DecodeInt(intBitsize))
  27755. if v != nil {
  27756. v[mk] = mv
  27757. }
  27758. }
  27759. dd.ReadMapEnd()
  27760. return v, changed
  27761. }
  27762. func (d *Decoder) fastpathDecMapInt16Int8R(f *codecFnInfo, rv reflect.Value) {
  27763. if rv.Kind() == reflect.Ptr {
  27764. vp := rv2i(rv).(*map[int16]int8)
  27765. if v, changed := fastpathTV.DecMapInt16Int8V(*vp, true, d); changed {
  27766. *vp = v
  27767. }
  27768. return
  27769. }
  27770. fastpathTV.DecMapInt16Int8V(rv2i(rv).(map[int16]int8), false, d)
  27771. }
  27772. func (f fastpathT) DecMapInt16Int8X(vp *map[int16]int8, d *Decoder) {
  27773. if v, changed := f.DecMapInt16Int8V(*vp, true, d); changed {
  27774. *vp = v
  27775. }
  27776. }
  27777. func (_ fastpathT) DecMapInt16Int8V(v map[int16]int8, canChange bool,
  27778. d *Decoder) (_ map[int16]int8, changed bool) {
  27779. dd, esep := d.d, d.hh.hasElemSeparators()
  27780. containerLen := dd.ReadMapStart()
  27781. if canChange && v == nil {
  27782. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  27783. v = make(map[int16]int8, xlen)
  27784. changed = true
  27785. }
  27786. if containerLen == 0 {
  27787. dd.ReadMapEnd()
  27788. return v, changed
  27789. }
  27790. var mk int16
  27791. var mv int8
  27792. hasLen := containerLen > 0
  27793. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27794. if esep {
  27795. dd.ReadMapElemKey()
  27796. }
  27797. mk = int16(dd.DecodeInt(16))
  27798. if esep {
  27799. dd.ReadMapElemValue()
  27800. }
  27801. if dd.TryDecodeAsNil() {
  27802. if d.h.DeleteOnNilMapValue {
  27803. delete(v, mk)
  27804. } else {
  27805. v[mk] = 0
  27806. }
  27807. continue
  27808. }
  27809. mv = int8(dd.DecodeInt(8))
  27810. if v != nil {
  27811. v[mk] = mv
  27812. }
  27813. }
  27814. dd.ReadMapEnd()
  27815. return v, changed
  27816. }
  27817. func (d *Decoder) fastpathDecMapInt16Int16R(f *codecFnInfo, rv reflect.Value) {
  27818. if rv.Kind() == reflect.Ptr {
  27819. vp := rv2i(rv).(*map[int16]int16)
  27820. if v, changed := fastpathTV.DecMapInt16Int16V(*vp, true, d); changed {
  27821. *vp = v
  27822. }
  27823. return
  27824. }
  27825. fastpathTV.DecMapInt16Int16V(rv2i(rv).(map[int16]int16), false, d)
  27826. }
  27827. func (f fastpathT) DecMapInt16Int16X(vp *map[int16]int16, d *Decoder) {
  27828. if v, changed := f.DecMapInt16Int16V(*vp, true, d); changed {
  27829. *vp = v
  27830. }
  27831. }
  27832. func (_ fastpathT) DecMapInt16Int16V(v map[int16]int16, canChange bool,
  27833. d *Decoder) (_ map[int16]int16, changed bool) {
  27834. dd, esep := d.d, d.hh.hasElemSeparators()
  27835. containerLen := dd.ReadMapStart()
  27836. if canChange && v == nil {
  27837. xlen := decInferLen(containerLen, d.h.MaxInitLen, 4)
  27838. v = make(map[int16]int16, xlen)
  27839. changed = true
  27840. }
  27841. if containerLen == 0 {
  27842. dd.ReadMapEnd()
  27843. return v, changed
  27844. }
  27845. var mk int16
  27846. var mv int16
  27847. hasLen := containerLen > 0
  27848. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27849. if esep {
  27850. dd.ReadMapElemKey()
  27851. }
  27852. mk = int16(dd.DecodeInt(16))
  27853. if esep {
  27854. dd.ReadMapElemValue()
  27855. }
  27856. if dd.TryDecodeAsNil() {
  27857. if d.h.DeleteOnNilMapValue {
  27858. delete(v, mk)
  27859. } else {
  27860. v[mk] = 0
  27861. }
  27862. continue
  27863. }
  27864. mv = int16(dd.DecodeInt(16))
  27865. if v != nil {
  27866. v[mk] = mv
  27867. }
  27868. }
  27869. dd.ReadMapEnd()
  27870. return v, changed
  27871. }
  27872. func (d *Decoder) fastpathDecMapInt16Int32R(f *codecFnInfo, rv reflect.Value) {
  27873. if rv.Kind() == reflect.Ptr {
  27874. vp := rv2i(rv).(*map[int16]int32)
  27875. if v, changed := fastpathTV.DecMapInt16Int32V(*vp, true, d); changed {
  27876. *vp = v
  27877. }
  27878. return
  27879. }
  27880. fastpathTV.DecMapInt16Int32V(rv2i(rv).(map[int16]int32), false, d)
  27881. }
  27882. func (f fastpathT) DecMapInt16Int32X(vp *map[int16]int32, d *Decoder) {
  27883. if v, changed := f.DecMapInt16Int32V(*vp, true, d); changed {
  27884. *vp = v
  27885. }
  27886. }
  27887. func (_ fastpathT) DecMapInt16Int32V(v map[int16]int32, canChange bool,
  27888. d *Decoder) (_ map[int16]int32, changed bool) {
  27889. dd, esep := d.d, d.hh.hasElemSeparators()
  27890. containerLen := dd.ReadMapStart()
  27891. if canChange && v == nil {
  27892. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  27893. v = make(map[int16]int32, xlen)
  27894. changed = true
  27895. }
  27896. if containerLen == 0 {
  27897. dd.ReadMapEnd()
  27898. return v, changed
  27899. }
  27900. var mk int16
  27901. var mv int32
  27902. hasLen := containerLen > 0
  27903. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27904. if esep {
  27905. dd.ReadMapElemKey()
  27906. }
  27907. mk = int16(dd.DecodeInt(16))
  27908. if esep {
  27909. dd.ReadMapElemValue()
  27910. }
  27911. if dd.TryDecodeAsNil() {
  27912. if d.h.DeleteOnNilMapValue {
  27913. delete(v, mk)
  27914. } else {
  27915. v[mk] = 0
  27916. }
  27917. continue
  27918. }
  27919. mv = int32(dd.DecodeInt(32))
  27920. if v != nil {
  27921. v[mk] = mv
  27922. }
  27923. }
  27924. dd.ReadMapEnd()
  27925. return v, changed
  27926. }
  27927. func (d *Decoder) fastpathDecMapInt16Int64R(f *codecFnInfo, rv reflect.Value) {
  27928. if rv.Kind() == reflect.Ptr {
  27929. vp := rv2i(rv).(*map[int16]int64)
  27930. if v, changed := fastpathTV.DecMapInt16Int64V(*vp, true, d); changed {
  27931. *vp = v
  27932. }
  27933. return
  27934. }
  27935. fastpathTV.DecMapInt16Int64V(rv2i(rv).(map[int16]int64), false, d)
  27936. }
  27937. func (f fastpathT) DecMapInt16Int64X(vp *map[int16]int64, d *Decoder) {
  27938. if v, changed := f.DecMapInt16Int64V(*vp, true, d); changed {
  27939. *vp = v
  27940. }
  27941. }
  27942. func (_ fastpathT) DecMapInt16Int64V(v map[int16]int64, canChange bool,
  27943. d *Decoder) (_ map[int16]int64, changed bool) {
  27944. dd, esep := d.d, d.hh.hasElemSeparators()
  27945. containerLen := dd.ReadMapStart()
  27946. if canChange && v == nil {
  27947. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  27948. v = make(map[int16]int64, xlen)
  27949. changed = true
  27950. }
  27951. if containerLen == 0 {
  27952. dd.ReadMapEnd()
  27953. return v, changed
  27954. }
  27955. var mk int16
  27956. var mv int64
  27957. hasLen := containerLen > 0
  27958. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  27959. if esep {
  27960. dd.ReadMapElemKey()
  27961. }
  27962. mk = int16(dd.DecodeInt(16))
  27963. if esep {
  27964. dd.ReadMapElemValue()
  27965. }
  27966. if dd.TryDecodeAsNil() {
  27967. if d.h.DeleteOnNilMapValue {
  27968. delete(v, mk)
  27969. } else {
  27970. v[mk] = 0
  27971. }
  27972. continue
  27973. }
  27974. mv = dd.DecodeInt(64)
  27975. if v != nil {
  27976. v[mk] = mv
  27977. }
  27978. }
  27979. dd.ReadMapEnd()
  27980. return v, changed
  27981. }
  27982. func (d *Decoder) fastpathDecMapInt16Float32R(f *codecFnInfo, rv reflect.Value) {
  27983. if rv.Kind() == reflect.Ptr {
  27984. vp := rv2i(rv).(*map[int16]float32)
  27985. if v, changed := fastpathTV.DecMapInt16Float32V(*vp, true, d); changed {
  27986. *vp = v
  27987. }
  27988. return
  27989. }
  27990. fastpathTV.DecMapInt16Float32V(rv2i(rv).(map[int16]float32), false, d)
  27991. }
  27992. func (f fastpathT) DecMapInt16Float32X(vp *map[int16]float32, d *Decoder) {
  27993. if v, changed := f.DecMapInt16Float32V(*vp, true, d); changed {
  27994. *vp = v
  27995. }
  27996. }
  27997. func (_ fastpathT) DecMapInt16Float32V(v map[int16]float32, canChange bool,
  27998. d *Decoder) (_ map[int16]float32, changed bool) {
  27999. dd, esep := d.d, d.hh.hasElemSeparators()
  28000. containerLen := dd.ReadMapStart()
  28001. if canChange && v == nil {
  28002. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  28003. v = make(map[int16]float32, xlen)
  28004. changed = true
  28005. }
  28006. if containerLen == 0 {
  28007. dd.ReadMapEnd()
  28008. return v, changed
  28009. }
  28010. var mk int16
  28011. var mv float32
  28012. hasLen := containerLen > 0
  28013. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28014. if esep {
  28015. dd.ReadMapElemKey()
  28016. }
  28017. mk = int16(dd.DecodeInt(16))
  28018. if esep {
  28019. dd.ReadMapElemValue()
  28020. }
  28021. if dd.TryDecodeAsNil() {
  28022. if d.h.DeleteOnNilMapValue {
  28023. delete(v, mk)
  28024. } else {
  28025. v[mk] = 0
  28026. }
  28027. continue
  28028. }
  28029. mv = float32(dd.DecodeFloat(true))
  28030. if v != nil {
  28031. v[mk] = mv
  28032. }
  28033. }
  28034. dd.ReadMapEnd()
  28035. return v, changed
  28036. }
  28037. func (d *Decoder) fastpathDecMapInt16Float64R(f *codecFnInfo, rv reflect.Value) {
  28038. if rv.Kind() == reflect.Ptr {
  28039. vp := rv2i(rv).(*map[int16]float64)
  28040. if v, changed := fastpathTV.DecMapInt16Float64V(*vp, true, d); changed {
  28041. *vp = v
  28042. }
  28043. return
  28044. }
  28045. fastpathTV.DecMapInt16Float64V(rv2i(rv).(map[int16]float64), false, d)
  28046. }
  28047. func (f fastpathT) DecMapInt16Float64X(vp *map[int16]float64, d *Decoder) {
  28048. if v, changed := f.DecMapInt16Float64V(*vp, true, d); changed {
  28049. *vp = v
  28050. }
  28051. }
  28052. func (_ fastpathT) DecMapInt16Float64V(v map[int16]float64, canChange bool,
  28053. d *Decoder) (_ map[int16]float64, changed bool) {
  28054. dd, esep := d.d, d.hh.hasElemSeparators()
  28055. containerLen := dd.ReadMapStart()
  28056. if canChange && v == nil {
  28057. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  28058. v = make(map[int16]float64, xlen)
  28059. changed = true
  28060. }
  28061. if containerLen == 0 {
  28062. dd.ReadMapEnd()
  28063. return v, changed
  28064. }
  28065. var mk int16
  28066. var mv float64
  28067. hasLen := containerLen > 0
  28068. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28069. if esep {
  28070. dd.ReadMapElemKey()
  28071. }
  28072. mk = int16(dd.DecodeInt(16))
  28073. if esep {
  28074. dd.ReadMapElemValue()
  28075. }
  28076. if dd.TryDecodeAsNil() {
  28077. if d.h.DeleteOnNilMapValue {
  28078. delete(v, mk)
  28079. } else {
  28080. v[mk] = 0
  28081. }
  28082. continue
  28083. }
  28084. mv = dd.DecodeFloat(false)
  28085. if v != nil {
  28086. v[mk] = mv
  28087. }
  28088. }
  28089. dd.ReadMapEnd()
  28090. return v, changed
  28091. }
  28092. func (d *Decoder) fastpathDecMapInt16BoolR(f *codecFnInfo, rv reflect.Value) {
  28093. if rv.Kind() == reflect.Ptr {
  28094. vp := rv2i(rv).(*map[int16]bool)
  28095. if v, changed := fastpathTV.DecMapInt16BoolV(*vp, true, d); changed {
  28096. *vp = v
  28097. }
  28098. return
  28099. }
  28100. fastpathTV.DecMapInt16BoolV(rv2i(rv).(map[int16]bool), false, d)
  28101. }
  28102. func (f fastpathT) DecMapInt16BoolX(vp *map[int16]bool, d *Decoder) {
  28103. if v, changed := f.DecMapInt16BoolV(*vp, true, d); changed {
  28104. *vp = v
  28105. }
  28106. }
  28107. func (_ fastpathT) DecMapInt16BoolV(v map[int16]bool, canChange bool,
  28108. d *Decoder) (_ map[int16]bool, changed bool) {
  28109. dd, esep := d.d, d.hh.hasElemSeparators()
  28110. containerLen := dd.ReadMapStart()
  28111. if canChange && v == nil {
  28112. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  28113. v = make(map[int16]bool, xlen)
  28114. changed = true
  28115. }
  28116. if containerLen == 0 {
  28117. dd.ReadMapEnd()
  28118. return v, changed
  28119. }
  28120. var mk int16
  28121. var mv bool
  28122. hasLen := containerLen > 0
  28123. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28124. if esep {
  28125. dd.ReadMapElemKey()
  28126. }
  28127. mk = int16(dd.DecodeInt(16))
  28128. if esep {
  28129. dd.ReadMapElemValue()
  28130. }
  28131. if dd.TryDecodeAsNil() {
  28132. if d.h.DeleteOnNilMapValue {
  28133. delete(v, mk)
  28134. } else {
  28135. v[mk] = false
  28136. }
  28137. continue
  28138. }
  28139. mv = dd.DecodeBool()
  28140. if v != nil {
  28141. v[mk] = mv
  28142. }
  28143. }
  28144. dd.ReadMapEnd()
  28145. return v, changed
  28146. }
  28147. func (d *Decoder) fastpathDecMapInt32IntfR(f *codecFnInfo, rv reflect.Value) {
  28148. if rv.Kind() == reflect.Ptr {
  28149. vp := rv2i(rv).(*map[int32]interface{})
  28150. if v, changed := fastpathTV.DecMapInt32IntfV(*vp, true, d); changed {
  28151. *vp = v
  28152. }
  28153. return
  28154. }
  28155. fastpathTV.DecMapInt32IntfV(rv2i(rv).(map[int32]interface{}), false, d)
  28156. }
  28157. func (f fastpathT) DecMapInt32IntfX(vp *map[int32]interface{}, d *Decoder) {
  28158. if v, changed := f.DecMapInt32IntfV(*vp, true, d); changed {
  28159. *vp = v
  28160. }
  28161. }
  28162. func (_ fastpathT) DecMapInt32IntfV(v map[int32]interface{}, canChange bool,
  28163. d *Decoder) (_ map[int32]interface{}, changed bool) {
  28164. dd, esep := d.d, d.hh.hasElemSeparators()
  28165. containerLen := dd.ReadMapStart()
  28166. if canChange && v == nil {
  28167. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  28168. v = make(map[int32]interface{}, xlen)
  28169. changed = true
  28170. }
  28171. if containerLen == 0 {
  28172. dd.ReadMapEnd()
  28173. return v, changed
  28174. }
  28175. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  28176. var mk int32
  28177. var mv interface{}
  28178. hasLen := containerLen > 0
  28179. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28180. if esep {
  28181. dd.ReadMapElemKey()
  28182. }
  28183. mk = int32(dd.DecodeInt(32))
  28184. if esep {
  28185. dd.ReadMapElemValue()
  28186. }
  28187. if dd.TryDecodeAsNil() {
  28188. if d.h.DeleteOnNilMapValue {
  28189. delete(v, mk)
  28190. } else {
  28191. v[mk] = nil
  28192. }
  28193. continue
  28194. }
  28195. if mapGet {
  28196. mv = v[mk]
  28197. } else {
  28198. mv = nil
  28199. }
  28200. d.decode(&mv)
  28201. if v != nil {
  28202. v[mk] = mv
  28203. }
  28204. }
  28205. dd.ReadMapEnd()
  28206. return v, changed
  28207. }
  28208. func (d *Decoder) fastpathDecMapInt32StringR(f *codecFnInfo, rv reflect.Value) {
  28209. if rv.Kind() == reflect.Ptr {
  28210. vp := rv2i(rv).(*map[int32]string)
  28211. if v, changed := fastpathTV.DecMapInt32StringV(*vp, true, d); changed {
  28212. *vp = v
  28213. }
  28214. return
  28215. }
  28216. fastpathTV.DecMapInt32StringV(rv2i(rv).(map[int32]string), false, d)
  28217. }
  28218. func (f fastpathT) DecMapInt32StringX(vp *map[int32]string, d *Decoder) {
  28219. if v, changed := f.DecMapInt32StringV(*vp, true, d); changed {
  28220. *vp = v
  28221. }
  28222. }
  28223. func (_ fastpathT) DecMapInt32StringV(v map[int32]string, canChange bool,
  28224. d *Decoder) (_ map[int32]string, changed bool) {
  28225. dd, esep := d.d, d.hh.hasElemSeparators()
  28226. containerLen := dd.ReadMapStart()
  28227. if canChange && v == nil {
  28228. xlen := decInferLen(containerLen, d.h.MaxInitLen, 20)
  28229. v = make(map[int32]string, xlen)
  28230. changed = true
  28231. }
  28232. if containerLen == 0 {
  28233. dd.ReadMapEnd()
  28234. return v, changed
  28235. }
  28236. var mk int32
  28237. var mv string
  28238. hasLen := containerLen > 0
  28239. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28240. if esep {
  28241. dd.ReadMapElemKey()
  28242. }
  28243. mk = int32(dd.DecodeInt(32))
  28244. if esep {
  28245. dd.ReadMapElemValue()
  28246. }
  28247. if dd.TryDecodeAsNil() {
  28248. if d.h.DeleteOnNilMapValue {
  28249. delete(v, mk)
  28250. } else {
  28251. v[mk] = ""
  28252. }
  28253. continue
  28254. }
  28255. mv = dd.DecodeString()
  28256. if v != nil {
  28257. v[mk] = mv
  28258. }
  28259. }
  28260. dd.ReadMapEnd()
  28261. return v, changed
  28262. }
  28263. func (d *Decoder) fastpathDecMapInt32UintR(f *codecFnInfo, rv reflect.Value) {
  28264. if rv.Kind() == reflect.Ptr {
  28265. vp := rv2i(rv).(*map[int32]uint)
  28266. if v, changed := fastpathTV.DecMapInt32UintV(*vp, true, d); changed {
  28267. *vp = v
  28268. }
  28269. return
  28270. }
  28271. fastpathTV.DecMapInt32UintV(rv2i(rv).(map[int32]uint), false, d)
  28272. }
  28273. func (f fastpathT) DecMapInt32UintX(vp *map[int32]uint, d *Decoder) {
  28274. if v, changed := f.DecMapInt32UintV(*vp, true, d); changed {
  28275. *vp = v
  28276. }
  28277. }
  28278. func (_ fastpathT) DecMapInt32UintV(v map[int32]uint, canChange bool,
  28279. d *Decoder) (_ map[int32]uint, changed bool) {
  28280. dd, esep := d.d, d.hh.hasElemSeparators()
  28281. containerLen := dd.ReadMapStart()
  28282. if canChange && v == nil {
  28283. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  28284. v = make(map[int32]uint, xlen)
  28285. changed = true
  28286. }
  28287. if containerLen == 0 {
  28288. dd.ReadMapEnd()
  28289. return v, changed
  28290. }
  28291. var mk int32
  28292. var mv uint
  28293. hasLen := containerLen > 0
  28294. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28295. if esep {
  28296. dd.ReadMapElemKey()
  28297. }
  28298. mk = int32(dd.DecodeInt(32))
  28299. if esep {
  28300. dd.ReadMapElemValue()
  28301. }
  28302. if dd.TryDecodeAsNil() {
  28303. if d.h.DeleteOnNilMapValue {
  28304. delete(v, mk)
  28305. } else {
  28306. v[mk] = 0
  28307. }
  28308. continue
  28309. }
  28310. mv = uint(dd.DecodeUint(uintBitsize))
  28311. if v != nil {
  28312. v[mk] = mv
  28313. }
  28314. }
  28315. dd.ReadMapEnd()
  28316. return v, changed
  28317. }
  28318. func (d *Decoder) fastpathDecMapInt32Uint8R(f *codecFnInfo, rv reflect.Value) {
  28319. if rv.Kind() == reflect.Ptr {
  28320. vp := rv2i(rv).(*map[int32]uint8)
  28321. if v, changed := fastpathTV.DecMapInt32Uint8V(*vp, true, d); changed {
  28322. *vp = v
  28323. }
  28324. return
  28325. }
  28326. fastpathTV.DecMapInt32Uint8V(rv2i(rv).(map[int32]uint8), false, d)
  28327. }
  28328. func (f fastpathT) DecMapInt32Uint8X(vp *map[int32]uint8, d *Decoder) {
  28329. if v, changed := f.DecMapInt32Uint8V(*vp, true, d); changed {
  28330. *vp = v
  28331. }
  28332. }
  28333. func (_ fastpathT) DecMapInt32Uint8V(v map[int32]uint8, canChange bool,
  28334. d *Decoder) (_ map[int32]uint8, changed bool) {
  28335. dd, esep := d.d, d.hh.hasElemSeparators()
  28336. containerLen := dd.ReadMapStart()
  28337. if canChange && v == nil {
  28338. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  28339. v = make(map[int32]uint8, xlen)
  28340. changed = true
  28341. }
  28342. if containerLen == 0 {
  28343. dd.ReadMapEnd()
  28344. return v, changed
  28345. }
  28346. var mk int32
  28347. var mv uint8
  28348. hasLen := containerLen > 0
  28349. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28350. if esep {
  28351. dd.ReadMapElemKey()
  28352. }
  28353. mk = int32(dd.DecodeInt(32))
  28354. if esep {
  28355. dd.ReadMapElemValue()
  28356. }
  28357. if dd.TryDecodeAsNil() {
  28358. if d.h.DeleteOnNilMapValue {
  28359. delete(v, mk)
  28360. } else {
  28361. v[mk] = 0
  28362. }
  28363. continue
  28364. }
  28365. mv = uint8(dd.DecodeUint(8))
  28366. if v != nil {
  28367. v[mk] = mv
  28368. }
  28369. }
  28370. dd.ReadMapEnd()
  28371. return v, changed
  28372. }
  28373. func (d *Decoder) fastpathDecMapInt32Uint16R(f *codecFnInfo, rv reflect.Value) {
  28374. if rv.Kind() == reflect.Ptr {
  28375. vp := rv2i(rv).(*map[int32]uint16)
  28376. if v, changed := fastpathTV.DecMapInt32Uint16V(*vp, true, d); changed {
  28377. *vp = v
  28378. }
  28379. return
  28380. }
  28381. fastpathTV.DecMapInt32Uint16V(rv2i(rv).(map[int32]uint16), false, d)
  28382. }
  28383. func (f fastpathT) DecMapInt32Uint16X(vp *map[int32]uint16, d *Decoder) {
  28384. if v, changed := f.DecMapInt32Uint16V(*vp, true, d); changed {
  28385. *vp = v
  28386. }
  28387. }
  28388. func (_ fastpathT) DecMapInt32Uint16V(v map[int32]uint16, canChange bool,
  28389. d *Decoder) (_ map[int32]uint16, changed bool) {
  28390. dd, esep := d.d, d.hh.hasElemSeparators()
  28391. containerLen := dd.ReadMapStart()
  28392. if canChange && v == nil {
  28393. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  28394. v = make(map[int32]uint16, xlen)
  28395. changed = true
  28396. }
  28397. if containerLen == 0 {
  28398. dd.ReadMapEnd()
  28399. return v, changed
  28400. }
  28401. var mk int32
  28402. var mv uint16
  28403. hasLen := containerLen > 0
  28404. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28405. if esep {
  28406. dd.ReadMapElemKey()
  28407. }
  28408. mk = int32(dd.DecodeInt(32))
  28409. if esep {
  28410. dd.ReadMapElemValue()
  28411. }
  28412. if dd.TryDecodeAsNil() {
  28413. if d.h.DeleteOnNilMapValue {
  28414. delete(v, mk)
  28415. } else {
  28416. v[mk] = 0
  28417. }
  28418. continue
  28419. }
  28420. mv = uint16(dd.DecodeUint(16))
  28421. if v != nil {
  28422. v[mk] = mv
  28423. }
  28424. }
  28425. dd.ReadMapEnd()
  28426. return v, changed
  28427. }
  28428. func (d *Decoder) fastpathDecMapInt32Uint32R(f *codecFnInfo, rv reflect.Value) {
  28429. if rv.Kind() == reflect.Ptr {
  28430. vp := rv2i(rv).(*map[int32]uint32)
  28431. if v, changed := fastpathTV.DecMapInt32Uint32V(*vp, true, d); changed {
  28432. *vp = v
  28433. }
  28434. return
  28435. }
  28436. fastpathTV.DecMapInt32Uint32V(rv2i(rv).(map[int32]uint32), false, d)
  28437. }
  28438. func (f fastpathT) DecMapInt32Uint32X(vp *map[int32]uint32, d *Decoder) {
  28439. if v, changed := f.DecMapInt32Uint32V(*vp, true, d); changed {
  28440. *vp = v
  28441. }
  28442. }
  28443. func (_ fastpathT) DecMapInt32Uint32V(v map[int32]uint32, canChange bool,
  28444. d *Decoder) (_ map[int32]uint32, changed bool) {
  28445. dd, esep := d.d, d.hh.hasElemSeparators()
  28446. containerLen := dd.ReadMapStart()
  28447. if canChange && v == nil {
  28448. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  28449. v = make(map[int32]uint32, xlen)
  28450. changed = true
  28451. }
  28452. if containerLen == 0 {
  28453. dd.ReadMapEnd()
  28454. return v, changed
  28455. }
  28456. var mk int32
  28457. var mv uint32
  28458. hasLen := containerLen > 0
  28459. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28460. if esep {
  28461. dd.ReadMapElemKey()
  28462. }
  28463. mk = int32(dd.DecodeInt(32))
  28464. if esep {
  28465. dd.ReadMapElemValue()
  28466. }
  28467. if dd.TryDecodeAsNil() {
  28468. if d.h.DeleteOnNilMapValue {
  28469. delete(v, mk)
  28470. } else {
  28471. v[mk] = 0
  28472. }
  28473. continue
  28474. }
  28475. mv = uint32(dd.DecodeUint(32))
  28476. if v != nil {
  28477. v[mk] = mv
  28478. }
  28479. }
  28480. dd.ReadMapEnd()
  28481. return v, changed
  28482. }
  28483. func (d *Decoder) fastpathDecMapInt32Uint64R(f *codecFnInfo, rv reflect.Value) {
  28484. if rv.Kind() == reflect.Ptr {
  28485. vp := rv2i(rv).(*map[int32]uint64)
  28486. if v, changed := fastpathTV.DecMapInt32Uint64V(*vp, true, d); changed {
  28487. *vp = v
  28488. }
  28489. return
  28490. }
  28491. fastpathTV.DecMapInt32Uint64V(rv2i(rv).(map[int32]uint64), false, d)
  28492. }
  28493. func (f fastpathT) DecMapInt32Uint64X(vp *map[int32]uint64, d *Decoder) {
  28494. if v, changed := f.DecMapInt32Uint64V(*vp, true, d); changed {
  28495. *vp = v
  28496. }
  28497. }
  28498. func (_ fastpathT) DecMapInt32Uint64V(v map[int32]uint64, canChange bool,
  28499. d *Decoder) (_ map[int32]uint64, changed bool) {
  28500. dd, esep := d.d, d.hh.hasElemSeparators()
  28501. containerLen := dd.ReadMapStart()
  28502. if canChange && v == nil {
  28503. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  28504. v = make(map[int32]uint64, xlen)
  28505. changed = true
  28506. }
  28507. if containerLen == 0 {
  28508. dd.ReadMapEnd()
  28509. return v, changed
  28510. }
  28511. var mk int32
  28512. var mv uint64
  28513. hasLen := containerLen > 0
  28514. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28515. if esep {
  28516. dd.ReadMapElemKey()
  28517. }
  28518. mk = int32(dd.DecodeInt(32))
  28519. if esep {
  28520. dd.ReadMapElemValue()
  28521. }
  28522. if dd.TryDecodeAsNil() {
  28523. if d.h.DeleteOnNilMapValue {
  28524. delete(v, mk)
  28525. } else {
  28526. v[mk] = 0
  28527. }
  28528. continue
  28529. }
  28530. mv = dd.DecodeUint(64)
  28531. if v != nil {
  28532. v[mk] = mv
  28533. }
  28534. }
  28535. dd.ReadMapEnd()
  28536. return v, changed
  28537. }
  28538. func (d *Decoder) fastpathDecMapInt32UintptrR(f *codecFnInfo, rv reflect.Value) {
  28539. if rv.Kind() == reflect.Ptr {
  28540. vp := rv2i(rv).(*map[int32]uintptr)
  28541. if v, changed := fastpathTV.DecMapInt32UintptrV(*vp, true, d); changed {
  28542. *vp = v
  28543. }
  28544. return
  28545. }
  28546. fastpathTV.DecMapInt32UintptrV(rv2i(rv).(map[int32]uintptr), false, d)
  28547. }
  28548. func (f fastpathT) DecMapInt32UintptrX(vp *map[int32]uintptr, d *Decoder) {
  28549. if v, changed := f.DecMapInt32UintptrV(*vp, true, d); changed {
  28550. *vp = v
  28551. }
  28552. }
  28553. func (_ fastpathT) DecMapInt32UintptrV(v map[int32]uintptr, canChange bool,
  28554. d *Decoder) (_ map[int32]uintptr, changed bool) {
  28555. dd, esep := d.d, d.hh.hasElemSeparators()
  28556. containerLen := dd.ReadMapStart()
  28557. if canChange && v == nil {
  28558. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  28559. v = make(map[int32]uintptr, xlen)
  28560. changed = true
  28561. }
  28562. if containerLen == 0 {
  28563. dd.ReadMapEnd()
  28564. return v, changed
  28565. }
  28566. var mk int32
  28567. var mv uintptr
  28568. hasLen := containerLen > 0
  28569. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28570. if esep {
  28571. dd.ReadMapElemKey()
  28572. }
  28573. mk = int32(dd.DecodeInt(32))
  28574. if esep {
  28575. dd.ReadMapElemValue()
  28576. }
  28577. if dd.TryDecodeAsNil() {
  28578. if d.h.DeleteOnNilMapValue {
  28579. delete(v, mk)
  28580. } else {
  28581. v[mk] = 0
  28582. }
  28583. continue
  28584. }
  28585. mv = uintptr(dd.DecodeUint(uintBitsize))
  28586. if v != nil {
  28587. v[mk] = mv
  28588. }
  28589. }
  28590. dd.ReadMapEnd()
  28591. return v, changed
  28592. }
  28593. func (d *Decoder) fastpathDecMapInt32IntR(f *codecFnInfo, rv reflect.Value) {
  28594. if rv.Kind() == reflect.Ptr {
  28595. vp := rv2i(rv).(*map[int32]int)
  28596. if v, changed := fastpathTV.DecMapInt32IntV(*vp, true, d); changed {
  28597. *vp = v
  28598. }
  28599. return
  28600. }
  28601. fastpathTV.DecMapInt32IntV(rv2i(rv).(map[int32]int), false, d)
  28602. }
  28603. func (f fastpathT) DecMapInt32IntX(vp *map[int32]int, d *Decoder) {
  28604. if v, changed := f.DecMapInt32IntV(*vp, true, d); changed {
  28605. *vp = v
  28606. }
  28607. }
  28608. func (_ fastpathT) DecMapInt32IntV(v map[int32]int, canChange bool,
  28609. d *Decoder) (_ map[int32]int, changed bool) {
  28610. dd, esep := d.d, d.hh.hasElemSeparators()
  28611. containerLen := dd.ReadMapStart()
  28612. if canChange && v == nil {
  28613. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  28614. v = make(map[int32]int, xlen)
  28615. changed = true
  28616. }
  28617. if containerLen == 0 {
  28618. dd.ReadMapEnd()
  28619. return v, changed
  28620. }
  28621. var mk int32
  28622. var mv int
  28623. hasLen := containerLen > 0
  28624. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28625. if esep {
  28626. dd.ReadMapElemKey()
  28627. }
  28628. mk = int32(dd.DecodeInt(32))
  28629. if esep {
  28630. dd.ReadMapElemValue()
  28631. }
  28632. if dd.TryDecodeAsNil() {
  28633. if d.h.DeleteOnNilMapValue {
  28634. delete(v, mk)
  28635. } else {
  28636. v[mk] = 0
  28637. }
  28638. continue
  28639. }
  28640. mv = int(dd.DecodeInt(intBitsize))
  28641. if v != nil {
  28642. v[mk] = mv
  28643. }
  28644. }
  28645. dd.ReadMapEnd()
  28646. return v, changed
  28647. }
  28648. func (d *Decoder) fastpathDecMapInt32Int8R(f *codecFnInfo, rv reflect.Value) {
  28649. if rv.Kind() == reflect.Ptr {
  28650. vp := rv2i(rv).(*map[int32]int8)
  28651. if v, changed := fastpathTV.DecMapInt32Int8V(*vp, true, d); changed {
  28652. *vp = v
  28653. }
  28654. return
  28655. }
  28656. fastpathTV.DecMapInt32Int8V(rv2i(rv).(map[int32]int8), false, d)
  28657. }
  28658. func (f fastpathT) DecMapInt32Int8X(vp *map[int32]int8, d *Decoder) {
  28659. if v, changed := f.DecMapInt32Int8V(*vp, true, d); changed {
  28660. *vp = v
  28661. }
  28662. }
  28663. func (_ fastpathT) DecMapInt32Int8V(v map[int32]int8, canChange bool,
  28664. d *Decoder) (_ map[int32]int8, changed bool) {
  28665. dd, esep := d.d, d.hh.hasElemSeparators()
  28666. containerLen := dd.ReadMapStart()
  28667. if canChange && v == nil {
  28668. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  28669. v = make(map[int32]int8, xlen)
  28670. changed = true
  28671. }
  28672. if containerLen == 0 {
  28673. dd.ReadMapEnd()
  28674. return v, changed
  28675. }
  28676. var mk int32
  28677. var mv int8
  28678. hasLen := containerLen > 0
  28679. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28680. if esep {
  28681. dd.ReadMapElemKey()
  28682. }
  28683. mk = int32(dd.DecodeInt(32))
  28684. if esep {
  28685. dd.ReadMapElemValue()
  28686. }
  28687. if dd.TryDecodeAsNil() {
  28688. if d.h.DeleteOnNilMapValue {
  28689. delete(v, mk)
  28690. } else {
  28691. v[mk] = 0
  28692. }
  28693. continue
  28694. }
  28695. mv = int8(dd.DecodeInt(8))
  28696. if v != nil {
  28697. v[mk] = mv
  28698. }
  28699. }
  28700. dd.ReadMapEnd()
  28701. return v, changed
  28702. }
  28703. func (d *Decoder) fastpathDecMapInt32Int16R(f *codecFnInfo, rv reflect.Value) {
  28704. if rv.Kind() == reflect.Ptr {
  28705. vp := rv2i(rv).(*map[int32]int16)
  28706. if v, changed := fastpathTV.DecMapInt32Int16V(*vp, true, d); changed {
  28707. *vp = v
  28708. }
  28709. return
  28710. }
  28711. fastpathTV.DecMapInt32Int16V(rv2i(rv).(map[int32]int16), false, d)
  28712. }
  28713. func (f fastpathT) DecMapInt32Int16X(vp *map[int32]int16, d *Decoder) {
  28714. if v, changed := f.DecMapInt32Int16V(*vp, true, d); changed {
  28715. *vp = v
  28716. }
  28717. }
  28718. func (_ fastpathT) DecMapInt32Int16V(v map[int32]int16, canChange bool,
  28719. d *Decoder) (_ map[int32]int16, changed bool) {
  28720. dd, esep := d.d, d.hh.hasElemSeparators()
  28721. containerLen := dd.ReadMapStart()
  28722. if canChange && v == nil {
  28723. xlen := decInferLen(containerLen, d.h.MaxInitLen, 6)
  28724. v = make(map[int32]int16, xlen)
  28725. changed = true
  28726. }
  28727. if containerLen == 0 {
  28728. dd.ReadMapEnd()
  28729. return v, changed
  28730. }
  28731. var mk int32
  28732. var mv int16
  28733. hasLen := containerLen > 0
  28734. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28735. if esep {
  28736. dd.ReadMapElemKey()
  28737. }
  28738. mk = int32(dd.DecodeInt(32))
  28739. if esep {
  28740. dd.ReadMapElemValue()
  28741. }
  28742. if dd.TryDecodeAsNil() {
  28743. if d.h.DeleteOnNilMapValue {
  28744. delete(v, mk)
  28745. } else {
  28746. v[mk] = 0
  28747. }
  28748. continue
  28749. }
  28750. mv = int16(dd.DecodeInt(16))
  28751. if v != nil {
  28752. v[mk] = mv
  28753. }
  28754. }
  28755. dd.ReadMapEnd()
  28756. return v, changed
  28757. }
  28758. func (d *Decoder) fastpathDecMapInt32Int32R(f *codecFnInfo, rv reflect.Value) {
  28759. if rv.Kind() == reflect.Ptr {
  28760. vp := rv2i(rv).(*map[int32]int32)
  28761. if v, changed := fastpathTV.DecMapInt32Int32V(*vp, true, d); changed {
  28762. *vp = v
  28763. }
  28764. return
  28765. }
  28766. fastpathTV.DecMapInt32Int32V(rv2i(rv).(map[int32]int32), false, d)
  28767. }
  28768. func (f fastpathT) DecMapInt32Int32X(vp *map[int32]int32, d *Decoder) {
  28769. if v, changed := f.DecMapInt32Int32V(*vp, true, d); changed {
  28770. *vp = v
  28771. }
  28772. }
  28773. func (_ fastpathT) DecMapInt32Int32V(v map[int32]int32, canChange bool,
  28774. d *Decoder) (_ map[int32]int32, changed bool) {
  28775. dd, esep := d.d, d.hh.hasElemSeparators()
  28776. containerLen := dd.ReadMapStart()
  28777. if canChange && v == nil {
  28778. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  28779. v = make(map[int32]int32, xlen)
  28780. changed = true
  28781. }
  28782. if containerLen == 0 {
  28783. dd.ReadMapEnd()
  28784. return v, changed
  28785. }
  28786. var mk int32
  28787. var mv int32
  28788. hasLen := containerLen > 0
  28789. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28790. if esep {
  28791. dd.ReadMapElemKey()
  28792. }
  28793. mk = int32(dd.DecodeInt(32))
  28794. if esep {
  28795. dd.ReadMapElemValue()
  28796. }
  28797. if dd.TryDecodeAsNil() {
  28798. if d.h.DeleteOnNilMapValue {
  28799. delete(v, mk)
  28800. } else {
  28801. v[mk] = 0
  28802. }
  28803. continue
  28804. }
  28805. mv = int32(dd.DecodeInt(32))
  28806. if v != nil {
  28807. v[mk] = mv
  28808. }
  28809. }
  28810. dd.ReadMapEnd()
  28811. return v, changed
  28812. }
  28813. func (d *Decoder) fastpathDecMapInt32Int64R(f *codecFnInfo, rv reflect.Value) {
  28814. if rv.Kind() == reflect.Ptr {
  28815. vp := rv2i(rv).(*map[int32]int64)
  28816. if v, changed := fastpathTV.DecMapInt32Int64V(*vp, true, d); changed {
  28817. *vp = v
  28818. }
  28819. return
  28820. }
  28821. fastpathTV.DecMapInt32Int64V(rv2i(rv).(map[int32]int64), false, d)
  28822. }
  28823. func (f fastpathT) DecMapInt32Int64X(vp *map[int32]int64, d *Decoder) {
  28824. if v, changed := f.DecMapInt32Int64V(*vp, true, d); changed {
  28825. *vp = v
  28826. }
  28827. }
  28828. func (_ fastpathT) DecMapInt32Int64V(v map[int32]int64, canChange bool,
  28829. d *Decoder) (_ map[int32]int64, changed bool) {
  28830. dd, esep := d.d, d.hh.hasElemSeparators()
  28831. containerLen := dd.ReadMapStart()
  28832. if canChange && v == nil {
  28833. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  28834. v = make(map[int32]int64, xlen)
  28835. changed = true
  28836. }
  28837. if containerLen == 0 {
  28838. dd.ReadMapEnd()
  28839. return v, changed
  28840. }
  28841. var mk int32
  28842. var mv int64
  28843. hasLen := containerLen > 0
  28844. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28845. if esep {
  28846. dd.ReadMapElemKey()
  28847. }
  28848. mk = int32(dd.DecodeInt(32))
  28849. if esep {
  28850. dd.ReadMapElemValue()
  28851. }
  28852. if dd.TryDecodeAsNil() {
  28853. if d.h.DeleteOnNilMapValue {
  28854. delete(v, mk)
  28855. } else {
  28856. v[mk] = 0
  28857. }
  28858. continue
  28859. }
  28860. mv = dd.DecodeInt(64)
  28861. if v != nil {
  28862. v[mk] = mv
  28863. }
  28864. }
  28865. dd.ReadMapEnd()
  28866. return v, changed
  28867. }
  28868. func (d *Decoder) fastpathDecMapInt32Float32R(f *codecFnInfo, rv reflect.Value) {
  28869. if rv.Kind() == reflect.Ptr {
  28870. vp := rv2i(rv).(*map[int32]float32)
  28871. if v, changed := fastpathTV.DecMapInt32Float32V(*vp, true, d); changed {
  28872. *vp = v
  28873. }
  28874. return
  28875. }
  28876. fastpathTV.DecMapInt32Float32V(rv2i(rv).(map[int32]float32), false, d)
  28877. }
  28878. func (f fastpathT) DecMapInt32Float32X(vp *map[int32]float32, d *Decoder) {
  28879. if v, changed := f.DecMapInt32Float32V(*vp, true, d); changed {
  28880. *vp = v
  28881. }
  28882. }
  28883. func (_ fastpathT) DecMapInt32Float32V(v map[int32]float32, canChange bool,
  28884. d *Decoder) (_ map[int32]float32, changed bool) {
  28885. dd, esep := d.d, d.hh.hasElemSeparators()
  28886. containerLen := dd.ReadMapStart()
  28887. if canChange && v == nil {
  28888. xlen := decInferLen(containerLen, d.h.MaxInitLen, 8)
  28889. v = make(map[int32]float32, xlen)
  28890. changed = true
  28891. }
  28892. if containerLen == 0 {
  28893. dd.ReadMapEnd()
  28894. return v, changed
  28895. }
  28896. var mk int32
  28897. var mv float32
  28898. hasLen := containerLen > 0
  28899. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28900. if esep {
  28901. dd.ReadMapElemKey()
  28902. }
  28903. mk = int32(dd.DecodeInt(32))
  28904. if esep {
  28905. dd.ReadMapElemValue()
  28906. }
  28907. if dd.TryDecodeAsNil() {
  28908. if d.h.DeleteOnNilMapValue {
  28909. delete(v, mk)
  28910. } else {
  28911. v[mk] = 0
  28912. }
  28913. continue
  28914. }
  28915. mv = float32(dd.DecodeFloat(true))
  28916. if v != nil {
  28917. v[mk] = mv
  28918. }
  28919. }
  28920. dd.ReadMapEnd()
  28921. return v, changed
  28922. }
  28923. func (d *Decoder) fastpathDecMapInt32Float64R(f *codecFnInfo, rv reflect.Value) {
  28924. if rv.Kind() == reflect.Ptr {
  28925. vp := rv2i(rv).(*map[int32]float64)
  28926. if v, changed := fastpathTV.DecMapInt32Float64V(*vp, true, d); changed {
  28927. *vp = v
  28928. }
  28929. return
  28930. }
  28931. fastpathTV.DecMapInt32Float64V(rv2i(rv).(map[int32]float64), false, d)
  28932. }
  28933. func (f fastpathT) DecMapInt32Float64X(vp *map[int32]float64, d *Decoder) {
  28934. if v, changed := f.DecMapInt32Float64V(*vp, true, d); changed {
  28935. *vp = v
  28936. }
  28937. }
  28938. func (_ fastpathT) DecMapInt32Float64V(v map[int32]float64, canChange bool,
  28939. d *Decoder) (_ map[int32]float64, changed bool) {
  28940. dd, esep := d.d, d.hh.hasElemSeparators()
  28941. containerLen := dd.ReadMapStart()
  28942. if canChange && v == nil {
  28943. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  28944. v = make(map[int32]float64, xlen)
  28945. changed = true
  28946. }
  28947. if containerLen == 0 {
  28948. dd.ReadMapEnd()
  28949. return v, changed
  28950. }
  28951. var mk int32
  28952. var mv float64
  28953. hasLen := containerLen > 0
  28954. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  28955. if esep {
  28956. dd.ReadMapElemKey()
  28957. }
  28958. mk = int32(dd.DecodeInt(32))
  28959. if esep {
  28960. dd.ReadMapElemValue()
  28961. }
  28962. if dd.TryDecodeAsNil() {
  28963. if d.h.DeleteOnNilMapValue {
  28964. delete(v, mk)
  28965. } else {
  28966. v[mk] = 0
  28967. }
  28968. continue
  28969. }
  28970. mv = dd.DecodeFloat(false)
  28971. if v != nil {
  28972. v[mk] = mv
  28973. }
  28974. }
  28975. dd.ReadMapEnd()
  28976. return v, changed
  28977. }
  28978. func (d *Decoder) fastpathDecMapInt32BoolR(f *codecFnInfo, rv reflect.Value) {
  28979. if rv.Kind() == reflect.Ptr {
  28980. vp := rv2i(rv).(*map[int32]bool)
  28981. if v, changed := fastpathTV.DecMapInt32BoolV(*vp, true, d); changed {
  28982. *vp = v
  28983. }
  28984. return
  28985. }
  28986. fastpathTV.DecMapInt32BoolV(rv2i(rv).(map[int32]bool), false, d)
  28987. }
  28988. func (f fastpathT) DecMapInt32BoolX(vp *map[int32]bool, d *Decoder) {
  28989. if v, changed := f.DecMapInt32BoolV(*vp, true, d); changed {
  28990. *vp = v
  28991. }
  28992. }
  28993. func (_ fastpathT) DecMapInt32BoolV(v map[int32]bool, canChange bool,
  28994. d *Decoder) (_ map[int32]bool, changed bool) {
  28995. dd, esep := d.d, d.hh.hasElemSeparators()
  28996. containerLen := dd.ReadMapStart()
  28997. if canChange && v == nil {
  28998. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  28999. v = make(map[int32]bool, xlen)
  29000. changed = true
  29001. }
  29002. if containerLen == 0 {
  29003. dd.ReadMapEnd()
  29004. return v, changed
  29005. }
  29006. var mk int32
  29007. var mv bool
  29008. hasLen := containerLen > 0
  29009. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29010. if esep {
  29011. dd.ReadMapElemKey()
  29012. }
  29013. mk = int32(dd.DecodeInt(32))
  29014. if esep {
  29015. dd.ReadMapElemValue()
  29016. }
  29017. if dd.TryDecodeAsNil() {
  29018. if d.h.DeleteOnNilMapValue {
  29019. delete(v, mk)
  29020. } else {
  29021. v[mk] = false
  29022. }
  29023. continue
  29024. }
  29025. mv = dd.DecodeBool()
  29026. if v != nil {
  29027. v[mk] = mv
  29028. }
  29029. }
  29030. dd.ReadMapEnd()
  29031. return v, changed
  29032. }
  29033. func (d *Decoder) fastpathDecMapInt64IntfR(f *codecFnInfo, rv reflect.Value) {
  29034. if rv.Kind() == reflect.Ptr {
  29035. vp := rv2i(rv).(*map[int64]interface{})
  29036. if v, changed := fastpathTV.DecMapInt64IntfV(*vp, true, d); changed {
  29037. *vp = v
  29038. }
  29039. return
  29040. }
  29041. fastpathTV.DecMapInt64IntfV(rv2i(rv).(map[int64]interface{}), false, d)
  29042. }
  29043. func (f fastpathT) DecMapInt64IntfX(vp *map[int64]interface{}, d *Decoder) {
  29044. if v, changed := f.DecMapInt64IntfV(*vp, true, d); changed {
  29045. *vp = v
  29046. }
  29047. }
  29048. func (_ fastpathT) DecMapInt64IntfV(v map[int64]interface{}, canChange bool,
  29049. d *Decoder) (_ map[int64]interface{}, changed bool) {
  29050. dd, esep := d.d, d.hh.hasElemSeparators()
  29051. containerLen := dd.ReadMapStart()
  29052. if canChange && v == nil {
  29053. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  29054. v = make(map[int64]interface{}, xlen)
  29055. changed = true
  29056. }
  29057. if containerLen == 0 {
  29058. dd.ReadMapEnd()
  29059. return v, changed
  29060. }
  29061. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  29062. var mk int64
  29063. var mv interface{}
  29064. hasLen := containerLen > 0
  29065. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29066. if esep {
  29067. dd.ReadMapElemKey()
  29068. }
  29069. mk = dd.DecodeInt(64)
  29070. if esep {
  29071. dd.ReadMapElemValue()
  29072. }
  29073. if dd.TryDecodeAsNil() {
  29074. if d.h.DeleteOnNilMapValue {
  29075. delete(v, mk)
  29076. } else {
  29077. v[mk] = nil
  29078. }
  29079. continue
  29080. }
  29081. if mapGet {
  29082. mv = v[mk]
  29083. } else {
  29084. mv = nil
  29085. }
  29086. d.decode(&mv)
  29087. if v != nil {
  29088. v[mk] = mv
  29089. }
  29090. }
  29091. dd.ReadMapEnd()
  29092. return v, changed
  29093. }
  29094. func (d *Decoder) fastpathDecMapInt64StringR(f *codecFnInfo, rv reflect.Value) {
  29095. if rv.Kind() == reflect.Ptr {
  29096. vp := rv2i(rv).(*map[int64]string)
  29097. if v, changed := fastpathTV.DecMapInt64StringV(*vp, true, d); changed {
  29098. *vp = v
  29099. }
  29100. return
  29101. }
  29102. fastpathTV.DecMapInt64StringV(rv2i(rv).(map[int64]string), false, d)
  29103. }
  29104. func (f fastpathT) DecMapInt64StringX(vp *map[int64]string, d *Decoder) {
  29105. if v, changed := f.DecMapInt64StringV(*vp, true, d); changed {
  29106. *vp = v
  29107. }
  29108. }
  29109. func (_ fastpathT) DecMapInt64StringV(v map[int64]string, canChange bool,
  29110. d *Decoder) (_ map[int64]string, changed bool) {
  29111. dd, esep := d.d, d.hh.hasElemSeparators()
  29112. containerLen := dd.ReadMapStart()
  29113. if canChange && v == nil {
  29114. xlen := decInferLen(containerLen, d.h.MaxInitLen, 24)
  29115. v = make(map[int64]string, xlen)
  29116. changed = true
  29117. }
  29118. if containerLen == 0 {
  29119. dd.ReadMapEnd()
  29120. return v, changed
  29121. }
  29122. var mk int64
  29123. var mv string
  29124. hasLen := containerLen > 0
  29125. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29126. if esep {
  29127. dd.ReadMapElemKey()
  29128. }
  29129. mk = dd.DecodeInt(64)
  29130. if esep {
  29131. dd.ReadMapElemValue()
  29132. }
  29133. if dd.TryDecodeAsNil() {
  29134. if d.h.DeleteOnNilMapValue {
  29135. delete(v, mk)
  29136. } else {
  29137. v[mk] = ""
  29138. }
  29139. continue
  29140. }
  29141. mv = dd.DecodeString()
  29142. if v != nil {
  29143. v[mk] = mv
  29144. }
  29145. }
  29146. dd.ReadMapEnd()
  29147. return v, changed
  29148. }
  29149. func (d *Decoder) fastpathDecMapInt64UintR(f *codecFnInfo, rv reflect.Value) {
  29150. if rv.Kind() == reflect.Ptr {
  29151. vp := rv2i(rv).(*map[int64]uint)
  29152. if v, changed := fastpathTV.DecMapInt64UintV(*vp, true, d); changed {
  29153. *vp = v
  29154. }
  29155. return
  29156. }
  29157. fastpathTV.DecMapInt64UintV(rv2i(rv).(map[int64]uint), false, d)
  29158. }
  29159. func (f fastpathT) DecMapInt64UintX(vp *map[int64]uint, d *Decoder) {
  29160. if v, changed := f.DecMapInt64UintV(*vp, true, d); changed {
  29161. *vp = v
  29162. }
  29163. }
  29164. func (_ fastpathT) DecMapInt64UintV(v map[int64]uint, canChange bool,
  29165. d *Decoder) (_ map[int64]uint, changed bool) {
  29166. dd, esep := d.d, d.hh.hasElemSeparators()
  29167. containerLen := dd.ReadMapStart()
  29168. if canChange && v == nil {
  29169. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  29170. v = make(map[int64]uint, xlen)
  29171. changed = true
  29172. }
  29173. if containerLen == 0 {
  29174. dd.ReadMapEnd()
  29175. return v, changed
  29176. }
  29177. var mk int64
  29178. var mv uint
  29179. hasLen := containerLen > 0
  29180. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29181. if esep {
  29182. dd.ReadMapElemKey()
  29183. }
  29184. mk = dd.DecodeInt(64)
  29185. if esep {
  29186. dd.ReadMapElemValue()
  29187. }
  29188. if dd.TryDecodeAsNil() {
  29189. if d.h.DeleteOnNilMapValue {
  29190. delete(v, mk)
  29191. } else {
  29192. v[mk] = 0
  29193. }
  29194. continue
  29195. }
  29196. mv = uint(dd.DecodeUint(uintBitsize))
  29197. if v != nil {
  29198. v[mk] = mv
  29199. }
  29200. }
  29201. dd.ReadMapEnd()
  29202. return v, changed
  29203. }
  29204. func (d *Decoder) fastpathDecMapInt64Uint8R(f *codecFnInfo, rv reflect.Value) {
  29205. if rv.Kind() == reflect.Ptr {
  29206. vp := rv2i(rv).(*map[int64]uint8)
  29207. if v, changed := fastpathTV.DecMapInt64Uint8V(*vp, true, d); changed {
  29208. *vp = v
  29209. }
  29210. return
  29211. }
  29212. fastpathTV.DecMapInt64Uint8V(rv2i(rv).(map[int64]uint8), false, d)
  29213. }
  29214. func (f fastpathT) DecMapInt64Uint8X(vp *map[int64]uint8, d *Decoder) {
  29215. if v, changed := f.DecMapInt64Uint8V(*vp, true, d); changed {
  29216. *vp = v
  29217. }
  29218. }
  29219. func (_ fastpathT) DecMapInt64Uint8V(v map[int64]uint8, canChange bool,
  29220. d *Decoder) (_ map[int64]uint8, changed bool) {
  29221. dd, esep := d.d, d.hh.hasElemSeparators()
  29222. containerLen := dd.ReadMapStart()
  29223. if canChange && v == nil {
  29224. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  29225. v = make(map[int64]uint8, xlen)
  29226. changed = true
  29227. }
  29228. if containerLen == 0 {
  29229. dd.ReadMapEnd()
  29230. return v, changed
  29231. }
  29232. var mk int64
  29233. var mv uint8
  29234. hasLen := containerLen > 0
  29235. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29236. if esep {
  29237. dd.ReadMapElemKey()
  29238. }
  29239. mk = dd.DecodeInt(64)
  29240. if esep {
  29241. dd.ReadMapElemValue()
  29242. }
  29243. if dd.TryDecodeAsNil() {
  29244. if d.h.DeleteOnNilMapValue {
  29245. delete(v, mk)
  29246. } else {
  29247. v[mk] = 0
  29248. }
  29249. continue
  29250. }
  29251. mv = uint8(dd.DecodeUint(8))
  29252. if v != nil {
  29253. v[mk] = mv
  29254. }
  29255. }
  29256. dd.ReadMapEnd()
  29257. return v, changed
  29258. }
  29259. func (d *Decoder) fastpathDecMapInt64Uint16R(f *codecFnInfo, rv reflect.Value) {
  29260. if rv.Kind() == reflect.Ptr {
  29261. vp := rv2i(rv).(*map[int64]uint16)
  29262. if v, changed := fastpathTV.DecMapInt64Uint16V(*vp, true, d); changed {
  29263. *vp = v
  29264. }
  29265. return
  29266. }
  29267. fastpathTV.DecMapInt64Uint16V(rv2i(rv).(map[int64]uint16), false, d)
  29268. }
  29269. func (f fastpathT) DecMapInt64Uint16X(vp *map[int64]uint16, d *Decoder) {
  29270. if v, changed := f.DecMapInt64Uint16V(*vp, true, d); changed {
  29271. *vp = v
  29272. }
  29273. }
  29274. func (_ fastpathT) DecMapInt64Uint16V(v map[int64]uint16, canChange bool,
  29275. d *Decoder) (_ map[int64]uint16, changed bool) {
  29276. dd, esep := d.d, d.hh.hasElemSeparators()
  29277. containerLen := dd.ReadMapStart()
  29278. if canChange && v == nil {
  29279. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  29280. v = make(map[int64]uint16, xlen)
  29281. changed = true
  29282. }
  29283. if containerLen == 0 {
  29284. dd.ReadMapEnd()
  29285. return v, changed
  29286. }
  29287. var mk int64
  29288. var mv uint16
  29289. hasLen := containerLen > 0
  29290. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29291. if esep {
  29292. dd.ReadMapElemKey()
  29293. }
  29294. mk = dd.DecodeInt(64)
  29295. if esep {
  29296. dd.ReadMapElemValue()
  29297. }
  29298. if dd.TryDecodeAsNil() {
  29299. if d.h.DeleteOnNilMapValue {
  29300. delete(v, mk)
  29301. } else {
  29302. v[mk] = 0
  29303. }
  29304. continue
  29305. }
  29306. mv = uint16(dd.DecodeUint(16))
  29307. if v != nil {
  29308. v[mk] = mv
  29309. }
  29310. }
  29311. dd.ReadMapEnd()
  29312. return v, changed
  29313. }
  29314. func (d *Decoder) fastpathDecMapInt64Uint32R(f *codecFnInfo, rv reflect.Value) {
  29315. if rv.Kind() == reflect.Ptr {
  29316. vp := rv2i(rv).(*map[int64]uint32)
  29317. if v, changed := fastpathTV.DecMapInt64Uint32V(*vp, true, d); changed {
  29318. *vp = v
  29319. }
  29320. return
  29321. }
  29322. fastpathTV.DecMapInt64Uint32V(rv2i(rv).(map[int64]uint32), false, d)
  29323. }
  29324. func (f fastpathT) DecMapInt64Uint32X(vp *map[int64]uint32, d *Decoder) {
  29325. if v, changed := f.DecMapInt64Uint32V(*vp, true, d); changed {
  29326. *vp = v
  29327. }
  29328. }
  29329. func (_ fastpathT) DecMapInt64Uint32V(v map[int64]uint32, canChange bool,
  29330. d *Decoder) (_ map[int64]uint32, changed bool) {
  29331. dd, esep := d.d, d.hh.hasElemSeparators()
  29332. containerLen := dd.ReadMapStart()
  29333. if canChange && v == nil {
  29334. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  29335. v = make(map[int64]uint32, xlen)
  29336. changed = true
  29337. }
  29338. if containerLen == 0 {
  29339. dd.ReadMapEnd()
  29340. return v, changed
  29341. }
  29342. var mk int64
  29343. var mv uint32
  29344. hasLen := containerLen > 0
  29345. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29346. if esep {
  29347. dd.ReadMapElemKey()
  29348. }
  29349. mk = dd.DecodeInt(64)
  29350. if esep {
  29351. dd.ReadMapElemValue()
  29352. }
  29353. if dd.TryDecodeAsNil() {
  29354. if d.h.DeleteOnNilMapValue {
  29355. delete(v, mk)
  29356. } else {
  29357. v[mk] = 0
  29358. }
  29359. continue
  29360. }
  29361. mv = uint32(dd.DecodeUint(32))
  29362. if v != nil {
  29363. v[mk] = mv
  29364. }
  29365. }
  29366. dd.ReadMapEnd()
  29367. return v, changed
  29368. }
  29369. func (d *Decoder) fastpathDecMapInt64Uint64R(f *codecFnInfo, rv reflect.Value) {
  29370. if rv.Kind() == reflect.Ptr {
  29371. vp := rv2i(rv).(*map[int64]uint64)
  29372. if v, changed := fastpathTV.DecMapInt64Uint64V(*vp, true, d); changed {
  29373. *vp = v
  29374. }
  29375. return
  29376. }
  29377. fastpathTV.DecMapInt64Uint64V(rv2i(rv).(map[int64]uint64), false, d)
  29378. }
  29379. func (f fastpathT) DecMapInt64Uint64X(vp *map[int64]uint64, d *Decoder) {
  29380. if v, changed := f.DecMapInt64Uint64V(*vp, true, d); changed {
  29381. *vp = v
  29382. }
  29383. }
  29384. func (_ fastpathT) DecMapInt64Uint64V(v map[int64]uint64, canChange bool,
  29385. d *Decoder) (_ map[int64]uint64, changed bool) {
  29386. dd, esep := d.d, d.hh.hasElemSeparators()
  29387. containerLen := dd.ReadMapStart()
  29388. if canChange && v == nil {
  29389. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  29390. v = make(map[int64]uint64, xlen)
  29391. changed = true
  29392. }
  29393. if containerLen == 0 {
  29394. dd.ReadMapEnd()
  29395. return v, changed
  29396. }
  29397. var mk int64
  29398. var mv uint64
  29399. hasLen := containerLen > 0
  29400. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29401. if esep {
  29402. dd.ReadMapElemKey()
  29403. }
  29404. mk = dd.DecodeInt(64)
  29405. if esep {
  29406. dd.ReadMapElemValue()
  29407. }
  29408. if dd.TryDecodeAsNil() {
  29409. if d.h.DeleteOnNilMapValue {
  29410. delete(v, mk)
  29411. } else {
  29412. v[mk] = 0
  29413. }
  29414. continue
  29415. }
  29416. mv = dd.DecodeUint(64)
  29417. if v != nil {
  29418. v[mk] = mv
  29419. }
  29420. }
  29421. dd.ReadMapEnd()
  29422. return v, changed
  29423. }
  29424. func (d *Decoder) fastpathDecMapInt64UintptrR(f *codecFnInfo, rv reflect.Value) {
  29425. if rv.Kind() == reflect.Ptr {
  29426. vp := rv2i(rv).(*map[int64]uintptr)
  29427. if v, changed := fastpathTV.DecMapInt64UintptrV(*vp, true, d); changed {
  29428. *vp = v
  29429. }
  29430. return
  29431. }
  29432. fastpathTV.DecMapInt64UintptrV(rv2i(rv).(map[int64]uintptr), false, d)
  29433. }
  29434. func (f fastpathT) DecMapInt64UintptrX(vp *map[int64]uintptr, d *Decoder) {
  29435. if v, changed := f.DecMapInt64UintptrV(*vp, true, d); changed {
  29436. *vp = v
  29437. }
  29438. }
  29439. func (_ fastpathT) DecMapInt64UintptrV(v map[int64]uintptr, canChange bool,
  29440. d *Decoder) (_ map[int64]uintptr, changed bool) {
  29441. dd, esep := d.d, d.hh.hasElemSeparators()
  29442. containerLen := dd.ReadMapStart()
  29443. if canChange && v == nil {
  29444. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  29445. v = make(map[int64]uintptr, xlen)
  29446. changed = true
  29447. }
  29448. if containerLen == 0 {
  29449. dd.ReadMapEnd()
  29450. return v, changed
  29451. }
  29452. var mk int64
  29453. var mv uintptr
  29454. hasLen := containerLen > 0
  29455. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29456. if esep {
  29457. dd.ReadMapElemKey()
  29458. }
  29459. mk = dd.DecodeInt(64)
  29460. if esep {
  29461. dd.ReadMapElemValue()
  29462. }
  29463. if dd.TryDecodeAsNil() {
  29464. if d.h.DeleteOnNilMapValue {
  29465. delete(v, mk)
  29466. } else {
  29467. v[mk] = 0
  29468. }
  29469. continue
  29470. }
  29471. mv = uintptr(dd.DecodeUint(uintBitsize))
  29472. if v != nil {
  29473. v[mk] = mv
  29474. }
  29475. }
  29476. dd.ReadMapEnd()
  29477. return v, changed
  29478. }
  29479. func (d *Decoder) fastpathDecMapInt64IntR(f *codecFnInfo, rv reflect.Value) {
  29480. if rv.Kind() == reflect.Ptr {
  29481. vp := rv2i(rv).(*map[int64]int)
  29482. if v, changed := fastpathTV.DecMapInt64IntV(*vp, true, d); changed {
  29483. *vp = v
  29484. }
  29485. return
  29486. }
  29487. fastpathTV.DecMapInt64IntV(rv2i(rv).(map[int64]int), false, d)
  29488. }
  29489. func (f fastpathT) DecMapInt64IntX(vp *map[int64]int, d *Decoder) {
  29490. if v, changed := f.DecMapInt64IntV(*vp, true, d); changed {
  29491. *vp = v
  29492. }
  29493. }
  29494. func (_ fastpathT) DecMapInt64IntV(v map[int64]int, canChange bool,
  29495. d *Decoder) (_ map[int64]int, changed bool) {
  29496. dd, esep := d.d, d.hh.hasElemSeparators()
  29497. containerLen := dd.ReadMapStart()
  29498. if canChange && v == nil {
  29499. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  29500. v = make(map[int64]int, xlen)
  29501. changed = true
  29502. }
  29503. if containerLen == 0 {
  29504. dd.ReadMapEnd()
  29505. return v, changed
  29506. }
  29507. var mk int64
  29508. var mv int
  29509. hasLen := containerLen > 0
  29510. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29511. if esep {
  29512. dd.ReadMapElemKey()
  29513. }
  29514. mk = dd.DecodeInt(64)
  29515. if esep {
  29516. dd.ReadMapElemValue()
  29517. }
  29518. if dd.TryDecodeAsNil() {
  29519. if d.h.DeleteOnNilMapValue {
  29520. delete(v, mk)
  29521. } else {
  29522. v[mk] = 0
  29523. }
  29524. continue
  29525. }
  29526. mv = int(dd.DecodeInt(intBitsize))
  29527. if v != nil {
  29528. v[mk] = mv
  29529. }
  29530. }
  29531. dd.ReadMapEnd()
  29532. return v, changed
  29533. }
  29534. func (d *Decoder) fastpathDecMapInt64Int8R(f *codecFnInfo, rv reflect.Value) {
  29535. if rv.Kind() == reflect.Ptr {
  29536. vp := rv2i(rv).(*map[int64]int8)
  29537. if v, changed := fastpathTV.DecMapInt64Int8V(*vp, true, d); changed {
  29538. *vp = v
  29539. }
  29540. return
  29541. }
  29542. fastpathTV.DecMapInt64Int8V(rv2i(rv).(map[int64]int8), false, d)
  29543. }
  29544. func (f fastpathT) DecMapInt64Int8X(vp *map[int64]int8, d *Decoder) {
  29545. if v, changed := f.DecMapInt64Int8V(*vp, true, d); changed {
  29546. *vp = v
  29547. }
  29548. }
  29549. func (_ fastpathT) DecMapInt64Int8V(v map[int64]int8, canChange bool,
  29550. d *Decoder) (_ map[int64]int8, changed bool) {
  29551. dd, esep := d.d, d.hh.hasElemSeparators()
  29552. containerLen := dd.ReadMapStart()
  29553. if canChange && v == nil {
  29554. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  29555. v = make(map[int64]int8, xlen)
  29556. changed = true
  29557. }
  29558. if containerLen == 0 {
  29559. dd.ReadMapEnd()
  29560. return v, changed
  29561. }
  29562. var mk int64
  29563. var mv int8
  29564. hasLen := containerLen > 0
  29565. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29566. if esep {
  29567. dd.ReadMapElemKey()
  29568. }
  29569. mk = dd.DecodeInt(64)
  29570. if esep {
  29571. dd.ReadMapElemValue()
  29572. }
  29573. if dd.TryDecodeAsNil() {
  29574. if d.h.DeleteOnNilMapValue {
  29575. delete(v, mk)
  29576. } else {
  29577. v[mk] = 0
  29578. }
  29579. continue
  29580. }
  29581. mv = int8(dd.DecodeInt(8))
  29582. if v != nil {
  29583. v[mk] = mv
  29584. }
  29585. }
  29586. dd.ReadMapEnd()
  29587. return v, changed
  29588. }
  29589. func (d *Decoder) fastpathDecMapInt64Int16R(f *codecFnInfo, rv reflect.Value) {
  29590. if rv.Kind() == reflect.Ptr {
  29591. vp := rv2i(rv).(*map[int64]int16)
  29592. if v, changed := fastpathTV.DecMapInt64Int16V(*vp, true, d); changed {
  29593. *vp = v
  29594. }
  29595. return
  29596. }
  29597. fastpathTV.DecMapInt64Int16V(rv2i(rv).(map[int64]int16), false, d)
  29598. }
  29599. func (f fastpathT) DecMapInt64Int16X(vp *map[int64]int16, d *Decoder) {
  29600. if v, changed := f.DecMapInt64Int16V(*vp, true, d); changed {
  29601. *vp = v
  29602. }
  29603. }
  29604. func (_ fastpathT) DecMapInt64Int16V(v map[int64]int16, canChange bool,
  29605. d *Decoder) (_ map[int64]int16, changed bool) {
  29606. dd, esep := d.d, d.hh.hasElemSeparators()
  29607. containerLen := dd.ReadMapStart()
  29608. if canChange && v == nil {
  29609. xlen := decInferLen(containerLen, d.h.MaxInitLen, 10)
  29610. v = make(map[int64]int16, xlen)
  29611. changed = true
  29612. }
  29613. if containerLen == 0 {
  29614. dd.ReadMapEnd()
  29615. return v, changed
  29616. }
  29617. var mk int64
  29618. var mv int16
  29619. hasLen := containerLen > 0
  29620. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29621. if esep {
  29622. dd.ReadMapElemKey()
  29623. }
  29624. mk = dd.DecodeInt(64)
  29625. if esep {
  29626. dd.ReadMapElemValue()
  29627. }
  29628. if dd.TryDecodeAsNil() {
  29629. if d.h.DeleteOnNilMapValue {
  29630. delete(v, mk)
  29631. } else {
  29632. v[mk] = 0
  29633. }
  29634. continue
  29635. }
  29636. mv = int16(dd.DecodeInt(16))
  29637. if v != nil {
  29638. v[mk] = mv
  29639. }
  29640. }
  29641. dd.ReadMapEnd()
  29642. return v, changed
  29643. }
  29644. func (d *Decoder) fastpathDecMapInt64Int32R(f *codecFnInfo, rv reflect.Value) {
  29645. if rv.Kind() == reflect.Ptr {
  29646. vp := rv2i(rv).(*map[int64]int32)
  29647. if v, changed := fastpathTV.DecMapInt64Int32V(*vp, true, d); changed {
  29648. *vp = v
  29649. }
  29650. return
  29651. }
  29652. fastpathTV.DecMapInt64Int32V(rv2i(rv).(map[int64]int32), false, d)
  29653. }
  29654. func (f fastpathT) DecMapInt64Int32X(vp *map[int64]int32, d *Decoder) {
  29655. if v, changed := f.DecMapInt64Int32V(*vp, true, d); changed {
  29656. *vp = v
  29657. }
  29658. }
  29659. func (_ fastpathT) DecMapInt64Int32V(v map[int64]int32, canChange bool,
  29660. d *Decoder) (_ map[int64]int32, changed bool) {
  29661. dd, esep := d.d, d.hh.hasElemSeparators()
  29662. containerLen := dd.ReadMapStart()
  29663. if canChange && v == nil {
  29664. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  29665. v = make(map[int64]int32, xlen)
  29666. changed = true
  29667. }
  29668. if containerLen == 0 {
  29669. dd.ReadMapEnd()
  29670. return v, changed
  29671. }
  29672. var mk int64
  29673. var mv int32
  29674. hasLen := containerLen > 0
  29675. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29676. if esep {
  29677. dd.ReadMapElemKey()
  29678. }
  29679. mk = dd.DecodeInt(64)
  29680. if esep {
  29681. dd.ReadMapElemValue()
  29682. }
  29683. if dd.TryDecodeAsNil() {
  29684. if d.h.DeleteOnNilMapValue {
  29685. delete(v, mk)
  29686. } else {
  29687. v[mk] = 0
  29688. }
  29689. continue
  29690. }
  29691. mv = int32(dd.DecodeInt(32))
  29692. if v != nil {
  29693. v[mk] = mv
  29694. }
  29695. }
  29696. dd.ReadMapEnd()
  29697. return v, changed
  29698. }
  29699. func (d *Decoder) fastpathDecMapInt64Int64R(f *codecFnInfo, rv reflect.Value) {
  29700. if rv.Kind() == reflect.Ptr {
  29701. vp := rv2i(rv).(*map[int64]int64)
  29702. if v, changed := fastpathTV.DecMapInt64Int64V(*vp, true, d); changed {
  29703. *vp = v
  29704. }
  29705. return
  29706. }
  29707. fastpathTV.DecMapInt64Int64V(rv2i(rv).(map[int64]int64), false, d)
  29708. }
  29709. func (f fastpathT) DecMapInt64Int64X(vp *map[int64]int64, d *Decoder) {
  29710. if v, changed := f.DecMapInt64Int64V(*vp, true, d); changed {
  29711. *vp = v
  29712. }
  29713. }
  29714. func (_ fastpathT) DecMapInt64Int64V(v map[int64]int64, canChange bool,
  29715. d *Decoder) (_ map[int64]int64, changed bool) {
  29716. dd, esep := d.d, d.hh.hasElemSeparators()
  29717. containerLen := dd.ReadMapStart()
  29718. if canChange && v == nil {
  29719. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  29720. v = make(map[int64]int64, xlen)
  29721. changed = true
  29722. }
  29723. if containerLen == 0 {
  29724. dd.ReadMapEnd()
  29725. return v, changed
  29726. }
  29727. var mk int64
  29728. var mv int64
  29729. hasLen := containerLen > 0
  29730. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29731. if esep {
  29732. dd.ReadMapElemKey()
  29733. }
  29734. mk = dd.DecodeInt(64)
  29735. if esep {
  29736. dd.ReadMapElemValue()
  29737. }
  29738. if dd.TryDecodeAsNil() {
  29739. if d.h.DeleteOnNilMapValue {
  29740. delete(v, mk)
  29741. } else {
  29742. v[mk] = 0
  29743. }
  29744. continue
  29745. }
  29746. mv = dd.DecodeInt(64)
  29747. if v != nil {
  29748. v[mk] = mv
  29749. }
  29750. }
  29751. dd.ReadMapEnd()
  29752. return v, changed
  29753. }
  29754. func (d *Decoder) fastpathDecMapInt64Float32R(f *codecFnInfo, rv reflect.Value) {
  29755. if rv.Kind() == reflect.Ptr {
  29756. vp := rv2i(rv).(*map[int64]float32)
  29757. if v, changed := fastpathTV.DecMapInt64Float32V(*vp, true, d); changed {
  29758. *vp = v
  29759. }
  29760. return
  29761. }
  29762. fastpathTV.DecMapInt64Float32V(rv2i(rv).(map[int64]float32), false, d)
  29763. }
  29764. func (f fastpathT) DecMapInt64Float32X(vp *map[int64]float32, d *Decoder) {
  29765. if v, changed := f.DecMapInt64Float32V(*vp, true, d); changed {
  29766. *vp = v
  29767. }
  29768. }
  29769. func (_ fastpathT) DecMapInt64Float32V(v map[int64]float32, canChange bool,
  29770. d *Decoder) (_ map[int64]float32, changed bool) {
  29771. dd, esep := d.d, d.hh.hasElemSeparators()
  29772. containerLen := dd.ReadMapStart()
  29773. if canChange && v == nil {
  29774. xlen := decInferLen(containerLen, d.h.MaxInitLen, 12)
  29775. v = make(map[int64]float32, xlen)
  29776. changed = true
  29777. }
  29778. if containerLen == 0 {
  29779. dd.ReadMapEnd()
  29780. return v, changed
  29781. }
  29782. var mk int64
  29783. var mv float32
  29784. hasLen := containerLen > 0
  29785. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29786. if esep {
  29787. dd.ReadMapElemKey()
  29788. }
  29789. mk = dd.DecodeInt(64)
  29790. if esep {
  29791. dd.ReadMapElemValue()
  29792. }
  29793. if dd.TryDecodeAsNil() {
  29794. if d.h.DeleteOnNilMapValue {
  29795. delete(v, mk)
  29796. } else {
  29797. v[mk] = 0
  29798. }
  29799. continue
  29800. }
  29801. mv = float32(dd.DecodeFloat(true))
  29802. if v != nil {
  29803. v[mk] = mv
  29804. }
  29805. }
  29806. dd.ReadMapEnd()
  29807. return v, changed
  29808. }
  29809. func (d *Decoder) fastpathDecMapInt64Float64R(f *codecFnInfo, rv reflect.Value) {
  29810. if rv.Kind() == reflect.Ptr {
  29811. vp := rv2i(rv).(*map[int64]float64)
  29812. if v, changed := fastpathTV.DecMapInt64Float64V(*vp, true, d); changed {
  29813. *vp = v
  29814. }
  29815. return
  29816. }
  29817. fastpathTV.DecMapInt64Float64V(rv2i(rv).(map[int64]float64), false, d)
  29818. }
  29819. func (f fastpathT) DecMapInt64Float64X(vp *map[int64]float64, d *Decoder) {
  29820. if v, changed := f.DecMapInt64Float64V(*vp, true, d); changed {
  29821. *vp = v
  29822. }
  29823. }
  29824. func (_ fastpathT) DecMapInt64Float64V(v map[int64]float64, canChange bool,
  29825. d *Decoder) (_ map[int64]float64, changed bool) {
  29826. dd, esep := d.d, d.hh.hasElemSeparators()
  29827. containerLen := dd.ReadMapStart()
  29828. if canChange && v == nil {
  29829. xlen := decInferLen(containerLen, d.h.MaxInitLen, 16)
  29830. v = make(map[int64]float64, xlen)
  29831. changed = true
  29832. }
  29833. if containerLen == 0 {
  29834. dd.ReadMapEnd()
  29835. return v, changed
  29836. }
  29837. var mk int64
  29838. var mv float64
  29839. hasLen := containerLen > 0
  29840. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29841. if esep {
  29842. dd.ReadMapElemKey()
  29843. }
  29844. mk = dd.DecodeInt(64)
  29845. if esep {
  29846. dd.ReadMapElemValue()
  29847. }
  29848. if dd.TryDecodeAsNil() {
  29849. if d.h.DeleteOnNilMapValue {
  29850. delete(v, mk)
  29851. } else {
  29852. v[mk] = 0
  29853. }
  29854. continue
  29855. }
  29856. mv = dd.DecodeFloat(false)
  29857. if v != nil {
  29858. v[mk] = mv
  29859. }
  29860. }
  29861. dd.ReadMapEnd()
  29862. return v, changed
  29863. }
  29864. func (d *Decoder) fastpathDecMapInt64BoolR(f *codecFnInfo, rv reflect.Value) {
  29865. if rv.Kind() == reflect.Ptr {
  29866. vp := rv2i(rv).(*map[int64]bool)
  29867. if v, changed := fastpathTV.DecMapInt64BoolV(*vp, true, d); changed {
  29868. *vp = v
  29869. }
  29870. return
  29871. }
  29872. fastpathTV.DecMapInt64BoolV(rv2i(rv).(map[int64]bool), false, d)
  29873. }
  29874. func (f fastpathT) DecMapInt64BoolX(vp *map[int64]bool, d *Decoder) {
  29875. if v, changed := f.DecMapInt64BoolV(*vp, true, d); changed {
  29876. *vp = v
  29877. }
  29878. }
  29879. func (_ fastpathT) DecMapInt64BoolV(v map[int64]bool, canChange bool,
  29880. d *Decoder) (_ map[int64]bool, changed bool) {
  29881. dd, esep := d.d, d.hh.hasElemSeparators()
  29882. containerLen := dd.ReadMapStart()
  29883. if canChange && v == nil {
  29884. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  29885. v = make(map[int64]bool, xlen)
  29886. changed = true
  29887. }
  29888. if containerLen == 0 {
  29889. dd.ReadMapEnd()
  29890. return v, changed
  29891. }
  29892. var mk int64
  29893. var mv bool
  29894. hasLen := containerLen > 0
  29895. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29896. if esep {
  29897. dd.ReadMapElemKey()
  29898. }
  29899. mk = dd.DecodeInt(64)
  29900. if esep {
  29901. dd.ReadMapElemValue()
  29902. }
  29903. if dd.TryDecodeAsNil() {
  29904. if d.h.DeleteOnNilMapValue {
  29905. delete(v, mk)
  29906. } else {
  29907. v[mk] = false
  29908. }
  29909. continue
  29910. }
  29911. mv = dd.DecodeBool()
  29912. if v != nil {
  29913. v[mk] = mv
  29914. }
  29915. }
  29916. dd.ReadMapEnd()
  29917. return v, changed
  29918. }
  29919. func (d *Decoder) fastpathDecMapBoolIntfR(f *codecFnInfo, rv reflect.Value) {
  29920. if rv.Kind() == reflect.Ptr {
  29921. vp := rv2i(rv).(*map[bool]interface{})
  29922. if v, changed := fastpathTV.DecMapBoolIntfV(*vp, true, d); changed {
  29923. *vp = v
  29924. }
  29925. return
  29926. }
  29927. fastpathTV.DecMapBoolIntfV(rv2i(rv).(map[bool]interface{}), false, d)
  29928. }
  29929. func (f fastpathT) DecMapBoolIntfX(vp *map[bool]interface{}, d *Decoder) {
  29930. if v, changed := f.DecMapBoolIntfV(*vp, true, d); changed {
  29931. *vp = v
  29932. }
  29933. }
  29934. func (_ fastpathT) DecMapBoolIntfV(v map[bool]interface{}, canChange bool,
  29935. d *Decoder) (_ map[bool]interface{}, changed bool) {
  29936. dd, esep := d.d, d.hh.hasElemSeparators()
  29937. containerLen := dd.ReadMapStart()
  29938. if canChange && v == nil {
  29939. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  29940. v = make(map[bool]interface{}, xlen)
  29941. changed = true
  29942. }
  29943. if containerLen == 0 {
  29944. dd.ReadMapEnd()
  29945. return v, changed
  29946. }
  29947. mapGet := !d.h.MapValueReset && !d.h.InterfaceReset
  29948. var mk bool
  29949. var mv interface{}
  29950. hasLen := containerLen > 0
  29951. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  29952. if esep {
  29953. dd.ReadMapElemKey()
  29954. }
  29955. mk = dd.DecodeBool()
  29956. if esep {
  29957. dd.ReadMapElemValue()
  29958. }
  29959. if dd.TryDecodeAsNil() {
  29960. if d.h.DeleteOnNilMapValue {
  29961. delete(v, mk)
  29962. } else {
  29963. v[mk] = nil
  29964. }
  29965. continue
  29966. }
  29967. if mapGet {
  29968. mv = v[mk]
  29969. } else {
  29970. mv = nil
  29971. }
  29972. d.decode(&mv)
  29973. if v != nil {
  29974. v[mk] = mv
  29975. }
  29976. }
  29977. dd.ReadMapEnd()
  29978. return v, changed
  29979. }
  29980. func (d *Decoder) fastpathDecMapBoolStringR(f *codecFnInfo, rv reflect.Value) {
  29981. if rv.Kind() == reflect.Ptr {
  29982. vp := rv2i(rv).(*map[bool]string)
  29983. if v, changed := fastpathTV.DecMapBoolStringV(*vp, true, d); changed {
  29984. *vp = v
  29985. }
  29986. return
  29987. }
  29988. fastpathTV.DecMapBoolStringV(rv2i(rv).(map[bool]string), false, d)
  29989. }
  29990. func (f fastpathT) DecMapBoolStringX(vp *map[bool]string, d *Decoder) {
  29991. if v, changed := f.DecMapBoolStringV(*vp, true, d); changed {
  29992. *vp = v
  29993. }
  29994. }
  29995. func (_ fastpathT) DecMapBoolStringV(v map[bool]string, canChange bool,
  29996. d *Decoder) (_ map[bool]string, changed bool) {
  29997. dd, esep := d.d, d.hh.hasElemSeparators()
  29998. containerLen := dd.ReadMapStart()
  29999. if canChange && v == nil {
  30000. xlen := decInferLen(containerLen, d.h.MaxInitLen, 17)
  30001. v = make(map[bool]string, xlen)
  30002. changed = true
  30003. }
  30004. if containerLen == 0 {
  30005. dd.ReadMapEnd()
  30006. return v, changed
  30007. }
  30008. var mk bool
  30009. var mv string
  30010. hasLen := containerLen > 0
  30011. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30012. if esep {
  30013. dd.ReadMapElemKey()
  30014. }
  30015. mk = dd.DecodeBool()
  30016. if esep {
  30017. dd.ReadMapElemValue()
  30018. }
  30019. if dd.TryDecodeAsNil() {
  30020. if d.h.DeleteOnNilMapValue {
  30021. delete(v, mk)
  30022. } else {
  30023. v[mk] = ""
  30024. }
  30025. continue
  30026. }
  30027. mv = dd.DecodeString()
  30028. if v != nil {
  30029. v[mk] = mv
  30030. }
  30031. }
  30032. dd.ReadMapEnd()
  30033. return v, changed
  30034. }
  30035. func (d *Decoder) fastpathDecMapBoolUintR(f *codecFnInfo, rv reflect.Value) {
  30036. if rv.Kind() == reflect.Ptr {
  30037. vp := rv2i(rv).(*map[bool]uint)
  30038. if v, changed := fastpathTV.DecMapBoolUintV(*vp, true, d); changed {
  30039. *vp = v
  30040. }
  30041. return
  30042. }
  30043. fastpathTV.DecMapBoolUintV(rv2i(rv).(map[bool]uint), false, d)
  30044. }
  30045. func (f fastpathT) DecMapBoolUintX(vp *map[bool]uint, d *Decoder) {
  30046. if v, changed := f.DecMapBoolUintV(*vp, true, d); changed {
  30047. *vp = v
  30048. }
  30049. }
  30050. func (_ fastpathT) DecMapBoolUintV(v map[bool]uint, canChange bool,
  30051. d *Decoder) (_ map[bool]uint, changed bool) {
  30052. dd, esep := d.d, d.hh.hasElemSeparators()
  30053. containerLen := dd.ReadMapStart()
  30054. if canChange && v == nil {
  30055. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  30056. v = make(map[bool]uint, xlen)
  30057. changed = true
  30058. }
  30059. if containerLen == 0 {
  30060. dd.ReadMapEnd()
  30061. return v, changed
  30062. }
  30063. var mk bool
  30064. var mv uint
  30065. hasLen := containerLen > 0
  30066. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30067. if esep {
  30068. dd.ReadMapElemKey()
  30069. }
  30070. mk = dd.DecodeBool()
  30071. if esep {
  30072. dd.ReadMapElemValue()
  30073. }
  30074. if dd.TryDecodeAsNil() {
  30075. if d.h.DeleteOnNilMapValue {
  30076. delete(v, mk)
  30077. } else {
  30078. v[mk] = 0
  30079. }
  30080. continue
  30081. }
  30082. mv = uint(dd.DecodeUint(uintBitsize))
  30083. if v != nil {
  30084. v[mk] = mv
  30085. }
  30086. }
  30087. dd.ReadMapEnd()
  30088. return v, changed
  30089. }
  30090. func (d *Decoder) fastpathDecMapBoolUint8R(f *codecFnInfo, rv reflect.Value) {
  30091. if rv.Kind() == reflect.Ptr {
  30092. vp := rv2i(rv).(*map[bool]uint8)
  30093. if v, changed := fastpathTV.DecMapBoolUint8V(*vp, true, d); changed {
  30094. *vp = v
  30095. }
  30096. return
  30097. }
  30098. fastpathTV.DecMapBoolUint8V(rv2i(rv).(map[bool]uint8), false, d)
  30099. }
  30100. func (f fastpathT) DecMapBoolUint8X(vp *map[bool]uint8, d *Decoder) {
  30101. if v, changed := f.DecMapBoolUint8V(*vp, true, d); changed {
  30102. *vp = v
  30103. }
  30104. }
  30105. func (_ fastpathT) DecMapBoolUint8V(v map[bool]uint8, canChange bool,
  30106. d *Decoder) (_ map[bool]uint8, changed bool) {
  30107. dd, esep := d.d, d.hh.hasElemSeparators()
  30108. containerLen := dd.ReadMapStart()
  30109. if canChange && v == nil {
  30110. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  30111. v = make(map[bool]uint8, xlen)
  30112. changed = true
  30113. }
  30114. if containerLen == 0 {
  30115. dd.ReadMapEnd()
  30116. return v, changed
  30117. }
  30118. var mk bool
  30119. var mv uint8
  30120. hasLen := containerLen > 0
  30121. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30122. if esep {
  30123. dd.ReadMapElemKey()
  30124. }
  30125. mk = dd.DecodeBool()
  30126. if esep {
  30127. dd.ReadMapElemValue()
  30128. }
  30129. if dd.TryDecodeAsNil() {
  30130. if d.h.DeleteOnNilMapValue {
  30131. delete(v, mk)
  30132. } else {
  30133. v[mk] = 0
  30134. }
  30135. continue
  30136. }
  30137. mv = uint8(dd.DecodeUint(8))
  30138. if v != nil {
  30139. v[mk] = mv
  30140. }
  30141. }
  30142. dd.ReadMapEnd()
  30143. return v, changed
  30144. }
  30145. func (d *Decoder) fastpathDecMapBoolUint16R(f *codecFnInfo, rv reflect.Value) {
  30146. if rv.Kind() == reflect.Ptr {
  30147. vp := rv2i(rv).(*map[bool]uint16)
  30148. if v, changed := fastpathTV.DecMapBoolUint16V(*vp, true, d); changed {
  30149. *vp = v
  30150. }
  30151. return
  30152. }
  30153. fastpathTV.DecMapBoolUint16V(rv2i(rv).(map[bool]uint16), false, d)
  30154. }
  30155. func (f fastpathT) DecMapBoolUint16X(vp *map[bool]uint16, d *Decoder) {
  30156. if v, changed := f.DecMapBoolUint16V(*vp, true, d); changed {
  30157. *vp = v
  30158. }
  30159. }
  30160. func (_ fastpathT) DecMapBoolUint16V(v map[bool]uint16, canChange bool,
  30161. d *Decoder) (_ map[bool]uint16, changed bool) {
  30162. dd, esep := d.d, d.hh.hasElemSeparators()
  30163. containerLen := dd.ReadMapStart()
  30164. if canChange && v == nil {
  30165. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  30166. v = make(map[bool]uint16, xlen)
  30167. changed = true
  30168. }
  30169. if containerLen == 0 {
  30170. dd.ReadMapEnd()
  30171. return v, changed
  30172. }
  30173. var mk bool
  30174. var mv uint16
  30175. hasLen := containerLen > 0
  30176. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30177. if esep {
  30178. dd.ReadMapElemKey()
  30179. }
  30180. mk = dd.DecodeBool()
  30181. if esep {
  30182. dd.ReadMapElemValue()
  30183. }
  30184. if dd.TryDecodeAsNil() {
  30185. if d.h.DeleteOnNilMapValue {
  30186. delete(v, mk)
  30187. } else {
  30188. v[mk] = 0
  30189. }
  30190. continue
  30191. }
  30192. mv = uint16(dd.DecodeUint(16))
  30193. if v != nil {
  30194. v[mk] = mv
  30195. }
  30196. }
  30197. dd.ReadMapEnd()
  30198. return v, changed
  30199. }
  30200. func (d *Decoder) fastpathDecMapBoolUint32R(f *codecFnInfo, rv reflect.Value) {
  30201. if rv.Kind() == reflect.Ptr {
  30202. vp := rv2i(rv).(*map[bool]uint32)
  30203. if v, changed := fastpathTV.DecMapBoolUint32V(*vp, true, d); changed {
  30204. *vp = v
  30205. }
  30206. return
  30207. }
  30208. fastpathTV.DecMapBoolUint32V(rv2i(rv).(map[bool]uint32), false, d)
  30209. }
  30210. func (f fastpathT) DecMapBoolUint32X(vp *map[bool]uint32, d *Decoder) {
  30211. if v, changed := f.DecMapBoolUint32V(*vp, true, d); changed {
  30212. *vp = v
  30213. }
  30214. }
  30215. func (_ fastpathT) DecMapBoolUint32V(v map[bool]uint32, canChange bool,
  30216. d *Decoder) (_ map[bool]uint32, changed bool) {
  30217. dd, esep := d.d, d.hh.hasElemSeparators()
  30218. containerLen := dd.ReadMapStart()
  30219. if canChange && v == nil {
  30220. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  30221. v = make(map[bool]uint32, xlen)
  30222. changed = true
  30223. }
  30224. if containerLen == 0 {
  30225. dd.ReadMapEnd()
  30226. return v, changed
  30227. }
  30228. var mk bool
  30229. var mv uint32
  30230. hasLen := containerLen > 0
  30231. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30232. if esep {
  30233. dd.ReadMapElemKey()
  30234. }
  30235. mk = dd.DecodeBool()
  30236. if esep {
  30237. dd.ReadMapElemValue()
  30238. }
  30239. if dd.TryDecodeAsNil() {
  30240. if d.h.DeleteOnNilMapValue {
  30241. delete(v, mk)
  30242. } else {
  30243. v[mk] = 0
  30244. }
  30245. continue
  30246. }
  30247. mv = uint32(dd.DecodeUint(32))
  30248. if v != nil {
  30249. v[mk] = mv
  30250. }
  30251. }
  30252. dd.ReadMapEnd()
  30253. return v, changed
  30254. }
  30255. func (d *Decoder) fastpathDecMapBoolUint64R(f *codecFnInfo, rv reflect.Value) {
  30256. if rv.Kind() == reflect.Ptr {
  30257. vp := rv2i(rv).(*map[bool]uint64)
  30258. if v, changed := fastpathTV.DecMapBoolUint64V(*vp, true, d); changed {
  30259. *vp = v
  30260. }
  30261. return
  30262. }
  30263. fastpathTV.DecMapBoolUint64V(rv2i(rv).(map[bool]uint64), false, d)
  30264. }
  30265. func (f fastpathT) DecMapBoolUint64X(vp *map[bool]uint64, d *Decoder) {
  30266. if v, changed := f.DecMapBoolUint64V(*vp, true, d); changed {
  30267. *vp = v
  30268. }
  30269. }
  30270. func (_ fastpathT) DecMapBoolUint64V(v map[bool]uint64, canChange bool,
  30271. d *Decoder) (_ map[bool]uint64, changed bool) {
  30272. dd, esep := d.d, d.hh.hasElemSeparators()
  30273. containerLen := dd.ReadMapStart()
  30274. if canChange && v == nil {
  30275. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  30276. v = make(map[bool]uint64, xlen)
  30277. changed = true
  30278. }
  30279. if containerLen == 0 {
  30280. dd.ReadMapEnd()
  30281. return v, changed
  30282. }
  30283. var mk bool
  30284. var mv uint64
  30285. hasLen := containerLen > 0
  30286. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30287. if esep {
  30288. dd.ReadMapElemKey()
  30289. }
  30290. mk = dd.DecodeBool()
  30291. if esep {
  30292. dd.ReadMapElemValue()
  30293. }
  30294. if dd.TryDecodeAsNil() {
  30295. if d.h.DeleteOnNilMapValue {
  30296. delete(v, mk)
  30297. } else {
  30298. v[mk] = 0
  30299. }
  30300. continue
  30301. }
  30302. mv = dd.DecodeUint(64)
  30303. if v != nil {
  30304. v[mk] = mv
  30305. }
  30306. }
  30307. dd.ReadMapEnd()
  30308. return v, changed
  30309. }
  30310. func (d *Decoder) fastpathDecMapBoolUintptrR(f *codecFnInfo, rv reflect.Value) {
  30311. if rv.Kind() == reflect.Ptr {
  30312. vp := rv2i(rv).(*map[bool]uintptr)
  30313. if v, changed := fastpathTV.DecMapBoolUintptrV(*vp, true, d); changed {
  30314. *vp = v
  30315. }
  30316. return
  30317. }
  30318. fastpathTV.DecMapBoolUintptrV(rv2i(rv).(map[bool]uintptr), false, d)
  30319. }
  30320. func (f fastpathT) DecMapBoolUintptrX(vp *map[bool]uintptr, d *Decoder) {
  30321. if v, changed := f.DecMapBoolUintptrV(*vp, true, d); changed {
  30322. *vp = v
  30323. }
  30324. }
  30325. func (_ fastpathT) DecMapBoolUintptrV(v map[bool]uintptr, canChange bool,
  30326. d *Decoder) (_ map[bool]uintptr, changed bool) {
  30327. dd, esep := d.d, d.hh.hasElemSeparators()
  30328. containerLen := dd.ReadMapStart()
  30329. if canChange && v == nil {
  30330. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  30331. v = make(map[bool]uintptr, xlen)
  30332. changed = true
  30333. }
  30334. if containerLen == 0 {
  30335. dd.ReadMapEnd()
  30336. return v, changed
  30337. }
  30338. var mk bool
  30339. var mv uintptr
  30340. hasLen := containerLen > 0
  30341. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30342. if esep {
  30343. dd.ReadMapElemKey()
  30344. }
  30345. mk = dd.DecodeBool()
  30346. if esep {
  30347. dd.ReadMapElemValue()
  30348. }
  30349. if dd.TryDecodeAsNil() {
  30350. if d.h.DeleteOnNilMapValue {
  30351. delete(v, mk)
  30352. } else {
  30353. v[mk] = 0
  30354. }
  30355. continue
  30356. }
  30357. mv = uintptr(dd.DecodeUint(uintBitsize))
  30358. if v != nil {
  30359. v[mk] = mv
  30360. }
  30361. }
  30362. dd.ReadMapEnd()
  30363. return v, changed
  30364. }
  30365. func (d *Decoder) fastpathDecMapBoolIntR(f *codecFnInfo, rv reflect.Value) {
  30366. if rv.Kind() == reflect.Ptr {
  30367. vp := rv2i(rv).(*map[bool]int)
  30368. if v, changed := fastpathTV.DecMapBoolIntV(*vp, true, d); changed {
  30369. *vp = v
  30370. }
  30371. return
  30372. }
  30373. fastpathTV.DecMapBoolIntV(rv2i(rv).(map[bool]int), false, d)
  30374. }
  30375. func (f fastpathT) DecMapBoolIntX(vp *map[bool]int, d *Decoder) {
  30376. if v, changed := f.DecMapBoolIntV(*vp, true, d); changed {
  30377. *vp = v
  30378. }
  30379. }
  30380. func (_ fastpathT) DecMapBoolIntV(v map[bool]int, canChange bool,
  30381. d *Decoder) (_ map[bool]int, changed bool) {
  30382. dd, esep := d.d, d.hh.hasElemSeparators()
  30383. containerLen := dd.ReadMapStart()
  30384. if canChange && v == nil {
  30385. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  30386. v = make(map[bool]int, xlen)
  30387. changed = true
  30388. }
  30389. if containerLen == 0 {
  30390. dd.ReadMapEnd()
  30391. return v, changed
  30392. }
  30393. var mk bool
  30394. var mv int
  30395. hasLen := containerLen > 0
  30396. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30397. if esep {
  30398. dd.ReadMapElemKey()
  30399. }
  30400. mk = dd.DecodeBool()
  30401. if esep {
  30402. dd.ReadMapElemValue()
  30403. }
  30404. if dd.TryDecodeAsNil() {
  30405. if d.h.DeleteOnNilMapValue {
  30406. delete(v, mk)
  30407. } else {
  30408. v[mk] = 0
  30409. }
  30410. continue
  30411. }
  30412. mv = int(dd.DecodeInt(intBitsize))
  30413. if v != nil {
  30414. v[mk] = mv
  30415. }
  30416. }
  30417. dd.ReadMapEnd()
  30418. return v, changed
  30419. }
  30420. func (d *Decoder) fastpathDecMapBoolInt8R(f *codecFnInfo, rv reflect.Value) {
  30421. if rv.Kind() == reflect.Ptr {
  30422. vp := rv2i(rv).(*map[bool]int8)
  30423. if v, changed := fastpathTV.DecMapBoolInt8V(*vp, true, d); changed {
  30424. *vp = v
  30425. }
  30426. return
  30427. }
  30428. fastpathTV.DecMapBoolInt8V(rv2i(rv).(map[bool]int8), false, d)
  30429. }
  30430. func (f fastpathT) DecMapBoolInt8X(vp *map[bool]int8, d *Decoder) {
  30431. if v, changed := f.DecMapBoolInt8V(*vp, true, d); changed {
  30432. *vp = v
  30433. }
  30434. }
  30435. func (_ fastpathT) DecMapBoolInt8V(v map[bool]int8, canChange bool,
  30436. d *Decoder) (_ map[bool]int8, changed bool) {
  30437. dd, esep := d.d, d.hh.hasElemSeparators()
  30438. containerLen := dd.ReadMapStart()
  30439. if canChange && v == nil {
  30440. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  30441. v = make(map[bool]int8, xlen)
  30442. changed = true
  30443. }
  30444. if containerLen == 0 {
  30445. dd.ReadMapEnd()
  30446. return v, changed
  30447. }
  30448. var mk bool
  30449. var mv int8
  30450. hasLen := containerLen > 0
  30451. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30452. if esep {
  30453. dd.ReadMapElemKey()
  30454. }
  30455. mk = dd.DecodeBool()
  30456. if esep {
  30457. dd.ReadMapElemValue()
  30458. }
  30459. if dd.TryDecodeAsNil() {
  30460. if d.h.DeleteOnNilMapValue {
  30461. delete(v, mk)
  30462. } else {
  30463. v[mk] = 0
  30464. }
  30465. continue
  30466. }
  30467. mv = int8(dd.DecodeInt(8))
  30468. if v != nil {
  30469. v[mk] = mv
  30470. }
  30471. }
  30472. dd.ReadMapEnd()
  30473. return v, changed
  30474. }
  30475. func (d *Decoder) fastpathDecMapBoolInt16R(f *codecFnInfo, rv reflect.Value) {
  30476. if rv.Kind() == reflect.Ptr {
  30477. vp := rv2i(rv).(*map[bool]int16)
  30478. if v, changed := fastpathTV.DecMapBoolInt16V(*vp, true, d); changed {
  30479. *vp = v
  30480. }
  30481. return
  30482. }
  30483. fastpathTV.DecMapBoolInt16V(rv2i(rv).(map[bool]int16), false, d)
  30484. }
  30485. func (f fastpathT) DecMapBoolInt16X(vp *map[bool]int16, d *Decoder) {
  30486. if v, changed := f.DecMapBoolInt16V(*vp, true, d); changed {
  30487. *vp = v
  30488. }
  30489. }
  30490. func (_ fastpathT) DecMapBoolInt16V(v map[bool]int16, canChange bool,
  30491. d *Decoder) (_ map[bool]int16, changed bool) {
  30492. dd, esep := d.d, d.hh.hasElemSeparators()
  30493. containerLen := dd.ReadMapStart()
  30494. if canChange && v == nil {
  30495. xlen := decInferLen(containerLen, d.h.MaxInitLen, 3)
  30496. v = make(map[bool]int16, xlen)
  30497. changed = true
  30498. }
  30499. if containerLen == 0 {
  30500. dd.ReadMapEnd()
  30501. return v, changed
  30502. }
  30503. var mk bool
  30504. var mv int16
  30505. hasLen := containerLen > 0
  30506. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30507. if esep {
  30508. dd.ReadMapElemKey()
  30509. }
  30510. mk = dd.DecodeBool()
  30511. if esep {
  30512. dd.ReadMapElemValue()
  30513. }
  30514. if dd.TryDecodeAsNil() {
  30515. if d.h.DeleteOnNilMapValue {
  30516. delete(v, mk)
  30517. } else {
  30518. v[mk] = 0
  30519. }
  30520. continue
  30521. }
  30522. mv = int16(dd.DecodeInt(16))
  30523. if v != nil {
  30524. v[mk] = mv
  30525. }
  30526. }
  30527. dd.ReadMapEnd()
  30528. return v, changed
  30529. }
  30530. func (d *Decoder) fastpathDecMapBoolInt32R(f *codecFnInfo, rv reflect.Value) {
  30531. if rv.Kind() == reflect.Ptr {
  30532. vp := rv2i(rv).(*map[bool]int32)
  30533. if v, changed := fastpathTV.DecMapBoolInt32V(*vp, true, d); changed {
  30534. *vp = v
  30535. }
  30536. return
  30537. }
  30538. fastpathTV.DecMapBoolInt32V(rv2i(rv).(map[bool]int32), false, d)
  30539. }
  30540. func (f fastpathT) DecMapBoolInt32X(vp *map[bool]int32, d *Decoder) {
  30541. if v, changed := f.DecMapBoolInt32V(*vp, true, d); changed {
  30542. *vp = v
  30543. }
  30544. }
  30545. func (_ fastpathT) DecMapBoolInt32V(v map[bool]int32, canChange bool,
  30546. d *Decoder) (_ map[bool]int32, changed bool) {
  30547. dd, esep := d.d, d.hh.hasElemSeparators()
  30548. containerLen := dd.ReadMapStart()
  30549. if canChange && v == nil {
  30550. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  30551. v = make(map[bool]int32, xlen)
  30552. changed = true
  30553. }
  30554. if containerLen == 0 {
  30555. dd.ReadMapEnd()
  30556. return v, changed
  30557. }
  30558. var mk bool
  30559. var mv int32
  30560. hasLen := containerLen > 0
  30561. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30562. if esep {
  30563. dd.ReadMapElemKey()
  30564. }
  30565. mk = dd.DecodeBool()
  30566. if esep {
  30567. dd.ReadMapElemValue()
  30568. }
  30569. if dd.TryDecodeAsNil() {
  30570. if d.h.DeleteOnNilMapValue {
  30571. delete(v, mk)
  30572. } else {
  30573. v[mk] = 0
  30574. }
  30575. continue
  30576. }
  30577. mv = int32(dd.DecodeInt(32))
  30578. if v != nil {
  30579. v[mk] = mv
  30580. }
  30581. }
  30582. dd.ReadMapEnd()
  30583. return v, changed
  30584. }
  30585. func (d *Decoder) fastpathDecMapBoolInt64R(f *codecFnInfo, rv reflect.Value) {
  30586. if rv.Kind() == reflect.Ptr {
  30587. vp := rv2i(rv).(*map[bool]int64)
  30588. if v, changed := fastpathTV.DecMapBoolInt64V(*vp, true, d); changed {
  30589. *vp = v
  30590. }
  30591. return
  30592. }
  30593. fastpathTV.DecMapBoolInt64V(rv2i(rv).(map[bool]int64), false, d)
  30594. }
  30595. func (f fastpathT) DecMapBoolInt64X(vp *map[bool]int64, d *Decoder) {
  30596. if v, changed := f.DecMapBoolInt64V(*vp, true, d); changed {
  30597. *vp = v
  30598. }
  30599. }
  30600. func (_ fastpathT) DecMapBoolInt64V(v map[bool]int64, canChange bool,
  30601. d *Decoder) (_ map[bool]int64, changed bool) {
  30602. dd, esep := d.d, d.hh.hasElemSeparators()
  30603. containerLen := dd.ReadMapStart()
  30604. if canChange && v == nil {
  30605. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  30606. v = make(map[bool]int64, xlen)
  30607. changed = true
  30608. }
  30609. if containerLen == 0 {
  30610. dd.ReadMapEnd()
  30611. return v, changed
  30612. }
  30613. var mk bool
  30614. var mv int64
  30615. hasLen := containerLen > 0
  30616. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30617. if esep {
  30618. dd.ReadMapElemKey()
  30619. }
  30620. mk = dd.DecodeBool()
  30621. if esep {
  30622. dd.ReadMapElemValue()
  30623. }
  30624. if dd.TryDecodeAsNil() {
  30625. if d.h.DeleteOnNilMapValue {
  30626. delete(v, mk)
  30627. } else {
  30628. v[mk] = 0
  30629. }
  30630. continue
  30631. }
  30632. mv = dd.DecodeInt(64)
  30633. if v != nil {
  30634. v[mk] = mv
  30635. }
  30636. }
  30637. dd.ReadMapEnd()
  30638. return v, changed
  30639. }
  30640. func (d *Decoder) fastpathDecMapBoolFloat32R(f *codecFnInfo, rv reflect.Value) {
  30641. if rv.Kind() == reflect.Ptr {
  30642. vp := rv2i(rv).(*map[bool]float32)
  30643. if v, changed := fastpathTV.DecMapBoolFloat32V(*vp, true, d); changed {
  30644. *vp = v
  30645. }
  30646. return
  30647. }
  30648. fastpathTV.DecMapBoolFloat32V(rv2i(rv).(map[bool]float32), false, d)
  30649. }
  30650. func (f fastpathT) DecMapBoolFloat32X(vp *map[bool]float32, d *Decoder) {
  30651. if v, changed := f.DecMapBoolFloat32V(*vp, true, d); changed {
  30652. *vp = v
  30653. }
  30654. }
  30655. func (_ fastpathT) DecMapBoolFloat32V(v map[bool]float32, canChange bool,
  30656. d *Decoder) (_ map[bool]float32, changed bool) {
  30657. dd, esep := d.d, d.hh.hasElemSeparators()
  30658. containerLen := dd.ReadMapStart()
  30659. if canChange && v == nil {
  30660. xlen := decInferLen(containerLen, d.h.MaxInitLen, 5)
  30661. v = make(map[bool]float32, xlen)
  30662. changed = true
  30663. }
  30664. if containerLen == 0 {
  30665. dd.ReadMapEnd()
  30666. return v, changed
  30667. }
  30668. var mk bool
  30669. var mv float32
  30670. hasLen := containerLen > 0
  30671. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30672. if esep {
  30673. dd.ReadMapElemKey()
  30674. }
  30675. mk = dd.DecodeBool()
  30676. if esep {
  30677. dd.ReadMapElemValue()
  30678. }
  30679. if dd.TryDecodeAsNil() {
  30680. if d.h.DeleteOnNilMapValue {
  30681. delete(v, mk)
  30682. } else {
  30683. v[mk] = 0
  30684. }
  30685. continue
  30686. }
  30687. mv = float32(dd.DecodeFloat(true))
  30688. if v != nil {
  30689. v[mk] = mv
  30690. }
  30691. }
  30692. dd.ReadMapEnd()
  30693. return v, changed
  30694. }
  30695. func (d *Decoder) fastpathDecMapBoolFloat64R(f *codecFnInfo, rv reflect.Value) {
  30696. if rv.Kind() == reflect.Ptr {
  30697. vp := rv2i(rv).(*map[bool]float64)
  30698. if v, changed := fastpathTV.DecMapBoolFloat64V(*vp, true, d); changed {
  30699. *vp = v
  30700. }
  30701. return
  30702. }
  30703. fastpathTV.DecMapBoolFloat64V(rv2i(rv).(map[bool]float64), false, d)
  30704. }
  30705. func (f fastpathT) DecMapBoolFloat64X(vp *map[bool]float64, d *Decoder) {
  30706. if v, changed := f.DecMapBoolFloat64V(*vp, true, d); changed {
  30707. *vp = v
  30708. }
  30709. }
  30710. func (_ fastpathT) DecMapBoolFloat64V(v map[bool]float64, canChange bool,
  30711. d *Decoder) (_ map[bool]float64, changed bool) {
  30712. dd, esep := d.d, d.hh.hasElemSeparators()
  30713. containerLen := dd.ReadMapStart()
  30714. if canChange && v == nil {
  30715. xlen := decInferLen(containerLen, d.h.MaxInitLen, 9)
  30716. v = make(map[bool]float64, xlen)
  30717. changed = true
  30718. }
  30719. if containerLen == 0 {
  30720. dd.ReadMapEnd()
  30721. return v, changed
  30722. }
  30723. var mk bool
  30724. var mv float64
  30725. hasLen := containerLen > 0
  30726. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30727. if esep {
  30728. dd.ReadMapElemKey()
  30729. }
  30730. mk = dd.DecodeBool()
  30731. if esep {
  30732. dd.ReadMapElemValue()
  30733. }
  30734. if dd.TryDecodeAsNil() {
  30735. if d.h.DeleteOnNilMapValue {
  30736. delete(v, mk)
  30737. } else {
  30738. v[mk] = 0
  30739. }
  30740. continue
  30741. }
  30742. mv = dd.DecodeFloat(false)
  30743. if v != nil {
  30744. v[mk] = mv
  30745. }
  30746. }
  30747. dd.ReadMapEnd()
  30748. return v, changed
  30749. }
  30750. func (d *Decoder) fastpathDecMapBoolBoolR(f *codecFnInfo, rv reflect.Value) {
  30751. if rv.Kind() == reflect.Ptr {
  30752. vp := rv2i(rv).(*map[bool]bool)
  30753. if v, changed := fastpathTV.DecMapBoolBoolV(*vp, true, d); changed {
  30754. *vp = v
  30755. }
  30756. return
  30757. }
  30758. fastpathTV.DecMapBoolBoolV(rv2i(rv).(map[bool]bool), false, d)
  30759. }
  30760. func (f fastpathT) DecMapBoolBoolX(vp *map[bool]bool, d *Decoder) {
  30761. if v, changed := f.DecMapBoolBoolV(*vp, true, d); changed {
  30762. *vp = v
  30763. }
  30764. }
  30765. func (_ fastpathT) DecMapBoolBoolV(v map[bool]bool, canChange bool,
  30766. d *Decoder) (_ map[bool]bool, changed bool) {
  30767. dd, esep := d.d, d.hh.hasElemSeparators()
  30768. containerLen := dd.ReadMapStart()
  30769. if canChange && v == nil {
  30770. xlen := decInferLen(containerLen, d.h.MaxInitLen, 2)
  30771. v = make(map[bool]bool, xlen)
  30772. changed = true
  30773. }
  30774. if containerLen == 0 {
  30775. dd.ReadMapEnd()
  30776. return v, changed
  30777. }
  30778. var mk bool
  30779. var mv bool
  30780. hasLen := containerLen > 0
  30781. for j := 0; (hasLen && j < containerLen) || !(hasLen || dd.CheckBreak()); j++ {
  30782. if esep {
  30783. dd.ReadMapElemKey()
  30784. }
  30785. mk = dd.DecodeBool()
  30786. if esep {
  30787. dd.ReadMapElemValue()
  30788. }
  30789. if dd.TryDecodeAsNil() {
  30790. if d.h.DeleteOnNilMapValue {
  30791. delete(v, mk)
  30792. } else {
  30793. v[mk] = false
  30794. }
  30795. continue
  30796. }
  30797. mv = dd.DecodeBool()
  30798. if v != nil {
  30799. v[mk] = mv
  30800. }
  30801. }
  30802. dd.ReadMapEnd()
  30803. return v, changed
  30804. }